-
+
+
+
+
diff --git a/src/app/pages/license/file-category/edit-file-category/edit-file-category.component.ts b/src/app/pages/license/file-category/edit-file-category/edit-file-category.component.ts
index 825b327..8d590bb 100644
--- a/src/app/pages/license/file-category/edit-file-category/edit-file-category.component.ts
+++ b/src/app/pages/license/file-category/edit-file-category/edit-file-category.component.ts
@@ -4,6 +4,7 @@ import { FormBuilder, FormGroup, Validators } from '@angular/forms';
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';
@Component({
selector: 'app-edit-file-category',
templateUrl: './edit-file-category.component.html',
@@ -14,7 +15,7 @@ export class EditFileCategoryComponent implements OnInit {
@Input() data?: any;
validateForm!: FormGroup;
- constructor(private modal: NzModalRef, private fb: FormBuilder, private http: HttpClient, private objectsSrv: ObjectsSimpleService) { }
+ constructor(private modal: NzModalRef, private fb: FormBuilder, private http: HttpClient, private objectsSrv: ObjectsSimpleService,private message: NzMessageService) { }
data2
@@ -94,9 +95,21 @@ export class EditFileCategoryComponent implements OnInit {
}
+ //获取文件格式
+ getFileType(name: string):string {
+ let suffix
+ if (name.substring(name.length-4).includes('png') || name.substring(name.length-4).includes('jpg') || name.substring(name.length-4).includes('jpeg') || name.substring(name.length-4).includes('webp')) {
+ suffix = 'img'
+ } else if (name.substring(name.length-4).includes('doc') || name.substring(name.length-4).includes('docx')) {
+ suffix = 'word'
+ } else if (name.substring(name.length-4).includes('pdf')) {
+ suffix = 'pdf'
+ }
+ return suffix
+ }
+
//查看图片
viewImg(url) {
- // url.split('?')[0]
let dom = document.getElementById(`viewerjs`)
let pObjs = dom.childNodes;
let node = document.createElement("img")
@@ -115,4 +128,20 @@ export class EditFileCategoryComponent implements OnInit {
}, 0);
}
+ //查看文件
+ lookFile(item) {
+ if (!item.imageUrl) {
+ return
+ }
+ if (this.getFileType(item.imageUrl) == 'word') {
+ let arr = item.imageUrl.split('.')
+ arr[arr.length - 1] = 'pdf'
+ window.open(arr.join('.'))
+ } else if (this.getFileType(item.imageUrl) == 'pdf') {
+ window.open(item.imageUrl)
+ } else {
+ this.message.create('warning', '暂不支持查看!');
+ }
+ }
+
}
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 7edc66d..376fd49 100644
--- a/src/app/pages/license/file-category/file-category.component.html
+++ b/src/app/pages/license/file-category/file-category.component.html
@@ -8,7 +8,7 @@
证件名称
有效期类型 |
-
图片 |
+
附件 |
提交时间 |
审核状态 |
操作 |
@@ -25,11 +25,13 @@
有
-
+
+
+
|
{{item.committedTime | date:"yyyy/MM/dd"}}未提交审核 |
- {{item.auditStatus | auditStatus}}
+ {{item.auditLog.auditStatusDesc || ''}}
|
编辑
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 e841d20..e8a7828 100644
--- a/src/app/pages/license/file-category/file-category.component.ts
+++ b/src/app/pages/license/file-category/file-category.component.ts
@@ -41,6 +41,19 @@ export class FileCategoryComponent implements OnInit {
})
}
+ //获取文件格式
+ getFileType(name: string):string {
+ let suffix
+ if (name.substring(name.length-4).includes('png') || name.substring(name.length-4).includes('jpg') || name.substring(name.length-4).includes('jpeg') || name.substring(name.length-4).includes('webp')) {
+ suffix = 'img'
+ } else if (name.substring(name.length-4).includes('doc') || name.substring(name.length-4).includes('docx')) {
+ suffix = 'word'
+ } else if (name.substring(name.length-4).includes('pdf')) {
+ suffix = 'pdf'
+ }
+ return suffix
+ }
+
//查看图片
viewImg(url) {
let dom = document.getElementById(`viewerjs`)
@@ -61,6 +74,22 @@ export class FileCategoryComponent implements OnInit {
}, 0);
}
+ //查看文件
+ lookFile(item) {
+ if (!item.imageUrl) {
+ return
+ }
+ if (this.getFileType(item.imageUrl) == 'word') {
+ let arr = item.imageUrl.split('.')
+ arr[arr.length - 1] = 'pdf'
+ window.open(arr.join('.'))
+ } else if (this.getFileType(item.imageUrl) == 'pdf') {
+ window.open(item.imageUrl)
+ } else {
+ this.message.create('warning', '暂不支持查看!');
+ }
+ }
+
dispose() {
}
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 635d1ef..9dfca80 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
@@ -29,7 +29,7 @@
审核记录
- 审核次数:{{auditList.length}}
+ 审核次数:{{getVerifyNum()}}
驳回次数:{{getRejectNum()}}
@@ -38,8 +38,9 @@
- {{item.creationTime | date:"yyyy/MM/dd"}}
- {{item.auditStatus | auditStatus}}
+ {{item.creationTime | date:"yyyy/MM/dd"}}
+ {{item.auditStatus | auditStatus}}
+ 驳回说明:{{item.auditLog? item.auditLog.rejectReason : ''}}
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 399308e..18de9d9 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
@@ -34,6 +34,17 @@ export class DetailsUpdateCategoryComponent implements OnInit {
})
}
+ //获取审核次数
+ getVerifyNum(): number {
+ let num = 0
+ this.auditList.forEach(item=>{
+ if (item.auditStatus == 2 || item.auditStatus == 3) {
+ num = num + 1
+ }
+ })
+ return num
+ }
+
//获取驳回次数
getRejectNum(): number {
let num = 0
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 f4018d9..e3c3c23 100644
--- a/src/app/pages/license/update-category/update-category.component.html
+++ b/src/app/pages/license/update-category/update-category.component.html
@@ -27,12 +27,9 @@
{{item.licenseCode || ''}} |
{{item.isLongTerm ? '长期证照' : (item.validityEndTime | date:"yyyy/MM/dd")}} |
-
-
-
+
+
+
|
@@ -47,7 +44,7 @@
{{item.committedTime | date:"yyyy/MM/dd"}}未提交审核 |
- {{item.auditStatus | auditStatus}}
+ {{item.auditLog.auditStatusDesc || ''}}
|
无
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 5753622..4e36b4f 100644
--- a/src/app/pages/license/update-category/update-category.component.ts
+++ b/src/app/pages/license/update-category/update-category.component.ts
@@ -36,7 +36,6 @@ export class UpdateCategoryComponent implements OnInit {
let data = JSON.parse(sessionStorage.getItem('userdataOfgasstation'));
let params = { orgId: data.organization.id || "" }
this.http.get(`/api/services/app/StationValidityLicense/GetCurStationLicense`,{params}).subscribe((info: any)=>{
- this.tableSpin = false
this.list = info.result
this.tableSpin = false
console.log(info.result)
| | |