@@ -421,12 +421,18 @@ function PdfRequestFiles(props) {
421
421
//getting document details
422
422
const documentData = await contractDocument ( docId ) ;
423
423
if ( documentData && documentData . length > 0 ) {
424
- const docSignTypes = documentData ?. [ 0 ] ?. SignatureType || signatureTypes ;
424
+ const userSignatureType =
425
+ documentData [ 0 ] ?. ExtUserPtr ?. SignatureType || signatureTypes ;
426
+ const docSignTypes =
427
+ documentData ?. [ 0 ] ?. SignatureType || userSignatureType ;
425
428
const updatedSignatureType = await handleSignatureType (
426
429
tenantSignTypes ,
427
430
docSignTypes
428
431
) ;
429
432
setSignatureType ( updatedSignatureType ) ;
433
+ const updatedPdfDetails = [ ...documentData ] ;
434
+ updatedPdfDetails [ 0 ] . SignatureType = updatedSignatureType ;
435
+ setPdfDetails ( updatedPdfDetails ) ;
430
436
const url =
431
437
documentData [ 0 ] &&
432
438
( documentData [ 0 ] ?. SignedUrl || documentData [ 0 ] ?. URL ) ;
@@ -2130,28 +2136,30 @@ function PdfRequestFiles(props) {
2130
2136
</ div >
2131
2137
</ ModalUi >
2132
2138
{ /* this component is used for signature pad modal */ }
2133
- < SignPad
2134
- signatureTypes = { signatureType }
2135
- isSignPad = { isSignPad }
2136
- isStamp = { isStamp }
2137
- setIsImageSelect = { setIsImageSelect }
2138
- setIsSignPad = { setIsSignPad }
2139
- setImage = { setImage }
2140
- isImageSelect = { isImageSelect }
2141
- imageRef = { imageRef }
2142
- onImageChange = { onImageChange }
2143
- setSignature = { setSignature }
2144
- image = { image }
2145
- onSaveImage = { saveImage }
2146
- onSaveSign = { saveSign }
2147
- defaultSign = { defaultSignImg }
2148
- myInitial = { myInitial }
2149
- isInitial = { isInitial }
2150
- setIsInitial = { setIsInitial }
2151
- setIsStamp = { setIsStamp }
2152
- currWidgetsDetails = { currWidgetsDetails }
2153
- setCurrWidgetsDetails = { setCurrWidgetsDetails }
2154
- />
2139
+ { documentId && (
2140
+ < SignPad
2141
+ signatureTypes = { signatureType }
2142
+ isSignPad = { isSignPad }
2143
+ isStamp = { isStamp }
2144
+ setIsImageSelect = { setIsImageSelect }
2145
+ setIsSignPad = { setIsSignPad }
2146
+ setImage = { setImage }
2147
+ isImageSelect = { isImageSelect }
2148
+ imageRef = { imageRef }
2149
+ onImageChange = { onImageChange }
2150
+ setSignature = { setSignature }
2151
+ image = { image }
2152
+ onSaveImage = { saveImage }
2153
+ onSaveSign = { saveSign }
2154
+ defaultSign = { defaultSignImg }
2155
+ myInitial = { myInitial }
2156
+ isInitial = { isInitial }
2157
+ setIsInitial = { setIsInitial }
2158
+ setIsStamp = { setIsStamp }
2159
+ currWidgetsDetails = { currWidgetsDetails }
2160
+ setCurrWidgetsDetails = { setCurrWidgetsDetails }
2161
+ />
2162
+ ) }
2155
2163
{ /* pdf header which contain funish back button */ }
2156
2164
< Header
2157
2165
isPdfRequestFiles = { isPublicTemplate ? false : true }
0 commit comments