{theme || ""}
diff --git a/pc4mobx/hrmSalary/pages/payroll/templatePreview/index.less b/pc4mobx/hrmSalary/pages/payroll/templatePreview/index.less
index 7eae1948..9a7c033c 100644
--- a/pc4mobx/hrmSalary/pages/payroll/templatePreview/index.less
+++ b/pc4mobx/hrmSalary/pages/payroll/templatePreview/index.less
@@ -173,8 +173,8 @@
.ph-switch {
height: 100%;
- margin: 0 auto;
- text-align: center;
+ display: flex;
+ justify-content: center;
.active, .phs-btn:hover {
background-color: rgba(0, 0, 0, .15);
@@ -184,8 +184,9 @@
.phs-btn {
height: 50px;
min-width: 88px;
- line-height: 50px;
- display: inline-block;
+ display: flex;
+ justify-content: center;
+ align-items: center;
color: #fff;
padding: 0 15px;
cursor: pointer;
From ae43a2aa7cc313cf7362f28255b5944006dc7695 Mon Sep 17 00:00:00 2001
From: lys <971387674@qq.com>
Date: Fri, 18 Apr 2025 16:21:49 +0800
Subject: [PATCH 17/41] release/2.19.1.2501.01
---
.../hrmSalary/pages/calculate/calculate.js | 56 +++++++++++++++----
.../components/calculateQuery/index.js | 2 +-
.../components/calculateTablelist/index.js | 8 ++-
pc4mobx/hrmSalary/pages/calculate/config.js | 19 +++++++
pc4mobx/hrmSalary/pages/calculate/index.less | 26 +++++++++
5 files changed, 97 insertions(+), 14 deletions(-)
create mode 100644 pc4mobx/hrmSalary/pages/calculate/config.js
diff --git a/pc4mobx/hrmSalary/pages/calculate/calculate.js b/pc4mobx/hrmSalary/pages/calculate/calculate.js
index e6207394..b23739b8 100644
--- a/pc4mobx/hrmSalary/pages/calculate/calculate.js
+++ b/pc4mobx/hrmSalary/pages/calculate/calculate.js
@@ -6,7 +6,8 @@
*/
import React, { Component } from "react";
import { inject, observer } from "mobx-react";
-import { WeaLocaleProvider, WeaTop } from "ecCom";
+import { WeaLocaleProvider, WeaTools, WeaTop } from "ecCom";
+import { WeaForm } from "comsMobx";
import { Button, message, Modal } from "antd";
import moment from "moment";
import CalculateQuery from "./components/calculateQuery";
@@ -15,9 +16,15 @@ import CalculateDialog from "./components/calculateDialog";
import ProgressModal from "../../components/progressModal";
import LogDialog from "../../components/logViewModal";
import { backCalculate, deleteSalaryacct, fileSalaryAcct, reAccounting } from "../../apis/calculate";
+import FormInfo from "../../components/FormInfo";
+import { queryConditions } from "./config";
+import { getTaxAgentSelectList } from "../../apis/taxAgent";
+import cs from "classnames";
import "./index.less";
+const getKey = WeaTools.getKey;
const getLabel = WeaLocaleProvider.getLabel;
+const form = new WeaForm();
@inject("calculateStore", "taxAgentStore")
@observer
@@ -31,17 +38,32 @@ class Calculate extends Component {
moment(new Date()).subtract(1, "year").startOf("year").format("YYYY-MM"),
moment(new Date()).endOf("year").format("YYYY-MM")
]
- }, isRefresh: false, logDialogVisible: false,
+ }, isRefresh: false, logDialogVisible: false, conditions: [],
progressModule: { visible: false, progress: 0, title: getLabel(111, "正在归档中请稍后") },
- calcDaialog: { visible: false, title: "" }
+ calcDaialog: { visible: false, title: "" }, showAdvance: false
};
this.timer = null;
this.handleDebounce = null;
}
+ async componentDidMount() {
+ const { data } = await getTaxAgentSelectList();
+ this.setState({
+ conditions: _.map(queryConditions, item => ({
+ ...item, items: _.map(item.items, o => {
+ o = { ...o, label: getLabel(o.lanId, o.label) };
+ if (getKey(o) === "taxAgentIds") {
+ return { ...o, options: _.map(data, k => ({ key: k.id, showname: k.content })) };
+ }
+ return { ...o };
+ })
+ }))
+ }, () => form.initFormFields(this.state.conditions));
+ }
+
renderCalculateOpts = () => {
const { taxAgentStore: { showOperateBtn } } = this.props;
- const { queryParams, isRefresh } = this.state;
+ const { queryParams, isRefresh, showAdvance } = this.state;
let calculateOpts = [
,
-
this.setState({
- isRefresh: _.keys(v)[0] === "name" ? isRefresh : !isRefresh,
- queryParams: { ...queryParams, ...v }
- })} onSearch={() => this.setState({ isRefresh: !isRefresh })}/>
+ this.setState({ showAdvance: !showAdvance })}
+ onChange={v => this.setState({
+ isRefresh: _.keys(v)[0] === "name" ? isRefresh : !isRefresh,
+ queryParams: { ...queryParams, ...v }
+ })} onSearch={() => this.setState({ isRefresh: !isRefresh })}/>
];
return !showOperateBtn ? calculateOpts.slice(1) : calculateOpts;
};
@@ -188,7 +211,9 @@ class Calculate extends Component {
};
render() {
- const { queryParams, isRefresh, calcDaialog, progressModule, logDialogVisible, filterConditions } = this.state;
+ const {
+ queryParams, isRefresh, calcDaialog, progressModule, logDialogVisible, filterConditions, conditions, showAdvance
+ } = this.state;
return (
} iconBgcolor="#F14A2D"
buttons={this.renderCalculateOpts()} className="calculate-main-layout" showDropIcon
@@ -201,7 +226,18 @@ class Calculate extends Component {
]}
>
-
+
+
+
+
+
+
+
+
+
this.setState({
calcDaialog: { ...calcDaialog, visible: false },
diff --git a/pc4mobx/hrmSalary/pages/calculate/components/calculateQuery/index.js b/pc4mobx/hrmSalary/pages/calculate/components/calculateQuery/index.js
index e8e89b97..0c74ccd5 100644
--- a/pc4mobx/hrmSalary/pages/calculate/components/calculateQuery/index.js
+++ b/pc4mobx/hrmSalary/pages/calculate/components/calculateQuery/index.js
@@ -27,7 +27,7 @@ class Index extends Component {
onChange={v => this.props.onChange({ name: v })}
onSearch={this.props.onSearch}
/>
- {getLabel(111, "高级搜索")}
+ {getLabel(111, "高级搜索")}
);
diff --git a/pc4mobx/hrmSalary/pages/calculate/components/calculateTablelist/index.js b/pc4mobx/hrmSalary/pages/calculate/components/calculateTablelist/index.js
index eecfa1db..63ab2e87 100644
--- a/pc4mobx/hrmSalary/pages/calculate/components/calculateTablelist/index.js
+++ b/pc4mobx/hrmSalary/pages/calculate/components/calculateTablelist/index.js
@@ -29,12 +29,14 @@ class Index extends Component {
}
getSalaryAcctList = (props) => {
- const { pageInfo } = this.state;
- const { queryParams } = props;
+ const { pageInfo } = this.state, { queryParams, form } = props;
+ const { taxAgentIds } = form.getFormParams();
const { dateRange, ...extra } = queryParams;
const [startMonthStr, endMonthStr] = dateRange || [];
const params = { startMonthStr, endMonthStr, ...extra };
- const payload = { ...pageInfo, ...params };
+ const payload = {
+ ...pageInfo, ...params, taxAgentIds: taxAgentIds ? taxAgentIds.split(",") : []
+ };
this.setState({ loading: true });
getSalaryAcctList(payload).then(({ status, data }) => {
this.setState({ loading: false });
diff --git a/pc4mobx/hrmSalary/pages/calculate/config.js b/pc4mobx/hrmSalary/pages/calculate/config.js
new file mode 100644
index 00000000..02da5b10
--- /dev/null
+++ b/pc4mobx/hrmSalary/pages/calculate/config.js
@@ -0,0 +1,19 @@
+export const queryConditions = [
+ {
+ items: [
+ {
+ conditionType: "SELECT",
+ domkey: ["taxAgentIds"],
+ fieldcol: 14,
+ label: "个税扣缴义务人",
+ lanI: 111,
+ multiple: true,
+ options: [],
+ labelcol: 6,
+ value: "",
+ viewAttr: 2
+ }
+ ],
+ defaultshow: true
+ }
+];
diff --git a/pc4mobx/hrmSalary/pages/calculate/index.less b/pc4mobx/hrmSalary/pages/calculate/index.less
index d7f45047..2e73f6b2 100644
--- a/pc4mobx/hrmSalary/pages/calculate/index.less
+++ b/pc4mobx/hrmSalary/pages/calculate/index.less
@@ -90,6 +90,32 @@
overflow-y: hidden;
}
+ .advance-calc {
+ display: none;
+ background: #FFF;
+ margin-bottom: 8px;
+
+ .advance-calc-btns {
+ display: flex;
+ justify-content: center;
+ align-items: center;
+ padding: 15px 0;
+ border-top: 1px solid #dadada;
+
+ button {
+ margin-right: 15px;
+ }
+ }
+
+ .wea-search-group, .wea-content {
+ padding: 0;
+ }
+ }
+
+ .show-advance-calc {
+ display: block;
+ }
+
.calculate-body {
height: 100%;
width: 100%;
From 51ac08d6fc10e427cf89d3176f7081cb3cc99278 Mon Sep 17 00:00:00 2001
From: lys <971387674@qq.com>
Date: Tue, 22 Apr 2025 09:35:04 +0800
Subject: [PATCH 18/41] release/2.19.1.2501.01
---
pc4mobx/hrmSalary/pages/mySalary/mySalaryView.js | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/pc4mobx/hrmSalary/pages/mySalary/mySalaryView.js b/pc4mobx/hrmSalary/pages/mySalary/mySalaryView.js
index 5fa76f93..56e1f2f4 100644
--- a/pc4mobx/hrmSalary/pages/mySalary/mySalaryView.js
+++ b/pc4mobx/hrmSalary/pages/mySalary/mySalaryView.js
@@ -14,6 +14,8 @@ import { confirmSalaryBill, feedBackSalaryBill, payrollCheckType } from "../../a
import CaptchaModal from "../../components/captchaModal";
import "./index.less";
+const isIPhone = new RegExp("\\biPhone\\b|\\biPod\\b", "i").test(window.navigator.userAgent);
+const isEm = window.navigator.userAgent.indexOf("E-Mobile7") >= 0;
const { getLabel } = WeaLocaleProvider;
@inject("mySalaryStore")
@@ -123,7 +125,7 @@ export const ConfirmBtns = (props) => {
}
{
- props.showFeedback === "1" &&
+ ((props.showFeedback === "1" && !isIPhone) || (props.showFeedback === "1" && isIPhone && isEm)) &&
}
;
From d652b2cdc61169d3c870781733a9a0a30f048e03 Mon Sep 17 00:00:00 2001
From: lys <971387674@qq.com>
Date: Wed, 23 Apr 2025 16:13:49 +0800
Subject: [PATCH 19/41] release/2.19.1.2501.01
---
.../pages/declare/components/declareQuery/index.js | 2 +-
.../declare/components/declareTablelist/index.js | 11 ++++++-----
2 files changed, 7 insertions(+), 6 deletions(-)
diff --git a/pc4mobx/hrmSalary/pages/declare/components/declareQuery/index.js b/pc4mobx/hrmSalary/pages/declare/components/declareQuery/index.js
index f5627a0c..e85383ca 100644
--- a/pc4mobx/hrmSalary/pages/declare/components/declareQuery/index.js
+++ b/pc4mobx/hrmSalary/pages/declare/components/declareQuery/index.js
@@ -17,7 +17,7 @@ class Index extends Component {
return (
- {getLabel(543549, "薪资所属月:")}
+ {getLabel(111, "税款所属期:")}
this.props.onChange({ dateRange: v })}/>
diff --git a/pc4mobx/hrmSalary/pages/declare/components/declareTablelist/index.js b/pc4mobx/hrmSalary/pages/declare/components/declareTablelist/index.js
index b2cab8ff..7d119c09 100644
--- a/pc4mobx/hrmSalary/pages/declare/components/declareTablelist/index.js
+++ b/pc4mobx/hrmSalary/pages/declare/components/declareTablelist/index.js
@@ -8,7 +8,7 @@ import React, { Component } from "react";
import { WeaLocaleProvider, WeaTable } from "ecCom";
import { Dropdown, Menu, message, Modal } from "antd";
import { getDeclareList, withDrawTaxDeclaration } from "../../../../apis/declare";
-import { sysConfCodeRule } from "../../../../apis/ruleconfig";
+import { sysConfCodeRule, sysinfo } from "../../../../apis/ruleconfig";
const getLabel = WeaLocaleProvider.getLabel;
@@ -35,9 +35,9 @@ class Index extends Component {
if (status && data === "1") this.setState({ showWithDrawBtn: data === "1" });
});
};
- getDeclareList = (props) => {
- const { pageInfo } = this.state;
- const { queryParams } = props;
+ getDeclareList = async (props) => {
+ const { data: sysData } = await sysinfo();
+ const { pageInfo } = this.state, { queryParams } = props;
const { dateRange, ...extra } = queryParams;
const [fromSalaryMonthStr, endSalaryMonthStr] = dateRange || [];
const params = { fromSalaryMonthStr, endSalaryMonthStr, ...extra };
@@ -46,7 +46,8 @@ class Index extends Component {
getDeclareList(payload).then(({ status, data }) => {
this.setState({ loading: false });
if (status) {
- const { columns, list: dataSource, pageNum, pageSize, total } = data;
+ let { columns, list: dataSource, pageNum, pageSize, total } = data;
+ sysData["TAX_DECLARATION_DATE_TYPE"] === "1" && (columns = _.filter(columns, o => o.dataIndex !== "salaryMonth"));
this.setState({
dataSource, pageInfo: { ...pageInfo, pageNum, pageSize, total },
columns: _.map(columns, o => {
From 9a50947d8aa7be5b730b863d5dd18449006888bc Mon Sep 17 00:00:00 2001
From: lys <971387674@qq.com>
Date: Wed, 23 Apr 2025 17:34:46 +0800
Subject: [PATCH 20/41] release/2.19.1.2501.01
---
.../pages/declare/components/declareTablelist/index.js | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/pc4mobx/hrmSalary/pages/declare/components/declareTablelist/index.js b/pc4mobx/hrmSalary/pages/declare/components/declareTablelist/index.js
index 7d119c09..74100061 100644
--- a/pc4mobx/hrmSalary/pages/declare/components/declareTablelist/index.js
+++ b/pc4mobx/hrmSalary/pages/declare/components/declareTablelist/index.js
@@ -39,8 +39,8 @@ class Index extends Component {
const { data: sysData } = await sysinfo();
const { pageInfo } = this.state, { queryParams } = props;
const { dateRange, ...extra } = queryParams;
- const [fromSalaryMonthStr, endSalaryMonthStr] = dateRange || [];
- const params = { fromSalaryMonthStr, endSalaryMonthStr, ...extra };
+ const [fromSalaryMonth, endSalaryMonth] = dateRange || [];
+ const params = { fromSalaryMonth: fromSalaryMonth + "-01", endSalaryMonth: endSalaryMonth + "-01", ...extra };
const payload = { ...pageInfo, ...params };
this.setState({ loading: true });
getDeclareList(payload).then(({ status, data }) => {
From dee1059ca7fd18a9ab9e39e68cfe095ef3cb5c49 Mon Sep 17 00:00:00 2001
From: lys <971387674@qq.com>
Date: Thu, 24 Apr 2025 16:38:36 +0800
Subject: [PATCH 21/41] release/2.19.1.2501.01
---
.../components/attendanceDataViewSlide.js | 78 ++++++++++++-------
.../attendance/components/index.less | 4 +-
2 files changed, 51 insertions(+), 31 deletions(-)
diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceDataViewSlide.js b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceDataViewSlide.js
index be64c8e8..2f4804b6 100644
--- a/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceDataViewSlide.js
+++ b/pc4mobx/hrmSalary/pages/dataAcquisition/attendance/components/attendanceDataViewSlide.js
@@ -5,9 +5,9 @@
* Date: 2023/3/7
*/
import React, { Component } from "react";
-import { WeaInputSearch, WeaLocaleProvider, WeaSlideModal, WeaTable, WeaTop } from "ecCom";
-import { Button } from "antd";
+import { WeaInputSearch, WeaLocaleProvider, WeaSlideModal, WeaTop } from "ecCom";
import { viewAttendQuote } from "../../../../apis/attendance";
+import { Button, Spin } from "antd";
import "./index.less";
const { getLabel } = WeaLocaleProvider;
@@ -16,11 +16,31 @@ 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: [], pageInfo: { current: 1, pageSize: 10, total: 0 }
};
}
+ componentDidMount() {
+ window.addEventListener("message", this.handleReceive, false);
+ }
+
+ componentWillUnmount() {
+ window.removeEventListener("message", this.handleReceive, false);
+ }
+
+ handleReceive = async ({ data }) => {
+ const { type, payload: { id, params } = {} } = data;
+ if (type === "turn") {
+ switch (id) {
+ case "PAGEINFO":
+ this.setState({ pageInfo: { ...this.state.pageInfo, ...params } }, () => this.viewAttendQuote());
+ break;
+ default:
+ break;
+ }
+ }
+ };
+
componentWillReceiveProps(nextProps, nextContext) {
if (nextProps.visible !== this.props.visible && nextProps.visible) {
document.querySelector(".attendanceRefWrapper").classList.add("zIndex0-attendance");
@@ -33,19 +53,29 @@ class AttendanceDataViewSlide extends Component {
viewAttendQuote = (extraPayload = {}, props) => {
const { loading, pageInfo, keyword } = this.state;
- const { attendQuoteId } = props;
+ const { attendQuoteId } = props || this.props;
this.setState({ loading: { ...loading, query: true } });
viewAttendQuote({ ...pageInfo, attendQuoteId, keyword, ...extraPayload }).then(({ status, data }) => {
this.setState({ loading: { ...loading, query: false } });
if (status) {
const { columns, list: dataSource, pageNum: current, pageSize, total } = data.pageInfo;
this.setState({
- pageInfo: { ...pageInfo, current, pageSize, total }, dataSource,
- columns: _.map(columns, (o, i) => ({ ...o, width: 150, fixed: i === 0 ? "left" : null }))
- });
+ pageInfo: { ...pageInfo, current, pageSize, total }, dataSource
+ }, () => this.postMessageToChild({
+ pageInfo: this.state.pageInfo, dataSource, showRowSelection: false, unitTableType: "attendanceView",
+ columns: _.map(columns, (o, i) => ({ ...o, width: 150, fixed: i === 0 ? "left" : false }))
+ }));
}
}).catch(() => this.setState({ loading: { ...loading, query: false } }));
};
+ postMessageToChild = (payload = {}) => {
+ const i18n = {
+ "操作": getLabel(30585, "操作"), "编辑": getLabel(111, "编辑"), "共": getLabel(18609, "共"),
+ "条": getLabel(18256, "条")
+ };
+ const childFrameObj = document.getElementById("attendanceViewTable");
+ childFrameObj && childFrameObj.contentWindow.postMessage(JSON.stringify({ ...payload, i18n }), "*");
+ };
handleExportAttendQuote = () => {
if (!this.handleDebounce) {
this.handleDebounce = _.debounce(() => {
@@ -60,24 +90,7 @@ class AttendanceDataViewSlide extends Component {
render() {
const { showOperateBtn, salaryYearMonth, ...extra } = this.props;
- const { columns, dataSource, loading, pageInfo, keyword } = this.state;
- const pagination = {
- ...pageInfo,
- showTotal: (total) => `共 ${total} 条`,
- pageSizeOptions: ["10", "20", "50", "100"],
- showSizeChanger: true,
- showQuickJumper: true,
- onShowSizeChange: (current, pageSize) => {
- this.setState({
- pageInfo: { ...pageInfo, current, pageSize }
- }, () => this.viewAttendQuote({}, this.props));
- },
- onChange: (current) => {
- this.setState({
- pageInfo: { ...pageInfo, current }
- }, () => this.viewAttendQuote({}, this.props));
- }
- };
+ const { loading, keyword } = this.state;
const btns = [
,
{getLabel(543376, "考勤周期")}:{salaryYearMonth}