xll před 7 měsíci
rodič
revize
8fb75a541c

+ 9 - 9
projects/textbook/src/modules/nav-author/components/attachment/attachment.component.html

@@ -11,7 +11,7 @@
           版权页截图
         </a>
         }
-        <app-comp-upload [width]="320" [type]="'pdf'" (change)="upload($event, 'copyrightImgUrl')" title="上传PDF"></app-comp-upload>
+        <app-comp-upload [type]="'pdf'" [width]="320" [type]="'pdf'" (change)="upload($event, 'copyrightImgUrl')" title="上传PDF"></app-comp-upload>
 
         <div class="text upText" style="margin: 10px 0">
           支持上传PDF,大小不超过 2M
@@ -29,7 +29,7 @@
           CIP 查询截图
         </a>
         }
-        <app-comp-upload [width]="320" (change)="upload($event, 'CIPImgUrl')" title="上传PDF"></app-comp-upload>
+        <app-comp-upload [type]="'pdf'" [width]="320" (change)="upload($event, 'CIPImgUrl')" title="上传PDF"></app-comp-upload>
 
         <div class="text upText" style="margin: 10px 0">
           支持批量上传 PDF 格式,单个文件大小不超过 2M。
@@ -51,7 +51,7 @@
       </p>
       }
       }
-      <app-comp-upload [width]="320" [maxlenght]="99" (change)="upload($event, 'cipProveFile')"
+      <app-comp-upload [type]="'pdf'" [width]="320" [maxlenght]="99" (change)="upload($event, 'cipProveFile')"
         title="上传PDF"></app-comp-upload>
   
       <div class="text upText" style="margin: 10px 0">
@@ -79,7 +79,7 @@
           自查结果记录表
         </a>
         }
-        <app-comp-upload [width]="320" (change)="upload($event, 'selfResults')" title="上传PDF"></app-comp-upload>
+        <app-comp-upload [type]="'pdf'" [width]="320" (change)="upload($event, 'selfResults')" title="上传PDF"></app-comp-upload>
         <div class="text upText" style="margin: 10px 0">
           支持上传PDF,大小不超过 2M
         </div>
@@ -102,7 +102,7 @@
           专家审查意见表
         </a>
         }
-        <app-comp-upload [width]="320" (change)="upload($event, 'expertOpinion')" title="上传PDF"></app-comp-upload>
+        <app-comp-upload [type]="'pdf'" [width]="320" (change)="upload($event, 'expertOpinion')" title="上传PDF"></app-comp-upload>
         <div class="text upText" style="margin: 10px 0">
           支持批量上传 PDF、JPG、JPEG、PNG 格式,单个大小不超过 2M
         </div>
@@ -124,7 +124,7 @@
           证明材料
         </a>
         }
-        <app-comp-upload [width]="320" (change)="upload($event, 'evidence')" title="上传PDF"></app-comp-upload>
+        <app-comp-upload [type]="'pdf'" [width]="320" (change)="upload($event, 'evidence')" title="上传PDF"></app-comp-upload>
         <div class="text upText" style="margin: 10px 0">
           支持上传PDF,大小不超过 2M
         </div>
@@ -144,7 +144,7 @@
     </p>
     }
     }
-    <app-comp-upload [width]="320" [maxlenght]="99" (change)="upload($event, 'moreMaterial')"
+    <app-comp-upload [type]="'pdf'" [width]="320" [maxlenght]="99" (change)="upload($event, 'moreMaterial')"
       title="上传PDF"></app-comp-upload>
 
     <div class="text upText" style="margin: 10px 0">
@@ -167,7 +167,7 @@
     </p>
     }
     }
-    <app-comp-upload [width]="320" [maxlenght]="99" (change)="upload($event, 'examine')"
+    <app-comp-upload [type]="'pdf'" [width]="320" [maxlenght]="99" (change)="upload($event, 'examine')"
       title="上传PDF"></app-comp-upload>
 
     <div class="text upText" style="margin: 10px 0">
@@ -190,7 +190,7 @@
               申报单位承诺意见
             </a>
           }
-          <app-comp-upload [width]="320" (change)="upload($event, 'unitMaterial')" title="上传PDF"></app-comp-upload>
+          <app-comp-upload [type]="'pdf'" [width]="320" (change)="upload($event, 'unitMaterial')" title="上传PDF"></app-comp-upload>
           <div class="text upText" style="margin: 10px 0">
             支持上传PDF,大小不超过 2M
           </div>

