}>
@@ -80,6 +81,7 @@ class LedgerSalaryItemBaseInfo extends Component {
className="wea-sortable-grid-item"
/>
{
return {
diff --git a/pc4mobx/hrmSalary/pages/payrollRelease/components/payrollCopyDialog/index.js b/pc4mobx/hrmSalary/pages/payrollRelease/components/payrollCopyDialog/index.js
index 904c84d2..611513d5 100644
--- a/pc4mobx/hrmSalary/pages/payrollRelease/components/payrollCopyDialog/index.js
+++ b/pc4mobx/hrmSalary/pages/payrollRelease/components/payrollCopyDialog/index.js
@@ -8,9 +8,10 @@ import React, { Component } from "react";
import { inject, observer } from "mobx-react";
import { WeaDialog, WeaLocaleProvider, WeaTools } from "ecCom";
import { Button, message } from "antd";
+import { postFetch } from "../../../../util/request";
import { getSearchs } from "../../../../util";
import { copyConditions } from "../conditions";
-import { duplicatePayroll, getPayrollTemplateLedgerList } from "../../../../apis/payroll";
+import { duplicatePayroll } from "../../../../apis/payroll";
const getLabel = WeaLocaleProvider.getLabel;
const getKey = WeaTools.getKey;
@@ -31,29 +32,30 @@ class Index extends Component {
}
getPayrollTemplateLedgerList = (props) => {
- getPayrollTemplateLedgerList().then(({ status, data }) => {
- if (status) {
- this.setState({
- conditions: _.map(copyConditions, item => {
- return {
- ...item, items: _.map(item.items, o => {
- if (getKey(o) === "salarySobId") {
- return {
- ...o, label: getLabel(o.lanId, o.label),
- options: _.map(data, d => ({ key: d.id, showname: d.content }))
- };
- } else {
- return { ...o, label: getLabel(o.lanId, o.label) };
- }
- })
- };
- })
- }, () => {
- props.payrollStore.payrollCopyForm.initFormFields(this.state.conditions);
- props.payrollStore.payrollCopyForm.updateFields({ salarySobId: { value: props.salarySobId } });
- });
- }
- });
+ postFetch("/api/bs/hrmsalary/salarysob/listAuth", { filterType: "ADMIN_DATA" })
+ .then(({ status, data }) => {
+ if (status) {
+ this.setState({
+ conditions: _.map(copyConditions, item => {
+ return {
+ ...item, items: _.map(item.items, o => {
+ if (getKey(o) === "salarySobId") {
+ return {
+ ...o, label: getLabel(o.lanId, o.label),
+ options: _.map(data, d => ({ key: String(d.id), showname: d.name }))
+ };
+ } else {
+ return { ...o, label: getLabel(o.lanId, o.label) };
+ }
+ })
+ };
+ })
+ }, () => {
+ props.payrollStore.payrollCopyForm.initFormFields(this.state.conditions);
+ props.payrollStore.payrollCopyForm.updateFields({ salarySobId: { value: props.salarySobId } });
+ });
+ }
+ });
};
save = () => {
diff --git a/pc4mobx/hrmSalary/pages/payrollRelease/index.js b/pc4mobx/hrmSalary/pages/payrollRelease/index.js
index 019e3ad7..b601298a 100644
--- a/pc4mobx/hrmSalary/pages/payrollRelease/index.js
+++ b/pc4mobx/hrmSalary/pages/payrollRelease/index.js
@@ -54,14 +54,14 @@ class Index extends Component {
];
break;
case "template":
- const loading = this.templateRef ? this.templateRef.wrappedInstance.state.delLoading : false;
- const delDisabled = !this.templateRef || _.isEmpty(this.templateRef.wrappedInstance.state.selectedRowKeys);
+ const loading = this.templateRef ? this.templateRef.state.delLoading : false;
+ const delDisabled = !this.templateRef || _.isEmpty(this.templateRef.state.selectedRowKeys);
const btns = [
,
];
const queryBtns = [
@@ -92,7 +92,7 @@ class Index extends Component {
case "grant":
dom = this.setState({ selectedKey: "template" }, () => {
- this.templateRef.wrappedInstance.handleOpts({ key: "edit" }, { id });
+ this.templateRef.handleOpts({ key: "edit" }, { id });
})}
onFilterLog={(type, targetid) => this.onDropMenuClick(type, targetid)}
/>;
diff --git a/pc4mobx/hrmSalary/pages/roleManagement/index.js b/pc4mobx/hrmSalary/pages/roleManagement/index.js
index 9d667ad7..0e4f7fb2 100644
--- a/pc4mobx/hrmSalary/pages/roleManagement/index.js
+++ b/pc4mobx/hrmSalary/pages/roleManagement/index.js
@@ -83,6 +83,9 @@ class Index extends Component {
const {
query, dataSource, columns, pageInfo, loading, selectedRowKeys, addRoleDialog, roleSetDialog
} = this.state;
+ const { taxAgentStore: { PageAndOptAuth } } = this.props;
+ const admin = PageAndOptAuth.opts.includes("admin");
+
const buttons = [