From 61984db82aaf9e756f4b068e49d277fd13628066 Mon Sep 17 00:00:00 2001
From: cpf <1105965053@qq.com>
Date: Thu, 12 May 2022 15:52:13 +0800
Subject: [PATCH] =?UTF-8?q?=E5=AE=8C=E5=96=84?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../audit-dispose.component.html | 4 +--
.../audit-dispose/audit-dispose.component.ts | 18 +++++++++++++
.../details-file-category.component.html | 2 +-
.../details-file-category.component.ts | 2 +-
.../edit-file-category.component.html | 4 +--
.../file-category.component.html | 4 +--
.../file-category/file-category.component.ts | 3 +++
.../details-update-category.component.html | 2 +-
.../details-update-category.component.ts | 20 +++++++++++++-
.../edit-update-category.component.html | 12 ++-------
.../edit-update-category.component.ts | 27 ++++++++++++++-----
.../update-category.component.html | 2 +-
.../update-category.component.ts | 26 ++++++++++++++----
13 files changed, 94 insertions(+), 32 deletions(-)
diff --git a/src/app/pages/audit/audit-ing/audit-dispose/audit-dispose.component.html b/src/app/pages/audit/audit-ing/audit-dispose/audit-dispose.component.html
index 14f841f..cdff8ed 100644
--- a/src/app/pages/audit/audit-ing/audit-dispose/audit-dispose.component.html
+++ b/src/app/pages/audit/audit-ing/audit-dispose/audit-dispose.component.html
@@ -18,14 +18,14 @@
证件名称: {{data.licenseTypeName}}
-
有效期类型: 有无不适用
+
有效期类型: 不适用无有
diff --git a/src/app/pages/license/file-category/details-file-category/details-file-category.component.ts b/src/app/pages/license/file-category/details-file-category/details-file-category.component.ts
index d6a6737..fe9d27d 100644
--- a/src/app/pages/license/file-category/details-file-category/details-file-category.component.ts
+++ b/src/app/pages/license/file-category/details-file-category/details-file-category.component.ts
@@ -22,7 +22,7 @@ export class DetailsFileCategoryComponent implements OnInit {
auditList: any[] = [];
//获取审核记录
getAuditLogging() {
- if (this.data.auditLogId == 0) {
+ if (!this.data.auditLogId) {
return
}
let params = { id: this.data.auditLogId }
diff --git a/src/app/pages/license/file-category/edit-file-category/edit-file-category.component.html b/src/app/pages/license/file-category/edit-file-category/edit-file-category.component.html
index 4d4386e..ea06c5b 100644
--- a/src/app/pages/license/file-category/edit-file-category/edit-file-category.component.html
+++ b/src/app/pages/license/file-category/edit-file-category/edit-file-category.component.html
@@ -15,9 +15,9 @@
-
+
-
+
diff --git a/src/app/pages/license/file-category/file-category.component.html b/src/app/pages/license/file-category/file-category.component.html
index 660c018..d5aa61f 100644
--- a/src/app/pages/license/file-category/file-category.component.html
+++ b/src/app/pages/license/file-category/file-category.component.html
@@ -20,9 +20,9 @@
{{item.licenseTypeName || ''}}
- 有
+ 不适用
无
- 不适用
+ 有
|
diff --git a/src/app/pages/license/file-category/file-category.component.ts b/src/app/pages/license/file-category/file-category.component.ts
index 4af5b3e..0374804 100644
--- a/src/app/pages/license/file-category/file-category.component.ts
+++ b/src/app/pages/license/file-category/file-category.component.ts
@@ -122,6 +122,9 @@ export class FileCategoryComponent implements OnInit {
//提交审核
submitReview(item){
+ if (!item.id) {
+ return
+ }
let params = { id: item.id }
this.http.post('/api/services/app/StationFileLicense/Commit', {},{params}).subscribe(data => {
this.message.create('success', '提交审核成功!');
diff --git a/src/app/pages/license/update-category/details-update-category/details-update-category.component.html b/src/app/pages/license/update-category/details-update-category/details-update-category.component.html
index f79a73b..3baf703 100644
--- a/src/app/pages/license/update-category/details-update-category/details-update-category.component.html
+++ b/src/app/pages/license/update-category/details-update-category/details-update-category.component.html
@@ -13,7 +13,7 @@
证件有效期: {{data.validityStartTime | date:"yyyy/MM/dd"}} - {{data.validityEndTime | date:"yyyy/MM/dd"}}
- 办理类型: {{data.handleType || ''}}
+ 办理类型: {{getHandleTypes(item.handleTypes)}}
有效期类型: {{data.validityDays || 0}}天
diff --git a/src/app/pages/license/update-category/details-update-category/details-update-category.component.ts b/src/app/pages/license/update-category/details-update-category/details-update-category.component.ts
index f908388..f3c57f2 100644
--- a/src/app/pages/license/update-category/details-update-category/details-update-category.component.ts
+++ b/src/app/pages/license/update-category/details-update-category/details-update-category.component.ts
@@ -5,6 +5,7 @@ import { HttpClient } from '@angular/common/http';
import { ObjectsSimpleService } from 'src/app/service/objectsSimple.service';
import Viewer from 'viewerjs';
import { NzMessageService } from 'ng-zorro-antd/message';
+import { handleType, handleTypeList } from '../edit-update-category/edit-update-category.component';
@Component({
selector: 'app-details-update-category',
@@ -23,7 +24,7 @@ export class DetailsUpdateCategoryComponent implements OnInit {
auditList: any[] = [];
//获取审核记录
getAuditLogging() {
- if (this.data.auditLogId == 0) {
+ if (!this.data.auditLogId) {
return
}
let params = { id: this.data.auditLogId }
@@ -48,6 +49,23 @@ export class DetailsUpdateCategoryComponent implements OnInit {
this.modal.destroy({ data: 'this the result data' });
}
+ //获取办理类型
+ getHandleTypes(handleTypes: any[]):string {
+ if (!handleTypes || !handleTypes.length) {
+ return
+ }
+ let name
+ let handleTypeList = JSON.parse(JSON.stringify(handleTypes));
+ let list: handleTypeList[] = new handleType().list;
+ handleTypeList.forEach(item=>{
+ list.find(element=>{
+ item == element.value? item = element.name : null
+ })
+ })
+ name = handleTypeList.join(',')
+ return name
+ }
+
//获取文件格式
getFileType(name: string):string {
let suffix
diff --git a/src/app/pages/license/update-category/edit-update-category/edit-update-category.component.html b/src/app/pages/license/update-category/edit-update-category/edit-update-category.component.html
index 1077ce0..2d3f7ad 100644
--- a/src/app/pages/license/update-category/edit-update-category/edit-update-category.component.html
+++ b/src/app/pages/license/update-category/edit-update-category/edit-update-category.component.html
@@ -38,16 +38,8 @@
-
-
-
-
-
-
-
-
-
-
+
+
diff --git a/src/app/pages/license/update-category/edit-update-category/edit-update-category.component.ts b/src/app/pages/license/update-category/edit-update-category/edit-update-category.component.ts
index 18c4222..d5091ac 100644
--- a/src/app/pages/license/update-category/edit-update-category/edit-update-category.component.ts
+++ b/src/app/pages/license/update-category/edit-update-category/edit-update-category.component.ts
@@ -18,11 +18,10 @@ export class EditUpdateCategoryComponent implements OnInit {
validateForm!: FormGroup;
constructor(private modal: NzModalRef, private fb: FormBuilder, private http: HttpClient, private objectsSrv: ObjectsSimpleService,private message: NzMessageService,) { }
-
+ handleTypeList: handleTypeList[] = new handleType().list;
data2: any; //深拷贝data
isLongTermTime: Date = null; // 限期 日期
isNoLongTermTime: Date[] = []; //长期 日期
- typeList: string[] = []; //办理类型 select多选 data
ngOnInit(): void {
this.validateForm = this.fb.group({
@@ -41,10 +40,6 @@ export class EditUpdateCategoryComponent implements OnInit {
this.isNoLongTermTime.push(new Date(this.data2.validityStartTime))
this.isNoLongTermTime.push(new Date(this.data2.validityEndTime))
}
- // 办理类型
- if (this.data2.handleType) {
- this.typeList = (this.data2.handleType).split('/')
- }
console.log(this.data2)
}
@@ -197,3 +192,23 @@ export class EditUpdateCategoryComponent implements OnInit {
}
}
+
+//办理类型
+export class handleType {
+ list: handleTypeList[] =[
+ { value: 0, name: "无" },
+ { value: 1, name: "年度公示" },
+ { value: 2, name: "年检" },
+ { value: 3, name: "到期换证" },
+ { value: 4, name: "年度执行报告" },
+ { value: 5, name: "到期检测" },
+ { value: 6, name: "年度复训" },
+ { value: 7, name: "年度检测" },
+ { value: 8, name: "到期备案" },
+ { value: 9, name: "到期评价" },
+ ]
+}
+export class handleTypeList {
+ value: number
+ name: string
+}
\ No newline at end of file
diff --git a/src/app/pages/license/update-category/update-category.component.html b/src/app/pages/license/update-category/update-category.component.html
index 618cab2..5a29bec 100644
--- a/src/app/pages/license/update-category/update-category.component.html
+++ b/src/app/pages/license/update-category/update-category.component.html
@@ -32,7 +32,7 @@
|
{{item.validityDays || 0}}天 |
-
{{item.handleType}} |
+
{{getHandleTypes(item.handleTypes)}} |
是否 |
{{item.committedTime | date:"yyyy/MM/dd"}}未提交审核 |
diff --git a/src/app/pages/license/update-category/update-category.component.ts b/src/app/pages/license/update-category/update-category.component.ts
index 1380759..8942581 100644
--- a/src/app/pages/license/update-category/update-category.component.ts
+++ b/src/app/pages/license/update-category/update-category.component.ts
@@ -3,7 +3,7 @@ import { NzModalService } from 'ng-zorro-antd/modal';
import { Observable, fromEvent } from 'rxjs';
import { debounceTime } from 'rxjs/operators';
import Viewer from 'viewerjs';
-import { EditUpdateCategoryComponent } from './edit-update-category/edit-update-category.component';
+import { EditUpdateCategoryComponent, handleType, handleTypeList } from './edit-update-category/edit-update-category.component';
import * as moment from 'moment';
import { NzMessageService } from 'ng-zorro-antd/message';
import { HttpClient } from '@angular/common/http';
@@ -40,6 +40,23 @@ export class UpdateCategoryComponent implements OnInit {
})
}
+ //获取办理类型
+ getHandleTypes(handleTypes: any[]):string {
+ if (!handleTypes || !handleTypes.length) {
+ return
+ }
+ let name
+ let handleTypeList = JSON.parse(JSON.stringify(handleTypes));
+ let list: handleTypeList[] = new handleType().list;
+ handleTypeList.forEach(item=>{
+ list.find(element=>{
+ item == element.value? item = element.name : null
+ })
+ })
+ name = handleTypeList.join(',')
+ return name
+ }
+
//获取文件格式
getFileType(name: string):string {
let suffix
@@ -121,10 +138,6 @@ export class UpdateCategoryComponent implements OnInit {
body.validityStartTime = instance.isNoLongTermTime[0] || new Date()
body.validityEndTime = instance.isNoLongTermTime[1] || new Date()
}
- // 办理类型
- if (instance.typeList.length) {
- body.handleType = instance.typeList.join("/")
- }
this.http.post('/api/services/app/StationValidityLicense/Create', body).subscribe(data => {
resolve(data);
this.getStationList();
@@ -169,6 +182,9 @@ export class UpdateCategoryComponent implements OnInit {
//提交审核
submitReview(item){
+ if (!item.id) {
+ return
+ }
let params = { id: item.id }
this.http.post('/api/services/app/StationValidityLicense/Commit', {},{params}).subscribe(data => {
this.message.create('success', '提交审核成功!');
|