ywana-core8 0.0.422 → 0.0.425
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.cjs +34 -18
- package/dist/index.cjs.map +1 -1
- package/dist/index.modern.js +34 -18
- package/dist/index.modern.js.map +1 -1
- package/dist/index.umd.js +34 -18
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
- package/src/domain/TablePage.js +1 -1
- package/src/site/site.js +4 -1
- package/src/widgets/upload/UploadDialog.js +2 -2
package/dist/index.modern.js
CHANGED
@@ -1095,8 +1095,6 @@ var DropDown = function DropDown(props) {
|
|
1095
1095
|
setLabel = _useState2[1];
|
1096
1096
|
|
1097
1097
|
useEffect(function () {
|
1098
|
-
console.log('DD change value', label);
|
1099
|
-
|
1100
1098
|
if (Array.isArray(options)) {
|
1101
1099
|
var option = options.find(function (option) {
|
1102
1100
|
return option.value === value;
|
@@ -3283,6 +3281,8 @@ var SiteMenu = function SiteMenu(_ref6) {
|
|
3283
3281
|
onClick: function onClick() {
|
3284
3282
|
return _goto(id);
|
3285
3283
|
}
|
3284
|
+
}, /*#__PURE__*/React.createElement(Tooltip, {
|
3285
|
+
text: title
|
3286
3286
|
}, /*#__PURE__*/React.createElement(Icon, {
|
3287
3287
|
key: id,
|
3288
3288
|
icon: icon,
|
@@ -3290,7 +3290,7 @@ var SiteMenu = function SiteMenu(_ref6) {
|
|
3290
3290
|
action: function action() {
|
3291
3291
|
return _goto(id);
|
3292
3292
|
}
|
3293
|
-
}), sideNav === 'max' ? /*#__PURE__*/React.createElement("label", null, title) : null);
|
3293
|
+
})), sideNav === 'max' ? /*#__PURE__*/React.createElement("label", null, title) : null);
|
3294
3294
|
}), /*#__PURE__*/React.createElement("div", {
|
3295
3295
|
className: "section-divider"
|
3296
3296
|
}));
|
@@ -3458,7 +3458,8 @@ var UploadDialog = function UploadDialog(_ref) {
|
|
3458
3458
|
onSuccess = _ref.onSuccess,
|
3459
3459
|
onComplete = _ref.onComplete,
|
3460
3460
|
onClose = _ref.onClose,
|
3461
|
-
children = _ref.children
|
3461
|
+
children = _ref.children,
|
3462
|
+
className = _ref.className;
|
3462
3463
|
var site = useContext(SiteContext);
|
3463
3464
|
|
3464
3465
|
function success(file, message) {
|
@@ -3489,7 +3490,8 @@ var UploadDialog = function UploadDialog(_ref) {
|
|
3489
3490
|
title: title,
|
3490
3491
|
open: true,
|
3491
3492
|
onAction: onAction,
|
3492
|
-
actions: actions
|
3493
|
+
actions: actions,
|
3494
|
+
className: className
|
3493
3495
|
}, /*#__PURE__*/React.createElement(Uploader, {
|
3494
3496
|
label: label,
|
3495
3497
|
accept: accept,
|
@@ -5348,6 +5350,16 @@ var TablePage = function TablePage(props) {
|
|
5348
5350
|
}
|
5349
5351
|
};
|
5350
5352
|
|
5353
|
+
var reload = function reload() {
|
5354
|
+
try {
|
5355
|
+
return Promise.resolve(pageContext.load()).then(function () {
|
5356
|
+
setPageContext(Object.assign({}, pageContext));
|
5357
|
+
});
|
5358
|
+
} catch (e) {
|
5359
|
+
return Promise.reject(e);
|
5360
|
+
}
|
5361
|
+
};
|
5362
|
+
|
5351
5363
|
var site = useContext(SiteContext);
|
5352
5364
|
var _props$id = props.id,
|
5353
5365
|
id = _props$id === void 0 ? "table" : _props$id,
|
@@ -5395,6 +5407,7 @@ var TablePage = function TablePage(props) {
|
|
5395
5407
|
pageContext = _useContext[0],
|
5396
5408
|
setPageContext = _useContext[1];
|
5397
5409
|
|
5410
|
+
var context = TableContext(url, field, host, urlQuery);
|
5398
5411
|
var selected = pageContext.selected;
|
5399
5412
|
var timer = useRef(null);
|
5400
5413
|
|
@@ -5402,20 +5415,8 @@ var TablePage = function TablePage(props) {
|
|
5402
5415
|
form = _useState[0],
|
5403
5416
|
setForm = _useState[1];
|
5404
5417
|
|
5405
|
-
useEffect(function () {
|
5406
|
-
setForm(selected);
|
5407
|
-
}, [selected]);
|
5408
|
-
useEffect(function () {
|
5409
|
-
if (autosave) {
|
5410
|
-
clearTimeout(timer.current);
|
5411
|
-
timer.current = setTimeout(function () {
|
5412
|
-
if (canSave()) save();
|
5413
|
-
}, delay);
|
5414
|
-
}
|
5415
|
-
}, [form]);
|
5416
5418
|
useEffect(function () {
|
5417
5419
|
try {
|
5418
|
-
var context = TableContext(url, field, host, urlQuery);
|
5419
5420
|
return Promise.resolve(context.load()).then(function () {
|
5420
5421
|
function _temp2() {
|
5421
5422
|
setPageContext(context);
|
@@ -5431,6 +5432,17 @@ var TablePage = function TablePage(props) {
|
|
5431
5432
|
return Promise.reject(e);
|
5432
5433
|
}
|
5433
5434
|
}, []);
|
5435
|
+
useEffect(function () {
|
5436
|
+
setForm(selected);
|
5437
|
+
}, [selected]);
|
5438
|
+
useEffect(function () {
|
5439
|
+
if (autosave) {
|
5440
|
+
clearTimeout(timer.current);
|
5441
|
+
timer.current = setTimeout(function () {
|
5442
|
+
if (canSave()) save();
|
5443
|
+
}, delay);
|
5444
|
+
}
|
5445
|
+
}, [form]);
|
5434
5446
|
|
5435
5447
|
function add() {
|
5436
5448
|
var onOK = function onOK(form) {
|
@@ -5530,7 +5542,11 @@ var TablePage = function TablePage(props) {
|
|
5530
5542
|
label: "A\xF1adir",
|
5531
5543
|
action: add,
|
5532
5544
|
raised: true
|
5533
|
-
}) : null,
|
5545
|
+
}) : null, "\xA0", /*#__PURE__*/React.createElement(Button, {
|
5546
|
+
icon: "refresh",
|
5547
|
+
label: "Reload",
|
5548
|
+
action: reload
|
5549
|
+
}), dev ? /*#__PURE__*/React.createElement(MenuIcon, {
|
5534
5550
|
align: "alignRight"
|
5535
5551
|
}, /*#__PURE__*/React.createElement(MenuItem, {
|
5536
5552
|
label: "Cargar Escenario 1",
|