浏览代码

Merge branch 'master' of http://git.fmode.cn:3000/bin/edu-textbook

ryanemax 6 月之前
父节点
当前提交
c05310da8a

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

@@ -354,7 +354,7 @@
   </div>
   <div class="author-content">
     <div class="title">6.其他材料(可选提供)</div>
-    <div class="text">其他佐证材料。</div>
+    <div class="text">其他佐证材料,限两份以内。</div>
     <!-- @if (moreMaterial.length>0) { @for (url of moreMaterial; track $index) {
     <p>
       <a style="color: #3e49b3; font-size: 14px" (click)="openFile(url?.url)">

+ 1 - 1
projects/textbook/src/modules/nav-author/components/create/content/content.component.ts

@@ -118,7 +118,7 @@ export class ContentComponent implements OnInit {
 
   async submitForm(): Promise<boolean> {
     let coursesVrifly = !this.courses.some((item) =>
-      Object.values(item).some((val) => val == '' || val == undefined)
+      Object.values(item).some((val) => val != 0 && (val == '' || val == undefined))
     );
     this.eduTextbookVolume?.set('courses', this.courses);
     await this.eduTextbookVolume?.save();

+ 5 - 5
projects/textbook/src/services/textbook.ts

@@ -60,14 +60,14 @@ export class textbookServer {
   async formatNode(id: string): Promise<Array<any>> {
     if (!id) return [];
     let query = new Parse.Query('Department');
-    query.select('name', 'parent', 'hasChildren', 'type', 'branch');
+    query.select('name', 'parent.name', 'branch');
     let r = await query.get(id);
     let arr = [
       {
         title: r.get('name'),
         key: r.id,
-        hasChildren: r.get('hasChildren'), //是否是最下级
-        type: r.get('type'),
+        // hasChildren: r.get('hasChildren'), //是否是最下级
+        // type: r.get('type'),
         branch: r?.get('branch'),
         parent: r?.get('parent')?.id, //上级
       },
@@ -354,8 +354,8 @@ export class textbookServer {
         'department.branch'
       );
       query.limit(3000);
-      // query.containedIn('status', ['103', '200', '201', '400']);
-      query.containedIn('status',['400'])
+      query.containedIn('status', ['103', '200', '201', '400']);
+      // query.containedIn('status',['400'])
       let data = await query.find();
       let table = `<table border="1px" cellspacing="0" cellpadding="0">
           <thead>