From 9e81e8244a981aaf99dffd45a874051bd9120fec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Thu, 25 Jan 2024 09:16:57 +0800 Subject: [PATCH 001/127] =?UTF-8?q?feature/2.10.1.2401.01-=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E6=93=8D=E4=BD=9C=E6=97=A5=E5=BF=97=E6=B7=BB=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pc4mobx/hrmSalary/apis/index.js | 18 ++ .../components/logViewModal/config.js | 78 +++++++ .../components/logViewModal/index.js | 207 ++++++++++-------- .../components/logViewModal/index.less | 30 +++ pc4mobx/hrmSalary/pages/salaryItem/index.js | 32 ++- pc4mobx/hrmSalary/stores/baseForm.js | 10 +- 6 files changed, 269 insertions(+), 106 deletions(-) create mode 100644 pc4mobx/hrmSalary/components/logViewModal/config.js create mode 100644 pc4mobx/hrmSalary/components/logViewModal/index.less diff --git a/pc4mobx/hrmSalary/apis/index.js b/pc4mobx/hrmSalary/apis/index.js index 854c9bf6..6be981c4 100644 --- a/pc4mobx/hrmSalary/apis/index.js +++ b/pc4mobx/hrmSalary/apis/index.js @@ -1,4 +1,5 @@ import { WeaTools } from "ecCom"; +import { postFetch } from "../util/request"; // form基础数据 export const getBaseForm = (params) => { @@ -19,3 +20,20 @@ export const getCondition = (params) => { export const getTableDatas = (params) => { return WeaTools.callApi("/api/demo03/weatableDemo", "GET", params); }; +//获取日志列表 +export const getLogs = params => { + const payload = { + ...params, + module: "hrsa", dataset: "dataset", + filterConditions: "[]", transMethod: "hrsa", + authParams: "{}" + }; + return postFetch("/api/bs/hrmsalary/elog/getLogs", payload); +}; +//获取单条操作记录的更新明细 +export const getDetailChanges = params => { + const payload = { + ...params, module: "hrsa", detailTransMethod: "elogDemoDetail", + }; + return postFetch("/api/bs/hrmsalary/elog/getDetailChanges", payload); +}; diff --git a/pc4mobx/hrmSalary/components/logViewModal/config.js b/pc4mobx/hrmSalary/components/logViewModal/config.js new file mode 100644 index 00000000..872a90c0 --- /dev/null +++ b/pc4mobx/hrmSalary/components/logViewModal/config.js @@ -0,0 +1,78 @@ +import React from "react"; +import { WeaFormItem, WeaLocaleProvider, WeaSearchGroup, WeaTools } from "ecCom"; +import { WeaSwitch } from "comsMobx"; +import { Button } from "antd"; + +const getKey = WeaTools.getKey; +const getLabel = WeaLocaleProvider.getLabel; +export const logConditions = [ + { + items: [ + { + conditionType: "INPUT", + domkey: ["operator"], + fieldcol: 18, + label: "操作人", + lanId: 17482, + labelcol: 6, + value: "", + viewAttr: 2 + }, + { + conditionType: "INPUT", + domkey: ["targetname"], + fieldcol: 18, + label: "对象", + lanId: 106, + labelcol: 6, + value: "", + viewAttr: 2 + }, + { + conditionType: "INPUT", + domkey: ["operatetypename"], + fieldcol: 18, + label: "操作类型", + lanId: 111, + labelcol: 6, + value: "", + viewAttr: 2 + } + ], + defaultshow: true, + title: "" + } +]; + +export const renderLogSearchsForm = (form, condition, onSearch = () => void (0)) => { + const { isFormInit } = form; + const formParams = form.getFormParams(); + let group = []; + isFormInit && condition && condition.map(c => { + let items = []; + c.items.map(fields => { + items.push({ + com: ( + + + { + getKey(fields) === "operatetypename" && +
+ + +
+ } +
), + colSpan: 1 + }); + }); + group.push( + ); + }); + return group; +}; diff --git a/pc4mobx/hrmSalary/components/logViewModal/index.js b/pc4mobx/hrmSalary/components/logViewModal/index.js index d95ceb25..aeab775a 100644 --- a/pc4mobx/hrmSalary/components/logViewModal/index.js +++ b/pc4mobx/hrmSalary/components/logViewModal/index.js @@ -1,99 +1,116 @@ -import React from 'react' -import { Button, Modal } from 'antd'; -import { WeaInput, WeaRangePicker, WeaTable} from 'ecCom' -import { logColumns, dataSource } from "../../common/columns" +/* + * Author: 黎永顺 + * name: 薪酬日志查看 + * Description: + * Date: 2024/1/24 + */ +import React, { Component } from "react"; +import { inject, observer } from "mobx-react"; +import { WeaDialog, WeaLocaleProvider, WeaTable } from "ecCom"; +import { logConditions, renderLogSearchsForm } from "./config"; +import "./index.less"; -export default class LogViewModal extends React.Component { - constructor(props) { - super(props) - this.state ={ - value: "" - } +const getLabel = WeaLocaleProvider.getLabel; + +@inject("baseFormStore") +@observer +class Index extends Component { + constructor(props) { + super(props); + this.state = { + dataSource: [], columns: [], pageInfo: { current: 1, pageSize: 10, total: 0 }, + loading: false, conditions: [] + }; + } + + componentDidMount() { + const { baseFormStore: { form } } = this.props; + this.setState({ + conditions: _.map(logConditions, it => ({ + ...it, items: _.map(it.items, o => ({ ...o, label: getLabel(o.lanId, o.label) })) + })) + }, () => form.initFormFields(this.state.conditions)); + } + + componentWillReceiveProps(nextProps, nextContext) { + // if (nextProps.visible !== this.props.visible && nextProps.visible) this.getAdjustHistoryList(); + if (nextProps.visible !== this.props.visible && !nextProps.visible) { + this.setState({ + dataSource: [], columns: [], pageInfo: { current: 0, pageSize: 10, total: 0 }, + loading: false + }); } - render() { - return ( - alert("ok")} onCancel={this.props.onCancel} - className="logViewModal" - style={{ top: 150 }} - width={'80%'} height={'50%'} - > -
-
-
操作时间
-
- this.setState({ value: v })} - /> -
-
-
-
操作人
-
- { - console.log(value); - this.setState({ value }); - }} - customBlur={v => { - console.log("custom blur", v); - }} - onFocus={v => console.log("focus", v)} - onBlur={v => console.log("blur", v)} - /> -
-
+ } -
-
对象
-
- { - console.log(value); - this.setState({ value }); - }} - customBlur={v => { - console.log("custom blur", v); - }} - onFocus={v => console.log("focus", v)} - onBlur={v => console.log("blur", v)} - /> -
-
+ // getAdjustHistoryList = (extra = {}) => { + // const { pageInfo } = this.state; + // const { archivesStore: { logForm } } = this.props; + // const payload = { ...pageInfo, ...logForm.getFormParams(), ...extra }; + // this.setState({ loading: true }); + // getAdjustHistoryList(payload).then(({ status, data }) => { + // this.setState({ loading: false }); + // if (status) { + // const { columns, list: dataSource, pageNum: current, pageSize, total } = data; + // this.setState({ + // pageInfo: { ...pageInfo, current, pageSize, total }, + // dataSource, columns: _.map(columns, it => { + // if (it.dataIndex === "operateTime") { + // return { ...it, render: (text) => ({moment(text).format("YYYY-MM-DD")}) }; + // } + // return { ...it }; + // }) + // }); + // } + // }).catch(() => this.setState({ loading: false })); + // }; -
-
操作类型
-
- { - console.log(value); - this.setState({ value }); - }} - customBlur={v => { - console.log("custom blur", v); - }} - onFocus={v => console.log("focus", v)} - onBlur={v => console.log("blur", v)} - /> -
-
- -
- -
-
- -
- ) - } -} \ No newline at end of file + render() { + const { loading, dataSource, columns, pageInfo, conditions } = this.state; + const { baseFormStore: { form } } = this.props; + const pagination = { + ...pageInfo, + showTotal: total => `${getLabel(18609, "共")} ${total} ${getLabel(18256, "条")}`, + showQuickJumper: true, + showSizeChanger: true, + pageSizeOptions: ["10", "20", "50", "100"], + onShowSizeChange: (current, pageSize) => { + this.setState({ + pageInfo: { ...pageInfo, current, pageSize } + }, () => this.getAdjustHistoryList()); + }, + onChange: current => { + this.setState({ + pageInfo: { ...pageInfo, current } + }, () => this.getAdjustHistoryList()); + } + }; + const scrollHeight = this.logRef ? this.logRef.state.height - 210 : 606.6; + return ( + this.logRef = dom} className="logDialog" initLoadCss + style={{ + width: 1150, + height: 606.6, + minHeight: 200, + minWidth: 380, + maxHeight: "90%", + maxWidth: "90%", + overflow: "hidden", + transform: "translate(0px, 0px)" + }} + > +
+ {renderLogSearchsForm(form, conditions, () => this.getAdjustHistoryList({ current: 1 }))} + +
+
+ ); + } +} + +export default Index; diff --git a/pc4mobx/hrmSalary/components/logViewModal/index.less b/pc4mobx/hrmSalary/components/logViewModal/index.less new file mode 100644 index 00000000..6c10dc6f --- /dev/null +++ b/pc4mobx/hrmSalary/components/logViewModal/index.less @@ -0,0 +1,30 @@ +.logDialog { + .wea-dialog-body { + overflow-y: hidden; + } + + .logDialogContent { + background: #F6F6F6; + padding: 16px; + width: 100%; + height: 100%; + + .wea-search-group { + padding: 0; + margin-bottom: 10px; + background: #FFF; + + .wea-form-cell { + padding: 0; + + .wea-form-item { + padding: 10px; + } + } + } + + .logTable { + background: #FFFFFF; + } + } +} diff --git a/pc4mobx/hrmSalary/pages/salaryItem/index.js b/pc4mobx/hrmSalary/pages/salaryItem/index.js index 921c9d2f..67a0f05e 100644 --- a/pc4mobx/hrmSalary/pages/salaryItem/index.js +++ b/pc4mobx/hrmSalary/pages/salaryItem/index.js @@ -11,6 +11,7 @@ import CustomSalaryItemSlide from "./customSalaryItemSlide"; import CustomPaginationTable from "../../components/customPaginationTable"; import SyncToSalaryAccountSetDialog from "./syncToSalaryAccountSetDialog"; import "../socialSecurityBenefits/programme/index.less"; +import LogDialog from "../../components/logViewModal"; const { getLabel } = WeaLocaleProvider; @inject("salaryItemStore", "taxAgentStore", "salaryFileStore") @@ -27,7 +28,8 @@ export default class SalaryItem extends React.Component { formalModalVisible: false, searchParams: { current: 1, pageSize: 10, total: 0 }, selectedRowKeys: [], - syncSalarySetDialog: { visible: false, title: "", id: "" } + syncSalarySetDialog: { visible: false, title: "", id: "" }, + logDialogVisible: false }; columns.map(item => { if (item.dataIndex == "refere") { @@ -191,6 +193,16 @@ export default class SalaryItem extends React.Component { getTableDatas({ ...searchParams }); } + onDropMenuClick = (key) => { + switch (key) { + case "log": + this.setState({ logDialogVisible: true }); + break; + default: + break; + } + }; + render() { const { salaryItemStore, @@ -198,7 +210,7 @@ export default class SalaryItem extends React.Component { taxAgentStore: { showOperateBtn, showSalaryItemBtn, taxAgentOption } } = this.props; const { userStatusList } = salaryFileStore; - const { selectedRowKeys } = this.state; + const { selectedRowKeys, logDialogVisible } = this.state; const { loading, deleteItemRequest, getTableDatas } = salaryItemStore; const { tableDataSource, @@ -342,11 +354,14 @@ export default class SalaryItem extends React.Component { }; return (
- } - iconBgcolor="#F14A2D" - showDropIcon={false} + } iconBgcolor="#F14A2D" + showDropIcon onDropMenuClick={this.onDropMenuClick} + dropMenuDatas={[ + { + key: "log", icon: , + content: getLabel(545781, "操作日志") + } + ]} >
@@ -387,7 +402,8 @@ export default class SalaryItem extends React.Component { } })} /> - + {/*操作日志*/} + this.setState({ logDialogVisible: false })}/> { systemItemVisible && this.logVisible = bool - -} \ No newline at end of file + +} From 7cb1b157ebc0c7ba43c2909585be97670e55a097 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Thu, 25 Jan 2024 11:52:10 +0800 Subject: [PATCH 002/127] =?UTF-8?q?feature/2.10.1.2401.01-=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E6=93=8D=E4=BD=9C=E6=97=A5=E5=BF=97=E6=B7=BB=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pc4mobx/hrmSalary/apis/index.js | 7 +- .../components/detailLogView/index.js | 81 +++++++++++++++++++ .../components/logViewModal/config.js | 18 ++++- .../components/logViewModal/index.js | 74 ++++++++++------- .../components/logViewModal/index.less | 41 ++++++++++ pc4mobx/hrmSalary/pages/salaryItem/index.js | 3 +- 6 files changed, 185 insertions(+), 39 deletions(-) create mode 100644 pc4mobx/hrmSalary/components/logViewModal/components/detailLogView/index.js diff --git a/pc4mobx/hrmSalary/apis/index.js b/pc4mobx/hrmSalary/apis/index.js index 6be981c4..af60888f 100644 --- a/pc4mobx/hrmSalary/apis/index.js +++ b/pc4mobx/hrmSalary/apis/index.js @@ -23,17 +23,16 @@ export const getTableDatas = (params) => { //获取日志列表 export const getLogs = params => { const payload = { - ...params, - module: "hrsa", dataset: "dataset", + ...params, module: "hrsa", dataset: "dataset", authParams: "{}", filterConditions: "[]", transMethod: "hrsa", - authParams: "{}" + showColums: "[{\"columName\":\"操作时间\",\"columIndex\":\"createdate\",\"width\":\"5%\"},{\"columName\":\"操作人\",\"columIndex\":\"operatorname\",\"width\":\"2%\"},{\"columName\":\"操作类型\",\"columIndex\":\"operatetypename\",\"width\":\"5%\"},{\"columName\":\"项目\",\"columIndex\":\"modulenamespan\",\"width\":\"3%\"},{\"columName\":\"对象\",\"columIndex\":\"targetname\",\"width\":\"4%\"},{\"columName\":\"修改详情\",\"columIndex\":\"operatedesc\",\"width\":\"2%\"},{\"columName\":\"客户端IP\",\"columIndex\":\"clientip\",\"width\":\"5%\"}]" }; return postFetch("/api/bs/hrmsalary/elog/getLogs", payload); }; //获取单条操作记录的更新明细 export const getDetailChanges = params => { const payload = { - ...params, module: "hrsa", detailTransMethod: "elogDemoDetail", + ...params, module: "hrsa", detailTransMethod: "elogDemoDetail" }; return postFetch("/api/bs/hrmsalary/elog/getDetailChanges", payload); }; diff --git a/pc4mobx/hrmSalary/components/logViewModal/components/detailLogView/index.js b/pc4mobx/hrmSalary/components/logViewModal/components/detailLogView/index.js new file mode 100644 index 00000000..a5c1a5cc --- /dev/null +++ b/pc4mobx/hrmSalary/components/logViewModal/components/detailLogView/index.js @@ -0,0 +1,81 @@ +/* + * Author: 黎永顺 + * name: 日志查看-详情 + * Description: + * Date: 2024/1/25 + */ +import React, { Component } from "react"; +import { WeaDialog, WeaLocaleProvider, WeaTransfer } from "ecCom"; +import * as API from "../../../../apis"; + +const getLabel = WeaLocaleProvider.getLabel; +const WeaTransferList = WeaTransfer.list; + +class Index extends Component { + constructor(props) { + super(props); + this.state = { + dataSource: [], loading: false + }; + } + + componentWillReceiveProps(nextProps, nextContext) { + if (nextProps.visible !== this.props.visible && nextProps.visible) this.getDetailChanges(nextProps); + if (nextProps.visible !== this.props.visible && !nextProps.visible) this.setState({ + dataSource: [], + loading: false + }); + } + + getDetailChanges = (props) => { + const { mainid, logFunction } = props; + const payload = { function: logFunction, mainid }; + this.setState({ loading: true }); + API.getDetailChanges(payload).then(({ status, data }) => { + this.setState({ loading: false }); + if (status) { + this.setState({ + dataSource: _.map(data, (o, i) => ({ + ...o, index: i + 1, + valueschanges: _.map(o.valueschanges, (g, gi) => ({ id: gi + 1, name: g })) + })) + }); + } + }).catch(() => this.setState({ loading: false })); + }; + + render() { + const { dataSource } = this.state; + const scrollHeight = this.logDetailRef ? this.logDetailRef.state.height - 32 : 606.6; + return ( + this.logDetailRef = dom} + style={{ + width: 750, + height: 606.6, + minHeight: 200, + minWidth: 380, + maxHeight: "90%", + maxWidth: "90%", + overflow: "hidden", + transform: "translate(0px, 0px)" + }} + > +
+ { + _.map(dataSource, item => ( (
+
{it.id}
+
{it.name}
+
)} + height={scrollHeight} checkedCb={() => ({})} checkedKeys={[]} + />)) + } +
+
+ ); + } +} + +export default Index; diff --git a/pc4mobx/hrmSalary/components/logViewModal/config.js b/pc4mobx/hrmSalary/components/logViewModal/config.js index 872a90c0..f3b3189a 100644 --- a/pc4mobx/hrmSalary/components/logViewModal/config.js +++ b/pc4mobx/hrmSalary/components/logViewModal/config.js @@ -8,6 +8,16 @@ const getLabel = WeaLocaleProvider.getLabel; export const logConditions = [ { items: [ + { + conditionType: "RANGEPICKER", + domkey: ["date"], + fieldcol: 18, + label: "操作时间", + lanId: 111, + labelcol: 6, + value: "", + viewAttr: 2 + }, { conditionType: "INPUT", domkey: ["operator"], @@ -44,7 +54,7 @@ export const logConditions = [ } ]; -export const renderLogSearchsForm = (form, condition, onSearch = () => void (0)) => { +export const renderLogSearchsForm = (form, condition, onSearch = () => void (0), onReset = () => void (0)) => { const { isFormInit } = form; const formParams = form.getFormParams(); let group = []; @@ -61,8 +71,8 @@ export const renderLogSearchsForm = (form, condition, onSearch = () => void (0)) { getKey(fields) === "operatetypename" && -
- +
+
} @@ -71,7 +81,7 @@ export const renderLogSearchsForm = (form, condition, onSearch = () => void (0)) }); }); group.push( - ); }); return group; diff --git a/pc4mobx/hrmSalary/components/logViewModal/index.js b/pc4mobx/hrmSalary/components/logViewModal/index.js index aeab775a..857ed362 100644 --- a/pc4mobx/hrmSalary/components/logViewModal/index.js +++ b/pc4mobx/hrmSalary/components/logViewModal/index.js @@ -7,7 +7,9 @@ import React, { Component } from "react"; import { inject, observer } from "mobx-react"; import { WeaDialog, WeaLocaleProvider, WeaTable } from "ecCom"; +import DetailLogView from "./components/detailLogView"; import { logConditions, renderLogSearchsForm } from "./config"; +import * as API from "../../apis/index"; import "./index.less"; const getLabel = WeaLocaleProvider.getLabel; @@ -19,7 +21,7 @@ class Index extends Component { super(props); this.state = { dataSource: [], columns: [], pageInfo: { current: 1, pageSize: 10, total: 0 }, - loading: false, conditions: [] + loading: false, conditions: [], logDetailDialog: { visible: false, title: "", logFunction: "", mainid: "" } }; } @@ -33,7 +35,7 @@ class Index extends Component { } componentWillReceiveProps(nextProps, nextContext) { - // if (nextProps.visible !== this.props.visible && nextProps.visible) this.getAdjustHistoryList(); + if (nextProps.visible !== this.props.visible && nextProps.visible) this.getLogs(); if (nextProps.visible !== this.props.visible && !nextProps.visible) { this.setState({ dataSource: [], columns: [], pageInfo: { current: 0, pageSize: 10, total: 0 }, @@ -42,30 +44,38 @@ class Index extends Component { } } - // getAdjustHistoryList = (extra = {}) => { - // const { pageInfo } = this.state; - // const { archivesStore: { logForm } } = this.props; - // const payload = { ...pageInfo, ...logForm.getFormParams(), ...extra }; - // this.setState({ loading: true }); - // getAdjustHistoryList(payload).then(({ status, data }) => { - // this.setState({ loading: false }); - // if (status) { - // const { columns, list: dataSource, pageNum: current, pageSize, total } = data; - // this.setState({ - // pageInfo: { ...pageInfo, current, pageSize, total }, - // dataSource, columns: _.map(columns, it => { - // if (it.dataIndex === "operateTime") { - // return { ...it, render: (text) => ({moment(text).format("YYYY-MM-DD")}) }; - // } - // return { ...it }; - // }) - // }); - // } - // }).catch(() => this.setState({ loading: false })); - // }; + getLogs = (extra = {}) => { + const { pageInfo, logDetailDialog } = this.state; + const { baseFormStore: { form }, logFunction } = this.props; + const payload = { + ...pageInfo, ...extra, searchMap: { ...form.getFormParams() }, + function: logFunction, showColums: "" + }; + this.setState({ loading: true }); + API.getLogs(payload).then(({ status, data }) => { + this.setState({ loading: false }); + if (status) { + const { columns, list: dataSource, pageNum: current, pageSize, total } = data; + this.setState({ + pageInfo: { ...pageInfo, current, pageSize, total }, + dataSource, columns: _.map(columns, it => { + if (it.dataIndex === "operatedesc") { + return { + ...it, render: (__, record) => ( { + const { operatedesc: title, uuid: mainid } = record; + this.setState({ logDetailDialog: { visible: true, title, logFunction, mainid } }); + }}>{getLabel(33564, "查看")}) + }; + } + return { ...it }; + }) + }); + } + }).catch(() => this.setState({ loading: false })); + }; render() { - const { loading, dataSource, columns, pageInfo, conditions } = this.state; + const { loading, dataSource, columns, pageInfo, conditions, logDetailDialog } = this.state; const { baseFormStore: { form } } = this.props; const pagination = { ...pageInfo, @@ -76,15 +86,15 @@ class Index extends Component { onShowSizeChange: (current, pageSize) => { this.setState({ pageInfo: { ...pageInfo, current, pageSize } - }, () => this.getAdjustHistoryList()); + }, () => this.getLogs()); }, onChange: current => { this.setState({ pageInfo: { ...pageInfo, current } - }, () => this.getAdjustHistoryList()); + }, () => this.getLogs()); } }; - const scrollHeight = this.logRef ? this.logRef.state.height - 210 : 606.6; + const scrollHeight = this.logRef ? this.logRef.state.height - 254 : 606.6; return (
- {renderLogSearchsForm(form, conditions, () => this.getAdjustHistoryList({ current: 1 }))} + {renderLogSearchsForm(form, conditions, () => this.getLogs({ current: 1 }), () => { + form.resetForm(); + this.getLogs({ current: 1 }); + })} + this.setState({ logDetailDialog: { ...logDetailDialog, visible: false } })}/>
); diff --git a/pc4mobx/hrmSalary/components/logViewModal/index.less b/pc4mobx/hrmSalary/components/logViewModal/index.less index 6c10dc6f..0d9e4d57 100644 --- a/pc4mobx/hrmSalary/components/logViewModal/index.less +++ b/pc4mobx/hrmSalary/components/logViewModal/index.less @@ -26,5 +26,46 @@ .logTable { background: #FFFFFF; } + + .wea-transfer-list-wrapper { + border: none; + + .ant-tree-switcher { + display: none; + } + + .transfer-tree { + background: #FFF; + border: 1px solid #dadada; + + .treeitem { + margin: 0 !important; + } + } + } + + .detailBox { + display: flex; + align-items: center; + + .order { + width: 35px; + color: #999; + text-align: center; + } + + .content { + position: relative; + flex: 1; + min-height: 40px; + color: #000; + display: flex; + align-items: center; + justify-content: flex-start; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; + } + } } } diff --git a/pc4mobx/hrmSalary/pages/salaryItem/index.js b/pc4mobx/hrmSalary/pages/salaryItem/index.js index 67a0f05e..d808d539 100644 --- a/pc4mobx/hrmSalary/pages/salaryItem/index.js +++ b/pc4mobx/hrmSalary/pages/salaryItem/index.js @@ -403,7 +403,8 @@ export default class SalaryItem extends React.Component { })} /> {/*操作日志*/} - this.setState({ logDialogVisible: false })}/> + this.setState({ logDialogVisible: false })}/> { systemItemVisible && Date: Thu, 25 Jan 2024 14:02:34 +0800 Subject: [PATCH 003/127] =?UTF-8?q?feature/2.10.1.2401.01-=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E6=93=8D=E4=BD=9C=E6=97=A5=E5=BF=97=E6=B7=BB=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/detailLogView/index.js | 13 ++-- .../components/logViewModal/index.less | 62 ++++++++++++------- 2 files changed, 45 insertions(+), 30 deletions(-) diff --git a/pc4mobx/hrmSalary/components/logViewModal/components/detailLogView/index.js b/pc4mobx/hrmSalary/components/logViewModal/components/detailLogView/index.js index a5c1a5cc..7ca588a9 100644 --- a/pc4mobx/hrmSalary/components/logViewModal/components/detailLogView/index.js +++ b/pc4mobx/hrmSalary/components/logViewModal/components/detailLogView/index.js @@ -63,14 +63,13 @@ class Index extends Component { >
{ - _.map(dataSource, item => ( (
-
{it.id}
-
{it.name}
-
)} + _.map(dataSource, item => (!_.isEmpty(item.valueschanges) ? (
+
{it.id}
+
{it.name}
+
)} height={scrollHeight} checkedCb={() => ({})} checkedKeys={[]} - />)) + /> :
{getLabel(111, "无数据变更记录")}
)) }
diff --git a/pc4mobx/hrmSalary/components/logViewModal/index.less b/pc4mobx/hrmSalary/components/logViewModal/index.less index 0d9e4d57..79d0bee5 100644 --- a/pc4mobx/hrmSalary/components/logViewModal/index.less +++ b/pc4mobx/hrmSalary/components/logViewModal/index.less @@ -9,6 +9,15 @@ width: 100%; height: 100%; + .empty { + width: 100%; + display: flex; + height: 100%; + justify-content: center; + align-items: center; + background: #ffff; + } + .wea-search-group { padding: 0; margin-bottom: 10px; @@ -37,34 +46,41 @@ .transfer-tree { background: #FFF; border: 1px solid #dadada; + padding: 0; - .treeitem { - margin: 0 !important; + & > li:not(:last-child) { + .detailBox .content { + border-bottom: 1px solid #dadada; + } } - } - } - .detailBox { - display: flex; - align-items: center; + & > li { + margin: 0 !important; - .order { - width: 35px; - color: #999; - text-align: center; - } + .detailBox { + display: flex; + align-items: center; - .content { - position: relative; - flex: 1; - min-height: 40px; - color: #000; - display: flex; - align-items: center; - justify-content: flex-start; - overflow: hidden; - text-overflow: ellipsis; - white-space: nowrap; + .order { + width: 35px; + color: #999; + text-align: center; + } + + .content { + position: relative; + flex: 1; + min-height: 40px; + color: #000; + display: flex; + align-items: center; + justify-content: flex-start; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; + } + } + } } } } From 0b3c97a53fc842550faa08a6427f202f876b115c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Tue, 30 Jan 2024 17:34:02 +0800 Subject: [PATCH 004/127] =?UTF-8?q?feature/2.10.1.2401.01-=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E6=93=8D=E4=BD=9C=E6=97=A5=E5=BF=97=E6=B7=BB=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pc4mobx/hrmSalary/pages/taxAgent/index.js | 39 +++++++++++++++++------ 1 file changed, 29 insertions(+), 10 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/taxAgent/index.js b/pc4mobx/hrmSalary/pages/taxAgent/index.js index 1010c090..a82f231c 100644 --- a/pc4mobx/hrmSalary/pages/taxAgent/index.js +++ b/pc4mobx/hrmSalary/pages/taxAgent/index.js @@ -1,13 +1,16 @@ import React from "react"; import { inject, observer } from "mobx-react"; import { Button, Col, message, Modal, Row, Switch } from "antd"; -import { WeaFormItem, WeaInputSearch, WeaSearchGroup, WeaTable, WeaTop } from "ecCom"; +import { WeaFormItem, WeaInputSearch, WeaLocaleProvider, WeaSearchGroup, WeaTable, WeaTop } from "ecCom"; import { renderNoright } from "../../util"; import EditModal from "./editModal"; import TipLabel from "../../components/TipLabel"; import { decentralizationConditions, editConditions } from "./editConditions"; +import LogDialog from "../../components/logViewModal"; import "./index.less"; +const getLabel = WeaLocaleProvider.getLabel; + @inject("taxAgentStore") @observer export default class TaxAgent extends React.Component { @@ -30,7 +33,8 @@ export default class TaxAgent extends React.Component { conditions: editConditions, decentralizationConditions: decentralizationConditions, permission: {}, - syncLoading: false + syncLoading: false, + logDialogVisible: false }; } @@ -282,6 +286,15 @@ export default class TaxAgent extends React.Component { } }); }; + onDropMenuClick = (key) => { + switch (key) { + case "log": + this.setState({ logDialogVisible: true }); + break; + default: + break; + } + }; render() { @@ -294,7 +307,8 @@ export default class TaxAgent extends React.Component { decentralizationConditions, permission, syncLoading, - name + name, + logDialogVisible } = this.state; const { loading, @@ -389,12 +403,15 @@ export default class TaxAgent extends React.Component { return (
- } // 左侧图标 - iconBgcolor="#F14A2D" // 左侧图标背景色 - buttons={showOperateBtn ? btns : btns.slice(1)} - showDropIcon={true}> + } iconBgcolor="#F14A2D" + buttons={showOperateBtn ? btns : btns.slice(1)} showDropIcon onDropMenuClick={this.onDropMenuClick} + dropMenuDatas={[ + { + key: "log", icon: , + content: getLabel(545781, "操作日志") + } + ]} + > @@ -440,7 +457,9 @@ export default class TaxAgent extends React.Component { - + {/*操作日志*/} + this.setState({ logDialogVisible: false })}/> {editModalProps.visible && Date: Wed, 31 Jan 2024 10:24:15 +0800 Subject: [PATCH 005/127] =?UTF-8?q?feature/2.10.1.2401.01-=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E6=93=8D=E4=BD=9C=E6=97=A5=E5=BF=97=E6=B7=BB=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pages/adjustSalaryManage/index.js | 28 ++++++++++++--- .../components/statisticsModal.js | 8 +++++ .../pages/analysisOfSalaryStatistics/index.js | 30 ++++++++++++++-- .../analysisOfSalaryStatistics/index.less | 9 ++--- .../hrmSalary/pages/calculate/calculate.js | 30 +++++++++++++--- pc4mobx/hrmSalary/pages/declare/declare.js | 28 ++++++++++++--- .../pages/externalPersonManage/index.js | 25 ++++++++++++-- .../hrmSalary/pages/fieldManagement/index.js | 34 ++++++++++++++----- pc4mobx/hrmSalary/pages/ledgerPage/index.js | 34 ++++++++++++++----- .../pages/payrollFiles/config/index.js | 4 +++ .../pages/payrollFiles/salaryFiles.js | 11 ++++-- .../updatePayrollTemplateSlide/index.js | 7 +++- .../hrmSalary/pages/payrollRelease/index.js | 28 ++++++++++++--- .../hrmSalary/pages/payrollRelease/index.less | 10 +++--- .../standingBook/standingBook.js | 28 +++++++++++++-- .../components/logDialog/index.js | 2 +- .../welfareArchive/config.js | 6 +++- .../welfareArchive/index.js | 15 +++++--- 18 files changed, 276 insertions(+), 61 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/adjustSalaryManage/index.js b/pc4mobx/hrmSalary/pages/adjustSalaryManage/index.js index e57ffa58..4e05e6b9 100644 --- a/pc4mobx/hrmSalary/pages/adjustSalaryManage/index.js +++ b/pc4mobx/hrmSalary/pages/adjustSalaryManage/index.js @@ -12,9 +12,9 @@ import AdvanceInputBtn from "./components/advanceInputBtn"; import AdjustAdvanceSearchPannel from "./components/adjustAdvanceSearchPannel"; import cs from "classnames"; import { Button } from "antd"; -import "./index.less"; import { convertToUrlString } from "../../util/url"; - +import LogDialog from "../../components/logViewModal"; +import "./index.less"; const getLabel = WeaLocaleProvider.getLabel; @@ -25,7 +25,7 @@ class Index extends Component { super(props); this.state = { loading: false, columns: [], dataSource: [], showSearchAd: false, - pageInfo: { current: 1, pageSize: 10, total: 0 } + pageInfo: { current: 1, pageSize: 10, total: 0 }, logDialogVisible: false }; } @@ -88,9 +88,18 @@ class Index extends Component { } this.handleDebounce(); }; + onDropMenuClick = (key) => { + switch (key) { + case "log": + this.setState({ logDialogVisible: true }); + break; + default: + break; + } + }; render() { - const { loading, dataSource, columns, pageInfo, showSearchAd } = this.state; + const { loading, dataSource, columns, pageInfo, showSearchAd, logDialogVisible } = this.state; const pagination = { ...pageInfo, showTotal: total => `${getLabel(18609, "共")} ${total} ${getLabel(18256, "条")}`, @@ -111,11 +120,17 @@ class Index extends Component { return ( } iconBgcolor="#F14A2D" + icon={} iconBgcolor="#F14A2D" showDropIcon buttons={[ , this.openAdvanceSearch()} onAdvanceSearch={this.adjustRecordItemList}/> + ]} onDropMenuClick={this.onDropMenuClick} + dropMenuDatas={[ + { + key: "log", icon: , + content: getLabel(545781, "操作日志") + } ]} >
@@ -129,6 +144,9 @@ class Index extends Component { dataSource={dataSource} loading={loading} pagination={pagination} columns={columns} /> + {/*操作日志*/} + this.setState({ logDialogVisible: false })}/> ); } diff --git a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/statisticsModal.js b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/statisticsModal.js index 1f333b7c..d80b2877 100644 --- a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/statisticsModal.js +++ b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/statisticsModal.js @@ -20,6 +20,14 @@ class StatisticsModal extends Component { }; } + componentWillReceiveProps(nextProps, nextContext) { + if (nextProps.visible !== this.props.visible && nextProps.visible) { + document.querySelector(".xc_tj_fx_wrapper").classList.add("zIndex0-statistics"); + } else if (nextProps.visible !== this.props.visible && !nextProps.visible) { + document.querySelector(".xc_tj_fx_wrapper").classList.remove("zIndex0-statistics"); + } + } + handleSaveReportList = () => { const { form, id, onCancel } = this.props; form.validateForm().then(f => { diff --git a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/index.js b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/index.js index f9a073e5..3461e431 100644 --- a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/index.js +++ b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/index.js @@ -19,6 +19,7 @@ import ReportList from "./components/reportList"; import ReportForm from "./components/reportForm"; import moment from "moment"; import "./index.less"; +import LogDialog from "../../components/logViewModal"; const { getLabel } = WeaLocaleProvider; @@ -41,7 +42,8 @@ class Index extends Component { modalReq: { title: "", visible: false, typeKey: "", id: "" - } + }, + logDialogVisible: false }; } @@ -243,10 +245,22 @@ class Index extends Component { initTable && this.dimensionTableRef.dimensionList(); }); }; + onDropMenuClick = (key) => { + switch (key) { + case "log": + this.setState({ logDialogVisible: true }); + break; + default: + break; + } + }; render() { const { taxAgentStore: { statisticsReportBtn }, attendanceStore: { statisticsForm, reportForm } } = this.props; - const { selectedKey, modalReq, slideReq, conditions, reportConditions, reportName, keyword, year } = this.state; + const { + selectedKey, modalReq, slideReq, conditions, reportConditions, + reportName, keyword, year, logDialogVisible + } = this.state; const buttons = selectedKey === "statistics" ? [ , , - ] : []; + ] : [ + , + this.setState({ fieldName })} + onSearch={() => this.fieldMangRef.getAttendanceFieldList({ fieldName, current: 1 })}/> + ]; return (
- this.setState({ selectedKey: v })} - searchsBaseValue={fieldName} onSearchChange={fieldName => this.setState({ fieldName })} - onSearch={() => this.fieldMangRef.getAttendanceFieldList({ fieldName, current: 1 })} - /> - { - selectedKey === "DATA" && this.getAttendanceDataScreen() - } -
- + } iconBgcolor="#F14A2D" + tabDatas={topTab} selectedKey={selectedKey} buttons={showOperateBtn ? buttons : []} + onChange={v => this.setState({ selectedKey: v })} title={getLabel(525196, "考勤数据")} + showDropIcon onDropMenuClick={this.onDropMenuClick} + dropMenuDatas={[ { - selectedKey === "DATA" ? - this.attendanceTableRef = dom} - showOperateBtn={showOperateBtn} - salaryYearMonth={salaryMonth} - /> : - this.fieldMangRef = dom} - showOperateBtn={showOperateBtn} - fieldName={fieldName} - /> + key: "log", icon: , + content: getLabel(545781, "操作日志") } - -
+ ]} + > + { + selectedKey === "DATA" && this.getAttendanceDataScreen() + } +
+ + { + selectedKey === "DATA" ? + this.attendanceTableRef = dom} + showOperateBtn={showOperateBtn} + salaryYearMonth={salaryMonth} + /> : + this.fieldMangRef = dom} + showOperateBtn={showOperateBtn} + fieldName={fieldName} + /> + } + +
+ {/*操作日志*/} + this.setState({ logDialogVisible: false })}/> +
); } diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less index 6e4af33c..5d7d9bed 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less @@ -14,6 +14,8 @@ .tableWrapper { flex: 1; overflow: hidden; + background: #FFF; + padding: 0 16px; } .linkWapper { diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js b/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js index 085f5756..98d9f374 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js @@ -548,7 +548,7 @@ class Index extends Component { onResizeWindowInnerWidth={this.handleResize} slidePayload={slidePayload} onClose={this.handleCloseSlide} onSave={this.handleSaveData} slideLoading={saveLoading} exportPayloadUrl={exportPayloadUrl} - exportPayloadType={exportPayloadType} + exportPayloadType={exportPayloadType} logFunction="addupdeduction" form={form} condition={advanceCondition} onAdSearch={this.handleAdSearch} onImportSetStep={this.handleImportSetStep} onCancel={this.handleCloseImport} importPayload={importPayload} onImportFile={this.handleImportFile} diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/cumSituation/index.js b/pc4mobx/hrmSalary/pages/dataAcquisition/cumSituation/index.js index 6a781d4b..ecf016bc 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/cumSituation/index.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/cumSituation/index.js @@ -552,7 +552,7 @@ class Index extends Component { onResizeWindowInnerWidth={this.handleResize} slidePayload={slidePayload} onClose={this.handleCloseSlide} onSave={this.handleSaveData} slideLoading={saveLoading} exportPayloadUrl={exportPayloadUrl} - exportPayloadType={exportPayloadType} + exportPayloadType={exportPayloadType} logFunction="addupsituation" form={form} condition={advanceCondition} onAdSearch={this.handleAdSearch} onImportSetStep={this.handleImportSetStep} onCancel={this.handleCloseImport} importPayload={{ ...importPayload, importOpts: { taxYearMonth: importPayload.importOpts.declareMonth } }} diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/layout.js b/pc4mobx/hrmSalary/pages/dataAcquisition/layout.js index 4c421d60..1cee5ed6 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/layout.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/layout.js @@ -7,11 +7,14 @@ import React, { Component } from "react"; import { inject, observer } from "mobx-react"; import { toJS } from "mobx"; -import { WeaNewScroll, WeaSlideModal, WeaTab, WeaTop } from "ecCom"; +import { WeaLocaleProvider, WeaNewScroll, WeaSlideModal, WeaTab, WeaTop } from "ecCom"; import ImportModal from "../../components/importModal"; import SlideModalTitle from "../../components/slideModalTitle"; import { getSearchs } from "../../util"; import "./index.less"; +import LogDialog from "../../components/logViewModal"; + +const getLabel = WeaLocaleProvider.getLabel; @inject("taxAgentStore") @observer @@ -19,7 +22,7 @@ class Layout extends Component { constructor(props) { super(props); this.state = { - showSearchAd: false + showSearchAd: false, logDialogVisible: false }; } @@ -49,14 +52,23 @@ class Layout extends Component { const { onResizeWindowInnerWidth } = this.props; onResizeWindowInnerWidth(window.innerWidth); }; + onDropMenuClick = (key) => { + switch (key) { + case "log": + this.setState({ logDialogVisible: true }); + break; + default: + break; + } + }; render() { - const { showSearchAd } = this.state; + const { showSearchAd, logDialogVisible } = this.state; const { title, btns, leftComp, children, taxAgentStore: { showOperateBtn }, slidePayload, onClose, onSave, slideLoading, form, condition, onAdSearch, onCancel, importPayload, onImportSetStep, onImportFile, - onPreviewImport, detailOptBtns, columns + onPreviewImport, detailOptBtns, columns, logFunction } = this.props; const { visible, title: subtitle, children: slideChildren } = slidePayload; const { @@ -66,8 +78,14 @@ class Layout extends Component { return (
} - iconBgcolor="#F14A2D" showDropIcon={false} + icon={} iconBgcolor="#F14A2D" + showDropIcon onDropMenuClick={this.onDropMenuClick} + dropMenuDatas={[ + { + key: "log", icon: , + content: getLabel(545781, "操作日志") + } + ]} /> + {/*操作日志*/} + this.setState({ logDialogVisible: false })}/>
); diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/otherDeduct/index.js b/pc4mobx/hrmSalary/pages/dataAcquisition/otherDeduct/index.js index 7f843623..2795207c 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/otherDeduct/index.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/otherDeduct/index.js @@ -546,7 +546,7 @@ class Index extends Component { onResizeWindowInnerWidth={this.handleResize} slidePayload={slidePayload} onClose={this.handleCloseSlide} onSave={this.handleSaveData} slideLoading={saveLoading} exportPayloadUrl={exportPayloadUrl} - exportPayloadType={exportPayloadType} + exportPayloadType={exportPayloadType} logFunction="otherdeduction" form={form} condition={advanceCondition} onAdSearch={this.handleAdSearch} onImportSetStep={this.handleImportSetStep} onCancel={this.handleCloseImport} importPayload={importPayload} onImportFile={this.handleImportFile} From 9697e5aa8103699b667f6cf7280624774d9da0ff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Wed, 31 Jan 2024 11:29:16 +0800 Subject: [PATCH 007/127] =?UTF-8?q?feature/2.10.1.2401.01-=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E6=93=8D=E4=BD=9C=E6=97=A5=E5=BF=97=E6=B7=BB=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less index 5d7d9bed..052f2e4b 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less @@ -15,7 +15,7 @@ flex: 1; overflow: hidden; background: #FFF; - padding: 0 16px; + margin: 0 16px; } .linkWapper { From 3093279f2932d6229a41b308d5736572d466c95b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Wed, 31 Jan 2024 11:31:14 +0800 Subject: [PATCH 008/127] =?UTF-8?q?feature/2.10.1.2401.01-=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E6=93=8D=E4=BD=9C=E6=97=A5=E5=BF=97=E6=B7=BB=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less index 052f2e4b..f6a0accb 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less @@ -15,7 +15,7 @@ flex: 1; overflow: hidden; background: #FFF; - margin: 0 16px; + margin: 16px; } .linkWapper { From e2898441cfc70fe711a3704f672b65839c602338 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Wed, 31 Jan 2024 11:37:20 +0800 Subject: [PATCH 009/127] =?UTF-8?q?feature/2.10.1.2401.01-=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E6=93=8D=E4=BD=9C=E6=97=A5=E5=BF=97=E6=B7=BB=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../attendance/components/attendanceDataViewSlide.js | 7 ++++++- .../hrmSalary/pages/dataAcquisition/attendance/index.less | 6 ++++++ 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceDataViewSlide.js b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceDataViewSlide.js index 45fa6bfe..1011398c 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceDataViewSlide.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceDataViewSlide.js @@ -29,7 +29,12 @@ class AttendanceDataViewSlide extends Component { } componentWillReceiveProps(nextProps, nextContext) { - if (nextProps.visible !== this.props.visible && nextProps.visible) this.viewAttendQuote({}, nextProps); + if (nextProps.visible !== this.props.visible && nextProps.visible) { + document.querySelector(".attendanceRefWrapper").classList.add("zIndex0-attendance"); + this.viewAttendQuote({}, nextProps); + } else if (nextProps.visible !== this.props.visible && !nextProps.visible) { + document.querySelector(".attendanceRefWrapper").classList.remove("zIndex0-attendance"); + } } viewAttendQuote = (extraPayload = {}, props) => { diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less index f6a0accb..e4dae347 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less @@ -25,6 +25,12 @@ } } +.zIndex0-attendance { + .wea-new-top-req { + z-index: 0 !important; + } +} + .attendenceImportWrapper { .wea-dialog-body { From 3c57000afcb324ad20494e4ac35deb7ab80ce7fe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Thu, 1 Feb 2024 14:04:55 +0800 Subject: [PATCH 010/127] =?UTF-8?q?feature/2.10.1.2401.01-=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E6=93=8D=E4=BD=9C=E6=97=A5=E5=BF=97=E6=B7=BB=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../hrmSalary/pages/mySalaryBenefits/index.js | 26 ++++++++++++++++--- 1 file changed, 23 insertions(+), 3 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/mySalaryBenefits/index.js b/pc4mobx/hrmSalary/pages/mySalaryBenefits/index.js index 89d25e4d..3a221393 100644 --- a/pc4mobx/hrmSalary/pages/mySalaryBenefits/index.js +++ b/pc4mobx/hrmSalary/pages/mySalaryBenefits/index.js @@ -11,6 +11,7 @@ import SalaryAdjustmentRecords from "./components/SalaryAdjustmentRecords"; import { MonthRangePicker } from "../reportView/components/statisticalMicroSettingsSlide"; import moment from "moment"; import "./index.less"; +import LogDialog from "../../components/logViewModal"; const getLabel = WeaLocaleProvider.getLabel; @@ -18,9 +19,9 @@ class Index extends Component { constructor(props) { super(props); this.state = { - selectedKey: "1", + selectedKey: "1", logDialogVisible: false, salaryYearMonth: [ - moment().subtract(1, 'year').startOf("year").format("YYYY-MM"), + moment().subtract(1, "year").startOf("year").format("YYYY-MM"), moment().endOf("year").format("YYYY-MM") ] }; @@ -41,9 +42,18 @@ class Index extends Component { } return Dom; }; + onDropMenuClick = (key) => { + switch (key) { + case "log": + this.setState({ logDialogVisible: true }); + break; + default: + break; + } + }; render() { - const { selectedKey, salaryYearMonth } = this.state; + const { selectedKey, salaryYearMonth, logDialogVisible } = this.state; const tabs = [ { key: "1", title: getLabel(111, "工资单") }, { key: "2", title: getLabel(543150, "调薪记录") } @@ -61,8 +71,18 @@ class Index extends Component { iconBgcolor="#F14A2D" tabDatas={tabs} className="mySalary_wrapper" buttons={selectedKey === "1" ? btns : []} buttonSpace={10} selectedKey={selectedKey} onChange={selectedKey => this.setState({ selectedKey })} + showDropIcon onDropMenuClick={this.onDropMenuClick} + dropMenuDatas={[ + { + key: "log", icon: , + content: getLabel(545781, "操作日志") + } + ]} > {this.renderContent()} + {/*操作日志*/} + this.setState({ logDialogVisible: false })}/> ); } From 4b95f6811fdacca262467c5c5b030abff69a8be1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Mon, 19 Feb 2024 09:03:40 +0800 Subject: [PATCH 011/127] =?UTF-8?q?feature/2.10.1.2401.01-=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E6=93=8D=E4=BD=9C=E6=97=A5=E5=BF=97=E6=B7=BB=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../logViewModal/components/detailLogView/index.js | 2 +- pc4mobx/hrmSalary/components/logViewModal/index.less | 4 +--- pc4mobx/hrmSalary/pages/ledgerPage/index.less | 2 +- pc4mobx/hrmSalary/pages/mySalaryBenefits/index.js | 5 +++-- 4 files changed, 6 insertions(+), 7 deletions(-) diff --git a/pc4mobx/hrmSalary/components/logViewModal/components/detailLogView/index.js b/pc4mobx/hrmSalary/components/logViewModal/components/detailLogView/index.js index 7ca588a9..f19e1c05 100644 --- a/pc4mobx/hrmSalary/components/logViewModal/components/detailLogView/index.js +++ b/pc4mobx/hrmSalary/components/logViewModal/components/detailLogView/index.js @@ -66,7 +66,7 @@ class Index extends Component { _.map(dataSource, item => (!_.isEmpty(item.valueschanges) ? (
{it.id}
-
{it.name}
+
{it.name}
)} height={scrollHeight} checkedCb={() => ({})} checkedKeys={[]} /> :
{getLabel(111, "无数据变更记录")}
)) diff --git a/pc4mobx/hrmSalary/components/logViewModal/index.less b/pc4mobx/hrmSalary/components/logViewModal/index.less index 79d0bee5..1d54174f 100644 --- a/pc4mobx/hrmSalary/components/logViewModal/index.less +++ b/pc4mobx/hrmSalary/components/logViewModal/index.less @@ -71,10 +71,8 @@ position: relative; flex: 1; min-height: 40px; + line-height: 40px; color: #000; - display: flex; - align-items: center; - justify-content: flex-start; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; diff --git a/pc4mobx/hrmSalary/pages/ledgerPage/index.less b/pc4mobx/hrmSalary/pages/ledgerPage/index.less index 36f3ec2b..2fc10db7 100644 --- a/pc4mobx/hrmSalary/pages/ledgerPage/index.less +++ b/pc4mobx/hrmSalary/pages/ledgerPage/index.less @@ -1,7 +1,7 @@ .ledgerOuter { .wea-new-top { .ant-col-10 { - span:nth-child(2) { + & > span:nth-child(2) { margin-top: -6px; } } diff --git a/pc4mobx/hrmSalary/pages/mySalaryBenefits/index.js b/pc4mobx/hrmSalary/pages/mySalaryBenefits/index.js index 3a221393..cef2bb12 100644 --- a/pc4mobx/hrmSalary/pages/mySalaryBenefits/index.js +++ b/pc4mobx/hrmSalary/pages/mySalaryBenefits/index.js @@ -9,9 +9,9 @@ import { WeaLocaleProvider, WeaReqTop } from "ecCom"; import Payroll from "./components/payrollTable"; import SalaryAdjustmentRecords from "./components/SalaryAdjustmentRecords"; import { MonthRangePicker } from "../reportView/components/statisticalMicroSettingsSlide"; +import LogDialog from "../../components/logViewModal"; import moment from "moment"; import "./index.less"; -import LogDialog from "../../components/logViewModal"; const getLabel = WeaLocaleProvider.getLabel; @@ -65,6 +65,7 @@ class Index extends Component { onChange={v => this.setState({ salaryYearMonth: v })}/>
]; + const logFunction = selectedKey === "1" ? "mysalarybill" : "myadjustrecord"; return ( } @@ -81,7 +82,7 @@ class Index extends Component { > {this.renderContent()} {/*操作日志*/} - this.setState({ logDialogVisible: false })}/> ); From 0e16bab13ce33d2ee46a8a19a418d32af9030d26 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Tue, 20 Feb 2024 17:03:51 +0800 Subject: [PATCH 012/127] =?UTF-8?q?feature/2.10.1.2401.01-=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E6=93=8D=E4=BD=9C=E6=97=A5=E5=BF=97=E6=B7=BB=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pages/dataAcquisition/specialAddDeduction/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/specialAddDeduction/index.js b/pc4mobx/hrmSalary/pages/dataAcquisition/specialAddDeduction/index.js index 5b4cd8f7..d743bfb7 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/specialAddDeduction/index.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/specialAddDeduction/index.js @@ -457,7 +457,7 @@ class Index extends Component { onResizeWindowInnerWidth={this.handleResize} slidePayload={slidePayload} onClose={this.handleCloseSlide} onSave={this.handleSaveData} slideLoading={saveLoading} exportPayloadUrl={exportPayloadUrl} - exportPayloadType={exportPayloadType} + exportPayloadType={exportPayloadType} logFunction="specialAddDeduction" form={advanceForm} condition={advanceCondition} onAdSearch={this.handleAdSearch} onImportSetStep={this.handleImportSetStep} onCancel={this.handleCloseImport} importPayload={importPayload} onImportFile={this.handleImportFile} From 7078b1c6c4bb83c5437f19780a7b673854ab4687 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Fri, 23 Feb 2024 10:13:43 +0800 Subject: [PATCH 013/127] =?UTF-8?q?feature/2.10.1.2401.01-=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E6=93=8D=E4=BD=9C=E6=97=A5=E5=BF=97=E6=B7=BB=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pc4mobx/hrmSalary/apis/index.js | 5 ++-- pc4mobx/hrmSalary/apis/standingBook.js | 2 +- .../components/logViewModal/index.js | 18 ++++++------ .../pages/adjustSalaryManage/index.js | 22 ++++++++++----- .../components/conditions.js | 5 +++- .../components/employeeDetails.js | 10 +++++-- .../components/reportList.js | 3 ++ .../pages/analysisOfSalaryStatistics/index.js | 15 ++++++---- .../hrmSalary/pages/calculate/calculate.js | 15 +++++++--- .../components/calculateTablelist/index.js | 3 +- .../components/attendanceDataComp.js | 27 ++++++++++++++++-- .../attendance/components/fieldMangComp.js | 14 ++++++++-- .../pages/dataAcquisition/attendance/index.js | 15 ++++++---- .../pages/dataAcquisition/cumDeduct/index.js | 8 ++++-- .../dataAcquisition/cumSituation/index.js | 11 ++++---- .../pages/dataAcquisition/dataTables.js | 17 ++++++++++- .../hrmSalary/pages/dataAcquisition/layout.js | 26 ++++++++++++----- .../dataAcquisition/otherDeduct/index.js | 8 ++++-- .../specialAddDeduction/index.js | 8 ++++-- .../components/declareTablelist/index.js | 18 +++++++++++- pc4mobx/hrmSalary/pages/declare/declare.js | 16 +++++++---- .../pages/externalPersonManage/index.js | 15 ++++++---- .../fieldManagement/components/fieldTable.js | 17 +++++++++-- .../hrmSalary/pages/fieldManagement/index.js | 17 +++++++---- .../ledgerPage/components/ledgerTable.js | 8 +++++- pc4mobx/hrmSalary/pages/ledgerPage/index.js | 16 +++++++---- .../SalaryAdjustmentRecords/index.js | 7 ++++- .../components/payrollTable/index.js | 10 +++++-- .../hrmSalary/pages/mySalaryBenefits/index.js | 18 +++++++----- .../components/salaryFileList/index.js | 6 +++- .../pages/payrollFiles/salaryFiles.js | 14 ++++++---- .../components/grantTableList/index.js | 11 +++++++- .../payrollTemplateTableList/index.js | 4 +++ .../hrmSalary/pages/payrollRelease/index.js | 17 +++++++---- pc4mobx/hrmSalary/pages/salaryItem/index.js | 20 ++++++++----- .../components/welfareRecordList.js | 8 ++++-- .../standingBook/standingBook.js | 16 +++++++---- .../components/welfareTableList/index.js | 6 +++- .../welfareArchive/index.js | 14 ++++++---- .../components/welfarePlanList/index.js | 15 ++++++++++ .../welfarePlan/index.js | 18 +++++++----- pc4mobx/hrmSalary/pages/taxAgent/index.js | 28 +++++++++++++++---- 42 files changed, 399 insertions(+), 152 deletions(-) diff --git a/pc4mobx/hrmSalary/apis/index.js b/pc4mobx/hrmSalary/apis/index.js index af60888f..eabea534 100644 --- a/pc4mobx/hrmSalary/apis/index.js +++ b/pc4mobx/hrmSalary/apis/index.js @@ -23,9 +23,8 @@ export const getTableDatas = (params) => { //获取日志列表 export const getLogs = params => { const payload = { - ...params, module: "hrsa", dataset: "dataset", authParams: "{}", - filterConditions: "[]", transMethod: "hrsa", - showColums: "[{\"columName\":\"操作时间\",\"columIndex\":\"createdate\",\"width\":\"5%\"},{\"columName\":\"操作人\",\"columIndex\":\"operatorname\",\"width\":\"2%\"},{\"columName\":\"操作类型\",\"columIndex\":\"operatetypename\",\"width\":\"5%\"},{\"columName\":\"项目\",\"columIndex\":\"modulenamespan\",\"width\":\"3%\"},{\"columName\":\"对象\",\"columIndex\":\"targetname\",\"width\":\"4%\"},{\"columName\":\"修改详情\",\"columIndex\":\"operatedesc\",\"width\":\"2%\"},{\"columName\":\"客户端IP\",\"columIndex\":\"clientip\",\"width\":\"5%\"}]" + ...params, module: "hrsa", dataset: "dataset", authParams: "{}", transMethod: "hrsa", + showColums: "[{\"columName\":\"操作时间\",\"columIndex\":\"createdate\",\"width\":\"5%\"},{\"columName\":\"操作人\",\"columIndex\":\"operatorname\",\"width\":\"2%\"},{\"columName\":\"操作类型\",\"columIndex\":\"operatetypename\",\"width\":\"5%\"},{\"columName\":\"对象\",\"columIndex\":\"targetname\",\"width\":\"4%\"},{\"columName\":\"修改详情\",\"columIndex\":\"operatedesc\",\"width\":\"2%\"},{\"columName\":\"客户端IP\",\"columIndex\":\"clientip\",\"width\":\"5%\"}]" }; return postFetch("/api/bs/hrmsalary/elog/getLogs", payload); }; diff --git a/pc4mobx/hrmSalary/apis/standingBook.js b/pc4mobx/hrmSalary/apis/standingBook.js index 8cf772a5..c4ae0be0 100644 --- a/pc4mobx/hrmSalary/apis/standingBook.js +++ b/pc4mobx/hrmSalary/apis/standingBook.js @@ -43,7 +43,7 @@ export const inspectList = (params) => { }; //社会福利台账-删除正常缴纳人员 export const siaccountCommonDelete = (params) => { - return postFetch("/api/bs/hrmsalary/siaccount/common/delete", params); + return postFetch("/api/bs/hrmsalary/siaccount/supplementary/delete", params); }; //社会福利台账-添加正常缴纳人员 export const siaccountCommonSave = (params) => { diff --git a/pc4mobx/hrmSalary/components/logViewModal/index.js b/pc4mobx/hrmSalary/components/logViewModal/index.js index 857ed362..1867b765 100644 --- a/pc4mobx/hrmSalary/components/logViewModal/index.js +++ b/pc4mobx/hrmSalary/components/logViewModal/index.js @@ -35,7 +35,7 @@ class Index extends Component { } componentWillReceiveProps(nextProps, nextContext) { - if (nextProps.visible !== this.props.visible && nextProps.visible) this.getLogs(); + if (nextProps.visible !== this.props.visible && nextProps.visible) this.getLogs({}, nextProps); if (nextProps.visible !== this.props.visible && !nextProps.visible) { this.setState({ dataSource: [], columns: [], pageInfo: { current: 0, pageSize: 10, total: 0 }, @@ -44,12 +44,12 @@ class Index extends Component { } } - getLogs = (extra = {}) => { - const { pageInfo, logDetailDialog } = this.state; - const { baseFormStore: { form }, logFunction } = this.props; + getLogs = (extra = {}, props) => { + const { pageInfo } = this.state; + const { baseFormStore: { form }, logFunction, filterConditions } = props; const payload = { ...pageInfo, ...extra, searchMap: { ...form.getFormParams() }, - function: logFunction, showColums: "" + function: logFunction, showColums: "", filterConditions }; this.setState({ loading: true }); API.getLogs(payload).then(({ status, data }) => { @@ -86,12 +86,12 @@ class Index extends Component { onShowSizeChange: (current, pageSize) => { this.setState({ pageInfo: { ...pageInfo, current, pageSize } - }, () => this.getLogs()); + }, () => this.getLogs({}, this.props)); }, onChange: current => { this.setState({ pageInfo: { ...pageInfo, current } - }, () => this.getLogs()); + }, () => this.getLogs({}, this.props)); } }; const scrollHeight = this.logRef ? this.logRef.state.height - 254 : 606.6; @@ -111,9 +111,9 @@ class Index extends Component { }} >
- {renderLogSearchsForm(form, conditions, () => this.getLogs({ current: 1 }), () => { + {renderLogSearchsForm(form, conditions, () => this.getLogs({ current: 1 }, this.props), () => { form.resetForm(); - this.getLogs({ current: 1 }); + this.getLogs({ current: 1 }, this.props); })} { + columns: [..._.map(columns, o => { if (o.dataIndex === "username") { return { ...o, width: 150, fixed: "left" }; } return { ...o, width: 150 }; - }) + }), { + dataIndex: "options", title: getLabel(30585, "操作"), + width: 120, render: (_, record) => ( this.onDropMenuClick("log", record.id)}>{getLabel(545781, "操作日志")}) + }] }); } }).catch(() => this.setState({ loading: false })); @@ -88,10 +93,13 @@ class Index extends Component { } this.handleDebounce(); }; - onDropMenuClick = (key) => { + onDropMenuClick = (key, targetid = "") => { switch (key) { case "log": - this.setState({ logDialogVisible: true }); + this.setState({ + logDialogVisible: true, + filterConditions: targetid ? `[{\"connectCondition\":\"AND\",\"columIndex\":\"targetid\",\"type\":\"=\",\"value\":\"${targetid}\"}]` : "[]" + }); break; default: break; @@ -99,7 +107,7 @@ class Index extends Component { }; render() { - const { loading, dataSource, columns, pageInfo, showSearchAd, logDialogVisible } = this.state; + const { loading, dataSource, columns, pageInfo, showSearchAd, logDialogVisible, filterConditions } = this.state; const pagination = { ...pageInfo, showTotal: total => `${getLabel(18609, "共")} ${total} ${getLabel(18256, "条")}`, @@ -145,7 +153,7 @@ class Index extends Component { pagination={pagination} columns={columns} /> {/*操作日志*/} - this.setState({ logDialogVisible: false })}/> ); diff --git a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/conditions.js b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/conditions.js index fe2554e4..080dd0e4 100644 --- a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/conditions.js +++ b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/conditions.js @@ -27,7 +27,10 @@ export const condition = [ labelcol: 6, options: [], rules: "required|string", - viewAttr: 3 + viewAttr: 3, + otherParams: { + showSearch: true, optionFilterProp: "children" + } }, { colSpan: 1, diff --git a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/employeeDetails.js b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/employeeDetails.js index dc89547d..17a73140 100644 --- a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/employeeDetails.js +++ b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/employeeDetails.js @@ -52,10 +52,14 @@ class EmployeeDetails extends Component { columns: [...columns, { title: "操作", dataIndex: "operate", - width: 80, + width: 120, render: (_, record) => { - return {getLabel(111, "查看")}; + return + {getLabel(111, "查看")} + this.props.onFilterLog("log", record.id)}>{getLabel(545781, "操作日志")} + ; } }] }); diff --git a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/reportList.js b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/reportList.js index ba66eec2..dccae63f 100644 --- a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/reportList.js +++ b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/reportList.js @@ -44,6 +44,8 @@ class ReportList extends Component { message.error(errormsg); } }); + } else if (key === "log") { + this.props.onFilterLog(key, id); } }; reportStatisticsReportDelete = (payload) => { @@ -106,6 +108,7 @@ class ReportList extends Component { {getLabel(111, "编辑")} {getLabel(77, "复制")} {getLabel(111, "删除")} + {getLabel(545781, "操作日志")} }> diff --git a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/index.js b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/index.js index 3461e431..3666ec39 100644 --- a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/index.js +++ b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/index.js @@ -43,7 +43,7 @@ class Index extends Component { title: "", visible: false, typeKey: "", id: "" }, - logDialogVisible: false + logDialogVisible: false, filterConditions: "[]" }; } @@ -245,10 +245,13 @@ class Index extends Component { initTable && this.dimensionTableRef.dimensionList(); }); }; - onDropMenuClick = (key) => { + onDropMenuClick = (key, targetid = "") => { switch (key) { case "log": - this.setState({ logDialogVisible: true }); + this.setState({ + logDialogVisible: true, + filterConditions: targetid ? `[{\"connectCondition\":\"AND\",\"columIndex\":\"targetid\",\"type\":\"=\",\"value\":\"${targetid}\"}]` : "[]" + }); break; default: break; @@ -259,7 +262,7 @@ class Index extends Component { const { taxAgentStore: { statisticsReportBtn }, attendanceStore: { statisticsForm, reportForm } } = this.props; const { selectedKey, modalReq, slideReq, conditions, reportConditions, - reportName, keyword, year, logDialogVisible + reportName, keyword, year, logDialogVisible, filterConditions } = this.state; const buttons = selectedKey === "statistics" ? [ , @@ -303,9 +306,11 @@ class Index extends Component { ref={dom => this.reportListRef = dom} reportName={reportName} onEdit={this.handleReqBtnsClick} + onFilterLog={(type, targetid) => this.onDropMenuClick(type, targetid)} /> : this.employeeListRef = dom} keyword={keyword} year={year} + onFilterLog={(type, targetid) => this.onDropMenuClick(type, targetid)} /> } {/*操作日志*/} - this.setState({ logDialogVisible: false })}/> ); diff --git a/pc4mobx/hrmSalary/pages/calculate/calculate.js b/pc4mobx/hrmSalary/pages/calculate/calculate.js index 6045ec6f..e6207394 100644 --- a/pc4mobx/hrmSalary/pages/calculate/calculate.js +++ b/pc4mobx/hrmSalary/pages/calculate/calculate.js @@ -166,14 +166,21 @@ class Calculate extends Component { } }); break; + case "log": + //操作日志 + this.onDropMenuClick(key, record.id); + break; default: break; } }; - onDropMenuClick = (key) => { + onDropMenuClick = (key, targetid = "") => { switch (key) { case "log": - this.setState({ logDialogVisible: true }); + this.setState({ + logDialogVisible: true, + filterConditions: targetid ? `[{\"connectCondition\":\"AND\",\"columIndex\":\"targetid\",\"type\":\"=\",\"value\":\"${targetid}\"}]` : "[]" + }); break; default: break; @@ -181,7 +188,7 @@ class Calculate extends Component { }; render() { - const { queryParams, isRefresh, calcDaialog, progressModule, logDialogVisible } = this.state; + const { queryParams, isRefresh, calcDaialog, progressModule, logDialogVisible, filterConditions } = this.state; return ( } iconBgcolor="#F14A2D" buttons={this.renderCalculateOpts()} className="calculate-main-layout" showDropIcon @@ -202,7 +209,7 @@ class Calculate extends Component { }, () => bool === "refresh" && window.open(`/spa/hrmSalary/static/index.html#/main/hrmSalary/calculate/${id}`))} /> {/*操作日志*/} - this.setState({ logDialogVisible: false })}/> {/* 归档进度条*/} { diff --git a/pc4mobx/hrmSalary/pages/calculate/components/calculateTablelist/index.js b/pc4mobx/hrmSalary/pages/calculate/components/calculateTablelist/index.js index 626eba5b..eecfa1db 100644 --- a/pc4mobx/hrmSalary/pages/calculate/components/calculateTablelist/index.js +++ b/pc4mobx/hrmSalary/pages/calculate/components/calculateTablelist/index.js @@ -72,7 +72,8 @@ class Index extends Component { /> , render: (__, record) => { - const { operate = [] } = record; + const { operate: opts = [] } = record; + const operate = [...opts, { index: "log", text: getLabel(30586, "查看日志") }]; return { _.map(operate.slice(0, 2), f => ( diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceDataComp.js b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceDataComp.js index 2395f7f1..cd8ec31a 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceDataComp.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceDataComp.js @@ -5,8 +5,8 @@ * Date: 2023/2/24 */ import React, { Component } from "react"; -import { WeaTable } from "ecCom"; -import { message, Modal } from "antd"; +import { WeaLocaleProvider, WeaTable } from "ecCom"; +import { Dropdown, Menu, message, Modal } from "antd"; import { deleteAttendance, getAttendanceFieldSettingList, @@ -28,6 +28,8 @@ import SelectItemsWrapper from "../../../../components/selectItemsModal/selectIt import AttendanceRefrenceDataModal from "./attendanceRefrenceDataModal"; import AttendanceDataViewSlide from "./attendanceDataViewSlide"; +const getLabel = WeaLocaleProvider.getLabel; + class AttendanceDataComp extends Component { constructor(props) { super(props); @@ -364,7 +366,26 @@ class AttendanceDataComp extends Component { ); diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/fieldMangComp.js b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/fieldMangComp.js index 687c6482..fd9f744e 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/fieldMangComp.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/fieldMangComp.js @@ -5,13 +5,15 @@ * Date: 2023/2/24 */ import React, { Component } from "react"; -import { WeaCheckbox, WeaTable } from "ecCom"; +import { WeaCheckbox, WeaLocaleProvider, WeaTable } from "ecCom"; import { Col, message, Row } from "antd"; import AttendanceCustomFieldsModal from "./attendanceCustomFieldsModal"; import { getAttendanceFieldList, updateAttendanceFieldStatus } from "../../../../apis/attendance"; import TipLabel from "../../../../components/TipLabel"; import { fieldsColumns } from "../columns"; +const getLabel = WeaLocaleProvider.getLabel; + class FieldMangComp extends Component { constructor(props) { super(props); @@ -71,7 +73,7 @@ class FieldMangComp extends Component { getColumns = () => { const { columns } = this.state; const { showOperateBtn } = this.props; - return _.map(_.filter(columns, item => !!item.display), child => ({ + return [..._.map(_.filter(columns, item => !!item.display), child => ({ ...child, render: (text, record) => { switch (child.dataIndex) { @@ -86,7 +88,13 @@ class FieldMangComp extends Component { return
; } } - })); + })), { + dataIndex: "options", + title: getLabel(30585, "操作"), + width: 120, + render: (_, record) => ( this.props.onFilterLog("log", record.id)}>{getLabel(545781, "操作日志")}) + }]; }; render() { diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.js b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.js index 6172f5e0..7f4c67c1 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.js @@ -24,7 +24,7 @@ class Index extends Component { super(props); this.state = { fieldName: "", selectedKey: "DATA", salaryMonth: [], - logDialogVisible: false + logDialogVisible: false, filterConditions: "[]" }; } @@ -68,10 +68,13 @@ class Index extends Component { visible: true, title: "引用考勤数据" }); }; - onDropMenuClick = (key) => { + onDropMenuClick = (key, targetid = "") => { switch (key) { case "log": - this.setState({ logDialogVisible: true }); + this.setState({ + logDialogVisible: true, + filterConditions: targetid ? `[{\"connectCondition\":\"AND\",\"columIndex\":\"targetid\",\"type\":\"=\",\"value\":\"${targetid}\"}]` : "[]" + }); break; default: break; @@ -79,7 +82,7 @@ class Index extends Component { }; render() { - const { selectedKey, salaryMonth, fieldName, logDialogVisible } = this.state; + const { selectedKey, salaryMonth, fieldName, logDialogVisible, filterConditions } = this.state; const { taxAgentStore: { showOperateBtn } } = this.props; const topTab = [ { title: "考勤数据", key: "DATA" }, @@ -119,18 +122,20 @@ class Index extends Component { ref={dom => this.attendanceTableRef = dom} showOperateBtn={showOperateBtn} salaryYearMonth={salaryMonth} + onFilterLog={(type, targetid) => this.onDropMenuClick(type, targetid)} /> : this.fieldMangRef = dom} showOperateBtn={showOperateBtn} fieldName={fieldName} + onFilterLog={(type, targetid) => this.onDropMenuClick(type, targetid)} /> }
{/*操作日志*/} this.setState({ logDialogVisible: false })}/> + onCancel={() => this.setState({ logDialogVisible: false })} filterConditions={filterConditions}/>
); diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js b/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js index 98d9f374..5c3658fb 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js @@ -66,7 +66,8 @@ class Index extends Component { }, exportPayloadUrl: "", exportPayloadType: false, - advanceCondition: null + advanceCondition: null, + targetid: "" }; this.tableRef = null; this.addItemRef = null; @@ -358,7 +359,7 @@ class Index extends Component { const { id } = record; key === "handleAddData" ? getAddUpDeduction({ id }).then(({ status, data }) => { if (status) this[key]("编辑", data); - }) : this[key](record); + }) : key === "log" ? this.setState({ targetid: id }) : this[key](record); }; handleCloseSlide = () => { const { slidePayload } = this.state; @@ -540,7 +541,7 @@ class Index extends Component { const { taxAgentStore: { showOperateBtn }, cumDeductStore: { form } } = this.props; const { declareMonth, taxAgentId, slidePayload, saveLoading, exportPayloadUrl, advanceCondition, - importPayload, exportPayloadType + importPayload, exportPayloadType, targetid } = this.state; const tablePayload = { declareMonth: [declareMonth], taxAgentId }; return ( @@ -553,6 +554,7 @@ class Index extends Component { onImportSetStep={this.handleImportSetStep} onCancel={this.handleCloseImport} importPayload={importPayload} onImportFile={this.handleImportFile} onPreviewImport={this.handlePreviewImport} detailOptBtns={this.getDetailOptBtns()} + targetid={targetid} onClearTargrtid={() => this.setState({ targetid: "" })} columns={modalColumns} > { if (status) this[key]("编辑", data); - }) : this.deleteSelectAddUpSituation(record); + }) : key === "log" ? this.setState({ targetid: id }) : this.deleteSelectAddUpSituation(record); }; /* * Author: 黎永顺 @@ -544,7 +545,7 @@ class Index extends Component { const { taxAgentStore: { showOperateBtn }, cumSituationStore: { form } } = this.props; const { declareMonth, taxAgentId, slidePayload, saveLoading, exportPayloadUrl, advanceCondition, - importPayload, year, exportPayloadType + importPayload, year, exportPayloadType, targetid } = this.state; const tablePayload = { taxYearMonth: `${year}-${declareMonth}`, year, taxAgentId }; return ( @@ -556,9 +557,9 @@ class Index extends Component { form={form} condition={advanceCondition} onAdSearch={this.handleAdSearch} onImportSetStep={this.handleImportSetStep} onCancel={this.handleCloseImport} importPayload={{ ...importPayload, importOpts: { taxYearMonth: importPayload.importOpts.declareMonth } }} - onImportFile={this.handleImportFile} + onImportFile={this.handleImportFile} columns={situationModalColumns} onPreviewImport={this.handlePreviewImport} detailOptBtns={this.getDetailOptBtns()} - columns={situationModalColumns} + targetid={targetid} onClearTargrtid={() => this.setState({ targetid: "" })} > this.tableRef = dom} diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/dataTables.js b/pc4mobx/hrmSalary/pages/dataAcquisition/dataTables.js index de207b22..742c7894 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/dataTables.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/dataTables.js @@ -8,6 +8,9 @@ import React, { Component } from "react"; import UnifiedTable from "../../components/UnifiedTable"; import { getTableDate } from "../../apis/cumDeduct"; import { Menu, Popover } from "antd"; +import { WeaLocaleProvider } from "ecCom"; + +const getLabel = WeaLocaleProvider.getLabel; class DataTables extends Component { constructor(props) { @@ -118,6 +121,7 @@ class DataTables extends Component { placement="bottomRight" content={ onTableOperate(e, record)}> 删除 + {getLabel(545781, "操作日志")} } title=""> @@ -132,8 +136,19 @@ class DataTables extends Component { onTableOperate({ key: "handleAddData" }, record)}>编辑 - onTableOperate({ key: "deleteSelectAddUpDeduction" }, record)}>删除 + { + showOperateBtn && + onTableOperate(e, record)}> + {getLabel(545781, "操作日志")} + } title=""> + + + } } diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/layout.js b/pc4mobx/hrmSalary/pages/dataAcquisition/layout.js index 1cee5ed6..587f2785 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/layout.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/layout.js @@ -22,7 +22,7 @@ class Layout extends Component { constructor(props) { super(props); this.state = { - showSearchAd: false, logDialogVisible: false + showSearchAd: false, logDialogVisible: false, filterConditions: "[]" }; } @@ -42,6 +42,15 @@ class Layout extends Component { */ window.open(nextProps.exportPayloadUrl, "_self"); } + if (nextProps.targetid !== this.props.targetid && nextProps.targetid) { + /* + * Author: 黎永顺 + * Description:操作日志 + * Params: + * Date: 2023/2/20 + */ + this.onDropMenuClick("log", nextProps.targetid); + } } componentWillUnmount() { @@ -52,10 +61,13 @@ class Layout extends Component { const { onResizeWindowInnerWidth } = this.props; onResizeWindowInnerWidth(window.innerWidth); }; - onDropMenuClick = (key) => { + onDropMenuClick = (key, targetid = "") => { switch (key) { case "log": - this.setState({ logDialogVisible: true }); + this.setState({ + logDialogVisible: true, + filterConditions: targetid ? `[{\"connectCondition\":\"AND\",\"columIndex\":\"targetid\",\"type\":\"=\",\"value\":\"${targetid}\"}]` : "[]" + }); break; default: break; @@ -63,12 +75,12 @@ class Layout extends Component { }; render() { - const { showSearchAd, logDialogVisible } = this.state; + const { showSearchAd, logDialogVisible, filterConditions } = this.state; const { title, btns, leftComp, children, taxAgentStore: { showOperateBtn }, slidePayload, onClose, onSave, slideLoading, form, condition, onAdSearch, onCancel, importPayload, onImportSetStep, onImportFile, - onPreviewImport, detailOptBtns, columns, logFunction + onPreviewImport, detailOptBtns, columns, logFunction, onClearTargrtid } = this.props; const { visible, title: subtitle, children: slideChildren } = slidePayload; const { @@ -143,8 +155,8 @@ class Layout extends Component { onClose={onClose} /> {/*操作日志*/} - this.setState({ logDialogVisible: false })}/> + this.setState({ logDialogVisible: false }, () => onClearTargrtid())}/>
); diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/otherDeduct/index.js b/pc4mobx/hrmSalary/pages/dataAcquisition/otherDeduct/index.js index 2795207c..208534b0 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/otherDeduct/index.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/otherDeduct/index.js @@ -64,7 +64,8 @@ class Index extends Component { }, exportPayloadUrl: "", exportPayloadType: false, - advanceCondition: null + advanceCondition: null, + targetid: "" }; this.tableRef = null; this.addItemRef = null; @@ -190,7 +191,7 @@ class Index extends Component { const { id } = record; key === "handleAddData" ? getData({ id }).then(({ status, data }) => { if (status) this[key]("编辑", data); - }) : this.deleteSelectData(record); + }) : key === "log" ? this.setState({ targetid: id }) : this.deleteSelectData(record); }; /* * Author: 黎永顺 @@ -538,7 +539,7 @@ class Index extends Component { const { taxAgentStore: { showOperateBtn }, otherDeductStore: { form } } = this.props; const { declareMonth, taxAgentId, slidePayload, saveLoading, exportPayloadUrl, advanceCondition, - importPayload, exportPayloadType + importPayload, exportPayloadType, targetid } = this.state; const tablePayload = { declareMonth: [declareMonth], taxAgentId }; return ( @@ -551,6 +552,7 @@ class Index extends Component { onImportSetStep={this.handleImportSetStep} onCancel={this.handleCloseImport} importPayload={importPayload} onImportFile={this.handleImportFile} onPreviewImport={this.handlePreviewImport} detailOptBtns={this.getDetailOptBtns()} + targetid={targetid} onClearTargrtid={() => this.setState({ targetid: "" })} columns={otherModalColumns} > { if (status) this[key]("编辑", data); - }) : this.specialAddDeductionDeleteSelectData(record); + }) : key === "log" ? this.setState({ targetid: id }) : this.specialAddDeductionDeleteSelectData(record); }; handleCloseSlide = () => { const { slidePayload } = this.state; @@ -449,7 +450,7 @@ class Index extends Component { const { taxAgentStore: { showOperateBtn }, specialAddStore: { advanceForm } } = this.props; const { taxAgentId, slidePayload, saveLoading, exportPayloadUrl, advanceCondition, importPayload, - exportPayloadType + exportPayloadType, targetid } = this.state; const tablePayload = { taxAgentId }; return ( @@ -462,6 +463,7 @@ class Index extends Component { onImportSetStep={this.handleImportSetStep} onCancel={this.handleCloseImport} importPayload={importPayload} onImportFile={this.handleImportFile} onPreviewImport={this.handlePreviewImport} detailOptBtns={[]} + targetid={targetid} onClearTargrtid={() => this.setState({ targetid: "" })} columns={specialModalColumns} > {getLabel(83110, "查看详情")} + { + !showWithDrawBtn && this.props.onFilterLog("log", record.id)}>{getLabel(545781, "操作日志")} + } { showWithDrawBtn && } + { + showWithDrawBtn && + + this.props.onFilterLog("log", record.id)}>{getLabel(545781, "操作日志")} + + + }> + + + } ; } } diff --git a/pc4mobx/hrmSalary/pages/declare/declare.js b/pc4mobx/hrmSalary/pages/declare/declare.js index 51910f80..dfdc681e 100644 --- a/pc4mobx/hrmSalary/pages/declare/declare.js +++ b/pc4mobx/hrmSalary/pages/declare/declare.js @@ -31,7 +31,7 @@ class Calculate extends Component { ] }, isRefresh: false, declareDaialog: { visible: false, title: "" }, - logDialogVisible: false + logDialogVisible: false, filterConditions: "[]" }; this.handleDebounce = null; } @@ -59,10 +59,13 @@ class Calculate extends Component { ]; return !showOperateBtn ? calculateOpts.slice(1) : calculateOpts; }; - onDropMenuClick = (key) => { + onDropMenuClick = (key, targetid = "") => { switch (key) { case "log": - this.setState({ logDialogVisible: true }); + this.setState({ + logDialogVisible: true, + filterConditions: targetid ? `[{\"connectCondition\":\"AND\",\"columIndex\":\"targetid\",\"type\":\"=\",\"value\":\"${targetid}\"}]` : "[]" + }); break; default: break; @@ -70,7 +73,7 @@ class Calculate extends Component { }; render() { - const { queryParams, isRefresh, declareDaialog, logDialogVisible } = this.state; + const { queryParams, isRefresh, declareDaialog, logDialogVisible, filterConditions } = this.state; return ( } iconBgcolor="#F14A2D" buttons={this.renderCalculateOpts()} className="declare-main-layout" showDropIcon @@ -80,7 +83,8 @@ class Calculate extends Component { } ]}>
- + this.onDropMenuClick(type, targetid)}/> this.setState({ declareDaialog: { ...declareDaialog, visible: false }, @@ -88,7 +92,7 @@ class Calculate extends Component { })} /> {/*操作日志*/} - this.setState({ logDialogVisible: false })}/>
diff --git a/pc4mobx/hrmSalary/pages/externalPersonManage/index.js b/pc4mobx/hrmSalary/pages/externalPersonManage/index.js index 49319217..7a99295c 100644 --- a/pc4mobx/hrmSalary/pages/externalPersonManage/index.js +++ b/pc4mobx/hrmSalary/pages/externalPersonManage/index.js @@ -24,7 +24,7 @@ class Index extends Component { constructor(props) { super(props); this.state = { - loading: false, logDialogVisible: false, + loading: false, logDialogVisible: false, filterConditions: "[]", selectedRowKeys: [], pageInfo: { current: 1, pageSize: 10, total: 0 }, showSearchAd: false, @@ -104,10 +104,13 @@ class Index extends Component { } })); }; - onDropMenuClick = (key) => { + onDropMenuClick = (key, targetid = "") => { switch (key) { case "log": - this.setState({ logDialogVisible: true }); + this.setState({ + logDialogVisible: true, + filterConditions: targetid ? `[{\"connectCondition\":\"AND\",\"columIndex\":\"targetid\",\"type\":\"=\",\"value\":\"${targetid}\"}]` : "[]" + }); break; default: break; @@ -116,7 +119,7 @@ class Index extends Component { render() { const { - showSearchAd, externalPersonManagePayload, loading, logDialogVisible, + showSearchAd, externalPersonManagePayload, loading, logDialogVisible, filterConditions, pageInfo, selectedRowKeys, dataSource, externalPersonImportPayload } = this.state; const { @@ -197,6 +200,8 @@ class Index extends Component { this.handleAdd(id)} style={{ paddingRight: 8 }}>编辑 + this.onDropMenuClick("log", id)} + style={{ paddingRight: 8 }}>{getLabel(545781, "操作日志")} {/* this.handleDelete(id)}>删除*/} ) @@ -239,7 +244,7 @@ class Index extends Component { }
{/*操作日志*/} - this.setState({ logDialogVisible: false })}/> diff --git a/pc4mobx/hrmSalary/pages/fieldManagement/components/fieldTable.js b/pc4mobx/hrmSalary/pages/fieldManagement/components/fieldTable.js index 87af593d..ad3cd14a 100644 --- a/pc4mobx/hrmSalary/pages/fieldManagement/components/fieldTable.js +++ b/pc4mobx/hrmSalary/pages/fieldManagement/components/fieldTable.js @@ -5,11 +5,13 @@ * Date: 2023/1/19 */ import React, { Component } from "react"; -import { WeaTable } from "ecCom"; +import { WeaLocaleProvider, WeaTable } from "ecCom"; import { inject, observer } from "mobx-react"; -import { Switch } from "antd"; +import { Dropdown, Menu, Switch } from "antd"; import { salaryFieldList } from "../../../apis/fieldManage"; +const getLabel = WeaLocaleProvider.getLabel; + @inject("taxAgentStore") @observer class FieldTable extends Component { @@ -75,6 +77,17 @@ class FieldTable extends Component { record.canDelete && (showSalaryItemBtn || showOperateBtn) && onDeleteLedger(record)}>删除 } + + + this.props.onFilterLog("log", record.id)}>{getLabel(545781, "操作日志")} + + + }> + + ; }; } else { diff --git a/pc4mobx/hrmSalary/pages/fieldManagement/index.js b/pc4mobx/hrmSalary/pages/fieldManagement/index.js index f74f1288..65da711e 100644 --- a/pc4mobx/hrmSalary/pages/fieldManagement/index.js +++ b/pc4mobx/hrmSalary/pages/fieldManagement/index.js @@ -22,7 +22,7 @@ class FieldManagement extends Component { constructor(props) { super(props); this.state = { - searchVal: "", doSearch: false, logDialogVisible: false, + searchVal: "", doSearch: false, logDialogVisible: false, filterConditions: "[]", slideparams: { visible: false, title: "新建字段", @@ -69,10 +69,13 @@ class FieldManagement extends Component { } }); }; - onDropMenuClick = (key) => { + onDropMenuClick = (key, targetid = "") => { switch (key) { case "log": - this.setState({ logDialogVisible: true }); + this.setState({ + logDialogVisible: true, + filterConditions: targetid ? `[{\"connectCondition\":\"AND\",\"columIndex\":\"targetid\",\"type\":\"=\",\"value\":\"${targetid}\"}]` : "[]" + }); break; default: break; @@ -80,7 +83,7 @@ class FieldManagement extends Component { }; render() { - const { searchVal, doSearch, slideparams, logDialogVisible } = this.state; + const { searchVal, doSearch, slideparams, logDialogVisible, filterConditions } = this.state; const { taxAgentStore } = this.props; const { showSalaryItemBtn, showOperateBtn } = taxAgentStore; const btns = [ @@ -108,7 +111,9 @@ class FieldManagement extends Component { >
this.handleDeleteField([record.id])}/> + onDeleteLedger={(record) => this.handleDeleteField([record.id])} + onFilterLog={(type, targetid) => this.onDropMenuClick(type, targetid)} + /> this.setState({ @@ -121,7 +126,7 @@ class FieldManagement extends Component { onRefreshList={() => this.setState({ doSearch: !doSearch })} /> {/*操作日志*/} - this.setState({ logDialogVisible: false })}/>
diff --git a/pc4mobx/hrmSalary/pages/ledgerPage/components/ledgerTable.js b/pc4mobx/hrmSalary/pages/ledgerPage/components/ledgerTable.js index 9f842e24..68f24fde 100644 --- a/pc4mobx/hrmSalary/pages/ledgerPage/components/ledgerTable.js +++ b/pc4mobx/hrmSalary/pages/ledgerPage/components/ledgerTable.js @@ -5,13 +5,15 @@ * Date: 2022/12/7 */ import React, { Component } from "react"; -import { WeaCheckbox, WeaTable } from "ecCom"; +import { WeaCheckbox, WeaLocaleProvider, WeaTable } from "ecCom"; import { inject, observer } from "mobx-react"; import { Menu, message, Modal, Popover } from "antd"; import { changeLedgerStatus, deleteLedger, getLedgerList } from "../../../apis/ledger"; import CopyLedgerModal from "./copyLedgerModal"; import "./index.less"; +const getLabel = WeaLocaleProvider.getLabel; + @inject("taxAgentStore", "ledgerStore") @observer class LedgerTable extends Component { @@ -91,6 +93,7 @@ class LedgerTable extends Component { placement="bottomRight" content={ this.handleMenuClick(e, record)}> 删除 + {getLabel(545781, "操作日志")} } title=""> @@ -161,6 +164,9 @@ class LedgerTable extends Component { } }); break; + case "log": + this.props.onFilterLog(key, id); + break; default: break; } diff --git a/pc4mobx/hrmSalary/pages/ledgerPage/index.js b/pc4mobx/hrmSalary/pages/ledgerPage/index.js index b172e312..d053ae3b 100644 --- a/pc4mobx/hrmSalary/pages/ledgerPage/index.js +++ b/pc4mobx/hrmSalary/pages/ledgerPage/index.js @@ -22,7 +22,7 @@ class Index extends Component { constructor(props) { super(props); this.state = { - searchVal: "", doSearch: false, logDialogVisible: false, + searchVal: "", doSearch: false, logDialogVisible: false, filterConditions: "[]", slideparams: { visible: false, title: "新建账套", @@ -53,10 +53,13 @@ class Index extends Component { } }); }; - onDropMenuClick = (key) => { + onDropMenuClick = (key, targetid = "") => { switch (key) { case "log": - this.setState({ logDialogVisible: true }); + this.setState({ + logDialogVisible: true, + filterConditions: targetid ? `[{\"connectCondition\":\"AND\",\"columIndex\":\"targetid\",\"type\":\"=\",\"value\":\"${targetid}\"}]` : "[]" + }); break; default: break; @@ -64,7 +67,7 @@ class Index extends Component { }; render() { - const { logDialogVisible, doSearch, slideparams } = this.state; + const { logDialogVisible, filterConditions, doSearch, slideparams } = this.state; const { taxAgentStore } = this.props; const { showOperateBtn } = taxAgentStore; const btns = [ @@ -87,14 +90,15 @@ class Index extends Component { ]} >
- + this.onDropMenuClick(type, targetid)}/> this.setState({ doSearch: !doSearch })} /> {/*操作日志*/} - this.setState({ logDialogVisible: false })}/>
diff --git a/pc4mobx/hrmSalary/pages/mySalaryBenefits/components/SalaryAdjustmentRecords/index.js b/pc4mobx/hrmSalary/pages/mySalaryBenefits/components/SalaryAdjustmentRecords/index.js index d13cd2fe..5defd410 100644 --- a/pc4mobx/hrmSalary/pages/mySalaryBenefits/components/SalaryAdjustmentRecords/index.js +++ b/pc4mobx/hrmSalary/pages/mySalaryBenefits/components/SalaryAdjustmentRecords/index.js @@ -44,7 +44,12 @@ class Index extends Component { const { columns, list: dataSource, pageNum: current, pageSize, total } = data; this.setState({ dataSource, pageInfo: { ...pageInfo, current, pageSize, total }, - columns: _.map(columns, it => ({ ...it, width: 150 })) + columns: [..._.map(columns, it => ({ ...it, width: 150 })), { + dataIndex: "options", + title: getLabel(30585, "操作"), + width: 120, render: (_, record) => ( this.props.onFilterLog("log", record.id)}>{getLabel(545781, "操作日志")}) + }] }); } }).catch(() => this.setState({ loading: false })); diff --git a/pc4mobx/hrmSalary/pages/mySalaryBenefits/components/payrollTable/index.js b/pc4mobx/hrmSalary/pages/mySalaryBenefits/components/payrollTable/index.js index 4c882560..385cdf51 100644 --- a/pc4mobx/hrmSalary/pages/mySalaryBenefits/components/payrollTable/index.js +++ b/pc4mobx/hrmSalary/pages/mySalaryBenefits/components/payrollTable/index.js @@ -83,9 +83,13 @@ class Index extends Component { dataIndex: "options", title: getLabel(30585, "操作"), width: 120, - render: (_, record) => ({getLabel(33564, "查看")}) + render: (_, record) => ( + {getLabel(33564, "查看")} + this.props.onFilterLog("log", record.id)}>{getLabel(545781, "操作日志")} + ) }]} /> ); diff --git a/pc4mobx/hrmSalary/pages/mySalaryBenefits/index.js b/pc4mobx/hrmSalary/pages/mySalaryBenefits/index.js index cef2bb12..f7323c48 100644 --- a/pc4mobx/hrmSalary/pages/mySalaryBenefits/index.js +++ b/pc4mobx/hrmSalary/pages/mySalaryBenefits/index.js @@ -19,7 +19,7 @@ class Index extends Component { constructor(props) { super(props); this.state = { - selectedKey: "1", logDialogVisible: false, + selectedKey: "1", logDialogVisible: false, filterConditions: "[]", salaryYearMonth: [ moment().subtract(1, "year").startOf("year").format("YYYY-MM"), moment().endOf("year").format("YYYY-MM") @@ -32,20 +32,24 @@ class Index extends Component { let Dom = null; switch (selectedKey) { case "1": - Dom = ; + Dom = this.onDropMenuClick(type, targetid)}/>; break; case "2": - Dom = ; + Dom = this.onDropMenuClick(type, targetid)}/>; break; default: break; } return Dom; }; - onDropMenuClick = (key) => { + onDropMenuClick = (key, targetid = "") => { switch (key) { case "log": - this.setState({ logDialogVisible: true }); + this.setState({ + logDialogVisible: true, + filterConditions: targetid ? `[{\"connectCondition\":\"AND\",\"columIndex\":\"targetid\",\"type\":\"=\",\"value\":\"${targetid}\"}]` : "[]" + }); break; default: break; @@ -53,7 +57,7 @@ class Index extends Component { }; render() { - const { selectedKey, salaryYearMonth, logDialogVisible } = this.state; + const { selectedKey, salaryYearMonth, logDialogVisible, filterConditions } = this.state; const tabs = [ { key: "1", title: getLabel(111, "工资单") }, { key: "2", title: getLabel(543150, "调薪记录") } @@ -82,7 +86,7 @@ class Index extends Component { > {this.renderContent()} {/*操作日志*/} - this.setState({ logDialogVisible: false })}/> ); diff --git a/pc4mobx/hrmSalary/pages/payrollFiles/components/salaryFileList/index.js b/pc4mobx/hrmSalary/pages/payrollFiles/components/salaryFileList/index.js index bf3cfc17..90c6938c 100644 --- a/pc4mobx/hrmSalary/pages/payrollFiles/components/salaryFileList/index.js +++ b/pc4mobx/hrmSalary/pages/payrollFiles/components/salaryFileList/index.js @@ -109,6 +109,9 @@ class Index extends Component { } }); break; + case "log": + this.props.onFilterLog(id, params.record.id); + break; default: break; } @@ -143,7 +146,8 @@ class Index extends Component { "删除待办": getLabel(543181, "删除待办"), "查看": getLabel(33564, "查看"), "取消停薪": getLabel(543309, "取消停薪"), "共": getLabel(18609, "共"), "条": getLabel(18256, "条"), "设为发薪人员": getLabel(543308, "设为发薪人员"), - "停薪": getLabel(542692, "停薪"), "编辑": getLabel(501169, "编辑") + "停薪": getLabel(542692, "停薪"), "编辑": getLabel(501169, "编辑"), + "操作日志": getLabel(545781, "操作日志") }; const childFrameObj = document.getElementById("atdTable"); childFrameObj.contentWindow.postMessage(JSON.stringify({ ...payload, i18n }), "*"); diff --git a/pc4mobx/hrmSalary/pages/payrollFiles/salaryFiles.js b/pc4mobx/hrmSalary/pages/payrollFiles/salaryFiles.js index eaaf5a24..3306e038 100644 --- a/pc4mobx/hrmSalary/pages/payrollFiles/salaryFiles.js +++ b/pc4mobx/hrmSalary/pages/payrollFiles/salaryFiles.js @@ -30,7 +30,7 @@ class SalaryFiles extends Component { selectedKey: "pending", showSearchAd: false, isQuery: false, showDelSalaryFileBtn: false, topTabCount: { PENDING: 0, FIXED: 0, SUSPEND: 0, STOP: 0, EXT: 0 }, showExtEmpsWitch: false, salaryFileImpDialog: { visible: false, title: getLabel(24023, "数据导入"), importType: "", isExtEmp: false }, - salaryImportTypes: [], logDialogVisible: false + salaryImportTypes: [], logDialogVisible: false, filterConditions: "" }; this.salaryFileListRef = null; } @@ -49,11 +49,14 @@ class SalaryFiles extends Component { handleOpenAdvanceSearch = () => this.setState({ showSearchAd: true }); handleAdvanceSearch = () => this.setState({ isQuery: !this.state.isQuery }); onAdSearch = () => this.setState({ showSearchAd: false, isQuery: !this.state.isQuery }); - onDropMenuClick = (key) => { + onDropMenuClick = (key, targetid = "") => { const { state, handleSalaryOpts } = this.salaryFileListRef.wrappedInstance || {}; switch (key) { case "log": - this.setState({ logDialogVisible: true }); + this.setState({ + logDialogVisible: true, + filterConditions: targetid ? `[{\"connectCondition\":\"AND\",\"columIndex\":\"targetid\",\"type\":\"=\",\"value\":\"${targetid}\"}]` : "[]" + }); break; case "custom_cols": const { payrollFilesStore: { tableStore } } = this.props; @@ -229,7 +232,7 @@ class SalaryFiles extends Component { render() { const { selectedKey, topTabCount, showSearchAd, isQuery, showDelSalaryFileBtn, showExtEmpsWitch, - salaryFileImpDialog, salaryImportTypes, logDialogVisible + salaryFileImpDialog, salaryImportTypes, logDialogVisible, filterConditions } = this.state; const { taxAgentStore: { showOperateBtn } } = this.props; return ( @@ -260,9 +263,10 @@ class SalaryFiles extends Component { selectedKey={selectedKey} showOperateBtn={showOperateBtn} showDelSalaryFileBtn={showDelSalaryFileBtn} onChangeTopTabCount={this.queryInsuranceTabTotal} + onFilterLog={(type, targetid) => this.onDropMenuClick(type, targetid)} /> {/*操作日志*/} - this.setState({ logDialogVisible: false })}/> {/* 导入*/} { salaryAcctType === 1 && - 补发 + {getLabel(388064, "补发")} } {`${getLabel(15323, "第")}${acctTimes}${getLabel(18929, "次")}`} @@ -90,6 +90,9 @@ class Index extends Component { message.warning(getLabel(543602, "请设置默认模板")); } break; + case "log": + this.props.onFilterLog(key, id); + break; default: break; } @@ -140,11 +143,17 @@ class Index extends Component { style={{ marginRight: 10 }} target="_blank" >{getLabel(83110, "查看详情")} } + { + !canSeeDetail && + this.props.onFilterLog("log", record.id)}>{getLabel(545781, "操作日志")} + } { sendNum !== sendTotal && !showGrant && this.handleOpts(e, record)}> {getLabel(543603, "更新模板")} + {getLabel(545781, "操作日志")} } > diff --git a/pc4mobx/hrmSalary/pages/payrollRelease/components/payrollTemplateTableList/index.js b/pc4mobx/hrmSalary/pages/payrollRelease/components/payrollTemplateTableList/index.js index cb9c2402..47fe8228 100644 --- a/pc4mobx/hrmSalary/pages/payrollRelease/components/payrollTemplateTableList/index.js +++ b/pc4mobx/hrmSalary/pages/payrollRelease/components/payrollTemplateTableList/index.js @@ -115,6 +115,9 @@ class Index extends Component { } }); break; + case "log": + this.props.onFilterLog(key, id); + break; default: break; } @@ -165,6 +168,7 @@ class Index extends Component { this.handleOpts(e, record)}> {getLabel(535052, "删除")} + {getLabel(545781, "操作日志")} } > diff --git a/pc4mobx/hrmSalary/pages/payrollRelease/index.js b/pc4mobx/hrmSalary/pages/payrollRelease/index.js index 362a621e..ebc36b4e 100644 --- a/pc4mobx/hrmSalary/pages/payrollRelease/index.js +++ b/pc4mobx/hrmSalary/pages/payrollRelease/index.js @@ -32,7 +32,7 @@ class Index extends Component { moment(new Date()).subtract(1, "year").startOf("year").format("YYYY-MM"), moment(new Date()).endOf("year").format("YYYY-MM") ] - }, logDialogVisible: false + }, logDialogVisible: false, filterConditions: "[]" }; this.templateRef = null; this.baseSetRef = null; @@ -93,11 +93,13 @@ class Index extends Component { onUpdateTemp={(id) => this.setState({ selectedKey: "template" }, () => { this.templateRef.wrappedInstance.handleOpts({ key: "edit" }, { id }); })} + onFilterLog={(type, targetid) => this.onDropMenuClick(type, targetid)} />; break; case "template": dom = this.templateRef = dom} queryParams={queryParams} - isRefresh={isRefresh} forceUpdate={() => this.forceUpdate()}/>; + isRefresh={isRefresh} forceUpdate={() => this.forceUpdate()} + onFilterLog={(type, targetid) => this.onDropMenuClick(type, targetid)}/>; break; case "watermark": dom = { + onDropMenuClick = (key, targetid = "") => { switch (key) { case "log": - this.setState({ logDialogVisible: true }); + this.setState({ + logDialogVisible: true, + filterConditions: targetid ? `[{\"connectCondition\":\"AND\",\"columIndex\":\"targetid\",\"type\":\"=\",\"value\":\"${targetid}\"}]` : "[]" + }); break; default: break; @@ -121,7 +126,7 @@ class Index extends Component { }; render() { - const { selectedKey, queryParams, logDialogVisible } = this.state; + const { selectedKey, queryParams, logDialogVisible, filterConditions } = this.state; const tabs = [ { key: "grant", title: getLabel(538012, "工资单发放") }, { key: "template", title: getLabel(543575, "工资单模板设置") }, @@ -148,7 +153,7 @@ class Index extends Component {
{this.renderContent()}
{/*操作日志*/} this.setState({ logDialogVisible: false })}/> + onCancel={() => this.setState({ logDialogVisible: false })} filterConditions={filterConditions}/> ); diff --git a/pc4mobx/hrmSalary/pages/salaryItem/index.js b/pc4mobx/hrmSalary/pages/salaryItem/index.js index d808d539..edfebb4c 100644 --- a/pc4mobx/hrmSalary/pages/salaryItem/index.js +++ b/pc4mobx/hrmSalary/pages/salaryItem/index.js @@ -29,7 +29,7 @@ export default class SalaryItem extends React.Component { searchParams: { current: 1, pageSize: 10, total: 0 }, selectedRowKeys: [], syncSalarySetDialog: { visible: false, title: "", id: "" }, - logDialogVisible: false + logDialogVisible: false, filterConditions: "[]" }; columns.map(item => { if (item.dataIndex == "refere") { @@ -136,8 +136,10 @@ export default class SalaryItem extends React.Component { render: (text, record) => { return ( - this.onEditItem(record, true)}>{(showSalaryItemBtn || showOperateBtn) ? "编辑" : "查看"} + this.onEditItem(record, true)}>{(showSalaryItemBtn || showOperateBtn) ? "编辑" : "查看"} + this.onDropMenuClick("log", record.id)}>{getLabel(545781, "操作日志")} { (record.canDelete && (showSalaryItemBtn || showOperateBtn)) && { + + onDropMenuClick = (key, targetid = "") => { switch (key) { case "log": - this.setState({ logDialogVisible: true }); + this.setState({ + logDialogVisible: true, + filterConditions: targetid ? `[{\"connectCondition\":\"AND\",\"columIndex\":\"targetid\",\"type\":\"=\",\"value\":\"${targetid}\"}]` : "[]" + }); break; default: break; @@ -210,7 +216,7 @@ export default class SalaryItem extends React.Component { taxAgentStore: { showOperateBtn, showSalaryItemBtn, taxAgentOption } } = this.props; const { userStatusList } = salaryFileStore; - const { selectedRowKeys, logDialogVisible } = this.state; + const { selectedRowKeys, logDialogVisible, filterConditions } = this.state; const { loading, deleteItemRequest, getTableDatas } = salaryItemStore; const { tableDataSource, @@ -403,7 +409,7 @@ export default class SalaryItem extends React.Component { })} /> {/*操作日志*/} - this.setState({ logDialogVisible: false })}/> { systemItemVisible && diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBook/components/welfareRecordList.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBook/components/welfareRecordList.js index c5d90a68..550dd048 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBook/components/welfareRecordList.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBook/components/welfareRecordList.js @@ -105,6 +105,9 @@ class WelfareRecordList extends Component { } }); break; + case "log": + this.props.onFilterLog(id, params.id); + break; default: break; } @@ -117,7 +120,7 @@ class WelfareRecordList extends Component { "未归档": getLabel(17999, "已归档"), "操作": getLabel(30585, "操作"), "核算": getLabel(538780, "核算"), "归档": getLabel(251, "归档"), "查看": getLabel(33564, "查看"), "重新核算": getLabel(542637, "重新核算"), - "删除": getLabel(535052, "删除") + "删除": getLabel(535052, "删除"), "操作日志": getLabel(545781, "操作日志") }; const childFrameObj = document.getElementById("unitTable"); childFrameObj && childFrameObj.contentWindow.postMessage(JSON.stringify({ ...payload, i18n }), "*"); @@ -136,7 +139,8 @@ class WelfareRecordList extends Component { pageInfo: { ...pageInfo, current, pageSize, total }, dataSource, columns }, () => this.postMessageToChild({ - scrollHeight: 108, dataSource, columns, pageInfo: this.state.pageInfo, showOperateBtn + scrollHeight: 108, dataSource, columns, pageInfo: this.state.pageInfo, showOperateBtn, + unitTableType: "welfareRecord" })); } }).catch(() => this.setState({ loading: false })); diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBook/standingBook.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBook/standingBook.js index d8fa8cc0..f4089c44 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBook/standingBook.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBook/standingBook.js @@ -34,7 +34,7 @@ class StandingBook extends Component { taxAgents: "" }, progressVisible: false, progress: 0, accountDialog: { visible: false, title: "", loading: false, options: [] }, - logDialogVisible: false + logDialogVisible: false, filterConditions: "[]" }; this.wfListRef = null; this.timer = null; @@ -104,10 +104,13 @@ class StandingBook extends Component { }); } }; - onDropMenuClick = (key) => { + onDropMenuClick = (key, targetid = "") => { switch (key) { case "log": - this.setState({ logDialogVisible: true }); + this.setState({ + logDialogVisible: true, + filterConditions: targetid ? `[{\"connectCondition\":\"AND\",\"columIndex\":\"targetid\",\"type\":\"=\",\"value\":\"${targetid}\"}]` : "[]" + }); break; default: break; @@ -115,7 +118,7 @@ class StandingBook extends Component { }; render() { - const { accountDialog, queryForm, logDialogVisible } = this.state; + const { accountDialog, queryForm, logDialogVisible, filterConditions } = this.state; const { taxAgentStore: { showOperateBtn } } = this.props; const rightBtns = [, + + ]} + bottomLeft={ + + + + + } + > + { + + { + !_.isEmpty(dataSource) ? + _.map(dataSource, it => { + const { fieldId, salaryItemName, checked } = it; + return + this.setState({ itemsCheckeds: _.xorWith(itemsCheckeds, [fieldId], _.isEqual) })}/> + ; + }) : 暂无数据 + } + + } + + ); + } +} + +export default ImportHeaderSetDialog; diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/index.less b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/index.less index 2ceecea0..235eba25 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/index.less +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/index.less @@ -290,3 +290,21 @@ } } } + +//导入头部设置 +.headerSetWrapper { + .ant-modal-body { + .ant-row { + padding: 16px 25px; + } + } + + .ant-col-8 { + padding: 0 8px !important; + } + + .wea-content { + padding: 8px 16px 0; + } +} + diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/makeupDifference.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/makeupDifference.js index 057f8379..9ff5fb28 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/makeupDifference.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/makeupDifference.js @@ -13,15 +13,23 @@ import * as API from "../../../../apis/standingBook"; import { calcPageNo } from "../../../../util"; import RegList from "./regList"; import RegEditDetial from "./regEditDetial"; -import AcctResultImportModal from "../../../calculateDetail/acctResult/importModal/acctResultImportModal"; import AddCompensationPersonnelDialog from "./addCompensationPersonnelDialog"; +import StandingBookCalcImportDialog from "./standingBookCalcImportDialog"; import "./index.less"; class MakeupDifference extends Component { constructor(props) { super(props); this.state = { - selectKey: [], fieldData: {}, loading: { save: false }, importDiffModal: { visible: false }, + selectKey: [], loading: { save: false }, + importDiffModal: { + visible: false, + fieldUrl: "getBalanceWelfareList", + tmpUrl: "exportSiaccountWelfarebalanceimporttemplatetetemplate", + cacheUrl: "cacheBalanceWelfareList", + importUrl: "importBalanceInsuranceDetail", + importparams: {} + }, returnEditPersonSlide: { title: "", editId: "", visible: false }, @@ -65,7 +73,12 @@ class MakeupDifference extends Component { }); break; case "import": - this.setState({ importDiffModal: { ...importDiffModal, visible: true } }); + this.setState({ + importDiffModal: { + ...importDiffModal, visible: true, + importparams: { billMonth: getQueryString("billMonth") } + } + }); break; case "export": const url = `${window.location.origin}/api/bs/hrmsalary/welfare/balance/export?billMonth=${billMonth}&paymentOrganization=${paymentOrganization}`; @@ -103,7 +116,7 @@ class MakeupDifference extends Component { render() { const billMonth = getQueryString("billMonth"); - const { selectKey, importDiffModal, fieldData, returnEditPersonSlide, addPersonalDialog } = this.state; + const { selectKey, importDiffModal, returnEditPersonSlide, addPersonalDialog } = this.state; return (
isRefresh && this.diffListRef.recessionList())} /> {/*导入补差*/} - { - importDiffModal.visible && - this.setState({ fieldData })} - onCancel={() => { - this.setState({ importDiffModal: { ...importDiffModal, visible: false }, fieldData: {} }, () => { - const name = this.regTopRef.state.name; - this.diffListRef.recessionList({ userName: name }); - }); - }} - isStandingBook - standingBookType="difference" - /> - } + this.setState({ + importDiffModal: { ...importDiffModal, visible: false } + }, () => isInit && this.diffListRef.recessionList())}/>
diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/normal.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/normal.js index 2fe404a5..45f1a728 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/normal.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/normal.js @@ -11,7 +11,7 @@ import { WeaFormItem, WeaInput, WeaSearchGroup, WeaTab } from "ecCom"; import { calcPageNo } from "../../../../util"; import { getQueryString } from "../../../../util/url"; import ProgressModal from "../../../../components/progressModal"; -import AcctResultImportModal from "../../../calculateDetail/acctResult/importModal/acctResultImportModal"; +import StandingBookCalcImportDialog from "./standingBookCalcImportDialog"; import AdjustmentSlide from "./adjustmentSlide"; import { getCalculateProgress } from "../../../../apis/calculate"; import RegEditDetial from "./regEditDetial"; @@ -48,7 +48,8 @@ export default class NormalIndex extends Component { progress: 0, fieldData: {}, //选中的表单头信息 importParams: { //导入信息的弹框表示 - visible: false + visible: false, fieldUrl: "getWelfareList", tmpUrl: "exportSiaccountWelfareImporttemplate", + cacheUrl: "cacheWelfareListField", importUrl: "importInsuranceAcctDetail", importparams: {} }, returnEditPersonSlide: { title: "", @@ -473,7 +474,12 @@ export default class NormalIndex extends Component { ]; const btn4 = [ + onClick={() => this.setState({ + importParams: { + ...importParams, visible: true, + tmpUrl: selectedKey === "1" ? "exportSiaccountWelfareImporttemplate" : "exportSiaccountWelfaresupplyimporttemplatetemplate" + } + })}>导入数据 ]; const btn5 = [ @@ -544,29 +550,10 @@ export default class NormalIndex extends Component { progress={this.state.progress} /> {/*导入弹框*/} - { - importParams.visible && - { - this.setState({ - fieldData - }); - }} - onCancel={() => { - this.setState({ importParams: { ...importParams, visible: false }, fieldData: {} }, () => { - const { billMonth, selectedKey, paymentOrganization } = this.props; - const { current } = this.state; - selectedKey === "1" - ? this.getNormalList({ billMonth, current, paymentOrganization }) - : this.getSupplementaryList({ billMonth, current, paymentOrganization }); - }); - }} - isStandingBook - standingBookTabKey={selectedKey} - /> - } + this.setState({ + importParams: { ...importParams, visible: false } + }, () => isInit && this.handleSearch())}/> {/* table */}
diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/standingBookCalcImportDialog.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/standingBookCalcImportDialog.js new file mode 100644 index 00000000..0dc97e42 --- /dev/null +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/standingBookCalcImportDialog.js @@ -0,0 +1,136 @@ +/* + * Author: 黎永顺 + * name: 社保福利台账-核算-导入 + * Description: + * Date: 2024/3/5 + */ +import React, { Component } from "react"; +import { WeaLocaleProvider } from "ecCom"; +import { Badge, Button, message } from "antd"; +import ImportDialog from "../../../../components/importDialog"; +import ImportHeaderSetDialog from "./importHeaderSetDialog"; +import * as API from "../../../../apis/standingBook"; +import { getQueryString } from "../../../../util/url"; + +const getLabel = WeaLocaleProvider.getLabel; + +class StandingBookCalcImportDialog extends Component { + constructor(props) { + super(props); + this.state = { + headerFieldsDialog: { visible: false, itemsByGroup: [], selectItems: [] }, + importDialog: { + visible: false, title: "", nextloading: false, + link: null, importResult: {}, imageId: "", + previewUrl: "/api/bs/hrmsalary/siaccount/welfare/preview" + } + }; + } + + async componentWillReceiveProps(nextProps, nextContext) { + if (nextProps.visible !== this.props.visible && nextProps.visible) { + const { fieldUrl } = nextProps; + const { data } = await API[fieldUrl](); + this.setState({ + importDialog: { + ...this.state.importDialog, link: this.handleExportTemp, title: getLabel(24023, "数据导入") + }, + headerFieldsDialog: { + ...this.state.headerFieldsDialog, itemsByGroup: data, + selectItems: _.map(_.filter(data, k => k.checked), o => o.fieldId) + } + }); + } + this.setState({ importDialog: { ...this.state.importDialog, visible: nextProps.visible } }); + } + + handleImport = (payload) => { + const { importDialog, headerFieldsDialog: { selectItems } } = this.state; + if (_.isEmpty(selectItems)) { + message.error(getLabel(111, "请选择表头字段")); + } else { + const { importUrl, importparams = {} } = this.props; + this.setState({ importDialog: { ...importDialog, nextloading: true } }); + API[importUrl]({ ...payload, ...importparams }).then(({ data, status, errormsg }) => { + this.setState({ importDialog: { ...importDialog, nextloading: false } }); + if (status) { + this.setState({ + importDialog: { ...importDialog, ...payload, importResult: data } + }); + } else { + message.warning(errormsg); + } + }).catch(() => this.setState({ importDialog: { ...importDialog, nextloading: false } })); + } + }; + handleExportTemp = () => { + const { tmpUrl } = this.props; + const { headerFieldsDialog: { selectItems, itemsByGroup } } = this.state; + if (_.isEmpty(selectItems)) { + message.error(getLabel(111, "请选择表头字段")); + } else { + const billMonth = getQueryString("billMonth"); + const paymentOrganization = getQueryString("paymentOrganization"); + const payload = { + billMonth, + welfareNames: _.map(_.filter(itemsByGroup, k => selectItems.includes(k.fieldId)), o => o.salaryItemName), + paymentOrganization: Number(paymentOrganization) + }; + const promise = API[tmpUrl](payload); + } + }; + handleSelectedField = () => { + this.setState({ + headerFieldsDialog: { + ...this.state.headerFieldsDialog, visible: true + } + }); + }; + /* + * Author: 黎永顺 + * Description:表单选项 + * Params: + * Date: 2023/9/18 + */ + renderFormComponent = () => { + const { selectItems } = this.state.headerFieldsDialog; + return
+ + + +
; + }; + + render() { + const { importDialog, headerFieldsDialog } = this.state; + const { cacheUrl } = this.props; + return ( + + this.setState(({ + importDialog: { ...importDialog, importResult: {}, imageId: "" } + }))} + nextCallback={imageId => this.setState({ importDialog: { ...importDialog, imageId } })} + nextUplaodCallback={imageId => this.handleImport({ imageId })} + /> + {/*表头设置*/} + this.setState({ + headerFieldsDialog: { ...headerFieldsDialog, visible: false } + })} + onAdd={selectItems => this.setState({ + headerFieldsDialog: { ...headerFieldsDialog, visible: false, selectItems } + }, () => { + const { selectItems: welfareNames } = this.state.headerFieldsDialog; + const promise = API[cacheUrl]({ welfareNames }); + })} + /> + + ); + } +} + +export default StandingBookCalcImportDialog; From 87d699c59de4322524ae708639e94b34a595cc61 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Wed, 6 Mar 2024 14:04:47 +0800 Subject: [PATCH 023/127] =?UTF-8?q?feature/2.10.1.2402.01-=E7=A4=BE?= =?UTF-8?q?=E4=BF=9D=E5=8F=B0=E8=B4=A6=E5=AF=BC=E5=85=A5=E7=BC=93=E5=AD=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../standingBookDetail/components/importHeaderSetDialog.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/importHeaderSetDialog.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/importHeaderSetDialog.js index 3dd17ed2..2fe7cb3d 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/importHeaderSetDialog.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/importHeaderSetDialog.js @@ -22,6 +22,8 @@ class ImportHeaderSetDialog extends Component { componentWillReceiveProps(nextProps, nextContext) { if (nextProps.visible !== this.props.visible && nextProps.visible) { this.setState({ itemsCheckeds: nextProps.selectItems }); + } else { + this.setState({ itemsCheckeds: [], showOnlyChecked: false }); } } From fce72a71fce21b9d38bb54f15df7407380fbf651 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Wed, 6 Mar 2024 14:33:28 +0800 Subject: [PATCH 024/127] hotfix/2.10.1.2402.01 --- .../hrmSalary/pages/payroll/templateBaseSettings.js | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/payroll/templateBaseSettings.js b/pc4mobx/hrmSalary/pages/payroll/templateBaseSettings.js index d8a1eeb2..ace92ee2 100644 --- a/pc4mobx/hrmSalary/pages/payroll/templateBaseSettings.js +++ b/pc4mobx/hrmSalary/pages/payroll/templateBaseSettings.js @@ -70,8 +70,15 @@ class TemplateBaseSettings extends Component { }; salaryBillBaseSetSave = () => { const { watermark, watermarkStatus, wmSetting, ackFeedbackSetting, salaryBillViewingLimitSetting } = this.state; - const { feedBackUrl, mobileFeedbackUrl } = ackFeedbackSetting; - if (!feedBackUrl || !mobileFeedbackUrl) { + const { feedBackUrl, mobileFeedbackUrl, feedbackStatus, autoAckDays, ackStatus } = ackFeedbackSetting; + if (ackStatus === "1" && _.isNil(autoAckDays)) { + Modal.warning({ + title: getLabel(111, "信息确认"), + content: getLabel(111, "必要信息不完整,红色*为必填项!") + }); + return; + } + if (feedbackStatus === "1" && (!feedBackUrl || !mobileFeedbackUrl)) { Modal.warning({ title: getLabel(111, "信息确认"), content: getLabel(111, "必要信息不完整,红色*为必填项!") From 439ed5c822760b519e448e25e032e4e68637dd1e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Wed, 6 Mar 2024 15:19:21 +0800 Subject: [PATCH 025/127] hotfix/2.10.1.2402.01 --- pc4mobx/hrmSalary/pages/payroll/templateBaseSettings.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pc4mobx/hrmSalary/pages/payroll/templateBaseSettings.js b/pc4mobx/hrmSalary/pages/payroll/templateBaseSettings.js index ace92ee2..059b9aa3 100644 --- a/pc4mobx/hrmSalary/pages/payroll/templateBaseSettings.js +++ b/pc4mobx/hrmSalary/pages/payroll/templateBaseSettings.js @@ -106,7 +106,7 @@ class TemplateBaseSettings extends Component { render() { const { watermarkStatus, watermark, watermarkSet, ackFeedbackSetting, salaryBillViewingLimitSetting } = this.state; const { ackStatus, feedbackStatus, autoAckDays, feedBackUrl, mobileFeedbackUrl } = ackFeedbackSetting; - const { limitMonth = 0 } = salaryBillViewingLimitSetting; + const { limitMonth } = salaryBillViewingLimitSetting; return ( From f70d539ef451acba9751c580c580a718e6ca3349 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Thu, 7 Mar 2024 09:09:07 +0800 Subject: [PATCH 026/127] =?UTF-8?q?=E6=97=A5=E5=BF=97bug=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pages/socialSecurityBenefits/welfareArchive/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/index.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/index.js index 5ed371ad..f2844ef5 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/index.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/index.js @@ -66,7 +66,7 @@ class Index extends Component { } }); }; - onDropMenuClick = (key) => { + onDropMenuClick = (key, targetid = "") => { switch (key) { case "import": this.setState({ From dbc68102dd4b15f5543bba41bdcda7ffdec2a4ac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Thu, 7 Mar 2024 09:48:11 +0800 Subject: [PATCH 027/127] =?UTF-8?q?=E6=97=A5=E5=BF=97bug=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/employeeDetails.js | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/employeeDetails.js b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/employeeDetails.js index 17a73140..48816b74 100644 --- a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/employeeDetails.js +++ b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/employeeDetails.js @@ -6,6 +6,7 @@ */ import React, { Component } from "react"; import { WeaLocaleProvider, WeaTable } from "ecCom"; +import { Dropdown, Menu } from "antd"; import { statisticsEmployeeList } from "../../../apis/statistics"; import "../index.less"; @@ -57,8 +58,17 @@ class EmployeeDetails extends Component { return {getLabel(111, "查看")} - this.props.onFilterLog("log", record.id)}>{getLabel(545781, "操作日志")} + + + this.props.onFilterLog("log", record.id)}>{getLabel(545781, "操作日志")} + + + }> + + ; } }] From d1f8f5d9aa68a555b51c169a1ae331b649eaaa3f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Thu, 7 Mar 2024 10:10:04 +0800 Subject: [PATCH 028/127] =?UTF-8?q?=E8=96=AA=E9=85=AC=E6=8A=A5=E8=A1=A8?= =?UTF-8?q?=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pc4mobx/hrmSalary/apis/index.js | 5 +++++ .../reportView/components/statisticalMicroSettingsSlide.js | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/pc4mobx/hrmSalary/apis/index.js b/pc4mobx/hrmSalary/apis/index.js index eabea534..668d2591 100644 --- a/pc4mobx/hrmSalary/apis/index.js +++ b/pc4mobx/hrmSalary/apis/index.js @@ -35,3 +35,8 @@ export const getDetailChanges = params => { }; return postFetch("/api/bs/hrmsalary/elog/getDetailChanges", payload); }; +//获取薪资账套全列表 +export const getSalarysobListAll = params => { + return postFetch("/api/bs/hrmsalary/salarysob/listAll", params); +}; + diff --git a/pc4mobx/hrmSalary/pages/reportView/components/statisticalMicroSettingsSlide.js b/pc4mobx/hrmSalary/pages/reportView/components/statisticalMicroSettingsSlide.js index 8065a654..738e1fb6 100644 --- a/pc4mobx/hrmSalary/pages/reportView/components/statisticalMicroSettingsSlide.js +++ b/pc4mobx/hrmSalary/pages/reportView/components/statisticalMicroSettingsSlide.js @@ -31,7 +31,7 @@ import { } from "../../../apis/statistics"; import { commonEnumList } from "../../../apis/ruleconfig"; import { getTaxAgentSelectList } from "../../../apis/taxAgent"; -import { getPayrollTemplateLedgerList } from "../../../apis/payroll"; +import { getSalarysobListAll } from "../../../apis"; import { condition } from "./condition"; import cs from "classnames"; import "../index.less"; @@ -70,7 +70,7 @@ class StatisticalMicroSettingsSlide extends Component { } getTaxAgentSelectList = async (props) => { - const { data: salarySobList } = await getPayrollTemplateLedgerList(); + const { data: salarySobList } = await getSalarysobListAll(); getTaxAgentSelectList(true).then(({ status, data }) => { if (status) { const conditions = _.map(condition, item => { From 3b0f7bd5ce67e1658e4069196c48f66c9bc79472 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Thu, 7 Mar 2024 10:31:56 +0800 Subject: [PATCH 029/127] =?UTF-8?q?=E8=96=AA=E9=85=AC=E6=8A=A5=E8=A1=A8?= =?UTF-8?q?=E8=AE=BE=E7=BD=AE=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../reportView/components/statisticalMicroSettingsSlide.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pc4mobx/hrmSalary/pages/reportView/components/statisticalMicroSettingsSlide.js b/pc4mobx/hrmSalary/pages/reportView/components/statisticalMicroSettingsSlide.js index 738e1fb6..71baa2f7 100644 --- a/pc4mobx/hrmSalary/pages/reportView/components/statisticalMicroSettingsSlide.js +++ b/pc4mobx/hrmSalary/pages/reportView/components/statisticalMicroSettingsSlide.js @@ -85,7 +85,7 @@ class StatisticalMicroSettingsSlide extends Component { } else if (getKey(child) === "salarySob") { return { ...child, viewAttr: props.isShare ? 1 : child.viewAttr, - options: _.map(salarySobList, o => ({ key: o.id, showname: o.content })) + options: _.map(salarySobList, o => ({ key: String(o.id), showname: o.name })) }; } return { ...child, viewAttr: props.isShare ? 1 : child.viewAttr }; From e4d272481c93ac2c88335b95fef9e7424e9c74b2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Mon, 11 Mar 2024 17:19:20 +0800 Subject: [PATCH 030/127] =?UTF-8?q?hotfix/3.0.0.2403.01=20=E5=B7=A5?= =?UTF-8?q?=E8=B5=84=E5=8D=95=E8=AE=BE=E7=BD=AE=E6=B7=BB=E5=8A=A0=E5=A4=B1?= =?UTF-8?q?=E6=95=88=E8=AE=BE=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pages/payroll/templateBaseSettings.js | 18 ++++++++++++++++-- .../pages/payrollFiles/salaryFiles.js | 2 +- 2 files changed, 17 insertions(+), 3 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/payroll/templateBaseSettings.js b/pc4mobx/hrmSalary/pages/payroll/templateBaseSettings.js index 059b9aa3..ec910237 100644 --- a/pc4mobx/hrmSalary/pages/payroll/templateBaseSettings.js +++ b/pc4mobx/hrmSalary/pages/payroll/templateBaseSettings.js @@ -40,7 +40,7 @@ class TemplateBaseSettings extends Component { mobileFeedbackUrl: "" }, salaryBillViewingLimitSetting: { - limitMonth: 0 + limitMonth: 0, burningAfterReadingMin: null } }; } @@ -106,7 +106,7 @@ class TemplateBaseSettings extends Component { render() { const { watermarkStatus, watermark, watermarkSet, ackFeedbackSetting, salaryBillViewingLimitSetting } = this.state; const { ackStatus, feedbackStatus, autoAckDays, feedBackUrl, mobileFeedbackUrl } = ackFeedbackSetting; - const { limitMonth } = salaryBillViewingLimitSetting; + const { limitMonth, burningAfterReadingMin } = salaryBillViewingLimitSetting; return ( @@ -216,6 +216,20 @@ class TemplateBaseSettings extends Component { style={{ marginLeft: 10 }} placement="top"/>
+
+ {getLabel(111, "首次查看")} + this.setState({ + salaryBillViewingLimitSetting: { + ...salaryBillViewingLimitSetting, burningAfterReadingMin + } + })}/> + {getLabel(111, "分钟后无法查看工资单")} + +
); diff --git a/pc4mobx/hrmSalary/pages/payrollFiles/salaryFiles.js b/pc4mobx/hrmSalary/pages/payrollFiles/salaryFiles.js index 8ef3c6df..3c670d5c 100644 --- a/pc4mobx/hrmSalary/pages/payrollFiles/salaryFiles.js +++ b/pc4mobx/hrmSalary/pages/payrollFiles/salaryFiles.js @@ -224,7 +224,7 @@ class SalaryFiles extends Component { message.warning(getLabel(543345, "请选择需要导出的数据!")); return; } - payload = { ids: selectedRowKeys.join(",") }; + payload = { ids: selectedRowKeys.join(","), runStatusList }; } window.open(`${url}?${convertToUrlString(payload)}`, "_blank"); }; From dc49211090d08c69aa416f6781c1774b5b306400 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Wed, 13 Mar 2024 09:26:29 +0800 Subject: [PATCH 031/127] =?UTF-8?q?hotfix/3.0.0.2403.01=20=E5=B7=A5?= =?UTF-8?q?=E8=B5=84=E5=8D=95=E8=AE=BE=E7=BD=AE=E6=B7=BB=E5=8A=A0=E5=A4=B1?= =?UTF-8?q?=E6=95=88=E8=AE=BE=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pc4mobx/hrmSalary/apis/index.js | 4 ++-- pc4mobx/hrmSalary/pages/payroll/templateBaseSettings.js | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pc4mobx/hrmSalary/apis/index.js b/pc4mobx/hrmSalary/apis/index.js index 668d2591..007bb6e6 100644 --- a/pc4mobx/hrmSalary/apis/index.js +++ b/pc4mobx/hrmSalary/apis/index.js @@ -26,14 +26,14 @@ export const getLogs = params => { ...params, module: "hrsa", dataset: "dataset", authParams: "{}", transMethod: "hrsa", showColums: "[{\"columName\":\"操作时间\",\"columIndex\":\"createdate\",\"width\":\"5%\"},{\"columName\":\"操作人\",\"columIndex\":\"operatorname\",\"width\":\"2%\"},{\"columName\":\"操作类型\",\"columIndex\":\"operatetypename\",\"width\":\"5%\"},{\"columName\":\"对象\",\"columIndex\":\"targetname\",\"width\":\"4%\"},{\"columName\":\"修改详情\",\"columIndex\":\"operatedesc\",\"width\":\"2%\"},{\"columName\":\"客户端IP\",\"columIndex\":\"clientip\",\"width\":\"5%\"}]" }; - return postFetch("/api/bs/hrmsalary/elog/getLogs", payload); + return postFetch("/api/bs/hrmelog/elog/getLogs", payload); }; //获取单条操作记录的更新明细 export const getDetailChanges = params => { const payload = { ...params, module: "hrsa", detailTransMethod: "elogDemoDetail" }; - return postFetch("/api/bs/hrmsalary/elog/getDetailChanges", payload); + return postFetch("/api/bs/hrmelog/elog/getDetailChanges", payload); }; //获取薪资账套全列表 export const getSalarysobListAll = params => { diff --git a/pc4mobx/hrmSalary/pages/payroll/templateBaseSettings.js b/pc4mobx/hrmSalary/pages/payroll/templateBaseSettings.js index ec910237..9eaa2ece 100644 --- a/pc4mobx/hrmSalary/pages/payroll/templateBaseSettings.js +++ b/pc4mobx/hrmSalary/pages/payroll/templateBaseSettings.js @@ -226,7 +226,7 @@ class TemplateBaseSettings extends Component { })}/> {getLabel(111, "分钟后无法查看工资单")} From b1ddea5305f96022d50cf6e428d5bee93ef78f8c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Wed, 13 Mar 2024 11:22:54 +0800 Subject: [PATCH 032/127] =?UTF-8?q?hotfix/3.0.0.2403.01=20=E5=B7=A5?= =?UTF-8?q?=E8=B5=84=E5=8D=95=E8=AE=BE=E7=BD=AE=E6=B7=BB=E5=8A=A0=E5=A4=B1?= =?UTF-8?q?=E6=95=88=E8=AE=BE=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pc4mobx/hrmSalary/pages/adjustSalaryManage/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pc4mobx/hrmSalary/pages/adjustSalaryManage/index.js b/pc4mobx/hrmSalary/pages/adjustSalaryManage/index.js index e57ffa58..cb1b28d3 100644 --- a/pc4mobx/hrmSalary/pages/adjustSalaryManage/index.js +++ b/pc4mobx/hrmSalary/pages/adjustSalaryManage/index.js @@ -50,7 +50,7 @@ class Index extends Component { effectiveTime: effectiveTime1 ? [effectiveTime1, effectiveTime2] : [], operateTime: operateTime1 ? [operateTime1, operateTime2] : [] }; - this.setState({ loading: true }); + this.setState({ loading: true, showSearchAd: false }); adjustRecordItemList(payload).then(({ status, data }) => { this.setState({ loading: false }); if (status) { From ffaf5dc036e80e6bc2bf7e8bf6748921f6251724 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Wed, 13 Mar 2024 14:23:08 +0800 Subject: [PATCH 033/127] hotfix/3.0.0.2403.01 --- .../doCalc/components/salaryCalcPersonConfirm/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryCalcPersonConfirm/index.js b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryCalcPersonConfirm/index.js index 83588d5b..68b7245f 100644 --- a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryCalcPersonConfirm/index.js +++ b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryCalcPersonConfirm/index.js @@ -173,10 +173,10 @@ class Index extends Component { const { routeParams: { salaryAcctRecordId } } = this.props; saveAcctemployee({ salaryAcctRecordId, employeeIds }).then(({ status, errormsg }) => { if (status) { - message.success(getLabel(541531, "添加成功!")); + message.success(getLabel(26712, "添加成功!")); this.queryPCList(); } else { - message.error(errormsg || getLabel(111, "添加失败!")); + message.error(errormsg || getLabel(545246, "添加失败!")); } }); }; From 0771ad9ed3e8530bdcf3aa3badffdc4809569872 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Wed, 13 Mar 2024 17:27:49 +0800 Subject: [PATCH 034/127] =?UTF-8?q?hotfix/3.0.0.2403.01=20=E6=95=B0?= =?UTF-8?q?=E6=8D=AE=E9=87=87=E9=9B=86=E9=A1=B5=E9=9D=A2=E5=AF=BC=E5=85=A5?= =?UTF-8?q?=E4=BF=AE=E6=94=B9=E9=87=8D=E6=9E=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/importDialog/index.less | 24 ++++++ .../cumDeduct/components/importFormCom.js | 2 +- .../pages/dataAcquisition/cumDeduct/index.js | 59 ++----------- .../dataAcquisition/cumSituation/index.js | 58 +------------ .../pages/dataAcquisition/importDialog.js | 84 +++++++++++++++++++ .../hrmSalary/pages/dataAcquisition/layout.js | 46 +++++----- .../dataAcquisition/otherDeduct/index.js | 32 +------ .../specialAddDeduction/index.js | 54 +----------- 8 files changed, 152 insertions(+), 207 deletions(-) create mode 100644 pc4mobx/hrmSalary/pages/dataAcquisition/importDialog.js diff --git a/pc4mobx/hrmSalary/components/importDialog/index.less b/pc4mobx/hrmSalary/components/importDialog/index.less index 95cee40b..21d314d9 100644 --- a/pc4mobx/hrmSalary/components/importDialog/index.less +++ b/pc4mobx/hrmSalary/components/importDialog/index.less @@ -120,6 +120,30 @@ } } + .import-option { + .screenWrapper { + padding: 0; + margin: 10px; + border: 1px solid #e5e5e5; + + .wea-content { + padding: 0; + } + + .wea-form-cell { + padding: 0 16px; + + .wea-date-picker { + width: 85%; + } + } + + .wea-helpful-tip { + padding-left: 10px; + } + } + } + } } diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/components/importFormCom.js b/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/components/importFormCom.js index 0044f630..4746d846 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/components/importFormCom.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/components/importFormCom.js @@ -32,7 +32,7 @@ class ImportFormCom extends Component { value: taxAgentId || "", onChange: this.screenChange, options: [{ key: "", showname: "全部" }, ...taxAgentOption], - key: "taxAgentId" + key: "taxAgentId", viewAttr: 3 }) } ]; diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js b/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js index 5c3658fb..eaba3e5b 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js @@ -19,14 +19,13 @@ import { editAddUpDeduction, getAddUpDeduction, getCumDeductSaCondition, - importCumDeductParam, - importCumDeductPreview + importCumDeductParam } from "../../../apis/cumDeduct"; import DataTables from "../dataTables"; import AddItems from "../addItems"; import ImportFormCom from "./components/importFormCom"; import TableRecord from "../components/tableRecord"; -import { dataCollectCondition, modalColumns } from "./columns"; +import { dataCollectCondition } from "./columns"; import { removePropertyCondition } from "../../../util/response"; import { convertToUrlString } from "../../../util/url"; import Layout from "../layout"; @@ -59,10 +58,9 @@ class Index extends Component { taxAgentId: "" }, importFormComponent: null, - step: 0, templateLink: "/api/bs/hrmsalary/addUpDeduction/downloadTemplate", importResult: {}, - slideDataSource: [] + previewUrl: "/api/bs/hrmsalary/addUpDeduction/preview" }, exportPayloadUrl: "", exportPayloadType: false, @@ -200,41 +198,6 @@ class Index extends Component { exportPayloadUrl: `${window.location.origin}/api/bs/hrmsalary/addUpDeduction/export?ids=${ids.join(",")}&declareMonth=${declareMonth}&taxAgentId=${taxAgentId}` }); }; - /* - * Author: 黎永顺 - * Description: 导入数据采集数据 - * Params: - * Date: 2023/2/20 - */ - handleImportFile = (params) => { - importCumDeductParam(params).then(({ status, data }) => { - if (status) { - const { importPayload } = this.state; - this.setState({ - importPayload: { ...importPayload, importResult: data } - }); - } - }); - }; - /* - * Author: 黎永顺 - * Description: 导入数据采集-数据查看 - * Params: - * Date: 2023/2/20 - */ - handlePreviewImport = (params) => { - importCumDeductPreview(params).then(({ status, data, errormsg }) => { - if (status) { - const { preview = [] } = data; - const { importPayload } = this.state; - this.setState({ - importPayload: { ...importPayload, slideDataSource: preview } - }); - } else { - message.error(errormsg || "预览失败"); - } - }); - }; /* * Author: 黎永顺 * Description: 数据采集-信息保存 @@ -530,12 +493,6 @@ class Index extends Component { importPayload: { ...importPayload, importOpts: { ...importOpts, [key]: value } } }); }; - handleImportSetStep = (step) => { - const { importPayload } = this.state; - this.setState({ - importPayload: { ...importPayload, step } - }); - }; render() { const { taxAgentStore: { showOperateBtn }, cumDeductStore: { form } } = this.props; @@ -551,11 +508,9 @@ class Index extends Component { slideLoading={saveLoading} exportPayloadUrl={exportPayloadUrl} exportPayloadType={exportPayloadType} logFunction="addupdeduction" form={form} condition={advanceCondition} onAdSearch={this.handleAdSearch} - onImportSetStep={this.handleImportSetStep} onCancel={this.handleCloseImport} - importPayload={importPayload} onImportFile={this.handleImportFile} - onPreviewImport={this.handlePreviewImport} detailOptBtns={this.getDetailOptBtns()} + onCancel={this.handleCloseImport} onImportFile={importCumDeductParam} + importPayload={importPayload} detailOptBtns={this.getDetailOptBtns()} targetid={targetid} onClearTargrtid={() => this.setState({ targetid: "" })} - columns={modalColumns} > this.tableRef = dom} @@ -588,9 +543,9 @@ export const DataCollectionDatePicker = (props) => { ; }; export const DataCollectionSelect = (props) => { - const { value, label, onChange, options, key, labelCol = 10, wrapperCol = 14 } = props; + const { value, label, onChange, options, key, labelCol = 10, wrapperCol = 14, viewAttr = 2 } = props; return - onChange({ key, value: val })} options={options}/> + onChange({ key, value: val })} options={options} viewAttr={viewAttr}/> ; }; diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/cumSituation/index.js b/pc4mobx/hrmSalary/pages/dataAcquisition/cumSituation/index.js index d6b70c9c..dd32ab7c 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/cumSituation/index.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/cumSituation/index.js @@ -15,8 +15,7 @@ import { editAddUpSituation, getAddUpSituation, getCumSituationSaCondition, - importCumSituationParam, - importCumSituationPreview + importCumSituationParam } from "../../../apis/cumSituation"; import { removePropertyCondition } from "../../../util/response"; import DataTables from "../dataTables"; @@ -27,7 +26,6 @@ import moment from "moment"; import { dataCollectCondition, taxOptions } from "./columns"; import AddItems from "../addItems"; import TableRecord from "../components/tableRecord"; -import { situationModalColumns } from "../cumDeduct/columns"; import { convertToUrlString } from "../../../util/url"; const getKey = WeaTools.getKey; @@ -57,10 +55,9 @@ class Index extends Component { declareMonth: moment(new Date()).format("YYYY-MM") }, importFormComponent: null, - step: 0, templateLink: "/api/bs/hrmsalary/addUpSituation/downloadTemplate", importResult: {}, - slideDataSource: [] + previewUrl: "/api/bs/hrmsalary/addUpSituation/preview" }, exportPayloadUrl: "", exportPayloadType: false, @@ -126,46 +123,6 @@ class Index extends Component { }); } }; - /* - * Author: 黎永顺 - * Description: 导入数据采集数据 - * Params: - * Date: 2023/2/20 - */ - handleImportFile = (params) => { - const { declareMonth, ...extra } = params; - const payload = { - taxYearMonth: declareMonth, - ...extra - }; - importCumSituationParam(payload).then(({ status, data }) => { - if (status) { - const { importPayload } = this.state; - this.setState({ - importPayload: { ...importPayload, importResult: data } - }); - } - }); - }; - /* - * Author: 黎永顺 - * Description: 导入数据采集-数据查看 - * Params: - * Date: 2023/2/20 - */ - handlePreviewImport = (params) => { - importCumSituationPreview(params).then(({ status, data, errormsg }) => { - if (status) { - const { preview = [] } = data; - const { importPayload } = this.state; - this.setState({ - importPayload: { ...importPayload, slideDataSource: preview } - }); - } else { - message.error(errormsg || "预览失败"); - } - }); - }; /* * Author: 黎永顺 * Description:列表操作 @@ -485,12 +442,6 @@ class Index extends Component { importPayload: { ...importPayload, importOpts: { ...importOpts, [key]: value } } }); }; - handleImportSetStep = (step) => { - const { importPayload } = this.state; - this.setState({ - importPayload: { ...importPayload, step } - }); - }; /* * Author: 黎永顺 * Description:详情页面-操作按钮 @@ -555,10 +506,9 @@ class Index extends Component { slideLoading={saveLoading} exportPayloadUrl={exportPayloadUrl} exportPayloadType={exportPayloadType} logFunction="addupsituation" form={form} condition={advanceCondition} onAdSearch={this.handleAdSearch} - onImportSetStep={this.handleImportSetStep} onCancel={this.handleCloseImport} + onCancel={this.handleCloseImport} onImportFile={importCumSituationParam} + detailOptBtns={this.getDetailOptBtns()} importPayload={{ ...importPayload, importOpts: { taxYearMonth: importPayload.importOpts.declareMonth } }} - onImportFile={this.handleImportFile} columns={situationModalColumns} - onPreviewImport={this.handlePreviewImport} detailOptBtns={this.getDetailOptBtns()} targetid={targetid} onClearTargrtid={() => this.setState({ targetid: "" })} > { + const { importDialog } = this.state, { onImportFile, importOpts } = this.props; + this.setState({ importDialog: { ...importDialog, nextloading: true } }); + onImportFile({ ...payload, ...importOpts }).then(({ data, status }) => { + this.setState({ importDialog: { ...importDialog, nextloading: false } }); + if (status) { + this.setState({ + importDialog: { ...importDialog, ...payload, importResult: data } + }); + } + }).catch(() => this.setState({ importDialog: { ...importDialog, nextloading: false } })); + }; + + render() { + const { importDialog, hasData } = this.state; + const { visible, onCancel, importParams, templateLink, importOpts } = this.props; + return ( + this.setState({ + importDialog: { ...importDialog, importResult: {}, imageId: "", link: "" } + })} + exportDataDom={ + this.setState({ hasData: val === "1" }, () => { + this.setState({ + importDialog: { + ...importDialog, + link: `${templateLink}?${convertToUrlString({ ...importOpts, hasData: this.state.hasData })}` + } + }); + })} + /> + } + nextCallback={imageId => this.setState({ importDialog: { ...importDialog, imageId } })} + nextUplaodCallback={imageId => this.handleImport({ imageId })} + /> + ); + } +} + +export default Index; diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/layout.js b/pc4mobx/hrmSalary/pages/dataAcquisition/layout.js index 587f2785..0c42281c 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/layout.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/layout.js @@ -8,11 +8,11 @@ import React, { Component } from "react"; import { inject, observer } from "mobx-react"; import { toJS } from "mobx"; import { WeaLocaleProvider, WeaNewScroll, WeaSlideModal, WeaTab, WeaTop } from "ecCom"; -import ImportModal from "../../components/importModal"; +import ImportModal from "./importDialog"; +import LogDialog from "../../components/logViewModal"; import SlideModalTitle from "../../components/slideModalTitle"; import { getSearchs } from "../../util"; import "./index.less"; -import LogDialog from "../../components/logViewModal"; const getLabel = WeaLocaleProvider.getLabel; @@ -78,14 +78,13 @@ class Layout extends Component { const { showSearchAd, logDialogVisible, filterConditions } = this.state; const { title, btns, leftComp, children, taxAgentStore: { showOperateBtn }, - slidePayload, onClose, onSave, slideLoading, form, condition, - onAdSearch, onCancel, importPayload, onImportSetStep, onImportFile, - onPreviewImport, detailOptBtns, columns, logFunction, onClearTargrtid + slidePayload, onClose, onSave, slideLoading, form, condition, onImportFile, + onAdSearch, onCancel, importPayload, detailOptBtns, logFunction, onClearTargrtid } = this.props; const { visible, title: subtitle, children: slideChildren } = slidePayload; const { - visible: importVisiable, step, importFormComponent, importOpts, - importResult, slideDataSource, templateLink + visible: importVisiable, importFormComponent, importOpts, + importResult, templateLink, previewUrl } = importPayload; return (
@@ -115,21 +114,26 @@ class Layout extends Component { {children} {/*导入弹框*/} onCancel(true)} - slideDataSource={slideDataSource} - previewImport={onPreviewImport} - importFile={onImportFile} - templateLink={templateLink} - renderFormComponent={() => importFormComponent} - visiable={importVisiable} - onCancel={onCancel} + visible={importVisiable} onCancel={onCancel} importParams={importFormComponent} + importOpts={importOpts} importResult={importResult} templateLink={templateLink} + previewUrl={previewUrl} onImportFile={onImportFile} /> + {/* onCancel(true)}*/} + {/* slideDataSource={slideDataSource}*/} + {/* previewImport={onPreviewImport}*/} + {/* importFile={onImportFile}*/} + {/* templateLink={templateLink}*/} + {/* renderFormComponent={() => importFormComponent}*/} + {/* visiable={importVisiable}*/} + {/* onCancel={onCancel}*/} + {/*/>*/} {/* 新增-编辑-详情弹框 */} { - importOtherDeductionParam(params).then(({ status, data }) => { - if (status) { - const { importPayload } = this.state; - this.setState({ - importPayload: { ...importPayload, importResult: data } - }); - } - }); - }; /* * Author: 黎永顺 * Description: 导入数据采集-数据查看 @@ -479,12 +461,6 @@ class Index extends Component { importPayload: { ...importPayload, importOpts: { ...importOpts, [key]: value } } }); }; - handleImportSetStep = (step) => { - const { importPayload } = this.state; - this.setState({ - importPayload: { ...importPayload, step } - }); - }; /* * Author: 黎永顺 * Description:详情页面-操作按钮 @@ -549,11 +525,9 @@ class Index extends Component { slideLoading={saveLoading} exportPayloadUrl={exportPayloadUrl} exportPayloadType={exportPayloadType} logFunction="otherdeduction" form={form} condition={advanceCondition} onAdSearch={this.handleAdSearch} - onImportSetStep={this.handleImportSetStep} onCancel={this.handleCloseImport} - importPayload={importPayload} onImportFile={this.handleImportFile} - onPreviewImport={this.handlePreviewImport} detailOptBtns={this.getDetailOptBtns()} + onCancel={this.handleCloseImport} importPayload={importPayload} + detailOptBtns={this.getDetailOptBtns()} onImportFile={importOtherDeductionParam} targetid={targetid} onClearTargrtid={() => this.setState({ targetid: "" })} - columns={otherModalColumns} > this.tableRef = dom} diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/specialAddDeduction/index.js b/pc4mobx/hrmSalary/pages/dataAcquisition/specialAddDeduction/index.js index 25288174..fe79d45f 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/specialAddDeduction/index.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/specialAddDeduction/index.js @@ -11,8 +11,7 @@ import { specialAddDeductionDeleteAllData, specialAddDeductionDeleteSelectData, specialAddDeductionEditData, - specialAddDeductionImportData, - specialAddDeductionPreview + specialAddDeductionImportData } from "../../../apis/special"; import { removePropertyCondition } from "../../../util/response"; import { DataCollectionSelect } from "../cumDeduct"; @@ -20,7 +19,6 @@ import ImportFormCom from "../cumDeduct/components/importFormCom"; import { condition } from "./components/condition"; import AddItems from "../addItems"; import TableRecord from "../components/tableRecord"; -import { specialModalColumns } from "../cumDeduct/columns"; import { convertToUrlString } from "../../../util/url"; const getKey = WeaTools.getKey; @@ -47,10 +45,9 @@ class Index extends Component { taxAgentId: "" }, importFormComponent: null, - step: 0, templateLink: "/api/bs/hrmsalary/specialAddDeduction/downloadTemplate", importResult: {}, - slideDataSource: [] + previewUrl: "/api/bs/hrmsalary/specialAddDeduction/preview" }, exportPayloadUrl: "", exportPayloadType: false, @@ -101,41 +98,6 @@ class Index extends Component { }); } }; - /* - * Author: 黎永顺 - * Description: 导入数据采集数据 - * Params: - * Date: 2023/2/20 - */ - handleImportFile = (params) => { - specialAddDeductionImportData(params).then(({ status, data }) => { - if (status) { - const { importPayload } = this.state; - this.setState({ - importPayload: { ...importPayload, importResult: data } - }); - } - }); - }; - /* - * Author: 黎永顺 - * Description: 导入数据采集-数据查看 - * Params: - * Date: 2023/2/20 - */ - handlePreviewImport = (params) => { - specialAddDeductionPreview(params).then(({ status, data, errormsg }) => { - if (status) { - const { preview = [] } = data; - const { importPayload } = this.state; - this.setState({ - importPayload: { ...importPayload, slideDataSource: preview } - }); - } else { - message.error(errormsg || "预览失败"); - } - }); - }; /* * Author: 黎永顺 * Description: 高级搜素框-表单项 @@ -439,12 +401,6 @@ class Index extends Component { importPayload: { ...importPayload, importOpts: { ...importOpts, [key]: value } } }); }; - handleImportSetStep = (step) => { - const { importPayload } = this.state; - this.setState({ - importPayload: { ...importPayload, step } - }); - }; render() { const { taxAgentStore: { showOperateBtn }, specialAddStore: { advanceForm } } = this.props; @@ -460,11 +416,9 @@ class Index extends Component { slideLoading={saveLoading} exportPayloadUrl={exportPayloadUrl} exportPayloadType={exportPayloadType} logFunction="specialAddDeduction" form={advanceForm} condition={advanceCondition} onAdSearch={this.handleAdSearch} - onImportSetStep={this.handleImportSetStep} onCancel={this.handleCloseImport} - importPayload={importPayload} onImportFile={this.handleImportFile} - onPreviewImport={this.handlePreviewImport} detailOptBtns={[]} + onCancel={this.handleCloseImport} detailOptBtns={[]} + importPayload={importPayload} onImportFile={specialAddDeductionImportData} targetid={targetid} onClearTargrtid={() => this.setState({ targetid: "" })} - columns={specialModalColumns} > this.tableRef = dom} From 0a23b261b198e250c2fc03d3d02060f151910041 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Thu, 14 Mar 2024 10:14:06 +0800 Subject: [PATCH 035/127] release/3.0.0.2403.01 --- pc4mobx/hrmSalary/apis/index.js | 2 +- pc4mobx/hrmSalary/pages/ruleConfig/ruleConfig.js | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/pc4mobx/hrmSalary/apis/index.js b/pc4mobx/hrmSalary/apis/index.js index 007bb6e6..4cb3b93c 100644 --- a/pc4mobx/hrmSalary/apis/index.js +++ b/pc4mobx/hrmSalary/apis/index.js @@ -24,7 +24,7 @@ export const getTableDatas = (params) => { export const getLogs = params => { const payload = { ...params, module: "hrsa", dataset: "dataset", authParams: "{}", transMethod: "hrsa", - showColums: "[{\"columName\":\"操作时间\",\"columIndex\":\"createdate\",\"width\":\"5%\"},{\"columName\":\"操作人\",\"columIndex\":\"operatorname\",\"width\":\"2%\"},{\"columName\":\"操作类型\",\"columIndex\":\"operatetypename\",\"width\":\"5%\"},{\"columName\":\"对象\",\"columIndex\":\"targetname\",\"width\":\"4%\"},{\"columName\":\"修改详情\",\"columIndex\":\"operatedesc\",\"width\":\"2%\"},{\"columName\":\"客户端IP\",\"columIndex\":\"clientip\",\"width\":\"5%\"}]" + showColums: "[{\"columName\":\"操作时间\",\"columIndex\":\"createdate\",\"width\":\"5%\"},{\"columName\":\"操作人\",\"columIndex\":\"operatorname\",\"width\":\"2%\"},{\"columName\":\"操作类型\",\"columIndex\":\"operatetypename\",\"width\":\"5%\"},{\"columName\":\"对象\",\"columIndex\":\"targetname\",\"width\":\"4%\"},{\"columName\":\"客户端IP\",\"columIndex\":\"clientip\",\"width\":\"5%\"},{\"columName\":\"修改详情\",\"columIndex\":\"operatedesc\",\"width\":\"2%\"}]" }; return postFetch("/api/bs/hrmelog/elog/getLogs", payload); }; diff --git a/pc4mobx/hrmSalary/pages/ruleConfig/ruleConfig.js b/pc4mobx/hrmSalary/pages/ruleConfig/ruleConfig.js index 45049a14..3e50d8ad 100644 --- a/pc4mobx/hrmSalary/pages/ruleConfig/ruleConfig.js +++ b/pc4mobx/hrmSalary/pages/ruleConfig/ruleConfig.js @@ -43,6 +43,11 @@ class RuleConfig extends Component { return { ...o, options: _.map(optionsList[getKey(o)], g => ({ key: g.value, showname: g.defaultLabel })) }; } else if (getKey(o) === "OPEN_APPLICATION_ENCRYPT") { return { ...o, viewAttr: sysinfo.showEncryptOperationButton === "true" ? 2 : 1 }; + } else if (getKey(o) === "taxDeclarationFunction") { + return { + ...o, + viewAttr: (_.isNil(sysinfo.taxDeclarationFunction) || sysinfo.taxDeclarationFunction !== "0") ? 2 : 1 + }; } return { ...o }; }) @@ -189,6 +194,7 @@ class RuleConfig extends Component { API.operateTaxDeclarationFunction({ operateTaxDeclaration }).then(({ status, errormsg }) => { if (status) { message.success(getLabel(22619, "保存成功!")); + const promise = this.init(); } else { message.error(errormsg || getLabel(22620, "保存失败!")); } From 5e3c20edc072ba092c0b8fa634e1a0b205dad30d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Fri, 15 Mar 2024 09:19:59 +0800 Subject: [PATCH 036/127] release/3.0.0.2403.01 --- pc4mobx/hrmSalary/apis/index.js | 2 +- .../components/importDialog/index.less | 24 ++++ .../components/selectItemsModal/index.js | 12 +- .../components/selectItemsModal/index.less | 2 +- .../selectItemsModal/selectItemsWrapper.js | 13 +- .../components/attendanceCustomFieldsModal.js | 10 +- .../components/attendanceDataComp.js | 133 +++++------------- .../components/attendanceRefrenceDataModal.js | 17 +-- .../attendance/components/importDialog.js | 82 +++++++++++ .../components/importFormOptions.js | 5 +- .../attendance/components/index.less | 4 - .../pages/dataAcquisition/attendance/index.js | 7 +- .../dataAcquisition/attendance/index.less | 2 +- .../pages/dataAcquisition/cumDeduct/index.js | 3 +- .../pages/dataAcquisition/dataTables.js | 5 +- .../pages/dataAcquisition/importDialog.js | 22 ++- pc4mobx/hrmSalary/stores/attendanceStore.js | 2 + 17 files changed, 202 insertions(+), 143 deletions(-) create mode 100644 pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/importDialog.js diff --git a/pc4mobx/hrmSalary/apis/index.js b/pc4mobx/hrmSalary/apis/index.js index 007bb6e6..4cb3b93c 100644 --- a/pc4mobx/hrmSalary/apis/index.js +++ b/pc4mobx/hrmSalary/apis/index.js @@ -24,7 +24,7 @@ export const getTableDatas = (params) => { export const getLogs = params => { const payload = { ...params, module: "hrsa", dataset: "dataset", authParams: "{}", transMethod: "hrsa", - showColums: "[{\"columName\":\"操作时间\",\"columIndex\":\"createdate\",\"width\":\"5%\"},{\"columName\":\"操作人\",\"columIndex\":\"operatorname\",\"width\":\"2%\"},{\"columName\":\"操作类型\",\"columIndex\":\"operatetypename\",\"width\":\"5%\"},{\"columName\":\"对象\",\"columIndex\":\"targetname\",\"width\":\"4%\"},{\"columName\":\"修改详情\",\"columIndex\":\"operatedesc\",\"width\":\"2%\"},{\"columName\":\"客户端IP\",\"columIndex\":\"clientip\",\"width\":\"5%\"}]" + showColums: "[{\"columName\":\"操作时间\",\"columIndex\":\"createdate\",\"width\":\"5%\"},{\"columName\":\"操作人\",\"columIndex\":\"operatorname\",\"width\":\"2%\"},{\"columName\":\"操作类型\",\"columIndex\":\"operatetypename\",\"width\":\"5%\"},{\"columName\":\"对象\",\"columIndex\":\"targetname\",\"width\":\"4%\"},{\"columName\":\"客户端IP\",\"columIndex\":\"clientip\",\"width\":\"5%\"},{\"columName\":\"修改详情\",\"columIndex\":\"operatedesc\",\"width\":\"2%\"}]" }; return postFetch("/api/bs/hrmelog/elog/getLogs", payload); }; diff --git a/pc4mobx/hrmSalary/components/importDialog/index.less b/pc4mobx/hrmSalary/components/importDialog/index.less index 21d314d9..4c9430f2 100644 --- a/pc4mobx/hrmSalary/components/importDialog/index.less +++ b/pc4mobx/hrmSalary/components/importDialog/index.less @@ -142,6 +142,30 @@ padding-left: 10px; } } + + .attendanceFormWrapper { + padding: 0 10px; + margin: 10px 0; + border: 1px solid #e5e5e5; + + .wea-form-cell { + padding: 0 !important; + } + + .wea-select, .ant-select-selection, .ant-select { + width: 100%; + } + + .wea-select { + display: inline-block; + position: relative; + } + + .ant-select-selection { + height: 30px; + border-radius: 0; + } + } } } diff --git a/pc4mobx/hrmSalary/components/selectItemsModal/index.js b/pc4mobx/hrmSalary/components/selectItemsModal/index.js index b7d01a5d..cae0464d 100644 --- a/pc4mobx/hrmSalary/components/selectItemsModal/index.js +++ b/pc4mobx/hrmSalary/components/selectItemsModal/index.js @@ -9,7 +9,6 @@ import { WeaCheckbox, WeaDialog, WeaInputSearch } from "ecCom"; import { Button } from "antd"; import "./index.less"; - export default class SelectItemModal extends React.Component { constructor(props) { super(props); @@ -58,10 +57,19 @@ export default class SelectItemModal extends React.Component { const bottomLeft = ; return ( {children} diff --git a/pc4mobx/hrmSalary/components/selectItemsModal/index.less b/pc4mobx/hrmSalary/components/selectItemsModal/index.less index 6486a98c..7572d9da 100644 --- a/pc4mobx/hrmSalary/components/selectItemsModal/index.less +++ b/pc4mobx/hrmSalary/components/selectItemsModal/index.less @@ -19,7 +19,7 @@ flex-wrap: wrap; li { - width: 124px; + width: 140px; overflow: hidden; padding: 4px 0; diff --git a/pc4mobx/hrmSalary/components/selectItemsModal/selectItemsWrapper.js b/pc4mobx/hrmSalary/components/selectItemsModal/selectItemsWrapper.js index 1a0d44d0..81c29aed 100644 --- a/pc4mobx/hrmSalary/components/selectItemsModal/selectItemsWrapper.js +++ b/pc4mobx/hrmSalary/components/selectItemsModal/selectItemsWrapper.js @@ -11,21 +11,22 @@ class SelectItemsWrapper extends Component { constructor(props) { super(props); this.state = { - searchVal: "", - selectItem: [], - groupItem: [], - showOnlyChecked: false + searchVal: "", selectItem: [], groupItem: [], showOnlyChecked: false }; } componentDidMount() { - const { dataSource } = this.props + this.initSelectItem(); + } + + initSelectItem = () => { + const { dataSource } = this.props; this.setState({ selectItem: _.map(_.filter(_.reduce(dataSource, (pre, cur) => { return [...pre, ...cur.items]; }, []), item => !!item.checked), it => it.id) }); - } + }; handleSearchItemSet = (searchVal) => this.setState({ searchVal }); handleShowOnlyChecked = (showOnlyChecked) => this.setState({ showOnlyChecked: !!Number(showOnlyChecked) }); diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceCustomFieldsModal.js b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceCustomFieldsModal.js index 0bbc46f0..aa7fd242 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceCustomFieldsModal.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceCustomFieldsModal.js @@ -22,7 +22,9 @@ class AttendanceCustomFieldsModal extends Component { } componentWillReceiveProps(nextProps, nextContext) { + const { attendanceStore: { initForm } } = nextProps; if (nextProps.visible !== this.props.visible && nextProps.visible) this.handleResetForm(); + if (nextProps.visible !== this.props.visible && !nextProps.visible) initForm(); } @@ -62,12 +64,8 @@ class AttendanceCustomFieldsModal extends Component { ]; return ( - - {getSearchs(form, conditions, 1)} + +
{getSearchs(form, conditions, 1)}
); } diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceDataComp.js b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceDataComp.js index cd8ec31a..dd103159 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceDataComp.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceDataComp.js @@ -14,14 +14,13 @@ import { getLedgerList, getSalaryCycleAndAttendCycle, importAttendQuoteData, - previewAttendQuote, returnToAttendanceFieldSettingDefault, saveAttendanceFieldSetting, saveAttendanceFieldSettingAsDefault } from "../../../../apis/attendance"; -import ImportModal from "../../../../components/importModal"; -import HeaderSet from "../../../../components/importModal/headerSet"; -import ImportFormOptions from "./importFormOptions"; +import ImportModal from "./importDialog"; +// import HeaderSet from "../../../../components/importModal/headerSet"; +// import ImportFormOptions from "./importFormOptions"; import SelectItemModal from "../../../../components/selectItemsModal"; import moment from "moment"; import SelectItemsWrapper from "../../../../components/selectItemsModal/selectItemsWrapper"; @@ -45,10 +44,7 @@ class AttendanceDataComp extends Component { pageSize: 10, total: 0 }, - importData: { - visiable: false, params: {}, step: 0, - columns: [], slideDataSource: [], importResult: [] - }, + importData: { visible: false, params: {} }, importFormPayload: { salaryYearMonth: moment().format("YYYY-MM"), salarySobList: [], salarySobId: "", salaryCycle: "", attendCycle: "" @@ -87,15 +83,24 @@ class AttendanceDataComp extends Component { } }).catch(() => this.setState({ loading: { ...loading, query: false } })); }; - getLedgerList = () => { + getLedgerList = (importData) => { const { importFormPayload } = this.state; getLedgerList().then(({ status, data }) => { if (status) { this.setState({ importFormPayload: { - ...importFormPayload, + ...importFormPayload, salarySobId: _.head(data).id, salarySobList: _.map(data, it => ({ key: it.id, showname: it.content })) } + }, async () => { + const { importFormPayload } = this.state; + const { salaryYearMonth, salarySobId } = importFormPayload; + const payload = { salaryYearMonthStr: salaryYearMonth, salarySobId }; + const { data } = await getSalaryCycleAndAttendCycle(payload); + this.setState({ + importData: { ...importData, params: { salaryYearMonth, salarySobId } }, + importFormPayload: { ...importFormPayload, ...data } + }); }); } }); @@ -154,64 +159,12 @@ class AttendanceDataComp extends Component { } }); }; - handleImportAttendanceData = (importData) => { - const { importFormPayload } = this.state; - const { salaryYearMonth, salarySobId } = importFormPayload; - this.getLedgerList(); - this.setState({ importData: { ...importData, params: { salaryYearMonth, salarySobId } } }); - }; - setStep = step => this.setState({ importData: { ...this.state.importData, step } }); - handleFinish = () => { + handleImportAttendanceData = (importData) => this.getLedgerList(importData); + handleFinish = (isFresh) => { const { importData } = this.state; - const { step } = importData; this.setState({ - importData: { - ...importData, visiable: false, params: {}, step: 0, - columns: [], slideDataSource: [], importResult: [] - } - }); - step === 2 && this.getAttendanceList(); - }; - handlePreviewImport = (params) => { - const { importData } = this.state; - previewAttendQuote(params).then(({ status, data }) => { - if (status) { - const { headers, list } = data; - this.setState({ - importData: { - ...importData, - columns: _.map(headers, (it, dataIndex) => ({ title: it, dataIndex })), - slideDataSource: _.map(list, item => { - return _.reduce(item, (pre, cur, key) => (_.assign(pre, { [key]: cur })), {}); - }) - } - }); - } - }); - }; - handleImport = (params) => { - const { importData } = this.state; - const { step } = importData; - importAttendQuoteData(params).then(({ status, data }) => { - if (status) { - this.setState({ - importData: { - ...importData, - step: step + 1, - importResult: data - } - }); - } - }); - }; - handleTemplateLinkClick = () => { - const { importFormPayload } = this.state; - const { salarySobId, salaryYearMonth } = importFormPayload; - if (!salarySobId || !salaryYearMonth) { - message.warning("请完善导入选项,再下载"); - return; - } - window.open(`/api/bs/hrmsalary/attendQuote/downloadTemplate?salaryYearMonth=${salaryYearMonth}&salarySobId=${salarySobId}`); + importData: { ...importData, visible: false, params: {} } + }, () => isFresh && this.getAttendanceList()); }; /* * Author: 黎永顺 @@ -236,7 +189,7 @@ class AttendanceDataComp extends Component { onSelectItem={this.handleSelectItem} /> } - }); + }, () => this.setItemRef && this.setItemRef.initSelectItem()); } }).catch(() => this.setState({ loading: { ...loading, headset: false } })); }; @@ -392,46 +345,30 @@ class AttendanceDataComp extends Component { } } ]} - dataSource={dataSource} - pagination={pagination} - loading={loading.query} - /> + dataSource={dataSource} pagination={pagination} loading={loading.query}/> {/* 考勤引用导入 */} - this.handleHeaderSettings({ sourceType: "IMPORT" })}/>} - renderFormComponent={() => - } + {/* 表头设置 */} + onMoreOpts={this.handleMoreOpts} onSave={this.handleSave}/> {/* 考勤数据引用 */} - + {/* 考勤数据查看 */} - this.setState({ - attendanceViewPayload: { - ...attendanceViewPayload, - visible: false, - attendQuoteId: "" - } - })} - /> + this.setState({ + attendanceViewPayload: { + ...attendanceViewPayload, + visible: false, + attendQuoteId: "" + } + })}/> ); } diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceRefrenceDataModal.js b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceRefrenceDataModal.js index 2308b556..14de4956 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceRefrenceDataModal.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceRefrenceDataModal.js @@ -13,7 +13,10 @@ import { getSearchs } from "../../../../util"; import { checkOperation, getAttendanceFieldSettingList, - getLedgerList, returnToAttendanceFieldSettingDefault, saveAttendanceFieldSetting, saveAttendanceFieldSettingAsDefault, + getLedgerList, + returnToAttendanceFieldSettingDefault, + saveAttendanceFieldSetting, + saveAttendanceFieldSettingAsDefault, syncAttendanceRefer } from "../../../../apis/attendance"; import SelectItemModal from "../../../../components/selectItemsModal"; @@ -124,7 +127,7 @@ class AttendanceRefrenceDataModal extends Component { onSelectItem={this.handleSelectItem} /> } - }); + }, () => this.setItemRef && this.setItemRef.initSelectItem()); } }).catch(() => this.setState({ headerSetLoading: false })); }; @@ -209,12 +212,10 @@ class AttendanceRefrenceDataModal extends Component { ]; return ( - - {getSearchs(refenceform, condition, 1)} + +
+ {getSearchs(refenceform, condition, 1)} +
{/* 表头设置 */} { + const { hasData } = this.state; + const { importFormPayload } = this.props; + const { salarySobId, salaryYearMonth } = importFormPayload; + if (!salarySobId || !salaryYearMonth) { + Modal.warning({ + title: getLabel(131329, "信息确认"), + content: getLabel(518702, "必要信息不完整,红色*为必填项!") + }); + return; + } + window.open(`/api/bs/hrmsalary/attendQuote/downloadTemplate?salaryYearMonth=${salaryYearMonth}&salarySobId=${salarySobId}`); + }; + handleImport = (payload) => { + const { importDialog } = this.state, { importAttendQuoteData, params } = this.props; + this.setState({ importDialog: { ...importDialog, nextloading: true } }); + importAttendQuoteData({ ...payload, ...params }).then(({ data, status }) => { + this.setState({ importDialog: { ...importDialog, nextloading: false } }); + if (status) { + this.setState({ + importDialog: { ...importDialog, ...payload, importResult: data } + }); + } + }).catch(() => this.setState({ importDialog: { ...importDialog, nextloading: false } })); + }; + + render() { + const { importDialog } = this.state; + const { + visible, onCancel, importFormPayload, onChangeImportForm, onHeaderSettings, loading + } = this.props; + return ( + this.setState({ + importDialog: { ...importDialog, importResult: {}, imageId: "", link: "" } + })} + importParams={} + exportDataDom={ onHeaderSettings({ sourceType: "IMPORT" })}/>} + nextCallback={imageId => this.setState({ importDialog: { ...importDialog, imageId } })} + nextUplaodCallback={imageId => this.handleImport({ imageId })} + /> + ); + } +} + +export default Index; diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/importFormOptions.js b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/importFormOptions.js index f16d18f3..08dfe2c2 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/importFormOptions.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/importFormOptions.js @@ -40,8 +40,9 @@ class ImportFormOptions extends Component { label: "薪资账套", value: salarySobId || "", onChange: this.screenChange, - options: [{ key: "", showname: "" }, ...salarySobList], - key: "salarySobId" + options: salarySobList, + key: "salarySobId", + viewAttr: 3 }) }, { com: Input("薪资周期", salaryCycle) }, diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/index.less b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/index.less index 6e340057..640d1b83 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/index.less +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/index.less @@ -18,10 +18,6 @@ } } -.attendanceFormWrapper { - padding: 0; -} - .attendanceSlideWrapper { .wea-slide-modal-title { height: initial; diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.js b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.js index 7f4c67c1..e27fc31e 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.js @@ -57,12 +57,7 @@ class Index extends Component { }; handleChangeSalaryMonth = (salaryMonth) => this.setState({ salaryMonth }, () => this.attendanceTableRef.getAttendanceList({ salaryYearMonth: _.compact(this.state.salaryMonth) })); handleAddAttendFileds = () => this.fieldMangRef.handleTriggerAttendFileds(); - handleImportAttendanceData = () => { - this.attendanceTableRef.handleImportAttendanceData({ - visiable: true, params: {}, step: 0, - columns: [], slideDataSource: [], importResult: [] - }); - }; + handleImportAttendanceData = () => this.attendanceTableRef.handleImportAttendanceData({ visible: true, params: {} }); handleQuoteAttendanceData = () => { this.attendanceTableRef.handleQuoteAttendanceData({ visible: true, title: "引用考勤数据" diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less index e4dae347..fafbff7c 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/index.less @@ -4,7 +4,7 @@ flex-direction: column; .wea-form-item { - padding: 8px 16px; + padding: 8px 16px 0 16px; .to { padding: 0 10px diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js b/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js index eaba3e5b..5d9db24e 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js @@ -545,7 +545,8 @@ export const DataCollectionDatePicker = (props) => { export const DataCollectionSelect = (props) => { const { value, label, onChange, options, key, labelCol = 10, wrapperCol = 14, viewAttr = 2 } = props; return - onChange({ key, value: val })} options={options} viewAttr={viewAttr}/> + onChange({ key, value: val })} options={options} + viewAttr={viewAttr}/> ; }; diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/dataTables.js b/pc4mobx/hrmSalary/pages/dataAcquisition/dataTables.js index 742c7894..e677d531 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/dataTables.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/dataTables.js @@ -35,7 +35,10 @@ class DataTables extends Component { getTableDate = (extraPayload = {}) => { const { loading, pageInfo } = this.state; const { url, payload } = this.props; - const module = { ...pageInfo, url, ...payload, ...extraPayload }; + const module = { + ...pageInfo, url, ...payload, ...extraPayload, + departmentIds: extraPayload.departmentIds ? extraPayload.departmentIds.split(",") : [] + }; this.setState({ loading: { ...loading, query: true } }); getTableDate(module).then(({ status, data }) => { this.setState({ loading: { ...loading, query: false } }); diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/importDialog.js b/pc4mobx/hrmSalary/pages/dataAcquisition/importDialog.js index 1cc14192..0e1777e9 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/importDialog.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/importDialog.js @@ -1,19 +1,16 @@ /* * Author: 黎永顺 - * name: 最优年终奖计税方案-策略-导入 + * name:数据采集四个基础项-导入 * Description: - * Date: 2024/3/1 + * Date: 2024/3/14 */ import React, { Component } from "react"; -import { inject, observer } from "mobx-react"; import { WeaCheckbox, WeaLocaleProvider } from "ecCom"; import ImportDialog from "../../components/importDialog"; import { convertToUrlString } from "../../util/url"; const getLabel = WeaLocaleProvider.getLabel; -@inject("specialAddStore") -@observer class Index extends Component { constructor(props) { super(props); @@ -32,11 +29,24 @@ class Index extends Component { this.setState({ importDialog: { ...importDialog, link: `${templateLink}?${convertToUrlString({ ...importOpts, hasData })}`, - importResult, params: importOpts, previewUrl + importResult, params: importOpts, previewUrl, extraPreview: importOpts } }); } + handleExportTemp = () => { + const { hasData } = this.state; + const { templateLink, importOpts } = this.props; + if (!Object.values(importOpts).every(o => !!o)) { + Modal.warning({ + title: getLabel(131329, "信息确认"), + content: getLabel(518702, "必要信息不完整,红色*为必填项!") + }); + return; + } + const payload = { ...importOpts, hasData }; + window.open(`${templateLink}?${convertToUrlString(payload)}`, "_blank"); + }; handleImport = (payload) => { const { importDialog } = this.state, { onImportFile, importOpts } = this.props; this.setState({ importDialog: { ...importDialog, nextloading: true } }); diff --git a/pc4mobx/hrmSalary/stores/attendanceStore.js b/pc4mobx/hrmSalary/stores/attendanceStore.js index f309619e..d34866d3 100644 --- a/pc4mobx/hrmSalary/stores/attendanceStore.js +++ b/pc4mobx/hrmSalary/stores/attendanceStore.js @@ -4,6 +4,8 @@ import { WeaForm } from "comsMobx"; export class AttendanceStore { @observable form = new WeaForm(); + @action("字段管理-新建字段表单初始化") + initForm = () => this.form = new WeaForm(); @observable refenceform = new WeaForm(); //薪酬统计 新增form @observable statisticsForm = new WeaForm(); From 689c837749fc24be4abc59498bd7d6d3f7994f3a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Fri, 15 Mar 2024 15:09:16 +0800 Subject: [PATCH 037/127] =?UTF-8?q?hotfix/3.00.0.2403.01=20=E8=80=83?= =?UTF-8?q?=E6=83=85=E7=AE=A1=E7=90=86=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/attendanceDataViewSlide.js | 104 ++++++------------ .../attendance/components/index.less | 30 +++++ .../welfareArchive/config.js | 2 +- 3 files changed, 65 insertions(+), 71 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceDataViewSlide.js b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceDataViewSlide.js index 1011398c..4e2735aa 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceDataViewSlide.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceDataViewSlide.js @@ -5,26 +5,19 @@ * Date: 2023/3/7 */ import React, { Component } from "react"; -import { WeaFormItem, WeaInput, WeaInputSearch, WeaSlideModal } from "ecCom"; +import { WeaInputSearch, WeaLocaleProvider, WeaSlideModal, WeaTable, WeaTop } from "ecCom"; import { Button } from "antd"; -import SlideModalTitle from "../../../../components/slideModalTitle"; import { viewAttendQuote } from "../../../../apis/attendance"; -import UnifiedTable from "../../../../components/UnifiedTable"; import "./index.less"; +const { getLabel } = WeaLocaleProvider; + class AttendanceDataViewSlide extends Component { constructor(props) { super(props); this.state = { - loading: { - query: false - }, - keyword: "", - dataSource: [], - columns: [], - pageInfo: { - current: 1, pageSize: 10, total: 0 - } + loading: { query: false }, keyword: "", dataSource: [], columns: [], + pageInfo: { current: 1, pageSize: 10, total: 0 } }; } @@ -46,29 +39,12 @@ class AttendanceDataViewSlide extends Component { if (status) { const { columns, list: dataSource, pageNum: current, pageSize, total } = data.pageInfo; this.setState({ - pageInfo: { ...pageInfo, current, pageSize, total }, - dataSource, - columns + pageInfo: { ...pageInfo, current, pageSize, total }, dataSource, + columns: _.map(columns, o => ({ ...o, width: 150, fixed: o.dataIndex === "username" ? "left" : null })) }); } }).catch(() => this.setState({ loading: { ...loading, query: false } })); }; - renderCustomOperate = () => { - const { keyword } = this.state; - const { showOperateBtn } = this.props; - return ([ -
- {showOperateBtn && } - this.setState({ keyword })} - onSearch={() => this.viewAttendQuote({ current: 1 }, this.props)} - /> -
- ]); - }; handleExportAttendQuote = () => { if (!this.handleDebounce) { this.handleDebounce = _.debounce(() => { @@ -83,7 +59,7 @@ class AttendanceDataViewSlide extends Component { render() { const { showOperateBtn, salaryYearMonth, ...extra } = this.props; - const { columns, dataSource, loading, pageInfo } = this.state; + const { columns, dataSource, loading, pageInfo, keyword } = this.state; const pagination = { ...pageInfo, showTotal: (total) => `共 ${total} 条`, @@ -101,45 +77,33 @@ class AttendanceDataViewSlide extends Component { }, () => this.viewAttendQuote({}, this.props)); } }; + const btns = [ + , + this.setState({ keyword })} + onSearch={() => this.viewAttendQuote({ current: 1 }, this.props)} + /> + ]; return ( - - } - content={ -
- - - - ({ - ...item, - render: (text) => { - return {text} ; - } - }))} - dataSource={dataSource} - pagination={pagination} - loading={loading.query} - xWidth={columns.length * 180} - /> -
- } + } + iconBgcolor="#F14A2D" + buttons={showOperateBtn ? btns : btns.slice(1)}/> + } + content={ +
+
+
{getLabel(543376, "考勤周期")}:{salaryYearMonth}
+
+
+ +
+ } /> ); } diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/index.less b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/index.less index 640d1b83..51316cab 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/index.less +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/index.less @@ -19,10 +19,18 @@ } .attendanceSlideWrapper { + .wea-slide-modal-content { + height: 100%; + } + .wea-slide-modal-title { height: initial; line-height: initial; text-align: left; + + .wea-new-top > div:last-child { + padding-right: 50px !important; + } } .rodal-close { @@ -30,6 +38,28 @@ top: 10px !important; } + .attendance-slide-body { + background: #f6f6f6; + height: 100%; + overflow-y: auto; + padding: 16px; + + .attendance-tb-tip { + display: flex; + justify-content: space-between; + align-items: center; + padding: 4px 0; + min-height: 32px; + line-height: 18px; + margin-bottom: 8px; + } + + .wea-new-table { + background: #FFF; + } + } + + } @media (min-width: 1260px) { diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/config.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/config.js index ea717c4f..2c0a760d 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/config.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/config.js @@ -825,7 +825,7 @@ const BenefitBaseComponent = (props) => { customComponent={
{getLabel(543195, "各项福利基数一致")} onSameChange(items, v)} - disabled={runStatuses === "4,5" || !showOperateBtn}/> + disabled={runStatuses === "4,5" || !showOperateBtn} precision={2}/>
} title={title} col={2} showGroup className="twoColumns-welfare-info-wrapper" />; From 80acc5f18a05b8db27091bfb1bc8b930d75ab403 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Mon, 18 Mar 2024 16:03:04 +0800 Subject: [PATCH 038/127] hotfix/2.12.1.2403.02 --- pc4mobx/hrmSalary/components/importDialog/index.less | 6 +++++- pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/pc4mobx/hrmSalary/components/importDialog/index.less b/pc4mobx/hrmSalary/components/importDialog/index.less index 4c9430f2..d37389ea 100644 --- a/pc4mobx/hrmSalary/components/importDialog/index.less +++ b/pc4mobx/hrmSalary/components/importDialog/index.less @@ -152,7 +152,11 @@ padding: 0 !important; } - .wea-select, .ant-select-selection, .ant-select { + .wea-select { + width: 200px !important; + } + + .ant-select-selection, .ant-select { width: 100%; } diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js b/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js index 5d9db24e..7fca9256 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.js @@ -545,7 +545,7 @@ export const DataCollectionDatePicker = (props) => { export const DataCollectionSelect = (props) => { const { value, label, onChange, options, key, labelCol = 10, wrapperCol = 14, viewAttr = 2 } = props; return - onChange({ key, value: val })} options={options} + onChange({ key, value: val })} options={options} viewAttr={viewAttr}/> ; }; From d9f3fafd51e13c4ee23a472c3abf808b633b12f0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Tue, 19 Mar 2024 14:29:00 +0800 Subject: [PATCH 039/127] =?UTF-8?q?hotfix/2.12.1.2403.02=20=E6=95=B0?= =?UTF-8?q?=E6=8D=AE=E9=80=8F=E8=A7=86=E5=AF=BC=E5=87=BA=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pc4mobx/hrmSalary/apis/payrollFiles.js | 70 ++++++++++--------- .../pages/reportView/components/index.less | 7 ++ .../components/povitpivotChartModal.js | 21 ++++-- pc4mobx/hrmSalary/util/request.js | 3 + 4 files changed, 63 insertions(+), 38 deletions(-) diff --git a/pc4mobx/hrmSalary/apis/payrollFiles.js b/pc4mobx/hrmSalary/apis/payrollFiles.js index 7ebdb6bb..f2516b5a 100644 --- a/pc4mobx/hrmSalary/apis/payrollFiles.js +++ b/pc4mobx/hrmSalary/apis/payrollFiles.js @@ -1,5 +1,5 @@ import { WeaTools } from "ecCom"; -import { postFetch } from "../util/request"; +import { postExportFetch, postFetch } from "../util/request"; //获取薪资档案各tab的人数 export const queryTabTotal = (params) => { @@ -11,65 +11,69 @@ export const queryList = ({ url, ...params }) => { }; // 导入档案 export const importSalaryArchive = (params) => { - return postFetch('/api/bs/hrmsalary/salaryArchive/importSalaryArchive', params); -} + return postFetch("/api/bs/hrmsalary/salaryArchive/importSalaryArchive", params); +}; // 薪资档案预览 export const salaryArchivePreview = (params) => { - return postFetch('/api/bs/hrmsalary/salaryArchive/preview', params); -} + return postFetch("/api/bs/hrmsalary/salaryArchive/preview", params); +}; // 公共枚举接口 export const commonEnumList = (params) => { - return WeaTools.callApi('/api/bs/hrmsalary/common/enum/list', 'GET', params); -} + return WeaTools.callApi("/api/bs/hrmsalary/common/enum/list", "GET", params); +}; // 获取导入类型 export const getImportTypes = () => { - return WeaTools.callApi('/api/bs/hrmsalary/salaryArchive/getImportTypes', 'GET', {}); -} + return WeaTools.callApi("/api/bs/hrmsalary/salaryArchive/getImportTypes", "GET", {}); +}; // 发起调薪地址 export const salaryAdjustmentInfo = (params) => { - return WeaTools.callApi('/api/bs/hrmsalary/process/salaryAdjustmentInfo', 'GET', params); -} + return WeaTools.callApi("/api/bs/hrmsalary/process/salaryAdjustmentInfo", "GET", params); +}; // 停薪 export const stopSalary = (params) => { - return postFetch('/api/bs/hrmsalary/salaryArchive/stopSalary', params); -} + return postFetch("/api/bs/hrmsalary/salaryArchive/stopSalary", params); +}; // 一键全部设为定薪员工 export const allGotoFixed = (params) => { - return postFetch('/api/bs/hrmsalary/salaryArchive/allGotoFixed', params); -} + return postFetch("/api/bs/hrmsalary/salaryArchive/allGotoFixed", params); +}; // 设为定薪员工 export const gotoFixed = (params) => { - return postFetch('/api/bs/hrmsalary/salaryArchive/gotoFixed', params); -} + return postFetch("/api/bs/hrmsalary/salaryArchive/gotoFixed", params); +}; // 停薪 export const gotoStop = (params) => { - return postFetch('/api/bs/hrmsalary/salaryArchive/gotoStop', params); -} + return postFetch("/api/bs/hrmsalary/salaryArchive/gotoStop", params); +}; //全部停薪 export const allGotoStop = (params) => { - return postFetch('/api/bs/hrmsalary/salaryArchive/allGotoStop', params); -} + return postFetch("/api/bs/hrmsalary/salaryArchive/allGotoStop", params); +}; // 取消停薪 export const cancelStop = (params) => { - return postFetch('/api/bs/hrmsalary/salaryArchive/cancelStop', params); -} + return postFetch("/api/bs/hrmsalary/salaryArchive/cancelStop", params); +}; // 保存发薪设置 export const savePaySet = (params) => { - return postFetch('/api/bs/hrmsalary/salaryArchive/savePaySet', params); -} + return postFetch("/api/bs/hrmsalary/salaryArchive/savePaySet", params); +}; // 待定薪删除待办 export const deletePendingTodo = (params) => { - return postFetch('/api/bs/hrmsalary/salaryArchive/deletePendingTodo', params); -} + return postFetch("/api/bs/hrmsalary/salaryArchive/deletePendingTodo", params); +}; // 待停薪删除待办 export const deleteSuspendTodo = (params) => { - return postFetch('/api/bs/hrmsalary/salaryArchive/deleteSuspendTodo', params); -} + return postFetch("/api/bs/hrmsalary/salaryArchive/deleteSuspendTodo", params); +}; // 待定薪、停薪员工 是否允许删除薪资档案 export const salaryArchiveDelete = (params) => { - return WeaTools.callApi('/api/bs/hrmsalary/sys/conf/code?code=salaryArchiveDelete', 'GET', params); -} + return WeaTools.callApi("/api/bs/hrmsalary/sys/conf/code?code=salaryArchiveDelete", "GET", params); +}; // 删除薪资档案 export const deleteSalaryArchive = (params) => { - return postFetch('/api/bs/hrmsalary/salaryArchive/deleteSalaryArchive', params); -} + return postFetch("/api/bs/hrmsalary/salaryArchive/deleteSalaryArchive", params); +}; +// 数据透视列表导出 +export const exportDataPerspective = (params) => { + return postExportFetch("/api/bs/hrmsalary/report/statistics/report/exportDataPerspective", params); +}; diff --git a/pc4mobx/hrmSalary/pages/reportView/components/index.less b/pc4mobx/hrmSalary/pages/reportView/components/index.less index d77aab7f..53e93a64 100644 --- a/pc4mobx/hrmSalary/pages/reportView/components/index.less +++ b/pc4mobx/hrmSalary/pages/reportView/components/index.less @@ -62,6 +62,13 @@ .ant-spin-nested-loading, .ant-spin-container { height: 100%; } + + .header-custom { + width: 100%; + display: flex; + justify-content: space-between; + align-items: center; + } } .shareDialogWrapper { diff --git a/pc4mobx/hrmSalary/pages/reportView/components/povitpivotChartModal.js b/pc4mobx/hrmSalary/pages/reportView/components/povitpivotChartModal.js index 801bb99e..9f9bddf7 100644 --- a/pc4mobx/hrmSalary/pages/reportView/components/povitpivotChartModal.js +++ b/pc4mobx/hrmSalary/pages/reportView/components/povitpivotChartModal.js @@ -5,11 +5,12 @@ * Date: 2023/6/8 */ import React, { Component } from "react"; -import { WeaDialog, WeaLocaleProvider } from "ecCom"; -import { WeaTableNew } from "comsMobx"; -import { Spin } from "antd"; -import { toJS } from "mobx"; import { inject, observer } from "mobx-react"; +import { WeaDialog, WeaLoadingGlobal, WeaLocaleProvider } from "ecCom"; +import * as API from "../../../apis/payrollFiles"; +import { WeaTableNew } from "comsMobx"; +import { Button, Spin } from "antd"; +import { toJS } from "mobx"; import "./index.less"; const WeaTableComx = WeaTableNew.WeaTable; @@ -103,13 +104,23 @@ class PovitpivotChartModal extends Component { showSum: false, pageInfo }); }; + exportDataPerspective = () => { + WeaLoadingGlobal.start(); + const { id, dimensionId, dimensionValue, isShare } = this.props; + const promise = API.exportDataPerspective({ id, dimensionId, dimensionValue, isShare }); + WeaLoadingGlobal.destroy(); + }; render() { const { loading } = this.state; const { payrollFilesStore: { pivotTableStore } } = this.props; return ( + {getLabel(111, "数据透视")} + +
} + scalable className="pivot-wrapper" initLoadCss visible={this.props.visible} style={{ width: "80vw", height: "80vh" }} buttons={[]} onCancel={this.props.onCancel}> diff --git a/pc4mobx/hrmSalary/util/request.js b/pc4mobx/hrmSalary/util/request.js index 821d58d6..4fd7e4e4 100644 --- a/pc4mobx/hrmSalary/util/request.js +++ b/pc4mobx/hrmSalary/util/request.js @@ -1,3 +1,5 @@ +import { WeaLoadingGlobal } from "ecCom"; + const server = window.server || ""; export const formHeaderPost = (url, method, params, header) => { if (typeof localStorage.access_token === "string" && localStorage.access_token !== "") { @@ -34,6 +36,7 @@ export const postExportFetch = (url, params) => { } url = server + url + "?__random__=" + (new Date()).valueOf(); return fetch(url, getFetchParams("POST", params)).then(res => { + WeaLoadingGlobal.destroy(); const filename = res.headers.get("Content-Disposition").split("filename=")[1]; res.blob().then(blob => { const url = window.URL.createObjectURL(blob); From 8af1f0a79a58ed712790bfc3b745e88ffeff6d18 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Tue, 19 Mar 2024 17:55:37 +0800 Subject: [PATCH 040/127] =?UTF-8?q?hotfix/2.12.1.2403.02=20=E5=AE=8C?= =?UTF-8?q?=E6=88=90=E5=AF=BC=E5=85=A5=E6=8A=A5=E9=94=99=E7=9A=84=E9=97=AE?= =?UTF-8?q?=E9=A2=98=E5=A4=84=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../doCalc/components/salaryEditCalcImport/index.js | 2 +- .../dataAcquisition/attendance/components/importDialog.js | 5 ++++- .../payrollFiles/components/salaryFileImportDialog/index.js | 2 +- .../components/standingBookCalcImportDialog.js | 2 +- .../components/welfareArchivesImportDialog/index.js | 2 +- 5 files changed, 8 insertions(+), 5 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalcImport/index.js b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalcImport/index.js index 463c7df4..ce58c616 100644 --- a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalcImport/index.js +++ b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalcImport/index.js @@ -63,7 +63,7 @@ class Index extends Component { this.setState({ importDialog: { ...this.state.importDialog, link: this.handleExportTemp, - visible: nextProps.visible, title: nextProps.title + visible: nextProps.visible, title: nextProps.title, importResult: {} } }); } diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/importDialog.js b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/importDialog.js index bf67e4b2..72df9bde 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/importDialog.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/importDialog.js @@ -29,7 +29,10 @@ class Index extends Component { const { hasData, importDialog } = this.state; const { params, previewUrl } = nextProps; this.setState({ - importDialog: { ...importDialog, link: this.handleExportTemp, params, previewUrl, extraPreview: params } + importDialog: { + ...importDialog, importResult: {}, link: this.handleExportTemp, + params, previewUrl, extraPreview: params + } }); } diff --git a/pc4mobx/hrmSalary/pages/payrollFiles/components/salaryFileImportDialog/index.js b/pc4mobx/hrmSalary/pages/payrollFiles/components/salaryFileImportDialog/index.js index 1a60b901..313a8675 100644 --- a/pc4mobx/hrmSalary/pages/payrollFiles/components/salaryFileImportDialog/index.js +++ b/pc4mobx/hrmSalary/pages/payrollFiles/components/salaryFileImportDialog/index.js @@ -51,7 +51,7 @@ class Index extends Component { if (isExtEmp) payload = { ...payload, extSalaryArchiveList: true }; this.setState({ importDialog: { - ...this.state.importDialog, extraPreview, + ...this.state.importDialog, extraPreview, importResult: {}, link: `/api/bs/hrmsalary/salaryArchive/downloadTemplate?${convertToUrlString(payload)}` } }); diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/standingBookCalcImportDialog.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/standingBookCalcImportDialog.js index 0dc97e42..fb4a2db8 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/standingBookCalcImportDialog.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/standingBookCalcImportDialog.js @@ -33,7 +33,7 @@ class StandingBookCalcImportDialog extends Component { const { data } = await API[fieldUrl](); this.setState({ importDialog: { - ...this.state.importDialog, link: this.handleExportTemp, title: getLabel(24023, "数据导入") + ...this.state.importDialog, importResult: {}, link: this.handleExportTemp, title: getLabel(24023, "数据导入") }, headerFieldsDialog: { ...this.state.headerFieldsDialog, itemsByGroup: data, diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/components/welfareArchivesImportDialog/index.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/components/welfareArchivesImportDialog/index.js index 149a304c..b61a17c2 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/components/welfareArchivesImportDialog/index.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/components/welfareArchivesImportDialog/index.js @@ -35,7 +35,7 @@ class Index extends Component { }; this.setState({ importDialog: { - ...this.state.importDialog, + ...this.state.importDialog, importResult: {}, link: `/api/bs/hrmsalary/scheme/template/export?${convertToUrlString(payload)}` } }); From 272e45d3e5e734e1867cca77272cba43042ccaef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Wed, 20 Mar 2024 09:10:06 +0800 Subject: [PATCH 041/127] =?UTF-8?q?hotfix/2.12.1.2403.02=20=E8=96=AA?= =?UTF-8?q?=E8=B5=84=E6=A1=A3=E6=A1=88=E8=B0=83=E8=96=AA=EF=BC=8C=E8=96=AA?= =?UTF-8?q?=E8=B5=84=E5=B0=8F=E6=95=B0=E4=BD=8D=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pages/salaryFile/salaryArchiveEditAdjLogRecord.js | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/salaryFile/salaryArchiveEditAdjLogRecord.js b/pc4mobx/hrmSalary/pages/salaryFile/salaryArchiveEditAdjLogRecord.js index a091c42f..a46b7129 100644 --- a/pc4mobx/hrmSalary/pages/salaryFile/salaryArchiveEditAdjLogRecord.js +++ b/pc4mobx/hrmSalary/pages/salaryFile/salaryArchiveEditAdjLogRecord.js @@ -63,7 +63,8 @@ class SalaryArchiveEditAdjLogRecordDialog extends Component { salaryArchiveItemDetail: { ...salaryArchiveItemDetail, list: _.map(salaryArchiveItemDetail.list, o => ({ - ...o, dataType: _.find(salaryArchiveItemDetail.salaryItemList, g => g.id === o.salaryItem).dataType + ...o, dataType: _.find(salaryArchiveItemDetail.salaryItemList, g => g.id === o.salaryItem).dataType, + pattern: _.find(salaryArchiveItemDetail.salaryItemList, g => g.id === o.salaryItem).pattern })) }, conditions: _.map(adjCondition, item => { @@ -108,7 +109,8 @@ class SalaryArchiveEditAdjLogRecordDialog extends Component { if (o.salaryItem === salaryItemId) { return { ...o, salaryBefore: data, - dataType: _.find(salaryArchiveItemDetail.salaryItemList, g => g.id === salaryItemId).dataType + dataType: _.find(salaryArchiveItemDetail.salaryItemList, g => g.id === salaryItemId).dataType, + pattern: _.find(salaryArchiveItemDetail.salaryItemList, g => g.id === salaryItemId).pattern }; } return { ...o }; @@ -238,7 +240,7 @@ class SalaryArchiveEditAdjLogRecordDialog extends Component { ...o, render: (__, record) => { if (record.dataType === "number") { return this.handleChangeAdjustAfter(record, v)} />; } else { From 1deceeb3e8955c884537ced9f0b4f2e3f95a2191 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Wed, 20 Mar 2024 16:36:56 +0800 Subject: [PATCH 042/127] =?UTF-8?q?feature/2.12.1.2403.02-=E7=A4=BE?= =?UTF-8?q?=E4=BF=9D=E6=A1=A3=E6=A1=88=E4=BF=9D=E5=AD=98=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../welfareEditArchiveSlide/index.js | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/components/welfareEditArchiveSlide/index.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/components/welfareEditArchiveSlide/index.js index 03a89212..304724fb 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/components/welfareEditArchiveSlide/index.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/components/welfareEditArchiveSlide/index.js @@ -180,7 +180,7 @@ class Index extends Component { welfareType, validate: welfareData[`${underTakeType}SchemeId`] ? !!welfareData[`${underTakeType}StartTime`] : true }; }; - save = async () => { + save = async (changeData = false) => { const socailPayload = this.covertPayload("SOCIAL_SECURITY", "social", getConditionDomkeys(this.props.socialBase.items), getConditionDomkeys(this.props.socialBase.comItems || [])), fundPayload = this.covertPayload("ACCUMULATION_FUND", "fund", getConditionDomkeys(this.props.fundBase.items), getConditionDomkeys(this.props.fundBase.comItems || [])), otherPayload = this.covertPayload("OTHER", "other", getConditionDomkeys(this.props.otherBase.items), getConditionDomkeys(this.props.otherBase.comItems || [])); @@ -198,13 +198,24 @@ class Index extends Component { }, { status: otherStatus, errormsg: otherErrorMsg = "!" - }] = await Promise.all([API.save(socailPayload), API.save(fundPayload), API.save(otherPayload)]); + }] = await Promise.all([ + API.save({ ...socailPayload, changeData }), + API.save({ ...fundPayload, changeData }), + API.save({ ...otherPayload, changeData })]); this.setState({ loading: false }); if (socialStatus && fundStatus && otherStatus) { message.success(getLabel(30700, "操作成功!")); this.props.onClose(true); } else { - message.error(socialErrorMsg + fundErrorMsg + otherErrorMsg); + Modal.confirm({ + title: getLabel(131329, "信息确认"), + content:
+
{socialErrorMsg + fundErrorMsg + otherErrorMsg}
+
{getLabel(111, "是否自动将方案的上下限调整为设置值?")}
+
, + onOk: () => this.save(true), + onCancel: () => this.props.onClose() + }); } }; updateFormData = (baseData) => this.setState({ formData: { ...this.state.formData, ...baseData } }); @@ -278,7 +289,7 @@ class Index extends Component {
{ runStatuses !== "4,5" && showOperateBtn && - + }
; From a7e75331e1a5b220f8b1f570beb3aed9bd2e3afb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Thu, 21 Mar 2024 13:49:18 +0800 Subject: [PATCH 043/127] =?UTF-8?q?hotfix/2.12.1.2403.02=201=E3=80=81?= =?UTF-8?q?=E5=B7=A5=E8=B5=84=E5=8D=95=E5=8F=91=E6=94=BE-=E6=9F=A5?= =?UTF-8?q?=E7=9C=8B=E8=AF=A6=E6=83=85-=E9=AB=98=E7=BA=A7=E6=90=9C?= =?UTF-8?q?=E7=B4=A2=20=E9=83=A8=E9=97=A8=E8=83=BD=E5=A4=9A=E9=80=89?= =?UTF-8?q?=EF=BC=8C=20=E5=A4=9A=E9=80=89=E5=88=86=E9=83=A8=202=E3=80=81?= =?UTF-8?q?=E7=A4=BE=E4=BF=9D=E7=A6=8F=E5=88=A9=E5=8F=B0=E8=B4=A6=EF=BC=9A?= =?UTF-8?q?=E6=AD=A3=E5=B8=B8=E7=BC=B4=E7=BA=B3=E3=80=81=E8=A1=A5=E7=BC=B4?= =?UTF-8?q?=E3=80=81=E9=80=80=E5=B7=AE=E3=80=81=E8=A1=A5=E5=B7=AE=20?= =?UTF-8?q?=E9=AB=98=E7=BA=A7=E6=90=9C=E7=B4=A2=E5=A2=9E=E5=8A=A0=E9=83=A8?= =?UTF-8?q?=E9=97=A8=E7=AD=9B=E9=80=89=EF=BC=8C=E5=A4=9A=E5=88=86=E9=83=A8?= =?UTF-8?q?=E7=AD=9B=E9=80=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pages/payroll/payrollDetail/index.js | 9 ++++- .../components/makeupDifference.js | 4 +- .../standingBookDetail/components/normal.js | 39 ++++++++++++++----- .../standingBookDetail/components/regTop.js | 30 ++++++++++---- .../components/regression.js | 39 ++++++++++--------- pc4mobx/hrmSalary/stores/payroll.js | 6 ++- 6 files changed, 86 insertions(+), 41 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/payroll/payrollDetail/index.js b/pc4mobx/hrmSalary/pages/payroll/payrollDetail/index.js index 6e6479c0..efa982db 100644 --- a/pc4mobx/hrmSalary/pages/payroll/payrollDetail/index.js +++ b/pc4mobx/hrmSalary/pages/payroll/payrollDetail/index.js @@ -87,9 +87,14 @@ export default class PayrollDetail extends React.Component { const { child, ...extraParams } = extra; const salarySendId = getQueryString("id"); const { payrollStore } = this.props; - const { detailListConditionForm: form } = payrollStore; - const payload = { salarySendId, ...pageInfo, ...extraParams, ...form.getFormParams() }; + const { detailListConditionForm: form, setDetailListShowSearchAd } = payrollStore; + const payload = { + salarySendId, ...pageInfo, ...extraParams, ...form.getFormParams(), + departmentIds: form.getFormParams().departmentIds ? form.getFormParams().departmentIds.split(",") : [], + subCompanyIds: form.getFormParams().subCompanyIds ? form.getFormParams().subCompanyIds.split(",") : [] + }; this.setState({ loading: true }); + setDetailListShowSearchAd(false) getPayrollDetailList(payload).then(({ status, data }) => { this.setState({ loading: false }); if (status) { diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/makeupDifference.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/makeupDifference.js index 9ff5fb28..d0085fd7 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/makeupDifference.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/makeupDifference.js @@ -62,6 +62,8 @@ class MakeupDifference extends Component { const { importDiffModal, addPersonalDialog } = this.state; const name = this.regTopRef.state.name; const workcode = this.regTopRef.state.workcode; + const departmentIds = this.regTopRef.state.departmentIds ? this.regTopRef.state.departmentIds.split(",") : []; + const subCompanyIds = this.regTopRef.state.subCompanyIds ? this.regTopRef.state.subCompanyIds.split(",") : []; const billMonth = getQueryString("billMonth"); const paymentOrganization = getQueryString("paymentOrganization"); switch (key) { @@ -85,7 +87,7 @@ class MakeupDifference extends Component { window.open(url, "_self"); break; case "search": - this.diffListRef.recessionList({ userName: name, workcode, current: 1 }); + this.diffListRef.recessionList({ userName: name, workcode, departmentIds, subCompanyIds, current: 1 }); break; case "add": this.setState({ diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/normal.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/normal.js index 45f1a728..d7366471 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/normal.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/normal.js @@ -5,9 +5,9 @@ * LastEditTime: 2022-06-29 09:53:36 */ import React, { Component } from "react"; -import { Button, Icon, message, Modal, Spin, Tooltip } from "antd"; +import { Button, Col, Icon, message, Modal, Row, Spin, Tooltip } from "antd"; import { inject, observer } from "mobx-react"; -import { WeaFormItem, WeaInput, WeaSearchGroup, WeaTab } from "ecCom"; +import { WeaBrowser, WeaFormItem, WeaInput, WeaLocaleProvider, WeaSearchGroup, WeaTab } from "ecCom"; import { calcPageNo } from "../../../../util"; import { getQueryString } from "../../../../util/url"; import ProgressModal from "../../../../components/progressModal"; @@ -19,6 +19,7 @@ import SupplementarySlide from "./supplementarySlide"; import _ from "lodash"; import "./index.less"; +const getLabel = WeaLocaleProvider.getLabel; @inject("standingBookStore") @observer export default class NormalIndex extends Component { @@ -44,6 +45,8 @@ export default class NormalIndex extends Component { }, searchValue: "", workcode: "", + departmentIds: "", + subCompanyIds: "", progressVisible: false, progress: 0, fieldData: {}, //选中的表单头信息 @@ -149,14 +152,18 @@ export default class NormalIndex extends Component { current: 1, paymentOrganization, userName: this.state.searchValue, - workcode: this.state.workcode + workcode: this.state.workcode, + departmentIds: this.state.departmentIds ? this.state.departmentIds.split(",") : [], + subCompanyIds: this.state.subCompanyIds ? this.state.subCompanyIds.split(",") : [] }) : this.getSupplementaryList({ billMonth, current: 1, paymentOrganization, userName: this.state.searchValue, - workcode: this.state.workcode + workcode: this.state.workcode, + departmentIds: this.state.departmentIds ? this.state.departmentIds.split(",") : [], + subCompanyIds: this.state.subCompanyIds ? this.state.subCompanyIds.split(",") : [] }); }; @@ -445,12 +452,24 @@ export default class NormalIndex extends Component { }; getSearchs = () => { return - - this.setState({ workcode: v })} - /> - + + + this.setState({ workcode: v })} + /> + + + this.setState({ departmentIds: v })}/> + + + this.setState({ subCompanyIds: v })}/> + + ; }; diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/regTop.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/regTop.js index 72acc3f1..0c6de7cc 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/regTop.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/regTop.js @@ -1,6 +1,6 @@ import React, { Component } from "react"; -import { Button } from "antd"; -import { WeaFormItem, WeaHelpfulTip, WeaInput, WeaLocaleProvider, WeaSearchGroup, WeaTab } from "ecCom"; +import { Button, Col, Row } from "antd"; +import { WeaBrowser, WeaFormItem, WeaHelpfulTip, WeaInput, WeaLocaleProvider, WeaSearchGroup, WeaTab } from "ecCom"; import { getQueryString } from "../../../../util/url"; const getLabel = WeaLocaleProvider.getLabel; @@ -11,6 +11,8 @@ class RegTop extends Component { this.state = { name: "", workcode: "", + departmentIds: "", + subCompanyIds: "", showSearchAd: false }; } @@ -56,12 +58,24 @@ class RegTop extends Component { }; getSearchs = () => { return - - this.setState({ workcode: v })} - /> - + + + this.setState({ workcode: v })} + /> + + + this.setState({ departmentIds: v })}/> + + + this.setState({ subCompanyIds: v })}/> + + ; }; diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/regression.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/regression.js index 4b4e790d..3b35e57e 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/regression.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBookDetail/components/regression.js @@ -6,7 +6,6 @@ */ import React, { Component } from "react"; import { message, Modal } from "antd"; -import { WeaNewScroll } from "ecCom"; import RegTop from "./regTop"; import RegList from "./regList"; import RegAddEmployee from "./regAddEmployee"; @@ -75,6 +74,8 @@ class Regression extends Component { const { returnPersonModal } = this.state; const name = this.regTopRef.state.name; const workcode = this.regTopRef.state.workcode; + const departmentIds = this.regTopRef.state.departmentIds ? this.regTopRef.state.departmentIds.split(",") : []; + const subCompanyIds = this.regTopRef.state.subCompanyIds ? this.regTopRef.state.subCompanyIds.split(",") : []; const billMonth = getQueryString("billMonth"); const creator = Number(getQueryString("creator")); const paymentOrganization = getQueryString("paymentOrganization"); @@ -98,7 +99,7 @@ class Regression extends Component { window.open(url, "_self"); break; case "search": - this.regListRef.recessionList({ userName: name, workcode, current: 1 }); + this.regListRef.recessionList({ userName: name, workcode, departmentIds, subCompanyIds, current: 1 }); break; default: break; @@ -136,23 +137,23 @@ class Regression extends Component { />
{/**/} - this.regListRef = dom} - visible={returnPersonModal.visible} - onChangeRowkey={(selectKey) => this.setState({ selectKey })} - onEdit={this.handleEdit} - /> - {/*编辑弹框*/} - - {/* 弹框 */} - this.regEmmployeeRef = dom} - {...returnPersonModal} - loading={loading} - onCancel={this.handleCloseModal} - onSave={this.handleSave} - /> + this.regListRef = dom} + visible={returnPersonModal.visible} + onChangeRowkey={(selectKey) => this.setState({ selectKey })} + onEdit={this.handleEdit} + /> + {/*编辑弹框*/} + + {/* 弹框 */} + this.regEmmployeeRef = dom} + {...returnPersonModal} + loading={loading} + onCancel={this.handleCloseModal} + onSave={this.handleSave} + /> {/**/}
diff --git a/pc4mobx/hrmSalary/stores/payroll.js b/pc4mobx/hrmSalary/stores/payroll.js index e170d4fc..4da841d0 100644 --- a/pc4mobx/hrmSalary/stores/payroll.js +++ b/pc4mobx/hrmSalary/stores/payroll.js @@ -453,7 +453,11 @@ export class payrollStore { @action getInfoList = (params = {}) => { let form = this.grantListConditionForm.getFormParams(); - params = { ...form, ...params }; + params = { + ...form, ...params, + departmentIds: form.departmentIds ? form.departmentIds.split(",") : [], + subCompanyIds: form.subCompanyIds ? form.subCompanyIds.split(",") : [] + }; API.getInfoList(params).then(res => { if (res.status) { this.salaryGrantTableStore = res.data.columns; From c51c93c8122f0058fd7fffb66f256126f7acf054 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Mon, 25 Mar 2024 17:23:42 +0800 Subject: [PATCH 044/127] =?UTF-8?q?hotfix/2.12.1.2403.02=20=E8=B0=83?= =?UTF-8?q?=E8=96=AA=E5=88=97=E8=A1=A8=E6=A0=B7=E5=BC=8F=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pc4mobx/hrmSalary/pages/salaryFile/index.less | 4 +++- pc4mobx/hrmSalary/pages/salaryFile/salaryItemChangeList.js | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/pc4mobx/hrmSalary/pages/salaryFile/index.less b/pc4mobx/hrmSalary/pages/salaryFile/index.less index ebc4a8a4..ac388b47 100644 --- a/pc4mobx/hrmSalary/pages/salaryFile/index.less +++ b/pc4mobx/hrmSalary/pages/salaryFile/index.less @@ -169,10 +169,12 @@ } .adjustItem-layout { - .ant-table-fixed td { + .ant-table-fixed-left td > span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; + width: 100px; + display: inline-block; } } diff --git a/pc4mobx/hrmSalary/pages/salaryFile/salaryItemChangeList.js b/pc4mobx/hrmSalary/pages/salaryFile/salaryItemChangeList.js index 13706751..97bb8519 100644 --- a/pc4mobx/hrmSalary/pages/salaryFile/salaryItemChangeList.js +++ b/pc4mobx/hrmSalary/pages/salaryFile/salaryItemChangeList.js @@ -4,6 +4,7 @@ import { WeaLocaleProvider, WeaTable } from "ecCom"; import { inject, observer } from "mobx-react"; import { deleteSalaryItem } from "../../apis/archive"; import SalaryArchiveEditAdjLogRecord from "./salaryArchiveEditAdjLogRecord"; +import "./index.less"; const { getLabel } = WeaLocaleProvider; @inject("salaryFileStore") From 85c222def8426529036415ebbed2fd8849e263e2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Tue, 26 Mar 2024 09:14:32 +0800 Subject: [PATCH 045/127] =?UTF-8?q?feature/2.12.1.2403.02-=E8=96=AA?= =?UTF-8?q?=E9=85=AC=E7=BB=9F=E8=AE=A1=E6=8A=A5=E8=A1=A8=E9=85=8D=E7=BD=AE?= =?UTF-8?q?=E9=A1=B9=E4=BB=A5=E5=8F=8A=E8=96=AA=E8=B5=84=E6=98=8E=E7=BB=86?= =?UTF-8?q?=E7=9A=84=E5=BC=80=E5=8F=91=201=E3=80=81=E8=A1=A5=E7=AE=97?= =?UTF-8?q?=E7=9A=84=E9=A1=B5=E9=9D=A2=E5=AE=8C=E6=88=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pc4mobx/hrmSalary/index.js | 3 + .../pages/supplementaryCalc/index.js | 190 ++++++++++++++++++ .../pages/supplementaryCalc/index.less | 0 3 files changed, 193 insertions(+) create mode 100644 pc4mobx/hrmSalary/pages/supplementaryCalc/index.js create mode 100644 pc4mobx/hrmSalary/pages/supplementaryCalc/index.less diff --git a/pc4mobx/hrmSalary/index.js b/pc4mobx/hrmSalary/index.js index 0990c113..1aaf8045 100644 --- a/pc4mobx/hrmSalary/index.js +++ b/pc4mobx/hrmSalary/index.js @@ -51,6 +51,7 @@ import WatermarkPreview from "./pages/payroll/watermarkPreview"; import ExternalPersonManage from "./pages/externalPersonManage"; import AdjustSalaryManage from "./pages/adjustSalaryManage"; import TopologyMap from "./pages/topologyMap"; +import SupplementaryCalc from "./pages/supplementaryCalc"; import stores from "./stores"; import "./style/index"; @@ -110,6 +111,7 @@ const DataAcquisition = (props) => props.children; // reportView 薪酬报表查看 // externalPersonManage 非系统人员管理 // adjustSalaryManage 档案管理 +// supplementaryCalc 补算 const Routes = ( + ); diff --git a/pc4mobx/hrmSalary/pages/supplementaryCalc/index.js b/pc4mobx/hrmSalary/pages/supplementaryCalc/index.js new file mode 100644 index 00000000..558c2c38 --- /dev/null +++ b/pc4mobx/hrmSalary/pages/supplementaryCalc/index.js @@ -0,0 +1,190 @@ +/* + * Author: 黎永顺 + * name: 补算 + * Description: + * Date: 2024/3/26 + */ +import React, { Component } from "react"; +import { Button, message } from "antd"; +import { WeaBrowser, WeaError, WeaFormItem, WeaLocaleProvider, WeaSearchGroup, WeaSelect, WeaTop } from "ecCom"; +import { supplementAcctRecord } from "../../apis"; +import "./index.less"; + +const { getLabel } = WeaLocaleProvider; + +class Index extends Component { + constructor(props) { + super(props); + this.state = { + type: "sob", salaryItemIds: "", salarySobIds: "", + salaryAcctRecordIds: "", loading: false + }; + } + + handleChangeItems = (key, value) => { + this.setState({ [key]: value }); + }; + handleSubmit = () => { + const { salaryItemIds, salarySobIds, salaryAcctRecordIds, type } = this.state; + if (!salaryItemIds && !salarySobIds && type === "sob") { + this.refs.salaryItemError.showError(); + this.refs.salarySobError.showError(); + return; + } + if (!salaryItemIds && !salaryAcctRecordIds && type === "record") { + this.refs.salaryItemError.showError(); + this.refs.salaryPigeonholeError.showError(); + return; + } + if (!salaryItemIds) { + this.refs.salaryItemError.showError(); + return; + } + if (!salaryAcctRecordIds && type === "record") { + this.refs.salaryPigeonholeError.showError(); + return; + } + if (!salarySobIds && type === "sob") { + this.refs.salarySobError.showError(); + return; + } + this.setState({ loading: true }); + supplementAcctRecord({ + type, + salaryAcctRecordIds: salaryAcctRecordIds ? salaryAcctRecordIds.split(",") : [], + salarySobIds: salarySobIds ? salarySobIds.split(",") : [], + salaryItemIds: salaryItemIds ? salaryItemIds.split(",") : [] + }).then(({ status, errormsg }) => { + this.setState({ loading: false }); + if (status) { + message.success(getLabel(111, "补算成功")); + } else { + message.error(errormsg || getLabel(111, "补算失败")); + } + }).catch(() => this.setState({ loading: false })); + }; + + render() { + const { type, salaryItemIds, salarySobIds, salaryAcctRecordIds, loading } = this.state; + return ( + } + buttons={[ + + ]} + > +
+ + + + this.setState({ type }, () => { + this.setState({ salarySobIds: "", salaryAcctRecordIds: "", salaryItemIds: "" }); + })} + /> + + + { + type === "sob" ? + + + this.handleChangeItems("salarySobIds", salarySobIds)} + /> + + : + + + this.handleChangeItems("salaryAcctRecordIds", salaryAcctRecordIds)} + /> + + + } + + + this.handleChangeItems("salaryItemIds", salaryItemIds)} + /> + + + +
+
+ ); + } +} + +export default Index; diff --git a/pc4mobx/hrmSalary/pages/supplementaryCalc/index.less b/pc4mobx/hrmSalary/pages/supplementaryCalc/index.less new file mode 100644 index 00000000..e69de29b From 8d58561b887be557a637fd7e26df4eed1d731c3d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Tue, 26 Mar 2024 17:07:21 +0800 Subject: [PATCH 046/127] =?UTF-8?q?feature/2.12.1.2403.02-=E8=96=AA?= =?UTF-8?q?=E9=85=AC=E7=BB=9F=E8=AE=A1=E6=8A=A5=E8=A1=A8=E9=85=8D=E7=BD=AE?= =?UTF-8?q?=E9=A1=B9=E4=BB=A5=E5=8F=8A=E8=96=AA=E8=B5=84=E6=98=8E=E7=BB=86?= =?UTF-8?q?=E7=9A=84=E5=BC=80=E5=8F=91=201=E3=80=81=E8=A1=A5=E7=AE=97?= =?UTF-8?q?=E7=9A=84=E9=A1=B5=E9=9D=A2=E5=AE=8C=E6=88=90=202=E3=80=81?= =?UTF-8?q?=E8=96=AA=E9=85=AC=E7=BB=9F=E8=AE=A1=E6=8A=A5=E8=A1=A8-?= =?UTF-8?q?=E8=96=AA=E8=B5=84=E6=8A=A5=E8=A1=A8=E7=9A=84=E9=A1=B5=E9=9D=A2?= =?UTF-8?q?=E5=BC=80=E5=8F=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pc4mobx/hrmSalary/apis/index.js | 5 +- pc4mobx/hrmSalary/apis/statistics.js | 14 +- .../components/advanceInputBtn/index.js | 33 ++++ .../components/advanceInputBtn/index.less | 29 ++++ .../components/conditions.js | 88 +++++++++++ .../components/salaryDetails.js | 148 ++++++++++++++++++ .../components/searchPannel/index.js | 77 +++++++++ .../pages/analysisOfSalaryStatistics/index.js | 75 +++++++-- .../analysisOfSalaryStatistics/index.less | 58 ++++++- .../pages/reportView/components/condition.js | 13 ++ .../statisticalMicroSettingsSlide.js | 16 +- .../pages/supplementaryCalc/index.less | 7 + pc4mobx/hrmSalary/stores/attendanceStore.js | 5 +- 13 files changed, 545 insertions(+), 23 deletions(-) create mode 100644 pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/advanceInputBtn/index.js create mode 100644 pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/advanceInputBtn/index.less create mode 100644 pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/salaryDetails.js create mode 100644 pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/searchPannel/index.js diff --git a/pc4mobx/hrmSalary/apis/index.js b/pc4mobx/hrmSalary/apis/index.js index 4cb3b93c..92514839 100644 --- a/pc4mobx/hrmSalary/apis/index.js +++ b/pc4mobx/hrmSalary/apis/index.js @@ -39,4 +39,7 @@ export const getDetailChanges = params => { export const getSalarysobListAll = params => { return postFetch("/api/bs/hrmsalary/salarysob/listAll", params); }; - +//补算 +export const supplementAcctRecord = (params) => { + return postFetch("/api/bs/hrmsalary/salaryacct/supplementAcctRecord", params); +}; diff --git a/pc4mobx/hrmSalary/apis/statistics.js b/pc4mobx/hrmSalary/apis/statistics.js index 3b70ee59..76056002 100644 --- a/pc4mobx/hrmSalary/apis/statistics.js +++ b/pc4mobx/hrmSalary/apis/statistics.js @@ -1,5 +1,5 @@ import { WeaTools } from "ecCom"; -import { postFetch } from "../util/request"; +import { postExportFetch, postFetch } from "../util/request"; //薪酬统计维度下拉列表 export const dimensionGetForm = (params) => { @@ -122,3 +122,15 @@ export const getExpandFieldSettings = (params) => { export const statisticsReportDuplicate = (params) => { return WeaTools.callApi("/api/bs/hrmsalary/report/statistics/report/duplicate", "GET", params); }; +//薪酬统计报表-薪资明细列表 +export const getSalaryList = (params) => { + return postFetch("/api/bs/hrmsalary/report/statistics/employee/salaryList", params); +}; +//薪酬统计报表-薪资明细列表总计行 +export const getSalaryListSum = (params) => { + return postFetch("/api/bs/hrmsalary/report/statistics/employee/salaryListSum", params); +}; +// 薪酬统计报表-薪资明细导出 +export const exportSalaryList = (params) => { + return postExportFetch("/api/bs/hrmsalary/report/statistics/employee/exportSalaryList", params); +}; diff --git a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/advanceInputBtn/index.js b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/advanceInputBtn/index.js new file mode 100644 index 00000000..86a5f416 --- /dev/null +++ b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/advanceInputBtn/index.js @@ -0,0 +1,33 @@ +/* + * Author: 黎永顺 + * name:薪酬统计报表-高级搜索 + * Description: + * Date: 2024/3/26 + */ +import React, { Component } from "react"; +import { inject, observer } from "mobx-react"; +import { Button } from "antd"; +import { WeaInputSearch, WeaLocaleProvider } from "ecCom"; +import "./index.less"; + +const getLabel = WeaLocaleProvider.getLabel; + +@inject("attendanceStore") +@observer +class Index extends Component { + render() { + const { attendanceStore: { salaryDetailSearchForm } } = this.props; + return ( +
+ salaryDetailSearchForm.updateFields({ keyword: v })} + onSearch={this.props.onAdvanceSearch} + /> + +
+ ); + } +} + +export default Index; diff --git a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/advanceInputBtn/index.less b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/advanceInputBtn/index.less new file mode 100644 index 00000000..9081d39f --- /dev/null +++ b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/advanceInputBtn/index.less @@ -0,0 +1,29 @@ +.achrive-advance-search { + display: flex; + align-items: center; + position: relative; + top: -1.5px; + + .wea-advanced-search { + top: 2px; + left: -1px; + height: 28px; + line-height: 1; + border-radius: 0; + position: relative; + color: #474747; + padding: 4px 15px; + } + + .wea-advanced-search:hover { + border: 1px solid #dadada; + color: #474747; + } + + .text-elli { + overflow: hidden; + white-space: nowrap; + text-overflow: ellipsis; + top: 1px; + } +} diff --git a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/conditions.js b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/conditions.js index 080dd0e4..6a19614c 100644 --- a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/conditions.js +++ b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/conditions.js @@ -1,3 +1,4 @@ +import React from "react"; import { WeaLocaleProvider } from "ecCom"; const { getLabel } = WeaLocaleProvider; @@ -131,3 +132,90 @@ export const extensionCondition = [ defaultshow: true } ]; +export const salaryDetailSearchConditions = [ + { + items: [ + { + conditionType: "INPUT", + domkey: ["keyword"], + fieldcol: 16, + label: getLabel(111, "姓名/工号"), + labelcol: 8, + value: "", + viewAttr: 2 + }, + { + conditionType: "SELECT", + domkey: ["taxAgentIds"], + fieldcol: 16, + label: getLabel(537996, "个税扣缴义务人"), + labelcol: 8, + options: [], + multiple: true, + viewAttr: 2 + }, + { + browserConditionParam: { + completeParams: {}, + conditionDataParams: {}, + dataParams: {}, + destDataParams: {}, + hasAddBtn: false, + hasAdvanceSerach: false, + idSeparator: ",", + isAutoComplete: 1, + isDetail: 0, + isMultCheckbox: false, + isSingle: false, + icon: "icon-coms-hrm", + linkUrl: "", + pageSize: 10, + quickSearchName: "", + replaceDatas: [], + title: "", + type: "164", + viewAttr: 2 + }, + colSpan: 1, + conditionType: "BROWSER", + domkey: ["subcompanyIds"], + fieldcol: 16, + label: getLabel(33553, "分部"), + labelcol: 8, + viewAttr: 2 + }, + { + browserConditionParam: { + completeParams: {}, + conditionDataParams: {}, + dataParams: {}, + destDataParams: {}, + hasAddBtn: false, + hasAdvanceSerach: false, + idSeparator: ",", + isAutoComplete: 1, + isDetail: 0, + isMultCheckbox: false, + isSingle: false, + icon: "icon-coms-hrm", + linkUrl: "", + pageSize: 10, + quickSearchName: "", + replaceDatas: [], + title: "", + type: "57", + viewAttr: 2 + }, + conditionType: "BROWSER", + domkey: ["departmentIds"], + fieldcol: 16, + label: getLabel(27511, "部门"), + labelcol: 8, + viewAttr: 2 + } + ], + defaultshow: true, + title: getLabel(1361, "基本信息"), + col: 2 + } +]; diff --git a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/salaryDetails.js b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/salaryDetails.js new file mode 100644 index 00000000..e83e95ca --- /dev/null +++ b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/salaryDetails.js @@ -0,0 +1,148 @@ +/* + * Author: 黎永顺 + * name:薪资明细列表 + * Description: + * Date: 2024/3/26 + */ +import React, { Component } from "react"; +import { inject, observer } from "mobx-react"; +import { toJS } from "mobx"; +import { WeaLoadingGlobal, WeaLocaleProvider } from "ecCom"; +import { WeaTableNew } from "comsMobx"; +import { message, Spin } from "antd"; +import * as API from "../../../apis/statistics"; +import { getIframeParentHeight } from "../../../util"; +import { sysConfCodeRule } from "../../../apis/ruleconfig"; +import "../index.less"; + +const WeaTableComx = WeaTableNew.WeaTable; +const { getLabel } = WeaLocaleProvider; + +@inject("attendanceStore") +@observer +class SalaryDetails extends Component { + constructor(props) { + super(props); + this.state = { + loading: false, dataSource: [], columns: [], selectedRowKeys: [], + pageInfo: { current: 1, pageSize: 10, total: 0 }, payload: {}, + countResult: {}, showTotalCell: false + }; + } + + componentDidMount() { + this.getSalaryList(this.props); + window.addEventListener("message", this.handleReceive, false); + } + + componentWillReceiveProps(nextProps, nextContext) { + if (nextProps.isQuery !== this.props.isQuery) this.getSalaryList(nextProps); + } + + componentWillUnmount() { + window.removeEventListener("message", this.handleReceive, false); + this.setState(({ selectedRowKeys: [] })); + } + + handleReceive = ({ data }) => { + const { type, payload: { id, params } = {} } = data; + const { pageInfo } = this.state; + if (type === "init") { + this.getColumns(); + } else if (type === "turn") { + if (id === "PAGEINFO") { + const { pageNum: current, size: pageSize } = params; + this.setState({ pageInfo: { ...pageInfo, current, pageSize } }, () => this.getSalaryList(this.props)); + } else if (id === "CHECKBOX") { + const { selectedRowKeys: checkBox } = params; + this.setState({ selectedRowKeys: checkBox }); + } + } + }; + postMessageToChild = (payload) => { + const i18n = { + "共": getLabel(18609, "共"), "条": getLabel(18256, "条"), + "总计": getLabel(523, "总计") + }; + const childFrameObj = document.getElementById("atdTable"); + childFrameObj && childFrameObj.contentWindow.postMessage(JSON.stringify({ ...payload, i18n }), "*"); + }; + getSalaryList = (props) => { + const { attendanceStore: { salaryDetailSearchForm, tableStore }, dateRange } = props; + const [startDateStr, endDateStr] = dateRange; + const { taxAgentIds, subcompanyIds, departmentIds, ...extra } = salaryDetailSearchForm.getFormParams(); + const { pageInfo } = this.state; + const payload = { + taxAgentIds: taxAgentIds ? taxAgentIds.split(",") : [], + departmentIds: departmentIds ? departmentIds.split(",") : [], + subcompanyIds: subcompanyIds ? subcompanyIds.split(",") : [], + ...extra, ...pageInfo, startDateStr, endDateStr + }; + this.setState({ loading: true }); + API.getSalaryList(payload).then(async ({ status, data }) => { + const [{ data: sumData }, { data: confCode }] = await Promise.all([API.getSalaryListSum(payload), sysConfCodeRule({ code: "OPEN_ACCT_RESULT_SUM" })]); + this.setState({ loading: false }); + if (status) { + const { dataKey, pageInfo: pageparams } = data; + const { list: dataSource, pageNum: current, total, pageSize } = pageparams; + this.setState({ + dataSource, pageInfo: { ...pageInfo, current, total, pageSize }, payload, + countResult: sumData.sumRow, showTotalCell: confCode === "1" + }, () => tableStore.getDatas(dataKey.datas)); + } + }).catch(() => this.setState({ loading: false })); + }; + handleExportSalaryList = (key) => { + let { selectedRowKeys, payload } = this.state; + if (key === "SELECTED" && selectedRowKeys.length === 0) { + message.warning(getLabel(543345, "请选择需要导出的数据!")); + return; + } + WeaLoadingGlobal.start(); + const promise = API.exportSalaryList({ ...payload, ids: selectedRowKeys }); + }; + getColumns = () => { + const { attendanceStore: { tableStore } } = this.props; + const { dataSource, pageInfo, selectedRowKeys, countResult, showTotalCell } = this.state; + const columns = _.filter(toJS(tableStore.columns), (item) => item.display === "true" && item.dataIndex !== "acctTimes"); + if (!_.isEmpty(columns)) { + this.postMessageToChild({ + dataSource, pageInfo, selectedRowKeys, showTotalCell, calcDetail: true, tableScrollHeight: 154, + sumRow: countResult, + columns: _.map(columns, (it, idx) => ({ + ...it, + width: (it.dataIndex === "taxAgent" || it.dataIndex === "salarySob") ? 176 : it.oldWidth, + fixed: (idx === 1 || idx === 0 || idx === 2) ? "left" : "", + ellipsis: true + })) + }); + } + return []; + }; + + render() { + const { loading, dataSource } = this.state; + const { attendanceStore: { tableStore } } = this.props; + return ( +
+ +