平台件项目库布局

This commit is contained in:
zyx.net
2023-09-12 17:03:16 +08:00
parent 57be98c5e1
commit 9f4600a74c
56 changed files with 28915 additions and 0 deletions
+3
View File
@@ -1969,4 +1969,7 @@ module.exports = {
Listcreationtime:'List creation time',
Chinesecharacters:'The role code cannot enter Chinese characters',
alreadyexistssystem:'The role encoding already exists',
maximum:'A maximum of 20 nodes can be added',
Nodename:'Node Name',
Nodedate:'Node Time',
}
+3
View File
@@ -3925,4 +3925,7 @@ module.exports = {
Fileupload:'文件上传',
Addresslink:'地址链接',
Problemanagement:'问题管理',
maximum:'最多添加20个节点',
Nodename:'节点名称',
Nodedate:'节点时间',
}
+5
View File
@@ -338,6 +338,11 @@ export const constantRouterMap = [
name: 'certificationListMaintenance',
component: () => import(/* webpackChunkName: "user" */ '@/views/virtualAuthenticationList/virtualAuthenticationListDesign/certificationListMaintenance')
},
{
path: '/platformItemLibraryDetails',
name: 'platformItemLibraryDetails',
component: () => import(/* webpackChunkName: "user" */ '@/views/projectManagement/platformItemLibraryDetails/index')
},
{
path: '/ProjectDetails',
name: 'ProjectDetails',
@@ -0,0 +1,470 @@
<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('entryName')">
<span>{{$t('entryName')}}</span>
</div>
<a-input class="box-input" :placeholder="$t('PleaseEnter')+$t('entryName')"
v-model="queryParam.projectName"></a-input>
</div>
</a-col>
<a-col :md="6" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('brand')">
<span>{{$t('brand')}}</span>
</div>
<j-dict-select-tag class="box-input" v-model="queryParam.targetMarket"
:placeholder="$t('PleaseSelect')+$t('brand')"
:type="'select'"
:triggerChange="false" :dictCode="'brand'"/>
</div>
</a-col>
<a-col :md="6" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('configurationItem')">
<span>{{$t('configurationItem')}}</span>
</div>
<a-input class="box-input" :placeholder="$t('PleaseEnter')+$t('configurationItem')"
v-model="queryParam.configurationItem"></a-input>
</div>
</a-col>
<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" style="margin-left: 8px" @click="searchReset">{{$t('reset')}}</a-button>
<a-button class="box-button" style="margin-left: 8px" type="primary" @click="searchQuery">{{$t('query')}}</a-button>
</a-col>
</span>
</a-row>
</a-form>
</div>
<div class="table-operator">
<div @click="handleAdd" class="operator-text" v-has="'projectLibraryBase:add'">
<a-icon type="plus"/>
{{$t('newlyAdded')}}
</div>
<!-- <div @click="handleDel" class="operator-text" v-has="'projectLibraryBase:deleteBatch'">-->
<!-- <a-icon type="delete"/>-->
<!-- {{$t('BatchDelete')}}-->
<!-- </div>-->
</div>
<div>
<a-table
ref="table"
size="middle"
:components="drag(columns,'columns')"
:loading="loading"
:pagination="false"
:scroll="{x: '100%'}"
rowKey="id"
@change="tableOnChange"
:data-source="dataSource"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
:columns="columns"
>
<span slot="projectName" slot-scope="text,record">
<a @click="entryNameClick(record)" :title="text">{{text}}</a>
</span>
<span slot="operation" slot-scope="text,record">
<!-- <a class="text-operation" @click="edit(record)">{{$t('edit')}}</a>-->
<a class="text-operation"
@click="toppingClick(record)">
{{record.flag == '1'?$t('cancelTopping'):$t('Topping')}}
</a>
<a class="text-operation"
v-has="'projectLibraryBase:delete'"
v-if="record.createBy == userInfoQuery.username || record.studioEngineerName == userInfoQuery.username || administrators"
@click="deleteLib(record)">{{$t('deleteLib')}}</a>
<!-- <a class="text-operation" @click="entryNameClick(record)">{{$t('see')}}</a>-->
</span>
</a-table>
</div>
<div class="page">
<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>
<addModel :url="url" ref="addModelRef" @addModelList="addModelList"/>
</a-card>
</template>
<script>
import { getAction, postAction, downloadFile, deleteAction } from '@/api/manage'
import addModel from '../platformItemLibraryDetails/components/addModel'
import PersonnelSelection from '@/components/PersonnelSelection/index'
import { mapGetters } from 'vuex'
import { ResizeHeader, ResizeColumnProvide } from '@/mixins/header'
export default {
name: 'index',
components: {
addModel,
PersonnelSelection,
},
mixins:[ResizeHeader, ResizeColumnProvide],
data() {
return {
loading: false,
toggleSearchStatus: false,
selectedRowKeys: [],
formInline: {},
rules: {},
visible: false,
isPersonnelSelection:true,
dataSource: [],
confirmLoading: false,
url: {
list: 'project/projectLibraryBase/page',
add: 'project/projectLibraryBase/add',
edit: 'project/projectLibraryBase/edit',
deleteBatch: 'project/projectLibraryBase/delete',
deleteAll: 'project/projectLibraryBase/deleteBatch'
},
total: 0,
pageSize: 10,
pageNo: 1,
title: '新增',
columns: [
{
title: this.$t('entryName'),
align: 'left',
dataIndex: 'projectName',
width: 300,
sorter:true,
ellipsis: true,
scopedSlots: { customRender: 'projectName' }
},
{
title: this.$t('regulatoryEngineer'),
align: 'left',
width: 120,
sorter:true,
ellipsis: true,
dataIndex: 'studioEngineerName'
},
{
title: this.$t('brand'),
align: 'left',
width: 120,
sorter:true,
ellipsis: true,
dataIndex: 'brandText'
},
{
title: this.$t('configurationItem'),
align: 'left',
width: 180,
sorter:true,
ellipsis: true,
dataIndex: 'explanation'
},
{
title: this.$t('explain'),
align: 'left',
width: 360,
ellipsis: true,
sorter:true,
dataIndex: 'explain'
},
{
title: this.$t('operation'),
align: 'left',
fixed: 'right',
width: 160,
scopedSlots: { customRender: 'operation' }
}
],
userInfoQuery: {},
queryParam: {},
orderBy: '1',
orderByField: '',
cut: '',
administrators: false
}
},
mounted() {
this.getList()
this.userInfoQuery = this.userInfo()
this.administrators = false
if (this.userInfo().userRoleList && this.userInfo().userRoleList.length > 0) {
this.userInfo().userRoleList.forEach(res => {
if (res.roleCode == 'admin') {
this.administrators = true
}
})
}
},
methods: {
...mapGetters(['userInfo']),
handleToggleSearch() {
this.toggleSearchStatus = !this.toggleSearchStatus
},
toppingClick(row) {
let flag = ''
if (row.flag == '1') {
flag = '0'
} else {
flag = '1'
}
let query = {
flag: flag,
id: row.id
}
getAction('/project/projectLibraryBase/top', query).then((res) => {
if (res.success) {
this.$message.success(this.$t('OperationSuccessful'))
this.getList()
} else {
this.$message.warning(this.$t('operationFailed'))
}
})
},
changeExtensionForm() {
this.getList()
},
onSelectChange(value) {
this.selectedRowKeys = value
},
//添加
handleAdd() {
this.$refs.addModelRef.addModel()
},
//批量删除
handleDel() {
if (this.selectedRowKeys.length > 0) {
let _this = this
this.$confirm({
content: _this.$t('ConfirmBatchDeletion'),
onOk() {
let idList = JSON.parse(JSON.stringify(_this.selectedRowKeys))
deleteAction(_this.url.deleteAll, { ids: idList.join(',') }).then((res) => {
if (res.success) {
_this.$message.success(_this.$t('OperationSuccessful'))
_this.selectedRowKeys = []
_this.getList()
} else {
_this.$message.warning(_this.$t('operationFailed'))
}
})
}
})
} else {
this.$message.warning(this.$t('selectLeastOne'))
}
},
//编辑
edit(item) {
this.$refs.addModelRef.editModel(JSON.parse(JSON.stringify(item)))
},
//删除
deleteLib(val) {
let _this = this
this.$confirm({
content: _this.$t(val.children ? 'allsubitemsitem' : 'ConfirmDelete'),
onOk() {
deleteAction(_this.url.deleteBatch, { id: val.id }).then((res) => {
if (res.success) {
_this.$message.success(_this.$t('OperationSuccessful'))
_this.getList()
} else {
_this.$message.warning(res.message)
}
})
}
})
},
//虚拟清单名称事件
entryNameClick(item) {
let newUrl = this.$router.resolve({
path: '/platformItemLibraryDetails',
query: item
})
window.open(newUrl.href, '_blank')
},
searchQuery() {
this.pageNo = 1
this.getList()
},
searchReset() {
this.isPersonnelSelection = false
this.$nextTick(()=>{
this.isPersonnelSelection = true
})
this.pageNo = 1
this.queryParam = {}
this.getList()
},
pageOnChange(page, pageSize) {
this.pageNo = page
this.getList()
},
SizeChange(page, pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.getList()
},
addModelList() {
this.pageNo = 1
this.getList()
},
PersonnelSelectionChange(value, id) {
this.queryParam[value] = id
this.queryParam = { ...this.queryParam }
},
tableOnChange(pagination, filters, sorter) {
this.orderBy = sorter.order == 'ascend' ? '1' : '2'
this.orderByField = sorter.columnKey
this.getList()
},
getList() {
let query = {
pageNo: this.pageNo,
pageSize: this.pageSize,
orderBy: this.orderBy,
orderByField: this.orderByField,
...this.queryParam
}
this.loading = true
postAction(this.url.list, query).then((res) => {
if (res.success) {
if (res.result.current > 1 && res.result.records.length == 0) {
this.pageNo = 1
this.getList()
return
}
this.total = res.result.total
this.cut = res.cut
this.dataSource = res.result.records || []
this.dataSource.forEach((item) => {
if(this.cut == 'en'){
item.brandText = item.brandTextEn
}else{
item.brandText = item.brandText
}
})
this.loading = false
} else {
this.loading = false
}
})
}
}
}
</script>
<style scoped>
@import '~@assets/less/common.less';
.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;
}
.page {
text-align: right;
margin-top: 20px;
}
.box-title-text-add {
line-height: 1.4;
display: flex;
}
.title-text-add {
width: 114px;
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: 42px;
margin-top: 3px;
}
.box-input-add {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 130px);
display: inline-block;
margin-top: 2px;
}
.Required {
color: red;
margin-right: 4px;
}
.title-text-text {
margin-top: 9px;
}
.formAdd {
margin-bottom: 40px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
width: 100%;
z-index: 100;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
</style>
@@ -0,0 +1,386 @@
<!--平台件-->
<template>
<div class="box">
<div class="box-text">
<div class="header-text">
{{$t('basicInformationOfParameters')}}
</div>
<div class="header-tight">
<a-button v-if="this.$route.query.studioEngineer == this.userInfo().id || administrators" class="box-button"
style="line-height: 32px" @click="edit">
{{$t('edit')}}
</a-button>
</div>
</div>
<div class="content-text">
<div class="text-field">
<span class="text-field-left" :title="$t('entryName')">{{$t('entryName')}}</span>
<span class="text-field-right" :title="queryForm.projectName"
>{{queryForm.projectName}}</span>
</div>
<div class="text-field">
<span class="text-field-left" :title="$t('brand')">{{$t('brand')}}</span>
<span class="text-field-right" :title="queryForm.brandText"
>{{queryForm.brandText}}</span>
</div>
<div class="text-field">
<span class="text-field-left" :title="$t('configurationItem')">{{$t('configurationItem')}}</span>
<span class="text-field-right" :title="queryForm.configurationItem"
>{{queryForm.configurationItem}}</span>
</div>
</div>
<div class="content-text">
<div class="text-field">
<span class="text-field-left" :title="$t('regulatoryEngineer')">{{$t('regulatoryEngineer')}}</span>
<span class="text-field-right" :title="queryForm.regulatoryEngineer"
>{{queryForm.regulatoryEngineer}}</span>
</div>
<div class="text-field">
<span class="text-field-left" :title="$t('dehicleDevelopmentPlan')">{{$t('dehicleDevelopmentPlan')}}</span>
<span class="text-field-right text-field-right-color"
:title="queryForm.vehicleDevelopmentPlan"
@click="urlClick(queryForm.vehicleDevelopmentPlan)"
>{{queryForm.vehicleDevelopmentPlan}}</span>
</div>
<div class="text-field">
<span class="text-field-left" :title="$t('certificationProgram')">{{$t('certificationProgram')}}</span>
<span class="text-field-right text-field-right-color"
:title="queryForm.attestationPlan"
@click="urlClick(queryForm.attestationPlan)"
>{{queryForm.attestationPlan}}</span>
</div>
</div>
<div class="content-text">
<div class="text-field">
<span class="text-field-left" :title="$t('explain')">{{$t('explain')}}</span>
<span class="text-field-right" :title="queryForm.explanation"
>{{queryForm.explanation}}</span>
</div>
</div>
<div class="box-text" style="margin-top: 10px;margin-bottom: 10px">
<div class="header-text">
{{$t('complianceCertificationProgram')}}
</div>
<div class="header-tight">
<a-button class="box-button"
v-if="this.$route.query.studioEngineer == this.userInfo().id || administrators"
style="line-height: 32px"
@click="settingClick">{{$t('setting')}}
</a-button>
</div>
</div>
<div class="process-content">
<complianceCertificationForm ref="complianceCertificationRef"/>
</div>
<div class="box-text" style="margin-top: 10px">
<div class="header-text">
{{$t('projectStatus')}}
</div>
<div class="header-tight">
<a-button class="box-button"
style="line-height: 32px"
@click="stateExportClick">{{$t('stateExport')}}
</a-button>
<a-button class="box-button"
v-if="activeKey == $t('regulatoryComplianceManagement') || activeKey == $t('certificationActivityManagement')"
style="line-height: 32px"
@click="versionStatisticsClick">{{$t('versionStatistics')}}
</a-button>
</div>
</div>
<projectStatus ref="projectStatusRef"
@currentStatus="currentStatus"
@projectStatusForm="projectStatusForm"/>
<versionStatistics ref="versionStatisticsRef" @versionStatisticsForm="versionStatisticsForm"/>
<addModel :url="url" ref="addModelRef" @addModelList="addModelList"/>
<settingList :url="url" ref="settingListRef" @settingListForm="settingListForm"/>
</div>
</template>
<script>
import * as echarts from 'echarts'
import { getAction, postAction, downloadFile, putAction } from '@/api/manage'
import addModel from './addModel'
import versionStatistics from './versionStatistics'
import complianceCertificationForm from './complianceCertificationForm'
import settingList from './settingList'
import projectStatus from './projectStatus'
import { mapGetters } from 'vuex'
export default {
name: 'ProjectDetails',
components: {
addModel,
settingList,
projectStatus,
versionStatistics,
complianceCertificationForm
},
data() {
return {
queryForm: {},
cut: '',
administrators: false,
activeKey: this.$t('regulatoryComplianceManagement'),
url: {
queryById: 'project/projectLibraryBase/queryById',
add: 'project/projectLibraryBase/add',
edit: 'project/projectLibraryBase/edit',
queryByProjectId: 'project/projectTaskPlanning/queryByProjectId',
addSettingUrl: 'project/projectTaskPlanning/add',
editSettingUrl: 'project/projectTaskPlanning/edit',
settingQueryForm: '/project/projectTaskPlanning/list'
},
selectedRowKeys: [],
idList: [],
regulatoryCertificationTaskPlanList: []
}
},
mounted() {
this.getForm()
this.administrators = false
this.activeKey = this.$t('regulatoryComplianceManagement')
if (this.userInfo().userRoleList && this.userInfo().userRoleList.length > 0) {
this.userInfo().userRoleList.forEach(res => {
if (res.roleCode == 'admin') {
this.administrators = true
}
})
}
},
methods: {
...mapGetters(['userInfo']),
getForm() {
getAction(this.url.queryById, { id: this.$route.query.id }).then((res) => {
if (res.success) {
this.cut = res.cut
this.queryForm = res.result[0] || {}
if (this.cut == 'en') {
this.queryForm.brandText = this.queryForm.brandTextEn
} else {
this.queryForm.brandText = this.queryForm.brandText
}
} else {
this.queryForm = {}
}
})
},
currentStatus(item) {
this.$emit('TaskListChange', item)
},
settingListForm() {
this.$refs.complianceCertificationRef.getSetting()
},
ListOfRelevantPersonnelClick() {
this.$refs.listOfRelevantPersonnelRef.getData()
},
rxswinClick(){
this.$refs.rxswinModelRef.getData()
},
urlClick(val) {
if (val) {
window.open(val)
}
},
edit() {
this.$refs.addModelRef.editModel(JSON.parse(JSON.stringify(this.queryForm)))
},
addModelList() {
this.getForm()
},
settingClick() {
this.$refs.settingListRef.edit()
},
stateExportClick() {
let query = {
projectLibraryId: this.$route.query.id
}
downloadFile('/project/projectLibraryBase/exportProjectProgressStatisticsXls',
this.queryForm.projectName+'-'+this.queryForm.projectVersion+'-'+this.$t('projectProgressStatistics') + '.xls', query)
},
versionStatisticsClick() {
this.$refs.versionStatisticsRef.addModel(JSON.parse(JSON.stringify(this.selectedRowKeys)))
},
versionStatisticsForm(value) {
this.$refs.projectStatusRef.versionStatisticsForm(value)
this.selectedRowKeys = JSON.parse(JSON.stringify(value))
},
projectStatusForm(activeKey) {
this.activeKey = activeKey
}
}
}
</script>
<style scoped lang="less">
@import '~@assets/less/common.less';
.box {
padding: 0 24px 24px 24px;
box-sizing: border-box;
}
.header-text {
font-size: 16px;
font-weight: bold;
color: #000F16;
}
.content-text {
width: 100%;
display: flex;
flex-wrap: wrap;
.text-field {
width: 33%;
margin-bottom: 8px;
.text-field-left {
width: 124px;
display: inline-block;
font-size: 14px;
font-weight: 400;
color: #6F7385;
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
margin-right: 24px;
}
.text-field-right {
width: calc(100% - 200px);
display: inline-block;
font-size: 16px;
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
word-break: break-word;
color: #040B29;
font-weight: 400;
}
}
.text-field-content {
width: 100%;
/*margin-bottom: 34px;*/
.text-field-left {
width: 124px;
display: inline-block;
font-size: 14px;
font-weight: 400;
color: #6F7385;
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
float: left;
margin-right: 24px;
margin-top: 3px;
}
.text-field-right {
width: calc(100% - 200px);
display: inline-block;
font-size: 16px;
float: left;
word-break: break-word;
color: #040B29;
font-weight: 400;
}
}
}
.process-content {
margin-top: 4px;
position: relative;
.process-content-content {
background: #fff;
z-index: 1000;
padding: 0 20px;
.process-content-left {
float: left;
}
.process-content-right {
float: left;
margin-left: 7px;
.process-content-right-top {
font-size: 14px;
font-weight: 400;
color: #040B29;
max-width: 155px;
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
}
.process-content-right-button {
max-width: 155px;
font-size: 12px;
font-weight: 400;
color: #6F7385;
margin-top: -4px;
}
}
}
.process-content-content:first-child {
padding: 0 20px 0 0;
}
.process-content-content:last-child {
padding: 0 0 0 20px;
}
.process-content-right-xian {
height: 2px;
width: calc(100% - 27px);
background: #E6E6E9;
position: absolute;
top: 16px;
}
}
@media screen and (min-width: 600px) and (max-width: 1600px) {
.process-content-right-top {
max-width: 70px !important;
white-space: inherit !important;
overflow: hidden !important;
}
.process-content-right-button {
max-width: 70px !important;
}
}
.text-field-right-color {
color: #00B3BE !important;
cursor: pointer;
}
.box-text {
display: flex;
justify-content: space-between;
height: 72px;
line-height: 80px;
}
.header-tight {
line-height: 90px;
}
.button-text {
padding: 0 13px;
}
.box-button {
margin-left: 12px;
}
</style>
@@ -0,0 +1,960 @@
<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('areaOfResponsibility')">
<span>{{$t('areaOfResponsibility')}}</span>
</div>
<j-multi-select-tag class="box-input" v-model="queryParam.dutyTerritory"
:placeholder="$t('PleaseSelect')+$t('areaOfResponsibility')"
:type="'select'"
:triggerChange="false" :dictCode="'duty_territory'"/>
</div>
</a-col>
<a-col :md="6" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('CertificationProgress')">
<span>{{$t('CertificationProgress')}}</span>
</div>
<j-dict-select-tag class="box-input" v-model="queryParam.certificationProgress"
:placeholder="$t('PleaseSelect')+$t('CertificationProgress')"
:type="'select'"
:triggerChange="false" :dictCode="'certification_progress'"/>
</div>
</a-col>
<template v-if="toggleSearchStatus">
<a-col :md="6" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('CurrentStatus')">
<span>{{$t('CurrentStatus')}}</span>
</div>
<a-select
class="box-input"
v-model="queryParam.projectStatusAssess"
:placeholder="$t('PleaseSelect')+$t('CurrentStatus')">
<a-select-option :value="'1'">
<span style="display: inline-block;width: 100%">
{{ $t('red') }}
</span>
</a-select-option>
<a-select-option :value="'2'">
<span style="display: inline-block;width: 100%">
{{ $t('yellow') }}
</span>
</a-select-option>
<a-select-option :value="'3'">
<span style="display: inline-block;width: 100%">
{{ $t('green') }}
</span>
</a-select-option>
<a-select-option :value="'4'">
<span style="display: inline-block;width: 100%">
{{ $t('blue') }}
</span>
</a-select-option>
</a-select>
</div>
</a-col>
</template>
<span style="float: right;overflow: hidden;" 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 class="operator-text" @click="cuibanClick" v-if="isRoleSwitching">
<a-icon type="sound"/>
{{ $t('CuiBan') }}
</div>
<div @click="BatchMaintenanceProgress" class="operator-text" v-if="isRoleSwitching">
<a-icon type="setting"/>
{{$t('BatchMaintenanceProgress')}}
</div>
<div @click="BatchChangeStatus" class="operator-text" v-if="isRoleSwitching">
<a-icon type="setting"/>
{{$t('BatchChangeStatus')}}
</div>
<div @click="CertificationDirectory" class="operator-text" v-if="isRoleSwitching">
<a-icon type="bulb"/>
{{$t('CertificationDirectory')}}
</div>
<div @click="handleExport" class="operator-text" v-if="isRoleSwitching">
<a-icon type="export" :rotate="-90"/>
{{$t('export')}}
</div>
</div>
<div style="width: 100%">
<!-- rowKey="id"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"-->
<a-table
ref="table"
bordered
class="taskTable"
:loading="loading"
:pagination="false"
:scroll="{x: '100%',y:'calc(100vh - 300px)'}"
:data-source="dataSource"
rowKey="id"
@change="tableOnChange"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
:columns="columns" :components="drag(columns,'columns',JSON.parse(JSON.stringify([[columns[3],200],[columns[4],200],[columns[5],200]])))"
>
<div slot="standardInformation" slot-scope="text,result" class="box-left">
<div class="content">
<a class="box-content-a" @click="standardClick(result)"
:title="result.serialNumber">{{result.serialNumber}}</a>
<a class="box-content-buttom" :title="result.title">{{result.title}}</a>
</div>
</div>
<div slot="areaOfResponsibility" slot-scope="text,result" class="box-left">
<div class="content" v-if="result.dutyTerritory_dictText">
<span v-for="(item,index) in result.dutyTerritory_dictText.split(',')">
<span class="box-content-index">{{item}}</span><br/>
</span>
</div>
</div>
<div slot="confirmationOfDesignConformity" slot-scope="text,result" class="box-left">
<div class="content" v-if="result.designTaskStatus" @click="verifyTaskClick(result,1,false)">
<span class="box-content">{{$t('Deadline')}}: {{result.designDueDate}}</span><br/>
<span class="box-content">{{$t('ProcessStatus')}}: {{result.designStatus}}</span><br/>
<span class="box-content-color"
:style="{'width':long=='zh-cn'?'78px' : '138px'}"
:class="color[result.designFlowTaskStatus]">
{{statusText[result.designFlowTaskStatus]}}
</span>
</div>
<div class="content-box" v-if="result.designTaskStatus == 'NotDone'" @click="verifyTaskClick(result,1,true)">
<div class="content-box-jiao"></div>
</div>
</div>
<div slot="PrehomoConfirmation" slot-scope="text,result" class="box-left">
<div class="content" v-if="result.prehomoTaskStatus" @click="verifyTaskClick(result,2,false)">
<span class="box-content">{{$t('Deadline')}}: {{result.prehomoDueDate}}</span><br/>
<span class="box-content">{{$t('ProcessStatus')}}: {{result.prehomoStatus}}</span><br/>
<span class="box-content-color"
:style="{'width':long=='zh-cn'?'78px' : '138px'}"
:class="color[result.prehomoFlowTaskStatus]">
{{statusText[result.prehomoFlowTaskStatus]}}
</span>
</div>
<div class="content-box" v-if="result.prehomoTaskStatus == 'NotDone'" @click="verifyTaskClick(result,2,true)">
<div class="content-box-jiao"></div>
</div>
</div>
<div slot="verificationAndConformityconfirmation" slot-scope="text,result" class="box-left">
<div class="content" v-if="result.verifyTaskStatus" @click="verifyTaskClick(result,3,false)">
<span class="box-content">{{$t('Deadline')}}: {{result.verifyDueDate}}</span><br/>
<span class="box-content">{{$t('ProcessStatus')}}: {{result.verifyStatus}}</span><br/>
<span class="box-content-color"
:style="{'width':long=='zh-cn'?'78px' : '138px'}"
:class="color[result.verifyFlowTaskStatus]">
{{statusText[result.verifyFlowTaskStatus]}}
</span>
</div>
<div class="content-box" v-if="result.verifyTaskStatus == 'NotDone'" @click="verifyTaskClick(result,3,true)">
<div class="content-box-jiao"></div>
</div>
</div>
<div slot="CertificationProgress" slot-scope="text,result">
<span class="box-content-Progress box-content-cou"
:style="{'width':long=='zh-cn'?'88px' : '108px'}"
:class="CertificationColor[result.certificationProgress]"
@click="CertificationProgressClick(result)"
>
{{result.certificationProgress_dictText ? result.certificationProgress_dictText : $t('maintainProgress')}}
</span>
</div>
<div slot="CurrentProjectStatusEvaluation" slot-scope="text,result">
<div class="Current-color box-content-cou" :style="{'background':CurrentColor[result.projectStatusAssess]}"
@click="CurrentProjectClick(result)">
<div class="Current-color-box" :style="{'background':CurrentColorBox[result.projectStatusAssess]}"></div>
</div>
</div>
</a-table>
</div>
<certificationDirectory :isDisplayNum="isDisplayNum" :url="url" ref="certificationDirectoryRef"/>
<TaskListModel @TaskListModelList="TaskListModelList" ref="TaskListModelRef"/>
<taskBatSetting @taskBatSettingForm="taskBatSettingForm" ref="taskBatSettingRef"></taskBatSetting>
<batchChangeModel @batchChangeModel="batchChangeModel" ref="batchChangeModelRef"/>
<cuibanModel @cibanModel="cibanModel" ref="cModelRef"/>
<batchModel @batchModel="batchModel" ref="batchModelRef"/>
<!-- 错误数据提示-->
<a-modal
:title="$t('operationFailed')"
:width="860"
v-model="visibleoperationFailed"
:maskClosable="false"
@cancel='cancleoperationFailed'
:footer="null"
>
<a-row :gutter="24">
<a-col :span="24">
<span style='font-size: 16px;margin-bottom: 20px;display: flex;justify-content: center'
v-for='(item,key) in NotSelectedNoEngineerValue'>
<span v-html='item'></span>
</span>
</a-col>
</a-row>
<div class="imports-footer">
<div class="imports-footer-wrap" style='text-align: center'>
<a-button class="imports-btn" type="primary" @click="cancleoperationFailed">{{$t('cancel')}}</a-button>
</div>
</div>
</a-modal>
</a-card>
</template>
<script>
import certificationDirectory from './certificationDirectory'
import batchChangeModel from './batchChangeModel'
import batchModel from './batchModel'
import TaskListModel from './TaskListModel'
import cuibanModel from './cuibanModel'
import taskBatSetting from './taskBatSetting'
import { getAction, postAction, deleteAction, downloadFile } from '@/api/manage'
import { mapGetters } from 'vuex'
import store from '@/store/'
import { ResizeHeader, ResizeColumnProvide } from '@/mixins/header'
export default {
name: 'TaskList',
components: {
certificationDirectory,
TaskListModel,
batchChangeModel,
batchModel,
cuibanModel,
taskBatSetting
},
props: ['isDisplayNum', 'areaOfResponsibility'],
mixins:[ResizeHeader, ResizeColumnProvide],
data() {
return {
toggleSearchStatus: false,
columns: [
{
title: this.$t('number'),
align: 'left',
width: 70,
customRender: function(t, r, index) {
return parseInt(index) + 1
}
},
{
title: this.$t('standardInformation'),
align: 'left',
dataIndex: 'standard',
width: 202,
sorter:true,
scopedSlots: { customRender: 'standardInformation' }
},
{
title: this.$t('areaOfResponsibility'),
align: 'left',
width: 100,
sorter:true,
dataIndex: 'areaOfResponsibility',
scopedSlots: { customRender: 'areaOfResponsibility' }
},
{
title: this.$t('confirmationOfDesignConformity'),
align: 'left',
width: 240,
sorter:true,
dataIndex: 'confirmationOfDesignConformity',
scopedSlots: { customRender: 'confirmationOfDesignConformity' }
},
{
title: this.$t('PrehomoConfirmation'),
align: 'left',
width: 240,
sorter:true,
dataIndex: 'PrehomoConfirmation',
scopedSlots: { customRender: 'PrehomoConfirmation' }
},
{
title: this.$t('verificationAndConformityconfirmation'),
align: 'left',
width: 240,
sorter:true,
dataIndex: 'verificationAndConformityconfirmation',
scopedSlots: { customRender: 'verificationAndConformityconfirmation' }
},
{
title: this.$t('CertificationProgress'),
align: 'left',
width: 150,
sorter:true,
dataIndex: 'CertificationProgress',
scopedSlots: { customRender: 'CertificationProgress' }
},
{
title: this.$t('CurrentStatus'),
align: 'left',
width: 150,
sorter:true,
dataIndex: 'CurrentProjectStatusEvaluation',
scopedSlots: { customRender: 'CurrentProjectStatusEvaluation' }
}
],
selectedRowKeys: [],
orderBy: '1',
orderByField: '',
status: {
'NotDone': '待办',
'haveDone': '已办',
'showData': '展示数据'
},
color: {
'Compliance': 'accordColor',
'Non-Compliance': 'nonConformityColor',
'To be tracked': 'TrackedColor',
'NA': 'notInvolvedColor',
'No rating': 'submittedColor',
'Termination of task': 'nonConformityColor'
},
statusText: {
'Compliance': this.$t('accord'),
'Non-Compliance': this.$t('nonConformity'),
'To be tracked': this.$t('Tracked'),
'NA': this.$t('notInvolved'),
'No rating': this.$t('toBeConfirmed'),
'Termination of task': this.$t('taskTermination')
},
CertificationColor: {
'Test passed': 'accordColor',
'Test failed': 'nonConformityColor',
'In progress': 'TrackedColor',
'NA': 'notInvolvedColor',
'Not start': 'submittedColor'
},
queryParam: {},
CurrentColor: {
'1': '#f3dddd',
'2': '#f6ebdb',
'3': '#dbf6e2',
'4': '#ddf3f4'
},
CurrentColorBox: {
'1': '#E83030',
'2': '#FDA71C',
'3': '#26BD4B',
'4': '#00B3BE'
},
url: {
list: '/project/projectTaskInventoryEO/list',
exportXls: '/project/projectTaskInventoryEO/exportXls'
},
isRoleSwitching:true,
loading: false,
visibleoperationFailed: false,
NotSelectedNoEngineerValue: [],
dataSource: [],
selectionRowsArray:[],
roleSwitchingList:[],
roleCodes:[],
long: ''
}
},
watch: {
'$socketPublic.state.msg': {
//处理接收到的消息
handler: function(res) {
let that = this
let data = JSON.parse(res.data)
if (data.msgId) {
this.getList()
}
}
}
},
created() {
if (store.getters.userInfo) {
this.$socketPublic.dispatch('webSocketInit')//初始化ws
}
},
mounted() {
if (this.areaOfResponsibility.dutyTerritory) {
this.queryParam.dutyTerritory = this.areaOfResponsibility.dutyTerritory
this.queryParam = { ...this.queryParam }
}
this.getList()
this.getRoleByUserId()
this.long = localStorage.getItem('language') || 'zh-cn'
},
methods: {
...mapGetters(['userInfo']),
handleToggleSearch() {
this.toggleSearchStatus = !this.toggleSearchStatus
},
searchQuery() {
this.getList()
},
getRoleByUserId(callback) {
getAction('/project/projectLawsInventoryEO/getRoleByUserId', { projectLibraryId: this.$route.query.id }).then((res) => {
if (res.success) {
this.roleSwitchingList = res.result || []
if(this.roleSwitchingList.length == 1){
if(this.roleSwitchingList[0].roleCode == '13'){
this.isRoleSwitching = false
}
}
} else {
this.roleSwitchingList = []
}
callback && callback()
})
},
searchReset() {
this.queryParam = {}
this.getList()
},
batSettingClick() {
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
this.$refs.taskBatSettingRef.edit(JSON.parse(JSON.stringify(this.selectedRowKeys)))
} else {
this.$message.warning(this.$t('selectLeastOne'))
}
},
taskBatSettingForm() {
this.getList()
},
batchChangeModel() {
this.getList()
},
batchModel() {
this.getList()
},
onSelectChange(value, selectionRows) {
this.selectedRowKeys = value
this.selectionRowsArray = selectionRows
},
handleExport() {
let query = {
...this.queryParam,
projectLibraryId: this.$route.query.id
}
downloadFile(this.url.exportXls, this.$t('taskList') + '.xls', query, this.Deselect)
},
verifyTaskClick(val, num, isTrue) {
let query = {}
switch (num) {
case 1:
val.designTaskId = val.designTaskId + ''
if (val.designTaskId.length > 30) {
val.designTaskId = ''
}
query = {
taskIds: val.designTaskId,
actiProcInstId: val.designPId,
projectTaskInventoryId: val.projectLawsInventoryId,
projectLibraryId: this.$route.query.id,
id: this.$route.query.id,
studioEngineer: this.$route.query.studioEngineer,
serialNumber: val.serialNumber,
TaskKey: val.designTaskDefinitionKey,
isDisplay: isTrue,
flowType: 2,
Sponsor: 'designInitiatorName',
personLiable: 'designDutyName',
typeOfDeliverables: 'designDeliverableTypeName',
deliverableTemplate: 'designDeliverableTemplate',
DueDate: 'designDueDate',
remarks: 'designRemark',
projectName: this.$route.query.projectName,
targetMarket: this.$route.query.targetMarket,
projectNameId: this.$route.query.projectNameId,
primaryKeyId: val.designTaskDetailId,
PersonChargeFeedback: val.designPersonChargeFeedback
}
break
case 2:
val.prehomoTaskId = val.prehomoTaskId + ''
if (val.prehomoTaskId.length > 30) {
val.prehomoTaskId = ''
}
query = {
taskIds: val.prehomoTaskId,
actiProcInstId: val.prehomoPId,
projectTaskInventoryId: val.projectLawsInventoryId,
studioEngineer: this.$route.query.studioEngineer,
projectLibraryId: this.$route.query.id,
serialNumber: val.serialNumber,
TaskKey: val.prehomoTaskDefinitionKey,
flowType: 3,
isDisplay: isTrue,
id: this.$route.query.id,
Sponsor: 'prehomoInitiatorName',
personLiable: 'prehomoDutyName',
typeOfDeliverables: 'prehomoDeliverableTypeName',
deliverableTemplate: 'prehomoDeliverableTemplate',
DueDate: 'prehomoDueDate',
remarks: 'prehomoRemark',
projectName: this.$route.query.projectName,
targetMarket: this.$route.query.targetMarket,
projectNameId: this.$route.query.projectNameId,
primaryKeyId: val.prehomoTaskDetailId,
PersonChargeFeedback: val.prehomoPersonChargeFeedback
}
break
case 3:
val.verifyTaskId = val.verifyTaskId + ''
if (val.verifyTaskId.length > 30) {
val.verifyTaskId = ''
}
query = {
taskIds: val.verifyTaskId,
actiProcInstId: val.verifyPId,
id: this.$route.query.id,
projectLibraryId: this.$route.query.id,
studioEngineer: this.$route.query.studioEngineer,
serialNumber: val.serialNumber,
projectTaskInventoryId: val.projectLawsInventoryId,
TaskKey: val.verifyTaskDefinitionKey,
flowType: 4,
isDisplay: isTrue,
Sponsor: 'verifyInitiatorName',
personLiable: 'verifyDutyName',
typeOfDeliverables: 'verifyDeliverableTypeName',
deliverableTemplate: 'verifyDeliverableTemplate',
DueDate: 'verifyDueDate',
remarks: 'verifyRemark',
projectName: this.$route.query.projectName,
targetMarket: this.$route.query.targetMarket,
projectNameId: this.$route.query.projectNameId,
primaryKeyId: val.verifyTaskDetailId,
PersonChargeFeedback: val.verifyPersonChargeFeedback
}
break
}
let newUrl = this.$router.resolve({
path: '/taskListProcess',
query: query
})
window.open(newUrl.href, '_blank')
},
CertificationDirectory() {
this.$refs.certificationDirectoryRef.addModel()
},
tableOnChange(pagination, filters, sorter) {
this.orderBy = sorter.order == 'ascend' ? '1' : '2'
if(sorter.columnKey == 'standard'){
this.orderByField = 'serialNumber'
} else if(sorter.columnKey == 'areaOfResponsibility') {
this.orderByField = 'dutyTerritory'
} else if(sorter.columnKey == 'confirmationOfDesignConformity') {
this.orderByField = 'designFlowTaskStatus'
} else if(sorter.columnKey == 'PrehomoConfirmation') {
this.orderByField = 'prehomoFlowTaskStatus'
} else if(sorter.columnKey == 'verificationAndConformityconfirmation') {
this.orderByField = 'verifyFlowTaskStatus'
} else if(sorter.columnKey == 'CertificationProgress') {
this.orderByField = 'certificationProgressName'
} else if(sorter.columnKey == 'CurrentProjectStatusEvaluation') {
this.orderByField = 'projectStatusAssess'
} else{
this.orderByField = sorter.columnKey
}
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(',')
}
})
if (queryParam.dutyTerritory) {
queryParam.dutyTerritory = '*' + queryParam.dutyTerritory + '*'
}
let query = {
projectLibraryId: this.$route.query.id,
orderBy: this.orderBy,
orderByField: this.orderByField,
...queryParam
}
this.loading = true
getAction(this.url.list, query).then((res) => {
if (res.success) {
this.dataSource = res.result
this.loading = false
// this.dataSource = [{}]
} else {
this.dataSource = []
this.loading = false
}
})
},
CertificationProgressClick(val) {
let item = JSON.parse(JSON.stringify(val))
this.$refs.TaskListModelRef.getData(item, this.$t('CertificationProgress'))
},
CurrentProjectClick(val) {
let item = JSON.parse(JSON.stringify(val))
this.$refs.TaskListModelRef.getData(item, this.$t('CurrentStatus'))
},
// 催办
cuibanClick() {
if (this.selectionRowsArray.length < 1) {
this.$message.warning(this.$t('selectLeastOne'))
} else {
this.$refs.cModelRef.getData(this.selectionRowsArray)
}
},
cibanModel() {
this.getList()
},
//批量维护进度
BatchMaintenanceProgress() {
if (this.selectionRowsArray.length < 1) {
this.$message.warning(this.$t('selectLeastOne'))
} else {
let query = {}
let projectLawsInventoryIds = []
let roleCodes = []
this.selectionRowsArray.forEach((item, index) => {
projectLawsInventoryIds.push(item.projectLawsInventoryId)
roleCodes.push(item.roleCode)
})
query = {
roleCodes: roleCodes.join(','),
operation: '1',
projectLawsInventoryIds: projectLawsInventoryIds.join(',')
}
postAction('/project/projectTaskInventoryEO/verifyRoleCode', query).then((res) => {
if (res.success) {
if (res.result.length == 0) {
this.$refs.batchModelRef.getData(this.selectedRowKeys)
} else {
this.NotSelectedNoEngineerValue = res.result
this.visibleoperationFailed = true
}
} else {
}
})
}
},
//批量修改状态
BatchChangeStatus() {
if (this.selectionRowsArray.length < 1) {
this.$message.warning(this.$t('selectLeastOne'))
} else {
let query = {}
let projectLawsInventoryIds = []
let roleCodes = []
this.selectionRowsArray.forEach((item, index) => {
projectLawsInventoryIds.push(item.projectLawsInventoryId)
roleCodes.push(item.roleCode)
})
query = {
roleCodes: roleCodes.join(','),
operation: '2',
projectLawsInventoryIds: projectLawsInventoryIds.join(',')
}
postAction('/project/projectTaskInventoryEO/verifyRoleCode', query).then((res) => {
if (res.success) {
if (res.result.length == 0) {
this.$refs.batchChangeModelRef.getData(this.selectionRowsArray)
} else {
this.NotSelectedNoEngineerValue = res.result
this.visibleoperationFailed = true
}
} else {
}
})
}
},
// 催办
cuibanClick() {
if (this.selectionRowsArray.length < 1) {
this.$message.warning(this.$t('selectLeastOne'))
} else {
this.$refs.cModelRef.getData(this.selectionRowsArray)
}
},
cibanModel() {
this.getList()
},
cancleoperationFailed() {
this.visibleoperationFailed = false
},
TaskListModelList() {
this.getList()
},
standardClick(row) {
let newUrl = this.$router.resolve({
path: '/docManage/library/detail',
query: {
id: row.standId
}
})
window.open(newUrl.href, '_blank')
}
}
}
</script>
<style lang="less" scoped>
@import '~@assets/less/common.less';
.box-title-text {
line-height: 1.4;
display: flex;
align-items: center;
margin-bottom: 10px;
}
.title-text {
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: calc(100% - 126px);
height: 38px;
margin-top: 2px;
}
.box-button {
height: 38px;
}
.text-operation {
margin-right: 8px;
}
.page {
text-align: right;
margin-top: 20px;
}
.operator-text-left {
font-size: 14px;
margin-right: 20px;
background: #eff1f3;
padding: 8px 8px;
cursor: pointer;
border-radius: 4px;
}
.box-left {
position: relative;
display: block;
height: 100%;
text-align: left;
}
.content {
text-align: left;
margin: 0 auto;
display: inline-block;
}
.content-box {
position: absolute;
width: calc(100% + 32px);
height: calc(100% + 32px);
top: -16px;
left: -16px;
border: 1px #00B3BE solid;
}
.content-box-jiao {
position: absolute;
right: 0;
width: 0;
height: 0;
border-right: 14px solid #00B3BE;
border-bottom: 14px solid transparent
}
.box-content {
margin-bottom: 8px;
display: inline-block;
text-align: left;
font-weight: 400;
color: #040B29;
}
.box-content-a {
display: inline-block;
text-align: left;
margin-bottom: 8px;
font-weight: 400;
display: -webkit-box;
width: 100%;
overflow: hidden;
text-overflow: ellipsis;
/*! autoprefixer: off */
-webkit-box-orient: vertical;
-webkit-line-clamp: 1;
/*! autoprefixer: on;*/
text-justify: inter-ideograph;
word-break: break-all
}
.box-content-index {
margin-bottom: 8px;
display: inline-block;
text-align: left;
font-weight: 400;
color: #040B29;
}
.box-content-index:last-child {
margin-bottom: 0;
}
.box-content-color {
width: 138px;
height: 32px;
display: inline-block;
border-radius: 4px;
text-align: center;
font-size: 14px;
line-height: 32px;
}
.box-content-Progress {
width: 88px;
height: 32px;
display: inline-block;
text-align: center;
line-height: 32px;
border-radius: 4px;
background: #f1f3f5;
color: #919399;
}
.accordColor {
background: #dbf6e2;
color: #26BD4B;
}
.nonConformityColor {
background: #f3dddd;
color: #E83030;
}
.TrackedColor {
background: #f6ebdb;
color: #FDA71C;
}
.notInvolvedColor {
background: #eef1f4;
color: #707486;
}
.submittedColor {
color: #00B3BE;
background: #ddf3f4;
}
.Current-color {
display: inline-block;
width: 28px;
height: 28px;
line-height: 32px;
text-align: center;
background: #ddf3f4;
border-radius: 50%;
}
.Current-color-box {
display: inline-block;
width: 14px;
height: 14px;
background: #00B3BE;
border-radius: 50%;
}
.box-content-cou {
cursor: pointer;
}
.box-content-buttom {
width: 100%;
overflow: hidden;
display: -webkit-box;
text-overflow: ellipsis;
/*! autoprefixer: off */
-webkit-box-orient: vertical;
-webkit-line-clamp: 1;
/*! autoprefixer: on;*/
text-justify: inter-ideograph;
word-break: break-all
}
///deep/.taskTable .ant-table-thead > tr > th {
// font-weight: bolder;
//}
/deep/ .ant-table-thead > tr > th {
background: #f3f6f6!important;
padding: 12px 16px!important;
}
/deep/ .ant-table-tbody > tr > td {
padding: 16px 16px!important;
}
::v-deep .ant-table-placeholder {
margin-top: 8px !important;
}
</style>
<style>
.box-input .ant-select-selection {
height: 38px !important;
}
.box-input .ant-select-selection__rendered {
line-height: 38px;
}
.taskTable .ant-empty-normal {
padding: 32px 0 !important;
margin: 0 !important;
}
</style>
@@ -0,0 +1,340 @@
<template>
<a-modal
:title="title"
:width="700"
:visible="visible"
:confirm-loading="confirmLoading"
:maskClosable="false"
@ok="handleOk"
@cancel="visible = false"
>
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24">
<div class="headerText" v-if="title == $t('CurrentStatus')">
{{this.$t('redSchedule')}}<br/>
{{this.$t('yellowSchedule')}}<br/>
{{this.$t('greenRequirements')}}<br/>
{{this.$t('blueUndeterminedState')}}
</div>
<a-col :span="24" v-if="title == $t('CertificationProgress')">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('CertificationProgress')">{{$t('CertificationProgress')}}</span>
</div>
<a-form-model-item class="itemModel" :prop="!disabled?'certificationProgress':''">
<j-dict-select-tag class="box-input" v-model="formInline.certificationProgress"
:disabled="disabled"
@input="handleInput('certificationProgress')"
:placeholder="$t('PleaseSelect')+$t('CertificationProgress')"
:type="'select'"
:triggerChange="false" :dictCode="'certification_progress'"/>
</a-form-model-item>
</div>
</a-col>
<a-col :span="24" v-if="title == $t('CertificationProgress')">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('remarks')">{{$t('remarks')}}</span>
</div>
<a-form-model-item class="itemModel" :prop="!disabled?'certificationProgressRemark':''">
<a-textarea
:placeholder="$t('PleaseEnter')+$t('remarks')"
:disabled="disabled"
v-model="formInline.certificationProgressRemark" :rows="4"/>
</a-form-model-item>
</div>
</a-col>
<a-col :span="24" v-if="title == $t('CurrentStatus') && this.formInline.roleCode != '0'">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('CurrentProjectStatusEvaluation')">{{$t('CurrentProjectStatusEvaluation')}}</span>
</div>
<a-form-model-item class="itemModel" prop="conditionAssessment">
<a-select
:disabled="disabled"
v-model="formInline.conditionAssessment"
:placeholder="$t('PleaseSelect')+$t('CurrentProjectStatusEvaluation')">
<a-select-option :value="'1'">
<span style="display: inline-block;width: 100%">
{{ $t('red') }}
</span>
</a-select-option>
<a-select-option :value="'2'">
<span style="display: inline-block;width: 100%">
{{ $t('yellow') }}
</span>
</a-select-option>
<a-select-option :value="'3'">
<span style="display: inline-block;width: 100%">
{{ $t('green') }}
</span>
</a-select-option>
<a-select-option :value="'4'" disabled>
<span style="display: inline-block;width: 100%">
{{ $t('blue') }}
</span>
</a-select-option>
</a-select>
</a-form-model-item>
</div>
</a-col>
<a-col :span="24" v-if="title == $t('CurrentStatus') && this.formInline.roleCode != '0'">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('remarks')">{{$t('remarks')}}</span>
</div>
<a-form-model-item class="itemModel" prop="remark">
<a-textarea
:placeholder="$t('remarks')"
:disabled="disabled"
v-model="formInline.remark" :rows="4"/>
</a-form-model-item>
</div>
</a-col>
<div v-for="item in studioList"
v-if="title == $t('CurrentStatus') && formInline.roleCode == '0'">
<div class="headerText"
v-if="item.roleCode == 1"
style="margin-top: 10px">
{{$t('regulatoryEngineer')+$t('judge')}}
</div>
<div class="headerText"
v-else-if="item.roleCode == 2"
style="margin-top: 10px">
{{$t('certifiedEngineer')+$t('judge')}}
</div>
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('CurrentStatus')">{{$t('CurrentStatus')}}</span>
</div>
<a-form-model-item class="itemModel" prop="conditionAssessment">
<a-select
:disabled="disabled"
v-model="item.conditionAssessment"
:placeholder="$t('PleaseSelect')+$t('CurrentStatus')">
<a-select-option :value="'1'">
<span style="display: inline-block;width: 100%">
{{ $t('red') }}
</span>
</a-select-option>
<a-select-option :value="'2'">
<span style="display: inline-block;width: 100%">
{{ $t('yellow') }}
</span>
</a-select-option>
<a-select-option :value="'3'">
<span style="display: inline-block;width: 100%">
{{ $t('green') }}
</span>
</a-select-option>
<a-select-option :value="'4'" disabled>
<span style="display: inline-block;width: 100%">
{{ $t('blue') }}
</span>
</a-select-option>
</a-select>
</a-form-model-item>
</div>
</a-col>
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('remarks')">{{$t('remarks')}}</span>
</div>
<a-form-model-item class="itemModel" prop="remark">
<a-textarea
:placeholder="$t('remarks')"
:disabled="disabled"
v-model="item.remark" :rows="4"/>
</a-form-model-item>
</div>
</a-col>
</div>
</a-row>
</a-form-model>
</a-modal>
</template>
<script>
import { postAction, putAction, getAction } from '@/api/manage'
export default {
name: 'TaskListModel',
data() {
return {
formInline: {},
rules: {
certificationProgressRemark:[
{
max: 500,
message: this.$t('remarks') + this.$t('cannotExceed') + 500 + this.$t('Characters'),
trigger: 'blur'
}
],
},
title: this.$t('CertificationProgress'),
visible: false,
confirmLoading: false,
studioList: [],
disabled: false,
url: {
// edit: '/project/projectTaskInventoryEO/edit',
edit: '/project/projectCertificationInventoryEO/edit',
addOrUpdate: '/project/projectTaskInventoryConditionAssessmentEO/addOrUpdate',
list: '/project/projectTaskInventoryConditionAssessmentEO/list'
}
}
},
mounted() {
},
methods: {
getData(val, title) {
this.visible = true
this.title = title
if (title == this.$t('CurrentStatus')) {
val.remark = val.projectStatusAssessRemark || ''
val.conditionAssessment = val.projectStatusAssess || ''
if (val.roleCode == '2' || val.roleCode == '4' || val.roleCode == '1') {
this.disabled = false
} else {
if (val.roleCode == '0') {
this.getList(val)
}
this.disabled = true
}
} else {
if (val.roleCode == '2') {
this.disabled = false
} else {
this.disabled = true
}
}
this.formInline = val
this.$nextTick(() => {
this.$refs.ruleForm.clearValidate()
})
},
getList(val) {
getAction(this.url.list, { projectLawsInventoryId: val.projectLawsInventoryId }).then((res) => {
if (res.success) {
this.studioList = res.result || []
} else {
this.studioList = []
}
})
},
handleInput(value) {
this.$nextTick(() => {
this.formInline = { ...this.formInline }
this.$refs.ruleForm.validateField([value])
})
},
handleOk() {
if (this.disabled) {
this.visible = false
return
}
this.$refs.ruleForm.validate(valid => {
if (valid) {
let query = {}
let url = ''
let Action
if (this.title == this.$t('CertificationProgress')) {
query = {
...this.formInline
// id: this.formInline.id,
// certificationProgress: this.formInline.certificationProgress,
// certificationProgressRemark: this.formInline.certificationProgressRemark
}
url = this.url.edit
Action = putAction
} else {
query = {
roleCode: this.formInline.roleCode,
remark: this.formInline.remark,
conditionAssessment: this.formInline.conditionAssessment,
projectLawsInventoryId: this.formInline.projectLawsInventoryId
}
url = this.url.addOrUpdate
Action = postAction
}
this.confirmLoading = true
Action(url, query).then((res) => {
if (res.success) {
this.visible = false
this.confirmLoading = false
this.$message.success(this.$t('OperationSuccessful'))
this.$emit('TaskListModelList')
} else {
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
}
})
}
})
}
}
}
</script>
<style scoped>
.box-title-text {
line-height: 1.4;
display: flex;
}
.Required {
color: red;
margin-right: 4px;
}
.title-text {
width: 134px;
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: 42px;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 130px);
display: inline-block;
margin-top: 2px;
}
.title-text-text {
margin-top: 9px;
}
.headerText {
margin-left: 30px;
color: #040B29;
font-weight: 400;
}
</style>
@@ -0,0 +1,663 @@
<template>
<a-card :bordered="false">
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24" class='add-padding'>
<a-col :md="7" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('title')">
<span>{{$t('title')}}</span>
</div>
<a-input class="box-input" :placeholder="$t('PleaseEnter')+$t('title')"
v-model="queryParam.title"></a-input>
</div>
</a-col>
<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" @click="searchReset">{{$t('reset')}}</a-button>
<a-button class="box-button" style="margin-left: 8px" type="primary" @click="searchQuery">{{$t('query')}}</a-button>
</a-col>
</span>
</a-row>
</a-form>
</div>
<div class="table-operator">
<div @click="handleAdd" class="operator-text" v-has="'params:manifest:add'">
<a-icon type="plus"/>
{{$t('addDetailList')}}
</div>
<div @click="handleModule" class="operator-text" v-has="'params:manifest:change'">
<a-icon type="file-sync"/>
{{$t('changeExtension')}}
</div>
<div @click="handleCody" class="operator-text" v-has="'params:manifest:copy'">
<a-icon type="copy"/>
{{$t('copyParamDetailList')}}
</div>
<div @click="handleDel" class="operator-text" v-has="'params:manifest:deleteBatch'">
<a-icon type="delete"/>
{{$t('BatchDelete')}}
</div>
</div>
<div style="width: 100%">
<a-table
class='table-area'
ref='table'
size='middle'
rowKey='id'
:components="drag(columns,'columns')"
:columns='columns'
:dataSource='dataSource'
:pagination='false'
:loading='loading'
:scroll="{x: '100%',y:'calc(100vh - 320px)'}"
:rowSelection='{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}'
@change='handleTableChange'>
<span slot="paramsManifestClick" slot-scope="text,record">
<a class="textName" :title="text" @click="paramsManifestClick(record)">
{{ text && text.length > 50 ? text.slice(0, 49) + '...' : text }}
</a>
</span>
<span slot="collectionCompletionTime" slot-scope="text,record">
<span class="textName" :title="record.finishTime">
{{record.finishTime ? record.finishTime : '-'}}
</span>
</span>
<span slot="operation" slot-scope="text,record">
<a class="text-operation" @click="configure(record)"
:disabled="record.isHistory == '1' ? true : false"
v-has="'params:config:list'">{{$t('configure')}}</a>
<a class="text-operation" @click="edit(record)"
:disabled="record.isHistory == '1' ? true : false"
v-has="'params:manifest:edit'">{{$t('edit')}}</a>
<a class="text-operation" @click="deleteLib(record)"
:disabled="record.isHistory == '1' ? true : false"
v-has="'params:manifest:delete'">{{$t('deleteLib')}}</a>
<!-- <a class="text-operation" @click="historicalVersion(record)" v-has="'params:manifest:history'">{{$t('historicalVersion')}}</a>-->
</span>
</a-table>
</div>
<!-- <div class="page">-->
<!-- <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>-->
<!-- 参数模板-->
<a-drawer
:visible="areaVisible"
:maskClosable="false"
@close="handleCancel"
:title="areaTitle"
width='850px'
style="height: 100%;overflow: auto;padding-bottom: 53px;"
placement="right"
:footer="null">
<parameter-template-add :url='url' ref='templateRef' v-if='areaVisible' @areaVisible='handleCancel'
:version='version'
:projectId='this.$route.query.parentId ? this.$route.query.parentId : this.$route.query.id'>
</parameter-template-add>
</a-drawer>
<!-- 配置-->
<configure ref="configureRef" :url='url' :itemId='itemId' :itemRow='itemRow'/>
<!-- 历史版本-->
<a-modal v-model="historicalVisible" :title="$t('historicalVersion')" width='750px' :footer="null">
<historical-version v-if='historicalVisible' :historicalRow='historicalRow'></historical-version>
</a-modal>
<!-- 复制参数模板-->
<a-drawer
class="show-drawer"
:maskClosable="false"
:visible="drawerVisible"
style="height: 100%;overflow: auto;padding-bottom: 53px;"
placement="right"
@close="drawerhandleCancel"
:title="$t('Copyparameterlist')"
width="850px"
:footer="null">
<project-collection-parameters v-if='drawerVisible' @areaVisible='drawerhandleCancel'
:templateTitle='templatetitle' @copysubmit='copysubmit'
:selectedRowKeyS='selectedRowKeys' :rowId='rowId' :version='version' :url='url'
:projectId='this.$route.query.parentId ? this.$route.query.parentId : this.$route.query.id'>
</project-collection-parameters>
</a-drawer>
</a-card>
</template>
<script>
import ImportFile from '@/components/ImportFile/index'
import ParameterTemplateAdd from '../../dialog/ParameterTemplateAdd'
import ProjectCollectionParameters from '../../dialog/ProjectCollectionParameters'
import HistoricalVersion from '../../dialog/historicalVersion'
import { getAction, postAction } from '@/api/manage'
import Configure from '../../dialog/configure'
import axios from 'axios'
import Vue from 'vue'
import { ACCESS_TOKEN } from '@/store/mutation-types'
import eventBUs from '@/common/event'
import store from '@/store/'
import { ResizeHeader, ResizeColumnProvide } from '@/mixins/header'
export default {
name: 'TaskParameterCollection',
components: {
ImportFile,
ParameterTemplateAdd,
Configure,
HistoricalVersion,
ProjectCollectionParameters
},
mixins:[ResizeHeader, ResizeColumnProvide],
data() {
return {
columns: [
{
title: this.$t('title'),
align: 'left',
dataIndex: 'title',
width: 280,
scopedSlots: { customRender: 'paramsManifestClick' }
},
{
title: this.$t('status'),
align: 'left',
width: 100,
ellipsis: true,
sorter:true,
dataIndex: 'state'
},
{
title: this.$t('parameterTemplateName'),
align: 'left',
width: 200,
ellipsis: true,
dataIndex: 'paramsTemplateName'
},
{
title: this.$t('relatedProjectVersion'),
align: 'left',
width: 150,
ellipsis: true,
sorter:true,
dataIndex: 'projectVersion'
},
{
title: this.$t('collectionCompletionTime'),
align: 'left',
dataIndex: 'finishTime',
width: 200,
ellipsis: true,
sorter:true,
scopedSlots: { customRender: 'collectionCompletionTime' }
},
{
title: this.$t('Version'),
align: 'left',
width: 100,
ellipsis: true,
sorter:true,
dataIndex: 'version'
},
{
title: this.$t('creator'),
align: 'left',
width: 110,
ellipsis: true,
dataIndex: 'createBy'
},
{
title: this.$t('created'),
align: 'left',
width: 200,
ellipsis: true,
sorter:true,
dataIndex: 'createTime'
},
{
title: this.$t('operation'),
align: 'left',
fixed: 'right',
width: localStorage.getItem('language') == 'zh-cn' ? 170:210,
scopedSlots: { customRender: 'operation' }
}
],
token: Vue.ls.get(ACCESS_TOKEN),
selectedRowKeys: [],
queryParam: {},
orderBy: '1',
orderByField: '',
url: {
list: 'params/manifest/page',
add: 'params/manifest/add',
edit: 'params/manifest/edit',
queryById: 'params/manifest/queryById',
deleteBatch: 'params/manifest/delete',
deleteAll: 'params/manifest/deleteBatch',
conAdd: 'params/config/addBatch',
conList: 'params/config/list',
changeExtension: 'params/manifest/changeExtension',
verifyConfig: 'params/manifest/verifyConfig',
configurelist: 'params/manifest/getConfigFlag'
},
loading: false,
dataSource: [],
areaVisible: false, // 弹框的控制
configureareaVisible: false, // 配置的彈框
pageNo: 1,
pageSize: 10,
total: 0,
selectedRowKeysArray: '',
templatetitle: '',
templatetitleId: '',
areaTitle:'',
rowId: '',
version: 0,
itemId: '', // 配置id
itemRow: {}, // 配置一行数据
configFlag: '',
historicalVisible: false,
historicalRow: {}, // 历史版本得数据
drawerVisible: false,
drawerVisibleitem: false,
titleTag: '',
selectedRowKeysvalArray: []
}
},
created() {
if (store.getters.userInfo) {
this.$socketPublicOne.dispatch('webSocketInit')//初始化ws
}
},
watch: {
'$socketPublicOne.state.msg': {
//处理接收到的消息
handler: function(res) {
let that = this
if (res.data == '1') {
this.getlist()
}
}
}
},
mounted() {
this.getlist()
},
methods: {
paramsManifestClick(item) {
let _this = this
// 先调取接口判断是否有配置信息
if (item.isHistory == '1'){
item.projectName = this.$route.query.projectName
let newUrl = _this.$router.resolve({
path: '/ParameterItemCollection',
query: {it: item.id,
...item
}
// projectName:this.$route.query.projectName
})
window.open(newUrl.href, '_blank')
}else{
getAction(this.url.verifyConfig, { paramsManifestId: item.id }).then((res) => {
if (res.result) {
// localStorage.setItem('paramsManifest', JSON.stringify(item))
item.projectName = this.$route.query.projectName
let newUrl = _this.$router.resolve({
path: '/ParameterItemCollection',
query: item
// projectName:this.$route.query.projectName
})
window.open(newUrl.href, '_blank')
} else {
_this.$message.warning(_this.$t('NoConfigurationNotStart'))
}
})
}
},
deleteLib(val) {
if (val.state === '已完成' || val.state === 'Finished' || val.state === '未收集' || val.state === 'Uncollected') {
let _this = this
this.$confirm({
content: _this.$t('ConfirmDelete'),
onOk() {
getAction(_this.url.deleteBatch, { id: val.id }).then((res) => {
if (res.success) {
_this.$message.success(_this.$t('OperationSuccessful'))
_this.getlist()
} else {
_this.$message.warning(_this.$t('operationFailed'))
}
})
}
})
} else {
this.$message.warning(this.$t('thisbuttonCompleted'))
}
},
// 历史版本
historicalVersion(historicalRow) {
this.historicalVisible = true
this.historicalRow = historicalRow
},
// 配置
configure(item) {
this.itemId = item.id
this.itemRow = item
this.$refs.configureRef.addModel(item.id, item)
},
handleCancel(val) {
this.areaVisible = false
this.getlist()
},
// 项目收集参数
drawerhandleCancel(val) {
this.drawerVisible = false
},
copysubmit() {
this.drawerVisible = false
this.getlist()
},
searchQuery() {
this.pageNo = 1
this.getlist()
},
searchReset() {
this.queryParam = {}
this.pageNo = 1
this.getlist()
},
onSelectChange(val, valArray) {
this.selectedRowKeys = val
this.selectedRowKeysArray = val.join(',')
this.selectedRowKeysvalArray = valArray
},
edit(edit) {
this.areaVisible = true
this.areaTitle = this.$t('editDetailList')
setTimeout(() => {
this.$refs.templateRef.editData(edit,1)
}, 50)
},
handleAdd() {
this.areaTitle = this.$t('addDetailList')
this.areaVisible = true
},
// 变更扩展
handleModule() {
let _this = this
if (this.selectedRowKeys.length == 0) {
this.$message.warning(_this.$t('pleaseSelectData'))
} else if (this.selectedRowKeys.length > 1) {
this.$message.warning(_this.$t('OnlyOneSelected'))
} else if (this.selectedRowKeysvalArray[0].state === '已完成' || this.selectedRowKeysvalArray[0].state === 'Finished') {
getAction(_this.url.changeExtension, { id: this.selectedRowKeys[0] }).then((res) => {
if (res.success) {
_this.$message.success(_this.$t('OperationSuccessful'))
_this.getlist()
} else {
_this.$message.warning(res.message)
this.selectedRowKeys = []
}
})
} else {
this.$message.warning(_this.$t('thisbuttonCompleted'))
}
},
handleDel() {
// 默认为0 可全部删除
let flag = 1
this.selectedRowKeysvalArray.forEach((item) => {
if (item.state !== '已完成' && item.state !== 'Finished' && item.state !== '未收集' && item.state !== 'Uncollected') {
flag = 0
}
})
if (flag) {
let param = {
ids: this.selectedRowKeys.join(',')
}
if (this.selectedRowKeys.length > 0) {
let _this = this
this.$confirm({
content: _this.$t('ConfirmBatchDeletion'),
onOk() {
postAction(_this.url.deleteAll, param).then((res) => {
if (res.success) {
_this.$message.success(_this.$t('OperationSuccessful'))
_this.getlist()
} else {
_this.$message.warning(_this.$t('operationFailed'))
this.selectedRowKeys = []
}
})
}
})
} else {
this.$message.warning(this.$t('selectLeastOne'))
}
} else {
this.$message.warning(this.$t('thisbuttonCompleted'))
}
},
handleCody() {
this.drawerVisible = true
},
pageOnChange(page, pageSize) {
this.pageNo = page
this.getlist()
},
SizeChange(page, pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.getlist()
},
handleTableChange(pagination, filters, sorter) {
this.orderBy = sorter.order == 'ascend' ? '1' : '2'
if(sorter.columnKey == 'projectVersion'){
this.orderByField = 'project_version'
} else if(sorter.columnKey == 'finishTime') {
this.orderByField = 'finish_time'
} else if(sorter.columnKey == 'createTime') {
this.orderByField = 'create_time'
} else{
this.orderByField = sorter.columnKey
}
this.getlist()
},
getlist() {
this.selectedRowKeys = []
let query = {
projectId: this.$route.query.parentId ? this.$route.query.parentId : this.$route.query.id,
// pageSize: this.pageSize,
// pageNo: this.pageNo,
orderBy: this.orderBy,
orderByField: this.orderByField,
...this.queryParam
}
this.loading = true
getAction(this.url.list, query).then((res) => {
if (res.success) {
if (res.result.current > 1 && res.result.records.length == 0) {
this.pageNo = res.result.current - 1
this.getlist()
return
}
this.total = res.result.total
this.dataSource = res.result.records || []
this.loading = false
} else {
this.loading = false
}
})
}
}
}
</script>
<style lang="less" scoped>
@import '~@assets/less/common.less';
/*/deep/ .ant-table td {*/
/* white-space: normal;*/
/*}*/
.doc-detail {
background: #fff;
height: 100%;
.Virtual-detail-header {
width: 100%;
height: 68px;
line-height: 68px;
padding: 0 32px 0 32px;
box-sizing: border-box;
display: flex;
justify-content: space-between;
border-bottom: 2px #eff1f3 solid;
background: #fff;
.Virtual-detail-title {
display: inline-block;
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
font-size: 20px;
font-weight: 400;
color: #040B29;
line-height: 68px;
}
.doc-detail-right {
width: 800px;
line-height: 68px;
display: flex;
}
}
.Virtual-detail-content {
padding: 0 38px 0 38px;
box-sizing: border-box;
font-size: 16px;
.box-title-text-add {
line-height: 1.4;
}
.title-text-add {
display: inline-block;
font-weight: 500;
margin-right: 16px;
height: 42px;
line-height: 42px;
}
}
}
.header-text {
font-size: 16px;
font-weight: 400;
height: 60px;
color: #000F16;
line-height: 40px;
}
.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;
}
.text-operation {
margin-right: 8px;
}
.page {
text-align: right;
margin-top: 20px;
}
.operator-text-left {
font-size: 14px;
margin-right: 20px;
background: #eff1f3;
padding: 8px 8px;
cursor: pointer;
border-radius: 4px;
}
///deep/ .add-padding {
// margin-left: -89px !important;
//}
.textName {
width: 100%;
overflow: hidden;
display: -webkit-box;
text-overflow: ellipsis;
/*! autoprefixer: off */
-webkit-box-orient: vertical;
-webkit-line-clamp: 1;
/*! autoprefixer: on;*/
text-justify: inter-ideograph;
word-break: break-all
}
::v-deep .ant-table-row:first-child {
background: #fff !important;
opacity: 0.95;
}
::v-deep .ant-table-body {
background: transparent !important;
}
///deep/.ant-table-thead > tr > th {
// font-weight: bolder;
//}
///deep/.ant-table-tbody > tr > td {
// color: #040B29 ;
//}
</style>
<style>
.box-input .ant-select-selection {
height: 38px !important;
}
.box-input .ant-select-selection__rendered {
line-height: 38px;
}
</style>
@@ -0,0 +1,630 @@
<!--平台件-->
<template>
<a-drawer
:title="title"
:maskClosable="false"
:width="1000"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<a-spin :spinning="confirmLoading">
<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('entryName')">{{$t('entryName')}}</span>
</div>
<a-form-model-item class="itemModel" prop="entryName">
<a-input class="box-input" :placeholder="$t('PleaseEnter')+$t('entryName')"
v-model="formInline.projectName"></a-input>
<!-- <a-select :placeholder="$t('PleaseSelect')+$t('modelName')"-->
<!-- @change="projectNameChange"-->
<!-- v-model="formInline.projectNameId">-->
<!-- <a-select-option v-for="(item, key) in projectNameList"-->
<!-- :key="key"-->
<!-- :value="item.id">-->
<!-- <span style="display: inline-block;width: 100%" :title=" item.projectName ">-->
<!-- {{ item.projectName}}-->
<!-- </span>-->
<!-- </a-select-option>-->
<!-- </a-select>-->
</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('brand')">{{$t('brand')}}</span>
</div>
<a-form-model-item class="itemModel" prop="brand">
<j-dict-select-tag class="box-input" v-model="formInline.targetMarket"
:placeholder="$t('PleaseSelect')+$t('brand')"
:type="'select'"
:triggerChange="false" :dictCode="'brand'"/>
</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="Required">*</span>
<span class="title-text-text" :title="$t('configurationItem')">{{$t('configurationItem')}}</span>
</div>
<a-form-model-item class="itemModel-multi" prop="configurationItem">
<a-input class="box-input" :placeholder="$t('PleaseEnter')+$t('configurationItem')"
v-model="formInline.configurationItem"></a-input>
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('explain')">{{$t('explain')}}</span>
</div>
<a-form-model-item class="itemModel" prop="explanation">
<a-textarea :placeholder="$t('pleaseEnter')+$t('explain')"
v-model="formInline.explanation"
: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="Required">*</span>-->
<!-- <span class="title-text-text" :title="$t('projectStatus')">{{$t('projectStatus')}}</span>-->
<!-- </div>-->
<!-- <a-form-model-item class="itemModel" prop="projectStatus">-->
<!-- <j-dict-select-tag class="box-input" v-model="formInline.projectStatus"-->
<!-- :disabled="disabled"-->
<!-- @input="handleInput('projectStatus')"-->
<!-- :placeholder="$t('PleaseSelect')+$t('projectStatus')"-->
<!-- :type="'select'"-->
<!-- :triggerChange="false" :dictCode="'project_status'"/>-->
<!-- </a-form-model-item>-->
<!-- </div>-->
<!-- </a-col>-->
<!-- <a-col :span="12">-->
<!-- <div class="box-title-text">-->
<!-- <div class="title-text">-->
<!-- <span class="title-text-text"-->
<!-- :title="$t('brand')">{{$t('brand')}}</span>-->
<!-- </div>-->
<!-- <a-form-model-item class="itemModel" :prop="'brand'">-->
<!-- <j-dict-select-tag v-model="formInline.brand"-->
<!-- :placeholder="$t('PleaseSelect')+$t('brand')"-->
<!-- :type="'select'"-->
<!-- :triggerChange="false" :dictCode="'brand'"/>-->
<!-- </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="Required">*</span>-->
<!-- <span class="title-text-text" :title="$t('StudioEngineer')">{{$t('StudioEngineer')}}</span>-->
<!-- </div>-->
<!-- <a-form-model-item class="itemModel-multi" :prop="'studioEngineerName'">-->
<!-- <PersonnelSelection :query="{db_field_name:'studioEngineer',db_field_txt:$t('StudioEngineer')}"-->
<!-- :isSingleChoice="true"-->
<!-- :personneQuery="formInline"-->
<!-- v-if="visible"-->
<!-- @change="PersonnelSelectionChange"-->
<!-- :disabled="disabled"-->
<!-- v-model="formInline.studioEngineerName"/>-->
<!-- </a-form-model-item>-->
<!-- </div>-->
<!-- </a-col>-->
<!-- <a-col :span="12">-->
<!-- <div class="box-title-text">-->
<!-- <div class="title-text">-->
<!-- <span class="title-text-text" :title="$t('certifiedEngineer')">{{$t('certifiedEngineer')}}</span>-->
<!-- </div>-->
<!-- <a-form-model-item class="itemModel-multi" :prop="'certificationEngineerName'">-->
<!-- <PersonnelSelection-->
<!-- :query="{db_field_name:'certificationEngineer',db_field_txt:$t('certifiedEngineer')}"-->
<!-- :personneQuery="formInline"-->
<!-- v-if="visible"-->
<!-- @change="PersonnelSelectionChange"-->
<!-- :disabled="disabled"-->
<!-- v-model="formInline.certificationEngineerName"/>-->
<!-- </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('DigitalPlatform')">{{$t('DigitalPlatform')}}</span>-->
<!-- </div>-->
<!-- <a-form-model-item class="itemModel" :prop="'digitalPlatform'">-->
<!-- <a-input class="box-input"-->
<!-- :disabled="disabled"-->
<!-- v-model="formInline.digitalPlatform"-->
<!-- :placeholder="$t('PleaseEnter')+$t('DigitalPlatform')"/>-->
<!-- </a-form-model-item>-->
<!-- </div>-->
<!-- </a-col>-->
<!-- <a-col :span="12">-->
<!-- <div class="box-title-text">-->
<!-- <div class="title-text">-->
<!-- <span class="title-text-text" :title="$t('ModelPlatform')">{{$t('ModelPlatform')}}</span>-->
<!-- </div>-->
<!-- <a-form-model-item class="itemModel" prop="vehiclePlatform">-->
<!-- <a-input class="box-input"-->
<!-- :disabled="disabled"-->
<!-- v-model="formInline.vehiclePlatform"-->
<!-- :placeholder="$t('PleaseEnter')+$t('ModelPlatform')"/>-->
<!-- </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('softwareVersion')">{{$t('softwareVersion')}}</span>-->
<!-- </div>-->
<!-- <a-form-model-item class="itemModel" :prop="'softwareVersion'">-->
<!-- <a-input class="box-input"-->
<!-- :disabled="disabled"-->
<!-- v-model="formInline.softwareVersion"-->
<!-- :placeholder="$t('PleaseEnter')+$t('softwareVersion')"/>-->
<!-- </a-form-model-item>-->
<!-- </div>-->
<!-- </a-col>-->
<!-- <a-col :span="12">-->
<!-- <div class="box-title-text">-->
<!-- <div class="title-text">-->
<!-- <span class="title-text-text"-->
<!-- :title="$t('dehicleDevelopmentPlan')">{{$t('dehicleDevelopmentPlan')}}</span>-->
<!-- </div>-->
<!-- <a-form-model-item class="itemModel" :prop="'vehicleDevelopmentPlan'">-->
<!-- <a-input class="box-input"-->
<!-- :disabled="disabled"-->
<!-- v-model="formInline.vehicleDevelopmentPlan"-->
<!-- :placeholder="$t('PleaseEnter')+$t('dehicleDevelopmentPlan')"/>-->
<!-- </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('certificationProgram')">{{$t('certificationProgram')}}</span>-->
<!-- </div>-->
<!-- <a-form-model-item class="itemModel" prop="attestationPlan">-->
<!-- <a-input class="box-input"-->
<!-- :disabled="disabled"-->
<!-- v-model="formInline.attestationPlan"-->
<!-- :placeholder="$t('PleaseEnter')+$t('certificationProgram')"/>-->
<!-- </a-form-model-item>-->
<!-- </div>-->
<!-- </a-col>-->
<!-- <a-col :span="12">-->
<!-- <div class="box-title-text">-->
<!-- <div class="title-text">-->
<!-- <span class="title-text-text"-->
<!-- :title="$t('configurationInformation')">{{$t('configurationInformation')}}</span>-->
<!-- </div>-->
<!-- <a-form-model-item class="itemModel" prop="ipdInfo">-->
<!-- <a-input class="box-input"-->
<!-- :disabled="disabled"-->
<!-- v-model="formInline.ipdInfo"-->
<!-- :placeholder="$t('PleaseEnter')+$t('configurationInformation')"/>-->
<!-- </a-form-model-item>-->
<!-- </div>-->
<!-- &lt;!&ndash; ^(ht|f)tp(s?)\:\/\/[0-9a-zA-Z]([-.\w]*[0-9a-zA-Z])*(:(0-9)*)*(\/?)([a-zA-Z0-9\-\.\?\,\'\/\\\+&amp;%\$#_]*)?$-->
<!-- &ndash;&gt;-->
<!-- </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('explain')">{{$t('explain')}}</span>-->
<!-- </div>-->
<!-- <a-form-model-item class="itemModel" prop="explanation">-->
<!-- <a-textarea :placeholder="$t('pleaseEnter')+$t('explain')"-->
<!-- v-model="formInline.explanation"-->
<!-- :rows="4"/>-->
<!-- </a-form-model-item>-->
<!-- </div>-->
<!-- </a-col>-->
<!-- </a-row>-->
</a-form-model>
</a-spin>
<div class="drawer-bootom-button">
<a-button style="margin-right: 8px" @click="handleCancel">{{$t('cancel')}}</a-button>
<a-button @click="handleSubmit" type="primary" :loading="confirmLoading">{{$t('submit')}}</a-button>
</div>
</a-drawer>
</template>
<script>
import PersonnelSelection from '@/components/PersonnelSelection/index'
import { getAction, postAction, downloadFile, putAction } from '@/api/manage'
import { mapGetters } from 'vuex'
export default {
name: 'addModel',
components: {
PersonnelSelection
},
props: ['url'],
data() {
return {
formInline: {},
confirmLoading: false,
visible: false,
yearNameDataList: [],
rules: {
ipdInfo: [
{
pattern: /(ht|f)tp(s?)\:\/\/[0-9a-zA-Z]([-.\w]*[0-9a-zA-Z])*(:(0-9)*)*(\/?)([a-zA-Z0-9\-\.\?\,\'\/\\\+&amp;%$#_]*)?/,
message: this.$t('pleaseEnterTheCorrectWebAddress')
},
{
max: 300,
message: this.$t('configurationInformation') + this.$t('cannotExceed') + 300 + this.$t('Characters'),
trigger: 'blur'
}
],
vehicleDevelopmentPlan: [
{
pattern: /(ht|f)tp(s?)\:\/\/[0-9a-zA-Z]([-.\w]*[0-9a-zA-Z])*(:(0-9)*)*(\/?)([a-zA-Z0-9\-\.\?\,\'\/\\\+&amp;%$#_]*)?/,
message: this.$t('pleaseEnterTheCorrectWebAddress')
},
{
max: 300,
message: this.$t('dehicleDevelopmentPlan') + this.$t('cannotExceed') + 300 + this.$t('Characters'),
trigger: 'blur'
}
],
explanation: [
{
max: 500,
message: this.$t('explain') + this.$t('cannotExceed') + 500 + this.$t('Characters'),
trigger: 'blur'
}
],
attestationPlan: [
{
pattern: /(ht|f)tp(s?)\:\/\/[0-9a-zA-Z]([-.\w]*[0-9a-zA-Z])*(:(0-9)*)*(\/?)([a-zA-Z0-9\-\.\?\,\'\/\\\+&amp;%$#_]*)?/,
message: this.$t('pleaseEnterTheCorrectWebAddress')
},
{
max: 300,
message: this.$t('certificationProgram') + this.$t('cannotExceed') + 300 + this.$t('Characters'),
trigger: 'blur'
}
],
vehiclePlatform: [
{
max: 100,
message: this.$t('ModelPlatform') + this.$t('cannotExceed') + 100 + this.$t('Characters'),
trigger: 'blur'
}
],
projectVersion:[
{
required: true,
message: this.$t('projectVersion') + this.$t('cannotEmpty'),
trigger: 'blur'
}
],
digitalPlatform: [
{
max: 100,
message: this.$t('DigitalPlatform') + this.$t('cannotExceed') + 100 + this.$t('Characters'),
trigger: 'blur'
}
],
softwareVersion: [
{
max: 300,
message: this.$t('softwareVersion') + this.$t('cannotExceed') + 300 + this.$t('Characters'),
trigger: 'blur'
}
],
projectNameId: [
{
required: true,
message: this.$t('entryName') + this.$t('cannotEmpty'),
trigger: 'change'
}
],
yearNameId: [
{
required: true,
message: this.$t('modelYear') + this.$t('cannotEmpty'),
trigger: 'change'
}
],
targetMarket: [
{
required: true,
message: this.$t('targetMarket') + this.$t('cannotEmpty'),
trigger: 'change'
}
],
projectStatus: [
{
required: true,
message: this.$t('projectStatus') + this.$t('cannotEmpty'),
trigger: 'change'
}
],
studioEngineerName: [
{
required: true,
message: this.$t('StudioEngineer') + this.$t('cannotEmpty'),
trigger: 'change'
},
{
max: 100,
message: this.$t('StudioEngineer') + this.$t('cannotExceed') + 100 + this.$t('Characters'),
trigger: 'change'
}
],
certificationEngineerName: [
{
max: 100,
message: this.$t('certifiedEngineer') + this.$t('cannotExceed') + 100 + this.$t('Characters'),
trigger: 'change'
}
]
},
disabled: false,
projectNameList: [],
title: ''
}
},
mounted() {
this.getNameList()
},
methods: {
...mapGetters(['userInfo']),
getNameList(value) {
getAction('project/projectNameInfoEO/list', {}).then((res) => {
if (res.success) {
this.projectNameList = res.result || []
if (this.title == this.$t('edit')) {
let content = this.projectNameList.filter(res => {
return res.id == value.projectNameId
})
this.yearNameDataList = content[0].yearNameDataList || []
this.formInline = value
this.formInline = { ...this.formInline }
}
} else {
this.projectNameList = []
}
})
},
addModel() {
this.visible = true
this.title = this.$t('add')
this.formInline = {}
this.getNameList()
this.formInline.studioEngineerName = this.userInfo().username
this.formInline.studioEngineer = this.userInfo().id
this.formInline.projectVersion = '00'
this.formInline = { ...this.formInline }
this.$nextTick(() => {
this.$refs.ruleForm.clearValidate()
})
},
editModel(value) {
this.visible = true
this.title = this.$t('edit')
this.getNameList(value)
this.$nextTick(() => {
this.$refs.ruleForm.clearValidate()
})
},
handleCancel() {
this.visible = false
},
handleSubmit() {
this.$refs.ruleForm.validate(valid => {
if (valid) {
let url = ''
let Action
if (this.formInline.id) {
url = this.url.edit
Action = putAction
} else {
url = this.url.add
Action = postAction
}
let query = JSON.parse(JSON.stringify(this.formInline))
Object.keys(query).forEach(res => {
if (query[res] && query[res] instanceof Array) {
query[res] = query[res].join(',')
}
})
this.confirmLoading = true
Action(url, query).then((res) => {
if (res.success) {
this.confirmLoading = false
this.$message.success(this.$t('OperationSuccessful'))
this.visible = false
this.$emit('addModelList')
// this.vdrClick()
} else {
this.$message.warning(res.message)
this.confirmLoading = false
}
})
}
})
},
// 跳转vdr
// vdrClick(){
// let _this = this
// this.$confirm({
// content: _this.$t('Rematchornot') + 'VDR',
// onOk() {
// let newUrl = _this.$router.resolve({
// path:'otaAuthentication',
// })
// window.open(newUrl.href, '_blank')
// }
// })
// },
handleInput(value) {
this.$nextTick(() => {
this.formInline = { ...this.formInline }
this.$refs.ruleForm.validateField([value])
})
},
PersonnelSelectionChange(value, id) {
this.formInline[value] = id
this.formInline = { ...this.formInline }
},
projectNameChange(value) {
this.formInline.yearNameId = undefined
let content = this.projectNameList.filter(res => {
return res.id == value
})
this.formInline.vehiclePlatform = content[0].vehiclePlatform || ''
this.yearNameDataList = content[0].yearNameDataList || []
this.formInline.digitalPlatform = content[0].digitalPlatform || ''
this.formInline = { ...this.formInline }
}
}
}
</script>
<style>
.formAdd .ant-form-item-label {
width: 130px;
}
.formAdd .ant-form-item-control-wrapper {
display: inline-block;
width: 100%;
}
/*.formAdd .ant-form-item {*/
/* margin-bottom: 20px;*/
/*}*/
.itemModel .ant-form-item-control-wrapper {
width: 100%;
}
.box-input .ant-select-selection--single {
height: 38px;
}
.box-input .ant-select-selection--multiple {
height: 38px;
}
.box-input .ant-select-selection__rendered {
line-height: 38px;
height: 38px;
}
.box-input .ant-select-selection--multiple .ant-select-selection__rendered > ul > li {
margin-top: 6px;
}
.box-input .ant-calendar-picker {
line-height: 38px;
height: 38px;
}
.box-input .ant-calendar-picker-input {
height: 38px;
}
.box-input .ant-input-number-input-wrap {
line-height: 38px;
height: 38px;
}
</style>
<style scoped>
.box-title-text {
line-height: 1.4;
display: flex;
/*align-items: center;*/
}
.title-text {
width: 114px;
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;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 130px);
display: inline-block;
margin-top: 2px;
height: 40px;
margin-bottom: 24px;
}
.Required {
color: red;
margin-right: 4px;
}
.title-text-text {
margin-top: 9px;
}
.formAdd {
margin-bottom: 40px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
width: 100%;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
z-index: 100;
background: #fff;
border-radius: 0 0 2px 2px;
}
</style>
<style>
.ant-input-disabled {
color: rgba(0, 0, 0, 0.65) !important;
}
</style>
@@ -0,0 +1,778 @@
<template>
<div>
<a-drawer
:title="title"
:maskClosable="false"
:width="900"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<a-spin :spinning="confirmLoading">
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text"
:title="$t('title')">{{$t('title')}}</span>
</div>
<a-form-model-item class="itemModel" prop="title">
<a-input class="box-input"
v-model='formInline.title'
:disabled="disabled"
:placeholder="$t('PleaseEnter')+$t('title')"/>
</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="Required">*</span>
<span class="title-text-text"
:title="$t('problemType')">{{$t('problemType')}}</span>
</div>
<a-form-model-item class="itemModel-multi" prop="problemType">
<j-dict-select-tag class="box-input" v-model="formInline.problemType"
:placeholder="$t('PleaseSelect')+$t('problemType')"
:type="'select'"
:triggerChange="false" :dictCode="'wen4_ti2_lei4_xing2'"/>
</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="'PS-issue'">{{'PS-issue'}}</span>
</div>
<a-form-model-item class="itemModel" prop="issue">
<a-input class="box-input"
v-model='formInline.psIssue'
:disabled="disabled"
:placeholder="$t('PleaseEnter')+'PS-issue'"/>
</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="Required">*</span>-->
<span class="title-text-text"
:title="$t('Relevantlawsregulations')">{{$t('Relevantlawsregulations')}}</span>
</div>
<a-form-model-item class="itemModel-multi" prop="creator">
<Standardselection
:query="{'db_field_txt':$t('Relevantlawsregulations')}"
:standard="formInline"
:disabled="false"
@input="Standardselectioninput"
@change="StandardselectionChange"
v-model="formInline.lawsName"/>
</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('RelatedItems')">{{$t('RelatedItems')}}</span>
</div>
<a-form-model-item class="itemModel" prop="contentTemplate">
<a-select allowClear
class="box-input"
v-model="formInline.projectId"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
showSearch
mode="multiple"
optionFilterProp="label"
:autoClearSearchValue="false"
:placeholder="$t('PleaseSelect')+$t('RelatedItems')">
<a-select-option v-for="(item, key) in projectNameList"
:key="key"
:label="item.projectName"
:value="item.id">
<span style="display: inline-block;width: 100%" :title=" item.projectName ">
{{ item.projectName}}
</span>
</a-select-option>
</a-select>
</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="Required">*</span>-->
<span class="title-text-text"
:title="$t('statisticalNodes')">{{$t('statisticalNodes')}}</span>
</div>
<a-form-model-item class="itemModel-multi" prop="creator">
<a-select :placeholder="$t('PleaseSelect')+$t('statisticalNodes')"
allowClear
show-search
mode="multiple"
class="box-input-search"
optionFilterProp="label"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
v-model="formInline.dutyTerritory">
<a-select-option v-for="(item, key) in firstLevelDutyTerritoryList"
:key="key"
:label="item.key"
:value="item.key">
<span style="display: inline-block;width: 100%" :title=" item.key ">
{{ item.key }}
</span>
</a-select-option>
</a-select>
</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('Problemstate')">{{$t('Problemstate')}}</span>
</div>
<a-form-model-item class="itemModel" prop="contentTemplate">
<a-select allowClear
class="box-input"
v-model="formInline.problemState"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
showSearch
optionFilterProp="label"
:autoClearSearchValue="false"
:placeholder="$t('PleaseSelect')+$t('Problemstate')">
<a-select-option v-for="(item, key) in ProblemstateList"
:label='item'
:key="key"
:value="item">
<span style="display: inline-block;width: 100%" :title=" item">
{{ item }}
</span>
</a-select-option>
</a-select>
</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="Required">*</span>-->
<span class="title-text-text"
:title="$t('descriptions')">{{$t('descriptions')}}</span>
</div>
<a-form-model-item class="itemModel" prop="descriptions">
<a-input class="box-input"
v-model='formInline.description'
:disabled="disabled"
:placeholder="$t('PleaseEnter')+$t('descriptions')"/>
</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="Required">*</span>-->
<span class="title-text-text"
:title="$t('documents')">{{$t('documents')}}</span>
</div>
<a-form-model-item class="itemModel" prop="fileLink">
<div v-for="(item,index) in formInline.fileLinkList" :key="index">
<a-input class="box-input"
style='width: 88%'
v-model='item.fileLink'
:disabled="disabled"
:placeholder="$t('PleaseEnter')+$t('Addresslink')"/>
<a-icon class="icon-text" @click="addClick(index)" style='margin-left: 10px;font-size: 18px;'
v-if="formInline.fileLinkList.length - 1 == index"
type="plus"/>
<a-icon class="icon-text" v-if="formInline.fileLinkList.length > 1 && formInline.fileLinkList.length - 1 !== index" style='margin-left: 10px;font-size: 18px;'
@click="deleteClick(index)"
type="minus"/>
</div>
<a-button type="primary" class="button-text"
@click="clickButtonToUpload('file')">
{{ (formInline.file === 'null' || formInline.file === '' ||
formInline.file == null) ? $t('Fileupload') : $t('viewUploadedFiles')
}}
</a-button>
</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="Required">*</span>-->
<span class="title-text-text"
:title="$t('progresstracking')">{{$t('progresstracking')}}</span>
</div>
<a-form-model-item class="itemModel" prop="progresstracking">
<div v-for="(item,index) in formInline.progressTrackingList" :key="index">
<!-- <span>{{item}}</span>-->
<a-input class="box-input"
style='width: 88%'
v-model='item.progressTracking'
:disabled="true"
:title='item.progressTracking'
:placeholder="$t('PleaseEnter')+$t('progresstracking')"/>
<a @click="addprogresstrackingClick(index)" style='margin-left: 10px' v-if="formInline.progressTrackingList.length - 1 == index">{{$t('newlyAdded')}}</a>
<a @click="deleteprogresstrackingClick(index,item)" v-if="formInline.progressTrackingList.length > 0" :disabled="disabled" style='margin-left: 10px' >{{$t('delete')}}</a>
</div>
</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="Required">*</span>-->
<span class="title-text-text"
:title="$t('conculsion')">{{$t('conculsion')}}</span>
</div>
<a-form-model-item class="itemModel" prop="conclusion">
<a-input class="box-input"
v-model='formInline.conclusion'
:disabled="disabled"
:placeholder="$t('PleaseEnter')+$t('conculsion')"/>
</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="Required">*</span>-->
<span class="title-text-text"
:title="$t('examineapproveevidence')">{{$t('examineapproveevidence')}}</span>
</div>
<a-form-model-item class="itemModel" prop="approvalEvidenceLink">
<div v-for="(item,index) in formInline.approvalEvidenceLinkList" :key="index">
<a-input class="box-input"
style='width: 88%'
v-model='item.approvalEvidenceLink'
:disabled="disabled"
:placeholder="$t('PleaseEnter')+$t('Addresslink')"/>
<a-icon class="icon-text" @click="addvidenceClick(index)" style='margin-left: 10px;font-size: 18px;'
v-if="formInline.approvalEvidenceLinkList.length - 1 == index"
type="plus"/>
<a-icon class="icon-text" v-if="formInline.approvalEvidenceLinkList.length > 1 && formInline.approvalEvidenceLinkList.length - 1 !== index"
style='margin-left: 10px;font-size: 18px;' @click="deletevidenceClick(index)"
type="minus" :disabled="disabled"/>
</div>
<a-button type="primary" class="button-text"
@click="clickButtonToUpload('approvalEvidence')">
{{ (formInline.approvalEvidence === 'null' || formInline.approvalEvidence === '' ||
formInline.approvalEvidence == null) ? $t('Fileupload') : $t('viewUploadedFiles')
}}
</a-button>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-spin>
<div class="drawer-bootom-button">
<a-button style="margin-right: 8px" @click="handleCancel">{{$t('cancel')}}</a-button>
<a-button @click="handleSubmit" v-if="!disabled" type="primary" :loading="confirmLoading">{{$t('submit')}}
</a-button>
</div>
</a-drawer>
<!-- <addModel ref="addModelRef" @addModelForm="addModelForm"/>-->
<a-modal
:title="$t('progresstracking')"
:width="600"
:visible="visibletrack"
:confirm-loading="confirmLoading"
:maskClosable="false"
@ok="handleOk"
@cancel="Cancel"
>
<a-form-model :model="formInlinetracking" class="formAdd" :rules="rulestracking" ref="ruleFormtracking">
<a-row :gutter="24">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('progresstracking')">
{{$t('progresstracking')}}</span>
</div>
<a-form-model-item class="itemModel" prop="progressTracking">
<a-textarea :placeholder="$t('pleaseEnter')+$t('progresstracking')"
v-model="formInlinetracking.progressTracking"
style="width: 90%"
:maxLength="500"
:rows="4"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-modal>
<uploadFile ref="uploadFile" @uploadSuccess="uploadSuccess"/>
</div>
</template>
<script>
// import defaultTemplate from './defaultTemplate'
// import solicitOpinions from './solicitOpinions'
// import releaseStandard from './releaseStandard'
// import industryTemplate from './industryTemplate'
// import addModel from './a/ddModel'
import Standardselection from '@/components/Standardselection/index'
import uploadFile from '@/components/uploadFile/file'
import { getAction, postAction,putAction, downloadFile } from '@/api/manage'
import moment from 'moment'
import { mapGetters } from 'vuex'
export default {
name: 'fillAdd',
components: {
// defaultTemplate,
// solicitOpinions,
// releaseStandard,
// industryTemplate,
// addModel
Standardselection,
uploadFile,
},
data() {
return {
rules: {
title: [
{
required: true,
message: this.$t('title') + this.$t('cannotEmpty'),
trigger: 'blur'
}
],
problemType: [
{
required: true,
message: this.$t('problemType') + this.$t('cannotEmpty'),
trigger: 'change'
}
],
},
visible: false,
visibletrack: false,
rulestracking:{
progressTracking: [
{
required: true,
message: this.$t('text') + this.$t('cannotEmpty'),
trigger: 'blur'
}
]
},
formInline: {
fileLinkList:[{}],
progressTrackingList:[{}],
approvalEvidenceLinkList:[{}],
dutyTerritory:undefined,
projectId:undefined,
problemState:undefined,
},
formInlinetracking:{},
confirmLoading: false,
title: '',
disabled: false,
isTrue: false,
chapterContentsList: [],
firstLevelDutyTerritoryList:[],
projectNameList: [],
ProblemstateList:[this.$t('red'),this.$t('yellow'),this.$t('green'),],
templateDisabled: false,
contentTemplateList: [
{
id: '1',
text: this.$t('defaultTemplate')
},
{
id: '2',
text: this.$t('newRequestCommentListTemplate')
},
{
id: '3',
text: this.$t('NewReleasedStandardTemplate')
},
{
id: '4',
text: this.$t('industryInformationDynamicTemplate')
}
],
index:'',
url: {
add: '/project/problemManagementEO/add',
edit: '/project/problemManagementEO/edit',
queryById: '/report/lawsMonthlyReportWriteEO/queryById'
}
}
},
mounted() {
},
methods: {
// bringInStandardInformationClick() {
// this.$refs.addModelRef.addModel()
// },
getNameList() {
getAction('/project/projectNameInfoEO/queryProjectNameList', {}).then((res) => {
if (res.success) {
this.projectNameList = res.result || []
} else {
this.projectNameList = []
}
})
},
addModelForm(value) {
this.$refs.defaultTemplateRef.getStandData(value)
},
getFirstLevelDutyTerritory() {
getAction('/sys/dictItem/getFirstLevelDutyTerritory', {}).then((res) => {
if (res.success) {
this.firstLevelDutyTerritoryList = res.result
} else {
this.firstLevelDutyTerritoryList = []
}
})
},
StandardselectionChange(value, id) {
this.formInline.lawsId = id
this.formInline = { ...this.formInline }
},
Standardselectioninput(val){
this.formInline.lawsName = val
},
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 }
},
...mapGetters(['userInfo']),
add() {
this.templateDisabled = false
this.getNameList()
this.getFirstLevelDutyTerritory()
this.title = this.$t('newlyAdded')
this.visible = true
this.disabled = false
this.formInline = {
fileLinkList:[{}],
progressTrackingList:[{}],
approvalEvidenceLinkList:[{}]
}
this.$nextTick(() => {
this.formInline = { ...this.formInline }
this.$refs.ruleForm.clearValidate()
})
},
edit(row) {
console.log(row)
this.getNameList()
this.getFirstLevelDutyTerritory()
this.title = this.$t('edit')
this.formInline = row
if(this.formInline.dutyTerritory != null){
this.formInline.dutyTerritory = this.formInline.dutyTerritory.split(',')
}else{
this.formInline.dutyTerritory = undefined
}
if(this.formInline.problemState == null){
this.formInline.problemState = undefined
}
if(this.formInline.progressTrackingList == null){
this.formInline.progressTrackingList = [{}]
}
if(this.formInline.approvalEvidenceLinkList == null){
this.formInline.approvalEvidenceLinkList = [{}]
}
if(this.formInline.fileLinkList == null){
this.formInline.fileLinkList = [{}]
}
if(this.formInline.projectId != null){
this.formInline.projectId = this.formInline.projectId.split(',')
}else{
this.formInline.projectId = undefined
}
console.log(this.formInline)
this.visible = true
this.disabled = false
this.templateDisabled = true
this.$nextTick(() => {
this.$refs.ruleForm.clearValidate()
})
},
addClick(index){
this.formInline.fileLinkList.splice(index + 1, 0, {})
this.formInline = { ...this.formInline }
},
deleteClick(index) {
this.formInline.fileLinkList.splice(index, 1)
this.formInline = { ...this.formInline }
},
addvidenceClick(index){
this.formInline.approvalEvidenceLinkList.splice(index + 1, 0, {})
this.formInline = { ...this.formInline }
},
deletevidenceClick(index) {
this.formInline.approvalEvidenceLinkList.splice(index, 1)
this.formInline = { ...this.formInline }
},
addprogresstrackingClick(index){
this.index = index
this.formInlinetracking = {}
this.visibletrack = true
this.$nextTick(() => {
this.formInlinetracking = { ...this.formInlinetracking }
this.isTrue = true
this.$refs.ruleForm.clearValidate()
})
},
deleteprogresstrackingClick(index,item) {
if(item.progressTracking && item.progressTracking != ''){
if(index == 0){
item.progressTracking = ''
}else{
this.formInline.progressTrackingList.splice(index, 1)
}
}
this.formInline = { ...this.formInline }
},
handleCancel() {
this.visible = false
},
Cancel(){
this.visibletrack = false
this.formInlinetracking = {}
this.$refs.ruleFormtracking.clearValidate()
},
handleOk(){
console.log(this.formInlinetracking)
let time = moment(new Date()).format('YYYY-MM-DD HH:mm:ss')
this.$refs.ruleFormtracking.validate(valid => {
if (valid) {
let text = this.userInfo().username + ' ' + time + ' ' + this.formInlinetracking.progressTracking
this.formInline.progressTrackingList.forEach((item,index) => {
console.log(item.progressTracking)
if(!item.progressTracking){
this.formInline.progressTrackingList.splice(0,1)
}
})
this.formInline.progressTrackingList.splice(this.index+1, 1, {progressTracking:text})
this.visibletrack = false
}
})
},
handleSubmit() {
console.log(this.formInline)
this.$refs.ruleForm.validate(valid => {
if (valid) {
this.confirmLoading = true
let url = ''
let action = ''
if (this.title == this.$t('newlyAdded')) {
url = this.url.add
action = postAction
} else {
url = this.url.edit
action = putAction
}
// Object.keys(formInline).forEach(res => {
// if (formInline[res] && formInline[res] instanceof Array) {
// formInline[res] = formInline[res].join(',')
// }
// })
let formInline = JSON.parse(JSON.stringify(this.formInline))
if(this.formInline.dutyTerritory && this.formInline.dutyTerritory instanceof Array){
this.formInline.dutyTerritory = this.formInline.dutyTerritory.join(',')
}
if(this.formInline.projectId && this.formInline.projectId instanceof Array){
this.formInline.projectId = this.formInline.projectId.join(',')
}
// let fileLinkList = []
// let approvalEvidenceLinkList = []
// let progressTrackingList = []
// if(this.formInline.fileLinkList){
// this.formInline.fileLinkList.forEach(item => {
// if(item.fileLink){
// fileLinkList.push(item.fileLink)
// }
// })
// this.formInline.fileLinkList = fileLinkList
// }
// if(this.formInline.approvalEvidenceLinkList){
// this.formInline.approvalEvidenceLinkList.forEach(item => {
// if(item.approvalEvidenceLink){
// approvalEvidenceLinkList.push(item.approvalEvidenceLink)
// }
// })
// this.formInline.approvalEvidenceLinkList = approvalEvidenceLinkList
// }
// if(this.formInline.progressTrackingList){
// this.formInline.progressTrackingList.forEach(item => {
// if(item.progressTracking){
// progressTrackingList.push(item.progressTracking)
// }
// })
// this.formInline.progressTrackingList = progressTrackingList
// }
delete this.formInline.lawsName
let query = {
// problemManagementEO:formInline
...this.formInline
}
action(url, query).then((res) => {
if (res.success) {
this.$message.success(this.$t('OperationSuccessful'))
this.visible = false
this.confirmLoading = false
this.$emit('addModelForm')
} else {
this.confirmLoading = false
this.$message.warning(this.$t('operationFailed'))
}
})
}
})
}
}
}
</script>
<style>
.ant-select-disabled {
color: rgba(0, 0, 0, 0.65);
}
.ant-input-disabled {
color: rgba(0, 0, 0, 0.65) !important;
}
</style>
<style scoped>
.box-title-text {
line-height: 1.4;
display: flex;
}
.title-text {
width: 114px;
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: 42px;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 130px);
display: inline-block;
margin-top: 2px;
}
.title-text-text {
margin-top: 9px;
}
.formAdd {
margin-bottom: 40px;
}
.Required {
color: red;
margin-right: 4px;
}
.title-text-text {
margin-top: 9px;
}
.formAdd {
margin-bottom: 40px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
z-index: 100;
width: 100%;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
.button-text {
height: 38px;
margin-top: 4px;
}
::v-deep .ant-select-tree-treenode-switcher-close {
width: 255px;
}
::v-deep .ant-select-tree-node-content-wrapper {
float: right;
margin-top: -2px !important;
}
::v-deep .ant-select-tree-title {
width: 100%;
display: block;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
word-break: break-word;
}
</style>
@@ -0,0 +1,667 @@
<template>
<a-modal
:title="$t('batchSettingInformation')"
:width="1200"
:visible="visible"
:confirm-loading="confirmLoading"
:maskClosable="false"
@ok="handleOk"
@cancel="handleCancel"
>
<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="title-text-text" :title="$t('certificationType')">{{$t('certificationType')}}</span>
</div>
<a-form-model-item class="itemModel-multi">
<j-multi-select-tag class="box-input" v-model="formInline.attestationType"
:placeholder="$t('PleaseSelect')+$t('certificationType')"
:type="'select'"
:triggerChange="false" :dictCode="'attestation_type'"/>
<!-- <j-dict-select-tag class="box-input" v-model="formInline.attestationType"-->
<!-- @input="handleInput('attestationType')"-->
<!-- :placeholder="$t('PleaseSelect')+$t('certificationType')"-->
<!-- :type="'select'"-->
<!-- :triggerChange="false" dictCode="attestation_type"/>-->
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('certificationLevel')">{{$t('certificationLevel')}}</span>
</div>
<a-form-model-item class="itemModel-multi">
<j-multi-select-tag class="box-input" v-model="formInline.attestationRank"
:placeholder="$t('PleaseSelect')+$t('certificationLevel')"
:type="'select'"
:triggerChange="false" :dictCode="'attestation_rank'"/>
<!-- <j-dict-select-tag class="box-input" v-model="formInline.attestationRank"-->
<!-- @input="handleInput('attestationRank')"-->
<!-- :placeholder="$t('PleaseSelect')+$t('certificationLevel')"-->
<!-- :type="'select'"-->
<!-- :triggerChange="false" dictCode="attestation_rank"/>-->
</a-form-model-item>
</div>
</a-col>
</a-row>
<a-row :gutter="24" v-if="this.code == '0'">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('statisticalNodes')">{{$t('statisticalNodes')}}</span>
</div>
<a-form-model-item class="itemModel-multi">
<a-select :placeholder="$t('PleaseSelect')+$t('statisticalNodes')"
class="box-input"
optionFilterProp="label"
@change="DutyDepartChange"
mode="multiple"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
v-model="formInline.dutyDepart">
<a-select-option v-for="(item, key) in firstLevelDutyTerritoryList"
:key="key"
:label="item.key"
:value="item.key">
<span style="display: inline-block;width: 100%" :title=" item.key ">
{{ item.key }}
</span>
</a-select-option>
</a-select>
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('areaOfResponsibility')">{{$t('areaOfResponsibility')}}</span>
</div>
<a-form-model-item class="itemModel-multi">
<a-select :placeholder="$t('PleaseSelect')+$t('areaOfResponsibility')"
class="box-input"
optionFilterProp="label"
mode="multiple"
@change="dutyTerritoryChange"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
v-model="formInline.dutyTerritory">
<a-select-option v-for="(item, key) in dutyTerritoryList"
:key="key"
:label="item.itemText"
:value="item.itemValue">
<span style="display: inline-block;width: 100%" :title=" item.itemText ">
{{ item.itemText }}
</span>
</a-select-option>
</a-select>
<!-- <j-multi-select-tag class="box-input" v-model="formInline.dutyTerritory"-->
<!-- @change="dutyTerritoryChange"-->
<!-- :placeholder="$t('PleaseSelect')+$t('areaOfResponsibility')"-->
<!-- :type="'select'"-->
<!-- :triggerChange="false" :dictCode="'duty_territory'"/>-->
</a-form-model-item>
</div>
</a-col>
</a-row>
<a-row :gutter="24" v-if="this.code == '0'">
<a-col :span="12" v-if="this.code == '0'">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('regulatoryEngineer')">{{$t('regulatoryEngineer')}}</span>
</div>
<a-form-model-item class="itemModel" prop="regulationOwnerId">
<a-select :placeholder="$t('PleaseSelect')+$t('regulatoryEngineer')"
class="box-input"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
allowClear
v-model="formInline.regulationOwnerId">
<a-select-option v-for="(item, key) in regulatoryEngineerList"
:key="key"
:value="item.value">
<span style="display: inline-block;width: 100%" :title=" item.name">
{{ item.name }}
</span>
</a-select-option>
</a-select>
<!-- <j-dict-select-tag class="box-input" v-model="formInline.designDuty"-->
<!-- :disabled="formInline.roleCode == 0 ? false : true"-->
<!-- @input="handleInput('designDuty')"-->
<!-- :placeholder="$t('PleaseSelect')+$t('personLiable')"-->
<!-- :type="'select'"-->
<!-- :triggerChange="false" :dictCode="'ze2_ren4_ren2'"/>-->
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('engineeringInterfacePerson')">{{$t('engineeringInterfacePerson')}}</span>
</div>
<a-form-model-item class="itemModel" prop="designDutyId">
<a-select :placeholder="$t('cannotSetResponsibilityAreas')"
class="box-input"
allowClear
:getPopupContainer="triggerNode=> triggerNode.parentNode"
v-model="formInline.engineeringInterfacePerson">
<a-select-option v-for="(item, key) in engineeringInterfacePersonList"
:key="key"
:value="item.value">
<span style="display: inline-block;width: 100%" :title=" item.name ">
{{ item.name }}
</span>
</a-select-option>
</a-select>
<!-- <PersonnelSelection-->
<!-- :query="{db_field_name:'engineeringInterfacePerson',db_field_txt:$t('engineeringInterfacePerson')}"-->
<!-- :isSingleChoice="true"-->
<!-- :personneQuery="formInline"-->
<!-- v-if="visible"-->
<!-- @change="PersonnelSelectionChange"-->
<!-- v-model="formInline.engineeringInterfacePersonName"/>-->
<!-- <j-dict-select-tag class="box-input" v-model="formInline.designDuty"-->
<!-- :disabled="formInline.roleCode == 0 ? false : true"-->
<!-- @input="handleInput('designDuty')"-->
<!-- :placeholder="$t('PleaseSelect')+$t('personLiable')"-->
<!-- :type="'select'"-->
<!-- :triggerChange="false" :dictCode="'ze2_ren4_ren2'"/>-->
</a-form-model-item>
</div>
</a-col>
</a-row>
<div class="header-text">
&nbsp;{{$t('confirmationOfDesignConformity')}}
</div>
<a-row :gutter="24">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('personLiable')">{{$t('personLiable')}}</span>
</div>
<a-form-model-item class="itemModel-multi" prop="designDutyIdName">
<PersonnelSelection :query="{db_field_name:'designDutyId',db_field_txt:$t('personLiable')}"
:isSingleChoice="true"
:personneQuery="formInline"
v-if="visible"
@change="PersonnelSelectionChange"
v-model="formInline.designDutyIdName"/>
<!-- <j-dict-select-tag class="box-input" v-model="formInline.designDuty"-->
<!-- :disabled="formInline.roleCode == 0 ? false : true"-->
<!-- @input="handleInput('designDuty')"-->
<!-- :placeholder="$t('PleaseSelect')+$t('personLiable')"-->
<!-- :type="'select'"-->
<!-- :triggerChange="false" :dictCode="'ze2_ren4_ren2'"/>-->
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('cutoffTime')">{{$t('cutoffTime')}}</span>
</div>
<a-form-model-item class="itemModel" :prop="'designDueDate'">
<a-date-picker class="box-input"
:placeholder="$t('PleaseSelect')+$t('cutoffTime')"
@change="dateChange({db_field_name:'designDueDate'})"
format="YYYY-MM-DD"
:getCalendarContainer="(trigger) => trigger.parentNode"
v-model="formInline.designDueDate"
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="title-text-text"-->
<!-- :title="$t('Sponsor')">{{$t('Sponsor')}}</span>-->
<!-- </div>-->
<!-- <a-form-model-item class="itemModel" prop="designInitiatorId">-->
<!-- <a-select :placeholder="$t('PleaseSelect')+$t('Sponsor')"-->
<!-- :disabled="formInline.roleCodeIndex == 0 ? false : true"-->
<!-- :getPopupContainer="triggerNode=> triggerNode.parentNode"-->
<!-- class="box-input"-->
<!-- allowClear-->
<!-- v-model="formInline.designInitiatorId">-->
<!-- <a-select-option v-for="(item, key) in designInitiatorList"-->
<!-- :key="key"-->
<!-- :value="item.value">-->
<!-- <span style="display: inline-block;width: 100%" :title=" item.name ">-->
<!-- {{ item.name }}-->
<!-- </span>-->
<!-- </a-select-option>-->
<!-- </a-select>-->
<!-- &lt;!&ndash; <j-dict-select-tag class="box-input" v-model="formInline.designInitiator"&ndash;&gt;-->
<!-- &lt;!&ndash; :disabled="formInline.roleCode == 0 ? false : true"&ndash;&gt;-->
<!-- &lt;!&ndash; @input="handleInput('designInitiator')"&ndash;&gt;-->
<!-- &lt;!&ndash; :placeholder="$t('PleaseSelect')+$t('Sponsor')"&ndash;&gt;-->
<!-- &lt;!&ndash; :type="'select'"&ndash;&gt;-->
<!-- &lt;!&ndash; :triggerChange="false" :dictCode="'fa1_qi3_ren2'"/>&ndash;&gt;-->
<!-- </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('typeOfDeliverables')">{{$t('typeOfDeliverables')}}</span>
</div>
<a-form-model-item class="itemModel-multi" prop="typeOfDeliverables">
<a-tree-select
tree-node-filter-prop="title"
v-model="formInline.designDeliverableType"
:maxTagCount="1"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
class="box-input"
style="width: 100%"
:tree-data="DeliverableTreeList"
tree-checkable
:placeholder="$t('PleaseSelect')+$t('typeOfDeliverables')"
/>
<!-- <j-dict-select-tag class="box-input" v-model="formInline.designDeliverableType"-->
<!-- @input="handleInput('designDeliverableType')"-->
<!-- :placeholder="$t('PleaseSelect')+$t('typeOfDeliverables')"-->
<!-- :type="'select'"-->
<!-- :triggerChange="false" :dictCode="'deliverable_template'"/>-->
</a-form-model-item>
</div>
</a-col>
</a-row>
<div class="header-text">
&nbsp;{{$t('verificationAndConformityconfirmation')}}
</div>
<a-row :gutter="24">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('personLiable')">{{$t('personLiable')}}</span>
</div>
<a-form-model-item class="itemModel-multi" prop="verifyDutyIdName">
<PersonnelSelection :query="{db_field_name:'verifyDutyId',db_field_txt:$t('personLiable')}"
:isSingleChoice="true"
:personneQuery="formInline"
v-if="visible"
@change="PersonnelSelectionChange"
v-model="formInline.verifyDutyIdName"/>
<!-- <j-dict-select-tag class="box-input" v-model="formInline.verifyDuty"-->
<!-- :disabled="formInline.roleCode == 0 ? false : true"-->
<!-- @input="handleInput('verifyDuty')"-->
<!-- :placeholder="$t('PleaseSelect')+$t('personLiable')"-->
<!-- :type="'select'"-->
<!-- :triggerChange="false" :dictCode="'ze2_ren4_ren2'"/>-->
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('cutoffTime')">{{$t('cutoffTime')}}</span>
</div>
<a-form-model-item class="itemModel" :prop="'verifyDueDate'">
<a-date-picker class="box-input"
:placeholder="$t('PleaseSelect')+$t('cutoffTime')"
@change="dateChange({db_field_name:'verifyDueDate'})"
format="YYYY-MM-DD"
:getCalendarContainer="(trigger) => trigger.parentNode"
v-model="formInline.verifyDueDate"
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="title-text-text"-->
<!-- :title="$t('Sponsor')">{{$t('Sponsor')}}</span>-->
<!-- </div>-->
<!-- <a-form-model-item class="itemModel" prop="verifyInitiatorId">-->
<!-- <a-select :placeholder="$t('PleaseSelect')+$t('Sponsor')"-->
<!-- class="box-input"-->
<!-- allowClear-->
<!-- :getPopupContainer="triggerNode=> triggerNode.parentNode"-->
<!-- :disabled="formInline.roleCodeIndex == 0 ? false : true"-->
<!-- v-model="formInline.verifyInitiatorId">-->
<!-- <a-select-option v-for="(item, key) in verifyInitiatorList"-->
<!-- :key="key"-->
<!-- :value="item.value">-->
<!-- <span style="display: inline-block;width: 100%" :title=" item.name ">-->
<!-- {{ item.name }}-->
<!-- </span>-->
<!-- </a-select-option>-->
<!-- </a-select>-->
<!-- &lt;!&ndash; <j-dict-select-tag class="box-input" v-model="formInline.verifyInitiator"&ndash;&gt;-->
<!-- &lt;!&ndash; :disabled="formInline.roleCode == 0 ? false : true"&ndash;&gt;-->
<!-- &lt;!&ndash; @input="handleInput('verifyInitiator')"&ndash;&gt;-->
<!-- &lt;!&ndash; :placeholder="$t('PleaseSelect')+$t('Sponsor')"&ndash;&gt;-->
<!-- &lt;!&ndash; :type="'select'"&ndash;&gt;-->
<!-- &lt;!&ndash; :triggerChange="false" :dictCode="'fa1_qi3_ren2'"/>&ndash;&gt;-->
<!-- </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('typeOfDeliverables')">{{$t('typeOfDeliverables')}}</span>
</div>
<a-form-model-item class="itemModel-multi" prop="verifyDeliverableType">
<a-tree-select
tree-node-filter-prop="title"
v-model="formInline.verifyDeliverableType"
:maxTagCount="1"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
class="box-input"
style="width: 100%"
:tree-data="DeliverableTreeList"
tree-checkable
:placeholder="$t('PleaseSelect')+$t('typeOfDeliverables')"
/>
<!-- <j-dict-select-tag class="box-input" v-model="formInline.verifyDeliverableType"-->
<!-- :disabled="formInline.taskAffirmStatus != 'Not started' && !formInline.verifyDeliverableType ? true : false"-->
<!-- @input="handleInput('verifyDeliverableType')"-->
<!-- :placeholder="$t('PleaseSelect')+$t('typeOfDeliverables')"-->
<!-- :type="'select'"-->
<!-- :triggerChange="false" :dictCode="'deliverable_template'"/>-->
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-modal>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
import PersonnelSelection from '@/components/PersonnelSelection/index'
import moment from 'moment'
export default {
name: 'batSetting',
props: ['url'],
components: {
PersonnelSelection
},
data() {
return {
visible: false,
confirmLoading: false,
designDutyList: [],
DeliverableTreeList: [],
formInline: {},
rules: {},
ids: [],
code: '',
dutyTerritoryList: [],
regulatoryEngineerList: [],
engineeringInterfacePersonList: [],
firstLevelDutyTerritoryList: []
}
},
mounted() {
},
methods: {
getFirstLevelDutyTerritory() {
getAction('/sys/dictItem/getFirstLevelDutyTerritory', {}).then((res) => {
if (res.success) {
this.firstLevelDutyTerritoryList = res.result
} else {
this.firstLevelDutyTerritoryList = []
}
})
},
DutyDepartChange(event) {
this.formInline.dutyTerritory = []
this.formInline = { ...this.formInline }
this.getDutyTerritory(event.join(','))
},
getDutyTerritory(row) {
let query = {
dutyDepart: row
}
getAction('/sys/dict/getDutyTeryByDD', query).then((res) => {
if (res.success) {
this.dutyTerritoryList = res.result || []
} else {
this.dutyTerritoryList = []
}
})
},
dutyTerritoryChange(event) {
this.formInline.regulationOwnerId = undefined
this.formInline.engineeringInterfacePerson = undefined
this.formInline = { ...this.formInline }
this.queryPersonByProject(event.join(','))
},
queryPersonByProject(row) {
let query = {
projectId: this.$route.query.id,
dutyTerritory: row.dutyTerritory || row
}
getAction('/project/projectRelatedPersonnel/queryPersonByProjectId', query).then((res) => {
if (res.success) {
this.regulatoryEngineerList = res.result.lawEngineerList || [] //法规工程师
this.engineeringInterfacePersonList = res.result.engineeringInterfacePersonList || [] //工程接口人
// if (this.regulatoryEngineerList.length == 1) {
// this.formInline.regulationOwnerId = this.regulatoryEngineerList[0].value
// }
// if (this.engineeringInterfacePersonList.length == 1) {
// this.formInline.engineeringInterfacePerson = this.engineeringInterfacePersonList[0].value
// }
// this.formInline = {...this.formInline}
}
})
},
PersonnelSelectionChange(value, id) {
this.formInline[value] = id
this.formInline = { ...this.formInline }
},
edit(data, code, content) {
this.visible = true
this.regulatoryEngineerList = []
this.dutyTerritoryList = []
this.engineeringInterfacePersonList = []
this.getDeliverableTree()
this.getFirstLevelDutyTerritory()
this.code = code
this.$nextTick(() => {
this.ids = data || []
this.formInline = {}
if (content && code == '0') {
// this.formInline.dutyTerritory = content.dutyTerritory
// this.queryPersonByProject(content)
}
this.formInline = { ...this.formInline }
})
},
handleOk() {
if (this.formInline.dutyTerritory) {
this.handleOkTwo()
} else {
this.handleOkOne()
}
},
getDeliverableTree() {
getAction('/sys/category/getDeliverableTree', {}).then((res) => {
if (res.success) {
this.DeliverableTreeList = res.result
} else {
this.DeliverableTreeList = []
}
})
},
handleOkOne() {
let ids = JSON.parse(JSON.stringify(this.ids))
let formInline = JSON.parse(JSON.stringify(this.formInline))
Object.keys(formInline).forEach(res => {
if (formInline[res] && formInline[res] instanceof Array) {
formInline[res] = formInline[res].join(',')
}
})
let query = {
ids: ids.join(','),
...formInline
}
this.confirmLoading = true
postAction(this.url.setBatch, query).then((res) => {
if (res.success) {
this.$message.success(this.$t('OperationSuccessful'))
this.visible = false
this.confirmLoading = false
this.$emit('batSettingList')
} else {
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
}
})
},
handleOkTwo() {
let _this = this
this.$confirm({
content: _this.$t('batchmodify'),
onOk() {
let ids = JSON.parse(JSON.stringify(_this.ids))
let formInline = JSON.parse(JSON.stringify(_this.formInline))
Object.keys(formInline).forEach(res => {
if (formInline[res] && formInline[res] instanceof Array) {
formInline[res] = formInline[res].join(',')
}
})
let query = {
ids: ids.join(','),
...formInline
}
_this.confirmLoading = true
postAction(_this.url.setBatch, query).then((res) => {
if (res.success) {
_this.$message.success(_this.$t('OperationSuccessful'))
_this.visible = false
_this.confirmLoading = false
_this.$emit('batSettingList')
} else {
_this.$message.warning(_this.$t('operationFailed'))
_this.confirmLoading = false
}
})
}
})
},
handleCancel() {
this.formInline = {}
this.visible = false
},
handleInput(value) {
this.$nextTick(() => {
this.formInline = { ...this.formInline }
this.$refs.ruleForm.validateField([value])
})
},
dateChange(item) {
this.formInline[item.db_field_name] = this.formInline[item.db_field_name] ? moment(this.formInline[item.db_field_name]).format('YYYY-MM-DD') : ''
}
}
}
</script>
<style>
.formAdd .ant-form-item-label {
width: 130px;
}
.formAdd .ant-form-item-control-wrapper {
display: inline-block;
width: 100%;
}
/*.formAdd .ant-form-item {*/
/* margin-bottom: 20px;*/
/*}*/
.itemModel .ant-form-item-control-wrapper {
width: 100%;
}
.box-input .ant-select-selection--single {
height: 38px;
}
.box-input .ant-select-selection--multiple {
height: 38px;
}
.box-input .ant-select-selection__rendered {
line-height: 38px;
height: 38px;
}
.box-input .ant-select-selection--multiple .ant-select-selection__rendered > ul > li {
margin-top: 6px;
}
.box-input .ant-calendar-picker {
line-height: 38px;
height: 38px;
}
.box-input .ant-calendar-picker-input {
height: 38px;
}
.box-input .ant-input-number-input-wrap {
line-height: 38px;
height: 38px;
}
.box-input .ant-calendar-picker-input {
padding: 4px 30px 4px 11px;
}
</style>
<style scoped>
.box-title-text {
line-height: 1.4;
display: flex;
}
.title-text {
width: 174px;
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: 42px;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 130px);
display: inline-block;
margin-top: 2px;
}
.title-text-text {
margin-top: 9px;
}
.formAdd {
margin-bottom: 40px;
}
</style>
@@ -0,0 +1,216 @@
<!--批量当前状态-->
<template>
<a-modal
:title="title"
:width="700"
:visible="visible"
:confirm-loading="confirmLoading"
:maskClosable="false"
@ok="handleOk"
@cancel="visible = false"
>
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24">
<div class="headerText">
{{this.$t('redSchedule')}}<br/>
{{this.$t('yellowSchedule')}}<br/>
{{this.$t('greenRequirements')}}<br/>
{{this.$t('blueUndeterminedState')}}
</div>
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('CurrentProjectStatusEvaluation')">{{$t('CurrentProjectStatusEvaluation')}}</span>
</div>
<a-form-model-item class="itemModel" prop="conditionAssessment">
<a-select
:disabled="disabled"
v-model="formInline.conditionAssessment"
:placeholder="$t('PleaseSelect')+$t('CurrentProjectStatusEvaluation')">
<a-select-option :value="'1'">
<span style="display: inline-block;width: 100%">
{{ $t('red') }}
</span>
</a-select-option>
<a-select-option :value="'2'">
<span style="display: inline-block;width: 100%">
{{ $t('yellow') }}
</span>
</a-select-option>
<a-select-option :value="'3'">
<span style="display: inline-block;width: 100%">
{{ $t('green') }}
</span>
</a-select-option>
<a-select-option :value="'4'" disabled>
<span style="display: inline-block;width: 100%">
{{ $t('blue') }}
</span>
</a-select-option>
</a-select>
</a-form-model-item>
</div>
</a-col>
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('remarks')">{{$t('remarks')}}</span>
</div>
<a-form-model-item class="itemModel" prop="remark">
<a-textarea
:placeholder="$t('remarks')"
:disabled="disabled"
v-model="formInline.remark" :rows="4"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-modal>
</template>
<script>
import { postAction, putAction, getAction } from '@/api/manage'
export default {
name: 'TaskListModel',
data() {
return {
formInline: {},
rules: {},
selectionRowsArray:[],
projectLawsInventoryIds:[],
roleCodes:[],
visible: false,
title:'',
confirmLoading: false,
studioList: [],
disabled: false,
url: {
edit: '/project/projectTaskInventoryEO/edit',
addOrUpdate: '/project/projectTaskInventoryConditionAssessmentEO/addOrUpdate',
list: '/project/projectTaskInventoryConditionAssessmentEO/list'
}
}
},
mounted() {
},
methods: {
getData(val) {
this.visible = true
this.title = this.$t('BatchChangeStatus')
this.selectionRowsArray = val
this.$nextTick(() => {
this.formInline = {}
this.$refs.ruleForm.clearValidate()
})
},
getList(val) {
getAction(this.url.list, { projectLawsInventoryId: val.projectLawsInventoryId }).then((res) => {
if (res.success) {
this.studioList = res.result || []
} else {
this.studioList = []
}
})
},
handleInput(value) {
this.$nextTick(() => {
this.formInline = { ...this.formInline }
this.$refs.ruleForm.validateField([value])
})
},
handleOk() {
if (this.disabled) {
this.visible = false
return
}
this.$refs.ruleForm.validate(valid => {
if (valid) {
let query = {}
let projectLawsInventoryIds = []
let roleCodes = []
let Action
this.selectionRowsArray.forEach((item,index) => {
projectLawsInventoryIds.push(item.projectLawsInventoryId)
roleCodes.push(item.roleCode)
})
query = {
roleCodes: roleCodes.join(','),
remark: this.formInline.remark,
conditionAssessment: this.formInline.conditionAssessment,
projectLawsInventoryIds: projectLawsInventoryIds.join(',')
}
Action = postAction
this.confirmLoading = true
Action('/project/projectTaskInventoryConditionAssessmentEO/addOrUpdateBatch', query).then((res) => {
if (res.success) {
this.visible = false
this.confirmLoading = false
this.$message.success(this.$t('OperationSuccessful'))
this.$emit('batchChangeModel')
} else {
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
}
})
}
})
}
}
}
</script>
<style scoped>
.box-title-text {
line-height: 1.4;
display: flex;
}
.Required {
color: red;
margin-right: 4px;
}
.title-text {
width: 134px;
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: 42px;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 130px);
display: inline-block;
margin-top: 2px;
}
.title-text-text {
margin-top: 9px;
}
.headerText {
margin-left: 30px;
color: #040B29;
font-weight: 400;
}
</style>
@@ -0,0 +1,182 @@
<!--批量维护进度-->
<template>
<a-modal
:title="title"
:width="700"
:visible="visible"
:confirm-loading="confirmLoading"
:maskClosable="false"
@ok="handleOk"
@cancel="visible = false"
>
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('CertificationProgress')">{{$t('CertificationProgress')}}</span>
</div>
<a-form-model-item class="itemModel" :prop="!disabled?'certificationProgress':''">
<j-dict-select-tag class="box-input" v-model="formInline.certificationProgress"
:disabled="disabled"
@input="handleInput('certificationProgress')"
:placeholder="$t('PleaseSelect')+$t('CertificationProgress')"
:type="'select'"
:triggerChange="false" :dictCode="'certification_progress'"/>
</a-form-model-item>
</div>
</a-col>
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('remarks')">{{$t('remarks')}}</span>
</div>
<a-form-model-item class="itemModel remarkbox" :prop="!disabled?'certificationProgressRemark':''">
<a-textarea
:placeholder="$t('PleaseEnter')+$t('remarks')"
:disabled="disabled"
v-model="formInline.certificationProgressRemark" :rows="4"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-modal>
</template>
<script>
import { postAction, putAction, getAction } from '@/api/manage'
export default {
name: 'TaskListModel',
data() {
return {
formInline: {},
selectionRowsArray:[],
rules: {},
title:'',
visible: false,
confirmLoading: false,
studioList: [],
ids:'',
disabled: false,
url: {
edit: '/project/projectTaskInventoryEO/edit',
addOrUpdate: '/project/projectTaskInventoryConditionAssessmentEO/addOrUpdate',
list: '/project/projectTaskInventoryConditionAssessmentEO/list'
}
}
},
mounted() {
},
methods: {
getData(val) {
this.visible = true
this.title = this.$t('BatchMaintenanceProgress')
this.selectionRowsArray = val
this.$nextTick(() => {
this.formInline = {}
this.$refs.ruleForm.clearValidate()
})
},
getList(val) {
getAction(this.url.list, { projectLawsInventoryId: val.projectLawsInventoryId }).then((res) => {
if (res.success) {
this.studioList = res.result || []
} else {
this.studioList = []
}
})
},
handleInput(value) {
this.$nextTick(() => {
this.formInline = { ...this.formInline }
this.$refs.ruleForm.validateField([value])
})
},
handleOk() {
if (this.disabled) {
this.visible = false
return
}
this.$refs.ruleForm.validate(valid => {
if (valid) {
let query = {}
this.ids = this.selectionRowsArray.join(',')
query = {
ids: this.ids,
certificationProgress: this.formInline.certificationProgress,
certificationProgressRemark: this.formInline.certificationProgressRemark
}
this.confirmLoading = true
postAction('/project/projectTaskInventoryEO/editBatch', query).then((res) => {
if (res.success) {
this.visible = false
this.confirmLoading = false
this.$message.success(this.$t('OperationSuccessful'))
this.$emit('batchModel')
} else {
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
}
})
}
})
}
}
}
</script>
<style scoped>
.box-title-text {
line-height: 1.4;
display: flex;
}
.Required {
color: red;
margin-right: 4px;
}
.title-text {
width: 134px;
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: 42px;
}
.box-input {
display: inline-block;
height: 38px;
width: 128%;
}
.itemModel {
width: calc(80% - 130px);
display: inline-block;
margin-top: 2px;
}
.title-text-text {
margin-top: 9px;
}
/deep/ .remarkbox .ant-form-item-control{
width: 128%;
}
.headerText {
margin-left: 30px;
color: #040B29;
font-weight: 400;
}
</style>
@@ -0,0 +1,418 @@
<template>
<a-modal
:title="$t('batchSettingPersonnel')"
:width="1000"
:visible="visible"
:confirm-loading="confirmLoading"
:maskClosable="false"
@ok="handleOk"
@cancel="handleCancel"
>
<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="title-text-text"
:title="$t('regulatoryEngineer')">{{$t('regulatoryEngineer')}}</span>
</div>
<a-form-model-item class="itemModel">
<a-select :placeholder="$t('PleaseSelect')+$t('regulatoryEngineer')"
class="box-input"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
allowClear
v-model="formInline.regulationOwnerId">
<a-select-option v-for="(item, key) in regulatoryEngineerList"
:key="key"
:value="item.value">
<span style="display: inline-block;width: 100%" :title=" item.name">
{{ item.name }}
</span>
</a-select-option>
</a-select>
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('certifiedEngineer')">{{$t('certifiedEngineer')}}</span>
</div>
<a-form-model-item class="itemModel">
<a-select :placeholder="$t('PleaseSelect')+$t('certifiedEngineer')"
class="box-input"
allowClear
:getPopupContainer="triggerNode=> triggerNode.parentNode"
v-model="formInline.homologationEngineerId">
<a-select-option v-for="(item, key) in certificationEngineerList"
:key="key"
:value="item.value">
<span style="display: inline-block;width: 100%" :title=" item.name ">
{{ item.name}}
</span>
</a-select-option>
</a-select>
</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('engineeringInterfacePerson')">{{$t('engineeringInterfacePerson')}}</span>
</div>
<a-form-model-item class="itemModel" :prop="'engineeringInterfacePerson'">
<a-select :placeholder="$t('PleaseSelect')+$t('engineeringInterfacePerson')"
class="box-input"
allowClear
:getPopupContainer="triggerNode=> triggerNode.parentNode"
v-model="formInline.engineeringInterfacePerson">
<a-select-option v-for="(item, key) in engineeringInterfacePersonList"
:key="key"
:value="item.value">
<span style="display: inline-block;width: 100%" :title=" item.name ">
{{ item.name }}
</span>
</a-select-option>
</a-select>
</a-form-model-item>
</div>
</a-col>
</a-row>
<div class="header-text">
&nbsp;{{$t('confirmationOfDesignConformity')}}
</div>
<a-row :gutter="24">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('Sponsor')">{{$t('Sponsor')}}</span>
</div>
<a-form-model-item class="itemModel">
<a-select :placeholder="$t('PleaseSelect')+$t('Sponsor')"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
class="box-input"
allowClear
v-model="formInline.designInitiatorId">
<a-select-option v-for="(item, key) in designInitiatorList"
:key="key"
:value="item.value">
<span style="display: inline-block;width: 100%" :title=" item.name ">
{{ item.name }}
</span>
</a-select-option>
</a-select>
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('personLiable')">{{$t('personLiable')}}</span>
</div>
<a-form-model-item class="itemModel">
<a-select :placeholder="$t('PleaseSelect')+$t('personLiable')"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
class="box-input"
allowClear
v-model="formInline.designDutyId">
<a-select-option v-for="(item, key) in designDutyList"
:key="key"
:value="item.value">
<span style="display: inline-block;width: 100%" :title=" item.name ">
{{ item.name }}
</span>
</a-select-option>
</a-select>
</a-form-model-item>
</div>
</a-col>
</a-row>
<div class="header-text">
&nbsp;{{$t('PrehomoConfirmation')}}
</div>
<a-row :gutter="24">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('Sponsor')">{{$t('Sponsor')}}</span>
</div>
<a-form-model-item class="itemModel">
<a-select :placeholder="$t('PleaseSelect')+$t('Sponsor')"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
class="box-input"
allowClear
v-model="formInline.prehomoInitiatorId">
<a-select-option v-for="(item, key) in prehomoInitiatorList"
:key="key"
:value="item.value">
<span style="display: inline-block;width: 100%" :title=" item.name ">
{{ item.name }}
</span>
</a-select-option>
</a-select>
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('personLiable')">{{$t('personLiable')}}</span>
</div>
<a-form-model-item class="itemModel">
<a-select :placeholder="$t('PleaseSelect')+$t('personLiable')"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
class="box-input"
allowClear
v-model="formInline.prehomoDutyId">
<a-select-option v-for="(item, key) in prehomoDutyList"
:key="key"
:value="item.value">
<span style="display: inline-block;width: 100%" :title=" item.name ">
{{ item.name }}
</span>
</a-select-option>
</a-select>
</a-form-model-item>
</div>
</a-col>
</a-row>
<div class="header-text">
&nbsp;{{$t('verificationAndConformityconfirmation')}}
</div>
<a-row :gutter="24">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('Sponsor')">{{$t('Sponsor')}}</span>
</div>
<a-form-model-item class="itemModel">
<a-select :placeholder="$t('PleaseSelect')+$t('Sponsor')"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
class="box-input"
allowClear
v-model="formInline.verifyInitiatorId">
<a-select-option v-for="(item, key) in verifyInitiatorList"
:key="key"
:value="item.value">
<span style="display: inline-block;width: 100%" :title=" item.name ">
{{ item.name }}
</span>
</a-select-option>
</a-select>
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('personLiable')">{{$t('personLiable')}}</span>
</div>
<a-form-model-item class="itemModel">
<a-select :placeholder="$t('PleaseSelect')+$t('personLiable')"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
class="box-input"
allowClear
v-model="formInline.verifyDutyId">
<a-select-option v-for="(item, key) in verifyDutyList"
:key="key"
:value="item.value">
<span style="display: inline-block;width: 100%" :title=" item.name ">
{{ item.name }}
</span>
</a-select-option>
</a-select>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-modal>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
import moment from 'moment'
export default {
name: 'batchSettingPersonnel',
props: ['url'],
data() {
return {
visible: false,
confirmLoading: false,
regulatoryEngineerList: [],
certificationEngineerList: [],
engineeringInterfacePersonList: [],
designInitiatorList: [],
designDutyList: [],
prehomoInitiatorList: [],
prehomoDutyList: [],
verifyInitiatorList: [],
verifyDutyList: [],
formInline: {},
rules: {},
ids: []
}
},
mounted() {
},
methods: {
edit(data, content) {
this.visible = true
this.$nextTick(() => {
this.ids = data || []
this.formInline = {}
this.queryPersonByProject(content[0].dutyTerritory)
})
},
queryPersonByProject(row) {
let query = {
projectId: this.$route.query.id,
dutyTerritory: row
}
getAction(this.url.queryPersonByProject, query).then((res) => {
if (res.success) {
this.regulatoryEngineerList = res.result.lawEngineerList //法规工程师
this.engineeringInterfacePersonList = res.result.engineeringInterfacePersonList //工程接口人
this.certificationEngineerList = res.result.certificationEngineerList //认证工程师
this.designInitiatorList = res.result.allPersonList || []
this.designDutyList = res.result.allPersonList || []
this.prehomoInitiatorList = res.result.allPersonList || []
this.prehomoDutyList = res.result.allPersonList || []
this.verifyInitiatorList = res.result.allPersonList || []
this.verifyDutyList = res.result.allPersonList || []
}
})
},
handleOk() {
let ids = JSON.parse(JSON.stringify(this.ids))
let query = {
ids: ids.join(','),
...this.formInline
}
this.confirmLoading = true
postAction(this.url.setBatch, query).then((res) => {
if (res.success) {
this.$message.success(this.$t('OperationSuccessful'))
this.visible = false
this.confirmLoading = false
this.$emit('batchSettingPersonnelForm')
} else {
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
}
})
},
handleCancel() {
this.formInline = {}
this.visible = false
}
}
}
</script>
<style>
.formAdd .ant-form-item-label {
width: 130px;
}
.formAdd .ant-form-item-control-wrapper {
display: inline-block;
width: 100%;
}
/*.formAdd .ant-form-item {*/
/* margin-bottom: 20px;*/
/*}*/
.itemModel .ant-form-item-control-wrapper {
width: 100%;
}
.box-input .ant-select-selection--single {
height: 38px;
}
.box-input .ant-select-selection--multiple {
height: 38px;
}
.box-input .ant-select-selection__rendered {
line-height: 38px;
height: 38px;
}
.box-input .ant-select-selection--multiple .ant-select-selection__rendered > ul > li {
margin-top: 6px;
}
.box-input .ant-calendar-picker {
line-height: 38px;
height: 38px;
}
.box-input .ant-calendar-picker-input {
height: 38px;
}
.box-input .ant-input-number-input-wrap {
line-height: 38px;
height: 38px;
}
.box-input .ant-calendar-picker-input {
padding: 4px 30px 4px 11px;
}
</style>
<style scoped>
.box-title-text {
line-height: 1.4;
display: flex;
}
.title-text {
width: 104px;
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: 42px;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 130px);
display: inline-block;
margin-top: 2px;
}
.title-text-text {
margin-top: 9px;
}
.formAdd {
margin-bottom: 40px;
}
.header-text {
font-size: 16px;
font-weight: bold;
margin-left: 15px;
/*border-bottom: 1px #d9d9d9 dashed;*/
height: 30px;
margin-bottom: 30px;
}
</style>
@@ -0,0 +1,196 @@
<template>
<a-modal
:title="$t('batchUpdateDeadline')"
:width="500"
:visible="visible"
:confirm-loading="confirmLoading"
:maskClosable="false"
@ok="handleOk"
@cancel="visible = false"
>
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text"
:title="$t('Deadline')">{{$t('Deadline')}}</span>
</div>
<a-form-model-item class="itemModel" :prop="'deadline'">
<a-date-picker class="box-input"
:placeholder="$t('PleaseSelect')+$t('Deadline')"
:getCalendarContainer="(trigger) => trigger.parentNode"
format="YYYY-MM-DD"
v-model="formInline.deadline"
style="width: 100%"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-modal>
</template>
<script>
import moment from 'moment'
import { postAction, putAction, getAction } from '@/api/manage'
export default {
name: 'batchUpdateDeadline',
data() {
return {
visible: false,
confirmLoading: false,
formInline: {},
rules: {
deadline: [
{
required: true,
message: this.$t('Deadline') + this.$t('cannotEmpty'),
trigger: 'change'
}
]
},
idList: []
}
},
mounted() {
},
methods: {
handleOk() {
this.$refs.ruleForm.validate(valid => {
if (valid) {
let query = {
ids: this.idList.join(','),
deadline: moment(this.formInline.deadline).format('YYYY-MM-DD HH:mm:ss')
}
this.confirmLoading = true
postAction('/params/collectManifest/batchEditDeadline', query).then((res) => {
if (res.success) {
this.visible = false
this.confirmLoading = false
this.$message.success(this.$t('OperationSuccessful'))
this.$emit('batchUpdateDeadlineForm')
} else {
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
}
})
}
})
},
getData(data) {
this.idList = []
if (data && data.length > 0) {
data.forEach(res => {
this.idList.push(res.id)
})
this.visible = true
this.formInline = {}
} else {
this.$message.warning(this.$t('selectLeastOne'))
}
}
}
}
</script>
<style>
.formAdd .ant-form-item-label {
width: 130px;
}
.formAdd .ant-form-item-control-wrapper {
display: inline-block;
width: 100%;
}
/*.formAdd .ant-form-item {*/
/* margin-bottom: 20px;*/
/*}*/
.itemModel .ant-form-item-control-wrapper {
width: 100%;
}
.box-input .ant-select-selection--single {
height: 38px;
}
.box-input .ant-select-selection--multiple {
height: 38px;
}
.box-input .ant-select-selection__rendered {
line-height: 38px;
height: 38px;
}
.box-input .ant-select-selection--multiple .ant-select-selection__rendered > ul > li {
margin-top: 6px;
}
.box-input .ant-calendar-picker {
line-height: 38px;
height: 38px;
}
.box-input .ant-calendar-picker-input {
height: 38px;
}
.box-input .ant-input-number-input-wrap {
line-height: 38px;
height: 38px;
}
.box-input .ant-calendar-picker-input {
padding: 4px 30px 4px 11px;
}
</style>
<style scoped>
.box-title-text {
line-height: 1.4;
display: flex;
}
.title-text {
width: 104px;
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: 42px;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 130px);
display: inline-block;
margin-top: 2px;
}
.title-text-text {
margin-top: 9px;
}
.formAdd {
margin-bottom: 40px;
}
.Required{
color: red;
}
</style>
@@ -0,0 +1,401 @@
<!--平台件-->
<template>
<div>
<div class="box-content">
<div class="box-content-left">
<div class="total-text">
<span>{{$t('totalTable')+' : '+mainLeftNum}}</span>
</div>
<div id="main-left"></div>
</div>
<div class="box-content-right">
<div class="total-text">
<span>{{$t('totalTable')+' : '+mainRightNum}}</span>
</div>
<div id="main-right"></div>
</div>
</div>
<!-- <div class="box-content">-->
<!-- <div class="box-content-bottom">-->
<!-- <div class="total-text-text" :class="{'total-text-text-cntop':long == 'zh-cn' ? true:false,-->
<!-- 'total-text-text-entop':long == 'zh-cn' ? false:true}">-->
<!-- <span>{{$t('totalTable')+' : '+mainBottomNum}}</span>-->
<!-- </div>-->
<!-- <div class="box-content-text">-->
<!-- <div class="box-content-text-text" @click="boxContentClick(0)">-->
<!-- {{$t('whole')}}-->
<!-- </div>-->
<!-- <div class="box-content-text-text" @click="boxContentClick(1)">-->
<!-- {{$t('completeVehicle')}}-->
<!-- </div>-->
<!-- <div class="box-content-text-text" @click="boxContentClick(2)">-->
<!-- {{$t('components')}}-->
<!-- </div>-->
<!-- </div>-->
<!-- <div id="main-bottom"></div>-->
<!-- </div>-->
<!-- </div>-->
<responsibilityList @responsibility="responsibility" ref="responsibilityListRef"/>
</div>
</template>
<script>
import * as echarts from 'echarts'
import { getAction, postAction, deleteAction, downloadFile } from '@/api/manage'
import responsibilityList from './responsibilityList'
export default {
name: 'certificationActivity',
components: {
responsibilityList
},
props: {
idList: {
type: Array,
default: []
}
},
data() {
return {
url: {
getProjectDetailsStatistics: '/project/projectLibraryBase/getProjectDetailsStatistics'
},
certificationProgressMap: {},
num: '0',
mainLeftNum: 0,
mainRightNum: 0,
mainBottomNum: 0,
long: localStorage.getItem('language') || 'zh-cn'
}
},
mounted() {
this.num = '0'
let boxContentTextColor = document.getElementsByClassName('box-content-text-color')
if (boxContentTextColor && boxContentTextColor.length > 0) {
boxContentTextColor[0].classList.remove('box-content-text-color')
}
let boxContentTextText = document.getElementsByClassName('box-content-text-text')
if (boxContentTextText && boxContentTextText.length > 0) {
boxContentTextText[0].classList.add('box-content-text-color')
}
this.getData()
},
methods: {
getData() {
let id = ''
if (this.idList && this.idList.length > 0) {
id = this.idList.join(',')
} else {
id = this.$route.query.id
}
getAction(this.url.getProjectDetailsStatistics, { id: id }).then((res) => {
if (res.success) {
if (res.result) {
let rzTaskToConfirmMapList = res.result.rzTaskToConfirmMap ? res.result.rzTaskToConfirmMap.rzTaskToConfirmMapList : []
let prehomoMapList = res.result.prehomoMap ? res.result.prehomoMap.prehomoMapList : []
this.certificationProgressMap = res.result.certificationProgressMap
let allMapList = res.result.certificationProgressMap ? res.result.certificationProgressMap.allMapList : []
this.dataEcharts(rzTaskToConfirmMapList)
this.mainRightEcharts(prehomoMapList)
}
}
})
},
dataEcharts(dataSource) {
let data = []
let color = []
this.mainLeftNum = 0
if (dataSource && dataSource.length > 0) {
this.dataSource = [{}]
dataSource.forEach(res => {
if (res.taskAffirmStatus == 'Not started') {
data.push({
value: res.taskAffirmStatusCount,
name: this.$t('notLaunch'),
color: '#00B3BE',
status: res.taskAffirmStatus
})
color.push('#00B3BE')
} else if (res.taskAffirmStatus == 'List to confirm') {
data.push({
value: res.taskAffirmStatusCount,
name: this.$t('listToConfirm'),
color: '#FDA71C',
status: res.taskAffirmStatus
})
color.push('#FDA71C')
} else if (res.taskAffirmStatus == 'Accepted') {
data.push({
value: res.taskAffirmStatusCount,
name: this.$t('accept'),
color: '#26BC4B',
status: res.taskAffirmStatus
})
color.push('#26BC4B')
} else if (res.taskAffirmStatus == 'Rejected') {
data.push({
value: res.taskAffirmStatusCount,
name: this.$t('refuse'),
color: '#E83030',
status: res.taskAffirmStatus
})
color.push('#E83030')
}
this.mainLeftNum += res.taskAffirmStatusCount
})
}
this.getEcharts('main-left', this.$t('certificationTaskConfirmation'), color, data)
},
mainRightEcharts(dataSource) {
let data = []
let color = []
this.mainRightNum = 0
if (dataSource && dataSource.length > 0) {
this.dataSource = [{}]
dataSource.forEach(res => {
if (res.taskAffirmStatus == 'Not started') {
data.push({
value: res.taskAffirmStatusCount,
name: this.$t('notLaunch'),
color: '#00B3BE',
status: res.taskAffirmStatus
})
color.push('#00B3BE')
} else if (res.taskAffirmStatus == 'List to confirm') {
data.push({
value: res.taskAffirmStatusCount,
name: this.$t('listToConfirm'),
color: '#FDA71C',
status: res.taskAffirmStatus
})
color.push('#FDA71C')
} else if (res.taskAffirmStatus == 'Review and pass') {
data.push({
value: res.taskAffirmStatusCount,
name: this.$t('reviewAndPass'),
color: '#26BC4B',
status: res.taskAffirmStatus
})
color.push('#26BC4B')
} else if (res.taskAffirmStatus == 'Review and return') {
data.push({
value: res.taskAffirmStatusCount,
name: this.$t('reviewAndReturn'),
color: '#E83030',
status: res.taskAffirmStatus
})
color.push('#E83030')
}
this.mainRightNum += res.taskAffirmStatusCount
})
}
this.getEcharts('main-right', this.$t('preHomoFlow'), color, data)
},
getEcharts(chart, title, color, data) {
var myChart = echarts.init(document.getElementById(chart))
myChart.setOption({
title: {
text: title
},
tooltip: {
trigger: 'item',
textStyle: {
fontWeight: 'normal',
fontSize: 14,
color: '#040B29',
fontFamily: 'BlueSkyNoto'
},
formatter: function(parms) {
let str = parms.marker + ' ' + parms.data.name + '&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;' + parms.data.value + ' (' + parms.percent + '%)'
return str
}
},
legend: {
itemWidth: 12,
itemHeight: 12,
bottom: '0',
left: 'center',
itemGap: 30,
icon: 'circle'
},
series: [
{
name: title,
type: 'pie',
radius: ['40%', '54%'],
avoidLabelOverlap: false,
label: {
show: false,
position: 'center'
},
labelLine: {
show: false
},
color: color,
data: data
}
]
})
myChart.off('click') // 重点代码
myChart.on('click', (params) => {
console.log(params)
let query = {
title: params.seriesName+'-'+params.name,
projectLibraryId: this.$route.query.id
}
if (params.seriesName === this.$t('certificationTaskConfirmation')) {
query.operatorType = 'queryRZTaskToConfirmStatistics'
query.status = params.data.status
} else if (params.seriesName === this.$t('preHomoFlow')) {
query.operatorType = 'queryPrehomoStatistics'
query.status = params.data.status
} else if (params.seriesName === this.$t('CertificationProgress')) {
if (this.num == '0') {
query.operatorType = 'queryCertificationProgressStatisticsAll'
} else if (this.num == '1') {
query.operatorType = 'queryCertificationProgressStatisticsCar'
} else if (this.num == '2') {
query.operatorType = 'queryCertificationProgressStatisticsPart'
}
query.status = params.data.status
}
this.$refs.responsibilityListRef.getData(query)
})
},
responsibility(item) {
this.$emit('currentStatus', item)
},
boxContentClick(num) {
let boxContentTextColor = document.getElementsByClassName('box-content-text-color')
if (boxContentTextColor && boxContentTextColor.length > 0) {
boxContentTextColor[0].classList.remove('box-content-text-color')
}
let boxContentTextText = document.getElementsByClassName('box-content-text-text')
if (boxContentTextText && boxContentTextText.length > 0) {
boxContentTextText[num].classList.add('box-content-text-color')
}
}
}
}
</script>
<style scoped lang="less">
.box-content {
width: 100%;
display: flex;
justify-content: space-between;
flex-wrap: wrap;
/*margin-bottom: 20px;*/
.box-content-left {
width: calc(50% - 10px);
height: 346px;
position: relative;
border: 2px #eff1f3 solid;
border-radius: 6px;
margin-top: 4px;
#main-left {
width: 100%;
height: 100%;
padding: 20px 24px;
box-sizing: border-box;
}
}
.box-content-right {
width: calc(50% - 10px);
height: 346px;
position: relative;
border: 2px #eff1f3 solid;
border-radius: 6px;
margin-top: 4px;
#main-right {
width: 100%;
height: 100%;
padding: 20px 24px;
box-sizing: border-box;
}
}
.box-content-bottom {
width: 100%;
height: 346px;
border: 2px #eff1f3 solid;
position: relative;
border-radius: 6px;
margin-top: 20px;
overflow: hidden;
.box-content-text {
height: 30px;
background: #F5F6F7;
border-radius: 4px;
position: absolute;
right: 24px;
top: 20px;
display: flex;
z-index: 100;
justify-content: space-between;
padding: 0 2px 0 2px;
.box-content-text-text {
display: inline-block;
font-size: 12px;
color: #6F7385;
line-height: 30px;
margin-right: 10px;
cursor: pointer;
margin-left: 10px;
}
.box-content-text-color {
box-shadow: 0px 1px 2px rgba(0, 0, 60, 0.01), 0px 2px 4px rgba(0, 22, 60, 0.02), 0px 4px 6px rgba(0, 22, 60, 0.0229458);
border-radius: 4px;
padding: 4px 6px;
background: #FFFFFF;
border: 1px solid #E6E7EC;
color: #01A0AC;
line-height: normal;
margin-right: 0;
margin-left: 0;
}
}
#main-bottom {
width: 100%;
height: 100%;
padding: 20px 24px;
box-sizing: border-box;
}
}
}
.total-text {
position: absolute;
right: 28px;
top: 19px;
font-size: 18px;
font-weight: bold;
}
.total-text-text {
position: absolute;
right: 28px;
top: 21px;
font-size: 18px;
font-weight: bold;
}
.total-text-text-cntop {
right: 180px;
}
.total-text-text-entop {
right: 290px;
}
</style>
@@ -0,0 +1,321 @@
<template>
<div>
<a-drawer
:title="$t('CertificationDirectory')"
:maskClosable="false"
:width="1100"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<div style="margin-bottom: 60px">
<div class="table-operator">
<div class="operator-text" v-if="isDisplayNum == 2 && roleSwitchingCode == 2"
@click="addData">
<a-icon type="plus"/>
{{$t('add')}}
</div>
</div>
<a-table
:components="drag(columns,'columnsAll')"
:columns="columns"
:scroll="{x: 900}"
:data-source="dataList"
:pagination="false"
:loading="loading">
<span slot="operation" slot-scope="text,record">
<a class="text" @click="edit(record)">
{{ $t('edit') }}
</a>
<a class="text" @click="deleteData(record)">
{{ $t('delete') }}
</a>
</span>
<span slot="operationFile" slot-scope="text,record">
<a @click="viewFileClick(text)" v-if="text">
{{$t('viewFile')}}
</a>
<span v-else>--</span>
</span>
</a-table>
<div class="page" v-if="dataList.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="onChange"
@showSizeChange="SizeChange"
/>
</div>
</div>
<div class="drawer-bootom-button">
<!-- style="margin-right: 16px"-->
<a-button @click="handleCancel">{{$t('cancel')}}</a-button>
<!-- <a-button @click="handleSubmit" type="primary" :loading="confirmLoading">{{$t('submit')}}</a-button>-->
</div>
</a-drawer>
<certificationDirectoryAdd @certificationDirectoryList="certificationDirectoryList"
ref="certificationDirectoryAddRef"/>
<viewFileModel ref="viewFileModelRef"/>
</div>
</template>
<script>
import { getAction, postAction, deleteAction } from '@/api/manage'
import certificationDirectoryAdd from './certificationDirectoryAdd'
import viewFileModel from '@/components/viewFileModel/index'
import { ResizeHeader, ResizeColumnProvide } from '@/mixins/header'
export default {
name: 'certificationDirectory',
components: {
certificationDirectoryAdd,
viewFileModel
},
props: ['isDisplayNum','roleSwitchingCode'],
mixins:[ResizeHeader, ResizeColumnProvide],
data() {
return {
visible: false,
queryParam: {},
confirmLoading: false,
selectedRowKeys: [],
columnsAll: [
{
title: this.$t('directoryName'),
dataIndex: 'directoryName',
align: 'left',
ellipsis: true,
width: 132
},
{
title: this.$t('batch'),
dataIndex: 'lot',
align: 'left',
ellipsis: true,
width: 132
},
{
title: this.$t('catalogFile'),
dataIndex: 'directoryFile',
align: 'left',
ellipsis: true,
scopedSlots: { customRender: 'operationFile' },
width: 132
},
{
title: this.$t('testScheme'),
dataIndex: 'experimentFile',
align: 'left',
ellipsis: true,
scopedSlots: { customRender: 'operationFile' },
width: 132
},
{
title: this.$t('testReportLocation'),
dataIndex: 'detectionReportLocation',
align: 'left',
ellipsis: true,
width: 132
},
{
title: this.$t('explain'),
dataIndex: 'explainInfo',
align: 'left',
ellipsis: true,
width: 132
},
{
title: this.$t('uploadTime'),
dataIndex: 'uploadTime',
align: 'left',
ellipsis: true,
width: 130
},
{
title: this.$t('operation'),
align: 'left',
width: 130,
scopedSlots: { customRender: 'operation' }
}
],
dataList: [],
content: [],
loading: false,
pageNo: 1,
pageSize: 10,
total: 0,
url: {
page: '/project/projectCertificationDirectoryEO/page',
delete: '/project/projectCertificationDirectoryEO/delete'
}
}
},
computed: {
columns() {
let columnResult = JSON.parse(JSON.stringify(this.columnsAll))
if (this.roleSwitchingCode == 2 && this.isDisplayNum == 2){
}else{
for (var i = 0; i < columnResult.length; i++) {
if (columnResult[i].title === this.$t('operation')) {
columnResult.splice(i, 1)
i--
}
}
}
return columnResult
}
},
mounted() {
},
methods: {
addModel() {
this.visible = true
this.queryParam = {}
this.selectedRowKeys = []
this.replacePage()
},
searchQuery() {
this.pageNo = 1
this.replacePage()
},
searchReset() {
this.pageNo = 1
this.queryParam = {}
this.replacePage()
},
onChange(page, pageSize) {
this.pageNo = page
this.replacePage()
},
SizeChange(page, pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.replacePage()
},
replacePage() {
let query = {
pageNo: this.pageNo,
pageSize: this.pageSize,
projectLibraryId: this.$route.query.id,
...this.queryParam
}
this.loading = true
getAction(this.url.page, query).then((res) => {
if (res.success) {
this.dataList = res.result.records || []
this.total = res.result.total
this.loading = false
} else {
this.loading = false
}
})
},
handleCancel() {
this.visible = false
},
handleSubmit() {
this.visible = false
},
edit(val) {
this.$refs.certificationDirectoryAddRef.edit(JSON.parse(JSON.stringify(val)))
},
deleteData(val) {
let _this = this
this.$confirm({
content: _this.$t('ConfirmDelete'),
onOk() {
deleteAction(_this.url.delete, { id: val.id }).then((res) => {
if (res.success) {
_this.$message.success(_this.$t('OperationSuccessful'))
_this.replacePage()
} else {
_this.$message.warning(_this.$t('operationFailed'))
}
})
}
})
},
addData() {
this.$refs.certificationDirectoryAddRef.add()
},
certificationDirectoryList() {
this.pageNo = 1
this.replacePage()
},
viewFileClick(item) {
this.$refs.viewFileModelRef.clickButtonToUpload(item)
}
}
}
</script>
<style scoped>
@import '~@assets/less/common.less';
.page {
text-align: right;
margin-top: 20px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
width: 100%;
z-index: 100;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
.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;
}
.table-operator {
text-align: right;
margin-bottom: 20px;
}
.text {
margin-right: 8px;
}
</style>
@@ -0,0 +1,318 @@
<template>
<div>
<a-drawer
:title="$t('add')"
:maskClosable="false"
:width="1000"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<a-spin :spinning="confirmLoading">
<a-form-model :model="formInline" :rules="rules" class="formAdd" ref="ruleForm">
<a-row :gutter="24">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('directoryName')">{{$t('directoryName')}}</span>
</div>
<a-form-model-item class="itemModel" prop="directoryName">
<a-input class="box-input"
:disabled="disabled"
v-model.trim="formInline.directoryName"
:placeholder="$t('PleaseEnter')+$t('directoryName')"/>
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('batch')">{{$t('batch')}}</span>
</div>
<a-form-model-item class="itemModel" prop="lot">
<a-input class="box-input"
:disabled="disabled"
v-model.trim="formInline.lot"
:placeholder="$t('PleaseEnter')+$t('batch')"/>
</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('catalogFile')">{{$t('catalogFile')}}</span>
</div>
<a-form-model-item class="itemModel">
<a-button type="primary" class="button-text"
@click="clickButtonToUpload('directoryFile')">
{{ (formInline.directoryFile === 'null' || formInline.directoryFile === ''||
formInline.directoryFile == null) ? $t('clickUpload') : $t('viewUploadedFiles') }}
</a-button>
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('testScheme')">{{$t('testScheme')}}</span>
</div>
<a-form-model-item class="itemModel">
<a-button type="primary" class="button-text"
@click="clickButtonToUpload('experimentFile')">
{{ (formInline.experimentFile === 'null' || formInline.experimentFile === ''||
formInline.experimentFile == null) ? $t('clickUpload') : $t('viewUploadedFiles') }}
</a-button>
</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('testReportLocation')">{{$t('testReportLocation')}}</span>
</div>
<a-form-model-item class="itemModel" prop="detectionReportLocation">
<a-input class="box-input"
:disabled="disabled"
v-model.trim="formInline.detectionReportLocation"
:placeholder="$t('PleaseEnter')+$t('testReportLocation')"/>
</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('explain')">{{$t('explain')}}</span>
</div>
<a-form-model-item class="itemModel" prop="explainInfo">
<a-textarea
style="width: 100%"
:placeholder="$t('PleaseEnter')+$t('explain')"
v-model.trim="formInline.explainInfo" :rows="4"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-spin>
<div class="drawer-bootom-button">
<a-button @click="handleCancel" style="margin-right: 16px">{{$t('cancel')}}</a-button>
<a-button @click="handleSubmit" type="primary" :loading="confirmLoading">{{$t('submit')}}</a-button>
</div>
</a-drawer>
<uploadFile ref="uploadFile" @uploadSuccess="uploadSuccess"/>
</div>
</template>
<script>
import { getAction, postAction, putAction } from '@/api/manage'
import uploadFile from '@/components/uploadFile/file'
export default {
name: 'certificationDirectoryAdd',
components: {
uploadFile
},
data() {
return {
visible: false,
formInline: {},
rules:{
directoryName: [
{
max: 100,
message: this.$t('directoryName') + this.$t('cannotExceed') + 100 + this.$t('Characters'),
trigger: 'blur'
}
],
lot: [
{
max: 100,
message: this.$t('batch') + this.$t('cannotExceed') + 100 + this.$t('Characters'),
trigger: 'blur'
}
],
detectionReportLocation:[
{
max: 500,
message: this.$t('testReportLocation') + this.$t('cannotExceed') + 500 + this.$t('Characters'),
trigger: 'blur'
}
],
explainInfo:[
{
max: 300,
message: this.$t('explain') + this.$t('cannotExceed') + 300 + this.$t('Characters'),
trigger: 'blur'
}
],
},
confirmLoading: false,
disabled: false,
url: {
add: '/project/projectCertificationDirectoryEO/add',
edit: '/project/projectCertificationDirectoryEO/edit'
}
}
},
mounted() {
},
methods: {
add() {
this.visible = true
this.formInline = {}
this.$nextTick(() => {
this.$refs.ruleForm.clearValidate()
})
},
edit(val) {
this.visible = true
this.$nextTick(() => {
this.formInline = val
this.$refs.ruleForm.clearValidate()
})
},
handleCancel() {
this.visible = false
},
handleSubmit() {
this.$refs.ruleForm.validate(valid => {
if (valid){
if (!this.formInline.directoryName && !this.formInline.lot && !this.formInline.directoryFile &&
!this.formInline.experimentFile && !this.formInline.detectionReportLocation && !this.formInline.explainInfo) {
this.$message.warning(this.$t('dataCannotEmpty'))
} else {
let Action
let url = ''
if (this.formInline.id) {
url = this.url.edit
Action = putAction
} else {
url = this.url.add
Action = postAction
}
let query = {
projectLibraryId: this.$route.query.id,
...this.formInline
}
this.confirmLoading = true
Action(url, query).then((res) => {
if (res.success) {
this.$message.success(this.$t('OperationSuccessful'))
this.visible = false
this.confirmLoading = false
this.$emit('certificationDirectoryList')
} else {
this.confirmLoading = false
this.$message.warning(res.message)
}
})
}
}
})
},
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 }
}
}
}
</script>
<style scoped>
.drawer-bootom-button {
position: absolute;
bottom: 0;
width: 100%;
z-index: 100;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
.box-title-text {
line-height: 1.4;
display: flex;
/*align-items: center;*/
}
.title-text {
width: 114px;
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;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 130px);
display: inline-block;
margin-top: 2px;
height: 40px;
margin-bottom: 24px;
}
.title-text-text {
margin-top: 9px;
}
.formAdd {
margin-bottom: 40px;
}
.button-text {
height: 38px;
width: calc(100% - 100px);
line-height: 38px;
background: #fff;
border: 1px #00B3BE solid;
color: #00B3BE;
}
</style>
@@ -0,0 +1,289 @@
<template>
<div>
<a-drawer
:title="$t('regulationNo')"
:width="1000"
:visible="visible"
placement="right"
:maskClosable="false"
:closable="true"
@close="handleCancel"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<div style="margin-bottom: 60px">
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :md="12" :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>
<template v-if="toggleSearchStatus">
<a-col :md="12" :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="12" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('areaOfResponsibility')">
<span>{{$t('areaOfResponsibility')}}</span>
</div>
<j-dict-select-tag class="box-input"
v-model="queryParam.dutyTerritory"
:placeholder="$t('PleaseSelect')+$t('areaOfResponsibility')"
:type="'select'"
:triggerChange="false" :dictCode="'duty_territory'"/>
</div>
</a-col>
</template>
<span style="float: right;overflow: hidden;" class="table-page-search-submitButtons">
<a-col :md="12" :sm="24">
<a @click="handleToggleSearch">
{{ !toggleSearchStatus ? $t('open') : $t('away') }}
<a-icon :type="toggleSearchStatus ? 'up' : 'down'"/>
</a>
<a-button class="box-button" style="margin-left: 8px" @click="searchReset">{{$t('reset')}}</a-button>
<a-button class="box-button" style="margin-left: 8px" type="primary" @click="searchQuery">{{$t('query')}}</a-button>
</a-col>
</span>
</a-row>
</a-form>
</div>
<div style="width: 100%">
<a-table
:columns="columns"
rowKey="id"
:scroll="{x: '100%',y:'calc(100vh - 300px)'}"
:data-source="dataList"
:pagination="false"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange ,columnTitle:' '}"
:loading="loading">
</a-table>
</div>
<!-- <div class="page" v-if="dataList.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="onChange"
@showSizeChange="SizeChange"
/>
</div>-->
</div>
<div class="drawer-bootom-button">
<a-button @click="handleCancel" style="margin-right: 16px">{{$t('cancel')}}</a-button>
<a-button @click="handleSubmit" type="primary" :loading="confirmLoading">{{$t('submit')}}</a-button>
</div>
</a-drawer>
</div>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
import { ResizeHeader, ResizeColumnProvide } from '@/mixins/header'
export default {
name: 'addCodeNumber',
mixins: [ResizeHeader, ResizeColumnProvide],
data() {
return {
url: {
addModelList: '/project/projectLawsInventoryEO/list'
},
visible: false,
toggleSearchStatus: false,
columns: [
{
title: this.$t('standard'),
dataIndex: 'serialNumber',
align: 'left',
ellipsis: true,
width: 250
},
{
title: this.$t('title'),
dataIndex: 'title',
align: 'left',
ellipsis: true,
width: 250
},
{
title: this.$t('certificationType'),
dataIndex: 'attestationType_dictText',
align: 'left',
ellipsis: true,
width: 190
},
{
title: this.$t('areaOfResponsibility'),
dataIndex: 'dutyTerritory_dictText',
align: 'left',
ellipsis: true,
width: 100
}
],
dataList: [],
selectedRowKeys: [],
loading: false,
pageNo: 1,
pageSize: 10,
total: 0,
queryParam: {},
confirmLoading: false
}
},
mounted() {
},
methods: {
handleToggleSearch() {
this.toggleSearchStatus = !this.toggleSearchStatus
},
add() {
this.visible = true
this.queryParam = {}
this.selectedRowKeys = []
this.replacePage()
},
handleCancel() {
this.visible = false
},
searchQuery() {
this.pageNo = 1
this.replacePage()
},
searchReset() {
this.pageNo = 1
this.queryParam = {}
this.replacePage()
},
onChange(page, pageSize) {
this.pageNo = page
this.replacePage()
},
SizeChange(page, pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.replacePage()
},
replacePage() {
let query = {
// pageNo: this.pageNo,
// pageSize: this.pageSize,
...this.queryParam,
projectLibraryId: this.$route.query.id,
roleCode: 0
}
this.loading = true
getAction(this.url.addModelList, query).then((res) => {
if (res.success) {
this.dataList = res.result || []
// this.total = res.result.total
this.loading = false
} else {
this.dataList = []
this.total = 0
this.loading = false
}
})
},
onSelectChange(value, row) {
this.selectedRowKeys = value
if (this.selectedRowKeys.length > 1) {
this.selectedRowKeys.shift()
}
this.selectedRowList = row
if (this.selectedRowList.length > 1) {
this.selectedRowList.shift()
}
},
handleSubmit() {
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
this.confirmLoading = true
let selectedRowKeys = JSON.parse(JSON.stringify(this.selectedRowKeys))
if (this.selectedRowKeys.length < 2) {
let fgid = this.selectedRowList[0].standId
let regulationIndex = this.selectedRowList[0].serialNumber
this.confirmLoading = false
this.visible = false
this.$emit('regulation', regulationIndex, fgid)
} else {
this.$message.warning(this.$t('OnlyOneSelected'))
this.confirmLoading = false
}
} else {
this.$message.warning(this.$t('selectLeastOne'))
this.confirmLoading = false
}
}
}
}
</script>
<style lang='less' scoped>
@import '~@assets/less/common.less';
.box-title-text {
line-height: 1.4;
display: flex;
align-items: center;
margin-bottom: 10px;
}
.title-text {
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: 100%;
height: 38px;
}
.box-button {
height: 38px;
}
.page {
text-align: right;
margin-top: 20px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
width: 100%;
z-index: 100;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
</style>
@@ -0,0 +1,140 @@
<template>
<a-modal
:title="$t('addConfiguration')"
:width="600"
:visible="visible"
:confirm-loading="confirmLoading"
:maskClosable="false"
@ok="handleOk"
@cancel="handleCancel"
>
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('configurationItem')">{{$t('configurationItem')}}</span>
</div>
<a-form-model-item class="itemModel" prop="configItem">
<a-input class="box-input"
v-model.trim="formInline.configItem"
:placeholder="$t('PleaseEnter')+$t('configurationItem')"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-modal>
</template>
<script>
import { getAction, postAction, downloadFile, deleteAction } from '@/api/manage'
export default {
name: 'addConfiguration',
data() {
return {
visible: false,
confirmLoading: false,
formInline: {},
ids: [],
rules: {
configItem: [
{
required: true,
message: this.$t('configurationItem') + this.$t('cannotEmpty'),
trigger: 'blur'
},
{
max: 100,
message: this.$t('configurationItem') + this.$t('cannotExceed') + 100 + this.$t('Characters'),
trigger: 'blur'
}
]
}
}
},
methods: {
getData(ids) {
this.visible = true
this.ids = ids
this.formInline = {}
this.$nextTick(() => {
this.$refs.ruleForm.clearValidate()
})
},
handleOk() {
this.$refs.ruleForm.validate(valid => {
if (valid) {
let query = {
ids: this.ids.join(','),
configItem: this.formInline.configItem
}
this.confirmLoading = true
postAction('/project/projectCertificationInventoryEO/addConfigByIds', query).then((res) => {
if (res.success) {
this.$message.success(this.$t('OperationSuccessful'))
this.confirmLoading = false
this.visible = false
this.$emit('addConfigurationForm')
} else {
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
}
})
}
})
},
handleCancel() {
this.visible = false
}
}
}
</script>
<style scoped>
.box-title-text {
line-height: 1.4;
display: flex;
}
.title-text {
width: 104px;
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: 42px;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 130px);
display: inline-block;
margin-top: 2px;
}
.title-text-text {
margin-top: 9px;
}
.formAdd {
margin-bottom: 40px;
}
.Required {
color: red;
margin-right: 4px;
}
</style>
@@ -0,0 +1,474 @@
<template>
<a-modal
:title="name"
:width="name == $t('changeSetting') ? 600 : 1000"
:visible="visible"
:confirm-loading="confirmLoading"
:maskClosable="false"
@ok="handleOk"
@cancel="handleCancel"
>
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24">
<a-col :span="name == $t('changeSetting') ? 24 : 12"
v-if="name == $t('BatchSetting') || name == $t('changeSetting')">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('configurationItem')">{{$t('configurationItem')}}</span>
</div>
<a-form-model-item class="itemModel">
<a-input class="box-input"
v-model.trim="formInline.configItem"
:placeholder="$t('PleaseEnter')+$t('configurationItem')"/>
<!-- <j-dict-select-tag class="box-input" v-model="formInline.configItem"-->
<!-- @input="handleInput('configItem')"-->
<!-- :placeholder="$t('PleaseSelect')+$t('configurationItem')"-->
<!-- :type="'select'"-->
<!-- :triggerChange="false" :dictCode="'ren4_zheng4_qing1_dan1_-_pei4_zhi4_xiang4'"/>-->
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('engineeringInterfacePerson')">{{$t('engineeringInterfacePerson')}}</span>
</div>
<a-form-model-item class="itemModel">
<a-select :placeholder="$t('cannotSetResponsibilityAreas')"
class="box-input"
allowClear
optionFilterProp="label"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
v-model="formInline.sdt">
<a-select-option v-for="(item, key) in engineeringInterfacePersonList"
:key="item.key"
:label="item.name"
:value="item.value">
<span style="display: inline-block;width: 100%" :title=" item.name ">
{{ item.name }}
</span>
</a-select-option>
</a-select>
</a-form-model-item>
</div>
</a-col>
</a-row>
<a-row :gutter="24" v-if="name == $t('BatchSetting')">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('statisticalNodes')">{{$t('statisticalNodes')}}</span>
</div>
<a-form-model-item class="itemModel-multi">
<a-select :placeholder="$t('PleaseSelect')+$t('statisticalNodes')"
class="box-input"
optionFilterProp="label"
@change="DutyDepartChange"
mode="multiple"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
v-model="formInline.dutyDepart">
<a-select-option v-for="(item, key) in firstLevelDutyTerritoryList"
:key="key"
:label="item.key"
:value="item.key">
<span style="display: inline-block;width: 100%" :title=" item.key ">
{{ item.key }}
</span>
</a-select-option>
</a-select>
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('areaOfResponsibility')">{{$t('areaOfResponsibility')}}</span>
</div>
<a-form-model-item class="itemModel-multi">
<a-select :placeholder="$t('PleaseSelect')+$t('areaOfResponsibility')"
class="box-input"
optionFilterProp="label"
mode="multiple"
@change="handleChange"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
v-model="formInline.dutyTerritory">
<a-select-option v-for="(item, key) in dutyTerritoryList"
:key="key"
:label="item.itemText"
:value="item.itemValue">
<span style="display: inline-block;width: 100%" :title=" item.itemText ">
{{ item.itemText }}
</span>
</a-select-option>
</a-select>
<!-- <j-dict-select-tag class="box-input" v-model="formInline.dutyTerritory"-->
<!-- @input="handleInput('dutyTerritory')"-->
<!-- @changeQuery="handleChange"-->
<!-- :placeholder="$t('PleaseSelect')+$t('areaOfResponsibility')"-->
<!-- :type="'select'"-->
<!-- :triggerChange="false" :dictCode="'duty_territory'"/>-->
</a-form-model-item>
</div>
</a-col>
</a-row>
<a-row :gutter="24" v-if="name == $t('BatchSetting')">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('typeOfDeliverables')">{{$t('typeOfDeliverables')}}</span>
</div>
<a-form-model-item class="itemModel-multi">
<!-- tree-checkable-->
<a-tree-select
tree-node-filter-prop="title"
v-model="formInline.deliverableType"
:maxTagCount="1"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
class="box-input"
style="width: 100%"
:tree-data="DeliverableTreeList"
:placeholder="$t('PleaseSelect')+$t('typeOfDeliverables')"
/>
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<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({db_field_name:'endTime'})"
format="YYYY-MM-DD"
:disabledDate="disabledDate"
:getCalendarContainer="(trigger) => trigger.parentNode"
v-model="formInline.endTime"
style="width: 100%"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
<a-row :gutter="24" v-if="name == $t('BatchSetting')">
<a-col :span="12" v-if="roleSwitchingCode == 2">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('CertificationProgress')">{{$t('CertificationProgress')}}</span>
</div>
<a-form-model-item class="itemModel">
<j-dict-select-tag class="box-input" v-model="formInline.certificationProgress"
@input="handleInput('certificationProgress')"
:placeholder="$t('PleaseSelect')+$t('CertificationProgress')"
:type="'select'"
:triggerChange="false" :dictCode="'certification_progress'"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
<a-row :gutter="24" v-if="name == $t('BatchSetting') && roleSwitchingCode == 2">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('remarks')">{{$t('remarks')}}</span>
</div>
<a-form-model-item class="itemModel" :prop="'certificationProgressRemark'">
<a-textarea
:placeholder="$t('PleaseEnter')+$t('remarks')"
v-model="formInline.certificationProgressRemark" :rows="4"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-modal>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
import PersonnelSelection from '@/components/PersonnelSelection/index'
import moment from 'moment'
export default {
name: 'batSetting',
props: ['url', 'roleSwitchingCode'],
components: {
PersonnelSelection
},
data() {
return {
visible: false,
confirmLoading: false,
formInline: {},
rules: {},
ids: [],
firstLevelDutyTerritoryList: [],
configurationItemList: [],
engineeringInterfacePersonList: [],
typeOfDeliverablesList: [],
name: '',
DeliverableTreeList: [],
dutyTerritoryList: []
}
},
mounted() {
},
methods: {
disabledDate(current) {
return current && current < moment().subtract(1, 'day')
},
getFirstLevelDutyTerritory() {
getAction('/sys/dictItem/getFirstLevelDutyTerritory', {}).then((res) => {
if (res.success) {
this.firstLevelDutyTerritoryList = res.result
} else {
this.firstLevelDutyTerritoryList = []
}
})
},
DutyDepartChange(event) {
this.formInline.dutyTerritory = []
this.formInline = { ...this.formInline }
this.getDutyTerritory(event.join(','))
},
getDutyTerritory(row) {
let query = {
dutyDepart: row
}
getAction('/sys/dict/getDutyTeryByDD', query).then((res) => {
if (res.success) {
this.dutyTerritoryList = res.result || []
} else {
this.dutyTerritoryList = []
}
})
},
getDeliverableTree() {
getAction('/sys/category/getCertificationDeliverableTree', {}).then((res) => {
if (res.success) {
this.DeliverableTreeList = res.result
} else {
this.DeliverableTreeList = []
}
})
},
edit(data, name, content) {
this.visible = true
this.getDeliverableTree()
this.getFirstLevelDutyTerritory()
this.$nextTick(() => {
this.ids = data || []
this.formInline = {}
this.dutyTerritoryList = []
this.name = name
if (content && name == this.$t('BatchSetting')) {
// this.formInline.dutyTerritory = content.dutyTerritory
// this.queryPersonByProject(content.dutyTerritory)
}
this.formInline = { ...this.formInline }
})
},
handleOk() {
// if (this.formInline.dutyTerritory) {
// this.handleOkTwo()
// } else {
this.handleOkOne()
// }
},
PersonnelSelectionChange(value, id) {
this.formInline[value] = id
this.formInline = { ...this.formInline }
},
handleOkOne() {
let ids = JSON.parse(JSON.stringify(this.ids))
let formInline = JSON.parse(JSON.stringify(this.formInline))
Object.keys(formInline).forEach(res => {
if (formInline[res] && formInline[res] instanceof Array) {
formInline[res] = formInline[res].join(',')
}
})
let query = {
ids: ids.join(','),
...formInline
}
let url = ''
this.confirmLoading = true
if (this.name == this.$t('changeSetting')) {
url = '/project/projectCertificationInventoryEO/updateConfigItemBatch'
} else {
url = this.url.setBatch
}
if (!query.configItem) {
query.configItem = undefined
}
postAction(url, query).then((res) => {
if (res.success) {
this.$message.success(this.$t('OperationSuccessful'))
this.visible = false
this.confirmLoading = false
this.$emit('batSettingForm')
} else {
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
}
})
},
handleOkTwo() {
let _this = this
this.$confirm({
content: _this.$t('areResponsibilityAreaInformationBatch'),
onOk() {
let ids = JSON.parse(JSON.stringify(_this.ids))
let query = {
ids: ids.join(','),
..._this.formInline
}
_this.confirmLoading = true
postAction(_this.url.setBatch, query).then((res) => {
if (res.success) {
_this.$message.success(_this.$t('OperationSuccessful'))
_this.visible = false
_this.confirmLoading = false
_this.$emit('batSettingForm')
} else {
_this.$message.warning(_this.$t('operationFailed'))
_this.confirmLoading = false
}
})
}
})
},
handleCancel() {
this.formInline = {}
this.visible = false
},
handleInput(value) {
this.$nextTick(() => {
this.formInline = { ...this.formInline }
this.$refs.ruleForm.validateField([value])
})
},
dateChange(item) {
this.formInline[item.db_field_name] = this.formInline[item.db_field_name] ? moment(this.formInline[item.db_field_name]).format('YYYY-MM-DD') : ''
},
handleChange(value) {
this.formInline.sdt = undefined
this.queryPersonByProject(this.formInline.dutyTerritory.join(','))
this.formInline = {...this.formInline}
},
queryPersonByProject(row) {
let query = {
projectId: this.$route.query.id,
dutyTerritory: row
}
getAction('/project/projectRelatedPersonnel/queryPersonByProjectId', query).then((res) => {
if (res.success) {
this.engineeringInterfacePersonList = res.result.engineeringInterfacePersonList || [] //工程接口人
}
})
}
}
}
</script>
<style>
.formAdd .ant-form-item-label {
width: 130px;
}
.formAdd .ant-form-item-control-wrapper {
display: inline-block;
width: 100%;
}
/*.formAdd .ant-form-item {*/
/* margin-bottom: 20px;*/
/*}*/
.itemModel .ant-form-item-control-wrapper {
width: 100%;
}
.box-input .ant-select-selection--single {
height: 38px;
}
.box-input .ant-select-selection--multiple {
height: 38px;
}
.box-input .ant-select-selection__rendered {
line-height: 38px;
height: 38px;
}
.box-input .ant-select-selection--multiple .ant-select-selection__rendered > ul > li {
margin-top: 6px;
}
.box-input .ant-calendar-picker {
line-height: 38px;
height: 38px;
}
.box-input .ant-calendar-picker-input {
height: 38px;
}
.box-input .ant-input-number-input-wrap {
line-height: 38px;
height: 38px;
}
.box-input .ant-calendar-picker-input {
padding: 4px 30px 4px 11px;
}
</style>
<style scoped>
.box-title-text {
line-height: 1.4;
display: flex;
}
.title-text {
width: 104px;
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: 42px;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 130px);
display: inline-block;
margin-top: 2px;
}
.title-text-text {
margin-top: 9px;
}
.formAdd {
margin-bottom: 40px;
}
</style>
@@ -0,0 +1,143 @@
<template>
<a-modal
:title="title"
:width="500"
:visible="visible"
:confirm-loading="confirmLoading"
:maskClosable="false"
@ok="handleOk"
@cancel="handleCancel"
>
<a-spin :spinning="confirmLoading">
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24">
<a-col :span="24">
<div class="box-title-text-index">
<div class="title-text-index" style="width: 100px">
<span class="Required">*</span>
<span class="title-text-text"
:title="$t('cutoffTime')">
{{ $t('cutoffTime') }}
</span>
</div>
<a-form-model-item class="itemModel" style="width: calc(100% - 120px)" :prop="queryData.dutyDueDate">
<a-date-picker class="box-input"
:placeholder="$t('PleaseSelect')+$t('cutoffTime')"
@change="dateChange({'db_field_name':queryData.dutyDueDate})"
format="YYYY-MM-DD"
:disabledDate="disabledDate"
:getCalendarContainer="(trigger) => trigger.parentNode"
v-model="formInline[queryData.dutyDueDate]"
style="width: 100%"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-spin>
</a-modal>
</template>
<script>
import moment from 'moment'
export default {
name: 'deadlineForm',
data() {
return {
title: '',
visible: false,
confirmLoading: false,
formInline: {},
rules: {},
queryData:{},
}
},
methods: {
getData(val) {
this.queryData = val
this.title = val.title
this.visible = true
this.formInline = {}
this.confirmLoading = false
this.$nextTick(() => {
this.$refs.ruleForm.clearValidate()
this.rules[val.dutyDueDate] = [
{
required: true,
message: this.$t('cutoffTime') + this.$t('cannotEmpty'),
trigger: 'change'
},
]
})
},
handleOk() {
this.$refs.ruleForm.validate(valid => {
if (valid) {
this.$emit('deadlineDataForm', this.queryData,this.formInline)
this.confirmLoading = true
}
})
},
handleCancel() {
this.visible = false
},
//时间禁用
disabledDate(current) {
return current && current < moment().subtract(1, 'day')
},
dateChange(item) {
this.formInline[item.db_field_name] = this.formInline[item.db_field_name] ? moment(this.formInline[item.db_field_name]).format('YYYY-MM-DD') : ''
}
}
}
</script>
<style scoped>
.box-title-text-index {
line-height: 1.4;
display: flex;
}
.title-text {
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;
}
.title-text-index {
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;
line-height: 40px;
}
.box-input {
display: inline-block;
width: calc(100% - 120px);
height: 38px;
margin-top: 2px;
}
.Required {
color: red;
margin-right: 4px;
}
</style>
@@ -0,0 +1,179 @@
<template>
<a-drawer
:title="$t('modifyHistory')"
:maskClosable="false"
:width="1000"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<div style="margin-bottom: 60px">
<a-table
:columns="columns"
rowKey="id"
:scroll="{x: '100%'}"
:data-source="dataList"
:pagination="false"
:loading="loading">
</a-table>
<div class="page" v-if="dataList.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="onChange"
@showSizeChange="SizeChange"
/>
</div>
</div>
<div class="drawer-bootom-button">
<a-button @click="handleCancel" type="primary">{{$t('determine')}}</a-button>
</div>
</a-drawer>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
export default {
name: 'modifyHistoryList',
data() {
return {
visible: false,
dataList: [],
confirmLoading: false,
loading: false,
pageNo: 1,
pageSize: 10,
total: 0,
projectCertificationInventoryId: '',
url: {
list: '/project/projectCertificationInventoryLogEO/page'
},
columns: [
{
title: this.$t('Operator'),
dataIndex: 'createBy',
align: 'left',
ellipsis: true,
width: 108
},
{
title: this.$t('operationTime'),
dataIndex: 'createTime',
align: 'left',
ellipsis: true,
width: 148
},
{
title: this.$t('OperationContent'),
dataIndex: 'content',
align: 'left',
ellipsis: true,
width: 528
}
]
}
},
mounted() {
},
methods: {
handleCancel() {
this.visible = false
},
getList(id) {
this.pageNo = 1
this.visible = true
this.projectCertificationInventoryId = id
this.replacePage()
},
onChange(page, pageSize) {
this.pageNo = page
this.replacePage()
},
SizeChange(page, pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.replacePage()
},
replacePage() {
let query = {
pageNo: this.pageNo,
pageSize: this.pageSize,
projectCertificationInventoryId: this.projectCertificationInventoryId
}
this.loading = true
getAction(this.url.list, query).then((res) => {
if (res.success) {
this.dataList = res.result.records || []
this.total = res.result.total
this.loading = false
} else {
this.dataList = []
this.total = 0
this.loading = false
}
})
}
}
}
</script>
<style scoped>
.page {
text-align: right;
margin-top: 20px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
width: 100%;
z-index: 100;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
.box-title-text {
line-height: 1.4;
display: flex;
align-items: center;
margin-bottom: 10px;
}
.title-text {
width: 110px;
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;
}
</style>
@@ -0,0 +1,139 @@
<template>
<div>
<a-modal
:title="title"
:width="600"
:visible="visible"
:confirm-loading="confirmLoading"
:maskClosable="false"
@ok="handleOk"
@cancel="handleCancel"
>
<a-form-model :model="formInline" class="formAdd" :rules="rules"
ref="ruleForm">
<a-row :gutter="24">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="title">{{ title }}</span>
</div>
<a-form-model-item class="itemModel" :prop="'reasonForReturn'">
<a-textarea :placeholder="$t('pleaseEnter')+title"
v-model.trim="formInline.reasonForReturn"
:rows="4"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-modal>
</div>
</template>
<script>
export default {
name: 'reasonForReturn',
data() {
return {
visible: false,
confirmLoading: false,
formInline: {},
rules: {},
value: '',
text: '',
ids: [],
notConditions: '',
data: '',
title: ''
}
},
mounted() {
},
methods: {
getData(value, text, ids, notConditions, data, title) {
this.value = value
this.text = text
this.ids = ids
this.notConditions = notConditions
this.data = data
this.title = title
this.visible = true
this.formInline = {}
this.confirmLoading = false
this.$nextTick(() => {
this.$refs.ruleForm.clearValidate()
this.rules = {
reasonForReturn: [
{
required: true,
message: title + this.$t('cannotEmpty'),
trigger: 'blur'
},
{
max: 300,
message: title + this.$t('cannotExceed') + 300 + this.$t('Characters'),
trigger: 'blur'
}
]
}
})
},
handleOk() {
this.$refs.ruleForm.validate(valid => {
if (valid) {
this.$emit('reasonForReturnForm', this.value, this.text, this.ids, this.notConditions, this.data,this.formInline.reasonForReturn)
this.confirmLoading = true
}
})
},
handleCancel() {
this.visible = false
}
}
}
</script>
<style scoped>
.box-title-text {
line-height: 1.4;
/*display: flex;*/
/*align-items: center;*/
}
.title-text {
width: 124px;
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;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 140px);
display: inline-block;
margin-top: 2px;
margin-bottom: 14px;
}
.Required {
color: red;
margin-right: 4px;
}
.title-text-text {
margin-top: 9px;
}
</style>
@@ -0,0 +1,266 @@
<template>
<a-drawer
:title="$t('referenceDeliverables')"
:maskClosable="false"
:width="1000"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<div style="margin-bottom: 60px">
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :md="12" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('entryName')">
<span>{{$t('entryName')}}</span>
</div>
<a-input class="box-input" :placeholder="$t('PleaseEnter')+$t('entryName')"
v-model="queryParam.projectName"></a-input>
</div>
</a-col>
<span style="float: right;overflow: hidden;margin-right: 11px" class="table-page-search-submitButtons">
<a-col :md="12" :sm="24">
<a-button class="box-button" @click="searchReset">{{$t('reset')}}</a-button>
<a-button class="box-button" style="margin-left: 8px" type="primary" @click="searchQuery">{{$t('query')}}</a-button>
</a-col>
</span>
</a-row>
</a-form>
</div>
<a-table
:columns="columns"
rowKey="id"
:scroll="{x: '100%',y:'calc(100vh - 330px)'}"
:data-source="dataList"
:pagination="false"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange,columnTitle:' '}"
:loading="loading">
</a-table>
<div class="page" v-if="dataList.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="onChange"
@showSizeChange="SizeChange"
/>
</div>
</div>
<div class="drawer-bootom-button">
<a-button @click="handleCancel" style="margin-right: 16px">{{$t('cancel')}}</a-button>
<a-button @click="handleSubmit" type="primary" :loading="confirmLoading">{{$t('determine')}}</a-button>
</div>
</a-drawer>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
export default {
name: 'referenceDeliverablesList',
components: {},
props: ['url'],
data() {
return {
visible: false,
queryParam: {},
confirmLoading: false,
selectedRowKeys: [],
columns: [
{
title: this.$t('entryName'),
dataIndex: 'projectName',
align: 'left',
ellipsis: true,
width: 223
},
{
title: 'Studio',
dataIndex: 'studioEngineerName',
align: 'left',
ellipsis: true,
width: 140
},
{
title: this.$t('explain'),
dataIndex: 'explanation',
align: 'left',
ellipsis: true,
width: 223
}
],
dataList: [],
content: [],
loading: false,
pageNo: 1,
pageSize: 10,
total: 0,
ids: '',
detailedWarningList: []
}
},
mounted() {
},
methods: {
transferModel(ids, detailedWarningList) {
this.visible = true
this.queryParam = {}
this.detailedWarningList = detailedWarningList
this.selectedRowKeys = []
this.ids = ids.join(',')
this.replacePage()
},
searchQuery() {
this.pageNo = 1
this.replacePage()
},
searchReset() {
this.pageNo = 1
this.queryParam = {}
this.replacePage()
},
onChange(page, pageSize) {
this.pageNo = page
this.replacePage()
},
SizeChange(page, pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.replacePage()
},
replacePage() {
let query = {
pageNo: this.pageNo,
pageSize: this.pageSize,
...this.queryParam
}
this.loading = true
postAction('project/projectLibraryBase/page', query).then((res) => {
if (res.success) {
this.dataList = res.result.records || []
this.total = res.result.total
this.loading = false
} else {
this.loading = false
}
})
},
onSelectChange(value) {
this.selectedRowKeys = value
if (this.selectedRowKeys.length > 1) {
this.selectedRowKeys.shift()
}
},
handleCancel() {
this.visible = false
},
failedMessageOne(data) {
let detailedWarningList = data
this.$warning({
content: ( < div > { detailedWarningList } < /div>)
})
},
handleSubmit() {
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
let selectedRowKeys = JSON.parse(JSON.stringify(this.selectedRowKeys))
if (selectedRowKeys.join(',') == this.$route.query.id) {
this.$message.warning(this.$t('theDeliverablesCannotReferencedPleaseReselect'))
return
}
this.confirmLoading = true
postAction('/project/projectCertificationInventoryEO/citeDeliverable', {
projectCertificationInventoryIds: this.ids,
projectLibraryId: this.$route.query.id,
citeProjectLibraryId: selectedRowKeys.join(',')
}).then((res) => {
if (res.success) {
this.confirmLoading = false
if (res.result) {
this.$message.warning(res.result)
} else {
this.$message.success(this.$t('OperationSuccessful'))
}
this.visible = false
this.selectedRowKeys = []
this.$emit('referenceDeliverablesListForm')
if (this.detailedWarningList && this.detailedWarningList.length > 0) {
this.failedMessageOne(this.detailedWarningList)
}
} else {
if (res.result) {
this.$message.warning(res.result)
} else {
this.$message.warning(this.$t('operationFailed'))
}
this.confirmLoading = false
}
})
} else {
this.$message.warning(this.$t('selectLeastOne'))
}
}
}
}
</script>
<style scoped>
.page {
text-align: right;
margin-top: 20px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
z-index: 100;
width: 100%;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
.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;
}
</style>
@@ -0,0 +1,290 @@
<template>
<div>
<a-drawer
:title="$t('Transfer')"
:maskClosable="false"
:width="1000"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<div style="margin-bottom: 60px">
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :md="12" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('marketCertificationList')">
<span>{{$t('marketCertificationList')}}</span>
</div>
<j-input class="box-input" :placeholder="$t('PleaseEnter')+$t('marketCertificationList')"
v-model="queryParam.name"></j-input>
</div>
</a-col>
<span style="float: right;overflow: hidden;margin-right: 11px" class="table-page-search-submitButtons">
<a-col :md="12" :sm="24">
<a-button class="box-button" @click="searchReset">{{$t('reset')}}</a-button>
<a-button class="box-button" style="margin-left: 8px" type="primary" @click="searchQuery">{{$t('query')}}</a-button>
</a-col>
</span>
</a-row>
</a-form>
</div>
<a-table
:components="drag(columns,'columns')"
:columns="columns"
rowKey="id"
:scroll="{x: 800}"
:data-source="dataList"
:pagination="false"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange,columnTitle:' ' }"
:loading="loading">
</a-table>
<div class="page" v-if="dataList.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="onChange"
@showSizeChange="SizeChange"
/>
</div>
</div>
<div class="drawer-bootom-button">
<a-button @click="handleCancel" style="margin-right: 16px">{{$t('cancel')}}</a-button>
<a-button @click="handleSubmit(undefined)" type="primary" :loading="confirmLoading">{{$t('determine')}}
</a-button>
</div>
</a-drawer>
<transferListvirtal :url="url" @transferListFormHomo="transferListFormHomo" ref="transferListvirtalRef"/>
</div>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
import { ResizeHeader, ResizeColumnProvide } from '@/mixins/header'
import transferListvirtal from './transferListvirtal'
export default {
name: 'transferList',
components: {
transferListvirtal
},
props: ['url'],
mixins: [ResizeHeader, ResizeColumnProvide],
data() {
return {
visible: false,
queryParam: {},
confirmLoading: false,
selectedRowKeys: [],
columns: [
{
title: this.$t('marketCertificationList'),
dataIndex: 'name',
align: 'left',
ellipsis: true,
width: 223
},
{
title: this.$t('instructionForUse'),
dataIndex: 'useExplain',
align: 'left',
ellipsis: true,
width: 223
},
{
title: this.$t('updateTime'),
dataIndex: 'updateTime',
align: 'left',
ellipsis: true,
width: 223
},
{
title: this.$t('creater'),
dataIndex: 'createBy',
align: 'left',
ellipsis: true,
width: 223
}
],
dataList: [],
content: [],
loading: false,
pageNo: 1,
pageSize: 10,
total: 0
}
},
mounted() {
},
methods: {
transferModel() {
this.visible = true
this.queryParam = {}
this.selectedRowKeys = []
this.replacePage()
},
searchQuery() {
this.pageNo = 1
this.replacePage()
},
searchReset() {
this.pageNo = 1
this.queryParam = {}
this.replacePage()
},
onChange(page, pageSize) {
this.pageNo = page
this.replacePage()
},
SizeChange(page, pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.replacePage()
},
replacePage() {
let query = {
pageNo: this.pageNo,
pageSize: this.pageSize,
...this.queryParam,
state:'1',
}
this.loading = true
getAction('/authDummy/authDummyInventoryBaseEO/page', query).then((res) => {
if (res.success) {
if (res.result.current > 1 && res.result.records.length == 0) {
this.pageNo = 1
this.replacePage()
return
}
this.dataList = res.result.records || []
this.total = res.result.total
this.loading = false
} else {
this.loading = false
}
})
},
transferListFormHomo() {
this.visible = false
this.selectedRowKeys = []
this.$emit('transferListForm')
},
onSelectChange(value) {
this.selectedRowKeys = value
if (this.selectedRowKeys.length > 1) {
this.selectedRowKeys.shift()
}
},
handleCancel() {
this.visible = false
this.selectedRowKeys = []
this.$emit('visible')
},
handleSubmit(flag) {
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
this.confirmLoading = true
let selectedRowKeys = JSON.parse(JSON.stringify(this.selectedRowKeys))
this.confirmLoading = false
// this.$emit('transferListForm',selectedRowKeys.join(','))
this.$refs.transferListvirtalRef.transferModel(selectedRowKeys.join(','))
// this.selectedRowKeys = []
// postAction('project/projectLawsInventoryEO/add', {
// dummyInventoryBaseId: selectedRowKeys.join(','),
// projectLibraryId: this.$route.query.id,
// flag: flag
// }).then((res) => {
// if (res.success) {
// this.confirmLoading = false
// // this.$message.success(this.$t('OperationSuccessful'))
// // this.visible = false
// this.selectedRowKeys = []
// this.$emit('transferListForm',selectedRowKeys.join(','))
// } else {
// // if (res.message == '该虚拟清单的维护清单中没有数据,是否需要添加') {
// // this.confirmLoading = false
// // this.getAdd()
// // return
// // }
// this.$message.warning(this.$t('operationFailed'))
// this.confirmLoading = false
// }
// })
} else {
this.$message.warning(this.$t('selectLeastOne'))
}
},
getAdd() {
let _this = this
this.$confirm({
content: _this.$t('TheDoesNotContainData'),
onOk() {
_this.handleSubmit('1')
}
})
}
}
}
</script>
<style scoped>
.page {
text-align: right;
margin-top: 20px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
z-index: 100;
width: 100%;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
.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;
}
</style>
@@ -0,0 +1,329 @@
<template>
<a-drawer
:title="$t('Transfer')"
:maskClosable="false"
:width="1000"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<div style="margin-bottom: 60px">
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :md="12" :sm="5">
<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="12" :sm="5">
<div class="box-title-text">
<div class="title-text" :title="$t('category')">
<span>{{$t('category')}}</span>
</div>
<j-input class="box-input" :placeholder="$t('PleaseEnter')+$t('category')"
v-model="queryParam.category"></j-input>
</div>
</a-col>
<span style="float: right;overflow: hidden;margin-right: 11px" class="table-page-search-submitButtons">
<a-col :md="12" :sm="24">
<!-- <globalAdvancedQuery ref="globalAdvancedQueryRef"-->
<!-- @handleSuperQuery="handleSuperQuery"-->
<!-- :fieldList="fieldList"/>-->
<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-col>
</span>
</a-row>
</a-form>
</div>
<a-table
:columns="columns"
rowKey="id"
:scroll="{x: 800,y:'calc(100vh - 330px)'}"
:data-source="dataList"
:pagination="false"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange,columnTitle:'' }"
:loading="loading">
</a-table>
<!-- <div class="page" v-if="dataList.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="onChange"-->
<!-- @showSizeChange="SizeChange"-->
<!-- />-->
<!-- </div>-->
</div>
<div class="drawer-bootom-button">
<a-button @click="handleCancel" style="margin-right: 16px">{{$t('cancel')}}</a-button>
<a-button @click="handleSubmit(undefined)" type="primary" :loading="confirmLoading">{{$t('submit')}}</a-button>
</div>
</a-drawer>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
import globalAdvancedQuery from '@/components/globalAdvancedQuery/index'
export default {
name: 'transferList',
components: {
globalAdvancedQuery
},
props: ['url'],
data() {
return {
visible: false,
queryParam: {},
confirmLoading: false,
selectedRowKeys: [],
columns: [
{
title: this.$t('category'),
align: 'left',
dataIndex: 'category',
width: 150,
ellipsis: true
},
{
title: this.$t('inspectionItems'),
align: 'left',
dataIndex: 'inspectionItem',
width: 150,
ellipsis: true,
scopedSlots: { customRender: 'inspectionItems' }
},
{
title: 'WVTA ID',
align: 'left',
dataIndex: 'wvtaId',
width: 150,
ellipsis: true
},
{
title: this.$t('standard'),
align: 'left',
dataIndex: 'serialNumber',
width: 150,
ellipsis: true
},
{
title: this.$t('areaOfResponsibility'),
align: 'left',
dataIndex: 'dutyTerritoryName',
width: 100,
ellipsis: true
},
{
title: this.$t('typeOfDeliverables'),
align: 'left',
dataIndex: 'deliverableTypeName',
width: 200,
ellipsis: true
}
],
fieldList: [
{
type: 'string',
value: 'wvtaId',
text: 'WVTA ID'
},
{
type: 'string',
value: 'inspectionItem',
text: this.$t('inspectionItems')
},
{
type: '',
value: 'dutyTerritory',
text: this.$t('areaOfResponsibility'),
dictCode: 'duty_territory'//只要 dictCode 有值,无论 type 是什么,都显示为字典下拉框
}
],
dataList: [],
content: [],
loading: false,
dummyInventoryBaseId: '',
pageNo: 1,
pageSize: 10,
total: 0
}
},
mounted() {
},
methods: {
transferModel(id) {
this.visible = true
this.dummyInventoryBaseId = id
this.queryParam = {}
this.selectedRowKeys = []
this.replacePage()
},
searchQuery() {
this.pageNo = 1
this.replacePage()
},
searchReset() {
this.pageNo = 1
this.queryParam = {}
this.replacePage()
// this.$refs.globalAdvancedQueryRef.resetLine()
// this.$refs.globalAdvancedQueryRef.emitCallback()
},
onChange(page, pageSize) {
this.pageNo = page
this.replacePage()
},
SizeChange(page, pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.replacePage()
},
// handleSuperQuery(params, matchType) {
// let sqp = {}
// if (!params || (params && params.length == 0)) {
// sqp['superQueryParams'] = ''
// this.$refs.globalAdvancedQueryRef.superQueryFlag = false
// } else {
// this.$refs.globalAdvancedQueryRef.superQueryFlag = true
// sqp['superQueryParams'] = encodeURI(JSON.stringify(params))
// sqp['superQueryMatchType'] = matchType
// }
// this.queryParamQuery = sqp
// this.replacePage()
// },
replacePage() {
let query = {
// pageNo: this.pageNo,
// pageSize: this.pageSize,
...this.queryParamQuery,
...this.queryParam,
authDummyInventoryBaseId: this.dummyInventoryBaseId
}
this.loading = true
getAction('/authDummy/authDummyInventoryInfoEO/list', query).then((res) => {
if (res.success) {
this.dataList = res.result || []
this.loading = false
} else {
this.loading = false
}
})
},
onSelectChange(value) {
this.selectedRowKeys = value
// if (this.selectedRowKeys.length > 1) {
// this.selectedRowKeys.shift()
// }
},
handleCancel() {
this.visible = false
},
handleSubmit(flag) {
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
this.confirmLoading = true
let selectedRowKeys = JSON.parse(JSON.stringify(this.selectedRowKeys))
postAction('project/projectCertificationInventoryEO/callAdd', {
authDummyInventoryBaseId: this.dummyInventoryBaseId,
projectLibraryId: this.$route.query.id,
authDummyInventoryInfoIds: selectedRowKeys.join(',')
}).then((res) => {
if (res.success) {
this.confirmLoading = false
if (res.result && res.result.length > 0) {
let detailedWarningList = []
res.result.forEach(val => {
detailedWarningList.push(
< div > { val } < /div>)
})
this.$warning({
content: (
< div >
{ detailedWarningList }
< /div>
)
})
} else {
this.$message.success(this.$t('OperationSuccessful'))
}
this.visible = false
this.selectedRowKeys = []
this.$emit('transferListFormHomo')
} else {
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
}
})
} else {
this.$message.warning(this.$t('selectLeastOne'))
}
}
}
}
</script>
<style scoped>
.page {
text-align: right;
margin-top: 20px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
z-index: 100;
width: 100%;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
.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;
}
</style>
@@ -0,0 +1,402 @@
<template>
<div>
<a-drawer
:title="$t('comment')"
:maskClosable="false"
:width="482"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible">
<div class="button-box">
<a-input-search class="box-input box-input-search" allowClear
@search="allowClearChange"
:placeholder="$t('PleaseEnter')+$t('comment')"
v-model="commentContent"></a-input-search>
<a-button @click="submitQuery" style="margin-right: 8px;" type="primary">{{$t('query')}}</a-button>
<a-button @click="handleSubmit" class="button-text" :title="$t('publishComment')" type="primary">
{{$t('publishComment')}}
</a-button>
</div>
<div class="comment-box" v-if="dataList && dataList.length > 0">
<div class="comment-box-top-box" v-for="(item,index) in dataList" :key="index">
<!-- <div class="title-text">{{$t('record')+(index + 1)}}</div>-->
<div class="box-content">
<div class="img-box">
<img src="@/assets/daiban.png" class="img" alt="">
</div>
<div class="box-text">
<span class="box-text-name">{{item.name}}</span>
<span calss="box-text-time">{{item.createTime}}</span>
</div>
<div class="box-text-text">
{{item.content}}
</div>
<div class="box-icon" @click="messageClick(item)">
<a-icon type="message"/>
</div>
</div>
<div class="inside-box" v-if="item.projectCommentVOList && item.projectCommentVOList.length > 0">
<div class="box-content-inside" v-for="(val,indexOne) in item.projectCommentVOList" :key="indexOne">
<div class="img-box">
<img src="@/assets/daiban.png" class="img" alt="">
</div>
<div class="box-text">
<span class="box-text-name">{{val.name}}</span>
<span calss="box-text-time">{{val.createTime}}</span>
</div>
<div class="box-text-text">
{{val.content}}
</div>
<div class="box-icon" @click="messageClick(item)">
<a-icon type="message"/>
</div>
</div>
</div>
</div>
</div>
<div class="comment-box-text" v-else>{{$t('noComment')}}</div>
<JLoading :loading="loading">{{$t('dataLoading')}}</JLoading>
</a-drawer>
<a-modal
:title="title"
:width="500"
:visible="visibleComment"
:confirm-loading="confirmLoading"
:maskClosable="false"
@ok="handleOkComment"
@cancel="handleCancelComment"
>
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="title">{{title}}</span>
</div>
<a-form-model-item v-if="title == $t('replyToComments')" class="itemModel" :prop="'replyContent'">
<a-textarea
:placeholder="$t('PleaseEnter')+title"
:disabled="false"
v-model="formInline.replyContent" :rows="4"/>
</a-form-model-item>
<a-form-model-item v-else-if="title == $t('publishComment')" class="itemModel" :prop="'commentContent'">
<a-textarea
:placeholder="$t('PleaseEnter')+title"
:disabled="false"
v-model="formInline.commentContent" :rows="4"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-modal>
</div>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
export default {
name: 'commentList',
data() {
return {
visible: false,
dataList: [],
formInline: {},
commentContent: '',
loading: false,
title: this.$t('comment'),
confirmLoading: false,
visibleComment: false,
url: {
list: '/project/projectCommentEO/list',
add: '/project/projectCommentEO/add',
edit: '/project/projectReplyEO/add'
},
rules: {
commentContent: [
{
required: true,
message: this.$t('publishComment') + this.$t('cannotEmpty'),
trigger: 'blur'
}
],
replyContent: [
{
required: true,
message: this.$t('replyToComments') + this.$t('cannotEmpty'),
trigger: 'blur'
}
]
}
}
},
mounted() {
},
methods: {
handleCancel() {
this.visible = false
},
getData() {
this.visible = true
this.getList()
},
handleSubmit() {
this.title = this.$t('publishComment')
this.formInline = {}
this.visibleComment = true
this.$nextTick(() => {
this.$refs.ruleForm.clearValidate()
})
},
allowClearChange() {
this.getList()
},
submitQuery() {
this.getList()
},
getList() {
this.loading = true
getAction(this.url.list, {
projectLibraryId: this.$route.query.id,
commentContent: this.commentContent
}).then((res) => {
if (res.success) {
this.loading = false
this.dataList = res.result || []
} else {
this.loading = false
this.dataList = []
}
})
},
handleOkComment() {
this.$refs.ruleForm.validate(valid => {
if (valid) {
let url = ''
let query = {}
if (this.title == this.$t('publishComment')) {
url = this.url.add
query = {
commentContent: this.formInline.commentContent,
projectLibraryId: this.$route.query.id
}
} else if (this.title == this.$t('replyToComments')) {
url = this.url.edit
query = {
replyContent: this.formInline.replyContent,
projectCommentId: this.formInline.projectCommentId
}
}
this.confirmLoading = true
postAction(url, query).then((res) => {
if (res.success) {
this.$message.success(this.$t('OperationSuccessful'))
this.visibleComment = false
this.confirmLoading = false
this.getList()
} else {
this.confirmLoading = false
this.$message.success(this.$t('operationFailed'))
}
})
}
})
},
handleCancelComment() {
this.visibleComment = false
},
messageClick(row) {
this.formInline = {}
this.formInline.projectCommentId = row.id
this.title = this.$t('replyToComments')
this.visibleComment = true
this.$nextTick(() => {
this.$refs.ruleForm.clearValidate()
})
}
}
}
</script>
<style scoped lang="less">
.comment-box {
position: absolute;
left: 0;
height: calc(100% - 140px);
width: 100%;
overflow: auto;
padding: 0 24px 24px 24px;
box-sizing: border-box;
}
.comment-box-top-box {
padding: 30px 24px 24px 24px;
box-sizing: border-box;
border: 1px solid #F1F2F4;
border-radius: 4px;
margin-bottom: 24px;
}
.img-box {
width: 32px;
height: 32px;
border-radius: 50%;
display: inline-block;
margin-right: 8px;
position: absolute;
.img {
width: 100%;
height: 100%;
}
}
.box-text {
display: inline-block;
position: absolute;
margin-left: 40px;
.box-text-name {
font-size: 14px;
font-weight: bold;
color: #040B29;
margin-right: 8px;
}
.box-text-time {
font-size: 14px;
font-weight: 400;
color: #6F7385;
}
}
.box-text-text {
font-size: 14px;
font-weight: 400;
color: #040B29;
display: inline-block;
margin-top: 22px;
margin-left: 40px;
}
.title-text {
font-size: 16px;
font-weight: 400;
color: #040B29;
margin-bottom: 18px;
}
.box-content {
position: relative;
}
.box-content-inside {
position: relative;
margin-bottom: 15px;
}
.box-icon {
position: absolute;
right: 0;
top: 0;
cursor: pointer;
}
.inside-box {
background: #F6F7FA;
border-radius: 4px;
margin-left: 40px;
width: calc(100% - 40px);
padding: 18px;
box-sizing: border-box;
margin-top: 15px;
}
.button-box {
text-align: right;
margin-bottom: 24px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
width: 100%;
z-index: 100;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
.box-title-text {
line-height: 1.4;
display: flex;
/*align-items: center;*/
}
.title-text {
width: 74px;
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;
}
.itemModel {
width: calc(100% - 64px);
display: inline-block;
margin-top: 2px;
}
.Required {
color: red;
margin-right: 4px;
}
.title-text-text {
margin-top: 9px;
}
.comment-box-text {
text-align: center;
margin-top: 40px;
}
.box-input {
width: calc(100% - 183px);
margin-right: 8px;
}
.button-text {
width: 88px;
overflow: hidden;
padding: 0 8px;
//box-sizing: border-box;
float: right;
}
::v-deep .button-text span {
width: 64px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
margin-top: 4px;
}
</style>
<style>
.box-input-search .ant-input-suffix .ant-input-search-icon{
display: none;
}
</style>
@@ -0,0 +1,302 @@
<!--平台件-->
<template>
<div class="box-top-content-right">
<div class="box-top-content-right-bottom">
<div class="process-content" v-if="timeData && timeData.length > 0">
<div class="process-content-right-xian"></div>
<div class="process-content-right-xian-color"></div>
<div class="process-content-right-xian-one"></div>
<div class="process-content-content" :style="val.left"
v-for="(val,indexOne) in timeData" :key="indexOne" v-if="val.g">
<div class="process-content-right-top" :title="val.name">{{ val.name }}</div>
<div class="process-content-right-button" :title="val.time.slice(0, 11)">{{ val.time.slice(0, 11) }}</div>
<!-- <div class="process-content-right-button" v-if="indexOne % 2 == 1" :title="val.name">{{ val.name }}-->
<!-- </div>-->
<a-tooltip placement="topLeft" overlayClassName="tooltipColor">
<template slot="title">
<span>{{ val.name }}</span>
</template>
<img v-if="val.status == 1" src="@/assets/heiTop.png" class="process-content-left"
alt="">
<img v-else-if="val.status == 2" src="@/assets/kongTop.png"
class="process-content-left"
alt="">
<img v-else-if="val.status == 3" src="@/assets/shiTop.png" class="process-content-left"
alt="">
</a-tooltip>
<!-- <div class="process-content-right-button">{{val.time.slice(0,11)}}</div>-->
</div>
<div class="process-content-contentOne" :style="val.left"
v-for="(val,indexTwo) in timeData" v-if="!val.g">
<div class="process-content-right-top" :title="val.time.slice(0, 11)">{{ val.time.slice(0, 11) }}</div>
<div class="process-content-right-button" :title="val.name">{{ val.name }}
</div>
<a-tooltip placement="topLeft" overlayClassName="tooltipColor">
<template slot="title">
<span>{{ val.name }}</span>
</template>
<img v-if="val.status == 1" src="@/assets/huiBottom.png" class="process-content-left"
alt="">
<img v-else-if="val.status == 2" src="@/assets/kongBottom.png"
class="process-content-left"
alt="">
<img v-else-if="val.status == 3" src="@/assets/shiBottom.png" class="process-content-left"
alt="">
</a-tooltip>
</div>
</div>
</div>
</div>
</template>
<script>
import { getAction, postAction, downloadFile, putAction } from '@/api/manage'
export default {
name: 'complianceCertificationForm',
data() {
return {
regulatoryCertificationTaskPlanList: [],
timeData: [],
url: {
queryByProjectId: 'project/projectTaskPlanning/queryByProjectId'
}
}
},
mounted() {
this.getSetting()
},
methods: {
//传入 YYYY-MM , YYYY-MM (2020-09) (2020-12) 返回 YYYY-MM 数组
getYearAndMonth(start, end) {
let result = [];
let starts = start.split('-');
let ends = end.split('-');
let staYear = parseInt(starts[0]);
let staMon = parseInt(starts[1]);
let endYear = parseInt(ends[0]);
let endMon = parseInt(ends[1]);
while (staYear <= endYear) {
if (staYear === endYear) {
while (staMon < endMon) {
staMon++;
var str = staYear + '-'+(staMon >= 10 ? staMon : '0' + staMon);
result.push(str);
}
staYear++;
} else {
staMon++;
if (staMon > 12) {
staMon = 1;
staYear++;
}
let str = staYear + '-'+(staMon >= 10 ? staMon : '0' + staMon);
result.push(str);
}
}
return result;
},
getSetting() {
getAction(this.url.queryByProjectId, { projectId: this.$route.query.id }).then((res) => {
if (res.success) {
this.timeData = res.result || []
let startTime = ''
let endTime = ''
if (this.timeData.length > 0) {
startTime = this.timeData[0].time.slice(0, 7)
endTime = this.timeData[this.timeData.length - 1].time.slice(0, 7)
let monDiff = this.getYearAndMonth(startTime, endTime)
monDiff.unshift(startTime)
setTimeout(() => {
let dataList = document.getElementsByClassName('box-top-content-right-bottom')
let clientWidth = dataList[0].clientWidth
clientWidth = clientWidth / monDiff.length
for (let i = 0; i < monDiff.length; i++) {
for (let j = 0; j < this.timeData.length; j++) {
let num = (Math.floor(clientWidth / 30 * 10000)/10000) * parseInt(this.timeData[j].time.slice(8, 10))
if (this.timeData[j].time.slice(0, 7) == monDiff[i]) {
this.timeData[j].left = 'left:' + ((clientWidth * i + num) - 10) + 'px'
}
}
}
console.log(this.timeData)
this.timeData = [...this.timeData]
}, 500)
}
} else {
this.regulatoryCertificationTaskPlanList = []
}
})
}
}
}
</script>
<style scoped lang="less">
.box-top-content-right {
width: 100%;
padding: 0 24px;
box-sizing: border-box;
}
.box-top-content-right-bottom {
position: relative;
/*padding-top: 50px;*/
}
.process-content {
position: relative;
height: 110px;
/*overflow:hidden;*/
.process-content-content {
background: transparent;
z-index: 98;
/*padding: 0 6px;*/
position: absolute;
left: 40px;
text-align: center;
width: 16px;
height: 16px;
border-radius: 50%;
margin-top: 37px;
.process-content-left {
width: 16px;
height: 16px;
/*margin-top: 5px;*/
}
.process-content-right-top {
font-size: 12px;
color: #040B29;
width: 83px;
background: #fff;
display: inline-block;
position: absolute;
top: -15px;
left: 50%;
transform: translate(-50%, -50%);
overflow: hidden;
display: -webkit-box;
text-overflow: ellipsis;
/*! autoprefixer: off */
-webkit-box-orient: vertical;
-webkit-line-clamp: 2;
/*! autoprefixer: on;*/
text-justify: inter-ideograph;
word-break: break-all
}
.process-content-right-button {
width: 83px;
font-size: 12px;
font-weight: 400;
color: #9C9FAC;
position: absolute;
left: 50%;
top: -36px;
transform: translate(-50%, -50%);
overflow: hidden;
display: -webkit-box;
text-overflow: ellipsis;
/*! autoprefixer: off */
-webkit-box-orient: vertical;
-webkit-line-clamp: 2;
/*! autoprefixer: on;*/
text-justify: inter-ideograph;
word-break: break-all
}
}
.process-content-contentOne {
background: transparent;
z-index: 98;
/*padding: 0 6px;*/
position: absolute;
left: 40px;
text-align: center;
width: 16px;
height: 16px;
border-radius: 50%;
margin-top: 63px;
.process-content-left {
width: 12px;
height: 12px;
/*margin-top: 5px;*/
}
.process-content-right-top {
font-size: 12px;
width: 83px;
background: #fff;
display: inline-block;
overflow: hidden;
position: absolute;
color: #9C9FAC;
top: 57px;
left: 50%;
transform: translate(-50%, -50%);
overflow: hidden;
display: -webkit-box;
text-overflow: ellipsis;
/*! autoprefixer: off */
-webkit-box-orient: vertical;
-webkit-line-clamp: 2;
/*! autoprefixer: on;*/
text-justify: inter-ideograph;
word-break: break-all
}
.process-content-right-button {
width: 83px;
font-size: 12px;
font-weight: 400;
color: #040B29;
background: #fff;
position: absolute;
left: 50%;
top: 36px;
line-height: 11px;
transform: translate(-50%, -50%);
overflow: hidden;
display: -webkit-box;
text-overflow: ellipsis;
/*! autoprefixer: off */
-webkit-box-orient: vertical;
-webkit-line-clamp: 2;
/*! autoprefixer: on;*/
text-justify: inter-ideograph;
word-break: break-all
}
}
.process-content-right-xian {
height: 1px;
width: 100%;
background: #00B3BE;
position: absolute;
top: 48px;
}
.process-content-right-xian-color {
height: 28px;
width: 100%;
position: absolute;
top: 48px;
background: linear-gradient(90deg, rgba(0, 179, 190, 0.12) 0%, rgba(4, 11, 41, 0.02) 100%);
transform: matrix(-1, 0, 0, 1, 0, 0);
}
.process-content-right-xian-one {
height: 1px;
width: 100%;
background: #00B3BE;
position: absolute;
top: 74px;
}
}
</style>
@@ -0,0 +1,189 @@
<!--催办-->
<template>
<a-modal
:title="title"
:width="700"
:visible="visible"
:confirm-loading="confirmLoading"
:maskClosable="false"
@ok="handleOk"
@cancel="visible = false"
>
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('taskType')">{{$t('taskType')}}</span>
</div>
<!-- mode="multiple"-->
<a-form-model-item class="itemModel" prop="type">
<a-select v-model="formInline.type"
class='box-input'
:placeholder="$t('PleaseSelect') + $t('taskType')"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
allowClear>
<a-select-option v-for="(item, key) in cuibanList" :key="key" :value="item.value">
<span style="display: inline-block;width: 100%" :title=" item.label ">
{{ item.label }}
</span>
</a-select-option>
</a-select>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-modal>
</template>
<script>
import { postAction, putAction, getAction } from '@/api/manage'
export default {
name: 'TaskListModel',
data() {
return {
formInline: {},
selectionRowsArray:[],
rules: {
type: [
{
required: true,
message: this.$t('PleaseSelect') + this.$t('taskType'),
trigger: 'change'
}
]
},
title:'',
visible: false,
confirmLoading: false,
studioList: [],
cuibanList:[
{ label: this.$t('confirmationOfDesignConformity'), value: '2' },
{ label: this.$t('PrehomoConfirmation'), value: '3' },
{ label: this.$t('verificationAndConformityconfirmation'), value: '4' },
],
ids:'',
disabled: false,
url: {
edit: '/project/projectTaskInventoryEO/edit',
addOrUpdate: '/project/projectTaskInventoryConditionAssessmentEO/addOrUpdate',
list: '/project/projectTaskInventoryConditionAssessmentEO/list'
}
}
},
mounted() {
},
methods: {
getData(val) {
this.visible = true
this.title = this.$t('CuiBan')
this.selectionRowsArray = val
this.$nextTick(() => {
this.formInline = {}
this.$refs.ruleForm.clearValidate()
})
},
getList(val) {
getAction(this.url.list, { projectLawsInventoryId: val.projectLawsInventoryId }).then((res) => {
if (res.success) {
this.studioList = res.result || []
} else {
this.studioList = []
}
})
},
handleInput(value) {
this.$nextTick(() => {
this.formInline = { ...this.formInline }
this.$refs.ruleForm.validateField([value])
})
},
handleOk() {
if (this.disabled) {
this.visible = false
return
}
this.$refs.ruleForm.validate(valid => {
if (valid) {
let ProjectTaskUrgVo = {}
let projectLawsInventoryId = []
this.selectionRowsArray.forEach((item) => {
if(item.projectLawsInventoryId){
projectLawsInventoryId.push(item.projectLawsInventoryId)
}
})
ProjectTaskUrgVo = {
projectLawsInventoryIds: projectLawsInventoryId.join(','),
type: this.formInline.type,
}
this.confirmLoading = true
postAction('/project/projectLawsInventoryEO/taskUrg', ProjectTaskUrgVo).then((res) => {
if (res.success) {
this.visible = false
this.confirmLoading = false
this.$message.success(this.$t('OperationSuccessful'))
this.$emit('cibanModel')
} else {
this.$message.warning(res.message)
this.confirmLoading = false
}
})
}
})
}
}
}
</script>
<style scoped>
.box-title-text {
line-height: 1.4;
display: flex;
}
.Required {
color: red;
margin-right: 4px;
}
.title-text {
width: 134px;
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: 42px;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(80% - 130px);
display: inline-block;
margin-top: 2px;
}
.title-text-text {
margin-top: 9px;
}
.headerText {
margin-left: 30px;
color: #040B29;
font-weight: 400;
}
</style>
@@ -0,0 +1,280 @@
<template>
<a-drawer
:title="$t('customize')"
:maskClosable="false"
:width="1000"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<div style="margin-bottom: 60px">
<a-table
:components="drag(columns,'columns')"
:columns="columns"
:rowKey="record=> record.key"
:scroll="{x: 800}"
:data-source="dataList"
:pagination="false"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange,columnTitle:'',getCheckboxProps: getCheckboxProps }"
:loading="loading">
</a-table>
<!-- <div class="page" v-if="dataList.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="onChange"-->
<!-- @showSizeChange="SizeChange"-->
<!-- />-->
<!-- </div>-->
</div>
<div class="drawer-bootom-button">
<a-button @click="handleCancel" style="margin-right: 16px">{{$t('cancel')}}</a-button>
<a-button @click="handleSubmit(undefined)" type="primary" :loading="confirmLoading">{{$t('determine')}}</a-button>
</div>
</a-drawer>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
import { ResizeHeader, ResizeColumnProvide } from '@/mixins/header'
export default {
name: 'transferList',
components: {},
props: ['url'],
mixins:[ResizeHeader, ResizeColumnProvide],
data() {
return {
visible: false,
queryParam: {},
confirmLoading: false,
selectedRowKeys: [],
columns: [
{
title: this.$t('customColumn'),
dataIndex: 'name',
align: 'left',
ellipsis: true,
width: 884
},
],
dataList: [
{
orderBy: '1',
name: '1',
id: '1',
status:1,
},
{
orderBy: '2',
name: '2',
id: '12',
status:2,
},
{
orderBy: '3',
name: '3',
id: '13',
},
{
orderBy: '4',
name: '4',
id: '15',
},
{
orderBy: '5',
name: '4',
id: '16',
},
{
orderBy: '6',
name: '4',
id: '17',
},
{
orderBy: '7',
name: '4',
id: '18',
},
{
orderBy: '8',
name: '4',
id: '19',
status:2,
},
],
content: [],
loading: false,
pageNo: 1,
pageSize: 10,
total: 0
}
},
mounted() {
},
methods: {
transferModel() {
this.visible = true
this.queryParam = {}
this.selectedRowKeys = []
// this.replacePage()
},
searchQuery() {
this.pageNo = 1
this.replacePage()
},
searchReset() {
this.pageNo = 1
this.queryParam = {}
this.replacePage()
},
onChange(page, pageSize) {
this.pageNo = page
this.replacePage()
},
SizeChange(page, pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.replacePage()
},
replacePage() {
let query = {
pageNo: this.pageNo,
pageSize: this.pageSize,
...this.queryParam
}
this.loading = true
postAction(this.url.transferUrl, query).then((res) => {
if (res.success) {
this.dataList = res.result.records || []
this.total = res.result.total
this.loading = false
} else {
this.loading = false
}
})
},
onSelectChange(value) {
this.selectedRowKeys = value
// if (this.selectedRowKeys.length > 1) {
// this.selectedRowKeys.shift()
// }
},
getCheckboxProps(record) {
console.log(record.status, 'status');
return ({
props: {
//当状态是1或者2的时候执行disable
disabled: record.status === 1 || record.status === 2
}
})
},
handleCancel() {
this.visible = false
},
handleSubmit(flag) {
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
this.confirmLoading = true
let selectedRowKeys = JSON.parse(JSON.stringify(this.selectedRowKeys))
this.confirmLoading = false
this.$emit('transferListForm',selectedRowKeys.join(','))
this.selectedRowKeys = []
// postAction(this.url.addModel, {
// dummyInventoryBaseId: selectedRowKeys.join(','),
// projectLibraryId: this.$route.query.id,
// flag: flag
// }).then((res) => {
// if (res.success) {
// this.confirmLoading = false
// this.$message.success(this.$t('OperationSuccessful'))
// this.visible = false
// this.selectedRowKeys = []
// this.$emit('transferListForm')
// } else {
// if (res.message == '该虚拟清单的维护清单中没有数据,是否需要添加') {
// this.confirmLoading = false
// this.getAdd()
// return
// }
// this.$message.warning(this.$t('operationFailed'))
// this.confirmLoading = false
// }
// })
} else {
this.$message.warning(this.$t('selectLeastOne'))
}
},
getAdd() {
let _this = this
this.$confirm({
content: _this.$t('TheDoesNotContainData'),
onOk() {
_this.handleSubmit('1')
}
})
}
}
}
</script>
<style scoped>
.page {
text-align: right;
margin-top: 20px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
z-index: 100;
width: 100%;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
.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;
}
</style>
@@ -0,0 +1,507 @@
<template>
<div>
<a-drawer
:title="title"
:maskClosable="false"
:width="900"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<a-spin :spinning="confirmLoading">
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('title')">{{$t('title')}}</span>
</div>
<a-form-model-item class="itemModel" prop="title">
<a-input class="box-input"
v-model='formInline.title'
:disabled="disabled"/>
</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('problemType')">{{$t('problemType')}}</span>
</div>
<a-form-model-item class="itemModel-multi" prop="problemType">
<j-dict-select-tag class="box-input" v-model="formInline.problemType"
:disabled="disabled"
:type="'select'"
:triggerChange="false" :dictCode="'wen4_ti2_lei4_xing2'"/>
</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="'PS-issue'">{{'PS-issue'}}</span>
</div>
<div>
<a style='width: 273px;display: inline-block;white-space: nowrap;overflow: hidden;text-overflow: ellipsis;margin-top: 12px;'
:title='formInline.psIssue'
@click='UserFeedback(formInline.psIssue)'>{{formInline.psIssue}}</a>
</div>
</div>
</a-col>
</a-row>
<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('Relevantlawsregulations')">{{$t('Relevantlawsregulations')}}</span>
</div>
<a-form-model-item class="itemModel-multi" prop="creator">
<a-input class="box-input"
:title='formInline.lawsName'
v-model='formInline.lawsName'
:disabled="disabled"/>
</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('RelatedItems')">{{$t('RelatedItems')}}</span>
</div>
<a-form-model-item class="itemModel" prop="contentTemplate">
<a-select allowClear
class="box-input"
v-model="formInline.projectId"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
showSearch
mode="multiple"
:disabled="disabled"
optionFilterProp="label"
:autoClearSearchValue="false">
<a-select-option v-for="(item, key) in projectNameList"
:key="key"
:label="item.projectName"
:value="item.id">
<span style="display: inline-block;width: 100%" :title=" item.projectName ">
{{ item.projectName}}
</span>
</a-select-option>
</a-select>
</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="Required">*</span>-->
<span class="title-text-text"
:title="$t('statisticalNodes')">{{$t('statisticalNodes')}}</span>
</div>
<a-form-model-item class="itemModel-multi" prop="creator">
<a-select
allowClear
show-search
mode="multiple"
:disabled="disabled"
class="box-input-search"
optionFilterProp="label"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
v-model="formInline.dutyTerritory">
<a-select-option v-for="(item, key) in firstLevelDutyTerritoryList"
:key="key"
:label="item.key"
:value="item.key">
<span style="display: inline-block;width: 100%" :title=" item.key ">
{{ item.key }}
</span>
</a-select-option>
</a-select>
</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('Problemstate')">{{$t('Problemstate')}}</span>
</div>
<a-form-model-item class="itemModel" prop="contentTemplate">
<a-select allowClear
class="box-input"
v-model="formInline.problemState"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
showSearch
:disabled="disabled"
optionFilterProp="label"
:autoClearSearchValue="false">
<a-select-option v-for="(item, key) in ProblemstateList"
:label='item'
:key="key"
:value="item">
<span style="display: inline-block;width: 100%" :title=" item">
{{ item }}
</span>
</a-select-option>
</a-select>
</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('descriptions')">{{$t('descriptions')}}</span>
</div>
<a-form-model-item class="itemModel" prop="descriptions">
<a-input class="box-input"
v-model='formInline.description'
:disabled="disabled"/>
</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('documents')">{{$t('documents')}}</span>
</div>
<a-form-model-item class="itemModel" prop="fileLink">
<div v-for="(item,index) in formInline.fileLinkList" :key="index">
<a @click='UserFeedback(item.fileLink)'>{{item.fileLink}}</a>
</div>
<div v-for='(item,index) in formInline.fileList'>
<a @click='download(item)'>{{item.fileName}}</a>
</div>
</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('progresstracking')">{{$t('progresstracking')}}</span>
</div>
<a-form-model-item class="itemModel" prop="progresstracking">
<div v-for="(item,index) in formInline.progressTrackingList" :key="index">
<a-input class="box-input"
style='width: 89%'
v-model='item.progressTracking'
:title='item.progressTracking'
:disabled="true"/>
</div>
</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('conculsion')">{{$t('conculsion')}}</span>
</div>
<a-form-model-item class="itemModel" prop="conclusion">
<a-input class="box-input"
v-model='formInline.conclusion'
:disabled="disabled"/>
</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="Required">*</span>-->
<span class="title-text-text"
:title="$t('examineapproveevidence')">{{$t('examineapproveevidence')}}</span>
</div>
<a-form-model-item class="itemModel" prop="approvalEvidenceLink">
<div v-for="(item,index) in formInline.approvalEvidenceLinkList" :key="index">
<a @click='UserFeedback(item.approvalEvidenceLink)'>{{item.approvalEvidenceLink}}</a>
</div>
<div v-for='(item,index) in formInline.approvalEvidenceFileList'>
<a @click='download(item)'>{{item.fileName}}</a>
</div>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-spin>
<div class="drawer-bootom-button">
<a-button style="margin-right: 8px" @click="handleCancel">{{$t('close')}}</a-button>
</div>
</a-drawer>
</div>
</template>
<script>
import { getAction, postAction,putAction, downloadFile } from '@/api/manage'
import moment from 'moment'
import { mapGetters } from 'vuex'
export default {
name: 'fillAdd',
components: {
},
data() {
return {
rules: {
title: [
{
required: true,
message: this.$t('title') + this.$t('cannotEmpty'),
trigger: 'blur'
}
],
problemType: [
{
required: true,
message: this.$t('problemType') + this.$t('cannotEmpty'),
trigger: 'change'
}
],
},
visible: false,
visibletrack: false,
rulestracking:{
progressTracking: [
{
required: true,
message: this.$t('text') + this.$t('cannotEmpty'),
trigger: 'blur'
}
]
},
formInline: {
fileLinkList:[{}],
progressTrackingList:[{}],
approvalEvidenceLinkList:[{}],
dutyTerritory:undefined,
projectId:undefined,
problemState:undefined,
},
formInlinetracking:{},
confirmLoading: false,
title: '',
disabled: false,
isTrue: false,
chapterContentsList: [],
firstLevelDutyTerritoryList:[],
projectNameList: [],
ProblemstateList:[this.$t('red'),this.$t('yellow'),this.$t('green'),],
templateDisabled: false,
contentTemplateList: [
{
id: '1',
text: this.$t('defaultTemplate')
},
{
id: '2',
text: this.$t('newRequestCommentListTemplate')
},
{
id: '3',
text: this.$t('NewReleasedStandardTemplate')
},
{
id: '4',
text: this.$t('industryInformationDynamicTemplate')
}
],
index:'',
url: {
add: '/project/problemManagementEO/add',
edit: '/project/problemManagementEO/edit',
queryById: '/report/lawsMonthlyReportWriteEO/queryById'
}
}
},
mounted() {
},
methods: {
getNameList() {
getAction('/project/projectNameInfoEO/queryProjectNameList', {}).then((res) => {
if (res.success) {
this.projectNameList = res.result || []
} else {
this.projectNameList = []
}
})
},
getFirstLevelDutyTerritory() {
getAction('/sys/dictItem/getFirstLevelDutyTerritory', {}).then((res) => {
if (res.success) {
this.firstLevelDutyTerritoryList = res.result
} else {
this.firstLevelDutyTerritoryList = []
}
})
},
...mapGetters(['userInfo']),
edit(row) {
this.getNameList()
this.getFirstLevelDutyTerritory()
this.title = this.$t('view')
this.formInline = row
if(this.formInline.dutyTerritory != null){
this.formInline.dutyTerritory = this.formInline.dutyTerritory.split(',')
}else{
this.formInline.dutyTerritory = undefined
}
if(this.formInline.problemState == null){
this.formInline.problemState = undefined
}
if(this.formInline.projectId != null){
this.formInline.projectId = this.formInline.projectId.split(',')
}else{
this.formInline.projectId = undefined
}
getAction('/project/problemManagementEO/queryById', {id:this.formInline.id}).then((res) => {
if (res.success) {
this.formInline.fileList = res.result.fileList
this.formInline.approvalEvidenceFileList = res.result.approvalEvidenceFileList
}
})
console.log(this.formInline)
this.visible = true
this.disabled = true
this.$nextTick(() => {
this.$refs.ruleForm.clearValidate()
})
},
UserFeedback(item){
window.open(item, '_blank');
},
download(item){
console.log(item)
downloadFile('/sys/common/downLoadFile', item.fileName, { id: item.id })
},
handleCancel() {
this.visible = false
},
}
}
</script>
<style>
.ant-select-disabled {
color: rgba(0, 0, 0, 0.65);
}
.ant-input-disabled {
color: rgba(0, 0, 0, 0.65) !important;
}
</style>
<style scoped>
.box-title-text {
line-height: 1.4;
display: flex;
}
.title-text {
width: 114px;
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: 42px;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 130px);
display: inline-block;
margin-top: 2px;
}
.title-text-text {
margin-top: 9px;
}
.formAdd {
margin-bottom: 40px;
}
.Required {
color: red;
margin-right: 4px;
}
.title-text-text {
margin-top: 9px;
}
.formAdd {
margin-bottom: 40px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
z-index: 100;
width: 100%;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
.button-text {
height: 38px;
margin-top: 4px;
}
::v-deep .ant-select-tree-treenode-switcher-close {
width: 255px;
}
::v-deep .ant-select-tree-node-content-wrapper {
float: right;
margin-top: -2px !important;
}
::v-deep .ant-select-tree-title {
width: 100%;
display: block;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
word-break: break-word;
}
</style>
@@ -0,0 +1,138 @@
<template>
<a-modal
:title="$t('fixedPlate')"
:width="500"
:visible="visible"
:confirm-loading="confirmLoading"
:maskClosable="false"
@ok="handleOk"
@cancel="handleCancel"
>
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('versionName')">{{$t('versionName')}}</span>
</div>
<a-form-model-item class="itemModel" :prop="'versionsName'">
<a-input class="box-input"
v-model="formInline.versionsName"
:placeholder="$t('PleaseEnter')+$t('versionName')"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-modal>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
export default {
name: 'fixedPlateForm',
data() {
return {
visible: false,
formInline: {},
loading: false,
confirmLoading: false,
url: {
add: '/project/projectHistoryVersionsEO/add'
},
rules: {
versionsName: [
{
required: true,
message: this.$t('versionName') + this.$t('cannotEmpty'),
trigger: 'blur'
},
{
max: 200,
message: this.$t('versionName') + this.$t('cannotExceed') + 200 + this.$t('Characters'),
trigger: 'blur'
}
]
}
}
},
methods: {
getData() {
this.visible = true
this.formInline = {}
this.$nextTick(() => {
this.$refs.ruleForm.clearValidate()
})
},
handleOk() {
this.$refs.ruleForm.validate(valid => {
if (valid) {
let query = {
projectLibraryId: this.$route.query.id,
...this.formInline
}
this.confirmLoading = true
postAction(this.url.add, query).then((res) => {
if (res.success) {
this.$message.success(this.$t('OperationSuccessful'))
this.visible = false
this.confirmLoading = false
} else {
this.confirmLoading = false
this.$message.success(this.$t('operationFailed'))
}
})
}
})
},
handleCancel() {
this.visible = false
}
}
}
</script>
<style scoped>
.box-title-text {
line-height: 1.4;
display: flex;
/*align-items: center;*/
}
.title-text {
width: 74px;
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;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 64px);
display: inline-block;
margin-top: 2px;
}
.Required {
color: red;
margin-right: 4px;
}
.title-text-text {
margin-top: 9px;
}
</style>
@@ -0,0 +1,105 @@
<template>
<a-modal
:title="$t('historicalVersion')"
:width="900"
:visible="visible"
:confirm-loading="confirmLoading"
:maskClosable="false"
@cancel="visible = false"
>
<template slot="footer">
<a-button key="back" @click="visible = false">
{{$t('cancel')}}
</a-button>
</template>
<a-table
class="table"
:components="drag(columns,'columns')"
:columns="columns"
:pagination="false"
:scroll="{x:'100%',y: 400}"
:data-source="dataSource"
:loading="loading"
>
<span slot="operation" slot-scope="text,record">
<a @click="seeClick(record)">{{$t('See')}}</a>
</span>
</a-table>
</a-modal>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
import { ResizeHeader, ResizeColumnProvide } from '@/mixins/header'
export default {
name: 'historicalVersionList',
mixins: [ResizeColumnProvide, ResizeHeader, ResizeColumnProvide],
data() {
return {
visible: false,
confirmLoading: false,
dataSource: [],
loading: false,
url: {
list: 'project/projectHistoryVersionsEO/list'
},
columns: [
{
title: this.$t('versionName'),
dataIndex: 'versionsName',
align: 'left',
ellipsis: true,
width: 362
},
{
title: this.$t('finalizationTime'),
dataIndex: 'createTime',
align: 'left',
ellipsis: true,
width: 362
},
{
title: this.$t('operation'),
align: 'left',
width: 120,
scopedSlots: { customRender: 'operation' }
}
]
}
},
mounted() {
},
methods: {
getList() {
this.visible = true
this.historicalList()
},
historicalList() {
let query = {
projectLibraryId: this.$route.query.id
}
this.loading = true
getAction(this.url.list, query).then((res) => {
if (res.success) {
this.dataSource = res.result || []
this.loading = false
} else {
this.loading = false
}
})
},
seeClick(item) {
let newUrl = this.$router.resolve({
path: '/historicalVersion',
query: item
})
window.open(newUrl.href, '_blank')
}
}
}
</script>
<style scoped>
</style>
@@ -0,0 +1,346 @@
<template>
<a-drawer
:title="$t('add')"
:maskClosable="false"
:width="1000"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<div style="margin-bottom: 60px">
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :md="12" :sm="5">
<div class="box-title-text">
<div class="title-text" :title="$t('standard')">
<span>{{$t('standard')}}</span>
</div>
<a-input class="box-input" :placeholder="$t('PleaseEnter')+$t('standard')"
v-model="queryParam.serial_number"></a-input>
</div>
</a-col>
<template v-if="toggleSearchStatus">
<a-col :md="12" :sm="5">
<div class="box-title-text">
<div class="title-text" :title="$t('title')">
<span>{{$t('title')}}</span>
</div>
<a-input class="box-input" :placeholder="$t('PleaseEnter')+$t('title')"
v-model="queryParam.title"></a-input>
</div>
</a-col>
<a-col :md="12" :sm="5">
<div class="box-title-text">
<div class="title-text" :title="$t('status')">
<span>{{$t('status')}}</span>
</div>
<j-dict-select-tag class="box-input" v-model="queryParam.state"
:placeholder="$t('PleaseSelect')+$t('status')"
:type="'select'"
:triggerChange="false" :dictCode="'state'"/>
</div>
</a-col>
</template>
<span style="float: right;overflow: hidden;" class="table-page-search-submitButtons">
<a-col :md="12" :sm="24">
<a @click="handleToggleSearch">
{{ !toggleSearchStatus ? $t('open') : $t('away') }}
<a-icon :type="toggleSearchStatus ? 'up' : 'down'"/>
</a>
<a-button class="box-button" style="margin-left: 8px" @click="searchReset">{{$t('reset')}}</a-button>
<a-button class="box-button" style="margin-left: 8px" type="primary" @click="searchQuery">{{$t('query')}}</a-button>
<globalAdvancedQuery ref="globalAdvancedQueryRef"
@handleSuperQuery="handleSuperQuery"
:fieldList="fieldList"/>
</a-col>
</span>
</a-row>
</a-form>
</div>
<a-table
:components="drag(columns,'columns')"
:columns="columns"
rowKey="id"
:scroll="{x: 1200}"
:data-source="dataList"
:pagination="false"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
:loading="loading">
</a-table>
<div class="page" v-if="dataList.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="onChange"
@showSizeChange="SizeChange"
/>
</div>
</div>
<div class="drawer-bootom-button">
<a-button @click="handleCancel" style="margin-right: 16px">{{$t('cancel')}}</a-button>
<a-button @click="handleSubmit" type="primary" :loading="confirmLoading">{{$t('submit')}}</a-button>
</div>
</a-drawer>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
import globalAdvancedQuery from '@/components/globalAdvancedQuery/index'
import { ResizeHeader, ResizeColumnProvide } from '@/mixins/header'
export default {
name: 'listAddModel',
components: {
globalAdvancedQuery
},
props: ['url'],
mixins:[ResizeHeader, ResizeColumnProvide],
data() {
return {
toggleSearchStatus: false,
visible: false,
queryParam: {},
confirmLoading: false,
selectedRowKeys: [],
columns: [
{
title: this.$t('standard'),
dataIndex: 'serial_number',
align: 'left',
ellipsis: true,
width: 228
},
{
title: this.$t('title'),
dataIndex: 'title',
align: 'left',
ellipsis: true,
width: 228
},
{
title: this.$t('zoneOfApplication'),
dataIndex: 'region',
align: 'left',
ellipsis: true,
width: 228
},
// {
// title: this.$t('status'),
// dataIndex: 'state',
// align: 'center',
// ellipsis: true
// },
// {
// title: this.$t('technicalField'),
// dataIndex: 'technology_territory',
// align: 'center',
// ellipsis: true
// },
{
title: this.$t('ImplementationDate'),
dataIndex: 'xin1_che1_xing2_shi2_shi1_ri4_qi1',
align: 'left',
ellipsis: true,
width: 190
},
{
title: this.$t('vehicleInProductionDate'),
dataIndex: 'implement_time',
align: 'left',
ellipsis: true,
width: 190
},
// {
// title: this.$t('correspondingStandard'),
// dataIndex: 'corresponding_standard',
// align: 'center',
// ellipsis: true
// }
],
dataList: [],
content: [],
loading: false,
pageNo: 1,
pageSize: 10,
total: 0,
fieldList: [],
queryConditionVOList: []
}
},
mounted() {
},
methods: {
handleToggleSearch() {
this.toggleSearchStatus = !this.toggleSearchStatus
},
addModel() {
this.visible = true
this.queryParam = {}
this.selectedRowKeys = []
this.queryConditionVOList = []
this.replacePage()
this.queryConditionInventory()
},
searchQuery() {
this.pageNo = 1
this.replacePage()
},
searchReset() {
this.pageNo = 1
this.queryParam = {}
this.queryConditionVOList = []
this.$refs.globalAdvancedQueryRef.resetLine()
this.$refs.globalAdvancedQueryRef.emitCallback()
this.replacePage()
},
onChange(page, pageSize) {
this.pageNo = page
this.replacePage()
},
SizeChange(page, pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.replacePage()
},
replacePage() {
let queryConditionVOList = JSON.parse(JSON.stringify(this.queryConditionVOList))
let query = {
pageNo: this.pageNo,
pageSize: this.pageSize,
...this.queryParam,
queryConditionVOList: JSON.stringify(queryConditionVOList)
}
this.loading = true
postAction(this.url.addModelList, query).then((res) => {
if (res.success) {
this.dataList = res.result.records || []
this.total = res.result.total
this.loading = false
} else {
this.dataList = []
this.total = 0
this.loading = false
}
})
},
onSelectChange(value) {
this.selectedRowKeys = value
},
handleCancel() {
this.visible = false
},
handleSubmit() {
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
this.confirmLoading = true
let selectedRowKeys = JSON.parse(JSON.stringify(this.selectedRowKeys))
postAction(this.url.addModel, {
ids: selectedRowKeys.join(','),
projectLibraryId: this.$route.query.id
}).then((res) => {
if (res.success) {
this.confirmLoading = false
this.$message.success(this.$t('OperationSuccessful'))
this.visible = false
this.selectedRowKeys = []
this.$emit('addModelList')
} else {
this.$message.warning(res.message)
this.confirmLoading = false
}
})
this.visible = false
} else {
this.$message.warning(this.$t('selectLeastOne'))
}
},
queryConditionInventory() {
let query = {
flag: 1
}
getAction(this.url.queryConditionInventory, query).then((res) => {
if (res.success) {
this.fieldList = res.result || []
} else {
this.fieldList = []
}
})
},
handleSuperQuery(params, matchType) {
let sqp = {}
if (!params || (params && params.length == 0)) {
this.queryConditionVOList = []
this.$refs.globalAdvancedQueryRef.superQueryFlag = false
} else {
this.$refs.globalAdvancedQueryRef.superQueryFlag = true
this.queryConditionVOList = params
this.queryConditionVOList.forEach(res => {
res.type = matchType
})
}
this.replacePage()
}
}
}
</script>
<style scoped>
.page {
text-align: right;
margin-top: 20px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
width: 100%;
z-index: 100;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
.box-title-text {
line-height: 1.4;
display: flex;
align-items: center;
margin-bottom: 10px;
}
.title-text {
width: 110px;
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;
}
</style>
@@ -0,0 +1,623 @@
<template>
<div>
<a-drawer
:title="$t('view')"
:maskClosable="false"
:width="900"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<a-spin :spinning="confirmLoading">
<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="title-text-text" :title="$t('standard')">{{$t('standard')}}</span>
</div>
<div class="itemModel">
{{formInline.serialNumber ? formInline.serialNumber : '--'}}
</div>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('title')">{{$t('title')}}</span>
</div>
<div class="itemModel">
{{formInline.title ? formInline.title : '--'}}
</div>
</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('subtitle')">{{$t('subtitle')}}</span>
</div>
<div class="itemModel">
{{formInline.subtitle? formInline.subtitle : '--'}}
</div>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('applicableSupplement')">{{$t('applicableSupplement')}}</span>
</div>
<div class="itemModel">
{{formInline.applicableSupplement ? formInline.applicableSupplement : '--'}}
</div>
</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('certificationType')">{{$t('certificationType')}}</span>
</div>
<div class="itemModel">
{{formInline.attestationType_dictText ? formInline.attestationType_dictText : '--'}}
</div>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('certificationLevel')">{{$t('certificationLevel')}}</span>
</div>
<div class="itemModel">
{{formInline.attestationRank_dictText ? formInline.attestationRank_dictText : '--'}}
</div>
</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('areaOfResponsibility')">{{$t('areaOfResponsibility')}}</span>
</div>
<div class="itemModel">
{{formInline.dutyTerritory_dictText ? formInline.dutyTerritory_dictText : '--'}}
</div>
</div>
</a-col>
<a-col :span="12" v-if="formInline.roleCodeIndex == 0 || formInline.roleCodeIndex == 1">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('regulatoryEngineer')">{{$t('regulatoryEngineer')}}</span>
</div>
<div class="itemModel">
{{formInline.regulationOwnerName ? formInline.regulationOwnerName : '--'}}
</div>
</div>
</a-col>
</a-row>
<a-row :gutter="24" v-if="formInline.roleCodeIndex == 0 || formInline.roleCodeIndex == 1">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('certifiedEngineer')">{{$t('certifiedEngineer')}}</span>
</div>
<div class="itemModel">
{{formInline.homologationEngineerName ? formInline.homologationEngineerName : '--'}}
</div>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('engineeringInterfacePerson')">{{$t('engineeringInterfacePerson')}}</span>
</div>
<div class="itemModel">
{{formInline.engineeringInterfacePersonName ? formInline.engineeringInterfacePersonName : '--'}}
</div>
</div>
</a-col>
</a-row>
<div class="header-text">
&nbsp;{{$t('confirmationOfDesignConformity')}}
</div>
<a-row :gutter="24">
<!-- <a-col :span="12">-->
<!-- <div class="box-title-text">-->
<!-- <div class="title-text">-->
<!-- <span class="title-text-text"-->
<!-- :title="$t('Sponsor')">{{$t('Sponsor')}}</span>-->
<!-- </div>-->
<!-- <div class="itemModel">-->
<!-- {{formInline.designInitiatorName ? formInline.designInitiatorName : '&#45;&#45;'}}-->
<!-- </div>-->
<!-- </div>-->
<!-- </a-col>-->
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('personLiable')">{{$t('personLiable')}}</span>
</div>
<div class="itemModel">
{{formInline.designDutyName ? formInline.designDutyName : '--'}}
</div>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('cutoffTime')">{{$t('cutoffTime')}}</span>
</div>
<div class="itemModel">
{{formInline.designDueDate ? formInline.designDueDate : '--'}}
</div>
</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('typeOfDeliverables')">{{$t('typeOfDeliverables')}}</span>
</div>
<div class="itemModel">
{{formInline.designDeliverableTypeName ? formInline.designDeliverableTypeName : '--'}}
</div>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('deliverableTemplate')">{{$t('deliverableTemplate')}}</span>
</div>
<div class="itemModel">
<span v-if="formInline.designDeliverableTemplate === 'null' || formInline.designDeliverableTemplate === '' ||
formInline.designDeliverableTemplate == null">
--
</span>
<a @click="clickButtonToUpload(formInline.designDeliverableTemplate)" v-else>
{{ $t('viewFile') }}
</a>
</div>
</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('descriptionDeliverables')">{{$t('descriptionDeliverables')}}</span>
</div>
<div class="itemModel" :prop="'designRemark'">
{{formInline.designRemark ? formInline.designRemark : '--'}}
</div>
</div>
</a-col>
</a-row>
<!-- <div class="header-text" v-if="formInline.roleCodeIndex == 0 ||-->
<!-- (formInline.roleCodeIndex == 4 && formInline.prehomoInitiatorId == formInline.homologationEngineerId &&-->
<!-- formInline.homologationEngineerId == userInfoQuery.id) ||-->
<!-- (formInline.roleCodeIndex == 4 && formInline.prehomoInitiatorId == formInline.regulationOwnerId &&-->
<!-- formInline.regulationOwnerId == userInfoQuery.id)">-->
<!-- &nbsp;{{$t('PrehomoConfirmation')}}-->
<!-- </div>-->
<!-- <a-row :gutter="24" v-if="formInline.roleCodeIndex == 0 ||-->
<!-- (formInline.roleCodeIndex == 4 && formInline.prehomoInitiatorId == formInline.homologationEngineerId &&-->
<!-- formInline.homologationEngineerId == userInfoQuery.id) ||-->
<!-- (formInline.roleCodeIndex == 4 && formInline.prehomoInitiatorId == formInline.regulationOwnerId &&-->
<!-- formInline.regulationOwnerId == userInfoQuery.id)">-->
<!-- <a-col :span="12">-->
<!-- <div class="box-title-text">-->
<!-- <div class="title-text">-->
<!-- <span class="title-text-text"-->
<!-- :title="$t('Sponsor')">{{$t('Sponsor')}}</span>-->
<!-- </div>-->
<!-- <div class="itemModel">-->
<!-- {{formInline.prehomoInitiatorName ? formInline.prehomoInitiatorName : '&#45;&#45;'}}-->
<!-- </div>-->
<!-- </div>-->
<!-- </a-col>-->
<!-- <a-col :span="12">-->
<!-- <div class="box-title-text">-->
<!-- <div class="title-text">-->
<!-- <span class="title-text-text"-->
<!-- :title="$t('personLiable')">{{$t('personLiable')}}</span>-->
<!-- </div>-->
<!-- <div class="itemModel">-->
<!-- {{formInline.prehomoDutyName ? formInline.prehomoDutyName : '&#45;&#45;'}}-->
<!-- </div>-->
<!-- </div>-->
<!-- </a-col>-->
<!-- </a-row>-->
<!-- <a-row :gutter="24" v-if="formInline.roleCodeIndex == 0 ||-->
<!-- (formInline.roleCodeIndex == 4 && formInline.prehomoInitiatorId == formInline.homologationEngineerId &&-->
<!-- formInline.homologationEngineerId == userInfoQuery.id) ||-->
<!-- (formInline.roleCodeIndex == 4 && formInline.prehomoInitiatorId == formInline.regulationOwnerId &&-->
<!-- formInline.regulationOwnerId == userInfoQuery.id)">-->
<!-- <a-col :span="12">-->
<!-- <div class="box-title-text">-->
<!-- <div class="title-text">-->
<!-- <span class="title-text-text"-->
<!-- :title="$t('cutoffTime')">{{$t('cutoffTime')}}</span>-->
<!-- </div>-->
<!-- <div class="itemModel">-->
<!-- {{formInline.prehomoDueDate ? formInline.prehomoDueDate : '&#45;&#45;'}}-->
<!-- </div>-->
<!-- </div>-->
<!-- </a-col>-->
<!-- </a-row>-->
<!-- <a-row :gutter="24" v-if="formInline.roleCodeIndex == 0 ||-->
<!-- (formInline.roleCodeIndex == 4 && formInline.prehomoInitiatorId == formInline.homologationEngineerId &&-->
<!-- formInline.homologationEngineerId == userInfoQuery.id) ||-->
<!-- (formInline.roleCodeIndex == 4 && formInline.prehomoInitiatorId == formInline.regulationOwnerId &&-->
<!-- formInline.regulationOwnerId == userInfoQuery.id)">-->
<!-- <a-col :span="12">-->
<!-- <div class="box-title-text">-->
<!-- <div class="title-text">-->
<!-- <span class="title-text-text"-->
<!-- :title="$t('typeOfDeliverables')">{{$t('typeOfDeliverables')}}</span>-->
<!-- </div>-->
<!-- <div class="itemModel">-->
<!-- {{formInline.prehomoDeliverableTypeName ? formInline.prehomoDeliverableTypeName : '&#45;&#45;'}}-->
<!-- </div>-->
<!-- </div>-->
<!-- </a-col>-->
<!-- <a-col :span="12">-->
<!-- <div class="box-title-text">-->
<!-- <div class="title-text">-->
<!-- <span class="title-text-text"-->
<!-- :title="$t('deliverableTemplate')">{{$t('deliverableTemplate')}}</span>-->
<!-- </div>-->
<!-- <div class="itemModel">-->
<!-- <span v-if="formInline.prehomoDeliverableTemplate === 'null' || formInline.prehomoDeliverableTemplate === '' ||-->
<!-- formInline.prehomoDeliverableTemplate == null">-->
<!-- &#45;&#45;-->
<!-- </span>-->
<!-- <a @click="clickButtonToUpload(formInline.prehomoDeliverableTemplate)" v-else>-->
<!-- {{ $t('viewFile') }}-->
<!-- </a>-->
<!-- </div>-->
<!-- </div>-->
<!-- </a-col>-->
<!-- </a-row>-->
<!-- <a-row :gutter="24" v-if="formInline.roleCodeIndex == 0 ||-->
<!-- (formInline.roleCodeIndex == 4 && formInline.prehomoInitiatorId == formInline.homologationEngineerId &&-->
<!-- formInline.homologationEngineerId == userInfoQuery.id) ||-->
<!-- (formInline.roleCodeIndex == 4 && formInline.prehomoInitiatorId == formInline.regulationOwnerId &&-->
<!-- formInline.regulationOwnerId == userInfoQuery.id)">-->
<!-- <a-col :span="24">-->
<!-- <div class="box-title-text">-->
<!-- <div class="title-text">-->
<!-- <span class="title-text-text"-->
<!-- :title="$t('descriptionDeliverables')">{{$t('descriptionDeliverables')}}</span>-->
<!-- </div>-->
<!-- <div class="itemModel">-->
<!-- {{formInline.prehomoRemark ? formInline.prehomoRemark : '&#45;&#45;'}}-->
<!-- </div>-->
<!-- </div>-->
<!-- </a-col>-->
<!-- </a-row>-->
<div class="header-text">
&nbsp;{{$t('verificationAndConformityconfirmation')}}
</div>
<a-row :gutter="24">
<!-- <a-col :span="12">-->
<!-- <div class="box-title-text">-->
<!-- <div class="title-text">-->
<!-- <span class="title-text-text"-->
<!-- :title="$t('Sponsor')">{{$t('Sponsor')}}</span>-->
<!-- </div>-->
<!-- <div class="itemModel">-->
<!-- {{formInline.verifyInitiatorName ? formInline.verifyInitiatorName : '&#45;&#45;'}}-->
<!-- </div>-->
<!-- </div>-->
<!-- </a-col>-->
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('personLiable')">{{$t('personLiable')}}</span>
</div>
<div class="itemModel">
{{formInline.verifyDutyName ? formInline.verifyDutyName : '--'}}
</div>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('cutoffTime')">{{$t('cutoffTime')}}</span>
</div>
<div class="itemModel">
{{formInline.verifyDueDate ? formInline.verifyDueDate : '--'}}
</div>
</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('typeOfDeliverables')">{{$t('typeOfDeliverables')}}</span>
</div>
<div class="itemModel">
{{formInline.verifyDeliverableTypeName ? formInline.verifyDeliverableTypeName : '--'}}
</div>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('deliverableTemplate')">{{$t('deliverableTemplate')}}</span>
</div>
<div class="itemModel">
<span v-if="formInline.verifyDeliverableTemplate === 'null' || formInline.verifyDeliverableTemplate === '' ||
formInline.verifyDeliverableTemplate == null">
--
</span>
<a @click="clickButtonToUpload(formInline.verifyDeliverableTemplate)" v-else>
{{ $t('viewFile') }}</a>
</div>
</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('descriptionDeliverables')">{{$t('descriptionDeliverables')}}</span>
</div>
<div class="itemModel">
{{formInline.verifyRemark ? formInline.verifyRemark : '--'}}
</div>
</div>
</a-col>
</a-row>
<div class="header-text" v-if="rejectCauseList && rejectCauseList.length > 0">
{{$t('listConfirmationRejectionReason')}}
</div>
<div v-if="rejectCauseList && rejectCauseList.length > 0"
v-for="(item,index) in rejectCauseList">
<a-row :gutter="24">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('rejectedBy')">{{$t('rejectedBy')}}</span>
</div>
<div class="itemModel">
{{item.createBy ? item.createBy : '--'}}
</div>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('rejectionTime')">{{$t('rejectionTime')}}</span>
</div>
<div class="itemModel">
{{item.rejectTime ? item.rejectTime : '--'}}
</div>
</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('rejectReason')">{{$t('rejectReason')}}</span>
</div>
<div class="itemModel">
{{item.rejectCause ? item.rejectCause : '--'}}
</div>
</div>
</a-col>
</a-row>
</div>
<div class="header-text" v-if="rejectCauseListOne && rejectCauseListOne.length > 0">
{{$t('taskConfirmationRejectionReason')}}
</div>
<div v-if="rejectCauseListOne && rejectCauseListOne.length > 0"
v-for="(item,index) in rejectCauseListOne">
<a-row :gutter="24">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('rejectedBy')">{{$t('rejectedBy')}}</span>
</div>
<div class="itemModel">
{{item.createBy ? item.createBy : '--'}}
</div>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('rejectionTime')">{{$t('rejectionTime')}}</span>
</div>
<div class="itemModel">
{{item.rejectTime ? item.rejectTime : '--'}}
</div>
</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('rejectReason')">{{$t('rejectReason')}}</span>
</div>
<div class="itemModel">
{{item.rejectCause ? item.rejectCause : '--'}}
</div>
</div>
</a-col>
</a-row>
</div>
</a-form-model>
</a-spin>
<div class="drawer-bootom-button">
<a-button style="margin-right: 8px" @click="handleCancel">{{$t('cancel')}}</a-button>
</div>
</a-drawer>
<viewFileModel ref="viewFileModelRef"/>
</div>
</template>
<script>
import viewFileModel from '@/components/viewFileModel/index'
import { getAction, postAction, putAction } from '@/api/manage'
import { mapGetters } from 'vuex'
export default {
name: 'listOfRegulationsView',
components: {
viewFileModel
},
props: ['url'],
data() {
return {
visible: false,
confirmLoading: false,
rules: {},
rulesData: {},
formInline: {},
disabled: false,
userInfoQuery: {},
rejectCauseList: [],
rejectCauseListOne: []
}
},
mounted() {
this.userInfoQuery = this.userInfo()
},
methods: {
...mapGetters(['userInfo']),
editModel(item) {
this.visible = true
this.formInline = item
this.getRejectCause(item.id)
this.formInline = { ...this.formInline }
},
getRejectCause(id) {
let query = {
projectLawsInventoryId: id
}
getAction('/project/projectLawsInventoryRejectCauseEO/list', query).then((res) => {
if (res.success) {
this.rejectCauseList = []
this.rejectCauseListOne = []
if (res.result && res.result.length > 0) {
res.result.forEach(val => {
if (val.rejectType == '0') {
this.rejectCauseList.push(val)
} else if (val.rejectType == '1') {
this.rejectCauseListOne.push(val)
}
})
}
} else {
this.rejectCauseList = []
this.rejectCauseListOne = []
}
})
},
handleCancel() {
this.visible = false
},
clickButtonToUpload(item) {
this.$refs.viewFileModelRef.clickButtonToUpload(item)
}
}
}
</script>
<style scoped>
.box-title-text {
line-height: 1.4;
display: flex;
margin-bottom: 20px;
/*align-items: center;*/
}
.title-text {
width: 114px;
text-align: right;
display: inline-block;
font-weight: 500;
font-size: 14px;
margin-right: 16px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
line-height: 24px;
}
.itemModel {
width: calc(100% - 130px);
display: inline-block;
font-size: 16px;
word-break: break-all;
color: #040B29;
}
.title-text-text {
margin-top: 9px;
}
.header-text {
font-size: 16px;
font-weight: bold;
margin-left: 15px;
/*border-bottom: 1px #d9d9d9 dashed;*/
height: 30px;
margin-bottom: 30px;
}
.formAdd {
margin-bottom: 40px;
}
.button-text {
height: 38px;
width: calc(100% - 100px);
line-height: 38px;
background: #fff;
border: 1px #00B3BE solid;
color: #00B3BE;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
width: 100%;
z-index: 100;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
</style>
@@ -0,0 +1,165 @@
<template>
<div>
<a-modal
:title="$t('modifyOperator')"
:width="600"
:visible="visible"
:confirm-loading="confirmLoading"
:maskClosable="false"
@ok="handleOk"
@cancel="handleCancel"
>
<a-spin :spinning="confirmLoading">
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24" v-if="isDesignFlow">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('designComplianceProcess')">{{ $t('designComplianceProcess') }}</span>
</div>
<a-form-model-item class="itemModel-multi" prop="designTransferUserIdName">
<PersonnelSelection
:query="{db_field_name:'designTransferUserId',db_field_txt:$t('designComplianceProcess')+$t('Operator')}"
:isSingleChoice="true"
:personneQuery="formInline"
v-if="visible"
@change="PersonnelSelectionChange"
v-model="formInline.designTransferUserIdName"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
<a-row :gutter="24" v-if="isVerifyFlow">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('validationComplianceProcess')">{{ $t('validationComplianceProcess') }}</span>
</div>
<a-form-model-item class="itemModel-multi" prop="verifyTransferUserIdName">
<PersonnelSelection
:query="{db_field_name:'verifyTransferUserId',db_field_txt:$t('validationComplianceProcess')+$t('Operator')}"
:isSingleChoice="true"
:personneQuery="formInline"
v-if="visible"
@change="PersonnelSelectionChange"
v-model="formInline.verifyTransferUserIdName"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-spin>
</a-modal>
</div>
</template>
<script>
import PersonnelSelection from '@/components/PersonnelSelection/index'
import { getAction, postAction, putAction } from '@/api/manage'
export default {
name: 'modifyOperator',
components: {
PersonnelSelection
},
data() {
return {
visible: false,
confirmLoading: false,
formInline: {},
rules: {},
isDesignFlow: false,
isVerifyFlow: false,
selectedRowKeys: {}
}
},
methods: {
getData(val, isDesignFlow, isVerifyFlow) {
this.selectedRowKeys = val
this.visible = true
this.isDesignFlow = isDesignFlow
this.isVerifyFlow = isVerifyFlow
this.formInline = {}
this.$nextTick(() => {
this.$refs.ruleForm.clearValidate()
})
},
handleOk() {
if (this.formInline.designTransferUserIdName || this.formInline.verifyTransferUserIdName) {
let query = {
projectLibraryId: this.$route.query.id,
ids: this.selectedRowKeys.id,
designTransferUserId: this.formInline.designTransferUserId,
verifyTransferUserId: this.formInline.verifyTransferUserId
}
this.confirmLoading = true
postAction('/project/projectLawsInventoryEO/compulsoryTransfer', query).then((res) => {
if (res.success) {
this.$message.success(this.$t('OperationSuccessful'))
this.confirmLoading = false
this.visible = false
this.$emit('modifyOperatorForm')
} else {
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
this.visible = false
}
})
} else {
this.$message.warning(this.$t('oneThePersonnelMustBeSelected'))
}
},
handleCancel() {
this.visible = false
},
PersonnelSelectionChange(value, id) {
this.formInline[value] = id
this.formInline = { ...this.formInline }
}
}
}
</script>
<style scoped>
.box-title-text {
line-height: 1.4;
display: flex;
}
.title-text {
width: 124px;
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: 42px;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 150px);
display: inline-block;
margin-top: 2px;
}
.title-text-text {
margin-top: 9px;
}
.formAdd {
margin-bottom: 40px;
}
</style>
@@ -0,0 +1,701 @@
<!--平台件-->
<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('title')">
<span>{{$t('title')}}</span>
</div>
<a-input class="box-input" :placeholder="$t('PleaseEnter')+$t('title')"
v-model="queryParam.title"></a-input>
</div>
</a-col>
<a-col :md="6" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('Relevantlawsregulations')">
<span>{{$t('Relevantlawsregulations')}}</span>
</div>
<a-input class="box-input" :placeholder="$t('PleaseEnter')+$t('Relevantlawsregulations')"
v-model="queryParam.lawsName"></a-input>
</div>
</a-col>
<a-col :md="6" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('RelatedItems')">
<span>{{$t('RelatedItems')}}</span>
</div>
<a-select allowClear
class="box-input"
v-model="queryParam.projectId"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
showSearch
optionFilterProp="label"
:autoClearSearchValue="false"
:placeholder="$t('PleaseSelect')+$t('RelatedItems')">
<a-select-option v-for="(item, key) in projectNameList"
:key="key"
:label="item.projectName"
:value="item.id">
<span style="display: inline-block;width: 100%" :title=" item.projectName ">
{{ item.projectName}}
</span>
</a-select-option>
</a-select>
</div>
</a-col>
<template v-if="toggleSearchStatus">
<a-col :md="6" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('problemType')">
<span>{{$t('problemType')}}</span>
</div>
<j-dict-select-tag class="box-input" v-model="queryParam.problemType"
:placeholder="$t('PleaseSelect')+$t('problemType')"
:type="'select'"
@changeQuery="onChange"
:triggerChange="false" :dictCode="'wen4_ti2_lei4_xing2'"/>
</div>
</a-col>
<a-col :md="6" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('statisticalNodes')">
<span>{{$t('statisticalNodes')}}</span>
</div>
<a-select :placeholder="$t('PleaseSelect')+$t('statisticalNodes')"
allowClear
show-search
class="box-input"
optionFilterProp="label"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
v-model="queryParam.dutyTerritory">
<a-select-option v-for="(item, key) in firstLevelDutyTerritoryList"
:key="key"
:label="item.key"
:value="item.key">
<span style="display: inline-block;width: 100%" :title=" item.key ">
{{ item.key }}
</span>
</a-select-option>
</a-select>
</div>
</a-col>
<a-col :md="6" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('Problemstate')">
<span>{{$t('Problemstate')}}</span>
</div>
<a-select allowClear
class="box-input"
v-model="queryParam.problemState"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
showSearch
optionFilterProp="label"
:autoClearSearchValue="false"
:placeholder="$t('PleaseSelect')+$t('Problemstate')">
<a-select-option v-for="(item, key) in ProblemstateList"
:label='item'
:key="key"
:value="item">
<span style="display: inline-block;width: 100%" :title=" item">
{{ item }}
</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 @click="handleToggleSearch">
{{ !toggleSearchStatus ? $t('open') : $t('away') }}
<a-icon :type="toggleSearchStatus ? 'up' : 'down'"/>
</a>
<a-button class="box-button" style="margin-left: 8px" @click="searchReset">{{$t('reset')}}</a-button>
<a-button class="box-button" style="margin-left: 8px" type="primary" @click="searchQuery">{{$t('query')}}</a-button>
</a-col>
</span>
</a-row>
</a-form>
</div>
<div class="table-operator">
<div class="operator-text" @click="handleAdd" v-has="'ncrTrack:add'">
<a-icon type="plus"/>
{{$t('newlyAdded')}}
</div>
<div @click="handleExport" v-has="'ncrTrack:exportData'" class="operator-text">
<a-icon type="export" :rotate="-90"/>
{{ $t('export') }}
</div>
</div>
<div>
<a-table
ref="table"
size="middle"
rowKey="uuid"
:components="drag(columns,'columns')"
:loading="loading"
:pagination="false"
:scroll="{x: '100%'}"
@change="tableOnChange"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
:data-source="dataSource"
:columns="columns"
>
<!-- <span slot="standard" slot-scope="text,result">-->
<!-- <a @click="designFlowStatusClick(result)" class="textName" :title="text">-->
<!-- {{text}}-->
<!-- </a>-->
<!-- </span>-->
<div slot="CertificationProgress" slot-scope="text,result">
<span v-if="result.problemState == $t('red')" class="box-content-Progress box-content-cou nonConformityColor"
:style="{'width':long=='zh-cn'?'90px' : '120px'}"
>
{{result.problemState ? result.problemState : ''}}
</span>
<span v-if="result.problemState == $t('green')" class="box-content-Progress box-content-cou accordColor"
:style="{'width':long=='zh-cn'?'90px' : '120px'}"
>
{{result.problemState ? result.problemState : ''}}
</span>
<span v-if="result.problemState == $t('yellow')" class="box-content-Progress box-content-cou TrackedColor"
:style="{'width':long=='zh-cn'?'90px' : '120px'}"
>
{{result.problemState ? result.problemState : ''}}
</span>
</div>
<!-- <span slot="problemType" slot-scope="text,result">-->
<!-- <span>{{result.flag== 'NEW'?result.problemType_dictText:result.problemType}}</span>-->
<!-- </span>-->
<span slot="operation" slot-scope="text,record">
<a class="text-operation" v-has="'ncrTrack:check'"
@click="detil(record)">
{{ $t('See') }}
</a>
<a class="text-operation" v-if="record.flag == 'NEW'" v-has="'ncrTrack:edit'"
@click="edit(record)">
{{ $t('edit') }}
</a>
<a class="text-operation" v-if="record.flag == 'NEW'" v-has="'ncrTrack:delete'"
@click="deleteLib(record)">
{{ $t('deleteLib') }}
</a>
</span>
</a-table>
</div>
<div class="page" v-if="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>
<designCompliance ref="designComplianceRef"/>
<addModel ref="addModelRef" @addModelForm="addModelForm"/>
<detilModel ref="detilModelRef"/>
</a-card>
</template>
<script>
import { getAction, postAction, downloadFile, deleteAction ,downloadFilePost} from '@/api/manage'
import PersonnelSelection from '@/components/PersonnelSelection/index'
import designCompliance from '../../../toDoCenter/projectRegulationTasks/components/designCompliance'
import store from '@/store/'
import addModel from './addModelconformance'
import moment from 'moment'
import detilModel from './detilModel'
import { ResizeHeader, ResizeColumnProvide } from '@/mixins/header'
export default {
name: 'projectNonConformance',
components: {
PersonnelSelection,
addModel,
detilModel,
designCompliance
},
mixins:[ResizeHeader, ResizeColumnProvide],
data() {
return {
queryParam: {},
loading: false,
dataSource: [],
selectedRowKeys: [],
projectNameList: [],
firstLevelDutyTerritoryList:[],
ProblemstateList:[this.$t('red'),this.$t('yellow'),this.$t('green'),],
// CertificationColor: {
// $t('red'): 'nonConformityColor',
// $t('green'): 'accordColor',
// $t('yellow'): 'TrackedColor',
// },
toggleSearchStatus: false,
columns: [
{
title: this.$t('title'),
align: 'left',
dataIndex: 'title',
width: 170,
sorter:true,
ellipsis: true
},
{
title: this.$t('Relevantlawsregulations'),
align: 'left',
dataIndex: 'lawsName',
width: 170,
sorter:true,
ellipsis: true
},
{
title: this.$t('RelatedItems'),
align: 'left',
dataIndex: 'projectName',
width: 170,
sorter:true,
ellipsis: true
},
{
title: this.$t('problemType'),
align: 'left',
dataIndex: 'problemType_dictText',
width: 170,
sorter:true,
ellipsis: true,
scopedSlots: { customRender: 'problemType' }
},
{
title: this.$t('statisticalNodes'),
align: 'left',
dataIndex: 'dutyTerritory',
width: 100,
sorter:true,
ellipsis: true
},
{
title: this.$t('creator'),
align: 'left',
dataIndex: 'createBy',
width: 100,
sorter:true,
ellipsis: true
},
{
title: this.$t('Problemstate'),
align: 'left',
dataIndex: 'problemState',
width: 120,
sorter:true,
ellipsis: true,
scopedSlots: { customRender: 'CertificationProgress' }
},
{
title: this.$t('createTime'),
align: 'left',
dataIndex: 'createTime',
sorter:true,
width: 180
},
{
title: this.$t('updateTime'),
align: 'left',
dataIndex: 'updateTime',
sorter:true,
width: 180
},
{
title: this.$t('operation'),
align: 'left',
fixed: 'right',
width: localStorage.getItem('language') == 'zh-cn' ? 160 : 180,
scopedSlots: { customRender: 'operation' }
}
],
total: 0,
pageSize: 10,
pageNo: 1,
orderBy: '1',
orderByField: '',
long: '',
isPersonnelSelection:true,
url: {
page: '/project/projectLawsInventoryEO/queryNotComplianList',
exportData: '/project/projectLawsInventoryEO/exportNotComplianList'
},
content: []
}
},
created() {
if (store.getters.userInfo) {
this.$socketPublic.dispatch('webSocketInit')//初始化ws
}
},
mounted() {
this.long = localStorage.getItem('language') || 'zh-cn'
this.getList()
this.getNameList()
this.getFirstLevelDutyTerritory()
},
watch: {
'$socketPublic.state.msg': {
//处理接收到的消息
handler: function(res) {
let that = this
let data = JSON.parse(res.data)
if (data.msgId) {
this.getList()
}
}
}
},
methods: {
getFirstLevelDutyTerritory() {
getAction('/sys/dictItem/getFirstLevelDutyTerritory', {}).then((res) => {
if (res.success) {
this.firstLevelDutyTerritoryList = res.result
} else {
this.firstLevelDutyTerritoryList = []
}
})
},
getNameList() {
getAction('/project/projectNameInfoEO/queryProjectNameList', {}).then((res) => {
if (res.success) {
this.projectNameList = res.result || []
} else {
this.projectNameList = []
}
})
},
handleToggleSearch() {
this.toggleSearchStatus = !this.toggleSearchStatus
},
searchQuery() {
this.pageNo = 1
this.getList()
},
addModelForm(){
this.getList()
},
onSelectChange(value) {
this.content = []
this.selectedRowKeys = value
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
this.dataSource.forEach(res => {
this.selectedRowKeys.forEach(val => {
if (res.uuid == val) {
this.content.push({
id: res.id || res.uuid,
flowType: res.flowType
})
}
})
})
}
},
searchReset() {
this.isPersonnelSelection = false
this.$nextTick(()=>{
this.isPersonnelSelection = true
})
this.pageNo = 1
this.queryParam = {}
this.getList()
},
pageOnChange(page, pageSize) {
this.pageNo = page
this.getList()
},
SizeChange(page, pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.getList()
},
tableOnChange(pagination, filters, sorter) {
this.orderBy = sorter.order == 'ascend' ? '1' : '2'
this.orderByField = sorter.columnKey
this.getList()
},
onChange(value){
console.log(value)
this.queryParam.problemType_dictText = value
},
getList() {
if(this.queryParam.problemType_dictText){
delete this.queryParam.problemType
}
let query = {
pageNo: this.pageNo,
pageSize: this.pageSize,
orderBy: this.orderBy,
orderByField: this.orderByField,
projectLibraryId: this.$route.query.id,
projectName:this.$route.query.projectName,
...this.queryParam
}
this.loading = true
getAction(this.url.page, query).then((res) => {
if (res.success) {
if (res.result.current > 1 && res.result.records.length == 0) {
this.pageNo = 1
this.getList()
return
}
this.dataSource = res.result.records || []
this.total = res.result.total
this.loading = false
} else {
this.dataSource = []
this.loading = false
}
})
},
handleAdd(){
this.$refs.addModelRef.add()
},
edit(record){
this.$refs.addModelRef.edit(JSON.parse(JSON.stringify(record)))
},
detil(record){
if(record.flag == 'NEW'){
this.$refs.detilModelRef.edit(JSON.parse(JSON.stringify(record)))
}else{
this.designFlowStatusClick(record)
}
},
deleteLib(record){
let _this = this
this.$confirm({
content: _this.$t('ConfirmDelete'),
onOk() {
deleteAction('/project/problemManagementEO/deleteBatch', { ids: record.uuid }).then((res) => {
if (res.success) {
_this.$message.success(_this.$t('OperationSuccessful'))
_this.getList()
} else {
_this.$message.warning(res.message)
}
})
}
})
},
handleExport() {
let query = {
...this.queryParam,
ncrTrackVOList: this.content,
projectLibraryId: this.$route.query.id,
projectName:this.$route.query.projectName,
}
let date = moment(new Date()).format('YYYY-MM-DD')
downloadFilePost(this.url.exportData, this.$t('Problemanagement') + date + '.zip', query, this.Deselect)
},
Deselect() {
this.selectedRowKeys = []
},
PersonnelSelectionChange(value, id) {
this.queryParam[value] = id
this.queryParam = { ...this.queryParam }
console.log(this.queryParam)
},
//流程状态点击事件
designFlowStatusClick(row, name) {
let query = {}
let TaskKey = ''
if (row.flowType == '2') {
if (row.flowStatus == 'Task to be confirmed' || row.flowStatus == 'Duty Person Rejected') {
TaskKey = 'zrrqr'
} else if (row.flowStatus == 'Results to be submitted' || row.flowStatus == 'Non-Compliance' ||row.flowStatus == 'To be tracked') {
TaskKey = 'zrrtjjfw'
} else if (row.flowStatus == 'Results to be reviewed' ||
row.flowStatus == 'Compliance' ||
row.flowStatus == 'NA') {
TaskKey = 'fggcssh'
}
query = {
actiProcInstId: row.actiProcInstId,
projectTaskInventoryId: row.id,
projectLibraryId: this.$route.query.id,
TaskKey: TaskKey,
isDisplay: false,
flowType: row.flowType,
Sponsor: 'regulationOwnerName',
personLiable: 'designDutyIdName',
typeOfDeliverables: 'designDeliverableTypeName',
deliverableTemplate: 'designDeliverableTemplate',
DueDate: 'designDueDate',
remarks: 'designRemark',
}
} else if(row.flowType == '4'){
if (row.flowStatus == 'Task to be confirmed' || row.flowStatus == 'Duty Person Rejected') {
TaskKey = 'zrrqr'
} else if (row.flowStatus == 'Results to be submitted' || row.flowStatus == 'Non-Compliance' ||row.flowStatus == 'To be tracked') {
TaskKey = 'zrrtjjfw'
} else if (row.flowStatus == 'Results to be reviewed' ||
row.flowStatus == 'Compliance' ||
row.flowStatus == 'NA') {
TaskKey = 'fggcssh'
}
query = {
actiProcInstId: row.actiProcInstId,
projectTaskInventoryId: row.id,
projectLibraryId: this.$route.query.id,
TaskKey: TaskKey,
flowType: row.flowType,
isDisplay: false,
Sponsor: 'regulationOwnerName',
personLiable: 'verifyDutyIdName',
typeOfDeliverables: 'verifyDeliverableTypeName',
deliverableTemplate: 'verifyDeliverableTemplate',
DueDate: 'verifyDueDate',
remarks: 'verifyRemark',
}
}
this.$refs.designComplianceRef.getList(JSON.parse(JSON.stringify(query)), row.flowTypeName)
},
standardClick(val) {
let num = val.prcType
let query = {
taskIds: val.taskId,
projectTaskInventoryId: val.projectLawsInventoryId,
projectLibraryId: val.projectLibraryId,
projectName: val.projectName,
id: val.projectLibraryId,
serialNumber: val.serialNumber,
actiProcInstId: val.prcId,
primaryKeyId: val.projectTaskInventoryDetailId,
TaskKey: val.taskDefinitionKey,
isDisplay: val.status == 'NotDone' ? true : false
}
switch (num) {
case '2':
query.flowType = 2
query.Sponsor = 'designInitiatorName'
query.personLiable = 'designDutyName'
query.typeOfDeliverables = 'designDeliverableTypeName'
query.deliverableTemplate = 'designDeliverableTemplate'
query.DueDate = 'designDueDate'
query.remarks = 'designRemark'
break
case '3':
query.flowType = 3
query.Sponsor = 'prehomoInitiatorName'
query.personLiable = 'prehomoDutyName'
query.typeOfDeliverables = 'prehomoDeliverableTypeName'
query.deliverableTemplate = 'prehomoDeliverableTemplate'
query.DueDate = 'prehomoDueDate'
query.remarks = 'prehomoRemark'
break
case '4':
query.flowType = 4
query.Sponsor = 'verifyInitiatorName'
query.personLiable = 'verifyDutyName'
query.typeOfDeliverables = 'verifyDeliverableTypeName'
query.deliverableTemplate = 'verifyDeliverableTemplate'
query.DueDate = 'verifyDueDate'
query.remarks = 'verifyRemark'
break
}
let newUrl = this.$router.resolve({
path: '/taskListProcess',
query: query
})
window.open(newUrl.href, '_blank')
}
}
}
</script>
<style scoped>
@import '~@assets/less/common.less';
.box-title-text {
line-height: 1.4;
display: flex;
align-items: center;
margin-bottom: 10px;
}
.title-text {
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;*/
}
.page {
text-align: right;
margin-top: 20px;
}
.box-content-Progress {
width: 78px;
height: 32px;
display: inline-block;
text-align: center;
line-height: 32px;
border-radius: 4px;
background: #f1f3f5;
color: #919399;
}
.accordColor {
background: #dbf6e2;
color: #26BD4B;
}
.nonConformityColor {
background: #f3dddd;
color: #E83030;
}
.TrackedColor {
background: #f6ebdb;
color: #FDA71C;
}
.notInvolvedColor {
background: #eef1f4;
color: #707486;
}
.submittedColor {
color: #00B3BE;
background: #ddf3f4;
}
.textName {
width: 100%;
overflow: hidden;
display: -webkit-box;
text-overflow: ellipsis;
/*! autoprefixer: off */
-webkit-box-orient: vertical;
-webkit-line-clamp: 1;
/*! autoprefixer: on;*/
text-justify: inter-ideograph;
word-break: break-all
}
</style>
@@ -0,0 +1,74 @@
<!--平台件-->
<template>
<a-card :bordered="false">
<a-tabs type="card" v-model="activeKey" @change="activeKeyChange" class="ant-tabs">
<a-tab-pane :key="$t('regulatoryComplianceManagement')" :tab="$t('regulatoryComplianceManagement')">
<regulatoryCompliance @currentStatus="currentStatus"
:idList="idList"
v-if="activeKey == $t('regulatoryComplianceManagement')"/>
</a-tab-pane>
<a-tab-pane :key="$t('certificationActivityManagement')" :tab="$t('certificationActivityManagement')">
<certificationActivity @currentStatus="currentStatus" :idList="idList"
v-if="activeKey == $t('certificationActivityManagement')"/>
</a-tab-pane>
<a-tab-pane :key="$t('Problemanagement')" :tab="$t('Problemanagement')">
<nonConformance @currentStatus="currentStatus" v-if="activeKey == $t('Problemanagement')"/>
</a-tab-pane>
</a-tabs>
</a-card>
</template>
<script>
import regulatoryCompliance from './regulatoryCompliance'
import certificationActivity from './certificationActivity'
import nonConformance from './nonConformance'
import { getAction, postAction } from '@/api/manage'
export default {
name: 'projectStatus',
components: {
regulatoryCompliance,
certificationActivity,
nonConformance,
},
data() {
return {
activeKey: this.$t('regulatoryComplianceManagement'),
selectedRowKeys: [],
idList: []
}
},
methods: {
activeKeyChange(){
this.$emit('projectStatusForm',this.activeKey)
},
currentStatus(item) {
this.$emit('currentStatus', item)
},
versionStatisticsClick() {
this.$refs.versionStatisticsRef.addModel(JSON.parse(JSON.stringify(this.selectedRowKeys)))
},
versionStatisticsForm(value) {
this.idList = []
let activeKey = JSON.parse(JSON.stringify(this.activeKey))
this.activeKey = ''
if (value && value.length > 0) {
value.forEach(res => {
this.idList.push(JSON.parse(res).id)
})
}
this.selectedRowKeys = JSON.parse(JSON.stringify(value))
this.$nextTick(() => {
this.activeKey = activeKey
})
}
}
}
</script>
<style scoped>
@import '~@assets/less/common.less';
::v-deep .ant-card-body{
padding: 0 0 24px 0 ;
}
</style>
@@ -0,0 +1,397 @@
<!--平台件-->
<template>
<div class="box-content">
<div class="box-content-top">
<div class="total-text">
<span>{{$t('totalTable')+' : '+mainTopNum}}</span>
</div>
<div id="main-top"></div>
</div>
<div class="box-content-left">
<div class="total-text">
<span>{{$t('totalTable')+' : '+mainLeftNum}}</span>
</div>
<div id="main-left"></div>
</div>
<div class="box-content-right">
<div class="total-text">
<span>{{$t('totalTable')+' : '+mainRightNum}}</span>
</div>
<div id="main-right"> </div>
</div>
<responsibilityList @responsibility="responsibility" ref="responsibilityListRef"/>
</div>
</template>
<script>
import * as echarts from 'echarts'
import { getAction, postAction, deleteAction, downloadFile } from '@/api/manage'
import responsibilityList from './responsibilityList'
import { ResizeHeader, ResizeColumnProvide } from '@/mixins/header'
export default {
name: 'regulatoryCompliance',
components: {
responsibilityList
},
props: {
idList: {
type: Array,
default: []
}
},
mixins: [ResizeHeader, ResizeColumnProvide],
data() {
return {
loading: false,
url: {
getProjectDetailsStatistics: '/project/projectLibraryBase/getProjectDetailsStatistics'
},
mainTopNum: 0,
mainLeftNum: 0,
mainRightNum: 0,
columns: [
{
title: this.$t('red'),
align: 'left',
dataIndex: 'redCount',
width: 139
},
{
title: this.$t('yellow'),
align: 'left',
dataIndex: 'yellowCount',
width: 139
},
{
title: this.$t('green'),
align: 'left',
dataIndex: 'greenCount',
width: 139
},
{
title: this.$t('blue'),
align: 'left',
dataIndex: 'blueCount',
width: 139
}
]
}
},
mounted() {
this.getData()
},
methods: {
getData() {
let id = ''
if (this.idList && this.idList.length > 0) {
id = this.idList.join(',')
} else {
id = this.$route.query.id
}
getAction(this.url.getProjectDetailsStatistics, { id: id }).then((res) => {
if (res.success) {
if (res.result) {
let mainTopDataSource = res.result.taskToConfirmMap ? res.result.taskToConfirmMap.taskToConfirmMapList : []
let mainLeftDataSource = res.result.designComplianceMap ? res.result.designComplianceMap.designComplianceMapList : []
let mainRightDataSource = res.result.verifyComplianceMap ? res.result.verifyComplianceMap.verifyComplianceMapList : []
this.mainTopEcharts(mainTopDataSource)
this.mainLeftEcharts(mainLeftDataSource)
this.mainRightEcharts(mainRightDataSource)
}
}
})
},
getEcharts(chart, title, color, data) {
var myChart = echarts.init(document.getElementById(chart))
myChart.setOption({
title: {
text: title
},
tooltip: {
trigger: 'item',
textStyle: {
fontWeight: 'normal',
fontSize: 14,
color: '#040B29',
fontFamily: 'BlueSkyNoto'
},
formatter: function(parms) {
let str = parms.marker + ' ' + parms.data.name + '&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;' + parms.data.value + ' (' + parms.percent + '%)'
return str
}
},
legend: {
itemWidth: 12,
itemHeight: 12,
bottom: '0',
left: 'center',
itemGap: 30,
icon: 'circle'
},
series: [
{
name: title,
type: 'pie',
radius: ['40%', '54%'],
avoidLabelOverlap: false,
label: {
show: false,
position: 'center'
},
labelLine: {
show: false
},
color: color,
data: data
}
]
})
myChart.on('click', (params) => {
let query = {}
if (params.seriesName == this.$t('regulatoryTaskConfirmation')) {
query = {
title: params.seriesName+'-'+params.name,
projectLibraryId: this.$route.query.id,
operatorType: 'queryFGTaskToConfirmStatistics',
status: params.data.status
}
} else if (params.seriesName == this.$t('designCompliance')) {
query = {
title: params.seriesName+'-'+params.name,
projectLibraryId: this.$route.query.id,
operatorType: 'queryDesignStatistics',
status: params.data.status
}
} else if (params.seriesName == this.$t('verifyCompliance')) {
query = {
title: params.seriesName+'-'+params.name,
projectLibraryId: this.$route.query.id,
operatorType: 'queryVerifyStatistics',
status: params.data.status
}
}
this.$refs.responsibilityListRef.getData(query)
})
},
mainTopEcharts(dataSource) {
let data = []
let color = []
this.mainTopNum = 0
if (dataSource && dataSource.length > 0) {
this.dataSource = [{}]
dataSource.forEach(res => {
if (res.taskAffirmStatus == 'Not started') {
data.push({
value: res.taskAffirmStatusCount,
name: this.$t('notLaunch'),
color: '#00B3BE',
status: res.taskAffirmStatus
})
color.push('#00B3BE')
} else if (res.taskAffirmStatus == 'List to confirm') {
data.push({
value: res.taskAffirmStatusCount,
name: this.$t('listToConfirm'),
color: '#FDA71C',
status: res.taskAffirmStatus
})
color.push('#FDA71C')
} else if (res.taskAffirmStatus == 'Accepted') {
data.push({
value: res.taskAffirmStatusCount,
name: this.$t('accept'),
color: '#26BC4B',
status: res.taskAffirmStatus
})
color.push('#26BC4B')
} else if (res.taskAffirmStatus == 'Rejected') {
data.push({
value: res.taskAffirmStatusCount,
name: this.$t('refuse'),
color: '#E83030',
status: res.taskAffirmStatus
})
color.push('#E83030')
}
this.mainTopNum += res.taskAffirmStatusCount
})
}
this.getEcharts('main-top', this.$t('regulatoryTaskConfirmation'), color, data)
},
mainLeftEcharts(dataSource) {
let data = []
let color = []
this.mainLeftNum = 0
if (dataSource && dataSource.length > 0) {
this.dataSource = [{}]
dataSource.forEach(res => {
if (res.designFlowTaskStatus == 'Not started') {
data.push({
value: res.designFlowTaskStatusCount,
name: this.$t('notLaunch'),
color: '#00B3BE',
status: res.designFlowTaskStatus
})
color.push('#00B3BE')
} else if (res.designFlowTaskStatus == 'List to confirm') {
data.push({
value: res.designFlowTaskStatusCount,
name: this.$t('listToConfirm'),
color: '#FDA71C',
status: res.designFlowTaskStatus
})
color.push('#FDA71C')
} else if (res.designFlowTaskStatus == 'Compliance') {
data.push({
value: res.designFlowTaskStatusCount,
name: this.$t('compliance'),
color: '#26BC4B',
status: res.designFlowTaskStatus
})
color.push('#26BC4B')
} else if (res.designFlowTaskStatus == 'Non-Compliance') {
data.push({
value: res.designFlowTaskStatusCount,
name: this.$t('nonCompliance'),
color: '#707486',
status: res.designFlowTaskStatus
})
color.push('#707486')
}
this.mainLeftNum += res.designFlowTaskStatusCount
})
}
this.getEcharts('main-left', this.$t('designCompliance'), color, data)
},
mainRightEcharts(dataSource) {
let data = []
let color = []
this.mainRightNum = 0
if (dataSource && dataSource.length > 0) {
this.dataSource = [{}]
dataSource.forEach(res => {
if (res.verifyFlowTaskStatus == 'Not started') {
data.push({
value: res.verifyFlowTaskStatusCount,
name: this.$t('notLaunch'),
color: '#00B3BE',
status: res.verifyFlowTaskStatus
})
color.push('#00B3BE')
} else if (res.verifyFlowTaskStatus == 'List to confirm') {
data.push({
value: res.verifyFlowTaskStatusCount,
name: this.$t('listToConfirm'),
color: '#FDA71C',
status: res.verifyFlowTaskStatus
})
color.push('#FDA71C')
} else if (res.verifyFlowTaskStatus == 'Compliance') {
data.push({
value: res.verifyFlowTaskStatusCount,
name: this.$t('compliance'),
color: '#26BC4B',
status: res.verifyFlowTaskStatus
})
color.push('#26BC4B')
} else if (res.verifyFlowTaskStatus == 'Non-Compliance') {
data.push({
value: res.verifyFlowTaskStatusCount,
name: this.$t('nonCompliance'),
color: '#707486',
status: res.verifyFlowTaskStatus
})
color.push('#707486')
}
this.mainRightNum += res.verifyFlowTaskStatusCount
})
}
this.getEcharts('main-right', this.$t('verifyCompliance'), color, data)
},
responsibility(item) {
this.$emit('currentStatus', item)
}
}
}
</script>
<style scoped lang="less">
.box-content {
width: 100%;
display: flex;
justify-content: space-between;
flex-wrap: wrap;
.box-content-top {
width: 100%;
position: relative;
margin-top: 4px;
height: 346px;
border: 2px #eff1f3 solid;
border-radius: 6px;
#main-top {
width: 100%;
height: 100%;
padding: 20px 24px;
box-sizing: border-box;
}
}
.box-content-left {
width: calc(50% - 10px);
margin-top: 20px;
height: 346px;
position: relative;
border: 2px #eff1f3 solid;
border-radius: 6px;
#main-left {
width: 100%;
height: 100%;
padding: 20px 24px;
box-sizing: border-box;
}
}
.box-content-right {
width: calc(50% - 10px);
margin-top: 20px;
height: 346px;
position: relative;
border-radius: 6px;
border: 2px #eff1f3 solid;
#main-right {
width: 100%;
height: 100%;
padding: 24px;
box-sizing: border-box;
}
}
}
.headerText {
margin-left: 30px;
color: #040B29;
font-weight: 400;
position: absolute;
width: 100%;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.total-text {
position: absolute;
right: 28px;
top: 19px;
font-size: 18px;
font-weight: bold;
}
</style>
@@ -0,0 +1,157 @@
<template>
<a-modal
:title="title"
:width="800"
:visible="visible"
:confirm-loading="confirmLoading"
:maskClosable="false"
@cancel="visible = false"
>
<template slot="footer">
<a-button key="back" @click="visible = false">
{{$t('cancel')}}
</a-button>
</template>
<!-- <div style="text-align: right;margin-bottom: 10px">-->
<!-- <div @click="handleExport" class="operator-text">-->
<!-- <a-icon type="export" :rotate="-90"/>-->
<!-- {{$t('export')}}-->
<!-- </div>-->
<!-- </div>-->
<a-table
ref="table"
:components="drag(columns,'columns')"
:loading="loading"
:pagination="false"
:scroll="{x: '100%',y:400}"
:data-source="dataSource"
@change="tableOnChange"
:columns="columns"
>
<!-- -->
<a slot="areaOfResponsibility" @click="areaOfResponsibilityClick(result)" slot-scope="text,result">
{{text}}
</a>
</a-table>
</a-modal>
</template>
<script>
import { getAction, postAction, downloadFile } from '@/api/manage'
import moment from 'moment'
import { ResizeHeader, ResizeColumnProvide } from '@/mixins/header'
export default {
name: 'responsibilityList',
mixins: [ResizeHeader, ResizeColumnProvide],
data() {
return {
visible: false,
title: '',
confirmLoading: false,
loading: false,
dataSource: [],
queryParam: {},
url: {
groupByTerritoryXls: '/project/projectLibraryBase/exportProjectDetailsStatisticsGroupByTerritoryXls',
GroupByTerritory: '/project/projectLibraryBase/getProjectDetailsStatisticsGroupByTerritory'
},
columns: [
{
title: this.$t('areaOfResponsibility'),
dataIndex: 'dutyTerritoryName',
align: 'left',
width: 150,
ellipsis: true,
sorter: true,
scopedSlots: { customRender: 'areaOfResponsibility' }
},
{
title: this.$t('Quantity'),
dataIndex: 'amount',
align: 'left',
ellipsis: true,
width: 150,
sorter: true
},
{
title: this.$t('proportionWithInTheAreaOfResponsibility'),
dataIndex: 'percentage',
align: 'left',
ellipsis: true,
width: 240,
sorter: true
}
]
}
},
mounted() {
},
methods: {
getData(data) {
this.visible = true
this.title = data.title
this.queryParam = data
this.getList()
},
tableOnChange(pagination, filters, sorter) {
this.orderBy = sorter.order == 'ascend' ? '1' : '2'
if (sorter.columnKey == 'attestationRank_dictText') {
this.orderByField = 'attestationRank'
} else if (sorter.columnKey == 'dutyTerritory_dictText') {
this.orderByField = 'dutyTerritory'
} else if (sorter.columnKey == 'designDeliverableTypeName') {
this.orderByField = 'designDeliverableType'
} else if (sorter.columnKey == 'verifyDeliverableTypeName') {
this.orderByField = 'verifyDeliverableType'
} else if (sorter.columnKey == 'designDutyIdName') {
this.orderByField = 'designDutyId'
} else if (sorter.columnKey == 'verifyDutyIdName') {
this.orderByField = 'verifyDutyId'
} else if (sorter.columnKey == 'verifyFlowStatusName') {
this.orderByField = 'verifyFlowStatus'
} else if (sorter.columnKey == 'designFlowStatusName') {
this.orderByField = 'designFlowStatus'
} else {
this.orderByField = sorter.columnKey
}
this.getList()
},
getList() {
this.loading = true
let query = {
...this.queryParam,
orderBy: this.orderBy,
orderByField: this.orderByField,
}
getAction(this.url.GroupByTerritory, query).then((res) => {
if (res.success) {
this.loading = false
this.dataSource = res.result.dataList || []
} else {
this.loading = false
this.dataSource = []
}
})
},
handleExport() {
downloadFile(this.url.groupByTerritoryXls, this.title + '.xls', this.queryParam)
},
handleCancel() {
this.visible = false
},
areaOfResponsibilityClick(item) {
if (this.queryParam.operatorType == 'queryFGTaskToConfirmStatistics' ||
this.queryParam.operatorType == 'queryDesignStatistics' ||
this.queryParam.operatorType == 'queryVerifyStatistics') {
item.isListing = '1'
}
this.$emit('responsibility', item)
}
}
}
</script>
<style scoped>
</style>
@@ -0,0 +1,245 @@
<template>
<div>
<a-modal v-model="visible"
:maskClosable="false"
@ok="handleOk"
:confirm-loading="confirmLoading"
@cancel="handleCancel"
:title="title">
<a-upload-dragger
accept='*.*'
:disabled="disabled"
class="ant-upload-list"
:class="{'uploadFile':isUploadFile}"
name="file"
:file-list="myfileList"
:multiple="true"
:action="uploadAction+'?cut='+cut"
:headers="headers"
@preview="preview"
:before-upload="beforeUpload"
:remove='remove'
@change="handleChange">
<p v-if="!isUploadFile">
<a-icon class="action-upload" type="cloud-upload"/>
</p>
<p v-if="!isUploadFile" class="ant-upload-text" style="font-size: 14px;line-height: 30px">
{{this.$t('clickUpload')}}</p>
</a-upload-dragger>
</a-modal>
</div>
</template>
<script>
import Vue from 'vue'
import { ACCESS_TOKEN } from '@/store/mutation-types'
import { getAction, postAction, downFile, downloadFile, putAction } from '@/api/manage'
import { Base64 } from 'js-base64'
import { mapGetters } from 'vuex'
export default {
name: 'resultReportedUpload',
props: ['disableds', 'disabled', 'thisFileUploadUrl', 'readonly', 'thisFileType', 'isUploadFile'],
data() {
return {
visible: false,
title: this.$t('upload1') + this.$t('resultReported'),
uploadAction: window._CONFIG['domianURL'] + '/sys/common/upload',
state: undefined,
myuploadAction: window._CONFIG['domianURL'] + this.thisFileUploadUrl,
upDataList: [],
downLoadFileUrl: window._CONFIG['domianPreviewURL'] + '/sys/common/download',
downLoadImgUrl: window._CONFIG['domianWebImgURL'] + '/sys/common/download',
fileList: [],
myfileList: [],
isLoding: false,
cut: '',
confirmLoading: false,
uploadQuery: {},
url: {
editModel: '/project/projectLawsInventoryEO/edit'
}
}
},
created() {
const token = Vue.ls.get(ACCESS_TOKEN)
this.headers = { 'X-Access-Token': token }
this.containerId = 'container-ty-' + new Date().getTime()
},
mounted() {
let long = localStorage.getItem('language')
this.cut = ''
if (long && long == 'zh-cn') {
this.cut = 'cn'
} else if (long && long == 'en-us') {
this.cut = 'en'
}
},
methods: {
...mapGetters(['userInfo']),
clickButtonToUploadFile(item) {
this.uploadQuery = item
this.myfileList = []
this.visible = true
getAction('sys/common/getFileInfos', { id: item.fileId }).then((res) => {
if (res.success) {
this.myfileList = res.result
if (this.myfileList && this.myfileList.length > 0) {
this.myfileList.forEach((val) => {
val.name = val.fileName
val.uid = val.id
if (val.response) {
this.fileList.push(val.response.result)
} else {
this.fileList.push(val)
}
})
} else {
this.myfileList = []
}
}
})
},
handleOk() {
if (this.myfileList && this.myfileList.length == 0) {
this.$message.warning(this.$t('pleaseUpload') + this.$t('resultReported'))
} else {
let content = []
this.fileList.forEach(res => {
content.push(res.id || res.name)
})
let formInline = JSON.parse(JSON.stringify(this.uploadQuery))
Object.keys(formInline).forEach(res => {
if (formInline[res] && formInline[res] instanceof Array) {
formInline[res] = formInline[res].join(',')
}
})
formInline.fileId = content.join(',')
this.confirmLoading = true
putAction(this.url.editModel, formInline).then((res) => {
if (res.success) {
this.$message.success(this.$t('OperationSuccessful'))
this.visible = false
this.confirmLoading = false
this.$emit('resultReportedUploadForm')
} else {
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
}
})
}
},
handleCancel() {
this.visible = false
},
beforeUpload(file) {
this.fileTypeSatus = true
this.$message.destroy()
},
remove() {
this.fileTypeSatus = true
},
handleChange(info) {
let { file } = info
const status = info.file.status
info.fileList.forEach((val, index) => {
if (val.response && !val.response.result) {
this.$message.error(val.response.message)
info.fileList.splice(index, 1)
}
})
if (status === 'error') {
this.$message.destroy()
this.$message.error(`${info.file.name}` + this.$t('FileUploadFailed'))
} else if (status === 'removed') {
this.myfileList = info.fileList
this.fileList = []
this.myfileList.forEach((res) => {
if (res.response) {
this.fileList.push(res.response.result)
} else {
this.fileList.push(res)
}
})
if (this.myfileList.length > 0) {
this.$message.destroy()
this.$message.success(`${info.file.name}` + this.$t('DeletedSuccessfully'))
}
} else if (status === 'done') {
this.fileList = []
this.myfileList = info.fileList
if (info.fileList.length > 20) {
info.fileList.splice(20)
this.myfileList = info.fileList
this.myfileList.forEach((res) => {
if (res.response) {
this.fileList.push(res.response.result)
} else {
this.fileList.push(res)
}
})
this.$message.destroy()
this.$message.error(this.$t('UploadMost'))
return
}
this.myfileList.forEach((res) => {
if (res.response) {
this.fileList.push(res.response.result)
} else {
this.fileList.push(res)
}
})
if (this.myfileList.length > 0) {
this.$message.destroy()
if (file.response.success) {
this.$message.success(`${info.file.name}` + this.$t('FileUploadedSuccessfully'))
}
}
} else if (status === 'uploading') {
this.myfileList = info.fileList
// this.$message.success(`${info.file.name} 文件上传成功。`);
}
},
resetFileList() {
this.myfileList = []
this.fileList = []
},
preview(file) {
let fileQuery = file.response ? file.response.result : file
let fileName = fileQuery.fileName
let index1 = fileName.lastIndexOf('.')
let index2 = fileName.length
let fileSuffix = fileName.substring(index1, index2)
if (fileSuffix === '.pdf') {
window.open('/pdf/web/viewer.html?file=' + encodeURIComponent('/jero-boot/sys/common/pdf/viewFile?id=' + fileQuery.id+'&userName='+this.userInfo().username))
} else if (fileSuffix === '.docx' || fileSuffix === '.doc') {
let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix)
window.open(url, '_blank')
} else if (fileSuffix === '.xlsx' || fileSuffix === '.xls') {
let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix)
window.open(url, '_blank')
}else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){
let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + fileQuery.id + fileSuffix)
window.open(url, '_blank')
} else {
downloadFile('/sys/common/downLoadFile', fileQuery.fileName, { id: fileQuery.id,userName:this.userInfo().username })
}
}
}
}
</script>
<style>
.ant-upload-list-item-name {
color: rgba(0, 0, 0, 0.65) !important;
}
.action-upload {
font-size: 67px;
color: #c0c4cc;
}
.uploadFile {
}
</style>
@@ -0,0 +1,267 @@
<!--平台件合规设定-->
<template>
<a-drawer
:title="$t('setting')"
:maskClosable="false"
:width="1000"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<a-spin :spinning="confirmLoading">
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<div v-for="(item,index) in formInline.list" :key="index">
<div style='margin-left: 25px'>
<a-row :gutter="24">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('Nodename')">{{$t('Nodename')}}</span>
</div>
<a-form-model-item class="itemModel">
<a-input class="box-input"
v-model="item.nodename"
:placeholder="$t('PleaseEnter')+$t('Nodename')"/>
</a-form-model-item>
</div>
</a-col>
<a-col :span="12" style='margin-left: -49px'>
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text" :title="$t('Nodedate')">{{$t('Nodedate')}}</span>
</div>
<a-form-model-item class="itemModel">
<a-date-picker class="box-input"
:placeholder="$t('PleaseSelect')+$t('Nodedate')"
@change="dateChange(item,index)"
format="YYYY-MM-DD"
:getCalendarContainer="(trigger) => trigger.parentNode"
v-model="item.date"
:disabled="false"
style="width: 100%"/>
</a-form-model-item>
</div>
</a-col>
<a-icon class="icon-text" style='font-size: 20px;margin-top: 10px;' @click="addClick(index)" type="plus"/>
<a-icon class="icon-text" style='font-size: 20px;margin-top: 10px;' v-if="formInline.list.length > 1" @click="deleteClick(index)"
type="minus" />
</a-row>
</div>
</div>
</a-form-model>
</a-spin>
<div class="drawer-bootom-button">
<a-button style="margin-right: 8px" @click="handleCancel">{{$t('cancel')}}</a-button>
<a-button @click="handleOk" type="primary" :loading="confirmLoading">{{$t('submit')}}</a-button>
</div>
</a-drawer>
</template>
<script>
import { getAction, postAction, putAction } from '@/api/manage'
import moment from 'moment'
export default {
name: 'settingList',
props: ['url'],
data() {
return {
visible: false,
confirmLoading: false,
formInline: {
list:[{}]
},
rules: {
},
ids: []
}
},
mounted() {
},
methods: {
addClick(index){
if(this.formInline.list.length > 19){
this.$message.warning(this.$t('maximum'))
}else{
this.formInline.list.splice(index + 1, 0, {})
}
this.formInline = { ...this.formInline }
},
deleteClick(index) {
this.formInline.list.splice(index, 1)
this.formInline = { ...this.formInline }
},
edit() {
this.visible = true
this.$nextTick(() => {
this.$refs.ruleForm.clearValidate()
})
this.settingQueryForm()
},
settingQueryForm() {
getAction(this.url.settingQueryForm, { projectId: this.$route.query.id }).then((res) => {
if (res.success) {
this.$nextTick(() => {
this.formInline=res.result? {list:[{}]} :res.result
if(!res.result.list || res.result.list.length==0){
this.formInline.list=[{}]
}
})
}
})
},
handleOk() {
this.$refs.ruleForm.validate(valid => {
if (valid) {
let query = {
...this.formInline,
projectId: this.$route.query.id
}
let url = ''
let Action
if (this.formInline.id) {
url = this.url.editSettingUrl
Action = putAction
} else {
url = this.url.addSettingUrl
Action = postAction
}
this.confirmLoading = true
Action(url, query).then((res) => {
if (res.success) {
this.$message.success(this.$t('OperationSuccessful'))
this.visible = false
this.confirmLoading = false
this.$emit('settingListForm')
if(res.result.matchVdr == true){
this.vdrClick()
}
} else {
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
}
})
}
})
},
handleCancel() {
this.formInline = {}
this.visible = false
},
dateChange(item,index) {
this.formInline.list[index].date = this.formInline.list[index].date ? moment(this.formInline.list[index].date).format('YYYY-MM-DD') : ''
}
}
}
</script>
<style>
.formAdd .ant-form-item-label {
width: 130px;
}
.formAdd .ant-form-item-control-wrapper {
display: inline-block;
width: 100%;
}
/*.formAdd .ant-form-item {*/
/* margin-bottom: 20px;*/
/*}*/
.itemModel .ant-form-item-control-wrapper {
width: 100%;
}
.box-input .ant-select-selection--single {
height: 38px;
}
.box-input .ant-select-selection--multiple {
height: 38px;
}
.box-input .ant-select-selection__rendered {
line-height: 38px;
height: 38px;
}
.box-input .ant-select-selection--multiple .ant-select-selection__rendered > ul > li {
margin-top: 6px;
}
.box-input .ant-calendar-picker {
line-height: 38px;
height: 38px;
}
.box-input .ant-calendar-picker-input {
height: 38px;
}
.box-input .ant-input-number-input-wrap {
line-height: 38px;
height: 38px;
}
</style>
<style scoped>
.box-title-text {
line-height: 1.4;
display: flex;
}
.title-text {
width: 106px;
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: 42px;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 130px);
display: inline-block;
margin-top: 2px;
}
.title-text-text {
margin-top: 9px;
}
.formAdd {
margin-bottom: 40px;
}
.Required {
color: red;
margin-right: 3px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
width: 100%;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
z-index: 100;
background: #fff;
border-radius: 0 0 2px 2px;
}
</style>
@@ -0,0 +1,251 @@
<template>
<a-modal
:title="$t('batSetting')"
:width="600"
:visible="visible"
:confirm-loading="confirmLoading"
:maskClosable="false"
@ok="handleOk"
@cancel="handleCancel"
>
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('CertificationProgress')">{{$t('CertificationProgress')}}</span>
</div>
<a-form-model-item class="itemModel">
<j-dict-select-tag class="box-input" v-model="formInline.certificationProgress"
@input="handleInput('certificationProgress')"
:placeholder="$t('PleaseSelect')+$t('CertificationProgress')"
:type="'select'"
:triggerChange="false" :dictCode="'certification_progress'"/>
</a-form-model-item>
</div>
</a-col>
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('CurrentStatus')">{{$t('CurrentStatus')}}</span>
</div>
<a-form-model-item class="itemModel" prop="conditionAssessment">
<a-select
v-model="formInline.conditionAssessment"
:placeholder="$t('PleaseSelect')+$t('CurrentProjectStatusEvaluation')">
<a-select-option :value="'1'">
<span style="display: inline-block;width: 100%">
{{ $t('red') }}
</span>
</a-select-option>
<a-select-option :value="'2'">
<span style="display: inline-block;width: 100%">
{{ $t('yellow') }}
</span>
</a-select-option>
<a-select-option :value="'3'">
<span style="display: inline-block;width: 100%">
{{ $t('green') }}
</span>
</a-select-option>
<a-select-option :value="'4'" disabled>
<span style="display: inline-block;width: 100%">
{{ $t('blue') }}
</span>
</a-select-option>
</a-select>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-modal>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
import moment from 'moment'
export default {
name: 'taskBatSetting',
props: ['url'],
data() {
return {
visible: false,
confirmLoading: false,
formInline: {},
rules: {},
ids: []
}
},
mounted() {
},
methods: {
edit(data) {
this.visible = true
this.$nextTick(() => {
this.ids = data || []
this.formInline = {}
})
},
handleOk() {
if (this.formInline.dutyTerritory) {
this.handleOkTwo()
} else {
this.handleOkOne()
}
},
handleOkOne() {
let ids = JSON.parse(JSON.stringify(this.ids))
let query = {
ids: ids.join(','),
...this.formInline
}
this.confirmLoading = true
postAction(this.url.setBatch, query).then((res) => {
if (res.success) {
this.$message.success(this.$t('OperationSuccessful'))
this.visible = false
this.confirmLoading = false
this.$emit('batSettingList')
} else {
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
}
})
},
handleOkTwo() {
let _this = this
this.$confirm({
content: _this.$t('areResponsibilityAreaInformationBatch'),
onOk() {
let ids = JSON.parse(JSON.stringify(_this.ids))
let query = {
ids: ids.join(','),
..._this.formInline
}
_this.confirmLoading = true
postAction(_this.url.setBatch, query).then((res) => {
if (res.success) {
_this.$message.success(_this.$t('OperationSuccessful'))
_this.visible = false
_this.confirmLoading = false
_this.$emit('batSettingList')
} else {
_this.$message.warning(_this.$t('operationFailed'))
_this.confirmLoading = false
}
})
}
})
},
handleCancel() {
this.formInline = {}
this.visible = false
},
handleInput(value) {
this.$nextTick(() => {
this.formInline = { ...this.formInline }
this.$refs.ruleForm.validateField([value])
})
},
}
}
</script>
<style>
.formAdd .ant-form-item-label {
width: 130px;
}
.formAdd .ant-form-item-control-wrapper {
display: inline-block;
width: 100%;
}
/*.formAdd .ant-form-item {*/
/* margin-bottom: 20px;*/
/*}*/
.itemModel .ant-form-item-control-wrapper {
width: 100%;
}
.box-input .ant-select-selection--single {
height: 38px;
}
.box-input .ant-select-selection--multiple {
height: 38px;
}
.box-input .ant-select-selection__rendered {
line-height: 38px;
height: 38px;
}
.box-input .ant-select-selection--multiple .ant-select-selection__rendered > ul > li {
margin-top: 6px;
}
.box-input .ant-calendar-picker {
line-height: 38px;
height: 38px;
}
.box-input .ant-calendar-picker-input {
height: 38px;
}
.box-input .ant-input-number-input-wrap {
line-height: 38px;
height: 38px;
}
.box-input .ant-calendar-picker-input {
padding: 4px 30px 4px 11px;
}
</style>
<style scoped>
.box-title-text {
line-height: 1.4;
display: flex;
}
.title-text {
width: 84px;
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: 42px;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 130px);
display: inline-block;
margin-top: 2px;
}
.title-text-text {
margin-top: 9px;
}
.formAdd {
margin-bottom: 40px;
}
</style>
@@ -0,0 +1,452 @@
<template>
<a-drawer
:title="$t('toResubmit')"
:maskClosable="false"
:width="700"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;margin-bottom: 436px;">
<a-spin :spinning="confirmLoading">
<div class="box">
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('submissionProcess')">{{$t('submissionProcess')}}</span>
</div>
</div>
<a-form-model-item class="itemModel" :prop="'submissionProcess'">
<a-select :placeholder="$t('PleaseSelect')+$t('submissionProcess')"
v-model="formInline.submissionProcess">
<a-select-option v-for="(item, key) in submissionProcessList"
:key="key"
:value="item.value">
<span style="display: inline-block;width: 100%" :title=" item.name ">
{{ item.name}}
</span>
</a-select-option>
</a-select>
</a-form-model-item>
</a-col>
</a-row>
<a-row :gutter="24">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('resultofhandling')">{{$t('resultofhandling')}}</span>
</div>
</div>
<a-form-model-item class="itemModel" :prop="'disposeResult'">
<a-radio-group @change="reviewResultChange"
class="box-input"
v-model="formInline.disposeResult">
<a-radio value="Compliance">
{{$t('accord')}}
</a-radio>
<a-radio value="Non-Compliance">
{{$t('nonConformity')}}
</a-radio>
<a-radio value="To be tracked">
{{$t('Tracked')}}
</a-radio>
<a-radio value="NA">
{{$t('notInvolved')}}
</a-radio>
<!-- <a-radio value="Returned">-->
<!-- {{$t('sendBack')}}-->
<!-- </a-radio>-->
</a-radio-group>
</a-form-model-item>
</a-col>
</a-row>
<a-row :gutter="24" v-if="isDeliveryTime">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text"
:title="$t('expectedDeliveryTime')">{{$t('expectedDeliveryTime')}}</span>
</div>
</div>
<a-form-model-item class="itemModel" :prop="'deliveryTime'">
<a-date-picker class="box-input"
:placeholder="$t('PleaseSelect')+$t('expectedDeliveryTime')"
@change="dateChange({db_field_name:'deliveryTime'})"
format="YYYY-MM-DD"
:getCalendarContainer="(trigger) => trigger.parentNode"
v-model="formInline.deliveryTime"
style="width: 100%"/>
</a-form-model-item>
</a-col>
</a-row>
<a-row :gutter="24">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('feedbackMessage')">{{$t('feedbackMessage')}}</span>
</div>
</div>
<a-form-model-item class="itemModel" prop="approvalOpinion">
<a-textarea :placeholder="$t('pleaseEnter')+$t('feedbackMessage')"
v-model="formInline.approvalOpinion"
:rows="2"
style="min-height: 68px"
/>
</a-form-model-item>
</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('enclosure')">{{$t('enclosure')}}</span>
</div>
</div>
<a-form-model-item class="itemModel">
<a-button type="primary" class="button-text"
@click="clickButtonToUpload('approvalFile')">
{{ (formInline.approvalFile === 'null' || formInline.approvalFile === '' ||
formInline.approvalFile == null) ? $t('clickUpload') : $t('viewUploadedFiles')
}}
</a-button>
</a-form-model-item>
</a-col>
</a-row>
</a-form-model>
<uploadFile ref="uploadFile"
@uploadSuccess="uploadSuccess"/>
</div>
</a-spin>
<div class="drawer-bootom-button">
<a-button style="margin-right: 8px" @click="handleCancel">{{$t('cancel')}}</a-button>
<a-button @click="handleSubmit" type="primary" :loading="confirmLoading">{{$t('submit')}}</a-button>
</div>
</a-drawer>
</template>
<script>
import { getAction, postAction, putAction, deleteAction } from '@/api/manage'
import uploadFile from '@/components/uploadFile/file'
import moment from 'moment'
import { mapGetters } from 'vuex'
export default {
name: 'toResubmitForm',
components: {
uploadFile
},
data() {
return {
visible: false,
confirmLoading: false,
isDeliveryTime: false,
formInline: {},
submissionProcessList: [],
rules: {
disposeResult: [
{
required: true,
message: this.$t('resultofhandling') + this.$t('cannotEmpty'),
trigger: 'change'
}
],
submissionProcess: [
{
required: true,
message: this.$t('submissionProcess') + this.$t('cannotEmpty'),
trigger: 'change'
}
],
deliveryTime: [
{
required: true,
message: this.$t('expectedDeliveryTime') + this.$t('cannotEmpty'),
trigger: 'change'
}
],
approvalOpinion: [
{
required: true,
message: this.$t('feedbackMessage') + this.$t('cannotEmpty'),
trigger: 'blur'
},
{
max: 300,
message: this.$t('feedbackMessage') + this.$t('cannotExceed') + 300 + this.$t('Characters'),
trigger: 'blur'
}
],
engineerFeedbackContent: [
{
required: true,
message: this.$t('feedbackFromTheEngineer') + this.$t('cannotEmpty'),
trigger: 'blur'
},
{
max: 300,
message: this.$t('feedbackFromTheEngineer') + this.$t('cannotExceed') + 300 + this.$t('Characters'),
trigger: 'blur'
}
],
fileId: [
{
required: true,
message: this.$t('Deliverables') + this.$t('cannotEmpty'),
trigger: 'change'
}
]
},
listOfData: {}
}
},
mounted() {
},
methods: {
...mapGetters(['userInfo']),
handleCancel() {
this.visible = false
},
handleSubmit() {
this.$refs.ruleForm.validate(valid => {
if (valid) {
this.confirmLoading = true
if (this.formInline.disposeResult == 'To be tracked') {
this.formInline.approvalOpinion = this.formInline.approvalOpinion + ';' + this.$t('expectedDeliveryTime') + ':' + this.formInline.deliveryTime
}
if (this.formInline.submissionProcess == '1') {
this.formInline.flowType = '32'
} else if (this.formInline.submissionProcess == '2') {
this.formInline.flowType = '34'
}
let query = Object.assign(this.listOfData, this.formInline)
this.startProcess(query)
}
})
},
startProcess(value) {
let query = {
type: 31,
projectLawsInvnetoryList: value,
projectNameId: this.$route.query.projectNameId,
projectName: this.$route.query.projectName,
projectLawsInventoryId: value.id
}
postAction('/workFlow/startProcess', query).then((res) => {
if (res.success) {
this.completeTask(value, res.result)
} else {
this.$message.warning(this.$t('operationFailed'))
}
})
},
completeTask(value, taskId) {
value.handlingTime = moment(new Date()).format('YYYY-MM-DD HH:mm:ss')
Object.keys(value).forEach(res => {
if (value[res] && typeof value[res] == 'string') {
value[res] = value[res].replace(/\"/g, '“')
value[res] = value[res].replace(/\'/g, '')
}
})
let query = {
userid: this.userInfo().id,
taskId: taskId,
json: JSON.stringify(value).replace(/\"/g, '\'')
}
postAction('/workFlow/completeTask', query).then((res) => {
if (res.success) {
this.$message.success(this.$t('OperationSuccessful'))
this.visible = false
this.confirmLoading = false
this.$emit('toResubmitFormForm')
} else {
this.confirmLoading = false
this.$message.warning(res.message)
}
})
},
getData(val, isDesign, isVerify) {
this.submissionProcessList = []
this.visible = true
this.listOfData = val
this.formInline = {}
if (isDesign) {
this.submissionProcessList.push({
name: this.$t('designComplianceProcess'),
value: '1'
})
} else {
this.formInline.submissionProcess = '2'
}
if (isVerify) {
this.submissionProcessList.push({
name: this.$t('validationComplianceProcess'),
value: '2'
})
} else {
this.formInline.submissionProcess = '1'
}
this.$nextTick(() => {
this.$refs.ruleForm.clearValidate()
})
},
reviewResultChange(value) {
if (value.target.value == 'To be tracked') {
this.isDeliveryTime = true
} else {
this.isDeliveryTime = false
this.formInline.deliveryTime = ''
}
this.formInline = { ...this.formInline }
},
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 }
this.$nextTick(() => {
this.$refs.ruleForm.validateField([this.uploadName])
})
},
dateChange(item) {
this.formInline[item.db_field_name] = this.formInline[item.db_field_name] ? moment(this.formInline[item.db_field_name]).format('YYYY-MM-DD') : ''
this.formInline = { ...this.formInline }
}
}
}
</script>
<style scoped lang="less">
.box {
padding: 0 0 24px 0;
box-sizing: border-box;
}
.box-text {
display: flex;
justify-content: space-between;
height: 40px;
line-height: 24px;
.header-text {
font-size: 16px;
font-weight: bold;
color: #000;
}
}
.box-title-text {
/*line-height: 1.4;*/
display: flex;
/*align-items: center;*/
}
.title-text {
/*width: 88px;*/
text-align: left;
display: inline-block;
font-weight: 500;
font-size: 14px;
margin-right: 16px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
height: 32px;
line-height: 36px;
color: #000F16;
}
.title-text-fq {
/*width: 130px;*/
text-align: left;
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: 100%;
display: inline-block;
margin-top: 2px;
margin-bottom: 0px;
}
.Required {
color: red;
margin-right: 4px;
}
.title-text-text {
margin-top: 9px;
}
/*.formAdd {*/
/* margin-bottom: 40px;*/
/*}*/
.text-header {
font-size: 16px;
color: #040B29;
font-weight: 400;
}
.button-text {
height: 38px;
width: calc(50% - 100px);
line-height: 38px;
background: #fff;
border: 1px #00B3BE solid;
color: #00B3BE;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
width: 100%;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
z-index: 100;
background: #fff;
border-radius: 0 0 2px 2px;
}
</style>
@@ -0,0 +1,268 @@
<template>
<a-drawer
:title="$t('Transfer')"
:maskClosable="false"
:width="1000"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<div style="margin-bottom: 60px">
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :md="12" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('VirtualListName')">
<span>{{$t('VirtualListName')}}</span>
</div>
<j-input class="box-input" :placeholder="$t('PleaseEnter')+$t('VirtualListName')"
v-model="queryParam.name"></j-input>
</div>
</a-col>
<span style="float: right;overflow: hidden;margin-right: 11px" class="table-page-search-submitButtons">
<a-col :md="12" :sm="24">
<a-button class="box-button" @click="searchReset">{{$t('reset')}}</a-button>
<a-button class="box-button" style="margin-left: 8px" type="primary" @click="searchQuery">{{$t('query')}}</a-button>
</a-col>
</span>
</a-row>
</a-form>
</div>
<a-table
:components="drag(columns,'columns')"
:columns="columns"
rowKey="id"
:scroll="{x: 1000}"
:data-source="dataList"
:pagination="false"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange,columnTitle:' ' }"
:loading="loading">
</a-table>
<div class="page" v-if="dataList.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="onChange"
@showSizeChange="SizeChange"
/>
</div>
</div>
<div class="drawer-bootom-button">
<a-button @click="handleCancel" style="margin-right: 16px">{{$t('cancel')}}</a-button>
<a-button @click="handleSubmit(undefined)" type="primary" :loading="confirmLoading">{{$t('determine')}}</a-button>
</div>
</a-drawer>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
import { ResizeHeader, ResizeColumnProvide } from '@/mixins/header'
export default {
name: 'transferList',
components: {},
props: ['url'],
mixins: [ResizeHeader, ResizeColumnProvide],
data() {
return {
visible: false,
queryParam: {},
confirmLoading: false,
selectedRowKeys: [],
columns: [
{
title: this.$t('VirtualListName'),
dataIndex: 'name',
align: 'left',
ellipsis: true,
width: 235
},
{
title: this.$t('instructionForUse'),
dataIndex: 'useExplain',
align: 'left',
ellipsis: true,
width: 235
},
{
title: this.$t('updateTime'),
dataIndex: 'updateTime',
align: 'left',
ellipsis: true,
width: 235
},
{
title: this.$t('creater'),
dataIndex: 'createBy',
align: 'left',
ellipsis: true,
width: 235
}
],
dataList: [],
content: [],
loading: false,
pageNo: 1,
pageSize: 10,
total: 0
}
},
mounted() {
},
methods: {
transferModel() {
this.visible = true
this.queryParam = {}
this.selectedRowKeys = []
this.replacePage()
},
searchQuery() {
this.pageNo = 1
this.replacePage()
},
searchReset() {
this.pageNo = 1
this.queryParam = {}
this.replacePage()
},
onChange(page, pageSize) {
this.pageNo = page
this.replacePage()
},
SizeChange(page, pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.replacePage()
},
replacePage() {
let query = {
pageNo: this.pageNo,
pageSize: this.pageSize,
...this.queryParam
}
this.loading = true
postAction(this.url.transferUrl, query).then((res) => {
if (res.success) {
this.dataList = res.result.records || []
this.total = res.result.total
this.loading = false
} else {
this.loading = false
}
})
},
onSelectChange(value) {
this.selectedRowKeys = value
if (this.selectedRowKeys.length > 1) {
this.selectedRowKeys.shift()
}
},
handleCancel() {
this.visible = false
},
handleSubmit(flag) {
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
this.confirmLoading = true
let selectedRowKeys = JSON.parse(JSON.stringify(this.selectedRowKeys))
this.confirmLoading = false
this.$emit('transferListForm',selectedRowKeys.join(','))
this.selectedRowKeys = []
// postAction(this.url.addModel, {
// dummyInventoryBaseId: selectedRowKeys.join(','),
// projectLibraryId: this.$route.query.id,
// flag: flag
// }).then((res) => {
// if (res.success) {
// this.confirmLoading = false
// this.$message.success(this.$t('OperationSuccessful'))
// this.visible = false
// this.selectedRowKeys = []
// this.$emit('transferListForm')
// } else {
// if (res.message == '该虚拟清单的维护清单中没有数据,是否需要添加') {
// this.confirmLoading = false
// this.getAdd()
// return
// }
// this.$message.warning(this.$t('operationFailed'))
// this.confirmLoading = false
// }
// })
} else {
this.$message.warning(this.$t('selectLeastOne'))
}
},
getAdd() {
let _this = this
this.$confirm({
content: _this.$t('TheDoesNotContainData'),
onOk() {
_this.handleSubmit('1')
}
})
}
}
}
</script>
<style scoped>
.page {
text-align: right;
margin-top: 20px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
z-index: 100;
width: 100%;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
.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;
}
</style>
@@ -0,0 +1,233 @@
<template>
<a-drawer
:title="$t('Transfer')"
:maskClosable="false"
:width="1000"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<div style="margin-bottom: 60px">
<a-table
:components="drag(columns,'columns')"
:columns="columns"
rowKey="id"
:scroll="{x: 800}"
:data-source="dataList"
:pagination="false"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange,columnTitle:' ' }"
:loading="loading">
</a-table>
<div class="page" v-if="dataList.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="onChange"
@showSizeChange="SizeChange"
/>
</div>
</div>
<div class="drawer-bootom-button">
<a-button @click="handleCancel" style="margin-right: 16px">{{$t('cancel')}}</a-button>
<a-button @click="handleSubmit(undefined)" type="primary" :loading="confirmLoading">{{$t('determine')}}</a-button>
</div>
</a-drawer>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
import { ResizeHeader, ResizeColumnProvide } from '@/mixins/header'
export default {
name: 'transferList',
components: {},
props: ['url'],
mixins: [ResizeHeader, ResizeColumnProvide],
data() {
return {
visible: false,
queryParam: {},
confirmLoading: false,
selectedRowKeys: [],
columns: [
{
title: this.$t('projectVersion'),
dataIndex: 'projectName',
align: 'left',
ellipsis: true,
width: 235
},
{
title: this.$t('Listcreationtime'),
dataIndex: 'createTime',
align: 'left',
ellipsis: true,
},
],
dataList: [],
content: [],
loading: false,
pageNo: 1,
pageSize: 10,
total: 0
}
},
mounted() {
},
methods: {
transferModel() {
this.visible = true
this.queryParam = {}
this.selectedRowKeys = []
this.replacePage()
},
searchQuery() {
this.pageNo = 1
this.replacePage()
},
searchReset() {
this.pageNo = 1
this.queryParam = {}
this.replacePage()
},
onChange(page, pageSize) {
this.pageNo = page
this.replacePage()
},
SizeChange(page, pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.replacePage()
},
replacePage() {
let query = {
projectId: this.$route.query.id,
pageNo: this.pageNo,
pageSize: this.pageSize,
...this.queryParam
}
this.loading = true
getAction('/project/projectRxswinEO/getOnePage', query).then((res) => {
if (res.success) {
this.dataList = res.result.records || []
this.total = res.result.total
this.loading = false
} else {
this.loading = false
}
})
},
onSelectChange(value) {
this.selectedRowKeys = value
if (this.selectedRowKeys.length > 1) {
this.selectedRowKeys.shift()
}
},
handleCancel() {
this.visible = false
},
handleSubmit(flag) {
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
this.confirmLoading = true
let selectedRowKeys = JSON.parse(JSON.stringify(this.selectedRowKeys))
this.confirmLoading = false
this.$emit('transferListForm',selectedRowKeys.join(','))
this.selectedRowKeys = []
// postAction(this.url.addModel, {
// dummyInventoryBaseId: selectedRowKeys.join(','),
// projectLibraryId: this.$route.query.id,
// flag: flag
// }).then((res) => {
// if (res.success) {
// this.confirmLoading = false
// this.$message.success(this.$t('OperationSuccessful'))
// this.visible = false
// this.selectedRowKeys = []
// this.$emit('transferListForm')
// } else {
// if (res.message == '该虚拟清单的维护清单中没有数据,是否需要添加') {
// this.confirmLoading = false
// this.getAdd()
// return
// }
// this.$message.warning(this.$t('operationFailed'))
// this.confirmLoading = false
// }
// })
} else {
this.$message.warning(this.$t('selectLeastOne'))
}
},
getAdd() {
let _this = this
this.$confirm({
content: _this.$t('TheDoesNotContainData'),
onOk() {
_this.handleSubmit('1')
}
})
}
}
}
</script>
<style scoped>
.page {
text-align: right;
margin-top: 20px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
z-index: 100;
width: 100%;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
.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;
}
</style>
@@ -0,0 +1,411 @@
<template>
<a-drawer
:title="$t('Transfer')"
:maskClosable="false"
:width="1100"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<div style="margin-bottom: 60px">
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :md="12" :sm="5">
<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="12" :sm="5">
<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>
<span style="float: right;overflow: hidden;margin-right: 11px" class="table-page-search-submitButtons">
<a-col :md="12" :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>
<globalAdvancedQuery ref="globalAdvancedQueryRef"
@handleSuperQuery="handleSuperQuery"
:fieldList="fieldList"/>
</a-col>
</span>
</a-row>
</a-form>
</div>
<a-table
:columns="columns"
rowKey="id"
:scroll="{x: 800,y:'calc(100vh - 330px)'}"
:data-source="dataList"
:pagination="false"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
:loading="loading">
</a-table>
<!-- <div class="page" v-if="dataList.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="onChange"-->
<!-- @showSizeChange="SizeChange"-->
<!-- />-->
<!-- </div>-->
</div>
<div class="drawer-bootom-button">
<a-button @click="handleCancel" style="margin-right: 16px">{{$t('cancel')}}</a-button>
<a-button @click="handleSubmit(undefined)" type="primary" :loading="confirmLoading">{{$t('submit')}}</a-button>
</div>
</a-drawer>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
import globalAdvancedQuery from '@/components/globalAdvancedQuery/index'
export default {
name: 'transferList',
components: {
globalAdvancedQuery
},
props: ['url'],
data() {
return {
visible: false,
queryParam: {},
confirmLoading: false,
selectedRowKeys: [],
columns: [
{
title: this.$t('standard'),
align: 'left',
dataIndex: 'serialNumber',
width: 180,
fixed: 'left',
ellipsis: true,
scopedSlots: { customRender: 'standard' }
},
{
title: this.$t('title'),
align: 'left',
dataIndex: 'title',
width: 180,
fixed: 'left',
ellipsis: true,
scopedSlots: { customRender: 'titleName' }
},
{
title: this.$t('subtitle'),
align: 'left',
dataIndex: 'subtitle',
ellipsis: true,
width: 150
},
{
title: this.$t('zoneOfApplication'),
align: 'left',
dataIndex: 'region_dictText',
width: 150,
ellipsis: true
},
{
title: this.$t('correspondingStandard'),
align: 'left',
dataIndex: 'correspondingStandard',
width: 150,
ellipsis: true
},
{
title: this.$t('implementationCategory'),
align: 'left',
dataIndex: 'implementType_dictText',
width: 150,
ellipsis: true
},
{
title: this.$t('ImplementationDate'),
align: 'left',
width: 190,
dataIndex: 'xin1Che1Xing2Shi2Shi1Ri4Qi1',
ellipsis: true
},
{
title: this.$t('vehicleInProductionDate'),
align: 'left',
width: 190,
dataIndex: 'implementTime',
ellipsis: true
},
{
title: this.$t('certificationType'),
align: 'left',
dataIndex: 'attestationType_dictText',
width: 180,
ellipsis: true
},
{
title: this.$t('certificationLevel'),
align: 'left',
dataIndex: 'attestationRank_dictText',
width: 180,
ellipsis: true
},
{
title: this.$t('applicableSupplement'),
align: 'left',
width: 220,
dataIndex: 'applicableSupplement',
ellipsis: true
},
{
title: 'WVTA ID',
align: 'left',
dataIndex: 'wvtaId',
width: 180,
ellipsis: true
},
{
title: this.$t('areaOfResponsibility'),
align: 'left',
ellipsis: true,
dataIndex: 'dutyTerritory_dictText',
width: 180
},
],
fieldList: [
{
type: 'string',
value: 'subtitle',
text: this.$t('subtitle')
},
{
type: '',
value: 'region',
text: this.$t('zoneOfApplication'),
dictCode: 'region'//只要 dictCode 有值,无论 type 是什么,都显示为字典下拉框
},
{
type: 'string',
value: 'correspondingStandard',
text: this.$t('correspondingStandard')
},
{
type: '',
value: 'implementType',
text: this.$t('implementationCategory'),
dictCode: 'implement_type'//只要 dictCode 有值,无论 type 是什么,都显示为字典下拉框
},
{
type: 'date',
value: 'xin1Che1Xing2Shi2Shi1Ri4Qi1',
text: this.$t('ImplementationDate')
},
{
type: 'date',
value: 'implementTime',
text: this.$t('vehicleInProductionDate')
},
{
type: '',
value: 'attestationType',
text: this.$t('certificationType'),
dictCode: 'attestation_type'//只要 dictCode 有值,无论 type 是什么,都显示为字典下拉框
},
{
type: '',
value: 'attestationRank',
text: this.$t('certificationLevel'),
dictCode: 'attestation_rank'//只要 dictCode 有值,无论 type 是什么,都显示为字典下拉框
},
{
type: 'string',
value: 'applicableSupplement',
text: this.$t('applicableSupplement')
},
{
type: 'string',
value: 'wvtaId',
text: 'WVTA ID'
},
{
type: '',
value: 'dutyTerritory',
text: this.$t('areaOfResponsibility'),
dictCode: 'duty_territory'//只要 dictCode 有值,无论 type 是什么,都显示为字典下拉框
},
],
dataList: [],
content: [],
loading: false,
dummyInventoryBaseId:'',
pageNo: 1,
pageSize: 10,
total: 0
}
},
mounted() {
},
methods: {
transferModel(id) {
this.visible = true
this.dummyInventoryBaseId = id
this.queryParam = {}
this.selectedRowKeys = []
this.replacePage()
},
searchQuery() {
this.pageNo = 1
this.replacePage()
},
searchReset() {
this.pageNo = 1
this.queryParam = {}
this.replacePage()
this.$refs.globalAdvancedQueryRef.resetLine()
this.$refs.globalAdvancedQueryRef.emitCallback()
},
onChange(page, pageSize) {
this.pageNo = page
this.replacePage()
},
SizeChange(page, pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.replacePage()
},
handleSuperQuery(params, matchType) {
let sqp = {}
if (!params || (params && params.length == 0)) {
sqp['superQueryParams'] = ''
this.$refs.globalAdvancedQueryRef.superQueryFlag = false
} else {
this.$refs.globalAdvancedQueryRef.superQueryFlag = true
sqp['superQueryParams'] = encodeURI(JSON.stringify(params))
sqp['superQueryMatchType'] = matchType
}
this.queryParamQuery = sqp
this.replacePage()
},
replacePage() {
let query = {
// pageNo: this.pageNo,
// pageSize: this.pageSize,
...this.queryParamQuery,
...this.queryParam,
dummyInventoryBaseId: this.dummyInventoryBaseId
}
this.loading = true
getAction('/dummy/dummyInventoryInfoEO/list', query).then((res) => {
if (res.success) {
this.dataList = res.result || []
this.loading = false
} else {
this.loading = false
}
})
},
onSelectChange(value) {
this.selectedRowKeys = value
// if (this.selectedRowKeys.length > 1) {
// this.selectedRowKeys.shift()
// }
},
handleCancel() {
this.visible = false
},
handleSubmit(flag) {
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
this.confirmLoading = true
let selectedRowKeys = JSON.parse(JSON.stringify(this.selectedRowKeys))
postAction('project/projectLawsInventoryEO/add', {
dummyInventoryBaseId: this.dummyInventoryBaseId,
projectLibraryId: this.$route.query.id,
dummyids: selectedRowKeys.join(','),
}).then((res) => {
if (res.success) {
this.confirmLoading = false
this.$message.success(this.$t('OperationSuccessful'))
this.visible = false
this.selectedRowKeys = []
this.$emit('transferListFormHomo')
} else {
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
}
})
} else {
this.$message.warning(this.$t('selectLeastOne'))
}
},
}
}
</script>
<style scoped>
.page {
text-align: right;
margin-top: 20px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
z-index: 100;
width: 100%;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
.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;
}
</style>
@@ -0,0 +1,370 @@
<template>
<a-drawer
:title="$t('Transfer')"
:maskClosable="false"
:width="1100"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<div style="margin-bottom: 60px">
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :md="12" :sm="8">
<div class="box-title-text-search">
<div class="title-text-search" :title="$t('standard')">
<span>{{$t('standard')}}</span>
</div>
<a-input class="box-input-search" allowClear :placeholder="$t('PleaseEnter') + $t('standard')"
v-model="queryParam.serialNumber"></a-input>
</div>
</a-col>
<template v-if="toggleSearchStatus">
<a-col :md="12" :sm="8">
<div class="box-title-text-search">
<div class="title-text-search" :title="$t('theme')">
<span>{{$t('theme')}}</span>
</div>
<a-input class="box-input-search" allowClear :placeholder="$t('PleaseEnter') + $t('theme')"
v-model="queryParam.theme"></a-input>
</div>
</a-col>
<a-col :md="12" :sm="8">
<div class="box-title-text-search">
<div class="title-text-search" :title="'RXSWIN'">
<span>RXSWIN</span>
</div>
<a-input class="box-input-search" allowClear :placeholder="$t('PleaseEnter') + 'RXSWIN'"
v-model="queryParam.rxswin"></a-input>
</div>
</a-col>
<!-- <a-col :md="12" :sm="8">-->
<!-- <div class="box-title-text-search">-->
<!-- <div class="title-text-search" :title="$t('Correspondingversion')">-->
<!-- <span>{{$t('Correspondingversion')}}</span>-->
<!-- </div>-->
<!-- <a-select :placeholder="$t('PleaseSelect')+$t('Correspondingversion')"-->
<!-- allowClear-->
<!-- show-search-->
<!-- class="box-input-search"-->
<!-- optionFilterProp="label"-->
<!-- showSearch-->
<!-- :autoClearSearchValue="false"-->
<!-- :getPopupContainer="triggerNode=> triggerNode.parentNode"-->
<!-- v-model="queryParam.version">-->
<!-- <a-select-option v-for="(item, key) in firstLevelDutyTerritoryList"-->
<!-- :key="key"-->
<!-- :label="item.key"-->
<!-- :value="item.key">-->
<!-- <span style="display: inline-block;width: 100%" :title=" item.key ">-->
<!-- {{ item.key }}-->
<!-- </span>-->
<!-- </a-select-option>-->
<!-- </a-select>-->
<!-- </div>-->
<!-- </a-col>-->
</template>
<span style="float: right;overflow: hidden;margin-right: 11px;margin-bottom: 20px"
class="table-page-search-submitButtons">
<a @click="handleToggleSearch">
{{ !toggleSearchStatus ? $t('open') : $t('away') }}
<a-icon :type="toggleSearchStatus ? 'up' : 'down'"/>
</a>
<a-button class="box-button-search" style="margin-left: 8px"
@click="searchReset">{{$t('reset')}}</a-button>
<a-button class="box-button-search" style="margin-left: 8px" type="primary" @click="searchQuery">{{$t('query')}}</a-button>
</span>
</a-row>
</a-form>
</div>
<a-table
:columns="columns"
rowKey="id"
:scroll="{x: 800,y:'calc(100vh - 330px)'}"
:data-source="dataList"
:pagination="false"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
:loading="loading">
</a-table>
<div class="page" v-if="dataList.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="onChange"
@showSizeChange="SizeChange"
/>
</div>
</div>
<div class="drawer-bootom-button">
<a-button @click="handleCancel" style="margin-right: 16px">{{$t('cancel')}}</a-button>
<a-button @click="handleSubmit(undefined)" type="primary" :loading="confirmLoading">{{$t('submit')}}</a-button>
</div>
</a-drawer>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
import globalAdvancedQuery from '@/components/globalAdvancedQuery/index'
export default {
name: 'transferList',
components: {
globalAdvancedQuery
},
props: ['url'],
data() {
return {
toggleSearchStatus: false,
visible: false,
queryParam: {},
confirmLoading: false,
selectedRowKeys: [],
columns: [
{
title: this.$t('standard'),
align: 'left',
dataIndex: 'serialNumber',
ellipsis: true,
sorter:true,
width: 170
},
{
title: this.$t('theme'),
align: 'left',
dataIndex: 'theme',
ellipsis: true,
sorter:true,
width: 300
},
{
title: 'RXSWIN',
align: 'left',
dataIndex: 'rxswin',
ellipsis: true,
sorter:true,
width: 170
},
{
title: this.$t('Correspondingversion'),
align: 'left',
dataIndex: 'version',
ellipsis: true,
sorter:true,
width: 170
},
],
dataList: [],
content: [],
loading: false,
dummyInventoryBaseId:'',
pageNo: 1,
pageSize: 10,
total: 0
}
},
mounted() {
},
methods: {
transferModel(id) {
this.visible = true
this.projectId = id
this.queryParam = {}
this.selectedRowKeys = []
this.replacePage()
},
handleToggleSearch() {
this.toggleSearchStatus = !this.toggleSearchStatus
},
searchQuery() {
this.pageNo = 1
this.replacePage()
},
searchReset() {
this.pageNo = 1
this.queryParam = {}
this.replacePage()
},
onChange(page, pageSize) {
this.pageNo = page
this.replacePage()
},
SizeChange(page, pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.replacePage()
},
replacePage() {
let query = {
pageNo: this.pageNo,
pageSize: this.pageSize,
...this.queryParam,
projectId: this.projectId
}
this.loading = true
getAction('/project/projectRxswinEO/getTwoPage', query).then((res) => {
if (res.success) {
this.dataList = res.result.records || []
this.loading = false
} else {
this.loading = false
}
})
},
onSelectChange(value) {
this.selectedRowKeys = value
// if (this.selectedRowKeys.length > 1) {
// this.selectedRowKeys.shift()
// }
},
handleCancel() {
this.visible = false
},
handleSubmit(flag) {
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
this.confirmLoading = true
let selectedRowKeys = JSON.parse(JSON.stringify(this.selectedRowKeys))
getAction('/project/projectRxswinEO/iSExist', {
projectId: this.$route.query.id,
// projectLibraryId: this.$route.query.id,
ids: selectedRowKeys.join(','),
}).then((res) => {
if (res.success) {
this.confirmLoading = false
// this.$message.success(this.$t('OperationSuccessful'))
if(res.result == 'YES'){
let _this = this
this.$confirm({
content: _this.$t('AlreadyExists'),
onOk() {
getAction('/project/projectRxswinEO/addBatch', {
ids: selectedRowKeys.join(','),
flag:'YES',
projectId: _this.$route.query.id,
}).then((res) => {
if (res.success) {
_this.$message.success(_this.$t('OperationSuccessful'))
_this.visible = false
_this.$emit('transferListFormHomo')
} else {
_this.$message.warning(res.message)
}
})
},
onCancel() {
_this.visible = false
_this.$emit('transferListFormHomo')
}
})
}else{
this.visible = false
this.$message.success(this.$t('OperationSuccessful'))
this.$emit('transferListFormHomo')
}
this.selectedRowKeys = []
} else {
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
}
})
} else {
this.$message.warning(this.$t('selectLeastOne'))
}
},
}
}
</script>
<style scoped>
.page {
text-align: right;
margin-top: 20px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
z-index: 100;
width: 100%;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
.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;
}
.box-title-text-search {
line-height: 1.4;
display: flex;
align-items: center;
margin-bottom: 10px;
}
.title-text-search {
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-search {
display: inline-block;
width: calc(100% - 100px);
height: 38px;
margin-top: 2px;
}
.box-button-search {
height: 38px;
/*margin-top: 2px;*/
}
</style>
@@ -0,0 +1,195 @@
<!--平台件-->
<template>
<a-drawer
:title="$t('versionStatistics')"
:maskClosable="false"
:width="1000"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<div style="margin-bottom: 60px">
<a-table
:components="drag(columns,'columns')"
:columns="columns"
:rowKey="(record)=>JSON.stringify(record)"
:scroll="{x: '100%',y:'calc(100vh - 280px)'}"
:data-source="dataList"
:pagination="false"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
:loading="loading">
</a-table>
<div class="page" v-if="dataList.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="onChange"
@showSizeChange="SizeChange"
/>
</div>
</div>
<div class="drawer-bootom-button">
<a-button @click="handleCancel" style="margin-right: 16px">{{$t('cancel')}}</a-button>
<a-button @click="handleSubmit" type="primary" :loading="confirmLoading">{{$t('submit')}}</a-button>
</div>
</a-drawer>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
import { ResizeHeader, ResizeColumnProvide } from '@/mixins/header'
export default {
name: 'versionStatistics',
mixins:[ResizeHeader, ResizeColumnProvide],
data() {
return {
visible: false,
queryParam: {},
confirmLoading: false,
selectedRowKeys: [],
columns: [
{
title: this.$t('VersionNumber'),
dataIndex: 'projectVersion',
align: 'left',
ellipsis: true,
width: 200
},
{
title: this.$t('describe'),
dataIndex: 'explanation',
align: 'left',
ellipsis: true,
width: 500
}
],
dataList: [],
loading: false,
pageNo: 1,
pageSize: 10,
total: 0,
url: {
list: '/project/projectLibraryBase/versionStatistics'
}
}
},
mounted() {
},
methods: {
addModel(value) {
this.visible = true
this.queryParam = {}
this.selectedRowKeys = JSON.parse(JSON.stringify(value))
this.replacePage()
},
searchQuery() {
this.pageNo = 1
this.replacePage()
},
searchReset() {
this.pageNo = 1
this.queryParam = {}
this.replacePage()
},
onChange(page, pageSize) {
this.pageNo = page
this.replacePage()
},
SizeChange(page, pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.replacePage()
},
replacePage() {
let query = {
pageNo: this.pageNo,
pageSize: this.pageSize,
id:this.$route.query.id,
...this.queryParam
}
this.loading = true
postAction(this.url.list, query).then((res) => {
if (res.success) {
this.dataList = res.result.records || []
this.total = res.result.total
this.loading = false
} else {
this.dataList = []
this.total = 0
this.loading = false
}
})
},
onSelectChange(value) {
this.selectedRowKeys = value
},
handleCancel() {
this.visible = false
},
handleSubmit() {
this.$emit('versionStatisticsForm', this.selectedRowKeys)
this.visible = false
}
}
}
</script>
<style scoped>
.page {
text-align: right;
margin-top: 20px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
width: 100%;
z-index: 100;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
.box-title-text {
line-height: 1.4;
display: flex;
align-items: center;
margin-bottom: 10px;
}
.title-text {
width: 33px;
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: 100%;
height: 38px;
}
.box-button {
height: 38px;
}
</style>
@@ -0,0 +1,701 @@
<template>
<div class="doc-detail">
<div class="Virtual-detail-header" style="position: fixed;top: 0">
<div class="Virtual-detail-title">
<span style="line-height: 64px;display: inline-block;float: left">
<a-icon @click="backClick" type="left-circle" theme="filled"
style="margin-right: 8px;font-size: 30px;color: #21c9cc;"/>
</span>
<span>
{{ this.title }}
</span>
</div>
<div class="Virtual-detail-text-right">
<!-- 待办中心-->
<div class="operator-text"
v-if="textTitle === $t('listOfRegulations')"
v-has="'projectComment:list'"
@click="todocenterClick">
<a-icon type="qrcode"/>
{{ $t('todocenter') }}
</div>
<!-- 更新LOGO-->
<div class="operator-text" v-has="'projectLawsInventoryLog:page'"
v-if="textTitle === $t('listOfRegulations')"
@click="UpdateLogClick">
<a-icon type="reload"/>
{{ $t('UpdateLog') }}
</div>
<!-- 历史版本-->
<div class="operator-text" v-has="'projectHistoryVersions:list'"
v-if="textTitle === $t('listOfRegulations')"
@click="historicalVersionClick">
<a-icon type="clock-circle"/>
{{ $t('historicalVersion') }}
</div>
<!-- 切换用户-->
<a-popconfirm overlayClassName="popconfirmDetails"
:visible="visible"
@visibleChange="handleVisibleChange"
placement="bottomRight">
<template slot="title" id="popconfirmDetails">
<div @click="roleSwitchingClick(item.roleCode)"
v-for="(item,index) in roleSwitchingList"
class="operator-text-title"
:class="{'operator-text-title-color' :item.roleName == roleSwitchName ? true : false}"
:title="item.roleName">
{{ item.roleName }}
</div>
<JLoading :loading="JTextLoading"></JLoading>
</template>
<div class="operator-text" style="position: relative"
v-if="(textTitle === $t('certificationList') || textTitle === $t('listOfRegulations')) && roleSwitchName">
<a-icon type="select"/>
{{ roleSwitchName }}
</div>
</a-popconfirm>
</div>
</div>
<!-- 左侧切换按钮-->
<div style="padding: 52px 0 0 0;background: #ffffff;height:100%">
<div class="detail-content" style="height: 100%">
<div v-if="isDisplay" class="Virtual-detail-left">
<!-- 项目详情-->
<div class="Virtual-detail-left-text" :title="$t('projectDetails')"
v-has="'projectLawsInventory:projectDetails'"
v-if="isTrue"
@click="textClick(0,$t('projectDetails'))">
<a-icon type="container"/>
{{ $t('projectDetails') }}
</div>
<!-- 法规清单-->
<div class="Virtual-detail-left-text" v-has="'projectLawsInventory:list'" :title="$t('listOfRegulations')"
@click="textClick(1,$t('listOfRegulations'))">
<a-icon type="control"/>
{{ $t('listOfRegulations') }}
</div>
<!-- 认证清单-->
<div class="Virtual-detail-left-text" :title="$t('certificationList')"
v-has="'projectLawsInventory:CertificationList'"
@click="textClick(6,$t('certificationList'))">
<a-icon type="safety"/>
{{ $t('certificationList') }}
</div>
<a-icon @click="textIconClick" type="menu-fold" class="text-icon"/>
</div>
<div v-if="!isDisplay" class="Virtual-detail-left-One">
<div class="Virtual-detail-left-text"
:title="$t('projectDetails')"
v-has="'projectLawsInventory:projectDetails'"
v-if="isTrue"
@click="textClick(0,$t('projectDetails'))">
<a-icon type="container"/>
</div>
<div class="Virtual-detail-left-text" v-has="'projectLawsInventory:list'" :title="$t('listOfRegulations')"
@click="textClick(1,$t('listOfRegulations'))">
<a-icon type="control"/>
</div>
<div class="Virtual-detail-left-text" :title="$t('certificationList')"
v-has="'projectLawsInventory:CertificationList'"
@click="textClick(6,$t('certificationList'))">
<a-icon type="safety"/>
</div>
<a-icon @click="textIconClick" type="menu-unfold" class="text-icon-one"/>
</div>
<div class="Virtual-detail-right"
:style="{'width':isDisplay?'calc(100% - 240px)':'calc(100% - 66px)'}">
<ProjectDetailsName @TaskListChange="TaskListChange" v-if="textTitle === $t('projectDetails')"/>
<listOfRegulations v-else-if="textTitle === $t('listOfRegulations')"
ref="listOfRegulationsRef"
@getRoleSwitch="getRoleSwitch"
@getRoleSwitchingList="getRoleSwitchingList"
:areaOfResponsibilityList="areaOfResponsibilityList"/>
<!-- <TaskList :isDisplayNum="isDisplayNum" :areaOfResponsibility="areaOfResponsibility"-->
<!-- v-else-if="textTitle === $t('taskList')"/>-->
<TaskParameterCollection v-else-if="textTitle === $t('TaskParameterCollection')"/>
<nonConformance v-else-if="textTitle === $t('nonConformance')"/>
<!-- <projectStatus @TaskListChange="TaskListChange"-->
<!-- v-else-if="textTitle === $t('projectStatus')"/>-->
<certificationList ref="certificationListRef"
:isDisplayNum="isDisplayNum"
:areaOfResponsibility="areaOfResponsibility"
@getRoleSwitch="getRoleSwitch"
@getRoleSwitchingList="getRoleSwitchingList"
v-else-if="textTitle === $t('certificationList')"/>
</div>
</div>
</div>
<updateLog :url="url" ref="updateLogRef"/>
<historicalVersionList ref="historicalVersionListRef"/>
<commentList ref="commentListRef"/>
<JLoading :loading="loading"></JLoading>
</div>
</template>
<script>
import TaskList from './components/TaskList'
import SelectedBy from '@/components/SelectedBy/index'
import listOfRegulations from './components/listOfRegulations'
import ProjectDetailsName from './components/ProjectDetails'
import TaskParameterCollection from './components/TaskParameterCollection'
import nonConformance from './components/nonConformance'
import projectStatus from './components/projectStatus'
import updateLog from '@/components/UpdateLog/index'
import historicalVersionList from './components/historicalVersionList'
import commentList from './components/commentList'
import {getAction, postAction, deleteAction, downloadFile} from '@/api/manage'
import certificationList from './components/certificationList/index'
import PersonnelSelection from '@/components/PersonnelSelection/index'
import {mapGetters} from 'vuex'
export default {
name: 'ProjectDetails',
components: {
TaskList,
listOfRegulations,
ProjectDetailsName,
TaskParameterCollection,
nonConformance,
updateLog,
historicalVersionList,
commentList,
projectStatus,
certificationList,
SelectedBy,
PersonnelSelection
},
data() {
return {
title: '',
selectVisible: false,
confirmLoading: false,
submitLoading: false,
isDisplayNum: '',
textTitle: '',
isTrue: true,
loading: false,
selectLoading: false,
JTextLoading: false,
isDisplay: true,
areaOfResponsibilityList: {},
url: {
logList: '/project/projectLawsInventoryLogEO/page',
historicalVersionUrl: '',
queryUserPremissionByProjectLibraryId: '/project/projectCertificationDirectoryEO/queryUserPremissionByProjectLibraryId'
},
roleSwitchListCn: {
'0': 'studio工程师',
'1': '法规工程师',
'2': '认证工程师',
'4': '法规工程师/认证工程师',
'11': 'R&H Manager',
'12': '系统管理员',
'13': 'Viewer',
'14': '品牌管理员',
'20': '工程接口人',
'21': '责任人',
'30': '工程接口人',
'31': '责任人'
},
roleSwitchListEn: {
'0': 'R&H Studio',
'1': 'studio',
'2': 'homo',
'4': 'Regulatory Engineer/Certification Engineer',
'11': 'R&H Manager',
'12': 'admin',
'13': 'Viewer',
'14': 'BrandAdministrator',
'20': 'Interface person',
'21': 'Person liable',
'30': 'Engineering interface person',
'31': 'Person liable'
},
areaOfResponsibility: {},
engineeringInterfacePerson: '',
roleSwitchName: '',
roleSwitchingList: [],
visible: false,
userIds: '',
userName: '',
dataSource: [],
columns: [
{
title: this.$t('replacedPerson'),
align: 'left',
dataIndex: 'userName',
width: 180,
customRender: (value, row, index) => {
const obj = {
children: value,
attrs: {}
}
if (index === 0) {
obj.attrs.rowSpan = row.maxLength
} else {
obj.attrs.rowSpan = 0
}
return obj
}
},
{
title: this.$t('areaOfResponsibility'),
align: 'left',
dataIndex: 'title',
width: 180
},
{
title: this.$t('replacementPerson'),
align: 'left',
dataIndex: 'replacementPerson',
width: 180,
scopedSlots: {customRender: 'replacementPerson'}
}
]
}
},
created() {
document.title = this.$route.query.projectName ? this.$t('projectDetails') + '-' + this.$route.query.projectName : this.$t('projectDetails')
this.title = this.$route.query.projectName
},
mounted() {
this.getTaskId()
if (this.$route.query.type) {
if (this.$route.query.type == '101') {
this.textColor(this.$t('projectDetails'))
this.textTitle = this.$t('projectDetails')
} else if (this.$route.query.type == '102') {
if (this.$route.query.dutyTerritoryName) {
this.areaOfResponsibilityList = this.$route.query
}
this.textColor(this.$t('listOfRegulations'))
this.textTitle = this.$t('listOfRegulations')
} else if (this.$route.query.type == '103') {
// this.textColor(this.$t('taskList'))
// this.textTitle = this.$t('taskList')
this.$router.push({
path: '/projectRegulationTasks'
})
} else if (this.$route.query.type == '104') {
// this.textColor(this.$t('nonConformance'))
// this.textTitle = this.$t('nonConformance')
} else if (this.$route.query.type == '105') {
this.textColor(this.$t('TaskParameterCollection'))
this.textTitle = this.$t('TaskParameterCollection')
} else if (this.$route.query.type == '106') {
if (this.$route.query.dutyTerritoryName) {
this.areaOfResponsibility = this.$route.query
}
this.textColor(this.$t('certificationList'))
this.textTitle = this.$t('certificationList')
}
} else {
if (this.userInfo().userRoleList && this.userInfo().userRoleList.length > 0) {
if (this.userInfo().userRoleList.length == 1 && this.userInfo().userRoleList[0].roleCode == 'sdt') {
this.getList()
} else {
this.textColor(0)
}
} else {
this.textColor(0)
}
}
},
methods: {
...mapGetters(['userInfo']),
textIconClick() {
this.isDisplay = !this.isDisplay
},
globalReplacementClick() {
this.$refs.SelectedByRef.getPush()
},
SelectedByForm(userIds, userName) {
this.userIds = userIds
this.userName = userName
this.selectVisible = true
this.$refs.SelectedByRef.visible = false
this.$refs.SelectedByRef.submitLoading = false
this.getUserAllDutyTerritoryList()
},
getUserAllDutyTerritoryList() {
let query = {
projectLibraryId: this.$route.query.id,
userName: this.userName,
userId: this.userIds
}
this.selectLoading = true
getAction('/project/projectLibraryBase/getUserAllDutyTerritoryList', query).then((res) => {
if (res.success) {
this.dataSource = res.result || []
this.dataSource.forEach(val => {
val.newUserId = ''
val.userName = this.userName
val.maxLength = this.dataSource.length
})
this.selectLoading = false
} else {
this.dataSource = []
this.selectLoading = false
}
})
},
handleCancel() {
this.selectVisible = false
},
handleSubmit() {
if (this.dataSource.length > 0) {
let replacementUserList = []
this.dataSource.forEach(res => {
replacementUserList.push({
dutyTerritory: res.value,
newUserId: res.newUserId || '',
newUserName: res.newUserIdName || ''
})
})
let query = {
userId: this.userIds,
projectLibraryId: this.$route.query.id,
userName: this.userName,
replacementUserList: replacementUserList
}
this.submitLoading = true
postAction('/project/projectLibraryBase/overallReplacementUser', query).then((res) => {
if (res.success) {
this.$message.success(this.$t('OperationSuccessful'))
this.submitLoading = false
this.selectVisible = false
this.dataSource = []
this.userName = ''
this.userIds = ''
let textTitle = this.textTitle
this.textTitle = ''
this.$nextTick(() => {
this.textTitle = textTitle
})
} else {
this.$message.warning(this.$t('operationFailed'))
this.submitLoading = false
}
})
} else {
this.$message.warning(this.$t('thereReplaceableData'))
}
},
textColor(name) {
let textColor = document.getElementsByClassName('Virtual-detail-left-text-color')
if (textColor && textColor.length > 0) {
textColor[0].classList.remove('Virtual-detail-left-text-color')
}
let text = document.getElementsByClassName('Virtual-detail-left-text')
if (name == 0) {
text[name].classList.add('Virtual-detail-left-text-color')
this.textTitle = text[name].title
} else {
if (text && text.length > 0) {
for (let i = 0; i < text.length; i++) {
if (text[i].title == name) {
text[i].classList.add('Virtual-detail-left-text-color')
} else if (text[i].title == name) {
text[i].classList.add('Virtual-detail-left-text-color')
} else if (text[i].title == name) {
text[i].classList.add('Virtual-detail-left-text-color')
} else if (text[i].title == name) {
text[i].classList.add('Virtual-detail-left-text-color')
} else if (text[i].title == name) {
text[i].classList.add('Virtual-detail-left-text-color')
}
}
}
}
},
textClick(num, name) {
this.areaOfResponsibilityList = {}
this.areaOfResponsibility = {}
this.textTitle = name
let textColor = document.getElementsByClassName('Virtual-detail-left-text-color')
if (textColor && textColor.length > 0) {
textColor[0].classList.remove('Virtual-detail-left-text-color')
}
let text = document.getElementsByClassName('Virtual-detail-left-text')
for (let i = 0; i < text.length; i++) {
if (text[i].title == name) {
text[i].classList.add('Virtual-detail-left-text-color')
} else if (text[i].title == name) {
text[i].classList.add('Virtual-detail-left-text-color')
} else if (text[i].title == name) {
text[i].classList.add('Virtual-detail-left-text-color')
} else if (text[i].title == name) {
text[i].classList.add('Virtual-detail-left-text-color')
} else if (text[i].title == name) {
text[i].classList.add('Virtual-detail-left-text-color')
}
}
},
//待办中心跳转
todocenterClick() {
this.$router.push({
path: '/projectRegulationTasks',
query: {
projectName: this.$route.query.projectName
}
})
},
UpdateLogClick() {
this.$refs.updateLogRef.getList({projectLibraryId: this.$route.query.id})
},
historicalVersionClick() {
this.$refs.historicalVersionListRef.getList()
},
commentClick() {
this.$refs.commentListRef.getData()
},
getTaskId() {
let query = {
projectLibraryId: this.$route.query.id
}
getAction(this.url.queryUserPremissionByProjectLibraryId, query).then((res) => {
if (res.success) {
this.isDisplayNum = res.result
}
})
},
getList() {
let query = {
projectId: this.$route.query.id
}
this.loading = true
postAction('/project/projectRelatedPersonnel/page', query).then((res) => {
if (res.success) {
let dataSource = res.result || []
dataSource.forEach(res => {
if (res.engineeringInterfacePerson || res.certificationEngineer || res.lawEngineer) {
this.engineeringInterfacePerson += res.engineeringInterfacePerson + ',' + res.certificationEngineer + ',' + res.lawEngineer + ','
}
})
if (this.engineeringInterfacePerson.includes(this.userInfo().id) ||
this.$route.query.studioEngineer == this.userInfo().id) {
this.isTrue = true
} else {
this.isTrue = false
}
this.$nextTick(() => {
this.textColor(0)
})
this.loading = false
} else {
this.textColor(0)
this.loading = false
}
})
},
TaskListChange(item) {
if (item.isListing && item.isListing == '1') {
this.areaOfResponsibilityList = item
this.textTitle = this.$t('listOfRegulations')
} else {
this.areaOfResponsibility = item
this.textTitle = this.$t('certificationList')
}
let textColor = document.getElementsByClassName('Virtual-detail-left-text-color')
if (textColor && textColor.length > 0) {
textColor[0].classList.remove('Virtual-detail-left-text-color')
}
let text = document.getElementsByClassName('Virtual-detail-left-text')
for (let i = 0; i < text.length; i++) {
if (text[i].title == this.textTitle) {
text[i].classList.add('Virtual-detail-left-text-color')
}
}
},
backClick() {
this.$router.push({
path: '/projectLibrary'
})
},
roleSwitchingClick(roleCode) {
this.JTextLoading = true
if (this.textTitle === this.$t('listOfRegulations')) {
this.$refs.listOfRegulationsRef.handleOkRoleSwitching(roleCode)
} else {
this.$refs.certificationListRef.handleOkRoleSwitching(roleCode)
}
},
getRoleSwitchingList(list) {
this.roleSwitchingList = list || []
this.roleSwitchingList = [...this.roleSwitchingList]
},
handleVisibleChange(visible) {
this.visible = visible
},
getRoleSwitch(value) {
let long = localStorage.getItem('language') || 'zh-cn'
if (long == 'zh-cn') {
this.roleSwitchName = this.roleSwitchListCn[value]
} else {
this.roleSwitchName = this.roleSwitchListEn[value]
}
this.JTextLoading = false
this.visible = false
},
PersonnelSelectionChange(value, id, index) {
this.dataSource[index][value] = id
this.dataSource = [...this.dataSource]
}
}
}
</script>
<style lang="less" scoped>
@import '~@assets/less/common.less';
.doc-detail {
background: #fff;
height: 100%;
position: relative;
.Virtual-detail-header {
width: 100%;
height: 56px;
line-height: 56px;
padding: 0 32px 0 32px;
box-sizing: border-box;
display: flex;
justify-content: space-between;
border-bottom: 2px #eff1f3 solid;
background: #fff;
.Virtual-detail-title {
display: inline-block;
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
font-size: 20px;
font-weight: 400;
color: #040B29;
line-height: 55px;
}
.doc-detail-right {
width: 800px;
line-height: 68px;
display: flex;
}
}
.Virtual-detail-left {
width: 240px;
flex: 0 0 240px;
padding: 16px 24px;
box-sizing: border-box;
font-size: 16px;
line-height: 3;
float: left;
transition: all 0.2s;
.Virtual-detail-left-text {
padding: 2px 12px;
cursor: pointer;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
}
.Virtual-detail-left-One {
width: 66px;
flex: 0 0 66px;
display: inline-block;
padding: 16px 16px;
box-sizing: border-box;
font-size: 18px;
right: 0;
transition: all 0.2s;
.Virtual-detail-left-text {
padding: 2px 8px;
cursor: pointer;
margin-bottom: 18px;
color: rgb(0, 0, 0);
}
}
.Virtual-detail-right {
border-left: 2px #eff1f3 solid;
height: 100%;
float: right;
overflow: auto;
transition: all 0.2s;
}
}
.Virtual-detail-left-text-color {
background: #eff1f3;
border-radius: 4px;
}
.Virtual-detail-text-right {
}
.text-icon {
color: rgb(0, 0, 0);
font-size: 22px;
position: absolute;
left: 200px;
bottom: 20px;
transition: all 0.2s;
}
.text-icon-one {
color: rgb(0, 0, 0);
font-size: 22px;
position: absolute;
left: 22px;
bottom: 20px;
transition: all 0.2s;
}
.operator-text-title {
cursor: pointer;
margin-right: 22px;
font-size: 14px;
font-weight: 400;
color: #040B29;
margin-bottom: 22px;
}
.operator-text-title:last-child {
margin-bottom: 0;
}
.operator-text-title-color {
color: #00B3BE;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
z-index: 100;
width: 100%;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
</style>
<style>
.popconfirmDetails {
z-index: 999;
top: 42px !important;
}
.popconfirmDetails .ant-popover-buttons {
display: none !important;
}
.popconfirmDetails .anticon-exclamation-circle {
display: none !important;
}
</style>