zy-react-library 1.0.150 → 1.0.152
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.
|
@@ -52,7 +52,7 @@ export interface FormListUniqueProps {
|
|
|
52
52
|
/** 删除按钮的文本,默认 '删除' */
|
|
53
53
|
removeButtonText?: string;
|
|
54
54
|
/** 表单配置项 */
|
|
55
|
-
options: (field: FormListFieldData) => FormOption[];
|
|
55
|
+
options: (field: FormListFieldData, index: number) => FormOption[];
|
|
56
56
|
/** 点击新增按钮时的默认值 */
|
|
57
57
|
addDefaultValue?: FormValues;
|
|
58
58
|
/** 点击新增按钮时插入的索引位置 */
|
|
@@ -223,9 +223,9 @@ const FormItemsRenderer = ({
|
|
|
223
223
|
};
|
|
224
224
|
|
|
225
225
|
// 获取 listOptions
|
|
226
|
-
const getListOptions = (listOptions, field) => {
|
|
226
|
+
const getListOptions = (listOptions, field, fieldIndex) => {
|
|
227
227
|
return typeof listOptions === "function"
|
|
228
|
-
? listOptions(field)
|
|
228
|
+
? listOptions(field, fieldIndex)
|
|
229
229
|
: (listOptions ?? []);
|
|
230
230
|
};
|
|
231
231
|
|
|
@@ -452,7 +452,7 @@ const FormItemsRenderer = ({
|
|
|
452
452
|
{(fields, { add, remove }) => (
|
|
453
453
|
<>
|
|
454
454
|
{fields.map((field, fieldIndex) => {
|
|
455
|
-
const listOptions = getListOptions(option.formListUniqueProps.options, field);
|
|
455
|
+
const listOptions = getListOptions(option.formListUniqueProps.options, field, fieldIndex);
|
|
456
456
|
return (
|
|
457
457
|
<Row gutter={gutter} key={field.key}>
|
|
458
458
|
{listOptions.map((listOption, listIndex) => {
|
|
@@ -206,7 +206,7 @@ function HiddenInfo(props) {
|
|
|
206
206
|
)
|
|
207
207
|
}
|
|
208
208
|
{
|
|
209
|
-
(info.
|
|
209
|
+
(info.hiddenConfirmUserCO && info.hiddenConfirmUserCO.length > 0) && (
|
|
210
210
|
<>
|
|
211
211
|
<Divider orientation="left">隐患确认</Divider>
|
|
212
212
|
{
|
|
@@ -379,7 +379,7 @@ function HiddenInfo(props) {
|
|
|
379
379
|
<>
|
|
380
380
|
<Divider orientation="left">整改信息</Divider>
|
|
381
381
|
{
|
|
382
|
-
info.
|
|
382
|
+
info.hiddenRectifyUserCO.map((item, index) => (
|
|
383
383
|
<Descriptions
|
|
384
384
|
key={item.id}
|
|
385
385
|
bordered
|
|
@@ -422,7 +422,7 @@ function HiddenInfo(props) {
|
|
|
422
422
|
<>
|
|
423
423
|
<Divider orientation="left">验收信息</Divider>
|
|
424
424
|
{
|
|
425
|
-
info.
|
|
425
|
+
info.hiddenAcceptUserCO.map((item, index) => (
|
|
426
426
|
<Descriptions
|
|
427
427
|
key={item.id}
|
|
428
428
|
bordered
|
|
@@ -446,7 +446,7 @@ function HiddenInfo(props) {
|
|
|
446
446
|
<>
|
|
447
447
|
<Divider orientation="left">验收打回信息</Divider>
|
|
448
448
|
{
|
|
449
|
-
info.
|
|
449
|
+
info.hiddenAcceptUserCO.map(item => (
|
|
450
450
|
<Descriptions
|
|
451
451
|
key={item.id}
|
|
452
452
|
bordered
|
|
@@ -81,6 +81,10 @@ export const UPLOAD_FILE_TYPE_ENUM = {
|
|
|
81
81
|
149: 149, // safety_qualification - 相关方-安全资质(弃用,全部改成使用148)
|
|
82
82
|
150: 150, // promise_bookmark_photo - 安全承诺签字
|
|
83
83
|
151: 151, // project_related_materials - 相关方-项目相关资料
|
|
84
|
+
152: 152, // legal_and_regulatory_database - 法律法规库
|
|
85
|
+
153: 153, // regulations_resource_library - 安全生产操作规程资源库
|
|
86
|
+
154: 154, // responsibility_based_resource_library - 安全生产责任制资源库
|
|
87
|
+
155: 155, // institutional_resource_library - 安全生产管理制度资源库
|
|
84
88
|
};
|
|
85
89
|
|
|
86
90
|
/**
|
|
@@ -163,4 +167,8 @@ export const UPLOAD_FILE_PATH_ENUM = {
|
|
|
163
167
|
149: "safety_qualification",
|
|
164
168
|
150: "promise_bookmark_photo",
|
|
165
169
|
151: "project_related_materials",
|
|
170
|
+
152: "legal_and_regulatory_database",
|
|
171
|
+
153: "regulations_resource_library",
|
|
172
|
+
154: "responsibility_based_resource_library",
|
|
173
|
+
155: "institutional_resource_library",
|
|
166
174
|
};
|