法规技术评估布局

This commit is contained in:
qq787203167
2022-07-11 11:02:48 +08:00
parent 963365cbdc
commit 8868cf0829
6 changed files with 806 additions and 0 deletions
+1
View File
@@ -1106,4 +1106,5 @@ module.exports = {
PreHomoNotification:'Pre-Homo Notification',
ValidationComplianceNotification:'Validation Compliance Notification',
RegulationTaskConfirmationNotification:'Regulation Task Confirmation Notification',
evaluationMethod:'Evaluation method',
}
+1
View File
@@ -1110,4 +1110,5 @@ module.exports = {
PreHomoNotification:'Pre-Homo通知',
ValidationComplianceNotification:'验证符合性通知',
RegulationTaskConfirmationNotification:'任务确认通知',
evaluationMethod:'评估方式',
}
@@ -97,6 +97,7 @@
this.$route.path == '/handshakeProcess' ||
this.$route.path == '/projectStatusAndProgress' ||
this.$route.path == '/TaskPlanList' ||
this.$route.path == '/evaluationInitiationProcess' ||
this.$route.path == '/historicalVersion' ||
this.$route.path == '/dashboard/analysis' ||
this.$route.path == '/processDetails') {
+5
View File
@@ -342,6 +342,11 @@ export const constantRouterMap = [
name: 'initiatingProcess',
component: () => import(/* webpackChunkName: "user" */ '@/views/businessSupport/collectionOfRegulatoryOpinions/components/initiatingProcess')
},
{
path: '/evaluationInitiationProcess',
name: 'evaluationInitiationProcess',
component: () => import(/* webpackChunkName: "user" */ '@/views/businessSupport/technologyAssessment/components/initiatingProcess')
},
// {
// path: '/ParameterItemCollection',
// name: 'ParameterItemCollection',
@@ -0,0 +1,447 @@
<template>
<div id="examineBox">
<headerProcess
:title="title"
/>
<div class="detail-box">
<div class="detail-content" style="padding: 20px">
<div class="table-page-search-wrapper">
<search ref="searchRef"
:flag="'1'"
:url="url"/>
</div>
<a-table
ref="table"
size="middle"
:loading="loading"
:pagination="false"
:scroll="{x: '100%'}"
rowKey="id"
:data-source="dataSource"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange ,columnTitle:' '}"
:columns="columns"
>
</a-table>
<div class="page" v-if="dataSource && dataSource.length > 0">
<a-pagination
:show-total="total => $t('total')+` ${total} `+$t('strip')"
show-quick-jumper
:page-size.sync="pageSize"
:total="total"
:current="pageNo"
@change="pageOnChange"
@showSizeChange="SizeChange"
/>
</div>
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('closingDate')">{{$t('closingDate')}}</span>
</div>
<a-form-model-item class="itemModel" prop="endTime">
<a-date-picker class="box-input"
:placeholder="$t('PleaseSelect')+$t('closingDate')"
@change="dateChange('endTime')"
:getCalendarContainer="(trigger) => trigger.parentNode"
format="YYYY-MM-DD"
v-model="formInline['endTime']"
style="width: 100%"/>
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('Assessor')">{{$t('Assessor')}}</span>
</div>
<a-form-model-item class="itemModel" prop="evaluatorIdsName">
<PersonnelSelection class="box-input"
:personneQuery="formInline"
:query="{db_field_name:'evaluatorIds',db_field_txt:$t('Assessor')}"
:isInput="true"
@change="PersonnelSelectionChange"
v-model="formInline.evaluatorIdsName"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
<a-row :gutter="24">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('taskDescription')">{{$t('taskDescription')}}</span>
</div>
<a-form-model-item class="itemModel" prop="taskExplain">
<a-textarea :placeholder="$t('pleaseEnter')+$t('taskDescription')"
v-model="formInline.taskExplain"
:rows="4"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
<a-row :gutter="24">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('enclosure')">{{$t('enclosure')}}</span>
</div>
<a-form-model-item class="itemModel" prop="accessory_id">
<a-button type="primary" class="button-text"
@click="clickButtonToUpload('accessory_id')">
{{ (formInline.accessory_id === 'null' || formInline.accessory_id === '' ||
formInline.accessory_id == null) ? $t('clickUpload') : $t('viewUploadedFiles')
}}
</a-button>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
<footerProcess
@submit="submit"
:isSubmit="true"
/>
</div>
</div>
<JLoading :loading="JLoading">{{this.$t('pleaseWaitWhileRunning')}}</JLoading>
<uploadFile ref="uploadFile" @uploadSuccess="uploadSuccess"/>
</div>
</template>
<script>
import headerProcess from '../../../processCenter/components/headerProcess'
import search from '@/components/search/index'
import uploadFile from '@/components/uploadFile/file'
import PersonnelSelection from '@/components/PersonnelSelection/index'
import footerProcess from '../../../processCenter/components/footerProcess'
import { getAction, postAction } from '@/api/manage'
import moment from 'moment'
import eventBUs from '../../../../common/event'
import { mapGetters } from 'vuex'
export default {
name: 'evaluationInitiationProcess',
components: {
headerProcess,
search,
uploadFile,
footerProcess,
PersonnelSelection
},
data() {
return {
title: this.$t('regulatoryEngineer') + this.$t('initiatingProcess'),
//url传参严格按照当前命名
url: {
seachList: 'document/bussDocumentLibraryEO/queryCondition', //搜索字段
addModelList: '/dummy/dummyInventoryInfoEO/queryPageDummy'
},
loading: false,
JLoading:false,
dataSource: [],
selectedRowKeys: [],
total: 0,
pageSize: 10,
pageNo: 1,
formInline: {},
rules: {
endTime: [
{
required: true,
message: this.$t('closingDate') + this.$t('cannotEmpty'),
trigger: 'change'
}
],
evaluatorIdsName: [
{
required: true,
message: this.$t('Assessor') + this.$t('cannotEmpty'),
trigger: 'change'
}
]
},
searchParmes: {},
selectedRowKeysRecord: [],
columns: [
{
title: this.$t('standard'),
align: 'center',
dataIndex: 'serial_number',
width: 170,
scopedSlots: { customRender: 'serial_number' }
},
{
title: this.$t('title'),
align: 'center',
dataIndex: 'title',
width: 170,
scopedSlots: { customRender: 'titleName' }
},
{
title: this.$t('status'),
align: 'center',
width: 140,
ellipsis: true,
dataIndex: 'state'
},
{
title: this.$t('zoneOfApplication'),
align: 'center',
width: 170,
ellipsis: true,
dataIndex: 'region'
},
{
title: this.$t('technicalField'),
align: 'center',
ellipsis: true,
width: 170,
dataIndex: 'technology_territory'
},
{
title: this.$t('correspondingStandard'),
align: 'center',
ellipsis: true,
width: 170,
dataIndex: 'corresponding_standard'
}
]
}
},
mounted() {
document.title = this.$t('regulatoryEngineer') + this.$t('initiatingProcess')
this.getList()
eventBUs.$on('searchQuery', search => {
Object.keys(search).forEach(res => {
if (search[res] instanceof Array) {
search[res] = search[res].join(',')
}
})
this.pageNo = 1
this.searchParmes = search
this.getList()
})
},
methods: {
...mapGetters(['userInfo']),
pageOnChange(page) {
this.pageNo = page
this.getList()
},
SizeChange(pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.getList()
},
getList() {
let query = {
pageNo: this.pageNo,
pageSize: this.pageSize,
...this.searchParmes
}
this.loading = true
postAction(this.url.addModelList, query).then((res) => {
if (res.success) {
this.dataSource = res.result.records || []
this.total = res.result.total
this.loading = false
} else {
this.dataSource = []
this.total = 0
this.loading = false
}
})
},
onSelectChange(value, record) {
this.selectedRowKeys = value
if (this.selectedRowKeys.length > 1) {
this.selectedRowKeys.shift()
record.shift()
}
this.selectedRowKeysRecord = record
},
clickButtonToUpload(item) {
this.$refs.uploadFile.perentHandleFunc()
this.$refs.uploadFile.visible = true
this.uploadName = item
getAction('sys/common/getFileInfos', { id: this.formInline[item] }).then((res) => {
if (res.success) {
this.$refs.uploadFile.perentHandleFunc(res.result)
} else {
this.$refs.uploadFile.perentHandleFunc()
}
})
},
/** 上传文件的回调 */
uploadSuccess(data) {
let attIdList = []
if (data && data.length > 0) {
data.map(item => {
attIdList.push(item.id || data.name)
})
}
/** 赋值给当前对应的表单文件 */
this.formInline[this.uploadName] = attIdList.join(',')
this.formInline = { ...this.formInline }
},
PersonnelSelectionChange(value, id) {
this.formInline[value] = id
this.formInline = { ...this.formInline }
},
dateChange(item) {
this.formInline[item] = this.formInline[item] ? moment(this.formInline[item]).format('YYYY-MM-DD') : ''
},
getUUID(){
var str=[];
var Chars='0123456789abcdefghijklmnopqrstuvwxyz';
for(var i=0;i<36;i++){
str[i]=Chars.substr(Math.floor(Math.random()*16),1)
}
str[0]=str[8]=str[13]=str[18]=str[23]='-';
return str.join("")
},
submit() {
this.$refs.ruleForm.validate(valid => {
if (valid) {
if (this.selectedRowKeysRecord && this.selectedRowKeysRecord.length == 0) {
this.$message.warning(this.$t('pleaseSelectStandard'))
} else {
this.JLoading = true
let value = Object.assign(this.formInline, this.selectedRowKeysRecord[0])
value.standId = value.id
value.taskAffirmDueDate = value.endTime
delete value.id
value.id = this.getUUID()
value.currentUserName = this.userInfo().username
Object.keys(value).forEach(res => {
if (value[res] && value[res] instanceof String) {
value[res] = value[res].replace(/\"/g, '“')
value[res] = value[res].replace(/\'/g, '')
}
})
this.startProcess(value)
}
}
})
},
startProcess(value) {
let query = {
type: 5,
msg: JSON.stringify(value).replace(/\"/g, '\'')
}
postAction('/workFlow/startProcess', query).then((res) => {
if (res.success) {
this.completeTask(value, res.result)
}else{
this.JLoading = false
}
})
},
completeTask(value, taskId) {
let query = {
userid: this.userInfo().id,
taskId: taskId,
json: JSON.stringify(value).replace(/\"/g, '\'')
}
postAction('/workFlow/completeTask', query).then((res) => {
if (res.success) {
// setTimeout(() => {
// window.close()
// }, 1000)
this.$message.success(this.$t('OperationSuccessful'))
this.JLoading = false
this.$router.push({
path: '/collectionOfRegulatoryOpinions'
})
} else {
this.JLoading = false
this.$message.warning(this.$t('operationFailed'))
}
})
}
}
}
</script>
<style scoped>
.detail-box {
padding: 67px 0 0 0;
background: #ffffff;
height: 100%;
overflow: auto;
}
#examineBox {
display: flex;
flex-direction: column;
background: #fff;
position: relative;
height: 100%;
overflow-y: auto;
}
.box-title-text {
line-height: 1.4;
display: flex;
/*align-items: center;*/
}
.title-text {
width: 88px;
text-align: right;
display: inline-block;
font-weight: 500;
font-size: 14px;
margin-right: 16px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
height: 42px;
line-height: 48px;
color: #000F16;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 130px);
display: inline-block;
margin-top: 2px;
margin-bottom: 12px;
}
.Required {
color: red;
margin-right: 4px;
}
.title-text-text {
margin-top: 9px;
}
.formAdd {
margin-top: 20px;
}
.button-text {
height: 38px;
width: calc(100% - 100px);
line-height: 38px;
background: #fff;
border: 1px #00B3BE solid;
color: #00B3BE;
}
.page {
text-align: right;
margin-top: 20px;
}
</style>
@@ -0,0 +1,351 @@
<template>
<a-card :bordered="false">
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :md="6" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('standard')">
<span>{{$t('standard')}}</span>
</div>
<j-input class="box-input" :placeholder="$t('PleaseEnter')+$t('standard')"
v-model="queryParam.serialNumber"></j-input>
</div>
</a-col>
<a-col :md="6" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('title')">
<span>{{$t('title')}}</span>
</div>
<j-input class="box-input" :placeholder="$t('PleaseEnter')+$t('title')"
v-model="queryParam.title"></j-input>
</div>
</a-col>
<a-col :md="6" :sm="8">
<div class="box-title-text tree-select">
<div class="title-text" :title="$t('technicalField')">
<span>{{$t('technicalField')}}</span>
</div>
<a-tree-select
tree-node-filter-prop="title"
v-model="queryParam.technologyTerritory"
:maxTagCount="1"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
class="box-input"
style="width: 100%"
:tree-data="CategoryTreeList"
tree-checkable
:placeholder="$t('PleaseSelect')+$t('technicalField')"
/>
</div>
</a-col>
<template v-if="toggleSearchStatus">
<a-col :md="6" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('ProcessStatus')">
<span>{{$t('ProcessStatus')}}</span>
</div>
<a-select :placeholder="$t('PleaseSelect')+$t('ProcessStatus')"
class="box-input"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
allowClear
v-model="queryParam.gatherResult">
<a-select-option v-for="(item, key) in gatherResultList"
:key="key"
:value="item.value">
<span style="display: inline-block;width: 100%" :title=" item.name">
{{ item.name }}
</span>
</a-select-option>
</a-select>
</div>
</a-col>
</template>
<span style="float: right;overflow: hidden;margin-right: 11px" class="table-page-search-submitButtons">
<a-col :md="6" :sm="24">
<a-button class="box-button" type="primary" @click="searchQuery">{{$t('query')}}</a-button>
<a-button class="box-button" style="margin-left: 8px" @click="searchReset">{{$t('reset')}}</a-button>
<a @click="handleToggleSearch" style="margin-left: 8px">
{{ !toggleSearchStatus ? $t('open') : $t('away') }}
<a-icon :type="toggleSearchStatus ? 'up' : 'down'"/>
</a>
</a-col>
</span>
</a-row>
</a-form>
</div>
<div class="table-operator">
<div @click="initiatingProcessClick" class="operator-text">
<a-icon type="apartment"/>
{{$t('initiatingProcess')}}
</div>
</div>
<div>
<a-table
ref="table"
size="middle"
:loading="loading"
:pagination="false"
:scroll="{x: '100%'}"
rowKey="id"
:data-source="dataSource"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
:columns="columns"
>
<span slot="operation" slot-scope="text,record">
<a class="text-operation" @click="viewProcessClick(record)">{{$t('viewProcess')}}</a>
<a class="text-operation" v-if="record.gatherResult == 'Completed'"
@click="evaluationResultsClick(record)">{{$t('evaluationResults')}}</a>
</span>
</a-table>
<div class="page" v-if="dataSource && dataSource.length > 0">
<a-pagination
:show-total="total => $t('total')+` ${total} `+$t('strip')"
show-quick-jumper
show-size-changer
:page-size.sync="pageSize"
:total="total"
:current="pageNo"
@change="pageOnChange"
@showSizeChange="SizeChange"
/>
</div>
</div>
</a-card>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
export default {
name: 'index',
data() {
return {
//url传参严格按照当前命名
url: {
list: '',
getSysCategoryTree: '/sys/category/getSysCategoryTree'
},
loading: false,
toggleSearchStatus: false,
dataSource: [],
selectedRowKeys: [],
total: 0,
pageSize: 10,
pageNo: 1,
CategoryTreeList: [],
queryParam: {},
gatherResultList: [
{
value: 'Underway',
name: this.$t('inProgress')
},
{
value: 'Completed',
name: this.$t('Finished')
}
],
columns: [
{
title: this.$t('standard'),
align: 'center',
dataIndex: 'serialNumber',
width: 170
},
{
title: this.$t('title'),
align: 'center',
dataIndex: 'title',
width: 170
},
{
title: this.$t('technicalField'),
align: 'center',
width: 170,
ellipsis: true,
dataIndex: 'technologyTerritory'
},
{
title: this.$t('evaluationMethod'),
align: 'center',
width: 170,
ellipsis: true,
dataIndex: 'evaluationMethod'
},
{
title: this.$t('ProcessStatus'),
align: 'center',
width: 170,
ellipsis: true,
dataIndex: 'ProcessStatus'
},
{
title: this.$t('dateOfInitiation'),
align: 'center',
ellipsis: true,
width: 170,
dataIndex: 'startTime'
},
{
title: this.$t('closingDate'),
align: 'center',
ellipsis: true,
width: 170,
dataIndex: 'endTime'
},
{
title: this.$t('remarks'),
align: 'center',
ellipsis: true,
width: 170,
dataIndex: 'remarks'
},
{
title: this.$t('operation'),
align: 'center',
fixed: 'right',
width: 260,
scopedSlots: { customRender: 'operation' }
}
]
}
},
mounted() {
this.getList()
this.getSysCategoryTree()
},
methods: {
getSysCategoryTree() {
getAction(this.url.getSysCategoryTree, {}).then((res) => {
if (res.success) {
this.CategoryTreeList = res.result
} else {
this.CategoryTreeList = []
}
})
},
handleToggleSearch() {
this.toggleSearchStatus = !this.toggleSearchStatus
},
searchQuery() {
this.pageNo = 1
this.getList()
},
searchReset() {
this.queryParam = {}
this.pageNo = 1
this.getList()
},
pageOnChange(page) {
this.pageNo = page
this.getList()
},
SizeChange(pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.getList()
},
getList() {
let queryParam = JSON.parse(JSON.stringify(this.queryParam))
Object.keys(queryParam).forEach(val => {
if (queryParam[val] instanceof Array) {
queryParam[val] = queryParam[val].join(',')
}
})
let query = {
pageNo: this.pageNo,
pageSize: this.pageSize,
...queryParam
}
this.loading = true
getAction(this.url.list, query).then((res) => {
if (res.success) {
this.dataSource = res.result.records || []
this.total = res.result.total
this.loading = false
} else {
this.loading = false
}
})
},
onSelectChange(value) {
this.selectedRowKeys = value
},
initiatingProcessClick() {
let newUrl = this.$router.resolve({
path: '/evaluationInitiationProcess'
})
// let newUrl = this.$router.resolve({
// path: '/regulatoryProcessReview'
// })
window.open(newUrl.href, '_blank')
},
viewProcessClick(row) {
let newUrl = this.$router.resolve({
path: '/processDetails',
query: {
prcNum: row.prcNum,
prcType: 6,
prcId: row.actiProcInstId
}
})
window.open(newUrl.href, '_blank')
},
evaluationResultsClick(row) {
this.$refs.evaluationResultsListRef.getData(JSON.parse(JSON.stringify(row)))
}
}
}
</script>
<style>
.tree-select .ant-select-tree-dropdown {
height: 298px !important;
}
</style>
<style scoped>
@import '~@assets/less/common.less';
.page {
text-align: right;
margin-top: 20px;
}
.box-title-text {
line-height: 1.4;
display: flex;
align-items: center;
margin-bottom: 10px;
}
.title-text {
width: 20%;
min-width: 110px;
color: #000F16;
display: inline-block;
font-weight: 500;
font-size: 14px;
margin-right: 16px;
margin-top: 3px;
text-align: right;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.box-input {
display: inline-block;
width: 70%;
height: 38px;
margin-top: 2px;
}
.box-button {
height: 38px;
/*margin-top: 2px;*/
}
.text-operation {
margin-right: 8px;
}
</style>