From d866cc07cf16744644f83b1a6e1c75bbbf95c7a2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Fri, 2 Feb 2024 16:09:03 +0800 Subject: [PATCH] =?UTF-8?q?feature/2.10.1.2401.01-=E7=A4=BE=E4=BF=9D?= =?UTF-8?q?=E7=A6=8F=E5=88=A9=E6=96=B9=E6=A1=88=E9=87=8D=E6=9E=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pc4mobx/hrmSalary/index.js | 4 +- .../welfarePlan/config.js | 44 +++++++++++ .../welfarePlan/index.js | 77 +++++++++++++++++++ .../welfarePlan/index.less | 72 +++++++++++++++++ pc4mobx/hrmSalary/stores/programme.js | 2 + 5 files changed, 198 insertions(+), 1 deletion(-) create mode 100644 pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfarePlan/config.js create mode 100644 pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfarePlan/index.js create mode 100644 pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfarePlan/index.less diff --git a/pc4mobx/hrmSalary/index.js b/pc4mobx/hrmSalary/index.js index 799df79c..e40f42e2 100644 --- a/pc4mobx/hrmSalary/index.js +++ b/pc4mobx/hrmSalary/index.js @@ -5,7 +5,8 @@ import HistoricalPayroll from "./pages/historicalPayroll"; import SalaryAdjustmentRecords from "./pages/salaryAdjustmentRecords"; import MySalaryMobile from "./pages/mySalaryMobile"; import MySalary from "./pages/mySalaryBenefits"; -import Programme from "./pages/socialSecurityBenefits/programme"; +import Programme from "./pages/socialSecurityBenefits/welfarePlan"; +import Programme_old from "./pages/socialSecurityBenefits/programme"; // import Archivess from "./pages/socialSecurityBenefits/archives"; import Archives from "./pages/socialSecurityBenefits/welfareArchive"; //社保福利档案重构页面 import StandingBook from "./pages/socialSecurityBenefits/standingBook"; @@ -128,6 +129,7 @@ const Routes = ( path="socialSecurityBenefits" component={SocialSecurityBenefits}> + {/**/} diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfarePlan/config.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfarePlan/config.js new file mode 100644 index 00000000..c2155dbf --- /dev/null +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfarePlan/config.js @@ -0,0 +1,44 @@ +import React from "react"; +import { WeaLocaleProvider, WeaTools } from "ecCom"; +import { Button } from "antd"; +import AdvanceInputBtn from "../welfareArchive/components/advanceInputBtn"; +import { CancelHelpfulDiv, HelpfulDiv } from "../welfareArchive/components/welfareTip"; + +const getKey = WeaTools.getKey; +const getLabel = WeaLocaleProvider.getLabel; + +export const tabWelfarePlanList = [ + { key: "SOCIAL_SECURITY", title: getLabel(538967, "社保") }, + { key: "ACCUMULATION_FUND", title: getLabel(538969, "公积金") }, + { key: "OTHER", title: getLabel(542717, "企业年金及其他福利") }, + { key: "CUSTOM", title: getLabel(543151, "自定义福利") } +]; +/* + * Author: 黎永顺 + * Description: 社保福利方案-头部操作 + * Params: + * Date: 2024/2/2 + */ +export const renderDropMenuDatas = (selectedKey, showOperateBtn) => { + return [{ + key: "log", + icon: , + content: getLabel(545781, "操作日志") + }]; +}; +export const renderReqBtns = (selectedKey, onSalaryOpts, showOperateBtn) => { + let reqBtns = showOperateBtn ? [ + , + onSalaryOpts("OPEN")} onAdvanceSearch={()=>onSalaryOpts("SEARCH")}/> + ] : [onSalaryOpts("OPEN")} onAdvanceSearch={()=>onSalaryOpts("SEARCH")}/>]; + if (showOperateBtn) { + switch (selectedKey) { + case "CUSTOM": + break; + default: + break; + } + } + return reqBtns; +}; + diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfarePlan/index.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfarePlan/index.js new file mode 100644 index 00000000..3fbf52c5 --- /dev/null +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfarePlan/index.js @@ -0,0 +1,77 @@ +/* + * Author: 黎永顺 + * name: 福利方案页面重构 + * Description: + * Date: 2024/2/2 + */ +import React, { Component } from "react"; +import { inject, observer } from "mobx-react"; +import { WeaLocaleProvider, WeaReqTop } from "ecCom"; +import { renderDropMenuDatas, renderReqBtns, tabWelfarePlanList } from "./config"; +import LogDialog from "../../../components/logViewModal"; +import "./index.less"; + +const getLabel = WeaLocaleProvider.getLabel; + +@inject("taxAgentStore") +@observer +class Index extends Component { + constructor(props) { + super(props); + this.state = { + selectedKey: "SOCIAL_SECURITY", showSearchAd: false, isQuery: false, logDialogVisible: false, + topTabCount: { stayAdd: 0, paying: 0, stayDel: 0, stopPay: 0, ext: 0 }, + welfareImpDialog: { visible: false, title: getLabel(24023, "数据导入"), runStatuses: "" }, + showExtEmpsWitch: false + }; + } + + handleReqBtnsCLick = (type, importType) => { + const { state, handleSalaryOpts } = this.salaryFileListRef.wrappedInstance || {}; + switch (type) { + case "ADD": + break; + case "OPEN": + this.handleOpenAdvanceSearch(); + break; + case "SEARCH": + this.handleAdvanceSearch(); + break; + default: + break; + } + }; + handleOpenAdvanceSearch = () => this.setState({ showSearchAd: true }); + handleAdvanceSearch = () => this.setState({ isQuery: !this.state.isQuery }); + onDropMenuClick = (key) => { + switch (key) { + case "log": + this.setState({ logDialogVisible: true }); + break; + default: + break; + } + }; + + render() { + const { taxAgentStore: { showOperateBtn }, logDialogVisible } = this.props; + return ( +
+ } + iconBgcolor="#F14A2D" showDropIcon dropMenuDatas={renderDropMenuDatas(selectedKey, showOperateBtn)} + onDropMenuClick={this.onDropMenuClick} tabDatas={tabWelfarePlanList} + buttons={renderReqBtns(selectedKey, this.handleReqBtnsCLick, showOperateBtn)} + > +
+
+ {/*操作日志*/} + this.setState({ logDialogVisible: false })}/> +
+
+ ); + } +} + +export default Index; diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfarePlan/index.less b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfarePlan/index.less new file mode 100644 index 00000000..e52aee71 --- /dev/null +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfarePlan/index.less @@ -0,0 +1,72 @@ +//社保福利方案页面重构 +.salary-welfare-plan-wrapper { + min-width: 1000px; + overflow: auto; + width: 100%; + height: 100%; + background: #f6f6f6; + + .wea-new-top-req-title > div:first-child > div > div { + padding-left: 0 !important; + + .wea-tab { + border-bottom: none; + } + } + + .salary-welfare-plan-content { + padding: 8px 16px; + display: flex; + flex-direction: column; + + .table-layout { + .ant-spin-nested-loading, .ant-spin-container { + height: 100%; + } + } + + .searchAdvanced-condition-hide { + display: none; + } + + .searchAdvanced-condition-container { + background: #FFF; + margin-bottom: 10px; + border: 1px solid #e5e5e5; + + .wea-search-buttons { + border-top: 1px solid #dadada; + padding: 15px 0; + } + + .wea-advanced-searchsAd { + height: 246px; + overflow: hidden auto; + + .formItem-delete { + position: absolute; + top: 0; + right: -40px; + } + + .searchAdvanced-commonSelect { + border-top: 1px solid #ebebeb; + margin: 0 25px; + padding: 10px 0; + } + + .custom-advance-largeSpacing { + padding-left: 26px; + + .link { + border: none; + border-radius: 0; + padding: 12px 10px 12px 26px; + color: #2db7f5 + } + } + + } + } + } +} diff --git a/pc4mobx/hrmSalary/stores/programme.js b/pc4mobx/hrmSalary/stores/programme.js index 1459cc09..b3e481ce 100644 --- a/pc4mobx/hrmSalary/stores/programme.js +++ b/pc4mobx/hrmSalary/stores/programme.js @@ -10,6 +10,8 @@ const { TableStore } = WeaTableNew; export class ProgrammeStore { //lys-表单初始化(方案查询表单) @observable planSearchForm = new WeaForm(); + @observable planForm = new WeaForm(); //社保方案-新增编辑Form + @action initPlanForm = () => this.planForm = new WeaForm();//社保方案-初始化新增编辑Form @observable tableStore = new TableStore(); // new table