Compare commits
3 Commits
f4726da0fc
...
3be80d9ab2
| Author | SHA1 | Date |
|---|---|---|
|
|
3be80d9ab2 | |
|
|
c1269e7dd3 | |
|
|
2b32f348ba |
|
|
@ -24,7 +24,7 @@ import "../index.less";
|
||||||
const WeaTableComx = WeaTableNew.WeaTable;
|
const WeaTableComx = WeaTableNew.WeaTable;
|
||||||
const { getLabel } = WeaLocaleProvider;
|
const { getLabel } = WeaLocaleProvider;
|
||||||
|
|
||||||
@inject("attendanceStore")
|
@inject("attendanceStore", "taxAgentStore")
|
||||||
@observer
|
@observer
|
||||||
class SalaryDetails extends Component {
|
class SalaryDetails extends Component {
|
||||||
constructor(props) {
|
constructor(props) {
|
||||||
|
|
@ -256,7 +256,8 @@ class SalaryDetails extends Component {
|
||||||
const {
|
const {
|
||||||
loading, dataSource, transferDialog, tempDialog, tempPageList, templateId, tempManageDialog, tempManageQuery
|
loading, dataSource, transferDialog, tempDialog, tempPageList, templateId, tempManageDialog, tempManageQuery
|
||||||
} = this.state;
|
} = this.state;
|
||||||
const { dateRange, showSearchAd } = this.props;
|
const { taxAgentStore: { PageAndOptAuth }, dateRange, showSearchAd } = this.props;
|
||||||
|
const { isOpenDevolution, isChief } = PageAndOptAuth;
|
||||||
const { dialogType } = transferDialog;
|
const { dialogType } = transferDialog;
|
||||||
return (<React.Fragment>
|
return (<React.Fragment>
|
||||||
<div className="query-div">
|
<div className="query-div">
|
||||||
|
|
@ -289,7 +290,7 @@ class SalaryDetails extends Component {
|
||||||
transferDialog: { ...transferDialog, completeURL: "", visible: false }
|
transferDialog: { ...transferDialog, completeURL: "", visible: false }
|
||||||
})}
|
})}
|
||||||
buttons={
|
buttons={
|
||||||
dialogType === "temp" ? [
|
dialogType === "temp" && isOpenDevolution && isChief ? [
|
||||||
<Button type="primary"
|
<Button type="primary"
|
||||||
onClick={this.handelAddTemp}>{getLabel(111, "存为模板")}</Button>,
|
onClick={this.handelAddTemp}>{getLabel(111, "存为模板")}</Button>,
|
||||||
<Button type="ghost" onClick={() => this.setState({
|
<Button type="ghost" onClick={() => this.setState({
|
||||||
|
|
|
||||||
|
|
@ -33,7 +33,7 @@ class Index extends Component {
|
||||||
conditions: [],
|
conditions: [],
|
||||||
convertConditions: [],
|
convertConditions: [],
|
||||||
reportConditions: [],
|
reportConditions: [],
|
||||||
selectedKey: "salaryDetail",
|
selectedKey: "statistics",
|
||||||
reportName: "",
|
reportName: "",
|
||||||
keyword: "",
|
keyword: "",
|
||||||
year: moment().format("YYYY"),
|
year: moment().format("YYYY"),
|
||||||
|
|
@ -323,12 +323,12 @@ class Index extends Component {
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
const tabs = [
|
const tabs = [
|
||||||
// { key: "statistics", title: getLabel(111, "统计表") },
|
{ key: "statistics", title: getLabel(111, "统计表") },
|
||||||
// { key: "detail", title: getLabel(111, "员工明细") },
|
// { key: "detail", title: getLabel(111, "员工明细") },
|
||||||
{ key: "salaryDetail", title: getLabel(111, "薪资明细") }
|
{ key: "salaryDetail", title: getLabel(111, "薪资明细") }
|
||||||
];
|
];
|
||||||
dropMenuDatas = selectedKey === "salaryDetail" ? dropMenuDatas.slice(-1) : dropMenuDatas.slice(0, 1);
|
dropMenuDatas = selectedKey === "salaryDetail" ? dropMenuDatas.slice(-1) : dropMenuDatas.slice(0, 1);
|
||||||
isOpenDevolution && !isChief && dropMenuDatas.shift();
|
// isOpenDevolution && !isChief && dropMenuDatas.shift();
|
||||||
return (
|
return (
|
||||||
<WeaReqTop
|
<WeaReqTop
|
||||||
title={getLabel(111, "薪酬统计报表")} icon={<i className="icon-coms-fa"/>} selectedKey={selectedKey}
|
title={getLabel(111, "薪酬统计报表")} icon={<i className="icon-coms-fa"/>} selectedKey={selectedKey}
|
||||||
|
|
|
||||||
|
|
@ -252,7 +252,7 @@ class EditCalcTable extends Component {
|
||||||
calculateStore: { ECSearchForm, otherConditions }, routeParams: { salaryAcctRecordId },
|
calculateStore: { ECSearchForm, otherConditions }, routeParams: { salaryAcctRecordId },
|
||||||
taxAgentStore: { showOperateBtn, PageAndOptAuth }, calcDetail = false
|
taxAgentStore: { showOperateBtn, PageAndOptAuth }, calcDetail = false
|
||||||
} = this.props;
|
} = this.props;
|
||||||
const { confirmAuth, submitAuth } = toJS(PageAndOptAuth);
|
const { confirmAuth, submitAuth, isAdminEnable, isChief } = toJS(PageAndOptAuth);
|
||||||
const {
|
const {
|
||||||
employeeIds, subcompanyIds, departmentIds, positionIds, statuses, htqslxList, rsdlgsList, ...extra
|
employeeIds, subcompanyIds, departmentIds, positionIds, statuses, htqslxList, rsdlgsList, ...extra
|
||||||
} = ECSearchForm.getFormParams();
|
} = ECSearchForm.getFormParams();
|
||||||
|
|
@ -277,8 +277,9 @@ class EditCalcTable extends Component {
|
||||||
const sumRowlistUrl = this.props.showTotalCell ? "/api/bs/hrmsalary/salaryacct/acctresult/sum" : "";
|
const sumRowlistUrl = this.props.showTotalCell ? "/api/bs/hrmsalary/salaryacct/acctresult/sum" : "";
|
||||||
this.postMessageToChild({
|
this.postMessageToChild({
|
||||||
dataSource, pageInfo, selectedRowKeys, showTotalCell: this.props.showTotalCell, sumRowlistUrl, payload,
|
dataSource, pageInfo, selectedRowKeys, showTotalCell: this.props.showTotalCell, sumRowlistUrl, payload,
|
||||||
calcDetail: (calcDetail || !showOperateBtn) && !confirmAuth && !submitAuth,
|
calcDetail: (((calcDetail || !showOperateBtn) && !confirmAuth && !submitAuth) || (!isAdminEnable && !isChief)),
|
||||||
showSee: (calcDetail || !showOperateBtn), tableScrollHeight: 265, pageSum,
|
showSee: calcDetail && (isAdminEnable || isChief), tableScrollHeight: 265, pageSum,
|
||||||
|
// (calcDetail || !showOperateBtn)
|
||||||
columns: _.every(traverse(columns, (calcDetail || !showOperateBtn)), (it, idx) => !it.fixed) ? _.map(traverse(columns, (calcDetail || !showOperateBtn)), (it, idx) => ({
|
columns: _.every(traverse(columns, (calcDetail || !showOperateBtn)), (it, idx) => !it.fixed) ? _.map(traverse(columns, (calcDetail || !showOperateBtn)), (it, idx) => ({
|
||||||
...it,
|
...it,
|
||||||
fixed: idx < 2 ? "left" : false
|
fixed: idx < 2 ? "left" : false
|
||||||
|
|
|
||||||
|
|
@ -244,7 +244,12 @@ class Index extends Component {
|
||||||
<Menu.Item key="calc_selected">{getLabel(543546, "核算所选人员")}</Menu.Item>
|
<Menu.Item key="calc_selected">{getLabel(543546, "核算所选人员")}</Menu.Item>
|
||||||
</Menu>
|
</Menu>
|
||||||
);
|
);
|
||||||
const moreMenu = (
|
const moreMenu = (!showOperateBtn && (confirmAuth || submitAuth)) ? (
|
||||||
|
<Menu onClick={this.handleMoreMenuClick}>
|
||||||
|
<Menu.Item key="exportAll">{getLabel(81272, "导出全部")}</Menu.Item>
|
||||||
|
<Menu.Item key="export_custom">{getLabel(544270, "自定义导出")}</Menu.Item>
|
||||||
|
</Menu>
|
||||||
|
) : (
|
||||||
<Menu onClick={this.handleMoreMenuClick}>
|
<Menu onClick={this.handleMoreMenuClick}>
|
||||||
{canEdit && <Menu.Item key="import">{getLabel(32935, "导入")}</Menu.Item>}
|
{canEdit && <Menu.Item key="import">{getLabel(32935, "导入")}</Menu.Item>}
|
||||||
<Menu.Item key="exportAll">{getLabel(81272, "导出全部")}</Menu.Item>
|
<Menu.Item key="exportAll">{getLabel(81272, "导出全部")}</Menu.Item>
|
||||||
|
|
@ -270,7 +275,7 @@ class Index extends Component {
|
||||||
isOpenApproval && reqBtns.unshift(<Button type="ghost" onClick={() => {
|
isOpenApproval && reqBtns.unshift(<Button type="ghost" onClick={() => {
|
||||||
window.open(`${approvalWorkflowUrl}&salaryAcctRecordId=${salaryAcctRecordId}`, "_blank");
|
window.open(`${approvalWorkflowUrl}&salaryAcctRecordId=${salaryAcctRecordId}`, "_blank");
|
||||||
}}>{getLabel(111, "发起审批")}</Button>);
|
}}>{getLabel(111, "发起审批")}</Button>);
|
||||||
!showOperateBtn && (reqBtns = reqBtns.slice(-1));
|
(!showOperateBtn && (confirmAuth || submitAuth)) && (reqBtns = reqBtns.slice(-2));
|
||||||
confirmAuth && reqBtns.unshift(<Button type="primary" loading={loading.az}
|
confirmAuth && reqBtns.unshift(<Button type="primary" loading={loading.az}
|
||||||
onClick={() => this.handleAZCalcOperate("azReturn")}>{getLabel(111, "退回")}</Button>);
|
onClick={() => this.handleAZCalcOperate("azReturn")}>{getLabel(111, "退回")}</Button>);
|
||||||
confirmAuth && reqBtns.unshift(<Button type="primary" loading={loading.az}
|
confirmAuth && reqBtns.unshift(<Button type="primary" loading={loading.az}
|
||||||
|
|
|
||||||
|
|
@ -111,15 +111,27 @@ export const renderReqBtns = (selectedKey, salaryImportTypes, onSalaryOpts, show
|
||||||
return reqBtns;
|
return reqBtns;
|
||||||
};
|
};
|
||||||
export const renderDropMenuDatas = (selectedKey, showOperateBtn) => {
|
export const renderDropMenuDatas = (selectedKey, showOperateBtn) => {
|
||||||
let menus = [{
|
let menus = [
|
||||||
key: "custom_cols",
|
{
|
||||||
icon: <i className="icon-coms-Custom"/>,
|
key: "exportAll",
|
||||||
content: getLabel(32535, "显示列定制")
|
icon: <i className="iconfont icon-daochu"/>,
|
||||||
}, {
|
content: getLabel(81272, "导出全部")
|
||||||
key: "log",
|
},
|
||||||
icon: <i className="iconfont icon-caozuorizhi32"/>,
|
{
|
||||||
content: getLabel(545781, "操作日志")
|
key: "exportSelected",
|
||||||
}];
|
icon: <i className="iconfont icon-piliangdaochu"/>,
|
||||||
|
content: getLabel(512938, "导出选中")
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: "custom_cols",
|
||||||
|
icon: <i className="icon-coms-Custom"/>,
|
||||||
|
content: getLabel(32535, "显示列定制")
|
||||||
|
}, {
|
||||||
|
key: "log",
|
||||||
|
icon: <i className="iconfont icon-caozuorizhi32"/>,
|
||||||
|
content: getLabel(545781, "操作日志")
|
||||||
|
}
|
||||||
|
];
|
||||||
switch (selectedKey) {
|
switch (selectedKey) {
|
||||||
case "pending":
|
case "pending":
|
||||||
menus = [
|
menus = [
|
||||||
|
|
@ -133,31 +145,31 @@ export const renderDropMenuDatas = (selectedKey, showOperateBtn) => {
|
||||||
// icon: <i className="iconfont icon-piliangshanchu"/>,
|
// icon: <i className="iconfont icon-piliangshanchu"/>,
|
||||||
// content: getLabel(543186, "批量删除待办")
|
// content: getLabel(543186, "批量删除待办")
|
||||||
// },
|
// },
|
||||||
{
|
// {
|
||||||
key: "exportAll",
|
// key: "exportAll",
|
||||||
icon: <i className="iconfont icon-daochu"/>,
|
// icon: <i className="iconfont icon-daochu"/>,
|
||||||
content: getLabel(81272, "导出全部")
|
// content: getLabel(81272, "导出全部")
|
||||||
},
|
// },
|
||||||
{
|
// {
|
||||||
key: "exportSelected",
|
// key: "exportSelected",
|
||||||
icon: <i className="iconfont icon-piliangdaochu"/>,
|
// icon: <i className="iconfont icon-piliangdaochu"/>,
|
||||||
content: getLabel(512938, "导出选中")
|
// content: getLabel(512938, "导出选中")
|
||||||
},
|
// },
|
||||||
...menus
|
...menus
|
||||||
];
|
];
|
||||||
break;
|
break;
|
||||||
case "fixed":
|
case "fixed":
|
||||||
menus = [
|
menus = [
|
||||||
{
|
// {
|
||||||
key: "exportAll",
|
// key: "exportAll",
|
||||||
icon: <i className="iconfont icon-daochu"/>,
|
// icon: <i className="iconfont icon-daochu"/>,
|
||||||
content: getLabel(81272, "导出全部")
|
// content: getLabel(81272, "导出全部")
|
||||||
},
|
// },
|
||||||
{
|
// {
|
||||||
key: "exportSelected",
|
// key: "exportSelected",
|
||||||
icon: <i className="iconfont icon-piliangdaochu"/>,
|
// icon: <i className="iconfont icon-piliangdaochu"/>,
|
||||||
content: getLabel(512938, "导出选中")
|
// content: getLabel(512938, "导出选中")
|
||||||
},
|
// },
|
||||||
...menus
|
...menus
|
||||||
];
|
];
|
||||||
break;
|
break;
|
||||||
|
|
@ -178,38 +190,38 @@ export const renderDropMenuDatas = (selectedKey, showOperateBtn) => {
|
||||||
// icon: <i className="iconfont icon-piliangshanchu"/>,
|
// icon: <i className="iconfont icon-piliangshanchu"/>,
|
||||||
// content: getLabel(543186, "批量删除待办")
|
// content: getLabel(543186, "批量删除待办")
|
||||||
// },
|
// },
|
||||||
{
|
// {
|
||||||
key: "exportAll",
|
// key: "exportAll",
|
||||||
icon: <i className="iconfont icon-daochu"/>,
|
// icon: <i className="iconfont icon-daochu"/>,
|
||||||
content: getLabel(81272, "导出全部")
|
// content: getLabel(81272, "导出全部")
|
||||||
},
|
// },
|
||||||
{
|
// {
|
||||||
key: "exportSelected",
|
// key: "exportSelected",
|
||||||
icon: <i className="iconfont icon-piliangdaochu"/>,
|
// icon: <i className="iconfont icon-piliangdaochu"/>,
|
||||||
content: getLabel(512938, "导出选中")
|
// content: getLabel(512938, "导出选中")
|
||||||
},
|
// },
|
||||||
...menus
|
...menus
|
||||||
];
|
];
|
||||||
break;
|
break;
|
||||||
case "stop":
|
case "stop":
|
||||||
menus = [
|
menus = [
|
||||||
{
|
// {
|
||||||
key: "exportAll",
|
// key: "exportAll",
|
||||||
icon: <i className="iconfont icon-daochu"/>,
|
// icon: <i className="iconfont icon-daochu"/>,
|
||||||
content: getLabel(81272, "导出全部")
|
// content: getLabel(81272, "导出全部")
|
||||||
},
|
// },
|
||||||
{
|
// {
|
||||||
key: "exportSelected",
|
// key: "exportSelected",
|
||||||
icon: <i className="iconfont icon-piliangdaochu"/>,
|
// icon: <i className="iconfont icon-piliangdaochu"/>,
|
||||||
content: getLabel(512938, "导出选中")
|
// content: getLabel(512938, "导出选中")
|
||||||
},
|
// },
|
||||||
...menus
|
...menus
|
||||||
];
|
];
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
return showOperateBtn ? menus : _.filter(menus, o => o.key === "custom_cols");
|
return showOperateBtn ? menus : _.filter(menus, o => o.key === "custom_cols" || o.key === "exportAll" || o.key === "exportSelected");
|
||||||
};
|
};
|
||||||
|
|
||||||
export const salaryFileSearchConditions = [
|
export const salaryFileSearchConditions = [
|
||||||
|
|
@ -449,7 +461,7 @@ export const salaryFilesConditions = [
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
defaultshow: true, title: getLabel(543329, "发薪设置"),
|
defaultshow: true, title: getLabel(543329, "发薪设置"),
|
||||||
col: 1,lanId: 543329,
|
col: 1, lanId: 543329,
|
||||||
items: [
|
items: [
|
||||||
{
|
{
|
||||||
colSpan: 1,
|
colSpan: 1,
|
||||||
|
|
@ -502,7 +514,7 @@ export const salaryFilesConditions = [
|
||||||
defaultshow: true, title: getLabel(538004, "薪资档案"),
|
defaultshow: true, title: getLabel(538004, "薪资档案"),
|
||||||
titleHelpful: getLabel(543330, "提示:显示已生效的最新数据"),
|
titleHelpful: getLabel(543330, "提示:显示已生效的最新数据"),
|
||||||
titleHelpfulLanId: 543330,
|
titleHelpfulLanId: 543330,
|
||||||
col: 2, salaryFile: true,lanId: 538004,
|
col: 2, salaryFile: true, lanId: 538004,
|
||||||
items: []
|
items: []
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue