[update] 调了一部分年度制修订计划

This commit is contained in:
lideqin
2023-10-23 18:26:25 +08:00
parent ffe1f88052
commit 1db65059a0
11 changed files with 535 additions and 330 deletions
+1
View File
@@ -93,6 +93,7 @@ module.exports = {
affiliatedWorkingGroup: '隶属工作组',
contactsSupervisorLevelLeaders: '收集联络人主管级领导',
templateExport: '年度制修订计划(各部门上报)导入模板',
standardizationInitTemplate: '年度制修订计划(标准化发起)导入模板',
batchSetContact: '批量设置联络人',
contactPerson: '联络人',
batchSetApprover: '批量设置审批人',
+1
View File
@@ -93,6 +93,7 @@ module.exports = {
affiliatedWorkingGroup: '隶属工作组',
contactsSupervisorLevelLeaders: '收集联络人主管级领导',
templateExport: '年度制修订计划(各部门上报)导入模板',
standardizationInitTemplate: '年度制修订计划(标准化发起)导入模板',
batchSetContact: '批量设置联络人',
contactPerson: '联络人',
batchSetApprover: '批量设置审批人',
@@ -236,6 +236,7 @@ export default {
data () {
return {
switchValue: 'base',
loading: false,
processInfoForm: this.$form.createForm(this),
labelCol: {
xs: { span: 24 },
@@ -254,6 +255,7 @@ export default {
sm: { span: 22 }
},
disabled: false,
onlyLook: false,
validatorRules: {
// 流程名称
processName: {
@@ -38,19 +38,19 @@
{{ $t('workCenter.enterpriseInitChangePlan.itemCategory') }}
</span>
</div>
<a-form-model-item class="item-model" prop="itemCategory">
<a-select v-model="formInline.itemCategory"
@change="itemCategoryChange"
<a-form-model-item class="item-model" prop="projectType">
<a-select v-model="formInline.projectType"
@change="projectTypeChange"
:disabled="disabled"
:placeholder="$t('pleaseSelect')+$t('workCenter.enterpriseInitChangePlan.itemCategory')">
<a-select-option :value="1">{{ $t('workCenter.enterpriseInitChangePlan.formulate') }}</a-select-option>
<a-select-option :value="2">{{ $t('workCenter.enterpriseInitChangePlan.revise') }}</a-select-option>
<a-select-option :value="ProjectType.ENACT.value">{{ $t('workCenter.enterpriseInitChangePlan.formulate') }}</a-select-option>
<a-select-option :value="ProjectType.MODIFY.value">{{ $t('workCenter.enterpriseInitChangePlan.revise') }}</a-select-option>
</a-select>
</a-form-model-item>
</div>
<!-- 标准立项-制定 -->
<template v-if="formInline.itemCategory && formInline.itemCategory === 1">
<!-- 企标编号 -->
<template v-if="formInline.projectType && formInline.projectType === ProjectType.ENACT.value">
<!-- 企标编号-新企标编号 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text">
<span class="required">*</span>
@@ -58,15 +58,15 @@
{{ $t('workCenter.enterpriseInitChangePlan.enterpriseStandardNum') }}
</span>
</div>
<a-form-model-item class="item-model" prop="enterpriseStandardNum">
<a-form-model-item class="item-model" prop="newEnStandardNo">
<a-input class="box-input"
v-model="formInline.enterpriseStandardNum"
v-model="formInline.newEnStandardNo"
:maxLength="50"
disabled
:placeholder="$t('pleaseEnter')+$t('workCenter.enterpriseInitChangePlan.enterpriseStandardNum')" />
</a-form-model-item>
</div>
<!-- 企标名称 -->
<!-- 企标名称-新企标名称 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text">
<span class="required">*</span>
@@ -74,9 +74,9 @@
{{ $t('workCenter.enterpriseInitChangePlan.enterpriseStandardName') }}
</span>
</div>
<a-form-model-item class="item-model" prop="enterpriseStandardName">
<a-form-model-item class="item-model" prop="newEnStandardName">
<a-input class="box-input"
v-model="formInline.enterpriseStandardName"
v-model="formInline.newEnStandardName"
:maxLength="50"
:disabled="disabled"
:placeholder="$t('pleaseEnter')+$t('workCenter.enterpriseInitChangePlan.enterpriseStandardName')" />
@@ -90,9 +90,10 @@
{{ $t('workCenter.enterpriseInitChangePlan.enterpriseStandardCode') }}
</span>
</div>
<a-form-model-item class="item-model" prop="enterpriseStandardCode">
<a-form-model-item class="item-model" prop="enStandardCode">
<j-dict-select-tag class="box-input"
v-model="formInline.enterpriseStandardCode"
ref="enStandardCodeRef"
v-model="formInline.enStandardCode"
:placeholder="$t('pleaseSelect')+$t('workCenter.enterpriseInitChangePlan.enterpriseStandardCode')"
:type="'select'"
:triggerChange="false"
@@ -108,9 +109,9 @@
{{ $t('workCenter.enterpriseInitChangePlan.enterpriseNameCode') }}
</span>
</div>
<a-form-model-item class="item-model" prop="enterpriseNameCode">
<a-form-model-item class="item-model" prop="enNameCode">
<j-dict-select-tag class="box-input"
v-model="formInline.enterpriseNameCode"
v-model="formInline.enNameCode"
:placeholder="$t('pleaseSelect')+$t('workCenter.enterpriseInitChangePlan.enterpriseNameCode')"
:type="'select'"
:triggerChange="false"
@@ -144,19 +145,20 @@
{{ $t('workCenter.enterpriseInitChangePlan.yearNumber') }}
</span>
</div>
<a-form-model-item class="item-model" prop="yearNumber">
<a-form-model-item class="item-model" prop="decadeCode">
<j-date show-type="year"
v-model="formInline.yearNumber"
v-model="formInline.decadeCode"
:default-value="yearNumberDefaultValue"
date-format="YYYY"
:disabled="disabled"
@change="decadeCodeChange"
:placeholder="$t('pleaseSelect')+$t('workCenter.enterpriseInitChangePlan.yearNumber')" />
</a-form-model-item>
</div>
</template>
<!-- 标准立项-修订 -->
<template v-else-if="formInline.itemCategory && formInline.itemCategory === 2">
<!-- 企标编号 -->
<template v-else-if="formInline.projectType && formInline.projectType === ProjectType.MODIFY.value">
<!-- 企标编号-原企标编号 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text">
<span class="required">*</span>
@@ -164,46 +166,46 @@
{{ $t('workCenter.enterpriseInitChangePlan.enterpriseStandardNum') }}
</span>
</div>
<a-form-model-item class="item-model" prop="enterpriseStandardNum">
<a-form-model-item class="item-model" prop="originEnStandardNo">
<standard-selection :source="StandardSource.ENTERPRISE.value"
:disabledSourceSearch="true"
type="radio"
:disabled="disabled"
v-model="formInline.enterpriseStandardNum"
v-model="formInline.originEnStandardNo"
@nameChange="nameChange"/>
</a-form-model-item>
</div>
<!-- 企标名称 -->
<!-- 企标名称-原企标名称 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text">
<span class="title-text-text" :title="$t('workCenter.enterpriseInitChangePlan.enterpriseStandardName')">
{{ $t('workCenter.enterpriseInitChangePlan.enterpriseStandardName') }}
</span>
</div>
<a-form-model-item class="item-model" prop="enterpriseStandardName">
<a-form-model-item class="item-model" prop="originEnStandardName">
<a-input class="box-input"
v-model="formInline.enterpriseStandardName"
v-model="formInline.originEnStandardName"
:maxLength="50"
disabled
:placeholder="$t('pleaseEnter')+$t('workCenter.enterpriseInitChangePlan.enterpriseStandardName')" />
</a-form-model-item>
</div>
<!-- 新企标编号 根据选的企标编号的那三个代号生成新的编号 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text">
<span class="required">*</span>
<span class="title-text-text" :title="$t('workCenter.enterpriseInitChangePlan.newEnterpriseStandardNum')">
{{ $t('workCenter.enterpriseInitChangePlan.newEnterpriseStandardNum') }}
</span>
</div>
<a-form-model-item class="item-model" prop="newEnterpriseStandardNum">
<a-input class="box-input"
v-model="formInline.newEnterpriseStandardNum"
:maxLength="50"
disabled
:placeholder="$t('pleaseEnter')+$t('workCenter.enterpriseInitChangePlan.newEnterpriseStandardNum')" />
</a-form-model-item>
</div>
<!-- 新企标编号 审批结束后才回显 -->
<!--<div class="box-title-text form-flex-item-half">-->
<!-- <div class="title-text">-->
<!-- <span class="required">*</span>-->
<!-- <span class="title-text-text" :title="$t('workCenter.enterpriseInitChangePlan.newEnterpriseStandardNum')">-->
<!-- {{ $t('workCenter.enterpriseInitChangePlan.newEnterpriseStandardNum') }}-->
<!-- </span>-->
<!-- </div>-->
<!-- <a-form-model-item class="item-model" prop="newEnStandardNo">-->
<!-- <a-input class="box-input"-->
<!-- v-model="formInline.newEnStandardNo"-->
<!-- :maxLength="50"-->
<!-- disabled-->
<!-- :placeholder="$t('pleaseEnter')+$t('workCenter.enterpriseInitChangePlan.newEnterpriseStandardNum')" />-->
<!-- </a-form-model-item>-->
<!--</div>-->
<!-- 新企标名称 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text">
@@ -212,9 +214,9 @@
{{ $t('workCenter.enterpriseInitChangePlan.newEnterpriseStandardName') }}
</span>
</div>
<a-form-model-item class="item-model" prop="newEnterpriseStandardName">
<a-form-model-item class="item-model" prop="newEnStandardName">
<a-input class="box-input"
v-model="formInline.newEnterpriseStandardName"
v-model="formInline.newEnStandardName"
:maxLength="50"
:disabled="disabled"
:placeholder="$t('pleaseEnter')+$t('workCenter.enterpriseInitChangePlan.newEnterpriseStandardName')" />
@@ -228,9 +230,9 @@
{{ $t('workCenter.enterpriseInitChangePlan.standardEnglishName') }}
</span>
</div>
<a-form-model-item class="item-model" prop="standardEnglishName">
<a-form-model-item class="item-model" prop="enStandardEnglishName">
<a-input class="box-input"
v-model="formInline.standardEnglishName"
v-model="formInline.enStandardEnglishName"
:maxLength="50"
:disabled="disabled"
:placeholder="$t('pleaseEnter')+$t('workCenter.enterpriseInitChangePlan.standardEnglishName')" />
@@ -244,9 +246,9 @@
{{ $t('workCenter.enterpriseInitChangePlan.standardSystem') }}
</span>
</div>
<a-form-model-item class="item-model" prop="standardSystem">
<a-form-model-item class="item-model" prop="enStandardSystem">
<a-tree-select
v-model="formInline.standardSystem"
v-model="formInline.enStandardSystem"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
style="width: 100%"
:tree-data="standardSystemOptions"
@@ -283,9 +285,9 @@
{{ $t('workCenter.enterpriseInitChangePlan.standardGradeClassification') }}
</span>
</div>
<a-form-model-item class="item-model" prop="standardGradeClassification">
<a-form-model-item class="item-model" prop="enStandardClassification">
<j-dict-select-tag class="box-input"
v-model="formInline.standardGradeClassification"
v-model="formInline.enStandardClassification"
:placeholder="$t('pleaseSelect')+$t('workCenter.enterpriseInitChangePlan.standardGradeClassification')"
:type="'select'"
:triggerChange="false"
@@ -300,11 +302,11 @@
{{ $t('workCenter.enterpriseInitChangePlan.compilationIllustration') }}
</span>
</div>
<a-form-model-item class="item-model" prop="compilationIllustration">
<a-button type="primary" class="button-text" @click="clickButtonToUpload('compilationIllustration')">
<a-form-model-item class="item-model" prop="compilationDescription">
<a-button type="primary" class="button-text" @click="clickButtonToUpload('compilationDescription')">
{{
(formInline.compilationIllustration === 'null' || formInline.compilationIllustration === ''
|| formInline.compilationIllustration === null || formInline.compilationIllustration === undefined)
(formInline.compilationDescription === 'null' || formInline.compilationDescription === ''
|| formInline.compilationDescription === null || formInline.compilationDescription === undefined)
? $t('uploadFile.clickUpload')
: $t('uploadFile.viewUploadedFiles')
}}
@@ -319,9 +321,9 @@
{{ $t('workCenter.enterpriseInitChangePlan.draftPlanFinishDate') }}
</span>
</div>
<a-form-model-item class="item-model" prop="draftPlanFinishDate">
<a-form-model-item class="item-model" prop="draftPlannedCompleteDate">
<a-date-picker
v-model="formInline.draftPlanFinishDate"
v-model="formInline.draftPlannedCompleteDate"
:showTime="false"
:disabled="disabled"
value-format="YYYY-MM-DD">
@@ -336,9 +338,9 @@
{{ $t('workCenter.enterpriseInitChangePlan.exposureDraftPlanFinishDate') }}
</span>
</div>
<a-form-model-item class="item-model" prop="exposureDraftPlanFinishDate">
<a-form-model-item class="item-model" prop="solicitationDraftPlanCompleteDate">
<a-date-picker
v-model="formInline.exposureDraftPlanFinishDate"
v-model="formInline.solicitationDraftPlanCompleteDate"
:showTime="false"
:disabled="disabled"
value-format="YYYY-MM-DD">
@@ -353,9 +355,9 @@
{{ $t('workCenter.enterpriseInitChangePlan.planSubmissionDate') }}
</span>
</div>
<a-form-model-item class="item-model" prop="planSubmissionDate">
<a-form-model-item class="item-model" prop="planApprovalDate">
<a-date-picker
v-model="formInline.planSubmissionDate"
v-model="formInline.planApprovalDate"
:showTime="false"
:disabled="disabled"
value-format="YYYY-MM-DD">
@@ -370,12 +372,13 @@
{{ $t('workCenter.revisionPlanActivelyReport.affiliatedWorkingGroup') }}
</span>
</div>
<a-form-model-item class="item-model" prop="affiliatedWorkingGroup">
<a-form-model-item class="item-model" prop="workGroup">
<a-tree-select
tree-node-filter-prop="title"
v-model="formInline.affiliatedWorkingGroup"
v-model="formInline.workGroup"
:maxTagCount="1"
:show-search="true"
labelInValue
:getPopupContainer="triggerNode=> triggerNode.parentNode"
style="width: 100%"
:tree-data="workingGroupTreeList"
@@ -397,8 +400,8 @@
{{ $t('workCenter.enterpriseInitChangePlan.partName') }}
</span>
</div>
<a-form-model-item class="item-model" prop="partName">
<a-tree-select v-model="formInline.partName"
<a-form-model-item class="item-model" prop="componentName">
<a-tree-select v-model="formInline.componentName"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
style="width: 100%"
:tree-data="partNameOptions"
@@ -415,9 +418,10 @@
{{ $t('workCenter.enterpriseInitChangePlan.authorizationDepart') }}
</span>
</div>
<a-form-model-item class="item-model" prop="authorizationDepart">
<j-select-depart v-model="formInline.authorizationDepart"
<a-form-model-item class="item-model" prop="authDept">
<j-select-depart v-model="formInline.authDept"
:disabled="disabled"
@back="authDeptBack"
:backDepart="true" />
</a-form-model-item>
</div>
@@ -429,12 +433,12 @@
{{ $t('workCenter.enterpriseInitChangePlan.principalDrafter') }}
</span>
</div>
<a-form-model-item class="item-model" prop="principalDrafter">
<a-form-model-item class="item-model" prop="mainDraftingUser">
<user-selection :placeholder="$t('pleaseSelect')+$t('workCenter.enterpriseInitChangePlan.principalDrafter')"
v-model="formInline.principalDrafter"
filedName="principalDrafter"
v-model="formInline.mainDraftingUser"
filedName="mainDraftingUser"
@nameChange="userSelectNameChange"
:nameStr="formInline.principalDrafter_dictText"
:nameStr="formInline.mainDraftingUser_dictText"
:disabled="disabled"
type="radio" />
</a-form-model-item>
@@ -447,9 +451,10 @@
{{ $t('workCenter.enterpriseInitChangePlan.mainDraftUnit') }}
</span>
</div>
<a-form-model-item class="item-model" prop="mainDraftUnit">
<j-select-depart v-model="formInline.mainDraftUnit"
<a-form-model-item class="item-model" prop="mainDraftingUnit">
<j-select-depart v-model="formInline.mainDraftingUnit"
:disabled="disabled"
@back="mainDraftingUnitBack"
:backDepart="true" />
</a-form-model-item>
</div>
@@ -461,12 +466,12 @@
{{ $t('workCenter.enterpriseInitChangePlan.headOfMainDraftingUnit') }}
</span>
</div>
<a-form-model-item class="item-model" prop="headOfMainDraftingUnit">
<a-form-model-item class="item-model" prop="mainDraftingUnitResponsiblePerson">
<user-selection :placeholder="$t('pleaseSelect')+$t('workCenter.enterpriseInitChangePlan.headOfMainDraftingUnit')"
v-model="formInline.headOfMainDraftingUnit"
filedName="headOfMainDraftingUnit"
v-model="formInline.mainDraftingUnitResponsiblePerson"
filedName="mainDraftingUnitResponsiblePerson"
@nameChange="userSelectNameChange"
:nameStr="formInline.headOfMainDraftingUnit_dictText"
:nameStr="formInline.mainDraftingUnitResponsiblePerson_dictText"
:disabled="disabled"
type="radio" />
</a-form-model-item>
@@ -479,12 +484,12 @@
{{ $t('workCenter.enterpriseInitChangePlan.standardPusher') }}
</span>
</div>
<a-form-model-item class="item-model" prop="standardPusher">
<a-form-model-item class="item-model" prop="standardPromoter">
<user-selection :placeholder="$t('pleaseSelect')+$t('workCenter.enterpriseInitChangePlan.standardPusher')"
v-model="formInline.standardPusher"
filedName="standardPusher"
v-model="formInline.standardPromoter"
filedName="standardPromoter"
@nameChange="userSelectNameChange"
:nameStr="formInline.standardPusher_dictText"
:nameStr="formInline.standardPromoter_dictText"
:disabled="disabled"
type="radio" />
</a-form-model-item>
@@ -504,7 +509,7 @@
</template>
<script>
import { StandardSource } from '@/enums/commonEnums'
import { StandardSource, ProjectType } from '@/enums/commonEnums'
import { getWorkGroupTreeList, getFormDictTreeList } from '@/api/api'
import UserSelection from '@/components/selection/UserSelection'
import StandardSelection from '@/components/selection/StandardSelection'
@@ -512,6 +517,7 @@ import UploadFile from '@/components/UploadFile'
import { getTreeList } from '@/api/enterpriseStandardLibraryApi'
import Vue from 'vue'
import { USER_INFO } from '@/store/mutation-types'
import { getEnStandardNo } from '@/api/workCenter'
export default {
name: 'ContactEnterSendTaskModal',
@@ -519,6 +525,7 @@ export default {
data () {
return {
StandardSource,
ProjectType,
workingGroupTreeList: [], // 隶属工作组下拉框数据
partNameOptions: [], // 零部件名称下拉框数据
standardSystemOptions: [], // 企标体系下拉框数据
@@ -537,15 +544,23 @@ export default {
}
],
// 项目类别
itemCategory: [
projectType: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.itemCategory') + this.$t('cannotEmpty'),
trigger: 'change'
}
],
// 企标编号
enterpriseStandardNum: [
// 企标编号-新企标编号(制定-企标编号,修订新企标编号)
newEnStandardNo: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.enterpriseStandardNum') + this.$t('cannotEmpty'),
trigger: 'change'
}
],
// 企标编号-原企标编号(修订-企标编号)
originEnStandardNo: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.enterpriseStandardNum') + this.$t('cannotEmpty'),
@@ -553,7 +568,7 @@ export default {
}
],
// 企业标准代号
enterpriseStandardCode: [
enStandardCode: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.enterpriseStandardCode') + this.$t('cannotEmpty'),
@@ -568,8 +583,8 @@ export default {
trigger: 'change'
}
],
// 企标名称
enterpriseStandardName: [
// 企标名称-新企标名称(制定-企标名称,修订-新企标名称)
newEnStandardName: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.enterpriseStandardName') + this.$t('cannotEmpty'),
@@ -577,7 +592,7 @@ export default {
}
],
// 企业名称代号
enterpriseNameCode: [
enNameCode: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.enterpriseNameCode') + this.$t('cannotEmpty'),
@@ -585,7 +600,7 @@ export default {
}
],
// 年代号
yearNumber: [
decadeCode: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.yearNumber') + this.$t('cannotEmpty'),
@@ -609,7 +624,7 @@ export default {
}
],
// 标准体系
standardSystem: [
enStandardSystem: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.standardSystem') + this.$t('cannotEmpty'),
@@ -617,7 +632,7 @@ export default {
}
],
// 标准等级分类
standardGradeClassification: [
enStandardClassification: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.standardGradeClassification') + this.$t('cannotEmpty'),
@@ -625,7 +640,7 @@ export default {
}
],
// 草稿计划完成日期
draftPlanFinishDate: [
draftPlannedCompleteDate: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.draftPlanFinishDate') + this.$t('cannotEmpty'),
@@ -633,7 +648,7 @@ export default {
}
],
// 征求意见稿计划完成日期
exposureDraftPlanFinishDate: [
solicitationDraftPlanCompleteDate: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.exposureDraftPlanFinishDate') + this.$t('cannotEmpty'),
@@ -641,7 +656,7 @@ export default {
}
],
// 计划报批日期
planSubmissionDate: [
planApprovalDate: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.planSubmissionDate') + this.$t('cannotEmpty'),
@@ -649,7 +664,7 @@ export default {
}
],
// 隶属工作组
affiliatedWorkingGroup: [
workGroup: [
{
required: true,
message: this.$t('workCenter.revisionPlanActivelyReport.affiliatedWorkingGroup') + this.$t('cannotEmpty'),
@@ -657,7 +672,7 @@ export default {
}
],
// 零部件名称
partName: [
componentName: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.partName') + this.$t('cannotEmpty'),
@@ -665,7 +680,7 @@ export default {
}
],
// 授权部门
authorizationDepart: [
authDept: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.authorizationDepart') + this.$t('cannotEmpty'),
@@ -673,7 +688,7 @@ export default {
}
],
// 主起草人
principalDrafter: [
mainDraftingUser: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.principalDrafter') + this.$t('cannotEmpty'),
@@ -681,7 +696,7 @@ export default {
}
],
// 主起草单位
mainDraftUnit: [
mainDraftingUnit: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.mainDraftUnit') + this.$t('cannotEmpty'),
@@ -689,7 +704,7 @@ export default {
}
],
// 起草单位负责人
headOfMainDraftingUnit: [
mainDraftingUnitResponsiblePerson: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.headOfMainDraftingUnit') + this.$t('cannotEmpty'),
@@ -697,7 +712,7 @@ export default {
}
],
// 标准推进人
standardPusher: [
standardPromoter: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.standardPusher') + this.$t('cannotEmpty'),
@@ -712,6 +727,20 @@ export default {
return new Date().getFullYear() + ''
}
},
watch: {
// 企业标准代号
'formInline.enStandardCode' (value) {
this.getEnStandardNo()
},
// 企业名称代号
'formInline.enNameCode' (value) {
this.getEnStandardNo()
},
// 标准类别代号
'formInline.standardCategoryCode' (value) {
this.getEnStandardNo()
}
},
mounted () {
this.getWorkGroupTree()
this.initPartNameOptions()
@@ -722,19 +751,21 @@ export default {
const userInfo = Vue.ls.get(USER_INFO)
const formInline = {}
// 初始化主起草人信息
formInline.principalDrafter = userInfo.id
formInline.principalDrafter_dictText = userInfo.realname
// 初始化主起草单位信息
formInline.mainDraftUnit = userInfo.departIds
formInline.mainDraftingUser = userInfo.id
formInline.mainDraftingUser_dictText = userInfo.realname
// 初始化主起草单位信息,需要翻译当前登录用户的部门,因为表格回显
formInline.mainDraftingUnit = userInfo.departIds
formInline.mainDraftingUnit_dictText = userInfo.departIds_dictText
// 初始化起草单位负责人 todo: 看怎么获取当前登录人的上级
// 初始化年代号
formInline.yearNumber = new Date().getFullYear() + ''
formInline.decadeCode = new Date().getFullYear() + ''
this.edit(formInline)
},
edit (record) {
this.visible = true
this.model = Object.assign({}, record)
this.formInline = Object.assign({}, record)
this.formInline.workGroup = { value: this.formInline.workGroup, label: this.formInline.workGroup_dictText }
},
look (record) {
this.visible = true
@@ -742,6 +773,40 @@ export default {
this.formInline = Object.assign({}, record)
this.disabled = true
},
// watch监视年代号会滞后
decadeCodeChange (value) {
this.getEnStandardNo()
},
// 根据三个代号和一个年代号获取企标编号
getEnStandardNo () {
// 如果是制定根据填的三个代号和一个年代号获取
if (this.formInline.projectType === ProjectType.ENACT.value) {
if (!this.formInline.enStandardCode || !this.formInline.enNameCode ||
!this.formInline.standardCategoryCode || !this.formInline.decadeCode) {
return
}
const param = {}
param.enStandardCode = this.formInline.enStandardCode
param.enNameCode = this.formInline.enNameCode
param.standardCategoryCode = this.formInline.standardCategoryCode
param.decadeCode = this.formInline.decadeCode
getEnStandardNo(param).then(res => {
if (res.success) {
this.$set(this.formInline, 'newEnStandardNo', res.message)
this.$forceUpdate()
}
})
} else {
// 是修订,通过选中的企标编号和年代号拼接新企标编号
if (this.formInline.originEnStandardNo && this.formInline.decadeCode) {
const standardNo = this.formInline.originEnStandardNo.split('-')[0] + '-' + this.formInline.decadeCode
this.$set(this.formInline, 'newEnStandardNo', standardNo)
this.$forceUpdate()
// 返回流程名称
this.returnProcessName()
}
}
},
// 获取零部件名称下拉框数据
initPartNameOptions () {
getFormDictTreeList({ dictId: '1696821512600637441' }).then(res => {
@@ -777,19 +842,22 @@ export default {
return item
})
},
// 授权部门返回参数
authDeptBack (value) {
this.formInline.authDept_dictText = value.map(item => item.text).join(',')
},
// 主起草单位返回参数
mainDraftingUnitBack (value) {
this.formInline.mainDraftingUnit_dictText = value.map(item => item.text).join(',')
},
// 标准选择组件返回标准名称的回调
nameChange (value) {
this.formInline.enterpriseStandardName = value
this.formInline.originEnStandardName = value
},
// 项目类别改变
itemCategoryChange (value) {
projectTypeChange (value) {
console.log(value)
if (value === 1) {
this.rules.enterpriseStandardName[0].required = true
} else {
this.rules.enterpriseStandardName[0].required = false
}
this.formInline.yesrNumber = new Date().getFullYear() + ''
this.formInline.decadeCode = new Date().getFullYear() + ''
},
// 选择用户得到用户名
userSelectNameChange (value, fieldName) {
@@ -829,6 +897,30 @@ export default {
if (valid) {
this.confirmLoading = true
const formInline = JSON.parse(JSON.stringify(this.formInline))
if (formInline.projectType) {
// 翻译项目类别
formInline.projectType_dictText = formInline.projectType === 1 ? ProjectType.ENACT.text : ProjectType.MODIFY.text
// 设置变更状态
if (formInline.projectType === 1) {
// 是制定,变更状态是新增
formInline.changeStatus_dictText = '新增'
} else {
// 是修订,变更状态是变更
formInline.changeStatus_dictText = '变更'
}
}
// 翻译隶属工作组
if (formInline.workGroup) {
formInline.workGroup_dictText = formInline.workGroup.label
formInline.workGroup = formInline.workGroup.value
}
// 翻译企业标准代号
if (formInline.enStandardCode) {
formInline.enStandardCode_dictText = this.$refs.enStandardCodeRef.dictOptions.find(item => item.value === formInline.enStandardCode).text
}
// 配合单位弹框中没有该字段,是否要加??
// 主起草单位的回显需要在登录信息中有当前登录人部门的翻译 ??
console.log(formInline)
this.$emit('ok', formInline)
this.close()
this.confirmLoading = false
@@ -32,11 +32,20 @@
:loading="loading"
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}">
<!-- 企标编号/企标名称 -->
<template v-slot:toDetail="{text, record}">
<!-- 企标编号/企标名称 -->
<template v-slot:toDetailOld="{text, record}">
<a-tooltip overlay-class-name="tooltip-style">
<template slot="title">{{ text || text === 0 ? text : global.emptyLine }}</template>
<a v-if="text" class="link-a" @click="handleGoDetail(record)">{{ text }}</a>
<a v-if="text" class="link-a" @click="handleGoDetailOld(record)">{{ text }}</a>
<div v-else class="table-text">{{ global.emptyLine }}</div>
</a-tooltip>
</template>
<!-- 新企标编号/企标名称 -->
<template v-slot:toDetailNew="{text, record}">
<a-tooltip overlay-class-name="tooltip-style">
<template slot="title">{{ text || text === 0 ? text : global.emptyLine }}</template>
<a v-if="text" class="link-a" @click="handleGoDetailNew(record)">{{ text }}</a>
<div v-else class="table-text">{{ global.emptyLine }}</div>
</a-tooltip>
</template>
@@ -186,13 +195,13 @@ export default {
dataIndex: 'cooperationUnit_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 主起草人
title: this.$t('enterpriseStandardLibrary.plan.principalDrafter'),
align: 'center',
width: 180,
dataIndex: 'mainDraftingUser_dictText',
scopedSlots: { customRender: 'text' }
},
// { // 主起草人
// title: this.$t('enterpriseStandardLibrary.plan.principalDrafter'),
// align: 'center',
// width: 180,
// dataIndex: 'mainDraftingUser_dictText',
// scopedSlots: { customRender: 'text' }
// },
{ // 主起草单位
title: this.$t('enterpriseStandardLibrary.plan.mainDraftingUnit'),
align: 'center',
@@ -226,21 +235,21 @@ export default {
align: 'center',
width: 180,
dataIndex: 'draftPlannedCompleteDate',
scopedSlots: { customRender: 'specialDate' }
scopedSlots: { customRender: 'text' }
},
{ // 征求意见稿计划完成日期
title: this.$t('enterpriseStandardLibrary.plan.exposureDraftPlanFinishDate'),
align: 'center',
width: 200,
dataIndex: 'solicitationDraftPlanCompleteDate',
scopedSlots: { customRender: 'specialDate' }
scopedSlots: { customRender: 'text' }
},
{ // 计划报批日期
title: this.$t('enterpriseStandardLibrary.plan.planSubmissionDate'),
align: 'center',
width: 180,
dataIndex: 'planApprovalDate',
scopedSlots: { customRender: 'specialDate' }
scopedSlots: { customRender: 'text' }
},
{ // 变更状态
title: this.$t('enterpriseStandardLibrary.plan.changeState'),
@@ -268,12 +277,21 @@ export default {
}
},
methods: {
// 企标编号,企标名称跳转详情
handleGoDetail (record) {
// 企标编号,企标名称跳转详情,原企标
handleGoDetailOld (record) {
this.$openPageNewSheet({
path: '/enterpriseStandardLibrary/enterpriseStandardDetail',
query: {
standardNumber: record.standardNo
standardNumber: record.originEnStandardNo
}
})
},
// 企标编号,企标名称跳转详情,新企标
handleGoDetailNew (record) {
this.$openPageNewSheet({
path: '/enterpriseStandardLibrary/enterpriseStandardDetail',
query: {
standardNumber: record.newEnStandardNo
}
})
},
@@ -341,8 +359,8 @@ export default {
} else {
this.$message.success(info.file.response.message || `${info.file.name} 文件上传成功`)
}
this.dataSource = Object.assign([], this.dataSource, info.file.response.result)
// this.dataSource.push(info.file.response.result)
// 推入表格中
this.dataSource = this.dataSource.concat(info.file.response.result)
} else {
this.$message.error(`${info.file.name} ${info.file.response.message}.`)
}
@@ -260,7 +260,7 @@ export default {
validateTrigger: 'blur'
}
},
currentNode: 7,
currentNode: 1,
approvalInfoForm: this.$form.createForm(this), // 审批信息表单
personnelInfoData: [], // 人员信息数据
url: {
@@ -33,14 +33,14 @@
<!-- 项目类别 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text">
<span v-if="rules.itemCategory[0].required" class="required">*</span>
<span v-if="rules.projectType[0].required" class="required">*</span>
<span class="title-text-text" :title="$t('workCenter.enterpriseInitChangePlan.itemCategory')">
{{ $t('workCenter.enterpriseInitChangePlan.itemCategory') }}
</span>
</div>
<a-form-model-item class="item-model" prop="itemCategory">
<a-select v-model="formInline.itemCategory"
@change="itemCategoryChange"
<a-form-model-item class="item-model" prop="projectType">
<a-select v-model="formInline.projectType"
@change="projectTypeChange"
:disabled="disabled"
:placeholder="$t('pleaseSelect')+$t('workCenter.enterpriseInitChangePlan.itemCategory')">
<a-select-option :value="1">{{ $t('workCenter.enterpriseInitChangePlan.formulate') }}</a-select-option>
@@ -49,18 +49,18 @@
</a-form-model-item>
</div>
<!-- 标准立项-制定 -->
<template v-if="formInline.itemCategory && formInline.itemCategory === 1">
<template v-if="formInline.projectType && formInline.projectType === 1">
<!-- 企标编号 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text">
<span v-if="rules.enterpriseStandardNum[0].required" class="required">*</span>
<span v-if="rules.newEnStandardNo[0].required" class="required">*</span>
<span class="title-text-text" :title="$t('workCenter.enterpriseInitChangePlan.enterpriseStandardNum')">
{{ $t('workCenter.enterpriseInitChangePlan.enterpriseStandardNum') }}
</span>
</div>
<a-form-model-item class="item-model" prop="enterpriseStandardNum">
<a-form-model-item class="item-model" prop="newEnStandardNo">
<a-input class="box-input"
v-model="formInline.enterpriseStandardNum"
v-model="formInline.newEnStandardNo"
:maxLength="50"
disabled
:placeholder="$t('pleaseEnter')+$t('workCenter.enterpriseInitChangePlan.enterpriseStandardNum')" />
@@ -69,14 +69,14 @@
<!-- 企标名称 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text">
<span v-if="rules.enterpriseStandardName[0].required" class="required">*</span>
<span v-if="rules.newEnStandardName[0].required" class="required">*</span>
<span class="title-text-text" :title="$t('workCenter.enterpriseInitChangePlan.enterpriseStandardName')">
{{ $t('workCenter.enterpriseInitChangePlan.enterpriseStandardName') }}
</span>
</div>
<a-form-model-item class="item-model" prop="enterpriseStandardName">
<a-form-model-item class="item-model" prop="newEnStandardName">
<a-input class="box-input"
v-model="formInline.enterpriseStandardName"
v-model="formInline.newEnStandardName"
:maxLength="50"
:disabled="disabled"
:placeholder="$t('pleaseEnter')+$t('workCenter.enterpriseInitChangePlan.enterpriseStandardName')" />
@@ -85,14 +85,14 @@
<!-- 企业标准代号 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text">
<span v-if="rules.enterpriseStandardCode[0].required" class="required">*</span>
<span v-if="rules.enStandardCode[0].required" class="required">*</span>
<span class="title-text-text" :title="$t('workCenter.enterpriseInitChangePlan.enterpriseStandardCode')">
{{ $t('workCenter.enterpriseInitChangePlan.enterpriseStandardCode') }}
</span>
</div>
<a-form-model-item class="item-model" prop="enterpriseStandardCode">
<a-form-model-item class="item-model" prop="enStandardCode">
<j-dict-select-tag class="box-input"
v-model="formInline.enterpriseStandardCode"
v-model="formInline.enStandardCode"
:placeholder="$t('pleaseSelect')+$t('workCenter.enterpriseInitChangePlan.enterpriseStandardCode')"
:type="'select'"
:triggerChange="false"
@@ -103,14 +103,14 @@
<!-- 企业名称代号 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text">
<span v-if="rules.enterpriseNameCode[0].required" class="required">*</span>
<span v-if="rules.enNameCode[0].required" class="required">*</span>
<span class="title-text-text" :title="$t('workCenter.enterpriseInitChangePlan.enterpriseNameCode')">
{{ $t('workCenter.enterpriseInitChangePlan.enterpriseNameCode') }}
</span>
</div>
<a-form-model-item class="item-model" prop="enterpriseNameCode">
<a-form-model-item class="item-model" prop="enNameCode">
<j-dict-select-tag class="box-input"
v-model="formInline.enterpriseNameCode"
v-model="formInline.enNameCode"
:placeholder="$t('pleaseSelect')+$t('workCenter.enterpriseInitChangePlan.enterpriseNameCode')"
:type="'select'"
:triggerChange="false"
@@ -139,14 +139,14 @@
<!-- 年代号 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text">
<span v-if="rules.yearNumber[0].required" class="required">*</span>
<span v-if="rules.decadeCode[0].required" class="required">*</span>
<span class="title-text-text" :title="$t('workCenter.enterpriseInitChangePlan.yearNumber')">
{{ $t('workCenter.enterpriseInitChangePlan.yearNumber') }}
</span>
</div>
<a-form-model-item class="item-model" prop="yearNumber">
<a-form-model-item class="item-model" prop="decadeCode">
<j-date show-type="year"
v-model="formInline.yearNumber"
v-model="formInline.decadeCode"
:default-value="yearNumberDefaultValue"
date-format="YYYY"
:disabled="disabled"
@@ -155,65 +155,65 @@
</div>
</template>
<!-- 标准立项-修订 -->
<template v-else-if="formInline.itemCategory && formInline.itemCategory === 2">
<!-- 企标编号 -->
<template v-else-if="formInline.projectType && formInline.projectType === 2">
<!-- 企标编号 原企标编号 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text">
<span class="title-text-text" :title="$t('workCenter.enterpriseInitChangePlan.enterpriseStandardNum')">
{{ $t('workCenter.enterpriseInitChangePlan.enterpriseStandardNum') }}
</span>
</div>
<a-form-model-item class="item-model" prop="enterpriseStandardNum">
<a-form-model-item class="item-model" prop="originEnStandardNo">
<standard-selection :source="StandardSource.ENTERPRISE.value"
:disabledSourceSearch="true"
type="radio"
:disabled="disabled"
v-model="formInline.enterpriseStandardNum"
v-model="formInline.originEnStandardNo"
@nameChange="nameChange"/>
</a-form-model-item>
</div>
<!-- 企标名称 -->
<!-- 企标编号 根据选的企标编号的那三个代号生成新的编号 -->
<!--<div class="box-title-text form-flex-item-half">-->
<!-- <div class="title-text">-->
<!-- <span class="title-text-text" :title="$t('workCenter.enterpriseInitChangePlan.newEnterpriseStandardNum')">-->
<!-- {{ $t('workCenter.enterpriseInitChangePlan.newEnterpriseStandardNum') }}-->
<!-- </span>-->
<!-- </div>-->
<!-- <a-form-model-item class="item-model" prop="newEnStandardNo">-->
<!-- <a-input class="box-input"-->
<!-- v-model="formInline.newEnStandardNo"-->
<!-- :maxLength="50"-->
<!-- disabled-->
<!-- :placeholder="$t('pleaseEnter')+$t('workCenter.enterpriseInitChangePlan.newEnterpriseStandardNum')" />-->
<!-- </a-form-model-item>-->
<!--</div>-->
<!-- 企标名称 原企标名称 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text">
<span v-if="rules.enterpriseStandardName[0].required" class="required">*</span>
<span v-if="rules.originEnStandardName[0].required" class="required">*</span>
<span class="title-text-text" :title="$t('workCenter.enterpriseInitChangePlan.enterpriseStandardName')">
{{ $t('workCenter.enterpriseInitChangePlan.enterpriseStandardName') }}
</span>
</div>
<a-form-model-item class="item-model" prop="enterpriseStandardName">
<a-form-model-item class="item-model" prop="originEnStandardName">
<a-input class="box-input"
v-model="formInline.enterpriseStandardName"
v-model="formInline.originEnStandardName"
:maxLength="50"
disabled
:placeholder="$t('pleaseEnter')+$t('workCenter.enterpriseInitChangePlan.enterpriseStandardName')" />
</a-form-model-item>
</div>
<!-- 新企标编号 根据选的企标编号的那三个代号生成新的编号 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text">
<span class="title-text-text" :title="$t('workCenter.enterpriseInitChangePlan.newEnterpriseStandardNum')">
{{ $t('workCenter.enterpriseInitChangePlan.newEnterpriseStandardNum') }}
</span>
</div>
<a-form-model-item class="item-model" prop="newEnterpriseStandardNum">
<a-input class="box-input"
v-model="formInline.newEnterpriseStandardNum"
:maxLength="50"
disabled
:placeholder="$t('pleaseEnter')+$t('workCenter.enterpriseInitChangePlan.newEnterpriseStandardNum')" />
</a-form-model-item>
</div>
<!-- 新企标名称 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text">
<span v-if="rules.newEnterpriseStandardName[0].required" class="required">*</span>
<span v-if="rules.newEnStandardName[0].required" class="required">*</span>
<span class="title-text-text" :title="$t('workCenter.enterpriseInitChangePlan.newEnterpriseStandardName')">
{{ $t('workCenter.enterpriseInitChangePlan.newEnterpriseStandardName') }}
</span>
</div>
<a-form-model-item class="item-model" prop="newEnterpriseStandardName">
<a-form-model-item class="item-model" prop="newEnStandardName">
<a-input class="box-input"
v-model="formInline.newEnterpriseStandardName"
v-model="formInline.newEnStandardName"
:maxLength="50"
:disabled="disabled"
:placeholder="$t('pleaseEnter')+$t('workCenter.enterpriseInitChangePlan.newEnterpriseStandardName')" />
@@ -227,9 +227,9 @@
{{ $t('workCenter.enterpriseInitChangePlan.standardEnglishName') }}
</span>
</div>
<a-form-model-item class="item-model" prop="standardEnglishName">
<a-form-model-item class="item-model" prop="enStandardEnglishName">
<a-input class="box-input"
v-model="formInline.standardEnglishName"
v-model="formInline.enStandardEnglishName"
:maxLength="50"
:disabled="disabled"
:placeholder="$t('pleaseEnter')+$t('workCenter.enterpriseInitChangePlan.standardEnglishName')" />
@@ -238,14 +238,14 @@
<!-- 标准体系 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text">
<span v-if="rules.standardSystem[0].required" class="required">*</span>
<span v-if="rules.enStandardSystem[0].required" class="required">*</span>
<span class="title-text-text" :title="$t('workCenter.enterpriseInitChangePlan.standardSystem')">
{{ $t('workCenter.enterpriseInitChangePlan.standardSystem') }}
</span>
</div>
<a-form-model-item class="item-model" prop="standardSystem">
<a-form-model-item class="item-model" prop="enStandardSystem">
<a-tree-select
v-model="formInline.standardSystem"
v-model="formInline.enStandardSystem"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
style="width: 100%"
:tree-data="standardSystemOptions"
@@ -277,14 +277,14 @@
<!-- 标准等级分类 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text">
<span v-if="rules.standardGradeClassification[0].required" class="required">*</span>
<span v-if="rules.enStandardClassification[0].required" class="required">*</span>
<span class="title-text-text" :title="$t('workCenter.enterpriseInitChangePlan.standardGradeClassification')">
{{ $t('workCenter.enterpriseInitChangePlan.standardGradeClassification') }}
</span>
</div>
<a-form-model-item class="item-model" prop="standardGradeClassification">
<a-form-model-item class="item-model" prop="enStandardClassification">
<j-dict-select-tag class="box-input"
v-model="formInline.standardGradeClassification"
v-model="formInline.enStandardClassification"
:placeholder="$t('pleaseSelect')+$t('workCenter.enterpriseInitChangePlan.standardGradeClassification')"
:type="'select'"
:triggerChange="false"
@@ -299,11 +299,11 @@
{{ $t('workCenter.enterpriseInitChangePlan.compilationIllustration') }}
</span>
</div>
<a-form-model-item class="item-model" prop="compilationIllustration">
<a-button type="primary" class="button-text" @click="clickButtonToUpload('compilationIllustration')">
<a-form-model-item class="item-model" prop="compilationDescription">
<a-button type="primary" class="button-text" @click="clickButtonToUpload('compilationDescription')">
{{
(formInline.compilationIllustration === 'null' || formInline.compilationIllustration === ''
|| formInline.compilationIllustration === null || formInline.compilationIllustration === undefined)
(formInline.compilationDescription === 'null' || formInline.compilationDescription === ''
|| formInline.compilationDescription === null || formInline.compilationDescription === undefined)
? $t('uploadFile.clickUpload')
: $t('uploadFile.viewUploadedFiles')
}}
@@ -314,14 +314,14 @@
<!-- 草稿计划完成日期 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text title-text-long">
<span v-if="rules.draftPlanFinishDate[0].required" class="required">*</span>
<span v-if="rules.draftPlannedCompleteDate[0].required" class="required">*</span>
<span class="title-text-text" :title="$t('workCenter.enterpriseInitChangePlan.draftPlanFinishDate')">
{{ $t('workCenter.enterpriseInitChangePlan.draftPlanFinishDate') }}
</span>
</div>
<a-form-model-item class="item-model" prop="draftPlanFinishDate">
<a-form-model-item class="item-model" prop="draftPlannedCompleteDate">
<a-date-picker
v-model="formInline.draftPlanFinishDate"
v-model="formInline.draftPlannedCompleteDate"
:showTime="false"
:disabled="editRole === 'contact' ? draftPlanFinishDateDisabled : (disabled || draftPlanFinishDateDisabled)"
value-format="YYYY-MM-DD">
@@ -331,14 +331,14 @@
<!-- 征求意见稿计划完成日期 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text title-text-long">
<span v-if="rules.exposureDraftPlanFinishDate[0].required" class="required">*</span>
<span v-if="rules.solicitationDraftPlanCompleteDate[0].required" class="required">*</span>
<span class="title-text-text" :title="$t('workCenter.enterpriseInitChangePlan.exposureDraftPlanFinishDate')">
{{ $t('workCenter.enterpriseInitChangePlan.exposureDraftPlanFinishDate') }}
</span>
</div>
<a-form-model-item class="item-model" prop="exposureDraftPlanFinishDate">
<a-form-model-item class="item-model" prop="solicitationDraftPlanCompleteDate">
<a-date-picker
v-model="formInline.exposureDraftPlanFinishDate"
v-model="formInline.solicitationDraftPlanCompleteDate"
:showTime="false"
:disabled="editRole === 'contact' ? exposureDraftPlanFinishDateDisabled : (disabled || exposureDraftPlanFinishDateDisabled)"
value-format="YYYY-MM-DD">
@@ -348,14 +348,14 @@
<!-- 计划报批日期 -->
<div class="box-title-text form-flex-item-half">
<div class="title-text title-text-long">
<span v-if="rules.planSubmissionDate[0].required" class="required">*</span>
<span v-if="rules.planApprovalDate[0].required" class="required">*</span>
<span class="title-text-text" :title="$t('workCenter.enterpriseInitChangePlan.planSubmissionDate')">
{{ $t('workCenter.enterpriseInitChangePlan.planSubmissionDate') }}
</span>
</div>
<a-form-model-item class="item-model" prop="planSubmissionDate">
<a-form-model-item class="item-model" prop="planApprovalDate">
<a-date-picker
v-model="formInline.planSubmissionDate"
v-model="formInline.planApprovalDate"
:showTime="false"
:disabled="editRole === 'contact' ? planSubmissionDateDisabled : (disabled || planSubmissionDateDisabled)"
value-format="YYYY-MM-DD">
@@ -375,8 +375,8 @@
{{ $t('workCenter.enterpriseInitChangePlan.partName') }}
</span>
</div>
<a-form-model-item class="item-model" prop="partName">
<a-tree-select v-model="formInline.partName"
<a-form-model-item class="item-model" prop="componentName">
<a-tree-select v-model="formInline.componentName"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
style="width: 100%"
:tree-data="partNameOptions"
@@ -393,8 +393,8 @@
{{ $t('workCenter.enterpriseInitChangePlan.authorizationDepart') }}
</span>
</div>
<a-form-model-item class="item-model" prop="authorizationDepart">
<j-select-depart v-model="formInline.authorizationDepart"
<a-form-model-item class="item-model" prop="authDept">
<j-select-depart v-model="formInline.authDept"
:disabled="disabled"
:backDepart="true" />
</a-form-model-item>
@@ -407,12 +407,12 @@
{{ $t('workCenter.enterpriseInitChangePlan.principalDrafter') }}
</span>
</div>
<a-form-model-item class="item-model" prop="principalDrafter">
<a-form-model-item class="item-model" prop="mainDraftingUser">
<user-selection :placeholder="$t('pleaseSelect')+$t('workCenter.enterpriseInitChangePlan.principalDrafter')"
v-model="formInline.principalDrafter"
filedName="principalDrafter"
v-model="formInline.mainDraftingUser"
filedName="mainDraftingUser"
@nameChange="userSelectNameChange"
:nameStr="formInline.principalDrafter_dictText"
:nameStr="formInline.mainDraftingUser_dictText"
:disabled="disabled"
type="radio" />
</a-form-model-item>
@@ -425,8 +425,8 @@
{{ $t('workCenter.enterpriseInitChangePlan.mainDraftUnit') }}
</span>
</div>
<a-form-model-item class="item-model" prop="mainDraftUnit">
<j-select-depart v-model="formInline.mainDraftUnit"
<a-form-model-item class="item-model" prop="mainDraftingUnit">
<j-select-depart v-model="formInline.mainDraftingUnit"
:disabled="disabled"
:backDepart="true" />
</a-form-model-item>
@@ -439,12 +439,12 @@
{{ $t('workCenter.enterpriseInitChangePlan.headOfMainDraftingUnit') }}
</span>
</div>
<a-form-model-item class="item-model" prop="headOfMainDraftingUnit">
<a-form-model-item class="item-model" prop="mainDraftingUnitResponsiblePerson">
<user-selection :placeholder="$t('pleaseSelect')+$t('workCenter.enterpriseInitChangePlan.headOfMainDraftingUnit')"
v-model="formInline.headOfMainDraftingUnit"
filedName="headOfMainDraftingUnit"
v-model="formInline.mainDraftingUnitResponsiblePerson"
filedName="mainDraftingUnitResponsiblePerson"
@nameChange="userSelectNameChange"
:nameStr="formInline.headOfMainDraftingUnit_dictText"
:nameStr="formInline.mainDraftingUnitResponsiblePerson_dictText"
:disabled="disabled"
type="radio" />
</a-form-model-item>
@@ -457,12 +457,12 @@
{{ $t('workCenter.enterpriseInitChangePlan.standardPusher') }}
</span>
</div>
<a-form-model-item class="item-model" prop="standardPusher">
<a-form-model-item class="item-model" prop="standardPromoter">
<user-selection :placeholder="$t('pleaseSelect')+$t('workCenter.enterpriseInitChangePlan.standardPusher')"
v-model="formInline.standardPusher"
filedName="standardPusher"
v-model="formInline.standardPromoter"
filedName="standardPromoter"
@nameChange="userSelectNameChange"
:nameStr="formInline.standardPusher_dictText"
:nameStr="formInline.standardPromoter_dictText"
:disabled="disabled"
type="radio" />
</a-form-model-item>
@@ -538,15 +538,15 @@ export default {
}
],
// 项目类别
itemCategory: [
projectType: [
{
required: false,
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.itemCategory') + this.$t('cannotEmpty'),
trigger: 'change'
}
],
// 企标编号
enterpriseStandardNum: [
// 企标编号-新企标编号(制定-企标编号,修订-新企标编号)
newEnStandardNo: [
{
required: false,
message: this.$t('workCenter.enterpriseInitChangePlan.enterpriseStandardNum') + this.$t('cannotEmpty'),
@@ -554,7 +554,7 @@ export default {
}
],
// 企业标准代号
enterpriseStandardCode: [
enStandardCode: [
{
required: false,
message: this.$t('workCenter.enterpriseInitChangePlan.enterpriseStandardCode') + this.$t('cannotEmpty'),
@@ -569,16 +569,8 @@ export default {
trigger: 'change'
}
],
// 企标名称
enterpriseStandardName: [
{
required: false,
message: this.$t('workCenter.enterpriseInitChangePlan.enterpriseStandardName') + this.$t('cannotEmpty'),
trigger: 'blur'
}
],
// 企业名称代号
enterpriseNameCode: [
enNameCode: [
{
required: false,
message: this.$t('workCenter.enterpriseInitChangePlan.enterpriseNameCode') + this.$t('cannotEmpty'),
@@ -586,21 +578,29 @@ export default {
}
],
// 年代号
yearNumber: [
decadeCode: [
{
required: false,
message: this.$t('workCenter.enterpriseInitChangePlan.yearNumber') + this.$t('cannotEmpty'),
trigger: 'change'
}
],
// 企标名称
newEnterpriseStandardName: [
// 企标名称-新企标名称(制定-企标名称,修订-新企标名称)
newEnStandardName: [
{
required: false,
message: this.$t('workCenter.enterpriseInitChangePlan.newEnterpriseStandardName') + this.$t('cannotEmpty'),
trigger: 'blur'
}
],
// 原企标名称
originEnStandardName: [
{
required: false,
message: this.$t('workCenter.enterpriseInitChangePlan.enterpriseStandardName') + this.$t('cannotEmpty'),
trigger: 'blur'
}
],
// 标准类型
standardType: [
{
@@ -610,7 +610,7 @@ export default {
}
],
// 标准体系
standardSystem: [
enStandardSystem: [
{
required: false,
message: this.$t('workCenter.enterpriseInitChangePlan.standardSystem') + this.$t('cannotEmpty'),
@@ -618,7 +618,7 @@ export default {
}
],
// 标准等级分类
standardGradeClassification: [
enStandardClassification: [
{
required: false,
message: this.$t('workCenter.enterpriseInitChangePlan.standardGradeClassification') + this.$t('cannotEmpty'),
@@ -626,7 +626,7 @@ export default {
}
],
// 草稿计划完成日期
draftPlanFinishDate: [
draftPlannedCompleteDate: [
{
required: false,
message: this.$t('workCenter.enterpriseInitChangePlan.draftPlanFinishDate') + this.$t('cannotEmpty'),
@@ -634,7 +634,7 @@ export default {
}
],
// 征求意见稿计划完成日期
exposureDraftPlanFinishDate: [
solicitationDraftPlanCompleteDate: [
{
required: false,
message: this.$t('workCenter.enterpriseInitChangePlan.exposureDraftPlanFinishDate') + this.$t('cannotEmpty'),
@@ -642,7 +642,7 @@ export default {
}
],
// 计划报批日期
planSubmissionDate: [
planApprovalDate: [
{
required: false,
message: this.$t('workCenter.enterpriseInitChangePlan.planSubmissionDate') + this.$t('cannotEmpty'),
@@ -650,7 +650,7 @@ export default {
}
],
// 零部件名称
partName: [
componentName: [
{
required: false,
message: this.$t('workCenter.enterpriseInitChangePlan.partName') + this.$t('cannotEmpty'),
@@ -658,7 +658,7 @@ export default {
}
],
// 授权部门
authorizationDepart: [
authDept: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.authorizationDepart') + this.$t('cannotEmpty'),
@@ -666,7 +666,7 @@ export default {
}
],
// 主起草人
principalDrafter: [
mainDraftingUser: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.principalDrafter') + this.$t('cannotEmpty'),
@@ -674,7 +674,7 @@ export default {
}
],
// 主起草单位
mainDraftUnit: [
mainDraftingUnit: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.mainDraftUnit') + this.$t('cannotEmpty'),
@@ -682,7 +682,7 @@ export default {
}
],
// 起草单位负责人
headOfMainDraftingUnit: [
mainDraftingUnitResponsiblePerson: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.headOfMainDraftingUnit') + this.$t('cannotEmpty'),
@@ -690,7 +690,7 @@ export default {
}
],
// 标准推进人
standardPusher: [
standardPromoter: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.standardPusher') + this.$t('cannotEmpty'),
@@ -721,13 +721,13 @@ export default {
const userInfo = Vue.ls.get(USER_INFO)
const formInline = {}
// 初始化主起草人信息
formInline.principalDrafter = userInfo.id
formInline.principalDrafter_dictText = userInfo.realname
formInline.mainDraftingUser = userInfo.id
formInline.mainDraftingUser_dictText = userInfo.realname
// 初始化主起草单位信息
formInline.mainDraftUnit = userInfo.departIds
formInline.mainDraftingUnit = userInfo.departIds
// 初始化起草单位负责人 todo: 看怎么获取当前登录人的上级
// 初始化年代号
formInline.yearNumber = new Date().getFullYear() + ''
formInline.decadeCode = new Date().getFullYear() + ''
this.edit(formInline)
},
edit (record) {
@@ -738,17 +738,17 @@ export default {
if (this.editRole === 'drafter') {
// 是主起草人的编辑
// 草稿计划完成日期的处理
if (this.formInline.draftPlanFinishDate) {
if (this.formInline.draftPlannedCompleteDate) {
// 草稿计划完成日期已经填写了, 主起草人不能修改
this.draftPlanFinishDateDisabled = true
}
// 征求意见稿计划完成日期
if (this.formInline.exposureDraftPlanFinishDate) {
if (this.formInline.solicitationDraftPlanCompleteDate) {
// 征求意见稿计划完成日期已经填写了, 主起草人不能修改
this.exposureDraftPlanFinishDateDisabled = true
}
// 计划报批日期
if (this.formInline.planSubmissionDate) {
if (this.formInline.planApprovalDate) {
// 计划报批日期已经填写了, 主起草人不能修改
this.planSubmissionDateDisabled = true
}
@@ -756,25 +756,25 @@ export default {
// 是联络人的编辑,只能编辑3个日期,如果标准化填过了不能修改,未填的话必填
this.disabled = true
// 草稿计划完成日期的处理
if (!this.formInline.draftPlanFinishDate) {
if (!this.formInline.draftPlannedCompleteDate) {
// 草稿计划完成日期没有填写, 联络人必填
this.rules.draftPlanFinishDate[0].required = true
this.rules.draftPlannedCompleteDate[0].required = true
} else {
// 填写了,不能修改
this.draftPlanFinishDateDisabled = true
}
// 征求意见稿计划完成日期
if (!this.formInline.exposureDraftPlanFinishDate) {
if (!this.formInline.solicitationDraftPlanCompleteDate) {
// 征求意见稿计划完成日期没有填写, 联络人必填
this.rules.exposureDraftPlanFinishDate[0].required = true
this.rules.solicitationDraftPlanCompleteDate[0].required = true
} else {
// 填写了,不能修改
this.exposureDraftPlanFinishDateDisabled = true
}
// 计划报批日期
if (!this.formInline.planSubmissionDate) {
if (!this.formInline.planApprovalDate) {
// 计划报批日期没有填写, 联络人必填
this.rules.planSubmissionDate[0].required = true
this.rules.planApprovalDate[0].required = true
} else {
// 填写了,不能修改
this.planSubmissionDateDisabled = true
@@ -805,10 +805,10 @@ export default {
},
// 标准选择组件返回标准名称的回调
nameChange (value) {
this.formInline.enterpriseStandardName = value
this.formInline.originEnStandardName = value
},
// 项目类别改变
itemCategoryChange (value) {
projectTypeChange (value) {
if (value === this.ProjectType.ENACT.value) {
// 是制定
this.formInline.decadeCode = new Date().getFullYear() + ''
@@ -24,11 +24,20 @@
:loading="loading"
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}">
<!-- 企标编号/企标名称 -->
<template v-slot:toDetail="{text, record}">
<!-- 企标编号/企标名称 -->
<template v-slot:toDetailOld="{text, record}">
<a-tooltip overlay-class-name="tooltip-style">
<template slot="title">{{ text || text === 0 ? text : global.emptyLine }}</template>
<a v-if="text" class="link-a" @click="handleGoDetail(record)">{{ text }}</a>
<a v-if="text" class="link-a" @click="handleGoDetailOld(record)">{{ text }}</a>
<div v-else class="table-text">{{ global.emptyLine }}</div>
</a-tooltip>
</template>
<!-- 新企标编号/企标名称 -->
<template v-slot:toDetailNew="{text, record}">
<a-tooltip overlay-class-name="tooltip-style">
<template slot="title">{{ text || text === 0 ? text : global.emptyLine }}</template>
<a v-if="text" class="link-a" @click="handleGoDetailNew(record)">{{ text }}</a>
<div v-else class="table-text">{{ global.emptyLine }}</div>
</a-tooltip>
</template>
@@ -75,7 +84,7 @@ export default {
title: this.$t('enterpriseStandardLibrary.plan.revisionType'),
align: 'center',
width: 180,
dataIndex: 'applicationCategory_dictText',
dataIndex: 'projectType_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 原企标编号
@@ -110,49 +119,49 @@ export default {
title: this.$t('enterpriseStandardLibrary.plan.authDepartment'),
align: 'center',
width: 180,
dataIndex: 'authDeparts',
dataIndex: 'authDept_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 企业标准代号
title: this.$t('enterpriseStandardLibrary.plan.enterpriseStandardCode'),
align: 'center',
width: 180,
dataIndex: 'enStandardCode',
dataIndex: 'enStandardCode_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 配合单位
title: this.$t('enterpriseStandardLibrary.plan.suitUnit'),
align: 'center',
width: 180,
dataIndex: 'cooperateDeparts',
dataIndex: 'cooperationUnit_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 主起草人
title: this.$t('enterpriseStandardLibrary.plan.principalDrafter'),
align: 'center',
width: 180,
dataIndex: 'mainDraftingUser',
dataIndex: 'mainDraftingUser_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 主起草单位
title: this.$t('enterpriseStandardLibrary.plan.mainDraftingUnit'),
align: 'center',
width: 180,
dataIndex: 'mainDraftingUnit',
dataIndex: 'mainDraftingUnit_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 主起草单位负责人
title: this.$t('enterpriseStandardLibrary.plan.headOfMainDraftingUnit'),
align: 'center',
width: 180,
dataIndex: 'mainDraftingUnitResponsiblePerson',
dataIndex: 'mainDraftingUnitResponsiblePerson_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 标准推进人
title: this.$t('enterpriseStandardLibrary.plan.standardPusher'),
align: 'center',
width: 180,
dataIndex: 'standardPromoter',
dataIndex: 'standardPromoter_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 草稿计划完成日期
@@ -160,21 +169,21 @@ export default {
align: 'center',
width: 180,
dataIndex: 'draftPlannedCompleteDate',
scopedSlots: { customRender: 'specialDate' }
scopedSlots: { customRender: 'text' }
},
{ // 征求意见稿计划完成日期
title: this.$t('enterpriseStandardLibrary.plan.exposureDraftPlanFinishDate'),
align: 'center',
width: 200,
dataIndex: 'solicitationDraftPlanCompleteDate',
scopedSlots: { customRender: 'specialDate' }
scopedSlots: { customRender: 'text' }
},
{ // 计划报批日期
title: this.$t('enterpriseStandardLibrary.plan.planSubmissionDate'),
align: 'center',
width: 180,
dataIndex: 'planApprovalDate',
scopedSlots: { customRender: 'specialDate' }
scopedSlots: { customRender: 'text' }
},
{ // 变更状态
title: this.$t('enterpriseStandardLibrary.plan.changeState'),
@@ -187,9 +196,9 @@ export default {
title: this.$t('workCenter.revisionPlanActivelyReport.approver'),
align: 'center',
width: 300,
dataIndex: 'approver',
dataIndex: 'approvalUser',
customRender: (value, row, index) => {
return <user-select-by-contact v-model={this.dataSource[index].approver}
return <user-select-by-contact v-model={this.dataSource[index].approvalUser}
disabled={this.disabled} type={'radio'} placeholder={this.$t('pleaseSelect')} />
}
}
@@ -203,6 +212,24 @@ export default {
}
},
methods: {
// 企标编号,企标名称跳转详情,原企标
handleGoDetailOld (record) {
this.$openPageNewSheet({
path: '/enterpriseStandardLibrary/enterpriseStandardDetail',
query: {
standardNumber: record.originEnStandardNo
}
})
},
// 企标编号,企标名称跳转详情,新企标
handleGoDetailNew (record) {
this.$openPageNewSheet({
path: '/enterpriseStandardLibrary/enterpriseStandardDetail',
query: {
standardNumber: record.newEnStandardNo
}
})
},
// 表格选中
onSelectChange (selectedRowKeys, selectionRows) {
this.selectedRowKeys = selectedRowKeys
@@ -11,7 +11,7 @@
<a-button icon="upload" type="primary" ghost>{{ $t('import') }}</a-button>
</a-upload>
<!-- 模板下载 -->
<a-button icon="download" type="primary" ghost @click="downTemplate($t('workCenter.revisionPlanActivelyReport.templateExport'))">
<a-button icon="download" type="primary" ghost @click="downTemplate($t('workCenter.revisionPlanActivelyReport.standardizationInitTemplate'))">
{{ $t('templateDownload') }}
</a-button>
<!-- 批量删除 -->
@@ -36,15 +36,23 @@
:loading="loading"
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}">
<!-- 企标编号/企标名称 -->
<template v-slot:toDetail="{text, record}">
<!-- 企标编号/企标名称 -->
<template v-slot:toDetailOld="{text, record}">
<a-tooltip overlay-class-name="tooltip-style">
<template slot="title">{{ text || text === 0 ? text : global.emptyLine }}</template>
<a v-if="text" class="link-a" @click="handleGoDetail(record)">{{ text }}</a>
<a v-if="text" class="link-a" @click="handleGoDetailOld(record)">{{ text }}</a>
<div v-else class="table-text">{{ global.emptyLine }}</div>
</a-tooltip>
</template>
<!-- 新企标编号/企标名称 -->
<template v-slot:toDetailNew="{text, record}">
<a-tooltip overlay-class-name="tooltip-style">
<template slot="title">{{ text || text === 0 ? text : global.emptyLine }}</template>
<a v-if="text" class="link-a" @click="handleGoDetailNew(record)">{{ text }}</a>
<div v-else class="table-text">{{ global.emptyLine }}</div>
</a-tooltip>
</template>
<!-- 操作栏 -->
<div slot="action" slot-scope="{record, index}" class="action-span-cell">
<a @click="handleEdit(record, index)" class="table-ope-btn">{{ $t('edit') }}</a>
@@ -118,7 +126,7 @@ export default {
title: this.$t('enterpriseStandardLibrary.plan.revisionType'),
align: 'center',
width: 180,
dataIndex: 'applicationCategory_dictText',
dataIndex: 'projectType_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 原企标编号
@@ -153,49 +161,49 @@ export default {
title: this.$t('enterpriseStandardLibrary.plan.authDepartment'),
align: 'center',
width: 180,
dataIndex: 'authDeparts',
dataIndex: 'authDept_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 企业标准代号
title: this.$t('enterpriseStandardLibrary.plan.enterpriseStandardCode'),
align: 'center',
width: 180,
dataIndex: 'enStandardCode',
dataIndex: 'enStandardCode_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 配合单位
title: this.$t('enterpriseStandardLibrary.plan.suitUnit'),
align: 'center',
width: 180,
dataIndex: 'cooperateDeparts',
dataIndex: 'cooperationUnit_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 主起草人
title: this.$t('enterpriseStandardLibrary.plan.principalDrafter'),
align: 'center',
width: 180,
dataIndex: 'mainDraftingUser',
dataIndex: 'mainDraftingUser_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 主起草单位
title: this.$t('enterpriseStandardLibrary.plan.mainDraftingUnit'),
align: 'center',
width: 180,
dataIndex: 'mainDraftingUnit',
dataIndex: 'mainDraftingUnit_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 主起草单位负责人
title: this.$t('enterpriseStandardLibrary.plan.headOfMainDraftingUnit'),
align: 'center',
width: 180,
dataIndex: 'mainDraftingUnitResponsiblePerson',
dataIndex: 'mainDraftingUnitResponsiblePerson_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 标准推进人
title: this.$t('enterpriseStandardLibrary.plan.standardPusher'),
align: 'center',
width: 180,
dataIndex: 'standardPromoter',
dataIndex: 'standardPromoter_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 草稿计划完成日期
@@ -203,21 +211,21 @@ export default {
align: 'center',
width: 180,
dataIndex: 'draftPlannedCompleteDate',
scopedSlots: { customRender: 'specialDate' }
scopedSlots: { customRender: 'text' }
},
{ // 征求意见稿计划完成日期
title: this.$t('enterpriseStandardLibrary.plan.exposureDraftPlanFinishDate'),
align: 'center',
width: 200,
dataIndex: 'solicitationDraftPlanCompleteDate',
scopedSlots: { customRender: 'specialDate' }
scopedSlots: { customRender: 'text' }
},
{ // 计划报批日期
title: this.$t('enterpriseStandardLibrary.plan.planSubmissionDate'),
align: 'center',
width: 180,
dataIndex: 'planApprovalDate',
scopedSlots: { customRender: 'specialDate' }
scopedSlots: { customRender: 'text' }
},
{ // 变更状态
title: this.$t('enterpriseStandardLibrary.plan.changeState'),
@@ -230,14 +238,14 @@ export default {
title: this.$t('workCenter.revisionPlanActivelyReport.contactPerson'),
align: 'center',
width: 300,
dataIndex: 'contactPerson',
dataIndex: 'contactUser',
customRender: (value, row, index) => {
if (this.isRejectedTodo) {
// 是被驳回的待办
return this.dataSource[index].contactPerson_dictText
return this.dataSource[index].contactUser_dictText
} else {
// 不是被驳回的待办,可以设置联络人
return <user-select-by-contact v-model={this.dataSource[index].contactPerson}
return <user-select-by-contact v-model={this.dataSource[index].contactUser}
disabled={this.disabled} type={'radio'} placeholder={this.$t('pleaseSelect')} />
}
}
@@ -255,7 +263,8 @@ export default {
selectionRows: [],
url: {
list: '',
downTemplateUrl: ''
downTemplateUrl: '/process/es/annualInit/templateDownload',
importExcelUrl: '/process/es/annualInit/importExcel'
},
modalType: '', // 是在新增还是在编辑,编辑的时候放正在编辑的下标
isRejectedTodo: false // 是否是被驳回的待办,被驳回的待办不可设置联络人
@@ -269,12 +278,21 @@ export default {
// this.isRejectedTodo = false
},
methods: {
// 企标编号,企标名称跳转详情
handleGoDetail (record) {
// 企标编号,企标名称跳转详情,原企标
handleGoDetailOld (record) {
this.$openPageNewSheet({
path: '/enterpriseStandardLibrary/enterpriseStandardDetail',
query: {
standardNumber: record.standardNo
standardNumber: record.originEnStandardNo
}
})
},
// 企标编号,企标名称跳转详情,新企标
handleGoDetailNew (record) {
this.$openPageNewSheet({
path: '/enterpriseStandardLibrary/enterpriseStandardDetail',
query: {
standardNumber: record.newEnStandardNo
}
})
},
@@ -342,7 +360,8 @@ export default {
} else {
this.$message.success(info.file.response.message || `${info.file.name} 文件上传成功`)
}
this.loadData()
// 推入表格中
this.dataSource = this.dataSource.concat(info.file.response.result)
} else {
this.$message.error(`${info.file.name} ${info.file.response.message}.`)
}
@@ -20,11 +20,20 @@
:loading="loading"
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}">
<!-- 企标编号/企标名称 -->
<template v-slot:toDetail="{text, record}">
<!-- 企标编号/企标名称 -->
<template v-slot:toDetailOld="{text, record}">
<a-tooltip overlay-class-name="tooltip-style">
<template slot="title">{{ text || text === 0 ? text : global.emptyLine }}</template>
<a v-if="text" class="link-a" @click="handleGoDetail(record)">{{ text }}</a>
<a v-if="text" class="link-a" @click="handleGoDetailOld(record)">{{ text }}</a>
<div v-else class="table-text">{{ global.emptyLine }}</div>
</a-tooltip>
</template>
<!-- 新企标编号/企标名称 -->
<template v-slot:toDetailNew="{text, record}">
<a-tooltip overlay-class-name="tooltip-style">
<template slot="title">{{ text || text === 0 ? text : global.emptyLine }}</template>
<a v-if="text" class="link-a" @click="handleGoDetailNew(record)">{{ text }}</a>
<div v-else class="table-text">{{ global.emptyLine }}</div>
</a-tooltip>
</template>
@@ -71,7 +80,7 @@ export default {
title: this.$t('enterpriseStandardLibrary.plan.revisionType'),
align: 'center',
width: 180,
dataIndex: 'applicationCategory_dictText',
dataIndex: 'projectType_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 原企标编号
@@ -106,49 +115,49 @@ export default {
title: this.$t('enterpriseStandardLibrary.plan.authDepartment'),
align: 'center',
width: 180,
dataIndex: 'authDeparts',
dataIndex: 'authDept_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 企业标准代号
title: this.$t('enterpriseStandardLibrary.plan.enterpriseStandardCode'),
align: 'center',
width: 180,
dataIndex: 'enStandardCode',
dataIndex: 'enStandardCode_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 配合单位
title: this.$t('enterpriseStandardLibrary.plan.suitUnit'),
align: 'center',
width: 180,
dataIndex: 'cooperateDeparts',
dataIndex: 'cooperationUnit_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 主起草人
title: this.$t('enterpriseStandardLibrary.plan.principalDrafter'),
align: 'center',
width: 180,
dataIndex: 'mainDraftingUser',
dataIndex: 'mainDraftingUser_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 主起草单位
title: this.$t('enterpriseStandardLibrary.plan.mainDraftingUnit'),
align: 'center',
width: 180,
dataIndex: 'mainDraftingUnit',
dataIndex: 'mainDraftingUnit_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 主起草单位负责人
title: this.$t('enterpriseStandardLibrary.plan.headOfMainDraftingUnit'),
align: 'center',
width: 180,
dataIndex: 'mainDraftingUnitResponsiblePerson',
dataIndex: 'mainDraftingUnitResponsiblePerson_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 标准推进人
title: this.$t('enterpriseStandardLibrary.plan.standardPusher'),
align: 'center',
width: 180,
dataIndex: 'standardPromoter',
dataIndex: 'standardPromoter_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 草稿计划完成日期
@@ -156,21 +165,21 @@ export default {
align: 'center',
width: 180,
dataIndex: 'draftPlannedCompleteDate',
scopedSlots: { customRender: 'specialDate' }
scopedSlots: { customRender: 'text' }
},
{ // 征求意见稿计划完成日期
title: this.$t('enterpriseStandardLibrary.plan.exposureDraftPlanFinishDate'),
align: 'center',
width: 200,
dataIndex: 'solicitationDraftPlanCompleteDate',
scopedSlots: { customRender: 'specialDate' }
scopedSlots: { customRender: 'text' }
},
{ // 计划报批日期
title: this.$t('enterpriseStandardLibrary.plan.planSubmissionDate'),
align: 'center',
width: 180,
dataIndex: 'planApprovalDate',
scopedSlots: { customRender: 'specialDate' }
scopedSlots: { customRender: 'text' }
},
{ // 变更状态
title: this.$t('enterpriseStandardLibrary.plan.changeState'),
@@ -199,6 +208,24 @@ export default {
}
},
methods: {
// 企标编号,企标名称跳转详情,原企标
handleGoDetailOld (record) {
this.$openPageNewSheet({
path: '/enterpriseStandardLibrary/enterpriseStandardDetail',
query: {
standardNumber: record.originEnStandardNo
}
})
},
// 企标编号,企标名称跳转详情,新企标
handleGoDetailNew (record) {
this.$openPageNewSheet({
path: '/enterpriseStandardLibrary/enterpriseStandardDetail',
query: {
standardNumber: record.newEnStandardNo
}
})
},
// 表格选中
onSelectChange (selectedRowKeys, selectionRows) {
this.selectedRowKeys = selectedRowKeys
@@ -11,11 +11,20 @@
:pagination="false"
:loading="loading">
<!-- 企标编号/企标名称 -->
<template v-slot:toDetail="{text, record}">
<!-- 企标编号/企标名称 -->
<template v-slot:toDetailOld="{text, record}">
<a-tooltip overlay-class-name="tooltip-style">
<template slot="title">{{ text || text === 0 ? text : global.emptyLine }}</template>
<a v-if="text" class="link-a" @click="handleGoDetail(record)">{{ text }}</a>
<a v-if="text" class="link-a" @click="handleGoDetailOld(record)">{{ text }}</a>
<div v-else class="table-text">{{ global.emptyLine }}</div>
</a-tooltip>
</template>
<!-- 新企标编号/企标名称 -->
<template v-slot:toDetailNew="{text, record}">
<a-tooltip overlay-class-name="tooltip-style">
<template slot="title">{{ text || text === 0 ? text : global.emptyLine }}</template>
<a v-if="text" class="link-a" @click="handleGoDetailNew(record)">{{ text }}</a>
<div v-else class="table-text">{{ global.emptyLine }}</div>
</a-tooltip>
</template>
@@ -85,7 +94,7 @@ export default {
title: this.$t('enterpriseStandardLibrary.plan.revisionType'),
align: 'center',
width: 180,
dataIndex: 'applicationCategory_dictText',
dataIndex: 'projectType_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 原企标编号
@@ -120,49 +129,49 @@ export default {
title: this.$t('enterpriseStandardLibrary.plan.authDepartment'),
align: 'center',
width: 180,
dataIndex: 'authDeparts',
dataIndex: 'authDept_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 企业标准代号
title: this.$t('enterpriseStandardLibrary.plan.enterpriseStandardCode'),
align: 'center',
width: 180,
dataIndex: 'enStandardCode',
dataIndex: 'enStandardCode_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 配合单位
title: this.$t('enterpriseStandardLibrary.plan.suitUnit'),
align: 'center',
width: 180,
dataIndex: 'cooperateDeparts',
dataIndex: 'cooperationUnit_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 主起草人
title: this.$t('enterpriseStandardLibrary.plan.principalDrafter'),
align: 'center',
width: 180,
dataIndex: 'mainDraftingUser',
dataIndex: 'mainDraftingUser_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 主起草单位
title: this.$t('enterpriseStandardLibrary.plan.mainDraftingUnit'),
align: 'center',
width: 180,
dataIndex: 'mainDraftingUnit',
dataIndex: 'mainDraftingUnit_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 主起草单位负责人
title: this.$t('enterpriseStandardLibrary.plan.headOfMainDraftingUnit'),
align: 'center',
width: 180,
dataIndex: 'mainDraftingUnitResponsiblePerson',
dataIndex: 'mainDraftingUnitResponsiblePerson_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 标准推进人
title: this.$t('enterpriseStandardLibrary.plan.standardPusher'),
align: 'center',
width: 180,
dataIndex: 'standardPromoter',
dataIndex: 'standardPromoter_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 草稿计划完成日期
@@ -170,21 +179,21 @@ export default {
align: 'center',
width: 180,
dataIndex: 'draftPlannedCompleteDate',
scopedSlots: { customRender: 'specialDate' }
scopedSlots: { customRender: 'text' }
},
{ // 征求意见稿计划完成日期
title: this.$t('enterpriseStandardLibrary.plan.exposureDraftPlanFinishDate'),
align: 'center',
width: 200,
dataIndex: 'solicitationDraftPlanCompleteDate',
scopedSlots: { customRender: 'specialDate' }
scopedSlots: { customRender: 'text' }
},
{ // 计划报批日期
title: this.$t('enterpriseStandardLibrary.plan.planSubmissionDate'),
align: 'center',
width: 180,
dataIndex: 'planApprovalDate',
scopedSlots: { customRender: 'specialDate' }
scopedSlots: { customRender: 'text' }
},
{ // 变更状态
title: this.$t('enterpriseStandardLibrary.plan.changeState'),
@@ -219,12 +228,21 @@ export default {
}
},
methods: {
// 企标编号,企标名称跳转详情
handleGoDetail (record) {
// 企标编号,企标名称跳转详情,原企标
handleGoDetailOld (record) {
this.$openPageNewSheet({
path: '/enterpriseStandardLibrary/enterpriseStandardDetail',
query: {
standardNumber: record.standardNo
standardNumber: record.originEnStandardNo
}
})
},
// 企标编号,企标名称跳转详情,新企标
handleGoDetailNew (record) {
this.$openPageNewSheet({
path: '/enterpriseStandardLibrary/enterpriseStandardDetail',
query: {
standardNumber: record.newEnStandardNo
}
})
},