From 2f4eebe6c7b54da6e363bb81adeda3a5b7d314ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Mon, 26 Jun 2023 10:24:05 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E4=BA=A7=E5=93=81-=E5=88=97=E8=A1=A8?= =?UTF-8?q?=E4=B8=8A=E9=9D=A2=E6=93=8D=E4=BD=9C=E6=8C=89=E9=92=AE=E6=98=BE?= =?UTF-8?q?=E7=A4=BA=E4=B8=A4=E4=B8=AA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../socialSecurityBenefits/archives/index.js | 2 +- .../socialSecurityBenefits/programme/index.js | 120 +++++------------- .../standingBook/index.js | 13 +- 3 files changed, 42 insertions(+), 93 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/archives/index.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/archives/index.js index 3a8ad7ab..72f9d432 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/archives/index.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/archives/index.js @@ -103,7 +103,7 @@ export default class Archives extends React.Component { }; getColumns = () => { - const { columns, pageInfo, selectedKey } = this.state; + const { columns, selectedKey } = this.state; const { taxAgentStore: { showOperateBtn } } = this.props; let tmpV = _.map(columns.filter(item => item.display === "TRUE"), item => { return { diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/programme/index.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/programme/index.js index bee748ee..80fbb6e5 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/programme/index.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/programme/index.js @@ -1,10 +1,9 @@ import React from "react"; import { inject, observer } from "mobx-react"; import { toJS } from "mobx"; -import { Button, Dropdown, Menu, message, Modal, Switch } from "antd"; -import { WeaNewScroll, WeaSelect, WeaSlideModal, WeaTop } from "ecCom"; -import { WeaTableNew } from "comsMobx"; -import { renderNoright } from "../../../util"; // 渲染form数据的方法:因为多个页面都会使用,所以抽的公共方法在util中 +import { Button, Dropdown, Menu, message, Modal } from "antd"; +import { WeaLocaleProvider, WeaNewScroll, WeaSelect, WeaSlideModal, WeaTop } from "ecCom"; +import { renderNoright } from "../../../util"; import CustomTab from "../../../components/customTab"; import SlideModalTitle from "../../../components/slideModalTitle"; import TipLabel from "../../../components/TipLabel"; @@ -14,11 +13,11 @@ import { paymentScopeEnum, welfareTypeEnum } from "./enum"; import CustomPaginationTable from "../../../components/customPaginationTable"; import TwoColContent from "../../../components/twoColContent"; import CopySchemaModal from "./copySchemaModal"; -import "./index.less"; import CustomBenefitsTable from "./customBenefitsTable"; +import "./index.less"; -const WeaMobxTable = WeaTableNew.WeaTable; +const { getLabel } = WeaLocaleProvider; @inject("programmeStore", "taxAgentStore", "salaryFileStore") @observer export default class Programme extends React.Component { @@ -57,25 +56,17 @@ export default class Programme extends React.Component { newColumns = newColumns.map(column => { let newColumn = column; - newColumn.render = (text, record, index) => { + newColumn.render = (text, record) => { //前端元素转义 let valueSpan = record[newColumn.dataIndex + "span"] !== undefined ? record[newColumn.dataIndex + "span"] : record[newColumn.dataIndex]; - if (newColumn.dataIndex == "id") { - newColumn.display = false; - } + if (newColumn.dataIndex === "id") newColumn.display = false; switch (newColumn.dataIndex) { case "operate": return ( - { - this.onEdit(record); - }}> - 编辑 - + this.onEdit(record)}>编辑 ); default: return
; @@ -87,72 +78,38 @@ export default class Programme extends React.Component { newColumns.push({ title: "操作", dataIndex: "operate", + width: 120, render: (text, record) => { return ( - { - this.onEdit(record); - }}> - {showOperateBtn ? "编辑" : "查看"} - - ); - } - }); - showOperateBtn && newColumns.push({ - key: "moreOperate", - dataIndex: "moreOperate", - render: (text, record) => { - return ( - - - { - this.onCopy(record); - }}> - 复制 - - - {/*暂时隐藏*/} - - { - this.onDelete(record); - }}> - 删除 - - - - }> - - - - - + + this.onEdit(record)} + style={{ marginRight: 10 }}>{showOperateBtn ? "编辑" : "查看"} + { + showOperateBtn && + this.onCopy(record)} + style={{ marginRight: 10 }}>{getLabel(111, "复制")} + } + { + showOperateBtn && + + + this.onDelete(record)}>{getLabel(111, "删除")} + + + }> + + + } + ); } }); return newColumns; }; - handleCategoryStatusChange(record, value) { - const { programmeStore: { updateCustomCategoryStatus } } = this.props; - Modal.confirm({ - title: "信息确认", - content: `确认要${value ? "启用" : "停用"}吗`, - onOk: () => { - updateCustomCategoryStatus(record.id, value); - }, - onCancel: () => { - } - }); - } - - onEdit(record) { + onEdit = (record) => { let id = record.id; const { programmeStore } = this.props; const { getForm, selectedKey } = programmeStore; @@ -162,15 +119,15 @@ export default class Programme extends React.Component { }).then(() => { this.setState({ slideVisiable: true, customEdit: true, currentOperate: "update" }); }); - } + }; - onCopy(record) { + onCopy = (record) => { this.setState({ copyId: record.id, copyModalValue: record.schemeName, copyModalVisible: true }); - } + }; onDelete = (record) => { const { programmeStore: { deleteScheme, deleteLoading, selectedKey } } = this.props; @@ -422,13 +379,6 @@ export default class Programme extends React.Component { welfareTypeEnum={customSelectkey} onCustomEdit={this.onCustomEdit} /> - // } rightContent={renderCustomRightContent()} /> diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBook/index.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBook/index.js index 9e41557a..1fef7990 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBook/index.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBook/index.js @@ -1,7 +1,7 @@ import React from "react"; import { inject, observer } from "mobx-react"; import { Button, DatePicker, Dropdown, Menu, message, Modal } from "antd"; -import { WeaNewScroll, WeaTop } from "ecCom"; +import { WeaLocaleProvider, WeaNewScroll, WeaTop } from "ecCom"; import { renderNoright } from "../../../util"; import Accountdialog from "./components/accountDialog"; import AbnormalDrawer from "./components/abnormalDrawer"; @@ -12,6 +12,7 @@ import { getCalculateProgress } from "../../../apis/calculate"; import "./index.less"; import UnifiedTable from "../../../components/UnifiedTable"; +const { getLabel } = WeaLocaleProvider; const MonthPicker = DatePicker.MonthPicker; @inject("standingBookStore", "taxAgentStore") @@ -139,6 +140,7 @@ export default class StandingBook extends React.Component { { title: "操作", dataIndex: "operate", + width: 120, key: "operate", render: (text, r) => { const { billStatus, billMonth, creator } = r; @@ -147,7 +149,7 @@ export default class StandingBook extends React.Component { {billStatus === "未归档" && ( this.handleGoDetail(billMonth, "", r.paymentOrganizationId, creator)}> 核算 @@ -155,7 +157,6 @@ export default class StandingBook extends React.Component { {billStatus === "已归档" && ( this.socialSecurityBenefitsRecalculate({ id: r.id })}> 重新核算 @@ -173,12 +174,10 @@ export default class StandingBook extends React.Component { }) }> 归档 - {/* 异常详情 */} 删除 - {/* 操作日志 */} }> - + )} {billStatus === "已归档" && ( @@ -196,7 +195,7 @@ export default class StandingBook extends React.Component { 查看 }> - + )} From ae9d7cc7c004b714483df1b16584de58e26c9312 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Mon, 26 Jun 2023 11:27:27 +0800 Subject: [PATCH 2/3] =?UTF-8?q?=E4=BA=A7=E5=93=81-=E5=88=97=E8=A1=A8?= =?UTF-8?q?=E4=B8=8A=E9=9D=A2=E6=93=8D=E4=BD=9C=E6=8C=89=E9=92=AE=E6=98=BE?= =?UTF-8?q?=E7=A4=BA=E4=B8=A4=E4=B8=AA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pc4mobx/hrmSalary/pages/calculate/index.js | 30 ++++--------- pc4mobx/hrmSalary/pages/salaryItem/index.js | 44 +++++++------------ .../socialSecurityBenefits/programme/index.js | 4 +- .../standingBook/index.js | 19 +++++--- 4 files changed, 39 insertions(+), 58 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/calculate/index.js b/pc4mobx/hrmSalary/pages/calculate/index.js index fda59a8d..84c858a2 100644 --- a/pc4mobx/hrmSalary/pages/calculate/index.js +++ b/pc4mobx/hrmSalary/pages/calculate/index.js @@ -1,8 +1,8 @@ import React from "react"; import { inject, observer } from "mobx-react"; import { Button, DatePicker, Dropdown, Menu, message, Modal, Tag } from "antd"; -import { WeaInputSearch, WeaNewScroll, WeaTop } from "ecCom"; -import { renderNoright } from "../../util"; // 渲染form数据的方法:因为多个页面都会使用,所以抽的公共方法在util中 +import { WeaInputSearch, WeaLocaleProvider, WeaNewScroll, WeaTop } from "ecCom"; +import { renderNoright } from "../../util"; import CustomTab from "../../components/customTab"; import moment from "moment"; import BaseFormModal from "./baseFormModal"; @@ -10,6 +10,7 @@ import CustomPaginationTable from "../../components/customPaginationTable"; import ProgressModal from "../../components/progressModal"; import "./index.less"; +const { getLabel } = WeaLocaleProvider; const MonthPicker = DatePicker.MonthPicker; @inject("calculateStore", "taxAgentStore") @@ -185,7 +186,7 @@ export default class Calculate extends React.Component {
; }; } - if (item.title == "操作" && showOperateBtn) { + if (item.dataIndex === "operate" && showOperateBtn) { item.render = (text, record) => { const accountBtn = _.filter( record.operate, @@ -327,18 +328,6 @@ export default class Calculate extends React.Component { link: "wui/index.html#/ns_demo03/index", importantlevel: 1 }; - const adBtn = [ - // 高级搜索内部按钮 - , - , - - ]; const renderRightOperation = () => { const { startDate, endDate } = this.state; @@ -393,13 +382,10 @@ export default class Calculate extends React.Component {
{/* 收藏功能: 配置之后显示 收藏、帮助、显示页面地址 这3个功能 */} } // 左侧图标 - iconBgcolor="#F14A2D" // 左侧图标背景色 - showDropIcon={false} // 是否显示下拉按钮 - dropMenuDatas={rightMenu} // 下拉菜单(和页面的右键菜单相同) - dropMenuProps={{ collectParams }}> - {/* 收藏功能: 配置之后显示 收藏、帮助、显示页面地址 这3个功能 */} + title="薪资核算" + icon={} + iconBgcolor="#F14A2D" + showDropIcon={false}>
diff --git a/pc4mobx/hrmSalary/pages/salaryItem/index.js b/pc4mobx/hrmSalary/pages/salaryItem/index.js index 40ac86b3..a07c33b2 100644 --- a/pc4mobx/hrmSalary/pages/salaryItem/index.js +++ b/pc4mobx/hrmSalary/pages/salaryItem/index.js @@ -1,7 +1,7 @@ import React from "react"; import { inject, observer } from "mobx-react"; import { Button, Dropdown, Menu, message, Modal, Switch } from "antd"; -import { WeaInputSearch, WeaNewScroll, WeaSlideModal, WeaTop } from "ecCom"; +import { WeaInputSearch, WeaLocaleProvider, WeaNewScroll, WeaSlideModal, WeaTop } from "ecCom"; import { renderLoading } from "../../util"; import CustomTab from "../../components/customTab"; import SystemSalaryItemModal from "./systemSalaryItemModal"; @@ -11,6 +11,7 @@ import CustomSalaryItemSlide from "./customSalaryItemSlide"; import CustomPaginationTable from "../../components/customPaginationTable"; import "../socialSecurityBenefits/programme/index.less"; +const { getLabel } = WeaLocaleProvider; @inject("salaryItemStore", "taxAgentStore", "salaryFileStore") @observer export default class SalaryItem extends React.Component { @@ -112,9 +113,9 @@ export default class SalaryItem extends React.Component { this.onEditItem(record, false); }}>{text}; case "useInEmployeeSalary": - return ; + return ; case "useDefault": - return ; + return ; default: return
; } @@ -124,37 +125,22 @@ export default class SalaryItem extends React.Component { columns.push({ key: "operate", title: "操作", + width: 120, render: (text, record) => { return ( - { - this.onEditItem(record, true); - }}>{(showSalaryItemBtn || showOperateBtn) ? "编辑" : "查看"} + + this.onEditItem(record, true)}>{(showSalaryItemBtn || showOperateBtn) ? "编辑" : "查看"} + { + (record.canDelete && (showSalaryItemBtn || showOperateBtn)) && + this.handleDeleteItem(record)} + >{getLabel(535052, "删除")} + } + ); } }); - columns.push({ - title: "", - key: "moreOperate", - dataIndex: "moreOperate", - render: (text, record) => { - if (record.canDelete && (showSalaryItemBtn || showOperateBtn)) { - return ( - - - { - this.handleDeleteItem(record); - }}>删除 - - }> - - - ); - } else { - return ""; - } - } - }); return [ // { // title: "序号", diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/programme/index.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/programme/index.js index 80fbb6e5..0f410ce0 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/programme/index.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/programme/index.js @@ -87,7 +87,7 @@ export default class Programme extends React.Component { { showOperateBtn && this.onCopy(record)} - style={{ marginRight: 10 }}>{getLabel(111, "复制")} + style={{ marginRight: 10 }}>{getLabel(77, "复制")} } { showOperateBtn && @@ -95,7 +95,7 @@ export default class Programme extends React.Component { overlay={ - this.onDelete(record)}>{getLabel(111, "删除")} + this.onDelete(record)}>{getLabel(535052, "删除")} }> diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBook/index.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBook/index.js index 1fef7990..be0ad9a8 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBook/index.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBook/index.js @@ -146,7 +146,7 @@ export default class StandingBook extends React.Component { const { billStatus, billMonth, creator } = r; return ( - {billStatus === "未归档" && ( + {billStatus === "0" && ( )} - {billStatus === "已归档" && ( + {billStatus === "1" && ( this.socialSecurityBenefitsRecalculate({ id: r.id })}> 重新核算 )} - {billStatus === "未归档" && ( + {billStatus === "0" && ( )} - {billStatus === "已归档" && ( + {billStatus === "1" && ( it.dataIndex !== "id").map(item => { - if (item.dataIndex !== "operate") { + if (item.dataIndex !== "operate" && item.dataIndex !== "billStatus") { return { ...item, render: (text) => { @@ -497,6 +497,15 @@ export default class StandingBook extends React.Component { } }; } + if (item.dataIndex === "billStatus") { + return { + ...item, + render: (_, record) => { + return {record.billStatus === "1" ? getLabel(18800, "已归档") : getLabel(17999, "未归档")}; + } + }; + } return { ...item }; })} dataSource={list} From 3d04a79fcddf204d6bfedab16b97a688816a5ddf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Mon, 3 Jul 2023 15:42:11 +0800 Subject: [PATCH 3/3] =?UTF-8?q?=E4=BA=A7=E5=93=81-=E7=BB=9F=E4=B8=80?= =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E5=88=97=E8=A1=A8=E6=93=8D=E4=BD=9C=E6=8C=89?= =?UTF-8?q?=E9=92=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/UnifiedTable/index.js | 2 +- .../components/UnifiedTable/index.less | 14 +-- pc4mobx/hrmSalary/pages/calculate/index.js | 92 +++++-------------- .../dataAcquisition/cumDeduct/index.less | 14 +-- .../pages/dataAcquisition/dataTables.js | 9 +- .../dataAcquisition/otherDeduct/index.less | 14 +-- pc4mobx/hrmSalary/pages/ledger/index.less | 12 +-- .../ledgerPage/components/ledgerTable.js | 15 ++- .../standingBook/index.js | 48 ++++++---- pc4mobx/hrmSalary/pages/taxAgent/index.js | 25 ++--- pc4mobx/hrmSalary/pages/taxAgent/index.less | 9 +- 11 files changed, 109 insertions(+), 145 deletions(-) diff --git a/pc4mobx/hrmSalary/components/UnifiedTable/index.js b/pc4mobx/hrmSalary/components/UnifiedTable/index.js index 8f406f4f..f8cbff97 100644 --- a/pc4mobx/hrmSalary/components/UnifiedTable/index.js +++ b/pc4mobx/hrmSalary/components/UnifiedTable/index.js @@ -13,7 +13,7 @@ class Index extends Component { return { ...item, fixed: "left", width: 176 }; } if (item.dataIndex === "operate") { - return { ...item, fixed: "right", width: "120px" }; + return { ...item, fixed: "right", width: item.width || "120px" }; } return { ...item, width: "33%" }; }); diff --git a/pc4mobx/hrmSalary/components/UnifiedTable/index.less b/pc4mobx/hrmSalary/components/UnifiedTable/index.less index e1dbaf1d..616d16f0 100644 --- a/pc4mobx/hrmSalary/components/UnifiedTable/index.less +++ b/pc4mobx/hrmSalary/components/UnifiedTable/index.less @@ -8,17 +8,17 @@ } .linkWapper { - a { - color: #4d7ad8; - margin-right: 8px; - } + //a { + // color: #4d7ad8; + // margin-right: 8px; + //} i { cursor: pointer; } - a:hover { - text-decoration: none; - } + //a:hover { + // text-decoration: none; + //} } } diff --git a/pc4mobx/hrmSalary/pages/calculate/index.js b/pc4mobx/hrmSalary/pages/calculate/index.js index 84c858a2..473e1ec0 100644 --- a/pc4mobx/hrmSalary/pages/calculate/index.js +++ b/pc4mobx/hrmSalary/pages/calculate/index.js @@ -187,15 +187,10 @@ export default class Calculate extends React.Component { }; } if (item.dataIndex === "operate" && showOperateBtn) { + item.width = 150; item.render = (text, record) => { - const accountBtn = _.filter( - record.operate, - it => it.text == "核算" || it.text == "重新核算" - ); - const notAccountBtn = _.filter( - record.operate, - it => it.text != "核算" && it.text != "重新核算" - ); + const accountBtn = _.take(record.operate, 2); + const notAccountBtn = _.drop(record.operate, 2); let operateBtn = []; if (!_.isEmpty(accountBtn)) { operateBtn.push( @@ -207,13 +202,8 @@ export default class Calculate extends React.Component { style={{ display: "inline-block", marginRight: 8 }}> { - if (it.text == "核算" || it.text == "重新核算") { - it.text == "核算" - ? this.handleAccount(record) - : this.handleReaccount(record); - } - }}> + style={it.index !== "4" ? { padding: "0 12px" } : {}} + onClick={() => this.handleOperateClick(it.index, record)}> {it.text}
@@ -229,31 +219,14 @@ export default class Calculate extends React.Component { {notAccountBtn.map(cz => { - if (cz.text == "核算") { - this.handleAccount(record); - } else if (cz.text == "删除") { - this.handleDeleteItem(record); - } else if (cz.text == "归档") { - this.handleFile(record); - } else if (cz.text == "重新核算") { - this.handleReaccount(record); - } else if (cz.text == "查看") { - this.handleDetail(record); - } else if (cz.text == "回算") { - this.handleBackCalculate(record); - } - }}> + onClick={() => this.handleOperateClick(cz.index, record)}> {cz.text} )} }> - + ); } @@ -261,7 +234,23 @@ export default class Calculate extends React.Component { }; } }); - return showOperateBtn ? columns : _.filter(columns, it => it.title != "操作"); + return showOperateBtn ? columns : _.filter(columns, it => it.title !== "操作"); + }; + + handleOperateClick = (index, record) => { + if (index === "0") { + this.handleAccount(record); + } else if (index === "1") { + this.handleDeleteItem(record); + } else if (index === "2") { + this.handleFile(record); + } else if (index === "4") { + this.handleReaccount(record); + } else if (index === "3") { + this.handleDetail(record); + } else if (index === "5") { + this.handleBackCalculate(record); + } }; // 分页 @@ -291,44 +280,13 @@ export default class Calculate extends React.Component { render() { const { calculateStore, taxAgentStore: { showOperateBtn } } = this.props; - const { - salaryListDataSource, - salaryListColumns, - loading, - hasRight, - form, - condition, - tableStore, - showSearchAd, - getTableDatas, - doSearch, - setShowSearchAd, - salaryListPageInfo - } = calculateStore; + const { salaryListDataSource, loading, hasRight, salaryListPageInfo } = calculateStore; const { modalParam } = this.state; if (!hasRight && !loading) { // 无权限处理 return renderNoright(); } - const rightMenu = [ - // 右键菜单 - { - key: "BTN_COLUMN", - icon: , - content: "显示列定制", - onClick: this.showColumn - } - ]; - const collectParams = { - // 收藏功能配置 - favname: "薪资核算", - favouritetype: 1, - objid: 0, - link: "wui/index.html#/ns_demo03/index", - importantlevel: 1 - }; - const renderRightOperation = () => { const { startDate, endDate } = this.state; return ( diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.less b/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.less index ebccaa07..56fd88df 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.less +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/cumDeduct/index.less @@ -45,18 +45,18 @@ } .linkWapper { - a { - color: #4d7ad8; - margin-right: 8px; - } + //a { + // color: #4d7ad8; + // margin-right: 8px; + //} i { cursor: pointer; } - a:hover { - text-decoration: none; - } + //a:hover { + // text-decoration: none; + //} } } diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/dataTables.js b/pc4mobx/hrmSalary/pages/dataAcquisition/dataTables.js index 7f41b9de..de207b22 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/dataTables.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/dataTables.js @@ -101,19 +101,22 @@ class DataTables extends Component { } else if (dataIndex === "operate") { return { ...item, + width: 150, render: (text, record) => (
{ !isSpecial && - onViewDetails(record)}>查看明细 + onTableOperate({ key: "handleAddData" }, record)}>编辑 + onViewDetails(record)}>查看明细 { showOperateBtn && onTableOperate(e, record)}> - 编辑 删除 } title=""> @@ -127,7 +130,7 @@ class DataTables extends Component { { showOperateBtn && - onTableOperate({ key: "handleAddData" }, record)}>编辑 onTableOperate({ key: "deleteSelectAddUpDeduction" }, record)}>删除 diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/otherDeduct/index.less b/pc4mobx/hrmSalary/pages/dataAcquisition/otherDeduct/index.less index 93bc2137..cf86d2f7 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/otherDeduct/index.less +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/otherDeduct/index.less @@ -11,18 +11,18 @@ } .linkWapper { - a { - color: #4d7ad8; - margin-right: 8px; - } + //a { + // color: #4d7ad8; + // margin-right: 8px; + //} i { cursor: pointer; } - a:hover { - text-decoration: none; - } + //a:hover { + // text-decoration: none; + //} } } diff --git a/pc4mobx/hrmSalary/pages/ledger/index.less b/pc4mobx/hrmSalary/pages/ledger/index.less index 21467cbe..27948111 100644 --- a/pc4mobx/hrmSalary/pages/ledger/index.less +++ b/pc4mobx/hrmSalary/pages/ledger/index.less @@ -222,13 +222,13 @@ .mySalaryBenefitsWrapper { .linkWapper { - a { - color: #4d7ad8; - } + //a { + // color: #4d7ad8; + //} - a:hover { - text-decoration: none; - } + //a:hover { + // text-decoration: none; + //} } } diff --git a/pc4mobx/hrmSalary/pages/ledgerPage/components/ledgerTable.js b/pc4mobx/hrmSalary/pages/ledgerPage/components/ledgerTable.js index 97fa0829..2c712894 100644 --- a/pc4mobx/hrmSalary/pages/ledgerPage/components/ledgerTable.js +++ b/pc4mobx/hrmSalary/pages/ledgerPage/components/ledgerTable.js @@ -38,10 +38,10 @@ class LedgerTable extends Component { } componentWillReceiveProps(nextProps, nextContext) { - if (nextProps.doSearch !== this.props.doSearch) this.getLedgerList({current: 1}); + if (nextProps.doSearch !== this.props.doSearch) this.getLedgerList({ current: 1 }); } - getLedgerList = (extra={}) => { + getLedgerList = (extra = {}) => { const { name } = this.props; const { pageInfo } = this.state; const payload = { name, ...pageInfo, ...extra }; @@ -74,17 +74,22 @@ class LedgerTable extends Component { />; }; } else if (dataIndex === "operate") { - item.width = 120; + item.width = 150; item.render = (text, record) => { return
- onEditLedger(record)}>{showOperateBtn ? "编辑" : "查看"} + onEditLedger(record)}>{showOperateBtn ? "编辑" : "查看"} + { + showOperateBtn && + this.handleMenuClick({ key: "copy" }, record)}>复制 + } { showOperateBtn && this.handleMenuClick(e, record)}> - 复制 删除 } title=""> diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBook/index.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBook/index.js index be0ad9a8..c4ee3869 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBook/index.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/standingBook/index.js @@ -140,7 +140,7 @@ export default class StandingBook extends React.Component { { title: "操作", dataIndex: "operate", - width: 120, + width: 150, key: "operate", render: (text, r) => { const { billStatus, billMonth, creator } = r; @@ -154,6 +154,32 @@ export default class StandingBook extends React.Component { 核算 )} + {billStatus === "0" && ( + this.handleOperate({ + key: "archive", + billMonth, + paymentOrganizationId: r.paymentOrganizationId, + creator + })}> + 归档 + + )} + {billStatus === "1" && ( + this.handleOperate({ + key: "view", + billMonth, + paymentOrganizationId: r.paymentOrganizationId, + creator + })}> + 查看 + + )} {billStatus === "1" && ( - 归档 删除 }> )} - {billStatus === "1" && ( - - this.handleOperate({ - key, - billMonth, - paymentOrganizationId: r.paymentOrganizationId, - creator - }) - }> - 查看 - - }> - - - )} ); } @@ -492,6 +499,7 @@ export default class StandingBook extends React.Component { if (item.dataIndex !== "operate" && item.dataIndex !== "billStatus") { return { ...item, + width:150, render: (text) => { return {text}; } diff --git a/pc4mobx/hrmSalary/pages/taxAgent/index.js b/pc4mobx/hrmSalary/pages/taxAgent/index.js index 6576e595..1010c090 100644 --- a/pc4mobx/hrmSalary/pages/taxAgent/index.js +++ b/pc4mobx/hrmSalary/pages/taxAgent/index.js @@ -1,8 +1,8 @@ import React from "react"; import { inject, observer } from "mobx-react"; -import { Button, Col, Dropdown, Menu, message, Modal, Row, Switch } from "antd"; +import { Button, Col, message, Modal, Row, Switch } from "antd"; import { WeaFormItem, WeaInputSearch, WeaSearchGroup, WeaTable, WeaTop } from "ecCom"; -import { renderNoright } from "../../util"; // 渲染form数据的方法:因为多个页面都会使用,所以抽的公共方法在util中 +import { renderNoright } from "../../util"; import EditModal from "./editModal"; import TipLabel from "../../components/TipLabel"; import { decentralizationConditions, editConditions } from "./editConditions"; @@ -357,22 +357,11 @@ export default class TaxAgent extends React.Component { onClick={() => this.showEditModal(record.id)}> 编辑 - - - this.deleteTaxAgent(record.id)}> - 删除 - - - - }> - - - - + this.deleteTaxAgent(record.id)}> + 删除 +
} ], diff --git a/pc4mobx/hrmSalary/pages/taxAgent/index.less b/pc4mobx/hrmSalary/pages/taxAgent/index.less index ccff7add..6bfafdb0 100644 --- a/pc4mobx/hrmSalary/pages/taxAgent/index.less +++ b/pc4mobx/hrmSalary/pages/taxAgent/index.less @@ -39,12 +39,13 @@ .operationWapper, .employeeRangeWapper { a { - color: #4d7ad8; + //color: #4d7ad8; + margin-right: 10px; } - a:hover { - text-decoration: none; - } + //a:hover { + // text-decoration: none; + //} a.ant-dropdown-link { margin-left: 18px;