warrior 8 months ago
parent
commit
f7e2a5baa0
19 changed files with 887 additions and 54 deletions
  1. 6 6
      projects/textbook/src/app/app.routes.ts
  2. 25 22
      projects/textbook/src/modules/nav-author/apply/apply.component.html
  3. 4 2
      projects/textbook/src/modules/nav-author/apply/apply.component.scss
  4. 10 7
      projects/textbook/src/modules/nav-author/apply/apply.component.ts
  5. 428 0
      projects/textbook/src/modules/nav-author/components/basic-in/basic-in.component.html
  6. 24 0
      projects/textbook/src/modules/nav-author/components/basic-in/basic-in.component.scss
  7. 24 0
      projects/textbook/src/modules/nav-author/components/basic-in/basic-in.component.spec.ts
  8. 203 0
      projects/textbook/src/modules/nav-author/components/basic-in/basic-in.component.ts
  9. 5 0
      projects/textbook/src/modules/nav-author/modules.routes.ts
  10. 16 0
      projects/textbook/src/modules/nav-review/approve/approve.component.html
  11. 0 0
      projects/textbook/src/modules/nav-review/approve/approve.component.scss
  12. 24 0
      projects/textbook/src/modules/nav-review/approve/approve.component.spec.ts
  13. 42 0
      projects/textbook/src/modules/nav-review/approve/approve.component.ts
  14. 19 9
      projects/textbook/src/modules/nav-review/modules.routes.ts
  15. 2 2
      projects/textbook/src/modules/nav-review/page-home/page-home.component.html
  16. 4 1
      projects/textbook/src/modules/nav-review/page-home/page-home.component.scss
  17. 12 4
      projects/textbook/src/modules/nav-review/page-home/page-home.component.ts
  18. 5 1
      projects/textbook/src/services/common.modules.ts
  19. 34 0
      projects/textbook/src/services/languages.map.ts

+ 6 - 6
projects/textbook/src/app/app.routes.ts

@@ -16,32 +16,32 @@ export const routes: Routes = [
   },
   {
     path: 'nav-admin', //国家级管理员管理平台
-    canActivate: mapToCanActivate([AuthGuard]),
+    //canActivate: mapToCanActivate([AuthGuard]),
     loadChildren: () =>import('../modules/nav-admin/modules.routes').then((mod) => mod.NavAdminRoutingModule),
   },
   {
     path: 'nav-province-submit',//省级教育行政部门
-    canActivate: mapToCanActivate([AuthGuard]),
+    //canActivate: mapToCanActivate([AuthGuard]),
     loadChildren: () =>import('../modules/nav-province-submit/modules.routes').then((mod) => mod.NavProRoutingModule),
   },
   {
     path: 'nav-province-contact',//中央部门所属高校联系人、部省合建高校联系人、出版单位联系人、省属高校流程管理员
-    canActivate: mapToCanActivate([AuthGuard]),
+    //canActivate: mapToCanActivate([AuthGuard]),
     loadChildren: () =>import('../modules/nav-province-contact/modules.routes').then((mod) => mod.NavProContactRoutingModule),
   },
   {
     path: 'nav-province-school-contact', //省属高校联系人
-    canActivate: mapToCanActivate([AuthGuard]),
+    //canActivate: mapToCanActivate([AuthGuard]),
     loadChildren: () =>import('../modules/nav-province-school-contact/modules.routes').then((mod) => mod.NavProSchoolRoutingModule),
   },
   {
     path: 'nav-review', //教材评审组成员
-    canActivate: mapToCanActivate([AuthGuard]),
+    //canActivate: mapToCanActivate([AuthGuard]),
     loadChildren: () =>import('../modules/nav-review/modules.routes').then((mod) => mod.NavReviewRoutingModule),
   },
   {
     path: 'nav-author', //作者 / 教师 / 主编
-    canActivate: mapToCanActivate([AuthGuard]),
+    //canActivate: mapToCanActivate([AuthGuard]),
     loadChildren: () =>import('../modules/nav-author/modules.routes').then((mod) => mod.NavAuthorRoutingModule),
   },
 ];

+ 25 - 22
projects/textbook/src/modules/nav-author/apply/apply.component.html

@@ -15,29 +15,32 @@
       <nz-step nzTitle="上传附件及承诺" nzDescription=""></nz-step>
     </nz-steps>
   </div>
-  <div class="state-title">{{stateMap}}</div>
+  <div class="state-title">{{ stateMap }}</div>
   <div class="submit-block">
-    <div class="entry">
-
-      
-    </div>
+    @switch (state) { @case (0) {
+      <app-basic></app-basic>
+    } @case (1) {
+    <div class="entry"></div>
     <div class="footer">
-      <button nz-button nzType="primary">下一步</button>
-      <button nz-button nzType="default">保存</button>
+      <button
+        nz-button
+        nzType="default"
+        style="margin-right: 20px"
+      >
+        保存本页
+      </button>
+      <button
+        nz-button
+        nzType="default"
+        style="margin-right: 20px"
+        (click)="state = 0"
+      >
+        上一页
+      </button>
+      <button nz-button nzType="primary">
+        下一页
+      </button>
     </div>
+    } @case (2) { } @case (3) { } }
   </div>
-  @switch (state) {
-    @case (1) {
-
-    }
-    @case (1) {
-
-    }
-    @case (1) {
-
-    }
-    @case (1) {
-
-    }
-  }
-</div>
+</div>

+ 4 - 2
projects/textbook/src/modules/nav-author/apply/apply.component.scss

@@ -12,14 +12,16 @@
     margin: 10px auto;
     .entry{
       min-height: 500px;
-      border: 1px solid;
+      // border: 1px solid;
     }
     .footer{
       display: flex;
       margin: 10px auto;
       align-items: center;
       justify-content: space-evenly;
-      width: 200px;
+      // width: 200px;
+      justify-content: end;
+      padding-right: 100px;
     }
   }
 }

+ 10 - 7
projects/textbook/src/modules/nav-author/apply/apply.component.ts

@@ -1,9 +1,11 @@
-import { Component, OnInit } from '@angular/core';
+import { Component, OnInit,Input,Output,EventEmitter } from '@angular/core';
 import { CommonCompModule } from '../../../services/common.modules'
 import { Router } from '@angular/router';
+import { ReactiveFormsModule } from '@angular/forms';
+import { BasicInComponent } from '../components/basic-in/basic-in.component'
 @Component({
   selector: 'app-apply',
-  imports: [CommonCompModule],
+  imports: [CommonCompModule,ReactiveFormsModule,BasicInComponent],
   standalone: true,
   templateUrl: './apply.component.html',
   styleUrls: ['./apply.component.scss']
@@ -12,18 +14,19 @@ export class ApplyComponent implements OnInit {
   state:number = 0
   get stateMap(){
     let map:any = {
-      '0':'填写基本信息',
-      '1':'填写材料适用情况',
+      '0':'教材基本信息',
+      '1':'教材适用情况',
       '2':'填写材料内容',
       '3':'上传附件及承诺',
     }
     return map[this.state]
   }
+  editForm:any
+
   constructor(
-    private router:Router
-  ) { }
+    private router:Router,
+  ) {}
 
   ngOnInit() {
   }
-
 }

+ 428 - 0
projects/textbook/src/modules/nav-author/components/basic-in/basic-in.component.html

@@ -0,0 +1,428 @@
+<div class="entry">
+  <form
+    nz-form
+    [formGroup]="validateForm"
+    class="login-form"
+    (ngSubmit)="submitForm()"
+  >
+    <nz-form-item style="margin-bottom: 16px">
+      <nz-form-label [nzSm]="8" [nzXs]="8" nzRequired nzFor="user"
+        >申报教材名称</nz-form-label
+      >
+      <nz-form-control nzErrorTip="请输入申报教材名称" [nzSm]="12" [nzXs]="12">
+        <nz-input-group>
+          <input
+            type="text"
+            nz-input
+            formControlName="name"
+            placeholder="请输入申报教材名称"
+          />
+        </nz-input-group>
+      </nz-form-control>
+    </nz-form-item>
+    <nz-form-item style="margin-bottom: 16px">
+      <nz-form-label [nzSm]="8" [nzXs]="8" nzRequired
+        >国际标准书号</nz-form-label
+      >
+      <nz-form-control nzErrorTip="请输入国际标准书号" [nzSm]="12" [nzXs]="12">
+        <nz-input-group>
+          <input
+            type="text"
+            nz-input
+            formControlName="ISBN"
+            placeholder="请输入国际标准书号"
+          />
+        </nz-input-group>
+      </nz-form-control>
+    </nz-form-item>
+    <nz-form-item style="margin-bottom: 16px">
+      <nz-form-label [nzSm]="8" [nzXs]="8" nzRequired
+        >第一主编(作者)</nz-form-label
+      >
+      <nz-form-control
+        nzErrorTip="请输入第一主编(作者)"
+        [nzSm]="12"
+        [nzXs]="12"
+      >
+        <nz-input-group>
+          <input
+            type="text"
+            nz-input
+            formControlName="author"
+            placeholder="请输入第一主编(作者)"
+          />
+        </nz-input-group>
+      </nz-form-control>
+    </nz-form-item>
+    <nz-form-item style="margin-bottom: 16px">
+      <nz-form-label [nzSm]="8" [nzXs]="8" nzRequired
+        >第一主编(作者)单位</nz-form-label
+      >
+      <nz-form-control
+        nzErrorTip="请输入第一主编(作者)单位"
+        [nzSm]="12"
+        [nzXs]="12"
+      >
+        <nz-input-group>
+          <input
+            type="text"
+            nz-input
+            formControlName="unit"
+            placeholder="请输入第一主编(作者)单位"
+          />
+        </nz-input-group>
+      </nz-form-control>
+    </nz-form-item>
+    <nz-form-item style="margin-bottom: 16px">
+      <nz-form-label [nzSm]="8" [nzXs]="8" nzRequired>申报类型</nz-form-label>
+      <nz-form-control nzErrorTip="请输入申报类型" [nzSm]="12" [nzXs]="12">
+        <nz-input-group>
+          <input
+            type="text"
+            nz-input
+            formControlName="type"
+            placeholder="请输入申报类型"
+          />
+        </nz-input-group>
+      </nz-form-control>
+    </nz-form-item>
+    <nz-form-item style="margin-bottom: 16px">
+      <nz-form-label [nzSm]="8" [nzXs]="8" nzRequired
+        >教材应用对象及所诉学科专业类</nz-form-label
+      >
+      <nz-form-control
+        nzErrorTip="请输入教材应用对象及所诉学科专业类"
+        [nzSm]="12"
+        [nzXs]="12"
+      >
+        <nz-input-group>
+          <nz-select
+            nzShowSearch
+            nzAllowClear
+            nzPlaceHolder="请输入搜索内容"
+            formControlName="majorPoniter"
+            (ngModelChange)="changeMajor()"
+            (nzOnSearch)="getMajor($event)"
+          >
+            @for(major of selectList; track major.code;let index = $index){
+            <nz-option
+              nzCustomContent
+              [nzValue]="major.code"
+              [nzLabel]="major.name"
+              >{{ major.name }}</nz-option
+            >
+            }
+          </nz-select>
+        </nz-input-group>
+      </nz-form-control>
+    </nz-form-item>
+    <nz-form-item style="margin-bottom: 16px">
+      <nz-form-label [nzSm]="8" [nzXs]="8" nzRequired
+        >教材主要语种类型</nz-form-label
+      >
+      <nz-form-control
+        nzErrorTip="请输入教材主要语种类型"
+        [nzSm]="12"
+        [nzXs]="12"
+      >
+        <nz-input-group>
+          <nz-select
+            nzShowSearch
+            nzAllowClear
+            nzPlaceHolder="请输入搜索内容"
+            formControlName="lang"
+            (ngModelChange)="changeMajor()"
+            (nzOnSearch)="getMajor($event)"
+          >
+            @for(lang of selectLang; track lang.lang;let index = $index){
+            <nz-option
+              nzCustomContent
+              [nzValue]="lang.lang"
+              [nzLabel]="lang.name"
+              >{{ lang.name }}</nz-option
+            >
+            }
+          </nz-select>
+        </nz-input-group>
+      </nz-form-control>
+    </nz-form-item>
+    <nz-form-item style="margin-bottom: 16px">
+      <nz-form-label [nzSm]="8" [nzXs]="8" nzRequired
+        >其他主编姓名</nz-form-label
+      >
+      <nz-form-control nzErrorTip="请输入其他主编姓名" [nzSm]="12" [nzXs]="12">
+        <nz-input-group>
+          <textarea
+            type="text"
+            nz-input
+            formControlName="authors"
+            placeholder="请输入其他主编姓名"
+          ></textarea>
+        </nz-input-group>
+      </nz-form-control>
+    </nz-form-item>
+    <nz-form-item style="margin-bottom: 16px">
+      <nz-form-label [nzSm]="8" [nzXs]="8" nzRequired
+        >其他编者姓名</nz-form-label
+      >
+      <nz-form-control nzErrorTip="请输入其他编者姓名" [nzSm]="12" [nzXs]="12">
+        <nz-input-group>
+          <textarea
+            type="text"
+            nz-input
+            formControlName="editor"
+            placeholder="请输入其他编者姓名"
+          ></textarea>
+        </nz-input-group>
+      </nz-form-control>
+    </nz-form-item>
+    <nz-form-item style="margin-bottom: 16px">
+      <nz-form-label [nzSm]="8" [nzXs]="8" nzRequired
+        >是否重点立项教材</nz-form-label
+      >
+      <nz-form-control nzErrorTip="请输入完成项" [nzSm]="12" [nzXs]="12">
+        <nz-input-group>
+          <nz-select
+            nzShowSearch
+            nzAllowClear
+            nzPlaceHolder="请输入是否重点立项教材"
+            formControlName="approval"
+            (ngModelChange)="changeMajor()"
+            (nzOnSearch)="getMajor($event)"
+          >
+            @for(item of directorys; track item.code;let index = $index){
+            <nz-option
+              nzCustomContent
+              [nzValue]="item.code"
+              [nzLabel]="item.name"
+              >{{ item.name }}</nz-option
+            >
+            }
+          </nz-select>
+        </nz-input-group>
+      </nz-form-control>
+    </nz-form-item>
+    <nz-form-item style="margin-bottom: 16px">
+      <nz-form-label [nzSm]="8" [nzXs]="8" nzRequired>出版单位</nz-form-label>
+      <nz-form-control nzErrorTip="请输入出版单位" [nzSm]="12" [nzXs]="12">
+        <nz-input-group>
+          <input
+            type="text"
+            nz-input
+            formControlName="edition"
+            placeholder="请输入出版单位"
+          />
+        </nz-input-group>
+      </nz-form-control>
+    </nz-form-item>
+    <nz-form-item style="margin-bottom: 16px">
+      <nz-form-label [nzSm]="8" [nzXs]="8" nzRequired>初版时间</nz-form-label>
+      <nz-form-control nzErrorTip="请输入初版时间" [nzSm]="12" [nzXs]="12">
+        <nz-input-group>
+          <nz-date-picker
+            style="width: 100%"
+            formControlName="editionFirst"
+            (ngModelChange)="onChange($event)"
+          ></nz-date-picker>
+        </nz-input-group>
+      </nz-form-control>
+    </nz-form-item>
+    <nz-form-item style="margin-bottom: 16px">
+      <nz-form-label [nzSm]="8" [nzXs]="8" nzRequired>载体形式</nz-form-label>
+      <nz-form-control nzErrorTip="请输入载体形式" [nzSm]="12" [nzXs]="12">
+        <nz-input-group>
+          <nz-select
+            nzShowSearch
+            nzAllowClear
+            nzPlaceHolder="请输入是否重点立项教材"
+            formControlName="approval"
+            (ngModelChange)="changeMajor()"
+            (nzOnSearch)="getMajor($event)"
+          >
+            @for(item of carrierOptions; track item.code;let index = $index){
+            <nz-option
+              nzCustomContent
+              [nzValue]="item.code"
+              [nzLabel]="item.name"
+              >{{ item.name }}</nz-option
+            >
+            }
+          </nz-select>
+        </nz-input-group>
+      </nz-form-control>
+    </nz-form-item>
+    <nz-form-item style="margin-bottom: 16px">
+      <nz-form-label [nzSm]="8" [nzXs]="8" nzRequired
+        >出版时间及版次</nz-form-label
+      >
+      <nz-form-control nzErrorTip="请输入出版时间" [nzSm]="12" [nzXs]="12">
+        <nz-input-group>
+          <div class="basic-row">
+            <nz-date-picker
+              style="flex: 1"
+              formControlName="editionDate"
+              (ngModelChange)="onChange($event)"
+            ></nz-date-picker>
+            <nz-input-group
+              style="width: 100px; margin-left: 20px"
+              [nzSuffix]="suffixTemplateInfo"
+            >
+              <input
+                type="number"
+                formControlName="editionNumber"
+                nz-input
+                placeholder="输入版次"
+              />
+            </nz-input-group>
+            <ng-template #suffixTemplateInfo> 次 </ng-template>
+          </div>
+        </nz-input-group>
+      </nz-form-control>
+    </nz-form-item>
+    <nz-form-item style="margin-bottom: 16px">
+      <nz-form-label [nzSm]="8" [nzXs]="8" nzRequired
+        >最新印次时间及印次</nz-form-label
+      >
+      <nz-form-control nzErrorTip="请输入完整内容" [nzSm]="12" [nzXs]="12">
+        <nz-input-group>
+          <div class="basic-row">
+            <nz-date-picker
+              style="flex: 1"
+              formControlName="printDate"
+              (ngModelChange)="onChange($event)"
+            ></nz-date-picker>
+            <nz-input-group
+              style="width: 100px; margin-left: 20px"
+              [nzSuffix]="suffixTemplateInfo"
+            >
+              <input
+                type="number"
+                formControlName="printNumber"
+                nz-input
+                placeholder="输入版次"
+              />
+            </nz-input-group>
+            <ng-template #suffixTemplateInfo> 次 </ng-template>
+          </div>
+        </nz-input-group>
+      </nz-form-control>
+    </nz-form-item>
+
+    <nz-form-item style="margin-bottom: 16px">
+      <nz-form-label [nzSm]="8" [nzXs]="8" nzRequired
+        >初版以来合计印次</nz-form-label
+      >
+      <nz-form-control
+        nzErrorTip="请输入初版以来合计印次"
+        [nzSm]="12"
+        [nzXs]="12"
+      >
+        <nz-input-group>
+          <nz-input-group [nzSuffix]="suffixTemplateInfo">
+            <input
+              type="number"
+              formControlName="printSum"
+              nz-input
+              placeholder="输入版次"
+            />
+          </nz-input-group>
+          <ng-template #suffixTemplateInfo> 次 </ng-template>
+        </nz-input-group>
+      </nz-form-control>
+    </nz-form-item>
+    <nz-form-item style="margin-bottom: 16px">
+      <nz-form-label [nzSm]="8" [nzXs]="8" nzRequired
+        >初版以来是否列为重点项目</nz-form-label
+      >
+      <nz-form-control nzErrorTip="" [nzSm]="12" [nzXs]="12">
+        <nz-input-group>
+          <!-- <input
+            type="text"
+            nz-input
+            formControlName="importantProject"
+            placeholder=""
+          /> -->
+          <nz-radio-group
+            style="display: flex; flex-direction: column"
+            formControlName="importantProject"
+          >
+            @for (item of importantProjectList; track item.value) {
+            <label nz-radio [nzValue]="item.value">{{ item.title }}</label>
+            } @if (validateForm.value.importantProject ==
+            '其他省部级及以上项目') {
+            <input
+              type="text"
+              formControlName="importantProjectOther"
+              nz-input
+            />
+            }
+            <label nz-radio nzValue="">否</label>
+          </nz-radio-group>
+        </nz-input-group>
+      </nz-form-control>
+    </nz-form-item>
+    <nz-form-item style="margin-bottom: 16px">
+      <nz-form-label [nzSm]="8" [nzXs]="8" nzRequired>版权页截图</nz-form-label>
+      <nz-form-control nzErrorTip="请输入版权页截图" [nzSm]="12" [nzXs]="12">
+        <nz-input-group>
+          <nz-upload
+            formControlName="copyrightImgUrl"
+            nzAction="https://www.mocky.io/v2/5cc8019d300000980a055e76"
+            [nzHeaders]="{ authorization: 'authorization-text' }"
+            (nzChange)="handleChange($event)"
+          >
+            <button nz-button>
+              <span nz-icon nzType="upload"></span>
+              上传截图
+            </button>
+          </nz-upload>
+        </nz-input-group>
+      </nz-form-control>
+    </nz-form-item>
+    <nz-form-item style="margin-bottom: 16px">
+      <nz-form-label [nzSm]="8" [nzXs]="8" nzRequired
+        >中国版本图书馆CIP查询截图</nz-form-label
+      >
+      <nz-form-control nzErrorTip="" [nzSm]="12" [nzXs]="12">
+        <nz-input-group>
+          <div class="row-block">
+            <nz-upload
+              formControlName="CIPImgUrl"
+              nzAction="https://www.mocky.io/v2/5cc8019d300000980a055e76"
+              [nzHeaders]="{ authorization: 'authorization-text' }"
+              (nzChange)="handleChange($event)"
+            >
+              <button nz-button>
+                <span nz-icon nzType="upload"></span>
+                上传截图
+              </button>
+            </nz-upload>
+            <div class="tips">
+              <span
+                nz-icon
+                nzType="exclamation-circle"
+                nzTheme="fill"
+                style="font-size: 16px; color: #3e49b3;margin-right: 4px;"
+              ></span
+              >如 CIP
+              数据中无“教材”字样的,须再上传内容提要或前言或后记中可以证明本书为教材的相关内容截图
+            </div>
+          </div>
+        </nz-input-group>
+      </nz-form-control>
+    </nz-form-item>
+  </form>
+</div>
+<div class="footer">
+  <button
+    nz-button
+    nzType="default"
+    style="margin-right: 20px"
+    (click)="submitForm('save')"
+  >
+    保存本页
+  </button>
+  <button nz-button nzType="primary" (click)="submitForm('next')">
+    下一页
+  </button>
+</div>

+ 24 - 0
projects/textbook/src/modules/nav-author/components/basic-in/basic-in.component.scss

@@ -0,0 +1,24 @@
+.entry{
+  min-height: 500px;
+  // border: 1px solid;
+  .basic-row{
+    display: flex;
+    justify-content: space-between;
+    width: 100%;
+  }
+  .tips{
+    margin-top: 10px;
+    padding: 10px;
+    background: #3e49b314;
+    border-radius: 6px;
+  }
+}
+.footer{
+  display: flex;
+  margin: 10px auto;
+  align-items: center;
+  justify-content: space-evenly;
+  // width: 200px;
+  justify-content: end;
+  padding-right: 100px;
+}

+ 24 - 0
projects/textbook/src/modules/nav-author/components/basic-in/basic-in.component.spec.ts

@@ -0,0 +1,24 @@
+import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
+import { IonicModule } from '@ionic/angular';
+
+import { BasicInComponent } from './basic-in.component';
+
+describe('BasicInComponent', () => {
+  let component: BasicInComponent;
+  let fixture: ComponentFixture<BasicInComponent>;
+
+  beforeEach(waitForAsync(() => {
+    TestBed.configureTestingModule({
+      declarations: [ BasicInComponent ],
+      imports: [IonicModule.forRoot()]
+    }).compileComponents();
+
+    fixture = TestBed.createComponent(BasicInComponent);
+    component = fixture.componentInstance;
+    fixture.detectChanges();
+  }));
+
+  it('should create', () => {
+    expect(component).toBeTruthy();
+  });
+});

+ 203 - 0
projects/textbook/src/modules/nav-author/components/basic-in/basic-in.component.ts

@@ -0,0 +1,203 @@
+import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core';
+import { languages } from '../../../../services/languages.map';
+import { CommonCompModule } from '../../../../services/common.modules';
+import { NzSelectModule } from 'ng-zorro-antd/select';
+import { ReactiveFormsModule } from '@angular/forms';
+import { NzRadioModule } from 'ng-zorro-antd/radio';
+import { NzUploadModule } from 'ng-zorro-antd/upload';
+import { NzMessageService } from 'ng-zorro-antd/message';
+import { NzUploadChangeParam } from 'ng-zorro-antd/upload';
+import {
+  FormControl,
+  FormGroup,
+  NonNullableFormBuilder,
+  Validators,
+} from '@angular/forms';
+interface applyType {
+  type: string;
+  num: string;
+}
+@Component({
+  selector: 'app-basic',
+  imports: [
+    CommonCompModule,
+    ReactiveFormsModule,
+    NzSelectModule,
+    NzRadioModule,
+    NzUploadModule,
+  ],
+  standalone: true,
+  templateUrl: './basic-in.component.html',
+  styleUrls: ['./basic-in.component.scss'],
+})
+export class BasicInComponent implements OnInit {
+  @Input('editFrom') editFrom: any;
+  @Output() next: EventEmitter<any> = new EventEmitter<any>();
+  @Output() save: EventEmitter<any> = new EventEmitter<any>();
+
+  validateForm: FormGroup<{
+    name: FormControl<string>; //申报教材名称
+    ISBN: FormControl<string>; //国际标准书号
+    author: FormControl<string>; //第一主编(作者)
+    unit: FormControl<string>; //第一主编(作者)单位
+    type: FormControl<applyType | any>; //申报类型
+    majorPoniter: FormControl<string>; //教材应用对象及所诉学科专业类
+    lang: FormControl<string>; //教材主要语种类型
+    authors: FormControl<string>; //其他主编姓名
+    editor: FormControl<string>; //其他编者姓名
+
+    approval: FormControl<string>; //是否重点立项教材
+    edition: FormControl<string>; //出版单位
+    editionFirst: FormControl<Date>; //初版时间
+    carrierShape: FormControl<string>; //载体形式
+
+    editionDate: FormControl<Date>; //出版时间
+    editionNumber: FormControl<number>; //出版版次
+    printDate: FormControl<Date>; //最新印次时间
+    printNumber: FormControl<number>; //最新印次
+
+    printSum: FormControl<number>; //初版以来合计印次
+
+    importantProject: FormControl<string>; //初版以来是否列为重点项目
+    importantProjectOther: FormControl<string>; //其他省部级及以上项目
+
+    copyrightImgUrl: FormControl<string>; //版权页截图
+    CIPImgUrl: FormControl<string>; //中国版本图书馆CIP查询截图
+
+    // remember: FormControl<boolean>;
+  }> = this.fb.group({
+    name: ['', [Validators.required]],
+    ISBN: ['', [Validators.required]],
+    author: ['', [Validators.required]],
+    unit: ['', [Validators.required]],
+    type: ['', [Validators.required]],
+    majorPoniter: ['', [Validators.required]],
+    lang: ['', [Validators.required]],
+    authors: ['', [Validators.required]],
+    editor: ['', [Validators.required]],
+    approval: ['', [Validators.required]],
+    edition: ['', [Validators.required]],
+    editionFirst: [new Date(), [Validators.required]],
+    carrierShape: ['', [Validators.required]],
+    editionDate: [new Date(), [Validators.required]],
+    editionNumber: [0, [Validators.required]],
+    printDate: [new Date(), [Validators.required]],
+    printNumber: [0, [Validators.required]],
+    printSum: [0, [Validators.required]],
+    importantProject: ['', [Validators.required]],
+    importantProjectOther: ['', [Validators.required]],
+    copyrightImgUrl: ['', [Validators.required]],
+    CIPImgUrl: ['', [Validators.required]],
+    // remember: [true],
+  });
+  //教材应用对象及所诉学科专业类
+  selectList: Array<any> = [
+    {
+      name: '机械与工程',
+      code: 'M001',
+    },
+    {
+      name: '软件工程',
+      code: 'M002',
+    },
+    {
+      name: '生物工程学',
+      code: 'M003',
+    },
+  ];
+  //语言选择
+  selectLang: Array<any> = languages.options;
+  //重点项目选择
+  directorys: Array<any> = [
+    {
+      name: '电气设计原理',
+      code: 'T001',
+    },
+    {
+      name: '微生物学',
+      code: 'T002',
+    },
+    {
+      name: '细胞学',
+      code: 'T003',
+    },
+  ];
+  //载体形式
+  carrierOptions: Array<any> = [
+    {
+      name: '载体一',
+      code: 'Z001',
+    },
+    {
+      name: '载体二',
+      code: 'Z002',
+    },
+    {
+      name: '载体三',
+      code: 'Z003',
+    },
+  ];
+  importantProjectList: Array<any> = [
+    {
+      title: '“十二五”普通高等教育本科国家级规划教材',
+      value: '“十二五”普通高等教育本科国家级规划教材',
+    },
+    {
+      title: '“十二五”以来省级优秀教材',
+      value: '“十二五”以来省级优秀教材',
+    },
+    {
+      title: '“十二五”以来省级规划教材',
+      value: '“十二五”以来省级规划教材',
+    },
+    {
+      title: '其他省部级及以上项目',
+      value: '其他省部级及以上项目',
+    },
+  ];
+  // get importantProjectState(){
+  //   return this.importantProjectList.some((item:any)=> item.value == this.validateForm.value.importantProject)
+  // }
+  constructor(
+    private fb: NonNullableFormBuilder,
+    private msg: NzMessageService
+  ) {}
+
+  ngOnInit() {}
+
+  changeMajor() {}
+  getMajor(e: any) {
+    console.log(e);
+  }
+  onChange(e: any) {
+    console.log(e);
+    console.log(this.validateForm);
+  }
+  handleChange(info: NzUploadChangeParam): void {
+    if (info.file.status !== 'uploading') {
+      console.log(info.file, info.fileList);
+    }
+    if (info.file.status === 'done') {
+      this.msg.success(`${info.file.name} file uploaded successfully`);
+    } else if (info.file.status === 'error') {
+      this.msg.error(`${info.file.name} file upload failed.`);
+    }
+  }
+
+  submitForm(event?: string): void {
+    console.log(this.validateForm.value);
+    if (this.validateForm.valid) {
+      console.log(this.validateForm.value);
+    } else {
+      Object.values(this.validateForm.controls).forEach((control) => {
+        if (control.invalid) {
+          control.markAsDirty();
+          control.updateValueAndValidity({ onlySelf: true });
+        }
+      });
+    }
+    if (event == 'next') {
+      this.next.emit();
+    }
+  }
+}

+ 5 - 0
projects/textbook/src/modules/nav-author/modules.routes.ts

@@ -5,6 +5,11 @@ import { PageTextbookComponent } from './page-textbook/page-textbook.component';
 import { ApplyComponent } from './apply/apply.component';
 import { ProfileComponent } from '../user/profile/profile.component';
 const routes: Routes = [
+  {
+    path: '',
+    redirectTo:'manage/apply',
+    pathMatch: "full",
+  },
   {
     path: 'manage',
     component: PageHomeComponent,

+ 16 - 0
projects/textbook/src/modules/nav-review/approve/approve.component.html

@@ -0,0 +1,16 @@
+<nz-page-header class="site-page-header" nzTitle="" nzSubtitle="">
+  <nz-breadcrumb nz-page-header-breadcrumb>
+    <nz-breadcrumb-item>报送流程</nz-breadcrumb-item>
+    <nz-breadcrumb-item>
+      <a>待审批材料列表</a>
+    </nz-breadcrumb-item>
+  </nz-breadcrumb>
+</nz-page-header>
+<comp-table-list
+  #list
+  [schema]="EduTextbook"
+  *ngIf="className && fieldsArray"
+  [className]="className"
+  [fieldsArray]="fieldsArray"
+  [queryParams]="queryParams"
+></comp-table-list>

+ 0 - 0
projects/textbook/src/modules/nav-review/approve/approve.component.scss


+ 24 - 0
projects/textbook/src/modules/nav-review/approve/approve.component.spec.ts

@@ -0,0 +1,24 @@
+import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
+import { IonicModule } from '@ionic/angular';
+
+import { ApproveComponent } from './approve.component';
+
+describe('ApproveComponent', () => {
+  let component: ApproveComponent;
+  let fixture: ComponentFixture<ApproveComponent>;
+
+  beforeEach(waitForAsync(() => {
+    TestBed.configureTestingModule({
+      declarations: [ ApproveComponent ],
+      imports: [IonicModule.forRoot()]
+    }).compileComponents();
+
+    fixture = TestBed.createComponent(ApproveComponent);
+    component = fixture.componentInstance;
+    fixture.detectChanges();
+  }));
+
+  it('should create', () => {
+    expect(component).toBeTruthy();
+  });
+});

+ 42 - 0
projects/textbook/src/modules/nav-review/approve/approve.component.ts

@@ -0,0 +1,42 @@
+import { Component, OnInit, ViewChild } from '@angular/core';
+import { RouterOutlet } from '@angular/router';
+import { CommonCompModule } from '../../../services/common.modules';
+import { CompTableListComponent } from '../../../app/comp-table/comp-table-list/comp-table-list.component';
+import { EduTextbook } from '../../../schemas/EduTextbook';
+import * as Parse from 'parse';
+import { CommonModule } from '@angular/common';
+
+@Component({
+  selector: 'app-approve',
+  imports: [
+    CommonCompModule,
+    CommonModule,
+    RouterOutlet,
+    CompTableListComponent,
+  ],
+  standalone: true,
+  templateUrl: './approve.component.html',
+  styleUrls: ['./approve.component.scss'],
+})
+export class ApproveComponent implements OnInit {
+  @ViewChild(CompTableListComponent) list: CompTableListComponent | undefined;
+
+  EduTextbook = EduTextbook;
+  user: Parse.User | undefined;
+  className: string | undefined;
+  queryParams: any | undefined;
+  fieldsArray: Array<any> | undefined;
+
+  constructor() {
+    this.user = Parse.User.current();
+    this.className = this.EduTextbook.className;
+    this.fieldsArray = this.EduTextbook.fieldsArray;
+    this.queryParams = {
+      where: {
+        isDeleted: { $ne: true },
+      },
+    };
+  }
+
+  ngOnInit() {}
+}

+ 19 - 9
projects/textbook/src/modules/nav-review/modules.routes.ts

@@ -1,17 +1,27 @@
-import { NgModule } from "@angular/core";
-import { RouterModule, Routes } from "@angular/router";
+import { NgModule } from '@angular/core';
+import { RouterModule, Routes } from '@angular/router';
 import { PageHomeComponent } from './page-home/page-home.component';
+import { ApproveComponent } from './approve/approve.component';
+import { ProfileComponent } from '../user/profile/profile.component';
 const routes: Routes = [
+  {
+    path: '',
+    redirectTo:'home/apply',
+    pathMatch: "full",
+  },
   {
     path: 'home',
     component: PageHomeComponent,
-    children:[
-      // {
-      //   path: "",
-      //   redirectTo: "pay",
-      //   pathMatch: "full",
-      // },
-    ]
+    children: [
+      {
+        path: 'apply', //创建教材
+        component: ApproveComponent,
+      },
+    ],
+  },
+  {
+    path: 'profile',
+    component: ProfileComponent,
   }
 ];
 @NgModule({

+ 2 - 2
projects/textbook/src/modules/nav-review/page-home/page-home.component.html

@@ -10,7 +10,7 @@
           <li
             nz-menu-item
             [nzSelected]="active == child.id"
-            (click)="toUrl('/nav-admin', child.id, { category: child.id })"
+            (click)="toUrl(child)"
           >
             {{ child.name }}
           </li>
@@ -20,7 +20,7 @@
       } @else {
       <li
         nz-menu-item
-        (click)="toUrl('/nav-admin', 'list')"
+        (click)="toUrl(item)"
         [nzSelected]="active == item.id"
       >
         <span nz-icon nzType="home" nzTheme="outline"></span>

+ 4 - 1
projects/textbook/src/modules/nav-review/page-home/page-home.component.scss

@@ -6,10 +6,13 @@
   .content-left{
     background-color:#fff;
   }
-  .content-rifht{
+  .preview{
     height: 100%;
     overflow-y: scroll;
     padding: 20px 0 40px 0;
     flex: 1;
   }
+  .proview{
+    flex: 1;
+  }
 }

+ 12 - 4
projects/textbook/src/modules/nav-review/page-home/page-home.component.ts

@@ -16,10 +16,12 @@ export class PageHomeComponent  implements OnInit {
     {
       name:'报送流程',
       id:'1',
+      path: '/nav-review/home/apply',
     },
     {
       name:'个人信息',
       id:'2',
+      path: '/nav-review/profile',
     },
   ]
   active:string = localStorage.getItem('active') || this.options[0].id
@@ -28,9 +30,15 @@ export class PageHomeComponent  implements OnInit {
   ) { }
 
   ngOnInit() {}
-  toUrl(url:string, cateid:string, params?:any){
-    this.active = cateid
-    localStorage.setItem('active', cateid)
-    // this.router.navigate([url, params ? params : {}])
+  toUrl(child: any){
+    let cateid = child.id;
+    this.active = cateid;
+    localStorage.setItem('active', cateid);
+    console.log(child);
+    if (child.params) {
+      this.router.navigate([child.path, child?.params]);
+    } else {
+      this.router.navigate([child.path]);
+    }
   }
 }

+ 5 - 1
projects/textbook/src/services/common.modules.ts

@@ -10,6 +10,8 @@ import { NzPageHeaderModule } from 'ng-zorro-antd/page-header';
 import { NzBreadCrumbModule } from 'ng-zorro-antd/breadcrumb';
 import { NzStepsModule } from 'ng-zorro-antd/steps';
 import { NzButtonModule } from 'ng-zorro-antd/button';
+import { NzInputModule } from 'ng-zorro-antd/input';
+import { NzDatePickerModule } from 'ng-zorro-antd/date-picker';
 @NgModule({
   exports: [
     FormsModule,
@@ -22,7 +24,9 @@ import { NzButtonModule } from 'ng-zorro-antd/button';
     NzPageHeaderModule,
     NzBreadCrumbModule,
     NzStepsModule,
-    NzButtonModule
+    NzButtonModule,
+    NzInputModule,
+    NzDatePickerModule
   ]
 })
 export class CommonCompModule { }

+ 34 - 0
projects/textbook/src/services/languages.map.ts

@@ -0,0 +1,34 @@
+export const languages = {
+  options:[
+    { lang: 'zh', name: '中文' },
+    { lang: 'en', name: '英语' },
+    { lang: 'es', name: '西班牙语' },
+    { lang: 'fr', name: '法语' },
+    { lang: 'de', name: '德语' },
+    { lang: 'ru', name: '俄语' },
+    { lang: 'ja', name: '日语' },
+    { lang: 'ko', name: '韩语' },
+    { lang: 'ar', name: '阿拉伯语' },
+    { lang: 'pt', name: '葡萄牙语' },
+    { lang: 'it', name: '意大利语' },
+    { lang: 'nl', name: '荷兰语' },
+    { lang: 'pl', name: '波兰语' },
+    { lang: 'sv', name: '瑞典语' },
+    { lang: 'da', name: '丹麦语' },
+    { lang: 'no', name: '挪威语' },
+    { lang: 'fi', name: '芬兰语' },
+    { lang: 'el', name: '希腊语' },
+    { lang: 'tr', name: '土耳其语' },
+    { lang: 'hu', name: '匈牙利语' },
+    { lang: 'cs', name: '捷克语' },
+    { lang: 'ro', name: '罗马尼亚语' },
+    { lang: 'sk', name: '斯洛伐克语' },
+    { lang: 'bg', name: '保加利亚语' },
+    { lang: 'hr', name: '克罗地亚语' },
+    { lang: 'sr', name: '塞尔维亚语' },
+    { lang: 'sl', name: '斯洛文尼亚语' },
+    { lang: 'et', name: '爱沙尼亚语' },
+    { lang: 'lv', name: '拉脱维亚语' },
+    { lang: 'lt', name: '立陶宛语' },
+  ]
+}