From 0c00895f180eff282443e915e6e531b8f6e88503 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com>
Date: Wed, 6 Dec 2023 11:42:12 +0800
Subject: [PATCH 1/2] =?UTF-8?q?custom/=E9=B2=81=E6=8E=A7=E6=95=B0=E5=AD=97?=
=?UTF-8?q?-=E8=96=AA=E8=B5=84=E6=A0=B8=E7=AE=97=E5=88=97=E8=A1=A8?=
=?UTF-8?q?=E9=A1=B5=E9=9D=A2=E6=89=B9=E9=87=8F=E7=BC=96=E8=BE=91?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
public/css/iconfont/demo_index.html | 29 +++++++++++++++++++++++++---
public/css/iconfont/iconfont.css | 10 +++++++---
public/css/iconfont/iconfont.js | 2 +-
public/css/iconfont/iconfont.json | 7 +++++++
public/css/iconfont/iconfont.ttf | Bin 5272 -> 5580 bytes
public/css/iconfont/iconfont.woff | Bin 3240 -> 3428 bytes
public/css/iconfont/iconfont.woff2 | Bin 2580 -> 2800 bytes
7 files changed, 41 insertions(+), 7 deletions(-)
diff --git a/public/css/iconfont/demo_index.html b/public/css/iconfont/demo_index.html
index 83eb5ca..aa55039 100644
--- a/public/css/iconfont/demo_index.html
+++ b/public/css/iconfont/demo_index.html
@@ -54,6 +54,12 @@
+ -
+
+
批量更新
+ 
+
+
-
全部
@@ -138,9 +144,9 @@
@font-face {
font-family: 'iconfont';
- src: url('iconfont.woff2?t=1698914262517') format('woff2'),
- url('iconfont.woff?t=1698914262517') format('woff'),
- url('iconfont.ttf?t=1698914262517') format('truetype');
+ src: url('iconfont.woff2?t=1701833672416') format('woff2'),
+ url('iconfont.woff?t=1701833672416') format('woff'),
+ url('iconfont.ttf?t=1701833672416') format('truetype');
}
第二步:定义使用 iconfont 的样式
@@ -166,6 +172,15 @@
+ -
+
+
+ 批量更新
+
+ .icon-pilianggengxin
+
+
+
-
@@ -292,6 +307,14 @@
+ -
+
+
批量更新
+ #icon-pilianggengxin
+
+
-
+
+
+ {i18n["批量更新"]}
+
);
};
diff --git a/src/pages/calcTable/customTableTitle.tsx b/src/pages/calcTable/customTableTitle.tsx
index 3931d39..cdcad41 100644
--- a/src/pages/calcTable/customTableTitle.tsx
+++ b/src/pages/calcTable/customTableTitle.tsx
@@ -13,20 +13,22 @@ interface OwnProps {
dataIndex?: string;
title?: string;
lockStatus?: string;
+ dataType?: string;
onHandleFormulatd?: any;
i18n?: any;
+ pattern?: number;
}
type Props = OwnProps;
const customTableTitle: FunctionComponent = (props) => {
- const { dataIndex, title, lockStatus, onHandleFormulatd, i18n = {} } = props;
+ const { dataIndex, title, lockStatus, onHandleFormulatd, i18n = {}, pattern, dataType } = props;
- const handleToggleSalaryItemVal = (salaryItemId: string, type: string) => {
+ const handleToggleSalaryItemVal = (salaryItemId: string, type: string, updateParams: any = {}) => {
window.parent.postMessage(
{
type: "turn",
- payload: { id: "LOCKING", params: { lockType: type, salaryItemId } }
+ payload: { id: "LOCKING", params: { lockType: type, salaryItemId, ...updateParams } }
},
"*"
);
@@ -42,6 +44,10 @@ const customTableTitle: FunctionComponent = (props) => {
onClick={() => handleToggleSalaryItemVal(dataIndex as string, "LOCK")}/>
handleToggleSalaryItemVal(dataIndex as string, "UNLOCK")}/>
+ handleToggleSalaryItemVal(dataIndex as string, "BATCHUPDATE", {
+ pattern, salaryItemName: title, dataType
+ })}/>
}