对接手机端

This commit is contained in:
范强强
2023-06-08 11:40:41 +08:00
parent 6c21adeb04
commit 94adfa0b1a
2 changed files with 34 additions and 19 deletions
+5 -3
View File
@@ -1,9 +1,11 @@
import { Base64 } from 'js-base64' import { Base64 } from 'js-base64'
import { Toast } from 'vant' import { Toast } from 'vant'
window._CONFIG['domianPreviewURL'] = 'http://localhost:8082/jero-boot' window._CONFIG['domianPreviewURL'] = 'http://localhost:8082/jero-boot'
window._CONFIG['domianWebImgURL'] = 'http://localhost:8082/jero-boot' window._CONFIG['domianWebImgURL'] = 'http://localhost:8082/jero-boot'
let downLoadFileUrl = window._CONFIG['domianPreviewURL'] + '/sys/common/download' let downLoadFileUrl = window._CONFIG['domianPreviewURL'] + '/sys/common/download'
let downLoadImgUrl = window._CONFIG['domianWebImgURL'] + '/sys/common/download' let downLoadImgUrl = window._CONFIG['domianWebImgURL'] + '/sys/common/download'
export function kkFileView(fileName, fileId) { export function kkFileView(fileName, fileId) {
let index1 = fileName.lastIndexOf('.') let index1 = fileName.lastIndexOf('.')
let index2 = fileName.length let index2 = fileName.length
@@ -11,11 +13,11 @@ export function kkFileView(fileName, fileId) {
window._CONFIG['onlinePreviewDomainURL'] = 'http://localhost:8012/onlinePreview' window._CONFIG['onlinePreviewDomainURL'] = 'http://localhost:8012/onlinePreview'
if (fileSuffix == '.docx' || fileSuffix == '.doc' || fileSuffix == '.pdf' || fileSuffix == '.xlsx' || fileSuffix == '.xls') { if (fileSuffix == '.docx' || fileSuffix == '.doc' || fileSuffix == '.pdf' || fileSuffix == '.xlsx' || fileSuffix == '.xls') {
let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(downLoadFileUrl + '/' + fileId + fileSuffix) let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(downLoadFileUrl + '/' + fileId + fileSuffix)
window.open(url, '_blank') window.open(url)
} else if (fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { } else if (fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') {
let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(downLoadImgUrl + '/' + fileId + fileSuffix) let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(downLoadImgUrl + '/' + fileId + fileSuffix)
window.open(url, '_blank') window.open(url)
}else { } else {
Toast('当前格式不支持预览') Toast('当前格式不支持预览')
} }
} }
+29 -16
View File
@@ -17,7 +17,7 @@
{{$t('regulationListIssuance')}} {{$t('regulationListIssuance')}}
</div> </div>
<div class="content-box-data-num"> <div class="content-box-data-num">
24 {{publishingCount}}
</div> </div>
</div> </div>
<div class="content-box-data" @click="processClick(2)"> <div class="content-box-data" @click="processClick(2)">
@@ -25,7 +25,7 @@
{{$t('designTheComplianceProcess')}} {{$t('designTheComplianceProcess')}}
</div> </div>
<div class="content-box-data-num"> <div class="content-box-data-num">
24 {{designCount}}
</div> </div>
</div> </div>
<div class="content-box-data" @click="processClick(4)"> <div class="content-box-data" @click="processClick(4)">
@@ -33,7 +33,7 @@
{{$t('verifyComplianceProcess')}} {{$t('verifyComplianceProcess')}}
</div> </div>
<div class="content-box-data-num"> <div class="content-box-data-num">
24 {{verifyCount}}
</div> </div>
</div> </div>
<div class="content-box-data" @click="processClick(21)"> <div class="content-box-data" @click="processClick(21)">
@@ -41,7 +41,7 @@
{{$t('thePreHomeProcess')}} {{$t('thePreHomeProcess')}}
</div> </div>
<div class="content-box-data-num"> <div class="content-box-data-num">
24 {{preHomoCount}}
</div> </div>
</div> </div>
<div class="content-box-data" @click="regulationListIssuanceClick"> <div class="content-box-data" @click="regulationListIssuanceClick">
@@ -49,7 +49,7 @@
{{$t('technicalAssessmentOfRegulations')}} {{$t('technicalAssessmentOfRegulations')}}
</div> </div>
<div class="content-box-data-num"> <div class="content-box-data-num">
24 {{technologyEvaluationCount}}
</div> </div>
</div> </div>
<div class="content-box-data" @click="regulationListIssuanceClick"> <div class="content-box-data" @click="regulationListIssuanceClick">
@@ -57,7 +57,7 @@
{{$t('legalOpinionCollection')}} {{$t('legalOpinionCollection')}}
</div> </div>
<div class="content-box-data-num"> <div class="content-box-data-num">
24 {{opinionCollectionCount}}
</div> </div>
</div> </div>
</div> </div>
@@ -159,11 +159,18 @@
pageSize: 10, pageSize: 10,
loading: false, loading: false,
finished: false, finished: false,
dataSource: [] dataSource: [],
publishingCount: 0,
preHomoCount: 0,
designCount: 0,
verifyCount: 0,
technologyEvaluationCount: 0,
opinionCollectionCount: 0
} }
}, },
mounted() { mounted() {
document.title = 'NIO GRP' document.title = 'NIO GRP'
this.getProcessDataCount()
}, },
methods: { methods: {
onChange(value) { onChange(value) {
@@ -195,23 +202,29 @@
} }
}) })
}, },
getToDoProcess() { getProcessDataCount() {
let query = { getAction('/phone/taskStatistics/getRegulatoryCertificationProcessDataCount', {}).then((res) => {
pageNo: this.toDoProcessPageNo,
pageSize: this.toDoProcessPageSize
}
getAction('/todoCenter/projectProcess/todoTaskList', query).then((res) => {
if (res.success) { if (res.success) {
this.toDoProcessList = res.result.records this.publishingCount = res.result.publishingCount || 0
this.preHomoCount = res.result.preHomoCount || 0
this.designCount = res.result.designCount || 0
this.verifyCount = res.result.verifyCount || 0
this.technologyEvaluationCount = res.result.technologyEvaluationCount || 0
this.opinionCollectionCount = res.result.opinionCollectionCount || 0
} else { } else {
this.toDoProcessList = [] this.publishingCount = 0
this.preHomoCount = 0
this.designCount = 0
this.verifyCount = 0
this.technologyEvaluationCount = 0
this.opinionCollectionCount = 0
} }
}) })
}, },
activeChange() { activeChange() {
if (this.activeTab == 'regulatoryCertification') { if (this.activeTab == 'regulatoryCertification') {
this.getProcessDataCount()
} else if (this.activeTab == 'parametercollection') { } else if (this.activeTab == 'parametercollection') {
this.loading = true this.loading = true
this.dataSource = [] this.dataSource = []