react-crud-mobile 1.3.112 → 1.3.115

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.
@@ -1347,7 +1347,6 @@ function UIModal(_ref) {
1347
1347
  index = _useState2[0],
1348
1348
  setIndex = _useState2[1];
1349
1349
  //v6
1350
- var label = scope.getLabel();
1351
1350
  var theme = scope.getTheme();
1352
1351
  var headerStyle = Utils.nvl((_theme$styles = theme.styles) == null || (_theme$styles = _theme$styles.defaults) == null ? void 0 : _theme$styles.header, {});
1353
1352
  var scrollRef = useRef(null);
@@ -1378,6 +1377,15 @@ function UIModal(_ref) {
1378
1377
  if (curr.uuid !== ((_main$dialog = main.dialog) == null || (_main$dialog = _main$dialog.crud) == null ? void 0 : _main$dialog.uuid)) {
1379
1378
  return /*#__PURE__*/jsx(Fragment, {});
1380
1379
  }
1380
+ var dialogLabel = Utils.nvl(dialog == null ? void 0 : dialog.label, scope.getLabel());
1381
+ var _useState3 = useState(ScopeUtils.create({
1382
+ parent: scope,
1383
+ crud: curr,
1384
+ label: dialogLabel
1385
+ })),
1386
+ dialogScope = _useState3[0];
1387
+ console.log(dialogLabel); //v2
1388
+ var label = dialogScope.getLabel();
1381
1389
  var headerRight = ComponentUtils.getDefine(props, 'header', 'right');
1382
1390
  var bottom = ComponentUtils.getDefine(props, 'bottom');
1383
1391
  scope.put('scrollRef', scrollRef);
@@ -2078,7 +2086,7 @@ function UIElement(props) {
2078
2086
  });
2079
2087
  };
2080
2088
  scope.dialogShow = function (args) {
2081
- var _args$event;
2089
+ var _args$event, _args$event2;
2082
2090
  var main = ViewUtils.getCrud('view');
2083
2091
  var parent = main.dialog;
2084
2092
  var crud = args.crud;
@@ -2086,7 +2094,8 @@ function UIElement(props) {
2086
2094
  var edit = args.edit === true;
2087
2095
  var def = {};
2088
2096
  var rowItem = null;
2089
- var component = args == null || (_args$event = args.event) == null ? void 0 : _args$event.component;
2097
+ var label = args == null || (_args$event = args.event) == null ? void 0 : _args$event.title;
2098
+ var component = args == null || (_args$event2 = args.event) == null ? void 0 : _args$event2.component;
2090
2099
  if (crud.is('row')) {
2091
2100
  def.parent = crud.parent.parent;
2092
2101
  def.search = crud.parent;
@@ -2107,7 +2116,8 @@ function UIElement(props) {
2107
2116
  var dialog = {
2108
2117
  crud: d,
2109
2118
  parent: parent,
2110
- component: component
2119
+ component: component,
2120
+ label: label
2111
2121
  };
2112
2122
  main.dialog = dialog;
2113
2123
  scope.toggleDialog(true);