+ 23 - 21
projects/textbook/src/modules/nav-author/components/attachment/attachment.component.ts

@@ -129,28 +129,29 @@ export class AttachmentComponent implements OnInit {
       msgList.push('版权页截图')
       isNull = true
     }
-    if (this.CIPImgUrl == '' || !this.CIPImgUrl) {
-      if (this.cipProveFile?.length > 0) {
-        let isExist = this.cipProveFile.every(item => item?.url == '' || !item?.url)
-        if (isExist) {
-          msgList.push('CIP 相关内容截图')
-          isNull = true
-        }
-      } else {
-          msgList.push('CIP 查询截图')
-          isNull = true
-      }
-    } 
     // if (this.CIPImgUrl == '' || !this.CIPImgUrl) {
-    //   msgList.push('CIP查询截图')
-    //   isCipNull = true
-    // }else if (this.cipProveFile?.length > 0) {
-    //   let isExist = this.cipProveFile.every(item => item?.url == '' || !item?.url)
-    //   if (isExist) {
-    //     msgList.push('CIP证明材料')
-    //     isNull = true
+    //   if (this.cipProveFile?.length > 0) {
+    //     let isExist = this.cipProveFile.every(item => item?.url == '' || !item?.url)
+    //     if (isExist) {
+    //       msgList.push('CIP 相关内容截图')
+    //       isNull = true
+    //     }
+    //   } else {
+    //       msgList.push('CIP 查询截图')
+    //       isNull = true
     //   }
-    // }
+    // } 
+    if (this.CIPImgUrl == '' || !this.CIPImgUrl) {
+      msgList.push('CIP查询截图')
+      isNull = true
+    }
+    if (this.cipProveFile?.length > 0) {
+      let isExist = this.cipProveFile.every(item => item?.url == '' || !item?.url)
+      if (isExist) {
+        msgList.push('CIP证明材料')
+        isNull = true
+      }
+    }
     if (this.selfResults.url == '' || !this.selfResults.url) {
       msgList.push('自查结果记录表')
       isNull = true
@@ -215,7 +216,8 @@ export class AttachmentComponent implements OnInit {
       'importantProject', 'importantProjectOther', 'complete', 'links', 'recommend',
       'printSun', 'discard', 'edition', 'eduProcess', 'authors', 'editor',
       'copyrightImgUrl', 'CIPImgurl', 'selfResults', 'expertOpinion', 'evidence',
-      'moreMaterial', 'unitMaterial', 'approvedImgUrl', 'department','CIPImgUrl','cipProveFile'
+      'moreMaterial', 'unitMaterial', 'approvedImgUrl', 'department','CIPImgUrl','cipProveFile',
+      'examine'
     ] //非必填字段
     let textBookJson = this.eduTextbook.toJSON()
 

+ 21 - 16
projects/textbook/src/services/EduTextbook.ts

@@ -8,12 +8,12 @@ export const EduTextbook = {
         },
         "user": {
             "type": "Pointer",
-            "targetClass":"_User",
+            "targetClass": "_User",
             "required": false
         },
         "department": { //所属流程
             "type": "Pointer",
-            "targetClass":"Department",
+            "targetClass": "Department",
             "required": false
         },
         "render": { //是否提交
@@ -212,31 +212,36 @@ export const EduTextbook = {
             "type": "String",
             "required": false
         },
-        "approvedImgUrl":{//重点立项教材获批截图            
-            "type":'String',
+        "approvedImgUrl": {//重点立项教材获批截图            
+            "type": 'String',
             "required": false
         },
         "eduProcess": {//所属流程
             "type": "Pointer",
-            "targetClass":"EduProcess",
+            "targetClass": "EduProcess",
             "required": false
         },
-        "code":{//编号
-            "type":'String',
+        "code": {//编号
+            "type": 'String',
             "required": false
         },
-        'editionUnit':{
-            "type":'String',
+        'editionUnit': {
+            "type": 'String',
             "required": false
         },
-        'copyrightImgUrl':{
-            "type":'String',
-            "required": false  
+        'copyrightImgUrl': {
+            "type": 'String',
+            "required": false
+        },
+        'CIPImgurl': {
+            "type": 'String',
+            "required": false
+        },
+
+        'examine': {//作者政治审核表
+            "type": 'Array',
+            "required": false
         },
-        'CIPImgurl':{
-            "type":'String',
-            "required": false  
-        }
     },
     "classLevelPermissions": {
         "find": {