authscape 1.0.470 → 1.0.472
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/index.js +16 -2
- package/package.json +1 -1
- package/src/components/mapping/fileMapping.js +15 -1
package/index.js
CHANGED
|
@@ -4397,7 +4397,13 @@ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
|
4397
4397
|
|
|
4398
4398
|
function FileMapping(_ref) {
|
|
4399
4399
|
var currentUser = _ref.currentUser,
|
|
4400
|
-
hideDocumentManager = _ref.hideDocumentManager
|
|
4400
|
+
hideDocumentManager = _ref.hideDocumentManager,
|
|
4401
|
+
_ref$onPublished = _ref.onPublished,
|
|
4402
|
+
_onPublished = _ref$onPublished === void 0 ? null : _ref$onPublished,
|
|
4403
|
+
_ref$onCanceled = _ref.onCanceled,
|
|
4404
|
+
onCanceled = _ref$onCanceled === void 0 ? null : _ref$onCanceled,
|
|
4405
|
+
_ref$onArchived = _ref.onArchived,
|
|
4406
|
+
onArchived = _ref$onArchived === void 0 ? null : _ref$onArchived;
|
|
4401
4407
|
var _useState = (0, _react.useState)(null),
|
|
4402
4408
|
_useState2 = _slicedToArray(_useState, 2),
|
|
4403
4409
|
documentComponentId = _useState2[0],
|
|
@@ -4409,17 +4415,25 @@ function FileMapping(_ref) {
|
|
|
4409
4415
|
setDocumentComponentId(documentComponentId);
|
|
4410
4416
|
},
|
|
4411
4417
|
onArchive: function onArchive(documentComponentId) {
|
|
4412
|
-
|
|
4413
4418
|
//alert(documentComponentId);
|
|
4419
|
+
if (onArchived != null) {
|
|
4420
|
+
onArchived(documentComponentId);
|
|
4421
|
+
}
|
|
4414
4422
|
}
|
|
4415
4423
|
}), documentComponentId != null && /*#__PURE__*/_react["default"].createElement(AssignMapping, {
|
|
4416
4424
|
currentUser: currentUser,
|
|
4417
4425
|
documentComponentId: documentComponentId,
|
|
4418
4426
|
onCancel: function onCancel() {
|
|
4419
4427
|
setDocumentComponentId(null);
|
|
4428
|
+
if (onCanceled != null) {
|
|
4429
|
+
onCanceled(documentComponentId);
|
|
4430
|
+
}
|
|
4420
4431
|
},
|
|
4421
4432
|
onPublished: function onPublished() {
|
|
4422
4433
|
setDocumentComponentId(null);
|
|
4434
|
+
if (_onPublished != null) {
|
|
4435
|
+
_onPublished(documentComponentId);
|
|
4436
|
+
}
|
|
4423
4437
|
}
|
|
4424
4438
|
}));
|
|
4425
4439
|
}
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@ import { Box } from '@mui/system';
|
|
|
3
3
|
// import ManageMappingDocuments from './manageMappingDocuments';
|
|
4
4
|
// import AssignMapping from './AssignMapping';
|
|
5
5
|
|
|
6
|
-
export function FileMapping({currentUser, hideDocumentManager}) {
|
|
6
|
+
export function FileMapping({currentUser, hideDocumentManager, onPublished = null, onCanceled = null, onArchived = null}) {
|
|
7
7
|
|
|
8
8
|
const [documentComponentId, setDocumentComponentId] = useState(null);
|
|
9
9
|
|
|
@@ -21,6 +21,10 @@ export function FileMapping({currentUser, hideDocumentManager}) {
|
|
|
21
21
|
onArchive={(documentComponentId) => {
|
|
22
22
|
|
|
23
23
|
//alert(documentComponentId);
|
|
24
|
+
if (onArchived != null)
|
|
25
|
+
{
|
|
26
|
+
onArchived(documentComponentId);
|
|
27
|
+
}
|
|
24
28
|
|
|
25
29
|
}}
|
|
26
30
|
/>
|
|
@@ -31,10 +35,20 @@ export function FileMapping({currentUser, hideDocumentManager}) {
|
|
|
31
35
|
onCancel={() => {
|
|
32
36
|
|
|
33
37
|
setDocumentComponentId(null);
|
|
38
|
+
|
|
39
|
+
if (onCanceled != null)
|
|
40
|
+
{
|
|
41
|
+
onCanceled(documentComponentId);
|
|
42
|
+
}
|
|
34
43
|
|
|
35
44
|
}}
|
|
36
45
|
onPublished={() => {
|
|
37
46
|
setDocumentComponentId(null);
|
|
47
|
+
|
|
48
|
+
if (onPublished != null)
|
|
49
|
+
{
|
|
50
|
+
onPublished(documentComponentId);
|
|
51
|
+
}
|
|
38
52
|
}} />
|
|
39
53
|
}
|
|
40
54
|
|