@mcurros2/microm 1.1.456-0 → 1.1.458-0

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 CHANGED
@@ -8208,6 +8208,19 @@ function $44e7b7cb2565e4b7$export$c7c6b9c457b10b8a(props) {
8208
8208
  }),
8209
8209
  ...parentKeys
8210
8210
  };
8211
+ const saveResult = await handleSaveBeforeAdd();
8212
+ if (saveResult === "error") {
8213
+ await modals.close();
8214
+ return {
8215
+ Failed: true,
8216
+ Results: [
8217
+ {
8218
+ Status: 11,
8219
+ Message: "Failed to save data before deletion"
8220
+ }
8221
+ ]
8222
+ };
8223
+ }
8211
8224
  if (keys.length === 1) {
8212
8225
  (0, $iKzSR.setValues)(deleteEntity.def.columns, keys[0], null, true);
8213
8226
  // Delete selected keys from mergedParentKeys
@@ -8290,7 +8303,8 @@ function $44e7b7cb2565e4b7$export$c7c6b9c457b10b8a(props) {
8290
8303
  modals,
8291
8304
  labels,
8292
8305
  parentKeys,
8293
- onRecordsDeleted
8306
+ onRecordsDeleted,
8307
+ handleSaveBeforeAdd
8294
8308
  ]);
8295
8309
  const handleDeleteClick = (0, $b4te3$react.useCallback)(async (keys, element)=>{
8296
8310
  if (onDeleteClick) {
@@ -9018,7 +9032,7 @@ const $e95081ddc267bf42$export$ac599717ae3cc508 = {
9018
9032
  };
9019
9033
  function $e95081ddc267bf42$export$2d99b517780ef7c2(props) {
9020
9034
  const mergedProps = (0, $b4te3$mantinecore.useComponentDefaultProps)('ImportDataPanel', $e95081ddc267bf42$export$ac599717ae3cc508, props);
9021
- const { client: client, entityConstructor: _entityConstructor, entityLoader: _entityLoader, parentKeys: parentKeys, entityProcName: entityProcName, importFileStepProps: importFileStepProps, loadingComponent: loadingComponent, stepperProps: suppliedStepperProps, historyEntityView: historyEntityView, ...dataGridProps } = mergedProps;
9035
+ const { client: client, entityConstructor: _entityConstructor, entityLoader: _entityLoader, parentKeys: parentKeys, entityProcName: entityProcName, importFileStepProps: importFileStepProps, loadingComponent: loadingComponent, stepperProps: suppliedStepperProps, ...dataGridProps } = mergedProps;
9022
9036
  const stepperProps = (0, $b4te3$react.useMemo)(()=>({
9023
9037
  ...$e95081ddc267bf42$export$ac599717ae3cc508.stepperProps,
9024
9038
  ...suppliedStepperProps
@@ -9038,23 +9052,16 @@ function $e95081ddc267bf42$export$2d99b517780ef7c2(props) {
9038
9052
  importFileStepProps: importFileStepProps,
9039
9053
  stepperProps: stepperProps
9040
9054
  });
9041
- if (historyEntityView) historyEntity.def.views = {
9042
- ...historyEntity.def.views,
9043
- [historyEntityView.name]: {
9044
- ...historyEntityView
9045
- }
9046
- };
9047
9055
  return {
9048
9056
  entity: historyEntity,
9049
- view: historyEntityView ? historyEntityView.name : historyEntity.def.views.ipr_brwStandard.name
9057
+ view: historyEntity.def.views.ipr_brwStandard.name
9050
9058
  };
9051
9059
  }, [
9052
9060
  destinationEntity,
9053
9061
  destinationEntityViewName,
9054
9062
  entityProcName,
9055
9063
  importFileStepProps,
9056
- stepperProps,
9057
- historyEntityView
9064
+ stepperProps
9058
9065
  ]);
9059
9066
  const historyParentKeys = (0, $b4te3$react.useMemo)(()=>destinationEntity ? {
9060
9067
  vc_assemblytypename: destinationEntity.name