Merge branch 'release/2.17.1.2411.01' into release/2.17.1.2411.01-个税
This commit is contained in:
commit
64b6a23310
|
|
@ -46,29 +46,20 @@ class Index extends Component {
|
||||||
...item, items: _.map(item.items, o => {
|
...item, items: _.map(item.items, o => {
|
||||||
if (getKey(o) === "taxAgentIds") {
|
if (getKey(o) === "taxAgentIds") {
|
||||||
return {
|
return {
|
||||||
...o,
|
...o, viewAttr: !_.isEmpty(detail) ? 1 : 3, label: getLabel(o.lanId, o.label),
|
||||||
viewAttr: !_.isEmpty(detail) ? 1 : 3,
|
|
||||||
label: getLabel(o.lanId, o.label),
|
|
||||||
value: detail[getKey(o)] || "",
|
value: detail[getKey(o)] || "",
|
||||||
options: _.map(taxAgentOption, (o, i) => ({ key: o.id, showname: o.content }))
|
options: _.map(taxAgentOption, (o, i) => ({ key: o.id, showname: o.content }))
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
return {
|
return {
|
||||||
...o,
|
...o, viewAttr: !_.isEmpty(detail) ? 1 : 3, label: getLabel(o.lanId, o.label),
|
||||||
viewAttr: !_.isEmpty(detail) ? 1 : 3,
|
|
||||||
label: getLabel(o.lanId, o.label),
|
|
||||||
value: detail[getKey(o)] || ""
|
value: detail[getKey(o)] || ""
|
||||||
};
|
};
|
||||||
})
|
})
|
||||||
})), {
|
})), {
|
||||||
items: _.map(data, o => ({
|
items: _.map(data, o => ({
|
||||||
conditionType: "INPUT",
|
conditionType: "INPUT", domkey: [String(o.id)], fieldcol: 14, label: o.name, labelcol: 6,
|
||||||
domkey: [String(o.id)],
|
value: detail[`${String(o.id)}_variableItem`] || "", viewAttr: 2, dataType: o.dataType
|
||||||
fieldcol: 14,
|
|
||||||
label: o.name,
|
|
||||||
labelcol: 6,
|
|
||||||
value: detail[`${String(o.id)}_variableItem`] || "",
|
|
||||||
viewAttr: 2
|
|
||||||
})), title: "", col: 2, defaultshow: true
|
})), title: "", col: 2, defaultshow: true
|
||||||
}]
|
}]
|
||||||
}, () => {
|
}, () => {
|
||||||
|
|
@ -76,8 +67,7 @@ class Index extends Component {
|
||||||
if (!_.isEmpty(detail)) {
|
if (!_.isEmpty(detail)) {
|
||||||
VSSalaryFileForm.updateFields({
|
VSSalaryFileForm.updateFields({
|
||||||
employeeId: {
|
employeeId: {
|
||||||
value: detail["employeeId"],
|
value: detail["employeeId"], valueSpan: detail["username"],
|
||||||
valueSpan: detail["username"],
|
|
||||||
valueObj: [{ id: detail["employeeId"], name: detail["username"] }]
|
valueObj: [{ id: detail["employeeId"], name: detail["username"] }]
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
@ -128,6 +118,19 @@ class Index extends Component {
|
||||||
</div>
|
</div>
|
||||||
</div>;
|
</div>;
|
||||||
};
|
};
|
||||||
|
handleChange = (formVal) => {
|
||||||
|
const key = _.keys(formVal)[0], value = formVal[key].value;
|
||||||
|
const [__, fields] = this.state.conditions, { items } = fields;
|
||||||
|
_.forEach(items, o => {
|
||||||
|
if (getKey(o) === key && o.dataType === "number") {
|
||||||
|
if (_.isNaN(Number(value))) {
|
||||||
|
const { baseTableStore: { VSSalaryFileForm } } = this.props;
|
||||||
|
message.warning(getLabel(111, "数值类型有误!"));
|
||||||
|
VSSalaryFileForm.updateFields({ [getKey(o)]: { value: "" } });
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
const { conditions } = this.state;
|
const { conditions } = this.state;
|
||||||
|
|
@ -135,7 +138,8 @@ class Index extends Component {
|
||||||
return (<WeaSlideModal
|
return (<WeaSlideModal
|
||||||
className="variable_salary_file_dialog" {...this.props} direction="right" onClose={() => onClose()}
|
className="variable_salary_file_dialog" {...this.props} direction="right" onClose={() => onClose()}
|
||||||
top={0} width={800} height={100} measureT="%" measureX="px" measureY="%" title={this.renderTitle()}
|
top={0} width={800} height={100} measureT="%" measureX="px" measureY="%" title={this.renderTitle()}
|
||||||
content={<div className="form-dialog-layout">{getSearchs(VSSalaryFileForm, conditions, 2, false)}</div>}
|
content={<div
|
||||||
|
className="form-dialog-layout">{getSearchs(VSSalaryFileForm, conditions, 2, false, this.handleChange)}</div>}
|
||||||
/>);
|
/>);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -43,12 +43,7 @@ export const getSearchs = (form, condition, col, isCenter, onChange = () => void
|
||||||
tipPosition="bottom" // 错误提示的显示位置: top/bottom
|
tipPosition="bottom" // 错误提示的显示位置: top/bottom
|
||||||
className={(fields.domkey[0] === "subcompanyName" || fields.domkey[0] === "departmentName") ? "hideFormItem" : classnames}
|
className={(fields.domkey[0] === "subcompanyName" || fields.domkey[0] === "departmentName") ? "hideFormItem" : classnames}
|
||||||
>
|
>
|
||||||
<WeaSwitch
|
<WeaSwitch fieldConfig={fields} form={form} formParams={formParams} onChange={onChange}/>
|
||||||
fieldConfig={fields}
|
|
||||||
form={form}
|
|
||||||
formParams={formParams}
|
|
||||||
onChange={onChange}
|
|
||||||
/>
|
|
||||||
{
|
{
|
||||||
fields.helpfulTitle &&
|
fields.helpfulTitle &&
|
||||||
<WeaHelpfulTip title={fields.helpfulTitle} style={{ position: "absolute", right: "-20px", top: "25%" }}/>
|
<WeaHelpfulTip title={fields.helpfulTitle} style={{ position: "absolute", right: "-20px", top: "25%" }}/>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue