zy-react-library 1.0.176 → 1.0.178

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -61,7 +61,7 @@ export interface FormListUniqueProps {
61
61
  /** 删除按钮的文本,默认 '删除' */
62
62
  removeButtonText?: string;
63
63
  /** 表单配置项 */
64
- options: (operations: FormListOperations) => FormOption[];
64
+ options: (field: FormListFieldData, operations: FormListOperations) => FormOption[];
65
65
  /** 点击新增按钮时的默认值 */
66
66
  addDefaultValue?: FormValues;
67
67
  /** 点击新增按钮时插入的索引位置 */
@@ -225,7 +225,7 @@ const FormItemsRenderer = ({
225
225
  // 获取 listOptions
226
226
  const getListOptions = (listOptions, field, fieldIndex, add, remove, move) => {
227
227
  return typeof listOptions === "function"
228
- ? listOptions(field, fieldIndex, add, remove, move)
228
+ ? listOptions(field, { field, fieldIndex, add, remove, move })
229
229
  : (listOptions ?? []);
230
230
  };
231
231
 
@@ -161,6 +161,7 @@ function HiddenInfo(props) {
161
161
  status: info.isRelated,
162
162
  }),
163
163
  },
164
+ ...(info.isRelated === 1 ? [{ label:'相关方项目',children:info.projectName }] : []),
164
165
  { label: "隐患图片", children: <PreviewImg files={hiddenImageFiles} /> },
165
166
  ...(hiddenVideoFiles.length > 0
166
167
  ? [{
@@ -184,7 +185,7 @@ function HiddenInfo(props) {
184
185
  column={1}
185
186
  styles={{ label: { width: 200 } }}
186
187
  items={[
187
- { label: "整改部门", children: info.hiddenUserPresetsCO.rectifyDeptName },
188
+ { label: `整改${info.isRelated === 1 ? "单位" : "部门"}`, children: info.hiddenUserPresetsCO.rectifyDeptName },
188
189
  { label: "整改人", children: info.hiddenUserPresetsCO.rectifyUserName },
189
190
  ...(info.rectificationType === 2
190
191
  ? [
@@ -220,8 +221,8 @@ function HiddenInfo(props) {
220
221
  ...(item.hiddenLevelName ? [{ label: "隐患级别", children: item.hiddenLevelName }] : []),
221
222
  ...(item.userName ? [{ label: "隐患确认人", children: item.userName }] : []),
222
223
  ...(item.rectificationTime ? [{ label: "隐患确认时间", children: item.rectificationTime }] : []),
223
- ...(item.rectifyDeptName ? [{ label: "整改负责人部门", children: item.rectifyDeptName }] : []),
224
- ...(item.rectifyUserName ? [{ label: "整改负责人", children: item.rectifyUserName }] : []),
224
+ ...(item.rectifyDeptName ? [{ label: `整改${info.isRelated === 1 ? "单位" : "部门"}`, children: item.rectifyDeptName }] : []),
225
+ ...(item.rectifyUserName ? [{ label: "整改人", children: item.rectifyUserName }] : []),
225
226
  ...(item.rectificationDeadline ? [{ label: "整改完成期限", children: item.rectificationDeadline }] : []),
226
227
  ...(item.checkDeptName ? [{ label: "验收部门", children: item.checkDeptName }] : []),
227
228
  ...(item.checkUserName ? [{ label: "验收人", children: item.checkUserName }] : []),
@@ -386,7 +387,7 @@ function HiddenInfo(props) {
386
387
  column={1}
387
388
  styles={{ label: { width: 200 } }}
388
389
  items={[
389
- ...(item.deptName ? [{ label: "整改部门", children: item.deptName }] : []),
390
+ ...(item.deptName ? [{ label: `整改${info.isRelated === 1 ? "单位" : "部门"}`, children: item.deptName }] : []),
390
391
  ...(item.userName ? [{ label: "整改人", children: item.userName }] : []),
391
392
  ...(item.rectificationTime ? [{ label: "整改时间", children: item.rectificationTime }] : []),
392
393
  ...(item.descr ? [{ label: "整改描述", children: item.descr }] : []),
@@ -53,7 +53,7 @@ function Pdf(props) {
53
53
  const renderPdfContent = () => (
54
54
  <>
55
55
  {loading && (
56
- <div style={{ display: "flex", justifyContent: "center", alignItems: "center", height: "80vh" }}>
56
+ <div style={{ display: "flex", justifyContent: "center", alignItems: "center", height: "72vh" }}>
57
57
  <Spin size="large" />
58
58
  </div>
59
59
  )}
@@ -110,7 +110,7 @@ function Pdf(props) {
110
110
  >
111
111
  关闭
112
112
  </Button>,
113
- <Button
113
+ !loading && <Button
114
114
  key="fullScreen"
115
115
  onClick={() => {
116
116
  isFullscreen ? exitFullscreen() : enterFullscreen();
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "zy-react-library",
3
3
  "private": false,
4
- "version": "1.0.176",
4
+ "version": "1.0.178",
5
5
  "type": "module",
6
6
  "description": "",
7
7
  "author": "LiuJiaNan",