@asaleh37/ui-base 25.12.171 → 25.12.173
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/components/templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid.tsx +2 -4
- package/src/components/templates/attachment/AttachmentImageViewer.tsx +2 -2
package/package.json
CHANGED
|
@@ -637,8 +637,7 @@ const TemplateGrid: React.FC<TemplateGridProps> = (props) => {
|
|
|
637
637
|
}
|
|
638
638
|
}
|
|
639
639
|
if (
|
|
640
|
-
record[props?.keyColumnName || "id"] &&
|
|
641
|
-
record[props?.keyColumnName || "id"] > 0 &&
|
|
640
|
+
(record[props?.keyColumnName] || (record["id"] && record["id"] > 0)) &&
|
|
642
641
|
props?.attachment
|
|
643
642
|
) {
|
|
644
643
|
actions?.push(
|
|
@@ -666,8 +665,7 @@ const TemplateGrid: React.FC<TemplateGridProps> = (props) => {
|
|
|
666
665
|
);
|
|
667
666
|
}
|
|
668
667
|
if (
|
|
669
|
-
record[props?.keyColumnName || "id"] &&
|
|
670
|
-
record[props?.keyColumnName || "id"] > 0 &&
|
|
668
|
+
(record[props?.keyColumnName] || (record["id"] && record["id"] > 0)) &&
|
|
671
669
|
props?.workFlowDocumentCode
|
|
672
670
|
) {
|
|
673
671
|
actions?.push(
|
|
@@ -30,10 +30,10 @@ const AttachmentImageViewer: React.FC<AttachmentImageViewerProps> = (props) => {
|
|
|
30
30
|
setImgSrc(imagePath);
|
|
31
31
|
};
|
|
32
32
|
useEffect(() => {
|
|
33
|
-
if (props?.refKey) {
|
|
33
|
+
if (props?.refKey || props?.attachmentId) {
|
|
34
34
|
handleImageSrc();
|
|
35
35
|
}
|
|
36
|
-
}, [props.refKey]);
|
|
36
|
+
}, [props.refKey, props?.attachmentId]);
|
|
37
37
|
{
|
|
38
38
|
/* </Avatar>
|
|
39
39
|
src={imgSrc}
|