Quellcode durchsuchen

update 校验教材

xll vor 9 Monaten
Ursprung
Commit
5cc9d0da38

+ 7 - 6
projects/textbook/src/modules/nav-author/components/attachment/attachment.component.ts

@@ -205,7 +205,7 @@ export class AttachmentComponent implements OnInit {
       }
     }
     if (!check) {
-      // this.msg.create('warning', '请返回选择适用课程性质')
+      this.msg.create('warning', '请返回选择适用课程性质')
       return true
     }
 
@@ -234,12 +234,12 @@ export class AttachmentComponent implements OnInit {
     let authorListAuth
     console.log(this.authorList);
     authorListAuth = this.authorList.some((obj:any)=>{
-      return Object.keys(obj).some((item: string) => !obj[item])
+      return Object.keys(obj).some((item: string) => item!= 'signature' && !obj[item])
     })
-    // console.log(authorListAuth);
+    console.log(authorListAuth);
 
     if (isVrifly || authorListAuth) {
-      // this.msg.warning('存在未填项')
+      this.msg.warning('已保存,存在未填项')
       return true
     } else {
       return false
@@ -262,6 +262,7 @@ export class AttachmentComponent implements OnInit {
     
     let isPageNull = this.examineNull()//检查本页空项
     let isIgnoreFiled = this.isIgnoreFiledNull()//检查数据空项
+    // console.log(isPageNull,isIgnoreFiled);
     await this.saveEduTextbook(params, (!isPageNull && !isIgnoreFiled));
 
     if (event == 'pre') {//上一步
@@ -395,7 +396,7 @@ export class AttachmentComponent implements OnInit {
           mobile: '',
           email: '',
           work: '',
-          signature: '',
+          // signature: '',
           examine: '',
         });
         break;
@@ -428,7 +429,7 @@ export class AttachmentComponent implements OnInit {
               mobile: '',
               email: '',
               work: '',
-              signature: '',
+              // signature: '',
               examine: '',
             },
           ];

+ 11 - 11
projects/textbook/src/modules/nav-author/components/textbook-pertain/textbook-pertain.component.ts

@@ -32,7 +32,7 @@ interface author {
   mobile: string;
   email: string;
   work: string;
-  signature: string;
+  // signature: string;
   examine: string;
 }
 interface achievementType {
@@ -139,7 +139,7 @@ export class TextbookPertainComponent implements OnInit {
       mobile: '',
       email: '',
       work: '',
-      signature: '',
+      // signature: '',
       examine: '',
     },
   ];
@@ -294,13 +294,13 @@ export class TextbookPertainComponent implements OnInit {
   }
   changeCode() { }
   getCode(e: any) { }
-  upload(e: any, type: string, index: number) {
-    console.log(e);
-    let file = e[0];
-    if (type == 'signature' || type == 'examine') {
-      this.authorList[index][type] = file?.url
-    }
-  }
+  // upload(e: any, type: string, index: number) {
+  //   console.log(e);
+  //   let file = e[0];
+  //   if (type == 'signature' || type == 'examine') {
+  //     this.authorList[index][type] = file?.url
+  //   }
+  // }
   //添加作者信息
   onPush(type: string, idx: number) {
     switch (type) {
@@ -319,7 +319,7 @@ export class TextbookPertainComponent implements OnInit {
           mobile: '',
           email: '',
           work: '',
-          signature: '',
+          // signature: '',
           examine: '',
         });
         break;
@@ -352,7 +352,7 @@ export class TextbookPertainComponent implements OnInit {
               mobile: '',
               email: '',
               work: '',
-              signature: '',
+              // signature: '',
               examine: '',
             },
           ];