shaogen1995 1 năm trước cách đây
mục cha
commit
fbe9f07a0c

+ 10 - 4
src/pages/A1Project/A1Inner/A1ILack.tsx

@@ -43,6 +43,7 @@ function A1ILack({ closeFu, addSuFu, projectId }: Props) {
         data.map((v) => ({
           ...v,
           done: v.attributeId === id ? val : v.done,
+          desc:v.attributeId === id&&v.desc==='-未填信息'?'':v.desc
         }))
       );
     },
@@ -66,11 +67,11 @@ function A1ILack({ closeFu, addSuFu, projectId }: Props) {
   // 点击确定
   const btnOk = useCallback(async () => {
     // 过滤掉已经 上传的 没有输入的
-    const arr = data.filter((v) => v.desc && v.done);
+    const arr = data.filter((v) => v.done);
 
     const arr2 = arr.map((v) => ({
       attributeId: v.attributeId,
-      description: v.desc,
+      description: v.desc || "-未填信息",
     }));
 
     const res = await A1_APIIsaveLack(projectId, arr2);
@@ -118,13 +119,18 @@ function A1ILack({ closeFu, addSuFu, projectId }: Props) {
                     <div className="A1ILmainCRow1Txt2">:</div>
                   </Checkbox>
                 </div>
-                <div className="A1ILmainCRow2">
+                <div
+                  className={classNames(
+                    "A1ILmainCRow2",
+                    v.desc === "-未填信息" ? "A1ILmainCRow2NoTxt" : ""
+                  )}
+                >
                   {v.hasUpload ? (
                     "已上传"
                   ) : (
                     <Input
                       disabled={!v.done}
-                      placeholder="请输入缺失原因,为空则不会录入系统"
+                      placeholder="请输入缺失原因"
                       maxLength={100}
                       showCount
                       value={v.desc}

+ 11 - 3
src/pages/A1Project/A1Inner/index.module.scss

@@ -32,7 +32,7 @@
       overflow: hidden;
 
       .ant-table-body {
-        height: 666px;
+        height: 610px;
         overflow-y: auto !important;
 
         .ant-table-row {
@@ -182,6 +182,12 @@
             }
 
           }
+
+          .A1ILmainCRow2NoTxt {
+            input {
+              color: #ccc;
+            }
+          }
         }
       }
 
@@ -222,14 +228,16 @@
             color: #ff4d4f;
           }
         }
-        .A1IAmainRow1_2{
+
+        .A1IAmainRow1_2 {
           padding-top: 4px;
         }
 
         .A1IAmainRow2 {
           width: calc(100% - 80px);
           display: flex;
-          &>div{
+
+          &>div {
             margin-right: 20px;
           }
         }

+ 11 - 7
src/pages/A1Project/A1Inner/index.tsx

@@ -189,12 +189,16 @@ function A1Inner({ projectId, myTitle, projectName }: Props) {
         render: (item: A1ItableType) =>
           item.hasLack === 1 ? (
             <>
-              <Tooltip title={item.description}>
-                <div className="iconHoverTit">
-                  无法提供&nbsp;
-                  <div className="iconHoverTitTxt">?</div>
-                </div>
-              </Tooltip>
+              {item.description === "-未填信息" ? (
+                "无法提供"
+              ) : (
+                <Tooltip title={item.description}>
+                  <div className="iconHoverTit">
+                    无法提供&nbsp;
+                    <div className="iconHoverTitTxt">?</div>
+                  </div>
+                </Tooltip>
+              )}
             </>
           ) : (
             item.fileName
@@ -378,7 +382,7 @@ function A1Inner({ projectId, myTitle, projectName }: Props) {
               disabled: item.hasLack === 1, // 配置无法勾选的列
             }),
           }}
-          scroll={{ y: 666 }}
+          scroll={{ y: 610 }}
           dataSource={data}
           columns={columns}
           rowKey="id"

+ 1 - 1
src/pages/A1Project/index.module.scss

@@ -36,7 +36,7 @@
       overflow: hidden;
 
       .ant-table-body {
-        height: 575px;
+        height: 550px;
         overflow-y: auto !important;
 
         .ant-table-row {

+ 1 - 1
src/pages/A1Project/index.tsx

@@ -487,7 +487,7 @@ function A1Project() {
       {/* 表格主体 */}
       <div className="A1tableBox">
         <Table
-          scroll={{ y: 575 }}
+          scroll={{ y: 550 }}
           dataSource={tableInfo.list}
           columns={columns}
           rowKey="id"