awing-library 2.1.72-beta → 2.1.74-beta
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.
|
@@ -215,6 +215,8 @@ function updateStateByPageModel(pageModel) {
|
|
|
215
215
|
}));
|
|
216
216
|
}
|
|
217
217
|
exports.updateStateByPageModel = updateStateByPageModel;
|
|
218
|
+
var getFieldsValue = function (template) {
|
|
219
|
+
};
|
|
218
220
|
/**
|
|
219
221
|
* Retrieves the template data based on the provided template parameters, view information data, page ID, and view number.
|
|
220
222
|
*
|
|
@@ -230,6 +232,15 @@ var getTemplateDatas = function (templateParameters, viewInfoData, pageId, viewN
|
|
|
230
232
|
? viewInfoData.viewDatas.find(function (el) { return el.fieldName === parameter.fieldName; })
|
|
231
233
|
: null;
|
|
232
234
|
var valData = tempData ? tempData.fieldValue : null;
|
|
235
|
+
var child = {};
|
|
236
|
+
getChilds(parameter, function (item) {
|
|
237
|
+
var keys = item.fieldName.split('.');
|
|
238
|
+
if (keys.length > 1) {
|
|
239
|
+
console.log("item.fieldValue", item.fieldValue);
|
|
240
|
+
child[keys.at(-1)] = item.fieldValue;
|
|
241
|
+
}
|
|
242
|
+
});
|
|
243
|
+
console.log("child", child);
|
|
233
244
|
var fieldValue = valData !== null && valData !== void 0 ? valData : (parameter.defaultValue ? parameter.defaultValue : '');
|
|
234
245
|
fieldValue = (0, exports.convertValueByType)(parameter.fieldType, fieldValue);
|
|
235
246
|
return {
|
|
@@ -151,9 +151,7 @@ var CreateOrEdit = function () {
|
|
|
151
151
|
onChange: function (_k, name) {
|
|
152
152
|
handleJobActionChange(jobActions.filter(function (x) { return x.name === name; })[0]);
|
|
153
153
|
handleChange('jobAction', name);
|
|
154
|
-
}, value: jobModel.jobAction, children: jobActions.map(function (item) { return ((0, jsx_runtime_1.jsx)(material_1.MenuItem, { value: item.name, children: item.name }, item.name)); }) }) }), (0, jsx_runtime_1.jsx)(material_1.Grid, { item: true, xs: 8, style: { marginTop: '16px' }, children: (jobModel === null || jobModel === void 0 ? void 0 : jobModel.inputParameters) && ((0, jsx_runtime_1.jsx)(InputParameters_1.default, { inputParameters: jobModel === null || jobModel === void 0 ? void 0 : jobModel.inputParameters, jobActionSelected: jobActionSelected, handleInputParamChange: handleInputParamChange })) }), (0, jsx_runtime_1.jsx)(material_1.Grid, { item: true, xs: 6, children: (0, jsx_runtime_1.jsxs)(material_1.Grid, { container: true, children: [(0, jsx_runtime_1.jsx)(material_1.Grid, { item: true, xs: 6, style: { paddingRight: '10px' }, children: (0, jsx_runtime_1.jsx)(BasicInput_1.default, { fullWidth: true, name: "authUsername", required: false, label: t('User.Username'), checkValid: function (value) {
|
|
155
|
-
return (0, validation_1.textValidation)(value, 50, false);
|
|
156
|
-
}, onChange: handleChange, value: jobModel.authUsername }) }), (0, jsx_runtime_1.jsx)(material_1.Grid, { item: true, xs: 5, style: { paddingRight: '10px' }, children: (0, jsx_runtime_1.jsx)(BasicInput_1.default, { fullWidth: true, autoComplete: "current-password", name: "authPassword", type: "password", required: false, label: t('User.Password'), onChange: handleChange, value: jobModel.authPassword }) }), (0, jsx_runtime_1.jsx)(material_1.Grid, { item: true, xs: 1, children: (0, jsx_runtime_1.jsx)(material_1.Tooltip, { placement: "top", title: t('TaskScheduler.Help.Authen'), arrow: true, children: (0, jsx_runtime_1.jsx)(icons_material_1.HelpOutline, { fontSize: "small", color: "action", style: {
|
|
154
|
+
}, value: jobModel.jobAction, children: jobActions.map(function (item) { return ((0, jsx_runtime_1.jsx)(material_1.MenuItem, { value: item.name, children: item.name }, item.name)); }) }) }), (0, jsx_runtime_1.jsx)(material_1.Grid, { item: true, xs: 8, style: { marginTop: '16px' }, children: (jobModel === null || jobModel === void 0 ? void 0 : jobModel.inputParameters) && ((0, jsx_runtime_1.jsx)(InputParameters_1.default, { inputParameters: jobModel === null || jobModel === void 0 ? void 0 : jobModel.inputParameters, jobActionSelected: jobActionSelected, handleInputParamChange: handleInputParamChange })) }), (0, jsx_runtime_1.jsx)(material_1.Grid, { item: true, xs: 6, children: (0, jsx_runtime_1.jsxs)(material_1.Grid, { container: true, children: [(0, jsx_runtime_1.jsx)(material_1.Grid, { item: true, xs: 6, style: { paddingRight: '10px' }, children: (0, jsx_runtime_1.jsx)(BasicInput_1.default, { fullWidth: true, name: "authUsername", required: false, label: t('User.Username'), checkValid: function (value) { return (0, validation_1.textValidation)(value, 150, false, /^[a-zA-Z0-9\/\-_.@()\[\] ]+$/g, false); }, onChange: handleChange, value: jobModel.authUsername }) }), (0, jsx_runtime_1.jsx)(material_1.Grid, { item: true, xs: 5, style: { paddingRight: '10px' }, children: (0, jsx_runtime_1.jsx)(BasicInput_1.default, { fullWidth: true, autoComplete: "current-password", name: "authPassword", type: "password", required: false, label: t('User.Password'), onChange: handleChange, value: jobModel.authPassword }) }), (0, jsx_runtime_1.jsx)(material_1.Grid, { item: true, xs: 1, children: (0, jsx_runtime_1.jsx)(material_1.Tooltip, { placement: "top", title: t('TaskScheduler.Help.Authen'), arrow: true, children: (0, jsx_runtime_1.jsx)(icons_material_1.HelpOutline, { fontSize: "small", color: "action", style: {
|
|
157
155
|
marginTop: '20px',
|
|
158
156
|
marginLeft: '-10px',
|
|
159
157
|
} }) }) })] }) })] }) }), (0, jsx_runtime_1.jsx)(material_1.Grid, { item: true, children: (0, jsx_runtime_1.jsx)(material_1.FormControlLabel, { control: (0, jsx_runtime_1.jsx)(material_1.Checkbox, { name: "status", checked: jobModel.status, onChange: function (event) {
|
|
@@ -12,6 +12,8 @@ exports.cloneValue = exports.getFormValidation = void 0;
|
|
|
12
12
|
var Enums_1 = require("./Enums");
|
|
13
13
|
var getFormValidation = function (job, jobValid) {
|
|
14
14
|
var isValid = false;
|
|
15
|
+
if (!Object.values(jobValid).length)
|
|
16
|
+
return true;
|
|
15
17
|
if (job.jobType === Enums_1.JobTypeEnum.Trigger) {
|
|
16
18
|
isValid =
|
|
17
19
|
(Boolean(job.triggerTopic) ||
|
|
@@ -27,7 +29,10 @@ var getFormValidation = function (job, jobValid) {
|
|
|
27
29
|
(jobValid['cronTime'] !== undefined &&
|
|
28
30
|
jobValid['cronTime'])) && job.inputParameters.length > 0;
|
|
29
31
|
}
|
|
30
|
-
|
|
32
|
+
if (jobValid['name'] !== undefined) {
|
|
33
|
+
isValid = isValid && jobValid['name'];
|
|
34
|
+
}
|
|
35
|
+
return isValid && (jobValid['authUsername'] === undefined || jobValid['authUsername']);
|
|
31
36
|
};
|
|
32
37
|
exports.getFormValidation = getFormValidation;
|
|
33
38
|
var cloneValue = function (item) {
|