艾志合并个税-个税申报表与人员信息报送页面权限添加
This commit is contained in:
parent
338a4a4053
commit
70e48d619a
|
|
@ -86,7 +86,7 @@ class Index extends Component {
|
|||
}
|
||||
return { ...o, width };
|
||||
})
|
||||
});
|
||||
}, ()=> props.onChangeAZOperate(canOperate));
|
||||
}
|
||||
}).catch(() => this.setState({ loading: false }));
|
||||
};
|
||||
|
|
|
|||
|
|
@ -31,14 +31,15 @@ class Calculate extends Component {
|
|||
]
|
||||
}, isRefresh: false,
|
||||
declareDaialog: { visible: false, title: "" },
|
||||
logDialogVisible: false, filterConditions: "[]"
|
||||
logDialogVisible: false, filterConditions: "[]",
|
||||
azOperate: false//艾志二开操作按钮的权限
|
||||
};
|
||||
this.handleDebounce = null;
|
||||
}
|
||||
|
||||
renderCalculateOpts = () => {
|
||||
const { taxAgentStore: { showOperateBtn } } = this.props;
|
||||
const { queryParams, isRefresh } = this.state;
|
||||
const { queryParams, isRefresh, azOperate } = this.state;
|
||||
let calculateOpts = [
|
||||
<Button type="primary" onClick={() => this.setState({
|
||||
declareDaialog: {
|
||||
|
|
@ -57,7 +58,7 @@ class Calculate extends Component {
|
|||
queryParams: { ...queryParams, ...v }
|
||||
})} onSearch={() => this.setState({ isRefresh: !isRefresh })}/>
|
||||
];
|
||||
return !showOperateBtn ? calculateOpts.slice(1) : calculateOpts;
|
||||
return (!showOperateBtn || !azOperate) ? calculateOpts.slice(1) : calculateOpts;
|
||||
};
|
||||
onDropMenuClick = (key, targetid = "") => {
|
||||
switch (key) {
|
||||
|
|
@ -85,7 +86,8 @@ class Calculate extends Component {
|
|||
]}>
|
||||
<div className="declare-body">
|
||||
<DeclareTablelist queryParams={queryParams} isRefresh={isRefresh} showOperateBtn={showOperateBtn}
|
||||
onFilterLog={(type, targetid) => this.onDropMenuClick(type, targetid)}/>
|
||||
onFilterLog={(type, targetid) => this.onDropMenuClick(type, targetid)}
|
||||
onChangeAZOperate={bool => this.setState({ azOperate: bool })}/>
|
||||
<DeclareDialog {...declareDaialog}
|
||||
onCancel={(bool) => this.setState({
|
||||
declareDaialog: { ...declareDaialog, visible: false },
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@ class TaxDeclarationInfo extends Component {
|
|||
|
||||
render() {
|
||||
const { resDialog } = this.state;
|
||||
const { declareInfo, onOperate } = this.props;
|
||||
const { declareInfo, onOperate, azOperate } = this.props;
|
||||
const { abnormalSize, declareFailSize } = declareInfo;
|
||||
const infoItem = [
|
||||
{ key: "salaryMonth", label: getLabel(542604, "薪资所属月") },
|
||||
|
|
@ -113,7 +113,9 @@ class TaxDeclarationInfo extends Component {
|
|||
onClick={() => this.handleSeeResult([{ key: "list4Fail" }], getLabel(111, "申报失败数据"))}>
|
||||
{getLabel(111, "申报失败数据")}({declareFailSize || 0})
|
||||
</span>
|
||||
<MoreBtnMenu dropMenuDatas={dropMenuDatas}/>
|
||||
{
|
||||
azOperate && <MoreBtnMenu dropMenuDatas={dropMenuDatas}/>
|
||||
}
|
||||
<DeclareResultDialog
|
||||
{...resDialog}
|
||||
onCancel={() => {
|
||||
|
|
|
|||
|
|
@ -60,7 +60,8 @@ class Index extends Component {
|
|||
visible: false, title: getLabel(1421, "新增"), taxDeclarationId: "", id: ""
|
||||
},
|
||||
intelCalcSalaryStatus: false, //智能算薪 总开关是否开启
|
||||
declareInfo: {}, pageInfo: { current: 0, pageSize: 10, total: 0 }
|
||||
declareInfo: {}, pageInfo: { current: 0, pageSize: 10, total: 0 },
|
||||
azOperate: false //艾志二开操作按钮的权限
|
||||
};
|
||||
this.timer = null;
|
||||
this.taxDeclareRef = null;
|
||||
|
|
@ -173,7 +174,8 @@ class Index extends Component {
|
|||
return { ...it, width: 150, fixed: "left", ellipsis: true };
|
||||
}
|
||||
return { ...it, width: 150, ellipsis: true };
|
||||
})
|
||||
}),
|
||||
azOperate: canOperate
|
||||
}, () => {
|
||||
const payload = {
|
||||
dataSource, pageInfo: this.state.pageInfo,
|
||||
|
|
@ -339,7 +341,7 @@ class Index extends Component {
|
|||
render() {
|
||||
const {
|
||||
tabs, selectedKey, loading, declareInfo, intelCalcSalaryStatus, taxDecPersonSlide,
|
||||
editTabVisible
|
||||
editTabVisible, azOperate
|
||||
} = this.state;
|
||||
const [__, taxDeclarationId] = selectedKey.split("%%");
|
||||
let btns = [
|
||||
|
|
@ -415,15 +417,16 @@ class Index extends Component {
|
|||
}
|
||||
return (
|
||||
<div className="declareDetail-layout">
|
||||
<TaxDeclarationInfo declareInfo={declareInfo} onOperate={fun => this[fun]()}/>
|
||||
<TaxDeclarationInfo declareInfo={declareInfo} onOperate={fun => this[fun]()} azOperate={azOperate}/>
|
||||
<div className="declareDetail-layout-content">
|
||||
<WeaTab
|
||||
datas={tabs} keyParam="viewcondition" selectedKey={selectedKey} showAddBtn buttons={btns}
|
||||
keyParam="viewcondition" selectedKey={selectedKey} showAddBtn={azOperate}
|
||||
type="editable-inline" onEdit={this.handleTabEdit} leftStyle={{ width: "calc(100% - 450px)" }}
|
||||
onChange={(v) => this.setState({ selectedKey: v }, () => this.getDetailList())}
|
||||
searchType={["base"]} searchsBasePlaceHolder={getLabel(26919, "请输入姓名")}
|
||||
onSearchChange={keyword => this.setState({ keyword })}
|
||||
onSearch={this.getDetailList}
|
||||
onSearch={this.getDetailList} datas={_.map(tabs, o => ({ ...o, editable: azOperate }))}
|
||||
buttons={azOperate ? btns : btns.slice(0, 1)}
|
||||
/>
|
||||
{/*个税申报表-新增编辑框*/}
|
||||
<IncomeTaxDeclarationPersonnelSlide
|
||||
|
|
|
|||
|
|
@ -49,7 +49,8 @@ class Index extends Component {
|
|||
declareEditDialog: { visible: false, id: "", title: "" },
|
||||
declareStatusList: [], employmentStatusList: [],
|
||||
employmentTypeList: [], adConditons: [],
|
||||
selectedRowKeys: [], exportPayload: {}
|
||||
selectedRowKeys: [], exportPayload: {},
|
||||
azOperate: false //艾志二开操作按钮的权限
|
||||
};
|
||||
this.baseInfoRef = null;
|
||||
this.importRef = null;
|
||||
|
|
@ -175,10 +176,11 @@ class Index extends Component {
|
|||
API[selectedKey](payload).then(({ status, data }) => {
|
||||
this.setState({ loading: { ...this.state.loading, query: false } });
|
||||
if (status) {
|
||||
const { pageInfo: result } = data;
|
||||
const { pageInfo: result, canOperate } = data;
|
||||
const { columns, list: dataSource, pageNum: current, pageSize, total } = result;
|
||||
this.baseInfoRef.getEmployeeDeclareInfo();
|
||||
this.setState({
|
||||
azOperate: canOperate,
|
||||
pageInfo: { ...pageInfo, current, pageSize, total }
|
||||
}, () => {
|
||||
const payload = {
|
||||
|
|
@ -418,7 +420,7 @@ class Index extends Component {
|
|||
render() {
|
||||
const {
|
||||
selectedKey, showSearchAd, declareStatus, declareStatusList, taxCycle, declareEditDialog, loading,
|
||||
pageInfo, adConditons, employmentTypeList, employmentStatusList
|
||||
pageInfo, adConditons, employmentTypeList, employmentStatusList, azOperate
|
||||
} = this.state;
|
||||
const { taxAgentStore: { showOperateBtn }, employeeDeclareStore: { advanceForm: form, declareForm } } = this.props;
|
||||
const menu = (
|
||||
|
|
@ -492,13 +494,13 @@ class Index extends Component {
|
|||
/>
|
||||
];
|
||||
// !showOperateBtn && tabBtns.shift();
|
||||
selectedKey !== "list" && tabBtns.shift();
|
||||
(selectedKey !== "list" || !azOperate) && tabBtns.shift();
|
||||
selectedKey !== "list" && tabBtns.shift();
|
||||
return (
|
||||
<WeaTop
|
||||
title={getLabel(544289, "人员信息报送")} iconBgcolor="#F14A2D"
|
||||
icon={<i className="icon-coms-fa"/>} className="declareWrapper"
|
||||
buttons={buttons}
|
||||
buttons={azOperate ? buttons : buttons.slice(0, 1)}
|
||||
// buttons={showOperateBtn ? buttons : []}
|
||||
>
|
||||
<div style={{ height: "100%", background: "#f6f6f6" }} className="flex flex-rollback">
|
||||
|
|
|
|||
Loading…
Reference in New Issue