Compare commits

...

2 Commits

Author SHA1 Message Date
lys 6c8739776e Merge branch 'master' into feature/2.9.42310.01-薪资项目拓扑图
# Conflicts:
#	src/pages/calcTable/index.tsx
2025-04-24 16:53:24 +08:00
lys 45862052c7 master 2025-04-24 16:51:07 +08:00
2 changed files with 54 additions and 2 deletions

View File

@ -248,8 +248,8 @@ const index: FunctionComponent<Props> = (props) => {
};
const rowSelection = {
columnWidth: 50,
columnTitle: isDetailTable ? "序号" : "",
renderCell: (value: boolean, record: any, index: number, originNode: React.ReactNode) => (isDetailTable ? <span>{index + 1}</span> : originNode),
columnTitle: isDetailTable && _.isNil(showSee) ? "序号" : "",
renderCell: (value: boolean, record: any, index: number, originNode: React.ReactNode) => (isDetailTable && _.isNil(showSee) ? <span>{index + 1}</span> : originNode),
selectedRowKeys,
preserveSelectedRowKeys: true,
onChange: (rowKeys: React.Key[]) => {

View File

@ -434,6 +434,58 @@ export function renderCols(initialState: any[], type: string, i18n?: AnyObject,
return col;
})
];
} else if (type === "attendanceView") {
return [
..._.map(initialState, (g) => {
let col = { ...g, ellipsis: true };
switch (g.dataIndex) {
case "operate":
col = {
...col,
width: 176,
fixed: "right" // render: (__: string, record: any) => {
// let items: MenuProps["items"] = [
// {
// key: "DeleteList",
// label: i18n?.["删除"],
// onClick: () => postMessageToParent("DEL", record)
// },
// {
// key: "Log",
// label: i18n?.["操作日志"],
// onClick: () => postMessageToParent("log", record)
// }
// ];
// isSpecial && items.shift();
// return (
// <Space>
// <Button type="link" onClick={() => postMessageToParent("EDIT", record)}>
// {i18n?.["编辑"]}
// </Button>
// {isSpecial ? (
// <Button type="link" onClick={() => postMessageToParent("DEL", record)}>
// {i18n?.["删除"]}
// </Button>
// ) : (
// <Button type="link" onClick={() => postMessageToParent("VIEW", record)}>
// {i18n?.["查看明细"]}
// </Button>
// )}
// <Dropdown menu={{ items }} placement="bottomRight">
// <Button type="link" icon={<MoreOutlined />} />
// </Dropdown>
// </Space>
// );
// }
};
break;
default:
col = { ...col };
break;
}
return col;
})
];
}
return initialState;
}, [initialState, type, i18n, extraParams]);