diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/otherDeduct/editSlideContent.js b/pc4mobx/hrmSalary/pages/dataAcquisition/otherDeduct/editSlideContent.js
index 3079fa7b..6f464d9e 100644
--- a/pc4mobx/hrmSalary/pages/dataAcquisition/otherDeduct/editSlideContent.js
+++ b/pc4mobx/hrmSalary/pages/dataAcquisition/otherDeduct/editSlideContent.js
@@ -92,12 +92,9 @@ export default class EditSlideContent extends React.Component {
};
render() {
- const {
- taxAgentStore: { taxAgentOption },
- } = this.props;
const { otherDeductStore } = this.props;
const {
- slideTableStore,
+ getOtherDeductDetailList,
currentRecord,
slideColumns,
slidePageObj,
@@ -106,13 +103,22 @@ export default class EditSlideContent extends React.Component {
slideLoading,
} = otherDeductStore;
const { startDate, endDate, taxAgentId } = this.state;
+ const declareMonth = [startDate, endDate];
const pagination = {
+ current: slidePageObj.current,
+ pageSize: slidePageObj.pageSize,
total: slidePageObj.total,
showTotal: (total) => `共 ${total} 条`,
showSizeChanger: true,
onShowSizeChange(current, pageSize) {
setSlidePageObj({ ...slidePageObj, current, pageSize });
+ getOtherDeductDetailList(currentRecord.id, {
+ ...slidePageObj,
+ current,
+ pageSize,
+ declareMonth: _.filter(declareMonth, item => item)
+ });
},
onChange(current) {
setSlidePageObj({
@@ -120,6 +126,11 @@ export default class EditSlideContent extends React.Component {
current,
pageSize: slidePageObj.pageSize,
});
+ getOtherDeductDetailList(currentRecord.id, {
+ ...slidePageObj,
+ current,
+ declareMonth: _.filter(declareMonth, item => item)
+ });
},
};
const newColumns = _.map([...slideColumns], (item) => ({ ...item }));
diff --git a/pc4mobx/hrmSalary/pages/payrollFiles/index.js b/pc4mobx/hrmSalary/pages/payrollFiles/index.js
index 4e552d4e..ba3322ff 100644
--- a/pc4mobx/hrmSalary/pages/payrollFiles/index.js
+++ b/pc4mobx/hrmSalary/pages/payrollFiles/index.js
@@ -472,7 +472,7 @@ class Index extends Component {
...item,
width: item.oldWidth,
render: (text) => {
- return
{text}
+ return
{text};
}
};
});
@@ -526,7 +526,8 @@ class Index extends Component {
let arrList = [];
if (showOperateBtn && isShow === "true" && selectedKey === "fixed") {
arrList.push(
);
}
if (showOperateBtn && selectedKey === "fixed") {
diff --git a/pc4mobx/hrmSalary/stores/cumDeduct.js b/pc4mobx/hrmSalary/stores/cumDeduct.js
index b276dd0b..44b46552 100644
--- a/pc4mobx/hrmSalary/stores/cumDeduct.js
+++ b/pc4mobx/hrmSalary/stores/cumDeduct.js
@@ -191,7 +191,7 @@ export class CumDeductStore {
pageSize
});
} else {
- this.setSlideTableDataSource(list);
+ this.setSlideTableDataSource([]);
this.setSlidePageObj({
...this.slidePageObj,
total: 0
From c468ff35ffa211396b58b9d28dfb004f993fa71d 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, 23 Nov 2022 15:42:51 +0800
Subject: [PATCH 2/5] =?UTF-8?q?=E4=B8=AA=E7=A8=8E=E6=89=A3=E7=BC=B4?=
=?UTF-8?q?=E4=B9=89=E5=8A=A1=E4=BA=BA=E6=B7=BB=E5=8A=A0=E5=90=8C=E6=AD=A5?=
=?UTF-8?q?=E4=BA=BA=E5=91=98=E8=8C=83=E5=9B=B4=E7=9A=84=E5=8A=9F=E8=83=BD?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
pc4mobx/hrmSalary/apis/taxAgent.js | 11 +++++++++
pc4mobx/hrmSalary/pages/taxAgent/index.js | 27 +++++++++++++++++++----
pc4mobx/hrmSalary/stores/taxAgent.js | 6 ++++-
3 files changed, 39 insertions(+), 5 deletions(-)
diff --git a/pc4mobx/hrmSalary/apis/taxAgent.js b/pc4mobx/hrmSalary/apis/taxAgent.js
index e5177c4d..d68e965d 100644
--- a/pc4mobx/hrmSalary/apis/taxAgent.js
+++ b/pc4mobx/hrmSalary/apis/taxAgent.js
@@ -12,6 +12,17 @@ export const getTaxAgentList = (params) => {
body: JSON.stringify(params),
}).then((res) => res.json());
};
+//同步人员范围
+export const taxAgentRangeSync = (params) => {
+ return fetch("/api/bs/hrmsalary/taxAgent/range/sync", {
+ method: "POST",
+ mode: "cors",
+ headers: {
+ "Content-Type": "application/json",
+ },
+ body: JSON.stringify(params),
+ }).then((res) => res.json());
+};
// 系统管理员权限
export const getPermission = (params) => {
diff --git a/pc4mobx/hrmSalary/pages/taxAgent/index.js b/pc4mobx/hrmSalary/pages/taxAgent/index.js
index d599b779..26356da9 100644
--- a/pc4mobx/hrmSalary/pages/taxAgent/index.js
+++ b/pc4mobx/hrmSalary/pages/taxAgent/index.js
@@ -1,6 +1,6 @@
import React from "react";
import { inject, observer } from "mobx-react";
-import { Col, message, Modal, Row, Switch } from "antd";
+import { Button, Col, message, Modal, Row, Switch } from "antd";
import { WeaFormItem, WeaRightMenu, WeaSearchGroup, WeaTable, WeaTop } from "ecCom";
import { renderNoright } from "../../util"; // 渲染form数据的方法:因为多个页面都会使用,所以抽的公共方法在util中
import EditModal from "./editModal";
@@ -28,7 +28,8 @@ export default class TaxAgent extends React.Component {
devolutionStatus: 0,
conditions: editConditions,
decentralizationConditions: decentralizationConditions,
- permission: {}
+ permission: {},
+ syncLoading: false
};
}
@@ -120,7 +121,7 @@ export default class TaxAgent extends React.Component {
this.setState(
{
conditions: [{ defaultshow: true, items: conditionMap }],
- decentralizationConditions: [{ defaultshow: true, items: conditionMap }],
+ decentralizationConditions: [{ defaultshow: true, items: conditionMap }]
},
() => {
devolutionStatus === 1 ? getCondition(this.state.conditions) : getFormDecentralizationCondition(this.state.decentralizationConditions);
@@ -268,6 +269,19 @@ export default class TaxAgent extends React.Component {
}
});
};
+ taxAgentRangeSync = () => {
+ const { taxAgentStore } = this.props;
+ const { taxAgentRangeSync, getTaxAgentList } = taxAgentStore;
+ this.setState({ syncLoading: true });
+ taxAgentRangeSync({}).then(({ status, data }) => {
+ this.setState({ syncLoading: false });
+ if (status) {
+ message.success(data || "操作成功");
+ getTaxAgentList();
+ }
+ });
+ };
+
render() {
const { taxAgentStore } = this.props;
@@ -277,7 +291,8 @@ export default class TaxAgent extends React.Component {
devolutionStatus,
conditions,
decentralizationConditions,
- permission
+ permission,
+ syncLoading
} = this.state;
const {
loading,
@@ -293,6 +308,9 @@ export default class TaxAgent extends React.Component {
return renderNoright();
}
+ const btns = [
+
+ ];
const renderTipsLabel = () => {
const tipList = [
"1、个税扣缴义务人与档案中的个税扣缴义务人匹配,修改个税扣缴义务人名称,薪资档案的个税扣缴义务人数据同步更新;",
@@ -376,6 +394,7 @@ export default class TaxAgent extends React.Component {
title="个税扣缴义务人" // 文字
icon={
} // 左侧图标
iconBgcolor="#F14A2D" // 左侧图标背景色
+ buttons={btns}
showDropIcon={true}>
(this.showSearchAd = bool);
+ @action("同步人员范围")
+ taxAgentRangeSync = params => {
+ return API.taxAgentRangeSync(params);
+ };
+
// 高级搜索 - 搜索
@action
doSearch = name => {
From f8169a9080e90af2dad7bcb79fb275b94a054a86 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, 23 Nov 2022 16:50:43 +0800
Subject: [PATCH 3/5] =?UTF-8?q?=E4=B8=AA=E7=A8=8E=E6=89=A3=E7=BC=B4?=
=?UTF-8?q?=E4=B9=89=E5=8A=A1=E4=BA=BA=E6=B7=BB=E5=8A=A0=E6=90=9C=E7=B4=A2?=
=?UTF-8?q?=E6=A1=86?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
pc4mobx/hrmSalary/pages/taxAgent/index.js | 18 ++++++++++++++----
1 file changed, 14 insertions(+), 4 deletions(-)
diff --git a/pc4mobx/hrmSalary/pages/taxAgent/index.js b/pc4mobx/hrmSalary/pages/taxAgent/index.js
index 26356da9..66e84489 100644
--- a/pc4mobx/hrmSalary/pages/taxAgent/index.js
+++ b/pc4mobx/hrmSalary/pages/taxAgent/index.js
@@ -1,7 +1,7 @@
import React from "react";
import { inject, observer } from "mobx-react";
import { Button, Col, message, Modal, Row, Switch } from "antd";
-import { WeaFormItem, WeaRightMenu, WeaSearchGroup, WeaTable, WeaTop } from "ecCom";
+import { WeaFormItem, WeaRightMenu, WeaSearchGroup, WeaTable, WeaTop, WeaInputSearch } from "ecCom";
import { renderNoright } from "../../util"; // 渲染form数据的方法:因为多个页面都会使用,所以抽的公共方法在util中
import EditModal from "./editModal";
import TipLabel from "../../components/TipLabel";
@@ -14,6 +14,7 @@ export default class TaxAgent extends React.Component {
constructor(props) {
super(props);
this.state = {
+ name: '',
editModalProps: {
title: "新增个税扣缴义务人",
visible: false,
@@ -292,7 +293,8 @@ export default class TaxAgent extends React.Component {
conditions,
decentralizationConditions,
permission,
- syncLoading
+ syncLoading,
+ name
} = this.state;
const {
loading,
@@ -300,7 +302,8 @@ export default class TaxAgent extends React.Component {
dataSource,
columns,
doInit,
- hasRight
+ hasRight,
+ getTaxAgentList
} = taxAgentStore;
if (!hasRight && !loading) {
@@ -309,7 +312,14 @@ export default class TaxAgent extends React.Component {
}
const btns = [
-
+ ,
+ this.setState({ name })}
+ onSearch={() => getTaxAgentList({name})}
+ />
];
const renderTipsLabel = () => {
const tipList = [
From 32072512a9213076fd63a192cdb5948b7c40d198 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, 24 Nov 2022 17:36:00 +0800
Subject: [PATCH 4/5] =?UTF-8?q?=E8=96=AA=E8=B5=84=E6=A0=B8=E7=AE=97?=
=?UTF-8?q?=E6=B7=BB=E5=8A=A0=E6=A0=B8=E7=AE=97=E4=BA=BA=E5=91=98=E7=9A=84?=
=?UTF-8?q?=E5=8A=9F=E8=83=BD?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../hrmSalary/pages/calculateDetail/index.js | 64 ++++++++++++-------
.../pages/calculateDetail/salaryDetail.js | 6 +-
pc4mobx/hrmSalary/stores/calculate.js | 11 ++--
3 files changed, 50 insertions(+), 31 deletions(-)
diff --git a/pc4mobx/hrmSalary/pages/calculateDetail/index.js b/pc4mobx/hrmSalary/pages/calculateDetail/index.js
index d59b9429..53550cee 100644
--- a/pc4mobx/hrmSalary/pages/calculateDetail/index.js
+++ b/pc4mobx/hrmSalary/pages/calculateDetail/index.js
@@ -3,11 +3,13 @@ import UserSure from "./userSure";
import { inject, observer } from "mobx-react";
import SalaryDetail from "./salaryDetail";
import { Button, Dropdown, Menu, message, Modal } from "antd";
-import { WeaBrowser, WeaCheckbox, WeaFormItem, WeaInput, WeaSearchGroup, WeaSelect, WeaTab } from "ecCom";
+import { WeaBrowser, WeaCheckbox, WeaDropdown, WeaFormItem, WeaInput, WeaSearchGroup, WeaSelect, WeaTab } from "ecCom";
import { getQueryString } from "../../util/url";
import AcctResultImportModal from "./acctResult/importModal/acctResultImportModal";
import ProgressModal from "../../components/progressModal";
+const { ButtonSelect } = WeaDropdown;
+
@inject("calculateStore", "salaryFileStore")
@observer
export default class CalculateDetail extends React.Component {
@@ -27,7 +29,8 @@ export default class CalculateDetail extends React.Component {
fieldData: {},
acctResultImportVisiable: false,
progressVisible: false,
- progress: 0
+ progress: 0,
+ accountIds: []
};
this.id = "";
this.timer;
@@ -100,8 +103,8 @@ export default class CalculateDetail extends React.Component {
this.setState({ searchItemsValue: { ...this.state.searchItemsValue, [key]: val } })}/>
@@ -126,19 +129,23 @@ export default class CalculateDetail extends React.Component {
};
// 核算点击事件
- handleAccount() {
+ handleAccount = (key) => {
const { calculateStore } = this.props;
- const {
- acctresultAccounting,
- acctResultList,
- getCalculateProgress
- } = calculateStore;
+ const { acctresultAccounting, getCalculateProgress } = calculateStore;
+ if (key === "SELECT" && _.isEmpty(this.state.accountIds)) {
+ message.warning("请先选择表格数据");
+ return;
+ }
Modal.confirm({
title: "信息确认",
content: "点击核算,公式项将按照公式逻辑核算,核算结果将覆盖原数据",
onOk: () => {
this.setState({ progress: 0 });
- acctresultAccounting(this.id).then(() => {
+ let payload = { salaryAcctRecordId: this.id };
+ if (key === "SELECT") {
+ payload = _.assign(payload, { employeeIds: this.state.accountIds });
+ }
+ acctresultAccounting(payload).then(() => {
this.setState({
progressVisible: true
});
@@ -152,7 +159,8 @@ export default class CalculateDetail extends React.Component {
clearInterval(this.timer);
this.timer = null;
this.setState({
- progressVisible: false
+ progressVisible: false,
+ accountIds: []
});
message.success("核算完成");
// acctResultList({ salaryAcctRecordId: this.id });
@@ -163,7 +171,7 @@ export default class CalculateDetail extends React.Component {
listType: "",
url: "/api/bs/hrmsalary/salaryacct/acctresult/list",
queryParams: {
- salaryAcctRecordId,
+ salaryAcctRecordId
}
};
childFrameObj.contentWindow.postMessage(JSON.stringify(payload), "*");
@@ -171,7 +179,8 @@ export default class CalculateDetail extends React.Component {
clearInterval(this.timer);
this.timer = null;
this.setState({
- progressVisible: false
+ progressVisible: false,
+ accountIds: []
});
message.error(data.message);
}
@@ -183,7 +192,7 @@ export default class CalculateDetail extends React.Component {
onCancel() {
}
});
- }
+ };
// 更多选项点击
handleMenuClick = e => {
@@ -199,7 +208,7 @@ export default class CalculateDetail extends React.Component {
);
} else if (e.key == "3") {
window.open(
- '/api/bs/hrmsalary/salaryacct/acctresult/export?salaryAcctRecordId=' + this.id +"&ids="
+ "/api/bs/hrmsalary/salaryacct/acctresult/export?salaryAcctRecordId=" + this.id + "&ids="
);
}
};
@@ -223,7 +232,7 @@ export default class CalculateDetail extends React.Component {
url: "/api/bs/hrmsalary/salaryacct/acctresult/list",
queryParams: {
salaryAcctRecordId,
- ...params,
+ ...params
}
};
childFrameObj.contentWindow.postMessage(JSON.stringify(payload), "*");
@@ -248,11 +257,19 @@ export default class CalculateDetail extends React.Component {
const renderRightOperation = () => {
return [
- ,
+ this.handleAccount(key)}
+ />,
+ // ,
更多
@@ -333,7 +350,8 @@ export default class CalculateDetail extends React.Component {
searchsBaseValue={this.state.searchItemsValue.employeeName} // 外部input搜索值受控: 这里和高级搜索的requestname同步form.getFormParams().username
/>
{selectedKey == 0 && }
- {selectedKey == 1 && }
+ {selectedKey == 1 && this.setState({ accountIds: ids })}
+ employeeName={this.state.searchValue}/>}
{acctResultImportVisiable &&
diff --git a/pc4mobx/hrmSalary/stores/calculate.js b/pc4mobx/hrmSalary/stores/calculate.js
index 24daf457..c1f420ff 100644
--- a/pc4mobx/hrmSalary/stores/calculate.js
+++ b/pc4mobx/hrmSalary/stores/calculate.js
@@ -332,7 +332,7 @@ export class calculateStore {
delete params[key];
}
}
- return new Promise((resolve,reject) => {
+ return new Promise((resolve, reject) => {
API.acctResultList({ ...params }).then(res => {
if (res.status) {
let list = res.data.pageInfo.list ? res.data.pageInfo.list : [];
@@ -366,11 +366,10 @@ export class calculateStore {
// 核算结果--薪资核算
@action
- acctresultAccounting = (salaryAcctRecordId) => {
+ acctresultAccounting = (params) => {
return new Promise((resolve, reject) => {
- API.acctresultAccounting({ salaryAcctRecordId }).then(res => {
+ API.acctresultAccounting(params).then(res => {
if (res.status) {
- // message.success("核算成功")
resolve();
} else {
message.error(res.errormsg || "核算失败");
@@ -449,7 +448,7 @@ export class calculateStore {
message.error(res.errormsg || "归档失败");
reject(res);
}
- })
+ });
});
};
@@ -662,6 +661,6 @@ export class calculateStore {
@action("更新薪资核算结果的锁定状态")
updateLockStatus = (params) => {
- return API.updateLockStatus(params)
+ return API.updateLockStatus(params);
};
}
From c6f170d373e0c77cf859ff3f5ca0af020868deec 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, 24 Nov 2022 17:37:16 +0800
Subject: [PATCH 5/5] =?UTF-8?q?=E8=96=AA=E8=B5=84=E6=A0=B8=E7=AE=97?=
=?UTF-8?q?=E6=B7=BB=E5=8A=A0=E6=A0=B8=E7=AE=97=E4=BA=BA=E5=91=98=E7=9A=84?=
=?UTF-8?q?=E5=8A=9F=E8=83=BD?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
pc4mobx/hrmSalary/pages/calculateDetail/salaryDetail.js | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/pc4mobx/hrmSalary/pages/calculateDetail/salaryDetail.js b/pc4mobx/hrmSalary/pages/calculateDetail/salaryDetail.js
index 4114885a..a7791cba 100644
--- a/pc4mobx/hrmSalary/pages/calculateDetail/salaryDetail.js
+++ b/pc4mobx/hrmSalary/pages/calculateDetail/salaryDetail.js
@@ -234,8 +234,8 @@ export default class SalaryDetail extends React.Component {