aldehyde 0.1.72 → 0.1.74
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/lib/chart/antd/Max2DimLineChart.d.ts.map +1 -1
- package/lib/chart/antd/Max2DimLineChart.js +3 -3
- package/lib/chart/antd/Max2DimLineChart.js.map +1 -1
- package/lib/chart/antd/chart-utils.js +1 -1
- package/lib/chart/antd/chart-utils.js.map +1 -1
- package/lib/chart/antd/statview-d2-chart.js +2 -2
- package/lib/chart/antd/statview-d2-chart.js.map +1 -1
- package/lib/controls/action/utils.js +1 -1
- package/lib/controls/action/utils.js.map +1 -1
- package/lib/controls/cascader/index.js +2 -2
- package/lib/controls/cascader/index.js.map +1 -1
- package/lib/controls/chemstruc/graph.js +2 -2
- package/lib/controls/chemstruc/graph.js.map +1 -1
- package/lib/controls/cquery/cquick-button.js +1 -1
- package/lib/controls/cquery/cquick-button.js.map +1 -1
- package/lib/controls/entity-select/entity-select.d.ts +1 -1
- package/lib/controls/entity-select/entity-select.d.ts.map +1 -1
- package/lib/controls/entity-select/entity-select.js +20 -7
- package/lib/controls/entity-select/entity-select.js.map +1 -1
- package/lib/controls/entity-select/lab-tree-select.js +5 -5
- package/lib/controls/entity-select/lab-tree-select.js.map +1 -1
- package/lib/controls/entity-select/popover-entity-select.js +1 -1
- package/lib/controls/entity-select/popover-entity-select.js.map +1 -1
- package/lib/controls/html-editor/draft.js +2 -2
- package/lib/controls/html-editor/draft.js.map +1 -1
- package/lib/controls/html-editor/tinymce.d.ts.map +1 -1
- package/lib/controls/html-editor/tinymce.js +2 -2
- package/lib/controls/html-editor/tinymce.js.map +1 -1
- package/lib/controls/input-number/index.js +2 -2
- package/lib/controls/input-number/index.js.map +1 -1
- package/lib/controls/signature/index.js +2 -2
- package/lib/controls/signature/index.js.map +1 -1
- package/lib/custom-page/custom-page-router.js +2 -2
- package/lib/custom-page/custom-page-router.js.map +1 -1
- package/lib/detail/button/submit-button-bar.js +1 -1
- package/lib/detail/button/submit-button-bar.js.map +1 -1
- package/lib/detail/edit/dtmpl-edit-card.js +2 -2
- package/lib/detail/edit/dtmpl-edit-card.js.map +1 -1
- package/lib/detail/edit/dtmpl-edit-page.js +2 -2
- package/lib/detail/edit/dtmpl-edit-page.js.map +1 -1
- package/lib/detail/edit/dtmpl-edit.js +4 -4
- package/lib/detail/edit/dtmpl-edit.js.map +1 -1
- package/lib/detail/view/modal-dtmpl-view.js +1 -1
- package/lib/detail/view/modal-dtmpl-view.js.map +1 -1
- package/lib/form/dtmpl-form.d.ts.map +1 -1
- package/lib/form/dtmpl-form.js +8 -14
- package/lib/form/dtmpl-form.js.map +1 -1
- package/lib/form/form-Item-group.d.ts +1 -1
- package/lib/form/form-Item-group.d.ts.map +1 -1
- package/lib/form/form-Item-group.js +3 -1
- package/lib/form/form-Item-group.js.map +1 -1
- package/lib/layout/MainPage.js +1 -1
- package/lib/layout/MainPage.js.map +1 -1
- package/lib/layout/menu/l2menu-quick-bar.js +1 -1
- package/lib/layout/menu/l2menu-quick-bar.js.map +1 -1
- package/lib/layout/menu/reset-password.js +1 -1
- package/lib/layout/menu/reset-password.js.map +1 -1
- package/lib/routable/dtmpl-route.js +2 -2
- package/lib/routable/dtmpl-route.js.map +1 -1
- package/lib/routable/ltmpl-route.js +2 -2
- package/lib/routable/ltmpl-route.js.map +1 -1
- package/lib/table/act-table.js +5 -5
- package/lib/table/act-table.js.map +1 -1
- package/lib/table/column/column-selector.js +2 -2
- package/lib/table/column/column-selector.js.map +1 -1
- package/lib/table/modal-select-table.js +1 -1
- package/lib/table/modal-select-table.js.map +1 -1
- package/lib/table/query-table.js +4 -4
- package/lib/table/query-table.js.map +1 -1
- package/lib/table/relation-table.js +4 -4
- package/lib/table/relation-table.js.map +1 -1
- package/lib/table/select-table.js +1 -1
- package/lib/table/select-table.js.map +1 -1
- package/lib/tmpl/hc-data-source.js +2 -2
- package/lib/tmpl/hc-data-source.js.map +1 -1
- package/lib/tmpl/hcservice-v3.js +7 -7
- package/lib/tmpl/hcservice-v3.js.map +1 -1
- package/lib/tmpl/interface.d.ts +4 -2
- package/lib/tmpl/interface.d.ts.map +1 -1
- package/lib/tmpl/interface.js.map +1 -1
- package/lib/tmpl/superagent.js +1 -1
- package/lib/tmpl/superagent.js.map +1 -1
- package/lib/units/index.js +3 -3
- package/lib/units/index.js.map +1 -1
- package/lib/welcome/quick-entrance.js +1 -1
- package/lib/welcome/quick-entrance.js.map +1 -1
- package/package.json +1 -1
- package/src/aldehyde/chart/antd/Max2DimLineChart.js +3 -4
- package/src/aldehyde/chart/antd/chart-utils.tsx +1 -1
- package/src/aldehyde/chart/antd/statview-d2-chart.tsx +2 -2
- package/src/aldehyde/controls/action/utils.tsx +1 -1
- package/src/aldehyde/controls/cascader/index.tsx +2 -2
- package/src/aldehyde/controls/chemstruc/graph.tsx +2 -2
- package/src/aldehyde/controls/cquery/cquick-button.tsx +1 -1
- package/src/aldehyde/controls/entity-select/entity-select.tsx +21 -10
- package/src/aldehyde/controls/entity-select/lab-tree-select.tsx +5 -5
- package/src/aldehyde/controls/entity-select/popover-entity-select.tsx +1 -1
- package/src/aldehyde/controls/html-editor/draft.tsx +2 -2
- package/src/aldehyde/controls/html-editor/tinymce.js +2 -2
- package/src/aldehyde/controls/input-number/index.tsx +2 -2
- package/src/aldehyde/controls/signature/index.tsx +2 -2
- package/src/aldehyde/custom-page/custom-page-router.tsx +2 -2
- package/src/aldehyde/detail/button/submit-button-bar.tsx +1 -1
- package/src/aldehyde/detail/edit/dtmpl-edit-card.tsx +2 -2
- package/src/aldehyde/detail/edit/dtmpl-edit-page.tsx +2 -2
- package/src/aldehyde/detail/edit/dtmpl-edit.tsx +4 -4
- package/src/aldehyde/detail/view/modal-dtmpl-view.tsx +1 -1
- package/src/aldehyde/form/dtmpl-form.tsx +11 -14
- package/src/aldehyde/form/form-Item-group.tsx +3 -1
- package/src/aldehyde/layout/MainPage.tsx +1 -1
- package/src/aldehyde/layout/menu/l2menu-quick-bar.tsx +1 -1
- package/src/aldehyde/layout/menu/reset-password.tsx +1 -1
- package/src/aldehyde/routable/dtmpl-route.tsx +2 -2
- package/src/aldehyde/routable/ltmpl-route.tsx +2 -2
- package/src/aldehyde/table/act-table.tsx +5 -5
- package/src/aldehyde/table/column/column-selector.tsx +2 -2
- package/src/aldehyde/table/modal-select-table.tsx +1 -1
- package/src/aldehyde/table/query-table.tsx +4 -4
- package/src/aldehyde/table/relation-table.tsx +4 -4
- package/src/aldehyde/table/select-table.tsx +1 -1
- package/src/aldehyde/tmpl/hc-data-source.tsx +2 -2
- package/src/aldehyde/tmpl/hcservice-v3.tsx +7 -7
- package/src/aldehyde/tmpl/interface.tsx +4 -2
- package/src/aldehyde/tmpl/superagent.js +1 -1
- package/src/aldehyde/units/index.tsx +3 -3
- package/src/aldehyde/welcome/quick-entrance.tsx +1 -1
|
@@ -41,7 +41,7 @@ export default class Draft extends React.PureComponent<DraftProps, DraftState>{
|
|
|
41
41
|
}
|
|
42
42
|
|
|
43
43
|
editorChange = value => {
|
|
44
|
-
console.log('html:',draftToHtml(value))
|
|
44
|
+
//console.log('html:',draftToHtml(value))
|
|
45
45
|
if (this.props.onChange) {
|
|
46
46
|
this.props.onChange(draftToHtml(value));
|
|
47
47
|
}
|
|
@@ -65,7 +65,7 @@ export default class Draft extends React.PureComponent<DraftProps, DraftState>{
|
|
|
65
65
|
const { contentBlocks, entityMap } = blocksFromHtml;
|
|
66
66
|
const contentState = ContentState.createFromBlockArray(contentBlocks, entityMap);
|
|
67
67
|
const editorState = EditorState.createWithContent(contentState);
|
|
68
|
-
console.log("editorState:",editorState)
|
|
68
|
+
//console.log("editorState:",editorState)
|
|
69
69
|
this.setState({
|
|
70
70
|
editorState
|
|
71
71
|
})
|
|
@@ -15,13 +15,13 @@ export default class HtmlEidtor extends React.Component {
|
|
|
15
15
|
}
|
|
16
16
|
|
|
17
17
|
onChange = (content, editor) => {
|
|
18
|
-
console.log('Content was updated:', content);
|
|
18
|
+
//console.log('Content was updated:', content);
|
|
19
19
|
this.setState({
|
|
20
20
|
value: content
|
|
21
21
|
})
|
|
22
22
|
}
|
|
23
23
|
onChange1 = (content, editor) => {
|
|
24
|
-
console.log('Content was updated11:', content);
|
|
24
|
+
//console.log('Content was updated11:', content);
|
|
25
25
|
this.setState({
|
|
26
26
|
value: content
|
|
27
27
|
})
|
|
@@ -12,9 +12,9 @@ const InputNumber: React.FC<InputNumberProps> = (props) => {
|
|
|
12
12
|
const {id,value, itemType, fieldConfig, onChange,style,min,max} = props;
|
|
13
13
|
|
|
14
14
|
let entryControl = undefined;
|
|
15
|
-
|
|
15
|
+
//console.log('form value',value);
|
|
16
16
|
const changeValue = (value) => {
|
|
17
|
-
console.log('input value',value);
|
|
17
|
+
//console.log('input value',value);
|
|
18
18
|
if (onChange) {
|
|
19
19
|
onChange(value);
|
|
20
20
|
}
|
|
@@ -48,7 +48,7 @@ export default class Signature extends React.PureComponent<SignatureProps, Signa
|
|
|
48
48
|
} else {
|
|
49
49
|
file = undefined;
|
|
50
50
|
}
|
|
51
|
-
console.log('file:', file);
|
|
51
|
+
//console.log('file:', file);
|
|
52
52
|
|
|
53
53
|
this.setState({
|
|
54
54
|
trimmedDataURL:file,
|
|
@@ -71,7 +71,7 @@ export default class Signature extends React.PureComponent<SignatureProps, Signa
|
|
|
71
71
|
// type: 'image/png'
|
|
72
72
|
// });
|
|
73
73
|
|
|
74
|
-
console.log('DataURL value:', value);
|
|
74
|
+
//console.log('DataURL value:', value);
|
|
75
75
|
// let data = this.signCanvas.toData();
|
|
76
76
|
// console.log('data data:', value);
|
|
77
77
|
this.triggerChange(value);
|
|
@@ -54,7 +54,7 @@ export interface CustomPageRouterStat {
|
|
|
54
54
|
|
|
55
55
|
getMenuId=()=>{
|
|
56
56
|
const {location} = this.props;
|
|
57
|
-
console.log("this.props.match.params",this.props);
|
|
57
|
+
//console.log("this.props.match.params",this.props);
|
|
58
58
|
var searchParams = new URLSearchParams( location.search);
|
|
59
59
|
let menuId = searchParams.get('menuId');
|
|
60
60
|
return menuId;
|
|
@@ -66,7 +66,7 @@ export interface CustomPageRouterStat {
|
|
|
66
66
|
let search = this.props.location.search;
|
|
67
67
|
let criteriaData = Units.transQueryStrToParams(search);
|
|
68
68
|
let Page = ProgramConfig.getCustomPage("/" + pageName) || DefCustomPage;
|
|
69
|
-
console.log("CustomPageRouter",{...this.props.match.params, ...criteriaData});
|
|
69
|
+
//console.log("CustomPageRouter",{...this.props.match.params, ...criteriaData});
|
|
70
70
|
return React.createElement(Page, {...this.props.match.params,goBack:this.goBackToLtmpl, ...criteriaData});
|
|
71
71
|
}
|
|
72
72
|
}
|
|
@@ -67,7 +67,7 @@ class SubmitButtonBar extends React.PureComponent<SubmitButtonProps, SubmitButto
|
|
|
67
67
|
const {buttons, actions} = dtmplConfig;
|
|
68
68
|
const cardList: TmplBase[] = [];
|
|
69
69
|
|
|
70
|
-
console.log(" submit-button-bar serial:",serial);
|
|
70
|
+
//console.log(" submit-button-bar serial:",serial);
|
|
71
71
|
// console.log(" submit-button-bar stateSerial:",stateSerial);
|
|
72
72
|
|
|
73
73
|
if (dtmplConfig.premises && dtmplConfig.premises.length > 0) {
|
|
@@ -26,7 +26,7 @@ export default class DtmplEditCard extends React.PureComponent<DtmplEditCardProp
|
|
|
26
26
|
autoSaveTimer = -1000000000000000;
|
|
27
27
|
autoSaveInterval=undefined;
|
|
28
28
|
onClickBody = (e) => {
|
|
29
|
-
console.log("点击了我" + this.autoSaveTimer);
|
|
29
|
+
//console.log("点击了我" + this.autoSaveTimer);
|
|
30
30
|
this.autoSaveTimer = 0;
|
|
31
31
|
}
|
|
32
32
|
static defaultProps = {
|
|
@@ -80,7 +80,7 @@ export default class DtmplEditCard extends React.PureComponent<DtmplEditCardProp
|
|
|
80
80
|
}
|
|
81
81
|
this.autoSaveInterval = setInterval(() => {
|
|
82
82
|
if(this.autoSaveTimer>=dtmplConfig.authSaveInterval){
|
|
83
|
-
|
|
83
|
+
// console.log('执行自动保存');
|
|
84
84
|
this.autoSaveTimer=-1000000000000000;
|
|
85
85
|
this.doSubmit(undefined);
|
|
86
86
|
}else{
|
|
@@ -31,7 +31,7 @@ export default class DtmplEditPage extends React.PureComponent<ModalEditorProps,
|
|
|
31
31
|
autoSaveInterval=undefined;
|
|
32
32
|
onClickBody = (e) => {
|
|
33
33
|
// console.log(e);
|
|
34
|
-
console.log("点击了我" + this.autoSaveTimer);
|
|
34
|
+
//console.log("点击了我" + this.autoSaveTimer);
|
|
35
35
|
this.autoSaveTimer = 0;
|
|
36
36
|
}
|
|
37
37
|
static defaultProps = {
|
|
@@ -98,7 +98,7 @@ export default class DtmplEditPage extends React.PureComponent<ModalEditorProps,
|
|
|
98
98
|
}
|
|
99
99
|
this.autoSaveInterval = setInterval(() => {
|
|
100
100
|
if(this.autoSaveTimer>=dtmplConfig.authSaveInterval){
|
|
101
|
-
console.log('执行自动保存');
|
|
101
|
+
//console.log('执行自动保存');
|
|
102
102
|
this.autoSaveTimer=-1000000000000000;
|
|
103
103
|
this.doSubmit(undefined);
|
|
104
104
|
}else{
|
|
@@ -58,7 +58,7 @@ export default class DtmplEdit extends React.PureComponent<DtmplEditProps, Dtmpl
|
|
|
58
58
|
|
|
59
59
|
onClickBody = (e) => {
|
|
60
60
|
// console.log(e);
|
|
61
|
-
console.log("点击了我" + this.autoSaveTimer);
|
|
61
|
+
//console.log("点击了我" + this.autoSaveTimer);
|
|
62
62
|
this.autoSaveTimer = 0;
|
|
63
63
|
}
|
|
64
64
|
|
|
@@ -86,7 +86,7 @@ export default class DtmplEdit extends React.PureComponent<DtmplEditProps, Dtmpl
|
|
|
86
86
|
}
|
|
87
87
|
this.autoSaveInterval = setInterval(() => {
|
|
88
88
|
if(this.autoSaveTimer>=dtmplConfig.authSaveInterval){
|
|
89
|
-
console.log('执行自动保存');
|
|
89
|
+
//console.log('执行自动保存');
|
|
90
90
|
this.autoSaveTimer=-1000000000000000;
|
|
91
91
|
this.doSubmit(undefined);
|
|
92
92
|
}else{
|
|
@@ -146,7 +146,7 @@ export default class DtmplEdit extends React.PureComponent<DtmplEditProps, Dtmpl
|
|
|
146
146
|
}
|
|
147
147
|
|
|
148
148
|
onFinish = (currentCode:string) => {
|
|
149
|
-
|
|
149
|
+
// console.log("提交返回的Code:", currentCode);
|
|
150
150
|
this.newCode=currentCode;
|
|
151
151
|
//默认返回到列表页面
|
|
152
152
|
const {dtmplConfig} = this.state;
|
|
@@ -192,7 +192,7 @@ export default class DtmplEdit extends React.PureComponent<DtmplEditProps, Dtmpl
|
|
|
192
192
|
|
|
193
193
|
render() {
|
|
194
194
|
const {dtmplConfig, showPostResult,loading,id,serial,dtmplData} = this.state;
|
|
195
|
-
console.log(" dtmpl edit serial:",serial);
|
|
195
|
+
//console.log(" dtmpl edit serial:",serial);
|
|
196
196
|
const { sourceId, showRightNav, code,addOrUpdate,maxColsOnRow,mainCode} = this.props;
|
|
197
197
|
//const {title} = dtmplConfig;
|
|
198
198
|
if (!dtmplConfig) {
|
|
@@ -34,7 +34,7 @@ export default class ModalDtmplView extends React.PureComponent<ModalDtmplViewPr
|
|
|
34
34
|
render() {
|
|
35
35
|
// console.log('antdModalProps:',this.antdModalProps);
|
|
36
36
|
const {height,onOk,onCancel,code,style,sourceId,visible} = this.props
|
|
37
|
-
console.log('antdModalProps code :',code);
|
|
37
|
+
//console.log('antdModalProps code :',code);
|
|
38
38
|
//const {code} = this.state;
|
|
39
39
|
return <Modal
|
|
40
40
|
visible={visible}
|
|
@@ -76,7 +76,7 @@ export default class DtmplForm extends React.PureComponent<DtmplFormProps, Dtmpl
|
|
|
76
76
|
})
|
|
77
77
|
}
|
|
78
78
|
//debounce(formRef.current.resetFields();, 500);
|
|
79
|
-
setTimeout(()=>formRef.current.resetFields(),200)
|
|
79
|
+
setTimeout(()=>formRef.current?formRef.current.resetFields():undefined,200)
|
|
80
80
|
}
|
|
81
81
|
|
|
82
82
|
doRefresh = async () => {
|
|
@@ -122,7 +122,7 @@ export default class DtmplForm extends React.PureComponent<DtmplFormProps, Dtmpl
|
|
|
122
122
|
onSubmit = async (values: any) => {
|
|
123
123
|
const {showConfirm, code, dtmplConfig} = this.props;
|
|
124
124
|
const {dtmplData} = this.state;
|
|
125
|
-
console.log("from value:",values);
|
|
125
|
+
// console.log("from value:",values);
|
|
126
126
|
let resultCode = undefined;
|
|
127
127
|
const result = values;
|
|
128
128
|
for (let group of dtmplConfig.groups) {
|
|
@@ -196,18 +196,15 @@ export default class DtmplForm extends React.PureComponent<DtmplFormProps, Dtmpl
|
|
|
196
196
|
}
|
|
197
197
|
|
|
198
198
|
onValuesChange=(changedValues, allValues)=>{
|
|
199
|
-
const {dtmplConfig,onValuesChange} = this.props;
|
|
199
|
+
const {dtmplConfig,onValuesChange,formRef} = this.props;
|
|
200
200
|
const {dtmplData}=this.state;
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
// dtmplData:{...dtmplData}
|
|
209
|
-
// })
|
|
210
|
-
// }
|
|
201
|
+
|
|
202
|
+
let appDtmplConfig=ProgramConfig.getAppDtmplConfig(dtmplConfig,dtmplData);
|
|
203
|
+
|
|
204
|
+
if(appDtmplConfig.onValuesChange){//自定义值修改逻辑
|
|
205
|
+
appDtmplConfig.onValuesChange(changedValues,allValues,formRef.current);
|
|
206
|
+
}
|
|
207
|
+
|
|
211
208
|
onValuesChange();
|
|
212
209
|
}
|
|
213
210
|
// nameValue = AntdForm.useWatch(this.props.dtmplConfig.groups[0].fields[0].id, this.props.formRef.current);
|
|
@@ -215,7 +212,7 @@ export default class DtmplForm extends React.PureComponent<DtmplFormProps, Dtmpl
|
|
|
215
212
|
const {formRef,dtmplConfig,sourceId, code,parentId,showHeader} = this.props;
|
|
216
213
|
const {loading,dtmplData}=this.state;
|
|
217
214
|
if(!dtmplConfig){
|
|
218
|
-
return <Card loading={
|
|
215
|
+
return <Card loading={true}>
|
|
219
216
|
加载中... ...
|
|
220
217
|
</Card>
|
|
221
218
|
}
|
|
@@ -61,9 +61,11 @@ export default class FormItemGroup extends React.PureComponent<FieldGroupProps,
|
|
|
61
61
|
|
|
62
62
|
getFieldConfig = (item: FieldConfig) => {
|
|
63
63
|
const {formRef} = this.props;
|
|
64
|
-
let fieldConfig;
|
|
64
|
+
let fieldConfig=item;
|
|
65
65
|
if (item.updateSelf) {
|
|
66
|
+
//item.value=formRef.current?formRef.current.getFieldValue(item.id):item.defaultValue;
|
|
66
67
|
fieldConfig = item.updateSelf(formRef.current);
|
|
68
|
+
//formRef.current.setFieldValue(item.id,fieldConfig.value);
|
|
67
69
|
} else {
|
|
68
70
|
fieldConfig = item;
|
|
69
71
|
}
|
|
@@ -38,7 +38,7 @@ class MainPage extends React.PureComponent<MainPageProps, MainPageState> {
|
|
|
38
38
|
|
|
39
39
|
async componentDidMount() {
|
|
40
40
|
var currentURL = new URL(window.location.href);
|
|
41
|
-
console.log('main page currentURL:',currentURL);
|
|
41
|
+
//console.log('main page currentURL:',currentURL);
|
|
42
42
|
const search = window.location.href.split("?")[1];
|
|
43
43
|
var searchParams = new URLSearchParams('?' + search);
|
|
44
44
|
let blockId = searchParams.get('blockId');
|
|
@@ -48,7 +48,7 @@ class L2MenuQuickBar extends React.PureComponent<L2MenuQuickBarProps, L2MenuQuic
|
|
|
48
48
|
});
|
|
49
49
|
}
|
|
50
50
|
showDraw=(currentId:string)=>{
|
|
51
|
-
console.log("点击了L2MenuQuickBar",currentId);
|
|
51
|
+
// console.log("点击了L2MenuQuickBar",currentId);
|
|
52
52
|
this.setState({
|
|
53
53
|
currentId,
|
|
54
54
|
showDraw:true
|
|
@@ -68,7 +68,7 @@ class ResetPassword extends React.PureComponent<ResetPasswordProps, ResetPasswor
|
|
|
68
68
|
|
|
69
69
|
handleBlurCapture=()=>{
|
|
70
70
|
//判断新密码和确认密码相同
|
|
71
|
-
|
|
71
|
+
//console.log("this.formRef.current.getFieldValue('newPassword')",this.formRef.current.getFieldValue('newPassword')) ;
|
|
72
72
|
let newPassword= this.formRef.current.getFieldValue('newPassword');
|
|
73
73
|
let reNewPassword= this.formRef.current.getFieldValue('reNewPassword');
|
|
74
74
|
if(newPassword && reNewPassword && newPassword!=reNewPassword){
|
|
@@ -45,7 +45,7 @@ class DtmplRoute extends React.PureComponent<DtmplRouteProps, DtmplRoutePropsSta
|
|
|
45
45
|
|
|
46
46
|
getMenuId=()=>{
|
|
47
47
|
const {location} = this.props;
|
|
48
|
-
console.log("this.props.match.params",this.props);
|
|
48
|
+
//console.log("this.props.match.params",this.props);
|
|
49
49
|
var searchParams = new URLSearchParams( location.search);
|
|
50
50
|
let menuId = searchParams.get('menuId');
|
|
51
51
|
return menuId;
|
|
@@ -119,7 +119,7 @@ class DtmplRoute extends React.PureComponent<DtmplRouteProps, DtmplRoutePropsSta
|
|
|
119
119
|
const {location,match}=this.props;
|
|
120
120
|
const {sourceId,} = match.params;
|
|
121
121
|
const {codeSource}=this.state;
|
|
122
|
-
console.log("this.props.match.params",match);
|
|
122
|
+
//console.log("this.props.match.params",match);
|
|
123
123
|
if(!location){
|
|
124
124
|
return <></>;
|
|
125
125
|
}
|
|
@@ -33,7 +33,7 @@ class LtmplRoute extends React.PureComponent<LtmplRouteProps, LtmplRouteState> {
|
|
|
33
33
|
|
|
34
34
|
getMenuId=()=>{
|
|
35
35
|
const {location} = this.props;
|
|
36
|
-
console.log("this.props.match.params",this.props);
|
|
36
|
+
//console.log("this.props.match.params",this.props);
|
|
37
37
|
var searchParams = new URLSearchParams( location.search);
|
|
38
38
|
let menuId = searchParams.get('menuId');
|
|
39
39
|
return menuId;
|
|
@@ -43,7 +43,7 @@ class LtmplRoute extends React.PureComponent<LtmplRouteProps, LtmplRouteState> {
|
|
|
43
43
|
const {location} = this.props;
|
|
44
44
|
const { sourceId} = this.props.match.params;
|
|
45
45
|
let criteriaData = Units.transQueryStrToParams(this.props.location.search);
|
|
46
|
-
console.log('acttable location search:', this.props.location.search);
|
|
46
|
+
//console.log('acttable location search:', this.props.location.search);
|
|
47
47
|
let ltmplConfigRes = await HCDataSource.requestLtmplConfig(sourceId);
|
|
48
48
|
this.setState({
|
|
49
49
|
ltmplConfigRes,
|
|
@@ -312,7 +312,7 @@ class ActTable extends React.PureComponent<ActTableProps, ActTableStat> {
|
|
|
312
312
|
}) : ""}
|
|
313
313
|
{ltmplConfig.rowCQuerys && ltmplConfig.rowCQuerys.length > 0 ?
|
|
314
314
|
ltmplConfig.rowCQuerys.map((cquery) => {
|
|
315
|
-
console.log("record record", record);
|
|
315
|
+
// console.log("record record", record);
|
|
316
316
|
return <CquickButton key={cquery.id} size={"small"} pageType={'drawer'}
|
|
317
317
|
// onClick={() => doCQuery(cquery.id)}
|
|
318
318
|
cQueryConfig={cquery}
|
|
@@ -360,9 +360,9 @@ class ActTable extends React.PureComponent<ActTableProps, ActTableStat> {
|
|
|
360
360
|
|
|
361
361
|
let {hiddenColIds, sortedColConfigs} = this.state;
|
|
362
362
|
|
|
363
|
-
console.log("UnitscriteriaData)", Units.transQueryParamsToStr(criteriaData));
|
|
364
|
-
console.log("preCriteriaData)", Units.transQueryParamsToStr(preCriteriaData));
|
|
365
|
-
console.log("preCriteriaData) bool", Units.transQueryParamsToStr(preCriteriaData) == Units.transQueryParamsToStr(criteriaData));
|
|
363
|
+
// console.log("UnitscriteriaData)", Units.transQueryParamsToStr(criteriaData));
|
|
364
|
+
// console.log("preCriteriaData)", Units.transQueryParamsToStr(preCriteriaData));
|
|
365
|
+
// console.log("preCriteriaData) bool", Units.transQueryParamsToStr(preCriteriaData) == Units.transQueryParamsToStr(criteriaData));
|
|
366
366
|
if (ltmplConfig && (!preLtmplConfig || ltmplConfig.id != preLtmplConfig.id) || (Units.transQueryParamsToStr(criteriaData) != Units.transQueryParamsToStr(preCriteriaData))) {
|
|
367
367
|
|
|
368
368
|
if (ltmplConfig.id == preLtmplConfig.id) {
|
|
@@ -497,7 +497,7 @@ class ActTable extends React.PureComponent<ActTableProps, ActTableStat> {
|
|
|
497
497
|
if (result.status === "success") {
|
|
498
498
|
let hydrocarbonToken = Units.getLocalStorge("hydrocarbonToken");
|
|
499
499
|
let url = result.url + "hydrocarbon_token=" + Units.getLocalStorge("hydrocarbonToken");
|
|
500
|
-
console.log(url);
|
|
500
|
+
// console.log(url);
|
|
501
501
|
window.open(url);
|
|
502
502
|
}
|
|
503
503
|
}
|
|
@@ -53,7 +53,7 @@ class ColumnSelector extends React.PureComponent<ColumnSelectorProps, ColumnSele
|
|
|
53
53
|
|
|
54
54
|
onChange = (checkedValues) => {
|
|
55
55
|
const {onChangeHiddenCols, columns, ignoredColIds} = this.props;
|
|
56
|
-
console.log('checked = ', checkedValues);
|
|
56
|
+
//console.log('checked = ', checkedValues);
|
|
57
57
|
const hiddenColIds = [];
|
|
58
58
|
for (let c of columns) {
|
|
59
59
|
if (checkedValues.length != 0 && !checkedValues.includes(c.id) && !ignoredColIds.includes(c.id)) {
|
|
@@ -68,7 +68,7 @@ class ColumnSelector extends React.PureComponent<ColumnSelectorProps, ColumnSele
|
|
|
68
68
|
const newData = arrayMoveImmutable([].concat(columns), oldIndex, newIndex).filter(
|
|
69
69
|
el => !!el,
|
|
70
70
|
);
|
|
71
|
-
console.log('Sorted items: ', newData);
|
|
71
|
+
//console.log('Sorted items: ', newData);
|
|
72
72
|
onChangeColSort(newData);
|
|
73
73
|
}
|
|
74
74
|
};
|
|
@@ -157,7 +157,7 @@ class ModelSelectTable extends React.PureComponent<ModelSelectTableProps, ModelS
|
|
|
157
157
|
}
|
|
158
158
|
|
|
159
159
|
changeRowSelection = (selectedRows_: SelectedRow[],selectedDatas?:DtmplData[], allRowKeys?: string[]) => {
|
|
160
|
-
console.log('changeRowSelection:', allRowKeys);
|
|
160
|
+
//console.log('changeRowSelection:', allRowKeys);
|
|
161
161
|
let {maxSelectedRows} = this.props;
|
|
162
162
|
if (allRowKeys) {
|
|
163
163
|
const {selectedRows} = this.state;
|
|
@@ -123,7 +123,7 @@ class QueryTable extends React.PureComponent<QueryTableProps, QueryTableStat> {
|
|
|
123
123
|
const newData = arrayMoveImmutable([].concat(dataSource), oldIndex, newIndex).filter(
|
|
124
124
|
el => !!el,
|
|
125
125
|
);
|
|
126
|
-
console.log('Sorted items: ', newData);
|
|
126
|
+
//console.log('Sorted items: ', newData);
|
|
127
127
|
this.setState({dataSource: newData});
|
|
128
128
|
}
|
|
129
129
|
};
|
|
@@ -215,8 +215,8 @@ class QueryTable extends React.PureComponent<QueryTableProps, QueryTableStat> {
|
|
|
215
215
|
type: maxSelectedRows == 1 ? 'radio' : 'checkbox',
|
|
216
216
|
selectedRowKeys,
|
|
217
217
|
onChange: (selectedRowKeys, selectedRows) => {
|
|
218
|
-
console.log('selectedRowKeys:', selectedRowKeys);
|
|
219
|
-
console.log('selectedRows:', selectedRows);
|
|
218
|
+
//console.log('selectedRowKeys:', selectedRowKeys);
|
|
219
|
+
// console.log('selectedRows:', selectedRows);
|
|
220
220
|
let selectedRows_: SelectedRow[] = [];
|
|
221
221
|
let selectedDatas: DtmplData[] = [];
|
|
222
222
|
let titleColId = null;
|
|
@@ -255,7 +255,7 @@ class QueryTable extends React.PureComponent<QueryTableProps, QueryTableStat> {
|
|
|
255
255
|
}
|
|
256
256
|
|
|
257
257
|
initViewList = (data) => {
|
|
258
|
-
console.log("data:",data);
|
|
258
|
+
//console.log("data:",data);
|
|
259
259
|
const {columns, columnConfigs} = this.props
|
|
260
260
|
const formItemList = [];
|
|
261
261
|
if (columnConfigs.length > 0) {
|
|
@@ -262,7 +262,7 @@ class RelationTable extends React.PureComponent<RelationTableProps, RelationTabl
|
|
|
262
262
|
}
|
|
263
263
|
|
|
264
264
|
showEntityView = (record) => {
|
|
265
|
-
console.log('tabel record:', record);
|
|
265
|
+
//console.log('tabel record:', record);
|
|
266
266
|
this.setState({
|
|
267
267
|
selectedCode: record.code,
|
|
268
268
|
showDtmplView: true,
|
|
@@ -305,7 +305,7 @@ class RelationTable extends React.PureComponent<RelationTableProps, RelationTabl
|
|
|
305
305
|
}
|
|
306
306
|
|
|
307
307
|
tabChange = (pagination) => {
|
|
308
|
-
console.log('pagination',pagination);
|
|
308
|
+
//console.log('pagination',pagination);
|
|
309
309
|
this.setState({
|
|
310
310
|
pageSize:pagination.pageSize,
|
|
311
311
|
})
|
|
@@ -313,7 +313,7 @@ class RelationTable extends React.PureComponent<RelationTableProps, RelationTabl
|
|
|
313
313
|
}
|
|
314
314
|
|
|
315
315
|
showSelect = () => {
|
|
316
|
-
console.log('showSelectTable click');
|
|
316
|
+
//console.log('showSelectTable click');
|
|
317
317
|
this.setState({
|
|
318
318
|
showSelectTable: true,
|
|
319
319
|
})
|
|
@@ -426,7 +426,7 @@ class RelationTable extends React.PureComponent<RelationTableProps, RelationTabl
|
|
|
426
426
|
}
|
|
427
427
|
onChange(fieldGroupConfig, datas);
|
|
428
428
|
|
|
429
|
-
console.log("handleRowEdit data:",datas);
|
|
429
|
+
//console.log("handleRowEdit data:",datas);
|
|
430
430
|
|
|
431
431
|
if (isAdd) {
|
|
432
432
|
message.success('已添加');
|
|
@@ -154,7 +154,7 @@ class SelectTable extends React.PureComponent<SelectTableProps, SelectTableStat>
|
|
|
154
154
|
// }
|
|
155
155
|
|
|
156
156
|
changeRowSelection = (selectedRows_: SelectedRow[], selectedDatas_: DtmplData[], allRowKeys?: string[]) => {
|
|
157
|
-
console.log('changeRowSelection:', allRowKeys);
|
|
157
|
+
//console.log('changeRowSelection:', allRowKeys);
|
|
158
158
|
let selectedRows_new: SelectedRow[];
|
|
159
159
|
let selectedDatas_new: DtmplData[] = [];
|
|
160
160
|
const {selectedRows, selectedDatas, onChange, maxSelectedRows} = this.props;
|
|
@@ -303,13 +303,13 @@ HCDataSource.clear =async function (roles:string[]) {
|
|
|
303
303
|
|
|
304
304
|
HCDataSource.cache=function (data:DtmplData){
|
|
305
305
|
if(data){
|
|
306
|
-
console.log('put----',data);
|
|
306
|
+
// console.log('put----',data);
|
|
307
307
|
objctCacheMap.set(data.code,data)
|
|
308
308
|
}
|
|
309
309
|
};
|
|
310
310
|
|
|
311
311
|
HCDataSource.getFromCache=function (code:string){
|
|
312
|
-
console.log('objctCacheMap',objctCacheMap);
|
|
312
|
+
//console.log('objctCacheMap',objctCacheMap);
|
|
313
313
|
return objctCacheMap.get(code);
|
|
314
314
|
}
|
|
315
315
|
|
|
@@ -127,7 +127,7 @@ export default class HcserviceV3 {
|
|
|
127
127
|
}
|
|
128
128
|
|
|
129
129
|
static async requestLtmplQueryKey(sourceId, condition?) {
|
|
130
|
-
console.log('condition:',condition);
|
|
130
|
+
//console.log('condition:',condition);
|
|
131
131
|
let url = `/v3/ltmpl/query/key`
|
|
132
132
|
let res = await Super.super({
|
|
133
133
|
url: url,
|
|
@@ -138,13 +138,13 @@ export default class HcserviceV3 {
|
|
|
138
138
|
}
|
|
139
139
|
|
|
140
140
|
static async requestLtmplQueryTop(sourceId, condition) {
|
|
141
|
-
|
|
141
|
+
// console.log('condition:',condition);
|
|
142
142
|
let url = `/v3/ltmpl/top-data`
|
|
143
143
|
return await this.requestCommonLtmplQueryTop(sourceId,condition,url);
|
|
144
144
|
}
|
|
145
145
|
|
|
146
146
|
static async requestMstrucLtmplQueryTop(sourceId, condition) {
|
|
147
|
-
console.log('condition:',condition);
|
|
147
|
+
//console.log('condition:',condition);
|
|
148
148
|
let url = `/v3/mstruc/ltmpl/top-data`
|
|
149
149
|
return await this.requestCommonLtmplQueryTop(sourceId,condition,url);
|
|
150
150
|
}
|
|
@@ -419,7 +419,7 @@ export default class HcserviceV3 {
|
|
|
419
419
|
return true;
|
|
420
420
|
}else{
|
|
421
421
|
message.error("删除失败");
|
|
422
|
-
console.log("删除失败消息",res.message);
|
|
422
|
+
//console.log("删除失败消息",res.message);
|
|
423
423
|
return false;
|
|
424
424
|
}
|
|
425
425
|
}
|
|
@@ -659,7 +659,7 @@ export default class HcserviceV3 {
|
|
|
659
659
|
pageSize: pageinfo.pageSize
|
|
660
660
|
}
|
|
661
661
|
});
|
|
662
|
-
console.log("ks list:", res);
|
|
662
|
+
//console.log("ks list:", res);
|
|
663
663
|
if(res.status=='error'){
|
|
664
664
|
return null;
|
|
665
665
|
}else{
|
|
@@ -678,7 +678,7 @@ export default class HcserviceV3 {
|
|
|
678
678
|
pageSize,queryKey
|
|
679
679
|
}
|
|
680
680
|
});
|
|
681
|
-
console.log("requestKsListToPage:", res);
|
|
681
|
+
//console.log("requestKsListToPage:", res);
|
|
682
682
|
return res.result;
|
|
683
683
|
}
|
|
684
684
|
|
|
@@ -689,7 +689,7 @@ export default class HcserviceV3 {
|
|
|
689
689
|
depth,
|
|
690
690
|
method: "GET",
|
|
691
691
|
});
|
|
692
|
-
console.log("ks unique:", res);
|
|
692
|
+
//console.log("ks unique:", res);
|
|
693
693
|
return res.result;
|
|
694
694
|
}
|
|
695
695
|
|
|
@@ -28,13 +28,14 @@ export interface FieldBase extends OrderableTmplBase {
|
|
|
28
28
|
colNum?: number;
|
|
29
29
|
mstrucId?: string;
|
|
30
30
|
defaultValue?: string;
|
|
31
|
+
value?:string;
|
|
31
32
|
tip?: string;
|
|
32
33
|
controlType?: string;
|
|
33
34
|
extControlType?: string;
|
|
34
35
|
required?: boolean;
|
|
35
36
|
comparator?:Comparator;
|
|
36
37
|
dependencies?:string[] ;
|
|
37
|
-
shouldUpdate?:(prevValue:object,curValue:object)=> boolean | boolean;
|
|
38
|
+
shouldUpdate?:((prevValue:object,curValue:object)=> boolean) | boolean;
|
|
38
39
|
}
|
|
39
40
|
export interface CQueryConfig extends OrderableTmplBase {
|
|
40
41
|
path?:string,
|
|
@@ -120,6 +121,7 @@ export interface DtmplConfig extends TmplBase {
|
|
|
120
121
|
actions: ActionConfig[];
|
|
121
122
|
premises: FieldConfig[];
|
|
122
123
|
groups: FieldGroupConfig[];
|
|
124
|
+
onValuesChange:(changedValues,allValues,formInstance:FormInstance)=>void
|
|
123
125
|
}
|
|
124
126
|
|
|
125
127
|
export type Comparator = 'equal' | 'unequal' | 'includeOne' | 'exclude' | 'noLess' | 'noGreater';
|
|
@@ -130,7 +132,7 @@ export interface FieldConfig extends FieldBase {
|
|
|
130
132
|
min?: string;
|
|
131
133
|
buttons?: ButtonName[];
|
|
132
134
|
rules?: FileRule[];
|
|
133
|
-
mainCode?:(form:FormInstance)=> Function |string,
|
|
135
|
+
mainCode?:((form:FormInstance)=> Function) |string,
|
|
134
136
|
updateSelf?:(form:FormInstance)=>FieldConfig,
|
|
135
137
|
|
|
136
138
|
}
|
|
@@ -48,7 +48,7 @@ export default class Superagent{
|
|
|
48
48
|
}
|
|
49
49
|
else if(res.status===403){
|
|
50
50
|
//message.info("请求权限不足,可能是token已经超时")
|
|
51
|
-
console.log('权限不足或登录超时',options);
|
|
51
|
+
//console.log('权限不足或登录超时',options);
|
|
52
52
|
window.location.hash="/login";
|
|
53
53
|
}else if(res.status===404||res.status===504){
|
|
54
54
|
message.info("服务器连接失败!")
|
|
@@ -90,10 +90,10 @@ export default {
|
|
|
90
90
|
let appi:string = window.localStorage['hydrocarbonServer'] ? window.localStorage['hydrocarbonServer'] : api;
|
|
91
91
|
if(!appi){
|
|
92
92
|
api=new URL(window.location.href).origin;
|
|
93
|
-
console.log('Hydrcarbon API:',api);
|
|
93
|
+
//console.log('Hydrcarbon API:',api);
|
|
94
94
|
}else if(!appi.startsWith("http")){
|
|
95
95
|
api=this.joinPath(new URL(window.location.href).origin,appi);
|
|
96
|
-
|
|
96
|
+
// console.log('Hydrcarbon API:',api);
|
|
97
97
|
}
|
|
98
98
|
return api;
|
|
99
99
|
},
|
|
@@ -132,7 +132,7 @@ export default {
|
|
|
132
132
|
// return str;
|
|
133
133
|
},
|
|
134
134
|
dateToString(date) { //日期转字符串
|
|
135
|
-
console.log(date)
|
|
135
|
+
//console.log(date)
|
|
136
136
|
let year = date.getFullYear();
|
|
137
137
|
let month = (date.getMonth() + 1).toString();
|
|
138
138
|
let day = (date.getDate()).toString();
|
|
@@ -41,7 +41,7 @@ class QuickEntrance extends React.PureComponent<QuickEntranceProps, QuickEntranc
|
|
|
41
41
|
componentWillUnmount(): void {
|
|
42
42
|
if(this.intervals.length>0){
|
|
43
43
|
for(let i of this.intervals){
|
|
44
|
-
console.log('快捷入口移除定时任务');
|
|
44
|
+
//console.log('快捷入口移除定时任务');
|
|
45
45
|
clearInterval( i);
|
|
46
46
|
}
|
|
47
47
|
}
|