2909 lines
111 KiB
Java
2909 lines
111 KiB
Java
<template>
|
|
<div class="doc-detail">
|
|
<div class="Virtual-detail-header" style="position: fixed;top: 0">
|
|
<div class="Virtual-detail-title">
|
|
<span>
|
|
{{$t('ParameteItemCollectionList')}}({{$t(this.$route.query.projectName)}}) — {{$t(this.$route.query.title)}}
|
|
</span>
|
|
</div>
|
|
<div class="Virtual-detail-title-right">
|
|
<a-popconfirm overlayClassName="popconfirmDetailsText"
|
|
:visible="visible"
|
|
@visibleChange="handleVisibleChange"
|
|
placement="bottomRight">
|
|
<template slot="title" id="popconfirmDetails">
|
|
<div @click="roleSwitchingClick(item.value)"
|
|
v-for="(item,index) in RoleType"
|
|
class="operator-text-title"
|
|
:class="{'operator-text-title-color':item.label == rolename ? true : false}"
|
|
:title="item.label">
|
|
{{ item.label }}
|
|
</div>
|
|
<JLoading :loading="JTextLoading"></JLoading>
|
|
</template>
|
|
<div class="operator-text" style="position: relative;margin-right: 0">
|
|
<a-icon type="select"/>
|
|
{{rolename}}
|
|
</div>
|
|
</a-popconfirm>
|
|
</div>
|
|
</div>
|
|
<div style="padding-top: 54px;background: #fff;height: 100%">
|
|
<div class="detail-content" style="height: 100%">
|
|
<a-card :bordered="false" class="card">
|
|
<div class="table-page-search-wrapper">
|
|
<!-- 认证参数收集-参数项收集清单-10控件-->
|
|
<div class='Virtual-detail-content' style='margin-top: 15px'>
|
|
<a-form layout="inline" @keyup.enter.native="searchQuery">
|
|
<a-row :gutter="24" style='margin-left: -90px;'>
|
|
<a-col :md="6" :sm="8">
|
|
<div class="box-title-text">
|
|
<div class="title-text" :title="$t('ParameterNo')">
|
|
<span>{{$t('ParameterNo')}}</span>
|
|
</div>
|
|
<a-input class="box-input" :placeholder="$t('PleaseEnter')+$t('ParameterNo')"
|
|
v-model="formInline.allNumber"></a-input>
|
|
</div>
|
|
</a-col>
|
|
<a-col :md="6" :sm="8">
|
|
<div class="box-title-text">
|
|
<div class="title-text" :title="$t('NParameterName')">
|
|
<span>{{$t('NParameterName')}}</span>
|
|
</div>
|
|
<a-input class="box-input" :placeholder="$t('PleaseEnter')+$t('NParameterName')"
|
|
v-model="formInline.paramsName"></a-input>
|
|
</div>
|
|
</a-col>
|
|
<!-- <a-col :md="6" :sm="8">-->
|
|
<!-- <div class="box-title-text">-->
|
|
<!-- <div class="title-text" :title="$t('NareaOfResponsibility')">-->
|
|
<!-- <span>{{$t('NareaOfResponsibility')}}</span>-->
|
|
<!-- </div>-->
|
|
<!-- <j-multi-select-tag class="box-input" v-model="formInline.dutyTerritory"-->
|
|
<!-- :placeholder="$t('PleaseSelect')+$t('NareaOfResponsibility')"-->
|
|
<!-- :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('NareaOfResponsibility')">
|
|
<span>{{$t('NareaOfResponsibility')}}</span>
|
|
</div>
|
|
<j-multi-select-tag class="box-input" v-model="formInline.dutyTerritory"
|
|
:placeholder="$t('PleaseSelect')+$t('NareaOfResponsibility')"
|
|
:type="'select'"
|
|
:triggerChange="false" :dictCode="'duty_territory'"/>
|
|
</div>
|
|
</a-col>
|
|
<template v-if="toggleSearchStatus">
|
|
<a-col :md="6" :sm="8">
|
|
<div class="box-title-text">
|
|
<div class="title-text" :title="$t('certificationCategory')">
|
|
<span>{{$t('certificationCategory')}}</span>
|
|
</div>
|
|
<j-dict-select-tag class="box-input" v-model="formInline.certCategory"
|
|
:placeholder="$t('PleaseSelect')+$t('certificationCategory')"
|
|
:type="'select'"
|
|
:triggerChange="false" :dictCode="'cert_category'"/>
|
|
</div>
|
|
</a-col>
|
|
<a-col :md="6" :sm="8">
|
|
<div class="box-title-text">
|
|
<div class="title-text" :title="$t('dre')">
|
|
<span>{{$t('dre')}}</span>
|
|
</div>
|
|
<a-input class="box-input" :placeholder="$t('PleaseEnter')+$t('dre')"
|
|
v-model="formInline.dre"></a-input>
|
|
</div>
|
|
</a-col>
|
|
<a-col :md="6" :sm="8">
|
|
<div class="box-title-text">
|
|
<div class="title-text" :title="$t('sdt')">
|
|
<span>{{$t('sdt')}}</span>
|
|
</div>
|
|
<a-input class="box-input" :placeholder="$t('PleaseEnter')+$t('sdt')"
|
|
v-model="formInline.sdt"></a-input>
|
|
</div>
|
|
</a-col>
|
|
</template>
|
|
<!-- <a-col :md="6" :sm="8">-->
|
|
<!-- <div class="box-title-text">-->
|
|
<!-- <div class="title-text" :title="$t('status')">-->
|
|
<!-- <span>{{$t('status')}}</span>-->
|
|
<!-- </div>-->
|
|
<!-- <a-select :placeholder="$t('PleaseSelect')+$t('status')"-->
|
|
<!-- class="box-input"-->
|
|
<!-- allowClear-->
|
|
<!-- :getPopupContainer="triggerNode=> triggerNode.parentNode"-->
|
|
<!-- v-model="formInline.state">-->
|
|
<!-- <a-select-option v-for="(item, key) in statusList"-->
|
|
<!-- :key="key"-->
|
|
<!-- :value="item.value">-->
|
|
<!-- <span style="display: inline-block;width: 100%" :title=" item.name ">-->
|
|
<!-- {{ item.name}}-->
|
|
<!-- </span>-->
|
|
<!-- </a-select-option>-->
|
|
<!-- </a-select>-->
|
|
<!-- </div>-->
|
|
<!-- </a-col>-->
|
|
<span style="float: right;overflow: hidden;margin-right: 11px"
|
|
class="table-page-search-submitButtons">
|
|
<a-col :md="6" :sm="24">
|
|
<!-- v-if="this.$route.query.it === undefined"-->
|
|
<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>
|
|
</div>
|
|
<div class="table-operator" v-if="!this.$route.query.it">
|
|
<!-- // 认证工程师 homo-->
|
|
<!-- // 工程接口人 sdt-->
|
|
<!-- // 填写人 dre-->
|
|
<!-- // R&H Studio studio-->
|
|
<!-- // R&H Manager manager-->
|
|
<!-- // 系统管理员 admin-->
|
|
<!-- // 游客 guest-->
|
|
<a-popconfirm overlayClassName='popconfirmIndex' placement="bottomRight" v-if='currentPersonRole == "homo"'>
|
|
<template slot="title" id="popconfirm">
|
|
<!-- 添加-->
|
|
<div @click="handleAdd" class="operator-text-title" v-if='currentPersonRole == "homo"'>
|
|
<a-icon type="plus"/>
|
|
{{$t('addTo')}}
|
|
</div>
|
|
<!-- <!– 下发收集 –>-->
|
|
<!-- <div @click="distributionAndCollectionJurisdiction" class="operator-text-title">-->
|
|
<!-- <a-icon type="solution"/>-->
|
|
<!-- {{$t('distributionAndCollection')}}-->
|
|
<!-- </div>-->
|
|
<!-- 导出-->
|
|
<div @click="handleExport" class="operator-text-title" v-if='currentPersonRole == "homo"'>
|
|
<a-icon type="export" :rotate="-90"/>
|
|
{{$t('dataExport')}}
|
|
</div>
|
|
<!-- 一键下发收集 -->
|
|
<div @click="defOneclickCollection" class="operator-text-title" v-if='currentPersonRole == "homo"'>
|
|
<a-icon type="solution"/>
|
|
{{$t('OneclickCollection')}}
|
|
</div>
|
|
<!-- 冻结配置-->
|
|
<div @click="freezeConfiguration" class="operator-text-title" v-if='currentPersonRole == "homo"'>
|
|
<a-icon type="lock"/>
|
|
{{$t('FreezeConfiguration')}}
|
|
</div>
|
|
<!-- 引用参数列-->
|
|
<div @click="Referenceparametercolumn" class="operator-text-title" v-if='currentPersonRole == "homo" '>
|
|
<a-icon type="plus"/>
|
|
{{$t('Referenceparametercolumn')}}
|
|
</div>
|
|
<!-- 更新参数列-->
|
|
<div @click="Updateparametercolumn" class="operator-text-title" v-if='currentPersonRole == "homo" '>
|
|
<a-icon type="check-circle"/>
|
|
{{$t('Updateparametercolumn')}}
|
|
</div>
|
|
<!-- 同步上报库 -->
|
|
<div @click="handleSynchronousReportLibraryJurisdiction" class="operator-text-title"
|
|
v-if='currentPersonRole == "homo"'>
|
|
<a-icon type="sync"/>
|
|
{{$t('SynchronousReportLibrary')}}
|
|
</div>
|
|
<!-- 截止时间-->
|
|
<!-- <div @click="TaskCutOffTimeLibrary" class="operator-text-title">-->
|
|
<!-- <a-icon type="bulb"/>-->
|
|
<!-- {{$t('TaskCutOffTime')}}-->
|
|
<!-- </div>-->
|
|
<!-- 批量删除-->
|
|
<div @click="handleDelJurisdiction" class="operator-text-title" v-if='currentPersonRole == "homo"'>
|
|
<a-icon type="delete"/>
|
|
{{$t('BatchDelete')}}
|
|
</div>
|
|
<div @click="bringInTheProjectInterfaceClick" class="operator-text-title"
|
|
v-if='currentPersonRole == "homo"'>
|
|
<a-icon type="user"/>
|
|
{{$t('bringInTheProjectInterface')}}
|
|
</div>
|
|
<div @click="AdjustareasofresponsibilityClick" class="operator-text-title"
|
|
v-if='currentPersonRole == "homo"'>
|
|
<a-icon type="setting"/>
|
|
{{$t('Adjustareasofresponsibility')}}
|
|
</div>
|
|
<!-- 认证工程师分配填写人-->
|
|
<div @click="assignedByHomo" class="operator-text-title" v-if='currentPersonRole == "homo" '>
|
|
<a-icon type="copy"/>
|
|
{{$t('Assignedby')}}
|
|
</div>
|
|
<!-- 批量更新截止时间-->
|
|
<div @click="batchUpdateDeadlineClick" class="operator-text-title" v-if='currentPersonRole == "homo" '>
|
|
<a-icon type="profile"/>
|
|
{{$t('batchUpdateDeadline')}}
|
|
</div>
|
|
</template>
|
|
<!-- @click='morepop'-->
|
|
<div class="operator-text" style="position: relative "
|
|
v-if='currentPersonRole == "homo" || currentPersonRole == "sdt"'>
|
|
<span style="position: absolute;left: -13px;top: -4px">...</span>{{ $t('more') }}
|
|
</div>
|
|
</a-popconfirm>
|
|
<!-- 下发收集 -->
|
|
<div @click="distributionAndCollectionJurisdiction" class="operator-text"
|
|
v-if='currentPersonRole == "homo"'>
|
|
<a-icon type="solution"/>
|
|
{{$t('distributionAndCollection')}}
|
|
</div>
|
|
|
|
<!-- 分配填写人-->
|
|
<div @click="assignedBy" class="operator-text" v-if='currentPersonRole == "sdt" '>
|
|
<a-icon type="copy"/>
|
|
{{$t('Assignedby')}}
|
|
</div>
|
|
<!-- 导出-->
|
|
<div @click="handleExport" class="operator-text" v-if='currentPersonRole == "sdt" || currentPersonRole == "admin" || currentPersonRole == "studio"'>
|
|
<a-icon type="export"/>
|
|
{{$t('dataExport')}}
|
|
</div>
|
|
<!-- 引用参数-->
|
|
<div @click="referenceparameter" class="operator-text" v-if='currentPersonRole == "dre" '>
|
|
<a-icon type="plus"/>
|
|
{{$t('referenceparameter')}}
|
|
</div>
|
|
<!-- 保存-->
|
|
<div @click="handlePreservation(1)" class="operator-text" v-if='currentPersonRole == "dre"'>
|
|
<a-icon type="check-circle"/>
|
|
{{$t('tempSave')}}
|
|
</div>
|
|
<!-- 提交-->
|
|
<div @click="handleSubmit" class="operator-text" v-if='currentPersonRole == "dre"'>
|
|
<a-icon type="check-circle"/>
|
|
{{$t('submit')}}
|
|
</div>
|
|
<!-- 退回-->
|
|
<div @click="returnDataJurisdiction" class="operator-text"
|
|
v-if='currentPersonRole == "sdt" || currentPersonRole == "homo" || currentPersonRole == "dre"'>
|
|
<a-icon type="rollback"/>
|
|
{{$t('sendBack')}}
|
|
</div>
|
|
<!-- 导入-->
|
|
<div class="operator-text" v-if='currentPersonRole == "dre"'>
|
|
<ImportFileOnlyList :url="url" :isTrue="false" :accept="'.zip'" :paramsManifestId='this.$route.query.id'
|
|
@getList='getList'/>
|
|
</div>
|
|
<!-- 填写人导出-->
|
|
<div @click="handleExportDre" class="operator-text"
|
|
v-if='currentPersonRole == "dre"'>
|
|
<a-icon type="export"/>
|
|
{{$t('export')}}
|
|
</div>
|
|
<!-- 强制撤回-->
|
|
<div @click="compulsoryWithdrawaljurisdiction" class="operator-text"
|
|
v-if='currentPersonRole == "homo" || currentPersonRole == "sdt"'>
|
|
<a-icon type="undo" :rotate="90"/>
|
|
{{$t('CompulsoryWithdrawal')}}
|
|
</div>
|
|
<!-- 列表设置-->
|
|
<!-- v-if="!this.$route.query.it"-->
|
|
<a-popconfirm :visible="customizevisible" overlayClassName="popconfirmIndex"
|
|
placement="bottomRight">
|
|
<template slot="title" id="popconfirmmize">
|
|
<div style="max-height:360px;overflow:scroll;overflow-x: auto;width: 211px">
|
|
<a-checkbox
|
|
style="margin-bottom: 22px;"
|
|
v-if="customizeList && customizeList.length"
|
|
v-model="checkAll"
|
|
:indeterminate="indeterminate"
|
|
@change="onCheckAllChange"
|
|
>{{ $t('selectAll') }}
|
|
</a-checkbox>
|
|
<a-checkbox-group @change="onChange" v-model="checkedList" class="customize-text">
|
|
<a-checkbox class="customize-text-title" :disabled="item.disabled"
|
|
v-for="(item, key) in customizeList"
|
|
:key="key" :value="item.field">{{ item.db_field_txt }}
|
|
</a-checkbox>
|
|
</a-checkbox-group>
|
|
<div class="drawer-bootom-button">
|
|
<a-button @click="cancel" style="margin-right: 16px">{{ $t('cancel') }}</a-button>
|
|
<a-button @click="handleSubmitcustomize" type="primary" :loading="confirmLoading">{{ $t('determine')
|
|
}}
|
|
</a-button>
|
|
</div>
|
|
</div>
|
|
</template>
|
|
<div class="operator-text" style="position: relative" @click="getcustomize">
|
|
<a-icon type="setting"/>
|
|
{{ $t('customize') }}
|
|
</div>
|
|
</a-popconfirm>
|
|
<!-- 角色切换 -->
|
|
<!-- <div class="operator-text"-->
|
|
<!-- v-if="!this.$route.query.it"-->
|
|
<!-- @click="roleSwitchingClick">-->
|
|
<!-- <a-icon type="select"/>-->
|
|
<!-- {{ $t('roleSwitching') }} ({{ $t(this.rolename)}})-->
|
|
<!-- </div>-->
|
|
|
|
</div>
|
|
<div style="width: 100%">
|
|
<!-- 表格-10控件-->
|
|
<!-- :queryParamQuery='queryParamQuery'-->
|
|
<table-collection ref="CollectionTabel" :url='url' :paramsManifest='paramsManifest' @rowValue='rowValue'
|
|
:formInline='formInline' :currentPersonRole='currentPersonRole'
|
|
@getDataSource="getDataSource"
|
|
@handlePreservation="handlePreservation"
|
|
@value='value'
|
|
@getcustomizeList="getcustomizeList"
|
|
@listReset='listReset' @LoginUserType='LoginUserType'/>
|
|
</div>
|
|
</a-card>
|
|
</div>
|
|
</div>
|
|
<!-- 添加--->
|
|
<a-modal v-model="areaVisible" :title="$t('ParameterLibrary')" width='850px' :footer="null">
|
|
<parameter-library-add v-if='areaVisible' :paramsManifest='paramsManifest' @areaVisible='areaVisible = false'
|
|
@GetgetTableList='GetgetTableList'/>
|
|
</a-modal>
|
|
<!-- 冻结配置--->
|
|
<a-modal v-model="areaVisibleFreeze" :title="$t('FreezeConfiguration')" width='600px' :footer="null">
|
|
<a-spin :spinning="confirmLoading">
|
|
<a-form-model
|
|
class='tag-module'
|
|
ref='ruleForm'
|
|
:model='Dateline'
|
|
:rules='rules'
|
|
:label-col='labelCol'
|
|
:wrapper-col='wrapperCol'
|
|
>
|
|
<a-row :gutter='24'>
|
|
<a-col :span='24'>
|
|
<a-form-model-item ref='region' :label="$t('FreezeConfiguration')" prop='region'>
|
|
<a-select :placeholder="$t('freeze')" v-model="Dateline.paramsConfig"
|
|
allowClear mode="multiple">
|
|
<a-select-option v-for="(item, key) in FreezeList" :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>
|
|
</a-col>
|
|
</a-row>
|
|
</a-form-model>
|
|
</a-spin>
|
|
<div style='padding-left: 60px;color: red'>
|
|
{{$t('Attentionfreeze')}}
|
|
</div>
|
|
<div class="imports-footer">
|
|
<div class="imports-footer-wrap">
|
|
|
|
<a-button class="imports-btn imports-sub" type="primary" @click="handleSubmitFreeze">{{$t('preservation')}}
|
|
</a-button>
|
|
<a-button class="imports-btn" type="primary" @click="cancleImportsFreeze">{{$t('cancel')}}</a-button>
|
|
</div>
|
|
</div>
|
|
</a-modal>
|
|
<!-- 分配填写人--->
|
|
<a-modal v-model="areaVisibleAssignedby" :title="$t('Assignedby')" width='950px' :footer="null">
|
|
<assigned-by v-if='areaVisibleAssignedby' :selectedRowKeysArray='selectedRowKeysArray'
|
|
@GetgetTableList='GetgetTableList'
|
|
@GetgetLoginUserType='GetgetLoginUserType'
|
|
@areaVisibleAssignedbyflag='areaVisibleAssignedbyflag' @areaVisible='areaVisibleAssignedby = false'/>
|
|
</a-modal>
|
|
<!-- 认证分配填写人--->
|
|
<a-modal v-model="areaVisibleAssignedbyhomo" :title="$t('Assignedby')" width='950px' :footer="null">
|
|
<assigned-by-homo v-if='areaVisibleAssignedbyhomo' :selectedRowKeysArray='selectedRowKeysArray'
|
|
@GetgetTableList='GetgetTableList'
|
|
@GetgetLoginUserType='GetgetLoginUserType'
|
|
@areaVisibleAssignedbyflaghomo='areaVisibleAssignedbyflaghomo'
|
|
@areaVisible='areaVisibleAssignedbyhomo = false'/>
|
|
</a-modal>
|
|
<!-- 下发收集--->
|
|
<!-- <a-modal v-model="areaVisibleTaskCutOffTime" :title="$t('distributionAndCollection')" width='400px' :footer="null">-->
|
|
<task-cut-off-time ref='areaVisibleTaskCutOffTime' :selectedRowKeysArray='selectedRowKeysArray'
|
|
@GetgetTableList='GetgetTableList'
|
|
@areaVisibleTaskCutOffTimeflag='areaVisibleTaskCutOffTimeflag'/>
|
|
<!-- </a-modal>-->
|
|
<!-- 一键下发收集--->
|
|
<!-- <a-modal v-model="OneclickCollection" :title="$t('OneclickCollection')" width='400px' :footer="null">-->
|
|
<task-time ref='OneclickCollection' :selectedRowKeysArray='selectedRowKeysArray'
|
|
@GetgetTableList='GetgetTableList'
|
|
@areaVisibleTaskCutOffTimeAll='areaVisibleTaskCutOffTimeAll'/>
|
|
<!-- </a-modal>-->
|
|
<!-- 调整责任领域-->
|
|
<a-modal v-model="Adjustareasofrespon" :title="$t('Adjustareasofresponsibility')" width='620px' :footer="null">
|
|
<adjustarea-sofrespon v-if='Adjustareasofrespon' :selectedRowKeysArray='selectedRowKeysArray'
|
|
@GetgetTableList='GetgetTableList'
|
|
@AdjustareasofresponAll='AdjustareasofresponAll'/>
|
|
</a-modal>
|
|
<!-- 引用参数--->
|
|
<a-modal v-model="areaVisiblereferenceparameter" :title="$t('referenceparameter')" width='650px' :footer="null">
|
|
<reference-parameter v-if='areaVisiblereferenceparameter' :paramsManifest='paramsManifest'
|
|
@GetgetTableList='GetgetTableList'
|
|
@areaVisibleAssignedbyflag='areaVisiblereferenceparameter = false'
|
|
:selectedRowKeysArray='selectedRowKeysArray'/>
|
|
</a-modal>
|
|
<!-- 同步上报库--->
|
|
<a-modal v-model="areaVisibsynchronous" :title="$t('SynchronousReportLibrary')" width='650px' :footer="null">
|
|
<synchronous-submission-library v-if='areaVisibsynchronous' :paramsManifest='paramsManifest'
|
|
@GetgetTableList='GetgetTableList'
|
|
:selectedRowKeysArray='selectedRowKeysArray'
|
|
@areaVisibsynchronous='areaVisibsynchronous = false'/>
|
|
</a-modal>
|
|
<!-- 引用参数列-->
|
|
<a-drawer
|
|
class="show-drawer"
|
|
:maskClosable="false"
|
|
:visible="parametercolumn"
|
|
style="height: 100%;overflow: auto;padding-bottom: 53px;"
|
|
placement="right"
|
|
@close="drawerhandleCancel"
|
|
:title="$t('Referenceparametercolumn')"
|
|
width="850px"
|
|
:footer="null">
|
|
<parameter-column v-if='parametercolumn' @drawerhandleCancel='drawerhandleCancel'
|
|
@GetgetTableList='GetgetTableList'
|
|
@GetgetHeader='GetgetHeader'
|
|
:templateTitle='templatetitle'
|
|
:selectedRowKeyS='selectedRowKeys' :rowId='rowId' :version='version' :url='url'
|
|
:projectId='this.$route.query.parentId ? this.$route.query.parentId : this.$route.query.id'>
|
|
|
|
</parameter-column>
|
|
</a-drawer>
|
|
<!-- 切换角色-->
|
|
<a-modal
|
|
:title="$t('roleSwitching')"
|
|
:width="500"
|
|
:visible="visibleRoleSwitching"
|
|
:confirm-loading="confirmLoadingRoleSwitching"
|
|
:maskClosable="false"
|
|
@ok="handleOkRoleSwitching"
|
|
@cancel="handleCancelRoleSwitching"
|
|
>
|
|
<a-form-model :model="formInlineRoleSwitching" class="formAdd" :rules="rulesRoleSwitching"
|
|
ref="ruleFormRoleSwitching">
|
|
<a-row :gutter="24">
|
|
<a-col :span="24">
|
|
<div class="box-title-text-index">
|
|
<div class="title-text-Comment">
|
|
<span class="Required">*</span>
|
|
<span class="title-text-text" :title="$t('roleSwitching')">{{$t('roleSwitching')}}</span>
|
|
</div>
|
|
<a-form-model-item class="itemModelComment itemitem" :prop="'roleSwitchingCode'">
|
|
<a-select allowClear :placeholder="$t('pleaseSelect')+$t('roleSwitching')"
|
|
v-model="formInlineRoleSwitching.roleSwitchingCode">
|
|
<a-select-option v-for="(item, key) in RoleType" :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>
|
|
<!-- 错误数据提示-->
|
|
<a-modal
|
|
:title="$t('operationFailed')"
|
|
:width="860"
|
|
v-model="visibleoperationFailed"
|
|
:maskClosable="false"
|
|
:footer="null"
|
|
>
|
|
<a-row :gutter="24">
|
|
<a-col :span="24">
|
|
<!-- 没有工程接口人,导致下发收集失败提示-->
|
|
<span v-if='NoEngineer === 0'>
|
|
{{$t('NiOnumberis')}}
|
|
</span>
|
|
<span style='font-size: 16px;margin-bottom: 20px;' v-for='(item,key) in NotSelectedNoEngineerValue'
|
|
v-if='NoEngineer === 0'>
|
|
<span style='color: red'>{{ item.nioNumber }}、</span>
|
|
</span>
|
|
<span v-if='NoEngineer === 0'>
|
|
{{$t('Filledperson')}}
|
|
</span>
|
|
<!-- 状态不符合,导致不能操作按钮,没有权限-->
|
|
<div style='font-size: 18px;margin-bottom: 20px;display: flex;justify-content: center'
|
|
class="box-title-text-index" v-for='(item,key) in NotSelectedRowKeysValue' v-if='NoEngineer === 1'>
|
|
<div>{{$t('NiOnumberis')}}{{ item.nioNumber }},{{$t('Statusis')}}<span
|
|
style='color: red'>{{ item.state }}</span>,{{$t('NoOperationPermissionForthisbutton')}}。
|
|
</div>
|
|
</div>
|
|
<!-- 认证工程师-提示-->
|
|
<div style='font-size: 18px;text-align: center' v-if='NoEngineer === 1'>
|
|
{{ currentPersonRole =='homo'? $t('certifiedEngineer'): (currentPersonRole =='sdt'?
|
|
$t('engineeringInterfacePerson'): $t('completedBy')) }}{{jurisdiction === 'homoQZTH'? $t('Datastateexcept')
|
|
: $t('Datastatusis')}}
|
|
<!-- 下发收集时-->
|
|
<span v-if='jurisdiction === "HOMOZFSJ"' class="text-wraning">
|
|
'{{$t('CollectionInitiated')}}'、'{{$t('ReturnedPerson')}}'{{$t('or')}}'{{$t('alteration')}}'
|
|
</span>
|
|
<!-- 同步上报库-->
|
|
<span v-else-if='jurisdiction === "HOMOTBSBK"' class="text-wraning">
|
|
'{{$t('Submitted')}}'{{$t('or')}}'{{$t('alteration')}}'
|
|
</span>
|
|
<!-- 截止时间-->
|
|
<span v-else-if='jurisdiction === "HOMOJZSJ"' class="text-wraning">
|
|
'{{$t('CollectionInitiated')}}'
|
|
</span>
|
|
<!-- 分配填写人 -->
|
|
<span v-else-if='jurisdiction === "SDTFPTXR"' class="text-wraning">
|
|
'{{$t('handledInterface')}}'{{$t('or')}}'{{$t('Filledreturn')}}'
|
|
</span>
|
|
<!-- 分配填写人 -->
|
|
<span v-else-if='jurisdiction === "SDTFPTXRHOMO"' class="text-wraning">
|
|
'{{$t('completed')}}''{{$t('or')}}'{{$t('Filledreturn')}}''{{$t('or')}}'{{$t('ReturnedEngineer')}}'
|
|
</span>
|
|
<!-- 引用参数-->
|
|
<span v-else-if='jurisdiction === "DREYYCS"' class="text-wraning">
|
|
'{{$t('completed')}}'{{$t('or')}}'{{$t('ReturnedEngineer')}}'
|
|
</span>
|
|
<!-- 退回-->
|
|
<span v-else-if='jurisdiction === "homoTH"' class="text-wraning" style='color: red'>
|
|
{{$t('Submitted')}}
|
|
</span>
|
|
<span v-else-if='jurisdiction === "sdtTH"' class="text-wraning">
|
|
<p style='display: inline; color: red'>'{{$t('handledInterface')}}'</p>
|
|
{{$t('or')}}
|
|
<p style='display: inline; color: red'>'{{$t('Filledreturn')}}'</p>
|
|
</span>
|
|
<span v-else-if='jurisdiction === "dreTH"' class="text-wraning">
|
|
<p style='display: inline; color: red'>'{{$t('completed')}}'</p>
|
|
{{$t('or')}}
|
|
<p style='display: inline; color: red'>'{{$t('ReturnedEngineer')}}'</p>
|
|
</span>
|
|
<!-- 强制撤回-->
|
|
<span v-else-if='jurisdiction === "homoQZTH"' class="text-wraning">
|
|
<p style='display: inline; color: red'>'{{$t('SynchronizedLibrary')}}'</p>
|
|
{{$t('or')}}
|
|
<p style='display: inline; color: red'>'{{$t('CollectionInitiated')}}'</p>
|
|
</span>
|
|
<span v-else-if='jurisdiction === "sdtQZTH"' class="text-wraning" style='color: red'>
|
|
{{$t('completed')}}
|
|
</span>
|
|
<span v-else-if='jurisdiction === "dreQZTH"' class="text-wraning" style='color: red'>
|
|
{{$t('Submitted')}}
|
|
</span>
|
|
{{$t('timeoperation')}}
|
|
</div>
|
|
</a-col>
|
|
</a-row>
|
|
<div class="imports-footer">
|
|
<div class="imports-footer-wrap">
|
|
<a-button class="imports-btn" type="primary" @click="cancleoperationFailed">{{$t('cancel')}}</a-button>
|
|
</div>
|
|
</div>
|
|
</a-modal>
|
|
<!-- 数据导出弹框-->
|
|
<a-modal
|
|
:title="$t('dataExport')"
|
|
:width="500"
|
|
:visible="dataExportFailed"
|
|
:maskClosable="false"
|
|
@ok="handleExportSubmit"
|
|
@cancel="handleCancel"
|
|
>
|
|
<a-form-model
|
|
class='formAdd'
|
|
ref='dataExportruleForm'
|
|
:model='dataExportformInline'
|
|
:rules='dataExportrules'
|
|
:label-col='labelCol'
|
|
:wrapper-col='wrapperCol'
|
|
>
|
|
<a-row :gutter="24">
|
|
<a-col :span="24">
|
|
<div class="box-title-text" >
|
|
<div class="title-text" :title="$t('exportOption')" style='margin-top: -17px;'>
|
|
<span class="Required">*</span>
|
|
<span class="title-text-text" :title="$t('exportOption')">
|
|
{{$t('exportOption')}}</span>
|
|
</div>
|
|
<a-form-model-item class="itemModel" prop="exportOption">
|
|
<a-select class="box-input" allowClear v-model="dataExportformInline.exportOption" :placeholder="$t('PleaseSelect')+$t('exportOption')">
|
|
<a-select-option :value="'1'">
|
|
{{$t('includeTitle')}}
|
|
</a-select-option>
|
|
<a-select-option :value="'0'">
|
|
{{$t('Notitleincluded')}}
|
|
</a-select-option>
|
|
</a-select>
|
|
</a-form-model-item>
|
|
</div>
|
|
</a-col>
|
|
</a-row>
|
|
</a-form-model>
|
|
</a-modal>
|
|
<JLoading :loading="textLoading">{{this.$t('pleaseWaitWhileRunning')}}</JLoading>
|
|
<batchUpdateDeadline ref="batchUpdateDeadlineRef" @batchUpdateDeadlineForm="batchUpdateDeadlineForm"/>
|
|
|
|
</div>
|
|
</template>
|
|
|
|
<script>
|
|
import TableCollection from '@/components/tableCollection/index'
|
|
import parameterColumn from '../dialog/parametercolumn'
|
|
import { getAction, postAction, downloadFile } from '../../../api/manage'
|
|
import eventBUs from '../../../common/event'
|
|
import customizeList from './customizeList'
|
|
import ParameterLibraryAdd from '@/components/ParameterLibraryAdd/index'
|
|
import globalAdvancedQuery from '@/components/globalAdvancedQuery/index'
|
|
import SynchronousSubmissionLibrary from '@/components/SynchronousSubmissionLibrary/index'
|
|
import TaskCutOffTime from '@/components/TaskCutOffTime/index'
|
|
import TaskTime from '@/components/TaskCutOffTime/indexonekey'
|
|
import AdjustareaSofrespon from '@/components/AdjustareaSofrespon/index'
|
|
import ReferenceParameter from '@/components/ReferenceParameter/index'
|
|
import AssignedBy from '@/components/AssignedBy/index'
|
|
import AssignedByHomo from '@/components/AssignedByHomo/index'
|
|
import ImportFileOnlyList from '@/components/ImportFileOnlyListtag/index'
|
|
import batchUpdateDeadline from './batchUpdateDeadline'
|
|
import axios from 'axios'
|
|
import { ACCESS_TOKEN } from '@/store/mutation-types'
|
|
import Vue from 'vue'
|
|
import { mapGetters } from 'vuex'
|
|
|
|
export default {
|
|
name: 'ParameterItemCollectionList',
|
|
components: {
|
|
TableCollection,
|
|
ParameterLibraryAdd,
|
|
customizeList,
|
|
parameterColumn,
|
|
AssignedBy,
|
|
AssignedByHomo,
|
|
AdjustareaSofrespon,
|
|
ImportFileOnlyList,
|
|
TaskCutOffTime,
|
|
ReferenceParameter,
|
|
SynchronousSubmissionLibrary,
|
|
TaskTime,
|
|
globalAdvancedQuery,
|
|
batchUpdateDeadline
|
|
},
|
|
data() {
|
|
this.statusList = [
|
|
{
|
|
value: '1',
|
|
text: this.$t('CollectionInitiated'),
|
|
key: '1'
|
|
},
|
|
{
|
|
value: '2',
|
|
text: this.$t('handledInterface'),
|
|
key: '2'
|
|
},
|
|
{
|
|
value: '3',
|
|
text: this.$t('ReturnedPerson'),
|
|
key: '3'
|
|
},
|
|
{
|
|
value: '4',
|
|
text: this.$t('completed'),
|
|
key: '4'
|
|
},
|
|
{
|
|
value: '5',
|
|
text: this.$t('Filledreturn'),
|
|
key: '5'
|
|
},
|
|
{
|
|
value: '6',
|
|
text: this.$t('Submitted'),
|
|
key: '6'
|
|
},
|
|
{
|
|
value: '7',
|
|
text: this.$t('ReturnedEngineer'),
|
|
key: '7'
|
|
},
|
|
{
|
|
value: '8',
|
|
text: this.$t('SynchronizedLibrary'),
|
|
key: '8'
|
|
},
|
|
{
|
|
value: '9',
|
|
text: this.$t('alteration'),
|
|
key: '9'
|
|
}
|
|
]
|
|
return {
|
|
// 认证工程师 homo
|
|
// 工程接口人 sdt
|
|
// 填写人 dre
|
|
// R&H Studio studio
|
|
// R&H Manager manager
|
|
// 系统管理员 admin
|
|
// 游客 guest
|
|
toggleSearchStatus: false,
|
|
columns: [
|
|
{
|
|
title: this.$t('title'),
|
|
align: 'center',
|
|
dataIndex: 'title',
|
|
scopedSlots: { customRender: 'paramsManifestClick' }
|
|
},
|
|
{
|
|
title: this.$t('status'),
|
|
align: 'center',
|
|
dataIndex: 'state'
|
|
},
|
|
{
|
|
title: this.$t('parameterTemplateName'),
|
|
align: 'center',
|
|
dataIndex: 'paramsTemplateName'
|
|
},
|
|
{
|
|
title: this.$t('collectionCompletionTime'),
|
|
align: 'center',
|
|
dataIndex: 'finishTime'
|
|
},
|
|
{
|
|
title: this.$t('Version'),
|
|
align: 'center',
|
|
dataIndex: 'version'
|
|
},
|
|
{
|
|
title: this.$t('creator'),
|
|
align: 'center',
|
|
dataIndex: 'createBy'
|
|
},
|
|
{
|
|
title: this.$t('createTime'),
|
|
align: 'center',
|
|
dataIndex: 'createTime'
|
|
},
|
|
{
|
|
title: this.$t('operation'),
|
|
align: 'center',
|
|
fixed: 'right',
|
|
width: 200,
|
|
scopedSlots: { customRender: 'operation' }
|
|
}
|
|
],
|
|
fieldList: [
|
|
{
|
|
type: '',
|
|
value: 'certCategory',
|
|
text: this.$t('certificationCategory'),
|
|
dictCode: 'cert_category'//只要 dictCode 有值,无论 type 是什么,都显示为字典下拉框
|
|
},
|
|
{
|
|
type: 'input',
|
|
value: 'paramsNumber',
|
|
text: this.$t('certificationCategoryNumber')
|
|
},
|
|
{
|
|
type: '',
|
|
value: 'state',
|
|
text: this.$t('status'),
|
|
options: this.statusList//只要 dictCode 有值,无论 type 是什么,都显示为字典下拉框
|
|
},
|
|
{
|
|
type: 'string',
|
|
value: 'params_batch',
|
|
text: this.$t('parameterBatch'),
|
|
dictCode: 'params_batch'
|
|
},
|
|
{
|
|
type: '',
|
|
value: 'sdt',
|
|
text: this.$t('sdt'),
|
|
dictCode: 'sdt'//只要 dictCode 有值,无论 type 是什么,都显示为字典下拉框
|
|
},
|
|
{
|
|
type: '',
|
|
value: 'dre',
|
|
text: this.$t('dre'),
|
|
dictCode: 'dre'//只要 dictCode 有值,无论 type 是什么,都显示为字典下拉框
|
|
}
|
|
],
|
|
customizevisible: false,
|
|
indeterminate: false,
|
|
checkAll: false,
|
|
visible: false,
|
|
selectedValue: [],
|
|
checkedList: ['nio_number', 'params_name', 'operation'],
|
|
// customizeList: [
|
|
// {
|
|
// sort: '1',
|
|
// name: this.$t('NiONumber'),
|
|
// disabled: true,
|
|
// headFieldCn: 'NIO编号',
|
|
// headFieldEn: 'NiONumber',
|
|
// field: 'nioNumber',
|
|
// key: 1,
|
|
// moduleFlag: '参数收集',
|
|
// status: 1
|
|
// },
|
|
// {
|
|
// sort: '2',
|
|
// disabled: true,
|
|
// name: this.$t('ParameterName'),
|
|
// headFieldCn: '参数名称',
|
|
// headFieldEn: 'Parameter Name',
|
|
// field: 'paramsName',
|
|
// key: 2,
|
|
// moduleFlag: '参数收集',
|
|
// status: 2
|
|
// },
|
|
// {
|
|
// sort: '3',
|
|
// name: this.$t('ParameterDescription'),
|
|
// headFieldCn: '参数说明',
|
|
// headFieldEn: 'Parameter Description',
|
|
// field: 'description',
|
|
// key: 3,
|
|
// moduleFlag: '参数收集'
|
|
// },
|
|
// {
|
|
// sort: '',
|
|
// name: this.$t('status'),
|
|
// headFieldCn: '状态',
|
|
// headFieldEn: 'status',
|
|
// field: 'state',
|
|
// key: 4,
|
|
// moduleFlag: '参数收集'
|
|
// },
|
|
// {
|
|
// sort: '',
|
|
// name: this.$t('areaOfResponsibility'),
|
|
// headFieldCn: '责任领域',
|
|
// headFieldEn: 'Responsible Field',
|
|
// field: 'dutyTerritory',
|
|
// key: 5,
|
|
// moduleFlag: '参数收集'
|
|
// },
|
|
// {
|
|
// sort: '',
|
|
// name: this.$t('engineeringInterfacePerson'),
|
|
// headFieldCn: '工程接口人',
|
|
// headFieldEn: 'Eng. Interface',
|
|
// field: 'sdt',
|
|
// key: 6,
|
|
// moduleFlag: '参数收集'
|
|
// },
|
|
// {
|
|
// sort: '',
|
|
// name: this.$t('completedBy'),
|
|
// headFieldCn: '填写人',
|
|
// headFieldEn: 'Filled by',
|
|
// field: 'dre',
|
|
// key: 15,
|
|
// moduleFlag: '参数收集'
|
|
// },
|
|
// {
|
|
// sort: '',
|
|
// name: this.$t('Deadline'),
|
|
// headFieldCn: '截止时间',
|
|
// headFieldEn: 'Due Date',
|
|
// field: 'deadline',
|
|
// key: 23,
|
|
// moduleFlag: '参数收集'
|
|
// },
|
|
// {
|
|
// sort: '',
|
|
// name: this.$t('databasereportingtime'),
|
|
// headFieldCn: '同步上报库时间',
|
|
// headFieldEn: 'database reporting time',
|
|
// field: 'reportTime',
|
|
// key: 23,
|
|
// moduleFlag: '参数收集'
|
|
// },
|
|
//
|
|
// {
|
|
// sort: '',
|
|
// disabled: true,
|
|
// name: this.$t('operation'),
|
|
// headFieldCn: '操作',
|
|
// headFieldEn: 'Operation',
|
|
// key: 35,
|
|
// field: 'operation',
|
|
// moduleFlag: '参数收集',
|
|
// status: 2
|
|
// }
|
|
// ],
|
|
customizeList: [],
|
|
selectedRowKeys: [],
|
|
textLoading: false,
|
|
formInline: {},
|
|
dataExportformInline: {},
|
|
queryParamQuery: {},
|
|
url: {
|
|
tableHeader: 'params/collectManifest/getHeader',
|
|
tableList: 'params/collectManifest/list',
|
|
add: 'params/collectManifest/submit',
|
|
getLoginUserType: 'params/collectManifest/getLoginUserType', // 获取当前登陆人
|
|
getquerySdtList: 'params/collectManifest/querySdtList', // 获取工程接口人的列表
|
|
updateSdt: 'params/collectManifest/updateSdt', // 提交工程接口人
|
|
importZipUrl: 'params/collectManifest/importDre', // 导入
|
|
deleteBatch: 'params/collectManifest/deleteBatch'
|
|
},
|
|
loading: false,
|
|
dataSource: [],
|
|
statuList: [],
|
|
areaVisible: false, // 弹框的控制
|
|
configureareaVisible: false, // 配置的彈框
|
|
pageNo: 1,
|
|
pageSize: 10,
|
|
rolename: '',
|
|
total: 0,
|
|
selectedRowKeysArray: '',
|
|
templatetitle: '',
|
|
templatetitleId: '',
|
|
roleSwitchName: '',
|
|
rowId: '',
|
|
version: 0,
|
|
confirmLoading: false,
|
|
importsVisible: false,
|
|
itemId: '',
|
|
selectedRowKeysValue: [], // table列表所选得数据
|
|
token: Vue.ls.get(ACCESS_TOKEN),
|
|
Dateline: {},
|
|
areaVisibleFreeze: false, // 冻结配置
|
|
areaVisibleAssignedby: false, // 分配填写人弹框
|
|
areaVisibleAssignedbyhomo: false, // 认证分配填写人弹框
|
|
areaVisibleTaskCutOffTime: false, // 截至时间弹框
|
|
OneclickCollection: false,
|
|
parametercolumn: false,
|
|
Adjustareasofrespon: false,
|
|
areaVisiblereferenceparameter: false, // 引用参数弹框
|
|
areaVisibsynchronous: false, // 同步上报库弹框
|
|
visibleoperationFailed: false, // 数据失败的弹框
|
|
dataExportFailed: false, // 数据失败的弹框
|
|
currentPersonRole: '', // 当前人角色
|
|
jurisdiction: '',
|
|
wrapperCol: {
|
|
xs: { span: 24 },
|
|
sm: { span: 14 }
|
|
},
|
|
labelCol: {
|
|
xs: { span: 24 },
|
|
sm: { span: 7 }
|
|
},
|
|
rules: {},
|
|
dataExportrules: {
|
|
exportOption:[
|
|
{ required: true, message: this.$t('PleaseSelect')+this.$t('exportOption'), trigger: 'change' }
|
|
]
|
|
},
|
|
FreezeList: [], // 冻结字段
|
|
roleSwitchingList: [],
|
|
JTextLoading: false,
|
|
visibleRoleSwitching: false, // 角色切换
|
|
confirmLoadingRoleSwitching: false,
|
|
formInlineRoleSwitching: {},
|
|
rulesRoleSwitching: {
|
|
roleSwitchingCode: [
|
|
{
|
|
required: true,
|
|
message: this.$t('roleSwitching') + this.$t('cannotEmpty'),
|
|
trigger: 'change'
|
|
}
|
|
]
|
|
},
|
|
RoleType: [],// 控件类型
|
|
NotSelectedRowKeysValue: [],
|
|
NoEngineer: 1, // 下发收集的权限,0为没有接口人 1为由接口人 默认有
|
|
NotSelectedNoEngineerValue: [],
|
|
paramsManifest: {},
|
|
timeBatch: '',
|
|
timer: ''
|
|
}
|
|
},
|
|
props: {
|
|
// paramsManifest: {
|
|
// type: Object,
|
|
// default: {},
|
|
// require: true
|
|
// }
|
|
},
|
|
mounted() {
|
|
this.handleClick()
|
|
this.getcustomizeList()
|
|
window.addEventListener('keyup', this.handleKeyup)
|
|
window.addEventListener('click', this.handleClick)
|
|
this.GetgetLoginUserType()
|
|
console.log(this.currentPersonRole)
|
|
if (this.$route.query.type == '1') {
|
|
this.handleOkRoleSwitching()
|
|
}
|
|
// clearTimeout(this.timeBatch)
|
|
// this.timeBatch = setTimeout(() => {
|
|
// if (this.currentPersonRole == 'dre') {
|
|
// this.handlePreservation()
|
|
// }
|
|
// }, 10000)
|
|
// if (this.currentPersonRole == 'dre') {
|
|
// this.timeBatch = setInterval(() => {
|
|
// this.handlePreservation();
|
|
// }, 10000);
|
|
// this.$nextTick(() => {
|
|
// var interval = setInterval(this.handlePreservation(),10000);
|
|
// /* if 5 minutes no operation then logout */
|
|
// var maxTime = 120; // seconds
|
|
// var time = maxTime;
|
|
// $('body').on('keydown mousemove mousedown', function(e) {
|
|
// time = maxTime; // reset
|
|
// });
|
|
// var intervalId = setInterval(function() {
|
|
// time--;
|
|
// if (time <= 0) {
|
|
// ShowInvalidLoginMessage();
|
|
// clearInterval(intervalId);
|
|
// }
|
|
// }, 10000)
|
|
// function ShowInvalidLoginMessage() {
|
|
// // 停止定时器
|
|
// clearInterval(interval);
|
|
// }
|
|
// })
|
|
// }
|
|
// this.paramsManifest = JSON.parse(localStorage.getItem('paramsManifest'))
|
|
this.paramsManifest = this.$route.query
|
|
// document.title = `${this.paramsManifest.title}-` + this.$t('ParameteItemCollectionList')
|
|
document.title = `${this.paramsManifest.title}-` + this.$t('ParameteItemCollectionList')
|
|
},
|
|
methods: {
|
|
...mapGetters(['userInfo']),
|
|
handleKeyup() {
|
|
clearTimeout(this.timer)
|
|
clearTimeout(this.timeBatch)
|
|
clearTimeout(this.timerOne)
|
|
this.timer = setTimeout(() => {
|
|
if (this.currentPersonRole == 'dre') {
|
|
this.handlePreservation()
|
|
}
|
|
}, 10000)
|
|
this.timerOne = setTimeout(() => {
|
|
clearTimeout(this.timer)
|
|
clearTimeout(this.timeBatch)
|
|
clearTimeout(this.timerOne)
|
|
}, 300000)
|
|
},
|
|
handleClick() {
|
|
clearTimeout(this.timer)
|
|
clearTimeout(this.timeBatch)
|
|
clearTimeout(this.timerOne)
|
|
this.timer = setTimeout(() => {
|
|
if (this.currentPersonRole == 'dre') {
|
|
this.handlePreservation()
|
|
}
|
|
}, 10000)
|
|
this.timerOne = setTimeout(() => {
|
|
clearTimeout(this.timer)
|
|
clearTimeout(this.timeBatch)
|
|
clearTimeout(this.timerOne)
|
|
}, 300000)
|
|
},
|
|
handleVisibleChange(visible) {
|
|
this.visible = visible
|
|
},
|
|
handleToggleSearch() {
|
|
this.toggleSearchStatus = !this.toggleSearchStatus
|
|
},
|
|
handleCancelRoleSwitching() {
|
|
this.visibleRoleSwitching = false
|
|
},
|
|
bringInTheProjectInterfaceClick() {
|
|
let query = {
|
|
paramsManifestId: this.paramsManifest.id,
|
|
projectId: this.$route.query.projectId
|
|
}
|
|
this.textLoading = true
|
|
getAction('/params/collectManifest/bringSdtInto', query).then((res) => {
|
|
if (res.success) {
|
|
this.$message.success(this.$t('OperationSuccessful'))
|
|
this.$refs.CollectionTabel.getTableList(this.queryParamQuery)
|
|
} else {
|
|
this.$message.warning(this.$t('operationFailed'))
|
|
}
|
|
this.textLoading = false
|
|
})
|
|
},
|
|
handleOkRoleSwitching() {
|
|
if (this.$route.query.type == '1') {
|
|
let query = {
|
|
userType: this.formInlineRoleSwitching.roleSwitchingCode ? this.formInlineRoleSwitching.roleSwitchingCode : this.$route.query.userType,
|
|
paramsManifestId: this.$route.query.id,
|
|
projectId: this.$route.query.projectId,
|
|
userId: this.userInfo().id
|
|
}
|
|
this.confirmLoadingRoleSwitching = true
|
|
postAction('/params/userTypeLog/edit', query).then((res) => {
|
|
if (res.success) {
|
|
this.currentPersonRole = this.formInlineRoleSwitching.roleSwitchingCode ? this.formInlineRoleSwitching.roleSwitchingCode : this.$route.query.userType
|
|
this.visibleRoleSwitching = false
|
|
this.confirmLoadingRoleSwitching = false
|
|
localStorage.setItem('currentPersonRole', JSON.stringify(this.formInlineRoleSwitching.roleSwitchingCode ? this.formInlineRoleSwitching.roleSwitchingCode : this.$route.query.userType))
|
|
this.RoleType.forEach((item, index) => {
|
|
if (item.value == this.currentPersonRole) {
|
|
this.rolename = item.label
|
|
}
|
|
})
|
|
this.selectedRowKeysValue = []
|
|
} else {
|
|
this.confirmLoadingRoleSwitching = false
|
|
this.$message.warning(this.$t('operationFailed'))
|
|
}
|
|
})
|
|
} else {
|
|
this.$refs.ruleFormRoleSwitching.validate(valid => {
|
|
if (valid) {
|
|
let query = {
|
|
userType: this.formInlineRoleSwitching.roleSwitchingCode,
|
|
paramsManifestId: this.$route.query.id,
|
|
projectId: this.$route.query.projectId,
|
|
userId: this.userInfo().id
|
|
}
|
|
this.confirmLoadingRoleSwitching = true
|
|
postAction('/params/userTypeLog/edit', query).then((res) => {
|
|
if (res.success) {
|
|
this.currentPersonRole = this.formInlineRoleSwitching.roleSwitchingCode
|
|
this.$message.success(this.$t('OperationSuccessful'))
|
|
this.visibleRoleSwitching = false
|
|
this.confirmLoadingRoleSwitching = false
|
|
localStorage.setItem('currentPersonRole', JSON.stringify(this.formInlineRoleSwitching.roleSwitchingCode))
|
|
this.RoleType.forEach((item, index) => {
|
|
if (item.value == this.currentPersonRole) {
|
|
this.rolename = item.label
|
|
}
|
|
})
|
|
this.selectedRowKeysValue = []
|
|
} else {
|
|
this.confirmLoadingRoleSwitching = false
|
|
this.$message.warning(this.$t('operationFailed'))
|
|
}
|
|
})
|
|
}
|
|
})
|
|
}
|
|
},
|
|
roleSwitchingClick(roleCode) {
|
|
console.log(roleCode, 1111)
|
|
this.JTextLoading = true
|
|
// this.visibleRoleSwitching = true
|
|
this.$nextTick(() => {
|
|
this.formInlineRoleSwitching.roleSwitchingCode = this.currentPersonRole
|
|
// this.$refs.ruleFormRoleSwitching.clearValidate()
|
|
clearTimeout(this.timeBatch)
|
|
this.timeBatch = setTimeout(() => {
|
|
if (this.currentPersonRole == 'dre') {
|
|
this.handlePreservation()
|
|
}
|
|
}, 10000)
|
|
// }
|
|
})
|
|
if (this.$route.query.type == '1') {
|
|
let query = {
|
|
userType: roleCode ? roleCode : this.$route.query.userType,
|
|
paramsManifestId: this.$route.query.id,
|
|
projectId: this.$route.query.projectId,
|
|
userId: this.userInfo().id
|
|
}
|
|
this.confirmLoadingRoleSwitching = true
|
|
postAction('/params/userTypeLog/edit', query).then((res) => {
|
|
if (res.success) {
|
|
this.currentPersonRole = roleCode ? roleCode : this.$route.query.userType
|
|
this.visibleRoleSwitching = false
|
|
this.confirmLoadingRoleSwitching = false
|
|
this.JTextLoading = false
|
|
this.visible = false
|
|
localStorage.setItem('currentPersonRole', JSON.stringify(roleCode ? roleCode : this.$route.query.userType))
|
|
this.RoleType.forEach((item, index) => {
|
|
if (item.value == this.currentPersonRole) {
|
|
this.rolename = item.label
|
|
}
|
|
})
|
|
this.selectedRowKeysValue = []
|
|
} else {
|
|
this.confirmLoadingRoleSwitching = false
|
|
this.JTextLoading = false
|
|
this.$message.warning(this.$t('operationFailed'))
|
|
}
|
|
})
|
|
} else {
|
|
// this.$refs.ruleFormRoleSwitching.validate(valid => {
|
|
// if (valid) {
|
|
let query = {
|
|
userType: roleCode,
|
|
paramsManifestId: this.$route.query.id,
|
|
projectId: this.$route.query.projectId,
|
|
userId: this.userInfo().id
|
|
}
|
|
this.confirmLoadingRoleSwitching = true
|
|
postAction('/params/userTypeLog/edit', query).then((res) => {
|
|
if (res.success) {
|
|
this.currentPersonRole = roleCode
|
|
this.$message.success(this.$t('OperationSuccessful'))
|
|
this.visibleRoleSwitching = false
|
|
this.confirmLoadingRoleSwitching = false
|
|
this.JTextLoading = false
|
|
this.visible = false
|
|
localStorage.setItem('currentPersonRole', JSON.stringify(roleCode))
|
|
this.RoleType.forEach((item, index) => {
|
|
if (item.value == this.currentPersonRole) {
|
|
this.rolename = item.label
|
|
}
|
|
})
|
|
this.selectedRowKeysValue = []
|
|
} else {
|
|
this.confirmLoadingRoleSwitching = false
|
|
this.JTextLoading = false
|
|
this.$message.warning(this.$t('operationFailed'))
|
|
}
|
|
})
|
|
// }
|
|
// })
|
|
}
|
|
// let query = {
|
|
// roleCode: roleSwitchingCode,
|
|
// id: this.AndUserId,
|
|
// projectLibraryId: this.$route.query.id,
|
|
// modelType: 'Laws inventory'
|
|
// }
|
|
// // this.confirmLoadingRoleSwitching = true
|
|
// postAction(this.url.AndUserIdEdit, query).then((res) => {
|
|
// if (res.success) {
|
|
// this.roleSwitchingCode = roleSwitchingCode
|
|
// this.$message.success(this.$t('OperationSuccessful'))
|
|
// // this.visibleRoleSwitching = false
|
|
// // this.confirmLoadingRoleSwitching = false
|
|
// this.$emit('getRoleSwitch', roleSwitchingCode)
|
|
// this.selectedRowKeys = []
|
|
// this.getList()
|
|
// } else {
|
|
// this.confirmLoadingRoleSwitching = false
|
|
// this.$message.warning(this.$t('operationFailed'))
|
|
// }
|
|
// })
|
|
},
|
|
GetgetLoginUserType() {
|
|
this.$refs.CollectionTabel.getLoginUserType()
|
|
},
|
|
GetgetTableList() {
|
|
this.$refs.CollectionTabel.getTableList(this.queryParamQuery)
|
|
},
|
|
GetgetHeader() {
|
|
this.$refs.CollectionTabel.getHeader()
|
|
},
|
|
// 错误数据的弹框
|
|
cancleoperationFailed() {
|
|
this.selectedRowKeysValue = []
|
|
this.visibleoperationFailed = false
|
|
this.$refs.CollectionTabel.cancleoperationFailed()
|
|
// this.GetgetTableList()
|
|
},
|
|
// 一下为认证工程师
|
|
// 认证工程师 下发收集 权限
|
|
// 仅仅状态为 待发起收集 工程接口人退回 变更 可以下发收集
|
|
homodistributionAndCollection() {
|
|
this.NoEngineer = 1
|
|
this.NotSelectedRowKeysValue = []
|
|
this.NotSelectedNoEngineerValue = []
|
|
// 定义开关 0为没有权限 1为有权限
|
|
let flag = 1
|
|
if (this.selectedRowKeysValue.length == 0) {
|
|
flag = 2
|
|
this.$message.warning(this.$t('selectLeastOne'))
|
|
} else {
|
|
this.selectedRowKeysValue.forEach((item, index) => {
|
|
// 状态不符合,不能下发收集
|
|
if (item.state !== '待发起收集' && item.state !== '工程接口人退回' && item.state !== '变更' && item.state !== 'To be collected' && item.state !== 'Rejected by eng. interface' && item.state !== 'Modify') {
|
|
this.NotSelectedRowKeysValue.push(item)
|
|
flag = 0
|
|
}
|
|
// 状态符合,但是没有工程接口人 不能下发收集
|
|
if ((item.sdt.dataValue === null || item.sdt.dataValue === 'undefined') && (flag == 1 || flag == 3)) {
|
|
this.NotSelectedNoEngineerValue.push(item)
|
|
flag = 3
|
|
}
|
|
})
|
|
}
|
|
return flag
|
|
},
|
|
// 认证工程师的权限
|
|
// 认证工程师 退回 权限
|
|
// 仅仅状态为 已提交 可以退回
|
|
homoJurisdictionReturn() {
|
|
console.log(this.selectedRowKeysValue)
|
|
// 认证工程师 已提交
|
|
if (this.currentPersonRole == 'homo') {
|
|
this.NotSelectedRowKeysValue = []
|
|
// 定义开关 0为没有权限 1为有权限
|
|
let flag = 1
|
|
if (this.selectedRowKeysValue.length == 0) {
|
|
flag = 2
|
|
this.$message.warning(this.$t('selectLeastOne'))
|
|
} else {
|
|
this.selectedRowKeysValue.forEach((item, index) => {
|
|
if (item.state !== '已提交' && item.state !== 'Submitted') {
|
|
this.NotSelectedRowKeysValue.push(item)
|
|
this.jurisdiction = 'homoTH'
|
|
flag = 0
|
|
}
|
|
})
|
|
}
|
|
return flag
|
|
//工程接口人 待工程接口人处理 填写人退回
|
|
} else if (this.currentPersonRole == 'sdt') {
|
|
this.NotSelectedRowKeysValue = []
|
|
// 定义开关 0为没有权限 1为有权限
|
|
let flag = 1
|
|
if (this.selectedRowKeysValue.length == 0) {
|
|
flag = 2
|
|
this.$message.warning(this.$t('selectLeastOne'))
|
|
} else {
|
|
this.selectedRowKeysValue.forEach((item, index) => {
|
|
if (item.state !== '待工程接口人处理' && item.state !== '填写人退回' && item.state !== 'To be processed by eng. interface' && item.state !== 'Rejected by the applicant') {
|
|
this.NotSelectedRowKeysValue.push(item)
|
|
this.jurisdiction = 'sdtTH'
|
|
flag = 0
|
|
}
|
|
})
|
|
}
|
|
return flag
|
|
//填写人 待填写 认证工程师退回
|
|
} else if (this.currentPersonRole == 'dre') {
|
|
this.NotSelectedRowKeysValue = []
|
|
// 定义开关 0为没有权限 1为有权限
|
|
let flag = 1
|
|
if (this.selectedRowKeysValue.length == 0) {
|
|
flag = 2
|
|
this.$message.warning(this.$t('selectLeastOne'))
|
|
} else {
|
|
this.selectedRowKeysValue.forEach((item, index) => {
|
|
if (item.state !== '待填写' && item.state !== '认证工程师退回' && item.state !== 'To be filled' && item.state !== 'Rejected by homo engineer') {
|
|
this.NotSelectedRowKeysValue.push(item)
|
|
this.jurisdiction = 'dreTH'
|
|
flag = 0
|
|
}
|
|
})
|
|
}
|
|
console.log(flag)
|
|
return flag
|
|
}
|
|
},
|
|
//导出
|
|
handleExport() {
|
|
this.dataExportFailed = true
|
|
// this.$message.success(this.$t('Intheexport'))
|
|
// let long = localStorage.getItem('language')
|
|
// this.cut = ''
|
|
// if (long && long === 'zh-cn') {
|
|
// this.cut = 'cn'
|
|
// } else if (long && long === 'en-us') {
|
|
// this.cut = 'en'
|
|
// }
|
|
// let query = {
|
|
// paramsManifestId: this.paramsManifest.id,
|
|
// paramsTemplateId: this.$route.query.paramsTemplateId,
|
|
// paramsTemplatePublishVersion: 1,
|
|
// cut: this.cut,
|
|
// userTypes: this.currentPersonRole,
|
|
// exportName: this.$route.query.projectName + '(' + this.$route.query.title + ')'
|
|
// }
|
|
// let name = this.$route.query.projectName + '(' + this.$route.query.title + ')' + '.zip'
|
|
// downloadFile('/params/collectManifest/exportAll', name, query, this.selectClear)
|
|
},
|
|
// 导出确定
|
|
handleExportSubmit(){
|
|
this.$refs.dataExportruleForm.validate(valid => {
|
|
if(valid){
|
|
this.$message.success(this.$t('Intheexport'))
|
|
let long = localStorage.getItem('language')
|
|
this.cut = ''
|
|
if (long && long === 'zh-cn') {
|
|
this.cut = 'cn'
|
|
} else if (long && long === 'en-us') {
|
|
this.cut = 'en'
|
|
}
|
|
let query = {
|
|
paramsManifestId: this.paramsManifest.id,
|
|
paramsTemplateId: this.$route.query.paramsTemplateId,
|
|
exportOption:this.dataExportformInline.exportOption,
|
|
paramsTemplatePublishVersion: 1,
|
|
cut: this.cut,
|
|
userTypes: this.currentPersonRole,
|
|
exportName: this.$route.query.projectName + '(' + this.$route.query.title + ')'
|
|
}
|
|
let name = this.$route.query.projectName + '(' + this.$route.query.title + ')' + '.zip'
|
|
downloadFile('/params/collectManifest/exportAll', name, query, this.selectClear)
|
|
}
|
|
})
|
|
},
|
|
handleCancel() {
|
|
this.dataExportformInline = {}
|
|
this.$refs.dataExportruleForm.clearValidate()
|
|
this.dataExportFailed = false
|
|
},
|
|
//填写人导出
|
|
handleExportDre() {
|
|
let long = localStorage.getItem('language')
|
|
this.cut = ''
|
|
if (long && long === 'zh-cn') {
|
|
this.cut = 'cn'
|
|
} else if (long && long === 'en-us') {
|
|
this.cut = 'en'
|
|
}
|
|
console.log(this.formInline)
|
|
let query = {
|
|
paramsManifestId: this.paramsManifest.id,
|
|
cut: this.cut,
|
|
...this.formInline,
|
|
...this.queryParamQuery,
|
|
ids: this.selectedRowKeys.join(','),
|
|
exportName: this.$route.query.projectName + '(' + this.$route.query.title + ')'
|
|
}
|
|
let name = this.$route.query.projectName + '(' + this.$route.query.title + ')' + '.zip'
|
|
downloadFile('/params/collectManifest/exportDre', name, query, this.selectClear)
|
|
},
|
|
getList() {
|
|
this.$refs.CollectionTabel.getTableList(this.queryParamQuery)
|
|
},
|
|
iVisible(val, num) {
|
|
this.importsVisible = val
|
|
if (num == 1) {
|
|
eventBUs.$emit('searchGetData')
|
|
}
|
|
},
|
|
// 高级搜索
|
|
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))
|
|
params.forEach((item) => {
|
|
item.type = matchType
|
|
})
|
|
sqp['queryConditionVOListStr'] = JSON.stringify(params)
|
|
sqp['superQueryMatchType'] = matchType
|
|
}
|
|
console.log(sqp)
|
|
this.queryParamQuery = sqp
|
|
this.$refs.CollectionTabel.pageNo = 1
|
|
// this.$refs.CollectionTabel.getTableList(this.queryParamQuery)
|
|
eventBUs.$emit('getTableList', this.queryParamQuery)
|
|
},
|
|
// 认证工程师 批量删除 权限
|
|
// 仅仅状态为 待发起收集 工程接口人退回 变更 可以批量删除
|
|
homoJurisdictionBatchdelete() {
|
|
this.NotSelectedRowKeysValue = []
|
|
// 定义开关 0为没有权限 1为有权限
|
|
let flag = 1
|
|
if (this.selectedRowKeysValue.length == 0) {
|
|
flag = 2
|
|
this.$message.warning(this.$t('selectLeastOne'))
|
|
} else {
|
|
this.selectedRowKeysValue.forEach((item, index) => {
|
|
if (item.state !== '待发起收集' && item.state !== '工程接口人退回' && item.state !== '变更' && item.state !== 'To be collected' && item.state !== 'Rejected by eng. interface' && item.state !== 'Modify') {
|
|
this.NotSelectedRowKeysValue.push(item)
|
|
flag = 0
|
|
}
|
|
})
|
|
}
|
|
return flag
|
|
},
|
|
// 认证工程师 同步上报库 权限
|
|
// 仅仅状态为 已提交 变更 可以同步上报库
|
|
homoJurisdictionSynchronousLibrary() {
|
|
// 定义开关 0为没有权限 1为有权限
|
|
this.NotSelectedRowKeysValue = []
|
|
let flag = 1
|
|
if (this.selectedRowKeysValue.length == 0) {
|
|
flag = 2
|
|
this.$message.warning(this.$t('selectLeastOne'))
|
|
} else {
|
|
this.selectedRowKeysValue.forEach((item, index) => {
|
|
if (item.state !== '已提交' && item.state !== '变更' && item.state !== 'Submitted' && item.state !== 'Modify') {
|
|
this.NotSelectedRowKeysValue.push(item)
|
|
flag = 0
|
|
}
|
|
})
|
|
}
|
|
return flag
|
|
},
|
|
// 填写人 截至时间 权限
|
|
// 仅仅状态为 可以截至时间
|
|
dreTaskCutOffTimeLibrary() {
|
|
// 定义开关 0为没有权限 1为有权限
|
|
this.NotSelectedRowKeysValue = []
|
|
let flag = 1
|
|
if (this.selectedRowKeysValue.length == 0) {
|
|
flag = 2
|
|
this.$message.warning(this.$t('selectLeastOne'))
|
|
} else {
|
|
this.selectedRowKeysValue.forEach((item, index) => {
|
|
if (item.state !== '待发起收集' && item.state !== 'To be collected') {
|
|
this.NotSelectedRowKeysValue.push(item)
|
|
flag = 0
|
|
}
|
|
})
|
|
}
|
|
return flag
|
|
},
|
|
// 认证工程师 强制撤回 权限
|
|
// 仅仅状态为 待工程接口人处理 填写人退回 可以强制撤回
|
|
homoJurisdictionCompulsoryWithdrawal() {
|
|
// 认证工程师 已提交
|
|
if (this.currentPersonRole == 'homo') {
|
|
this.NotSelectedRowKeysValue = []
|
|
// 定义开关 0为没有权限 1为有权限
|
|
let flag = 1
|
|
if (this.selectedRowKeysValue.length == 0) {
|
|
flag = 2
|
|
this.$message.warning(this.$t('selectLeastOne'))
|
|
} else {
|
|
this.selectedRowKeysValue.forEach((item, index) => {
|
|
console.log(item)
|
|
if (item.state == '已同步至上报库' || item.state == 'Synced to library' || item.state == '待发起收集' || item.state == 'To be collected') {
|
|
this.NotSelectedRowKeysValue.push(item)
|
|
this.jurisdiction = 'homoQZTH'
|
|
flag = 0
|
|
}
|
|
})
|
|
}
|
|
return flag
|
|
// 工程接口人 强制撤回 权限
|
|
// 仅仅状态为 待填写 可以强制撤回
|
|
} else if (this.currentPersonRole == 'sdt') {
|
|
this.NotSelectedRowKeysValue = []
|
|
// 定义开关 0为没有权限 1为有权限
|
|
let flag = 1
|
|
if (this.selectedRowKeysValue.length == 0) {
|
|
flag = 2
|
|
this.$message.warning(this.$t('selectLeastOne'))
|
|
} else {
|
|
this.selectedRowKeysValue.forEach((item, index) => {
|
|
if (item.state !== '待填写' && item.state !== 'To be filled') {
|
|
this.NotSelectedRowKeysValue.push(item)
|
|
this.jurisdiction = 'sdtQZTH'
|
|
flag = 0
|
|
}
|
|
})
|
|
}
|
|
return flag
|
|
//填写人 已提交
|
|
} else if (this.currentPersonRole == 'dre') {
|
|
this.NotSelectedRowKeysValue = []
|
|
// 定义开关 0为没有权限 1为有权限
|
|
let flag = 1
|
|
if (this.selectedRowKeysValue.length == 0) {
|
|
flag = 2
|
|
this.$message.warning(this.$t('selectLeastOne'))
|
|
} else {
|
|
this.selectedRowKeysValue.forEach((item, index) => {
|
|
if (item.state !== '已提交' && item.state !== 'Submitted') {
|
|
this.NotSelectedRowKeysValue.push(item)
|
|
this.jurisdiction = 'dreQZTH'
|
|
flag = 0
|
|
}
|
|
})
|
|
}
|
|
return flag
|
|
}
|
|
},
|
|
// 工程接口人 分配填写人 权限
|
|
// 仅仅状态为 待工程接口人处理 填写人退回 可以分配填写人
|
|
sdtJurisdictionAssigned() {
|
|
// 定义开关 0为没有权限 1为有权限
|
|
this.NotSelectedRowKeysValue = []
|
|
let flag = 1
|
|
if (this.selectedRowKeysValue.length == 0) {
|
|
flag = 2
|
|
this.$message.warning(this.$t('selectLeastOne'))
|
|
} else {
|
|
this.selectedRowKeysValue.forEach((item, index) => {
|
|
if (item.state !== '待工程接口人处理' && item.state !== '填写人退回' && item.state !== 'To be processed by eng. interface' && item.state !== 'Rejected by the applicant') {
|
|
this.NotSelectedRowKeysValue.push(item)
|
|
flag = 0
|
|
}
|
|
})
|
|
}
|
|
return flag
|
|
},
|
|
// 认证工程师 分配填写人 权限
|
|
// 仅仅状态为 待填写 可以分配填写人
|
|
sdtJurisdictionAssignedhomo() {
|
|
// 定义开关 0为没有权限 1为有权限
|
|
this.NotSelectedRowKeysValue = []
|
|
let flag = 1
|
|
if (this.selectedRowKeysValue.length == 0) {
|
|
flag = 2
|
|
this.$message.warning(this.$t('selectLeastOne'))
|
|
} else {
|
|
this.selectedRowKeysValue.forEach((item, index) => {
|
|
console.log(item.state)
|
|
if (item.state !== '待填写' && item.state !== 'To be filled' && item.state !== '填写人退回' && item.state !== 'Rejected by the applicant' && item.state !== '认证工程师退回' && item.state !== 'Rejected by homo engineer') {
|
|
this.NotSelectedRowKeysValue.push(item)
|
|
flag = 0
|
|
}
|
|
})
|
|
}
|
|
console.log(flag)
|
|
return flag
|
|
},
|
|
// 填写人 提交 权限
|
|
// 仅仅状态为 待填写 认证工程师退回 可以提交
|
|
dreJurisdictionSubmit() {
|
|
// 定义开关 0为没有权限 1为有权限
|
|
this.NotSelectedRowKeysValue = []
|
|
let flag = 1
|
|
if (this.selectedRowKeysValue.length == 0) {
|
|
flag = 2
|
|
this.$message.warning(this.$t('selectLeastOne'))
|
|
} else {
|
|
this.selectedRowKeysValue.forEach((item, index) => {
|
|
if (item.state !== '待填写' && item.state !== '认证工程师退回' && item.state !== 'To be filled' && item.state !== 'Rejected by homo engineer') {
|
|
this.NotSelectedRowKeysValue.push(item)
|
|
flag = 0
|
|
}
|
|
})
|
|
}
|
|
return flag
|
|
},
|
|
// 填写人 引用参数 权限
|
|
// 仅仅状态为 待填写 认证工程师退回 可以引用参数
|
|
dreJurisdictionreferenceParameter() {
|
|
this.NotSelectedRowKeysValue = []
|
|
let flag = 1
|
|
if (this.selectedRowKeysValue.length == 0) {
|
|
flag = 2
|
|
this.$message.warning(this.$t('selectLeastOne'))
|
|
} else {
|
|
this.selectedRowKeysValue.forEach((item, index) => {
|
|
if (item.state !== '待填写' && item.state !== '认证工程师退回' && item.state !== 'To be filled' && item.state !== 'Rejected by homo engineer') {
|
|
this.NotSelectedRowKeysValue.push(item)
|
|
flag = 0
|
|
}
|
|
})
|
|
}
|
|
return flag
|
|
},
|
|
LoginUserType(val, currentPersonRole, userType) {
|
|
this.RoleType = []
|
|
if (this.currentPersonRole == '') {
|
|
this.currentPersonRole = currentPersonRole || userType || val[0].value
|
|
}
|
|
this.RoleType = val
|
|
this.RoleType.forEach((item, index) => {
|
|
if (item.value == this.currentPersonRole) {
|
|
this.rolename = item.label
|
|
}
|
|
})
|
|
this.formInlineRoleSwitching.roleSwitchingCode = currentPersonRole || userType || val[0].value
|
|
this.formInlineRoleSwitching = { ...this.formInlineRoleSwitching }
|
|
},
|
|
// 表格所选中得行内容
|
|
rowValue(val) {
|
|
this.selectedRowKeysValue = val
|
|
},
|
|
// 表格所选中得id
|
|
value(val) {
|
|
this.selectedRowKeys = val,
|
|
this.selectedRowKeysArray = val.join(',')
|
|
},
|
|
// 冻结配置
|
|
freezeConfiguration() {
|
|
// 认证工程师 任意状态 都有此权限
|
|
this.areaVisibleFreeze = true
|
|
this.Dateline = {}
|
|
// 获取冻结配置数据
|
|
this.confirmLoading = true
|
|
this.getFreeze(() => {
|
|
this.getLockedConfigIdList()
|
|
})
|
|
},
|
|
getLockedConfigIdList() {
|
|
getAction('/params/collectManifest/getLockedConfigIdList',
|
|
{ paramsManifestId: this.paramsManifest.id }).then((res) => {
|
|
if (res.success) {
|
|
this.Dateline.paramsConfig = res.result
|
|
this.Dateline = { ...this.Dateline }
|
|
} else {
|
|
this.Dateline.paramsConfig = []
|
|
}
|
|
this.confirmLoading = false
|
|
})
|
|
},
|
|
// 冻结配置提交
|
|
handleSubmitFreeze() {
|
|
let _this = this
|
|
let paramsConfig = this.Dateline.paramsConfig === undefined ? '' : this.Dateline.paramsConfig.join(',')
|
|
let param = { paramsManifestId: this.paramsManifest.id, paramsConfigIds: paramsConfig }
|
|
this.textLoading = true
|
|
axios({
|
|
url: '/jero-boot/params/collectManifest/lockConfigColumn',
|
|
method: 'post',
|
|
data: param,
|
|
transformRequest: [function(data) {
|
|
let ret = ''
|
|
for (let it in data) {
|
|
ret += encodeURIComponent(it) + '=' + encodeURIComponent(data[it]) + '&'
|
|
}
|
|
return ret
|
|
}],
|
|
headers: {
|
|
'Content-Type': 'application/x-www-form-urlencoded',
|
|
'X-Access-Token': _this.token
|
|
}
|
|
})
|
|
.then((res) => {
|
|
if (res.data.success) {
|
|
this.textLoading = false
|
|
_this.$message.success(this.$t('OperationSuccessful'))
|
|
this.areaVisibleFreeze = false
|
|
this.$refs.CollectionTabel.getTableList(this.queryParamQuery)
|
|
this.$refs.CollectionTabel.getHeader()
|
|
} else {
|
|
this.textLoading = false
|
|
_this.$message.warning(this.$t('operationFailed'))
|
|
}
|
|
})
|
|
.catch((error) => {
|
|
this.textLoading = false
|
|
})
|
|
},
|
|
// 冻结配置取消
|
|
cancleImportsFreeze() {
|
|
this.areaVisibleFreeze = false
|
|
},
|
|
getFreeze(callback) {
|
|
let _this = this
|
|
let param = { paramsManifestId: this.$route.query.id, configFlag: 1 }
|
|
axios({
|
|
url: '/jero-boot/params/collectManifest/getConfigLableList',
|
|
method: 'post',
|
|
data: param,
|
|
transformRequest: [function(data) {
|
|
let ret = ''
|
|
for (let it in data) {
|
|
ret += encodeURIComponent(it) + '=' + encodeURIComponent(data[it]) + '&'
|
|
}
|
|
return ret
|
|
}],
|
|
headers: {
|
|
'Content-Type': 'application/x-www-form-urlencoded',
|
|
'X-Access-Token': _this.token
|
|
}
|
|
})
|
|
.then((res) => {
|
|
if (res.data.success) {
|
|
this.FreezeList = res.data.result
|
|
callback && callback()
|
|
} else {
|
|
_this.$message.warning(res.data.message)
|
|
_this.confirmLoading = false
|
|
}
|
|
|
|
})
|
|
.catch((error) => {
|
|
_this.confirmLoading = false
|
|
})
|
|
},
|
|
// 调整责任领域
|
|
AdjustareasofresponsibilityClick() {
|
|
if (this.selectedRowKeysValue.length == 0) {
|
|
this.$message.warning(this.$t('selectLeastOne'))
|
|
} else {
|
|
this.Adjustareasofrespon = true
|
|
}
|
|
},
|
|
// 下发收集的权限
|
|
distributionAndCollectionJurisdiction() {
|
|
if (this.selectedRowKeysValue.length == 0) {
|
|
this.$message.warning(this.$t('selectLeastOne'))
|
|
} else {
|
|
this.$refs.areaVisibleTaskCutOffTime.searchData()
|
|
}
|
|
// let homodistributionAndCollection = this.homodistributionAndCollection()
|
|
// if (homodistributionAndCollection == 1) {
|
|
// this.areaVisibleTaskCutOffTime = true
|
|
// // this.distributionAndCollection()
|
|
// } else if (homodistributionAndCollection == 0) {
|
|
// this.visibleoperationFailed = true
|
|
// this.jurisdiction = 'HOMOZFSJ'
|
|
// } else if (homodistributionAndCollection == 3) {
|
|
// this.visibleoperationFailed = true
|
|
// this.NoEngineer = 0
|
|
// }
|
|
},
|
|
// 一键下发收集
|
|
defOneclickCollection() {
|
|
this.$refs.OneclickCollection.searchData()
|
|
// this.OneclickCollection = true
|
|
},
|
|
// 引用参数列
|
|
Referenceparametercolumn() {
|
|
this.parametercolumn = true
|
|
},
|
|
Updateparametercolumn() {
|
|
let data = JSON.parse(JSON.stringify(this.$refs.CollectionTabel.dataSource))
|
|
let referencesCol = []
|
|
let postDate = []
|
|
let colunmnFlag = ''
|
|
this.colunmnFlag = false
|
|
data.forEach((item, index) => {
|
|
if (!item.referencesCol) {
|
|
this.colunmnFlag = true
|
|
}
|
|
referencesCol.push({
|
|
referencesCol: item.referencesCol,
|
|
id: item.id
|
|
})
|
|
})
|
|
if (this.colunmnFlag) {
|
|
this.$message.warning(this.$t('columnfirst'))
|
|
return
|
|
}
|
|
console.log(referencesCol)
|
|
// for (let i = 0; i < referencesCol.length; i++) {
|
|
// let postDateobj = {}
|
|
// let itemIn = Object.keys(referencesCol[i])
|
|
// for (let j = 0; j < itemIn.length; j++) {
|
|
// if (itemIn[j] !== 'sdt' && referencesCol[i][itemIn[j]].list) {
|
|
// if (referencesCol[i][itemIn[j]] instanceof Object && !(referencesCol[i][itemIn[j]] instanceof Array)) {
|
|
// postDateobj[itemIn[j]] = referencesCol[i][itemIn[j]]
|
|
// for (let k = 0; k < referencesCol[i][itemIn[j]].list.length; k++) {
|
|
// if (referencesCol[i][itemIn[j]].list[k].type == 'pull_more' && referencesCol[i][itemIn[j]].list[k].dataValue instanceof Array) {
|
|
// referencesCol[i][itemIn[j]].list[k].dataValue = referencesCol[i][itemIn[j]].list[k].dataValue.join(',')
|
|
// }
|
|
// if (referencesCol[i][itemIn[j]].list[k].type == 'text' && referencesCol[i][itemIn[j]].list[k].dataValue !== null) {
|
|
// referencesCol[i][itemIn[j]].list[k].dataValue = referencesCol[i][itemIn[j]].list[k].dataValue.toString()
|
|
// }
|
|
// }
|
|
// }
|
|
// }
|
|
// }
|
|
// postDateobj.id = referencesCol[i].id
|
|
// postDate.push(postDateobj)
|
|
// }
|
|
let configDataList = []
|
|
for (let i = 0; i < referencesCol.length; i++) {
|
|
configDataList.push({
|
|
id: referencesCol[i].id
|
|
})
|
|
let key = Object.keys(referencesCol[i].referencesCol.paramsConfigData)
|
|
let value = referencesCol[i].referencesCol.paramsConfigData
|
|
for (let j = 0; j < key.length; j++) {
|
|
let keyName = key[j]
|
|
for (let k = 0; k < value[keyName].length; k++) {
|
|
if (value[keyName][k].type == 'pull_more') {
|
|
value[keyName][k].dataValue = value[keyName][k].dataValue.join(',')
|
|
}
|
|
}
|
|
configDataList[i][keyName] = value[keyName]
|
|
}
|
|
}
|
|
let query = {
|
|
configDataList: configDataList,
|
|
paramsManifestId: this.paramsManifest.id
|
|
}
|
|
postAction('/params/collectManifest/updateReferencesCol', query).then((res) => {
|
|
if (res.success) {
|
|
this.GetgetTableList()
|
|
this.$message.success(this.$t('OperationSuccessful'))
|
|
} else {
|
|
this.$message.warning(this.$t('operationFailed'))
|
|
}
|
|
})
|
|
},
|
|
onCheckAllChange(e) {
|
|
let selectedValue = ['nio_number', 'params_name', 'operation']
|
|
this.checkedList = e.target.checked ? this.customizeList.map(item => item.field) : selectedValue
|
|
this.selectedValue = this.checkedList
|
|
this.indeterminate = false
|
|
},
|
|
getcustomizeList(item) {
|
|
let params = {
|
|
paramsManifestId: this.$route.query.id,
|
|
projectName: this.$route.query.projectName,
|
|
flag: '7'
|
|
}
|
|
getAction('params/collectManifest/getHeader', params).then((res) => {
|
|
if (res.success) {
|
|
let List = []
|
|
let sList = []
|
|
res.result.forEach((item, index) => {
|
|
if (!item.isLock) {
|
|
if (item.headFieldCn == '操作') {
|
|
item.field = 'operation'
|
|
item.disabled = true
|
|
} else if (item.headFieldCn == 'NIO编号' || item.headFieldCn == '参数名称') {
|
|
item.disabled = true
|
|
}
|
|
List.push(item)
|
|
}
|
|
if (item.isLock) {
|
|
sList.push(item)
|
|
}
|
|
})
|
|
this.customizeList = List
|
|
this.statuList = sList
|
|
}
|
|
})
|
|
if (item) {
|
|
console.log(item)
|
|
this.checkedList = item
|
|
}
|
|
},
|
|
onChange() {
|
|
this.selectedValue = this.checkedList
|
|
},
|
|
getcustomize() {
|
|
this.customizevisible = true
|
|
},
|
|
cancel() {
|
|
this.customizevisible = false
|
|
},
|
|
handleSubmitcustomize() {
|
|
let list = []
|
|
let uniqueArray = this.selectedValue.filter((item, index, array) => {
|
|
return array.indexOf(item) === index
|
|
})
|
|
uniqueArray.forEach(item => {
|
|
this.customizeList.forEach((val, index) => {
|
|
if (item == val.field) {
|
|
// val.sort = index + 1
|
|
val.dbFieldName = val.db_field_name
|
|
val.dbFieldTxt = val.db_field_txt
|
|
list.push(val)
|
|
}
|
|
})
|
|
})
|
|
this.confirmLoading = true
|
|
let headCustomEOList = JSON.parse(JSON.stringify(list)).concat(this.statuList)
|
|
let query = {
|
|
headCustomEOList: headCustomEOList
|
|
}
|
|
postAction('head/headCustomEO/add', query).then((res) => {
|
|
if (res.success) {
|
|
this.confirmLoading = false
|
|
this.$message.success(this.$t('OperationSuccessful'))
|
|
this.customizevisible = false
|
|
this.$refs.CollectionTabel.getHeader()
|
|
} else {
|
|
this.$message.warning(this.$t('operationFailed'))
|
|
this.confirmLoading = false
|
|
this.customizevisible = false
|
|
}
|
|
})
|
|
},
|
|
// // 下发收集---请求接口
|
|
// distributionAndCollection() {
|
|
//
|
|
// let _array = []
|
|
// this.selectedRowKeysValue.forEach((item, index) => {
|
|
// _array.push(item.id)
|
|
// })
|
|
// let _this = this
|
|
// let param = {
|
|
// paramsManifestId: this.$route.query.id,
|
|
// projectId: this.$route.query.projectId,
|
|
// ids: _array.join(',')
|
|
// }
|
|
// this.textLoading = true
|
|
// axios({
|
|
// url: '/jero-boot/params/collectManifest/issueCollection',
|
|
// method: 'post',
|
|
// data: param,
|
|
// transformRequest: [function(data) {
|
|
// let ret = ''
|
|
// for (let it in data) {
|
|
// ret += encodeURIComponent(it) + '=' + encodeURIComponent(data[it]) + '&'
|
|
// }
|
|
// return ret
|
|
// }],
|
|
// headers: {
|
|
// 'Content-Type': 'application/x-www-form-urlencoded',
|
|
// 'X-Access-Token': _this.token
|
|
// }
|
|
// })
|
|
// .then((res) => {
|
|
// if (res.data.success) {
|
|
// _this.$message.success(this.$t('OperationSuccessful'))
|
|
// _this.areaVisible = false
|
|
// this.textLoading = false
|
|
// _this.GetgetTableList()
|
|
// } else {
|
|
// this.textLoading = false
|
|
// _this.$message.warning(this.$t('operationFailed'))
|
|
// }
|
|
// })
|
|
// .catch((error) => {
|
|
// this.textLoading = false
|
|
// })
|
|
// },
|
|
// 同步上报库 权限
|
|
handleSynchronousReportLibraryJurisdiction() {
|
|
let homoJurisdictionSynchronousLibrary = this.homoJurisdictionSynchronousLibrary()
|
|
if (homoJurisdictionSynchronousLibrary == 1) {
|
|
this.handleSynchronousReportLibrary()
|
|
} else if (homoJurisdictionSynchronousLibrary == 0) {
|
|
this.visibleoperationFailed = true
|
|
this.jurisdiction = 'HOMOTBSBK'
|
|
this.NoEngineer = 1
|
|
}
|
|
},
|
|
// 同步上报库
|
|
handleSynchronousReportLibrary() {
|
|
this.areaVisibsynchronous = true
|
|
},
|
|
// 添加
|
|
handleAdd() {
|
|
// 认证工程师 任意状态 都有此权限
|
|
this.areaVisible = true
|
|
},
|
|
// 提交
|
|
handleSubmit() {
|
|
// 填写人 权限
|
|
let dreJurisdictionSubmit = this.dreJurisdictionSubmit()
|
|
console.log(dreJurisdictionSubmit)
|
|
if (dreJurisdictionSubmit == 1) {
|
|
this.ishandleSubmit()
|
|
} else if (dreJurisdictionSubmit == 0) {
|
|
this.visibleoperationFailed = true
|
|
this.jurisdiction = 'DREYYCS'
|
|
this.NoEngineer = 1
|
|
}
|
|
},
|
|
getDataSource(data) {
|
|
this.dataSource = data
|
|
},
|
|
handlePreservation(num) {
|
|
let _this = this
|
|
let postDate = []
|
|
let data = JSON.parse(JSON.stringify(this.$refs.CollectionTabel.dataSource))
|
|
let selectedRowKeysValue = []
|
|
data.forEach(res => {
|
|
if (res.state == 'To be filled' || res.state == '待填写' || res.state == '认证工程师退回' ||
|
|
res.state == 'Rejected by homo engineer') {
|
|
selectedRowKeysValue.push(res)
|
|
}
|
|
})
|
|
// for (let i = 0; i < selectedRowKeysValue.length; i++) {
|
|
// let postDateobj = {}
|
|
// let itemIn = Object.keys(selectedRowKeysValue[i])
|
|
// for (let j = 0; j < itemIn.length; j++) {
|
|
// if (itemIn[j] !== 'sdt' && selectedRowKeysValue[i][itemIn[j]].list) {
|
|
// if (selectedRowKeysValue[i][itemIn[j]] instanceof Object && !(selectedRowKeysValue[i][itemIn[j]] instanceof Array)) {
|
|
// postDateobj[itemIn[j]] = selectedRowKeysValue[i][itemIn[j]]
|
|
// for (let k = 0; k < selectedRowKeysValue[i][itemIn[j]].list.length; k++) {
|
|
// if (selectedRowKeysValue[i][itemIn[j]].list[k].type == 'pull_more') {
|
|
// selectedRowKeysValue[i][itemIn[j]].list[k].dataValue = selectedRowKeysValue[i][itemIn[j]].list[k].dataValue.join(',')
|
|
// }
|
|
// if (selectedRowKeysValue[i][itemIn[j]].list[k].type == 'text' && selectedRowKeysValue[i][itemIn[j]].list[k].dataValue !== null) {
|
|
// selectedRowKeysValue[i][itemIn[j]].list[k].dataValue = selectedRowKeysValue[i][itemIn[j]].list[k].dataValue.toString()
|
|
// }
|
|
// }
|
|
// }
|
|
// }
|
|
// }
|
|
// postDateobj.id = selectedRowKeysValue[i].id
|
|
// delete postDateobj.referencesCol
|
|
// postDate.push(postDateobj)
|
|
// }
|
|
// console.log(postDate)
|
|
if (selectedRowKeysValue && selectedRowKeysValue.length > 0) {
|
|
if (num && num == 1) {
|
|
this.textLoading = true
|
|
}
|
|
let configDataList = []
|
|
for (let i = 0; i < selectedRowKeysValue.length; i++) {
|
|
configDataList.push({
|
|
id: selectedRowKeysValue[i].id
|
|
})
|
|
if (selectedRowKeysValue[i].configIds && selectedRowKeysValue[i].configIds.length > 0) {
|
|
for (let j = 0; j < selectedRowKeysValue[i].configIds.length; j++) {
|
|
let keyIndex = Object.keys(selectedRowKeysValue[i])
|
|
for (let k = 0; k < keyIndex.length; k++) {
|
|
if (keyIndex[k] == selectedRowKeysValue[i].configIds[j]) {
|
|
let keyName = keyIndex[k]
|
|
configDataList[i][keyName] = selectedRowKeysValue[i][keyName]
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
// return
|
|
if (configDataList && configDataList.length > 0) {
|
|
configDataList.forEach(res => {
|
|
Object.keys(res).forEach(val => {
|
|
if (res[val] && res[val].paramsConfigData) {
|
|
let paramsConfigData = res[val].paramsConfigData
|
|
Object.keys(paramsConfigData).forEach((ol, index) => {
|
|
paramsConfigData[ol][0].orderNum = index
|
|
paramsConfigData[ol].forEach(item => {
|
|
if (item.type == 'pull_more') {
|
|
item.dataValue = item.dataValue.join(',')
|
|
}
|
|
})
|
|
})
|
|
}
|
|
})
|
|
})
|
|
}
|
|
let query = {
|
|
// ...configDataList,
|
|
configDataList: configDataList,
|
|
paramsManifestId: this.paramsManifest.id
|
|
}
|
|
postAction('/params/collectManifest/save', query).then((res) => {
|
|
if (res.success) {
|
|
if (num && num == 1) {
|
|
_this.$message.success(_this.$t('OperationSuccessful'))
|
|
this.textLoading = false
|
|
}
|
|
clearTimeout(this.timeBatch)
|
|
this.timeBatch = setTimeout(() => {
|
|
if (this.currentPersonRole == 'dre') {
|
|
this.handlePreservation()
|
|
}
|
|
}, 10000)
|
|
// if (this.currentPersonRole == 'dre') {
|
|
// this.timeBatch = setTimeout(() => {
|
|
// this.handlePreservation();
|
|
// }, 10000);
|
|
// var interval = setInterval(this.handlePreservation(),10000);
|
|
// /* if 5 minutes no operation then logout */
|
|
// var maxTime = 120; // seconds
|
|
// var time = maxTime;
|
|
// $('body').on('keydown mousemove mousedown', function(e) {
|
|
// time = maxTime; // reset
|
|
// });
|
|
// var intervalId = setInterval(function() {
|
|
// time--;
|
|
// if (time <= 0) {
|
|
// ShowInvalidLoginMessage();
|
|
// clearInterval(intervalId);
|
|
// }
|
|
// }, 10000)
|
|
// function ShowInvalidLoginMessage() {
|
|
// // 停止定时器
|
|
// clearInterval(interval);
|
|
// }
|
|
// }
|
|
} else {
|
|
if (num && num == 1) {
|
|
_this.$message.warning(_this.$t('operationFailed'))
|
|
this.textLoading = false
|
|
}
|
|
}
|
|
})
|
|
} else {
|
|
if (num && num == 1) {
|
|
this.$message.warning(this.$t('theCurrentListSaved'))
|
|
}
|
|
}
|
|
},
|
|
// 提交数据
|
|
ishandleSubmit() {
|
|
let _this = this
|
|
let postDate = []
|
|
let selectedRowKeysValue = JSON.parse(JSON.stringify(this.selectedRowKeysValue))
|
|
// for (let i = 0; i < selectedRowKeysValue.length; i++) {
|
|
// let postDateobj = {}
|
|
// let itemIn = Object.keys(selectedRowKeysValue[i])
|
|
// for (let j = 0; j < itemIn.length; j++) {
|
|
// if (itemIn[j] !== 'sdt' && selectedRowKeysValue[i][itemIn[j]].list) {
|
|
// if (selectedRowKeysValue[i][itemIn[j]] instanceof Object && !(selectedRowKeysValue[i][itemIn[j]] instanceof Array)) {
|
|
// postDateobj[itemIn[j]] = selectedRowKeysValue[i][itemIn[j]]
|
|
// for (let k = 0; k < selectedRowKeysValue[i][itemIn[j]].list.length; k++) {
|
|
// if (selectedRowKeysValue[i][itemIn[j]].list[k].type == 'pull_more') {
|
|
// selectedRowKeysValue[i][itemIn[j]].list[k].dataValue = selectedRowKeysValue[i][itemIn[j]].list[k].dataValue.join(',')
|
|
// }
|
|
// if (selectedRowKeysValue[i][itemIn[j]].list[k].type == 'text' && selectedRowKeysValue[i][itemIn[j]].list[k].dataValue !== null) {
|
|
// selectedRowKeysValue[i][itemIn[j]].list[k].dataValue = selectedRowKeysValue[i][itemIn[j]].list[k].dataValue.toString()
|
|
// }
|
|
// if (!selectedRowKeysValue[i][itemIn[j]].list[k].dataValue && selectedRowKeysValue[i][itemIn[j]].list[k].isMust == '1'
|
|
// && selectedRowKeysValue[i][itemIn[j]].list[k].isLock == '0') {
|
|
// this.$message.warning(selectedRowKeysValue[i].nioNumber + ',' + this.$t('requiredParametersEmpty'))
|
|
// return
|
|
// }
|
|
// }
|
|
// }
|
|
// }
|
|
// }
|
|
// postDateobj.id = selectedRowKeysValue[i].id
|
|
// postDate.push(postDateobj)
|
|
// }
|
|
let configDataList = []
|
|
for (let i = 0; i < selectedRowKeysValue.length; i++) {
|
|
configDataList.push({
|
|
id: selectedRowKeysValue[i].id
|
|
})
|
|
if (selectedRowKeysValue[i].configIds && selectedRowKeysValue[i].configIds.length > 0) {
|
|
for (let j = 0; j < selectedRowKeysValue[i].configIds.length; j++) {
|
|
let keyIndex = Object.keys(selectedRowKeysValue[i])
|
|
for (let k = 0; k < keyIndex.length; k++) {
|
|
if (keyIndex[k] == selectedRowKeysValue[i].configIds[j]) {
|
|
let keyName = keyIndex[k]
|
|
configDataList[i][keyName] = selectedRowKeysValue[i][keyName]
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
// return
|
|
if (configDataList && configDataList.length > 0) {
|
|
for (let i = 0; i < configDataList.length; i++) {
|
|
let res = Object.keys(configDataList[i])
|
|
for (let j = 0; j < res.length; j++) {
|
|
let key = res[j]
|
|
if (configDataList[i][key] && configDataList[i][key].paramsConfigData) {
|
|
let paramsConfigData = configDataList[i][key].paramsConfigData
|
|
let paramsConfigDataQuery = Object.keys(paramsConfigData)
|
|
for (let k = 0; k < paramsConfigDataQuery.length; k++) {
|
|
let keyName = paramsConfigDataQuery[k]
|
|
paramsConfigData[keyName][0].orderNum = k
|
|
let keyNameOne = paramsConfigData[keyName]
|
|
for (let l = 0; l < keyNameOne.length; l++) {
|
|
if (keyNameOne[l].type == 'pull_more') {
|
|
keyNameOne[l].dataValue = keyNameOne[l].dataValue.join(',')
|
|
}
|
|
if (!keyNameOne[l].dataValue && keyNameOne[l].isMust == '1' && keyNameOne[l].isLock == '0') {
|
|
this.$message.warning(selectedRowKeysValue[i].nioNumber + ',' + this.$t('requiredParametersEmpty'))
|
|
return
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
// configDataList.forEach(res => {
|
|
// Object.keys(res).forEach(val => {
|
|
// if (res[val] && res[val].paramsConfigData) {
|
|
// let paramsConfigData = res[val].paramsConfigData
|
|
// Object.keys(paramsConfigData).forEach((ol, index) => {
|
|
// paramsConfigData[ol][0].orderNum = index
|
|
// paramsConfigData[ol].forEach(item => {
|
|
// if (item.type == 'pull_more') {
|
|
// item.dataValue = item.dataValue.join(',')
|
|
// }
|
|
// })
|
|
// })
|
|
// }
|
|
// })
|
|
// })
|
|
}
|
|
// let configDataList = { configDataList: postDate }
|
|
if (this.selectedRowKeys.length == 0) {
|
|
this.$message.warning(this.$t('selectLeastOne'))
|
|
} else {
|
|
let _configDataListNo = []
|
|
this.$confirm({
|
|
content: _this.$t('Areyousureparameteritems'),
|
|
onOk() {
|
|
let query = {
|
|
configDataList: configDataList,
|
|
paramsManifestId: _this.paramsManifest.id
|
|
}
|
|
postAction(_this.url.add, query).then((res) => {
|
|
if (res.success) {
|
|
_this.$message.success(_this.$t('OperationSuccessful'))
|
|
_this.GetgetTableList()
|
|
} else {
|
|
_this.$message.warning(_this.$t('operationFailed'))
|
|
}
|
|
})
|
|
}
|
|
})
|
|
}
|
|
},
|
|
returnDataJurisdiction() {
|
|
// 退回的状态权限
|
|
let homoJurisdictionReturn = this.homoJurisdictionReturn()
|
|
console.log(homoJurisdictionReturn, 'homoJurisdictionReturn')
|
|
if (homoJurisdictionReturn == 1) {
|
|
this.returnData()
|
|
} else if (homoJurisdictionReturn == 0) {
|
|
this.visibleoperationFailed = true
|
|
this.returnData()
|
|
}
|
|
},
|
|
// 退回
|
|
returnData() {
|
|
// todo 退回没有选择数据
|
|
let _array = []
|
|
if (this.currentPersonRole == 'homo') {
|
|
this.selectedRowKeysValue = this.selectedRowKeysValue.filter(item => item.state == '已提交' || item.state == 'Submitted')
|
|
} else if (this.currentPersonRole == 'sdt') {
|
|
this.selectedRowKeysValue = this.selectedRowKeysValue.filter(item => item.state == '待工程接口人处理' || item.state == '填写人退回' || item.state == 'To be processed by eng. interface' || item.state == 'Rejected by the applicant')
|
|
} else if (this.currentPersonRole == 'dre') {
|
|
this.selectedRowKeysValue = this.selectedRowKeysValue.filter(item => item.state == '待填写' || item.state == '认证工程师退回' || item.state == 'To be filled' || item.state == 'Rejected by homo engineer')
|
|
}
|
|
this.selectedRowKeysValue.forEach((item, index) => {
|
|
_array.push(item.id)
|
|
})
|
|
if (_array.length == 0) {
|
|
return
|
|
}
|
|
let _this = this
|
|
let param = {
|
|
ids: _array.join(','),
|
|
currentPersonRole: this.currentPersonRole,
|
|
paramsManifestId: this.$route.query.id
|
|
}
|
|
this.textLoading = true
|
|
axios({
|
|
url: '/jero-boot/params/collectManifest/back',
|
|
method: 'post',
|
|
data: param,
|
|
transformRequest: [function(data) {
|
|
let ret = ''
|
|
for (let it in data) {
|
|
ret += encodeURIComponent(it) + '=' + encodeURIComponent(data[it]) + '&'
|
|
}
|
|
return ret
|
|
}],
|
|
headers: {
|
|
'Content-Type': 'application/x-www-form-urlencoded',
|
|
'X-Access-Token': _this.token
|
|
}
|
|
})
|
|
.then((res) => {
|
|
if (res.data.success) {
|
|
this.textLoading = false
|
|
_this.$message.success(_this.$t('OperationSuccessful'))
|
|
_this.GetgetTableList()
|
|
_this.selectedRowKeysValue = []
|
|
} else {
|
|
this.textLoading = false
|
|
_this.$message.warning(_this.$t('operationFailed'))
|
|
}
|
|
})
|
|
.catch((error) => {
|
|
this.textLoading = false
|
|
})
|
|
},
|
|
// 强制撤回权限
|
|
compulsoryWithdrawaljurisdiction() {
|
|
let homoJurisdictionCompulsoryWithdrawal = this.homoJurisdictionCompulsoryWithdrawal()
|
|
if (homoJurisdictionCompulsoryWithdrawal === 1) {
|
|
this.compulsoryWithdrawal()
|
|
} else if (homoJurisdictionCompulsoryWithdrawal === 0) {
|
|
this.visibleoperationFailed = true
|
|
}
|
|
},
|
|
drawerhandleCancel(val) {
|
|
console.log(11131)
|
|
this.parametercolumn = false
|
|
},
|
|
// 强制撤回
|
|
compulsoryWithdrawal() {
|
|
let _array = []
|
|
this.selectedRowKeysValue.forEach((item, index) => {
|
|
_array.push(item.id)
|
|
})
|
|
let _this = this
|
|
let param = {
|
|
ids: _array.join(','),
|
|
paramsManifestId: this.$route.query.id,
|
|
projectId: this.$route.query.projectId
|
|
|
|
}
|
|
let url = ''
|
|
if (this.currentPersonRole == 'homo') {
|
|
url = '/jero-boot/params/collectManifest/mandatoryWithdraw'
|
|
} else {
|
|
url = '/jero-boot/params/collectManifest/withdraw'
|
|
}
|
|
this.$confirm({
|
|
title: this.$t('columnforced'),
|
|
content: '',
|
|
onOk:
|
|
async () => {
|
|
this.textLoading = true
|
|
axios({
|
|
url: url,
|
|
method: 'post',
|
|
data: param,
|
|
transformRequest: [function(data) {
|
|
let ret = ''
|
|
for (let it in data) {
|
|
ret += encodeURIComponent(it) + '=' + encodeURIComponent(data[it]) + '&'
|
|
}
|
|
return ret
|
|
}],
|
|
headers: {
|
|
'Content-Type': 'application/x-www-form-urlencoded',
|
|
'X-Access-Token': _this.token
|
|
}
|
|
})
|
|
.then((res) => {
|
|
if (res.data.success) {
|
|
this.textLoading = false
|
|
_this.$message.success(_this.$t('OperationSuccessful'))
|
|
_this.GetgetTableList()
|
|
_this.selectedRowKeysValue = []
|
|
} else {
|
|
this.textLoading = false
|
|
_this.$message.warning(_this.$t('operationFailed'))
|
|
}
|
|
})
|
|
.catch((error) => {
|
|
this.textLoading = false
|
|
})
|
|
}
|
|
})
|
|
},
|
|
// 分配填写人
|
|
assignedBy() {
|
|
let sdtJurisdictionAssigned = this.sdtJurisdictionAssigned()
|
|
// 工程接口人
|
|
if (sdtJurisdictionAssigned == 1) {
|
|
this.areaVisibleAssignedby = true
|
|
} else if (sdtJurisdictionAssigned == 0) {
|
|
this.visibleoperationFailed = true
|
|
this.jurisdiction = 'SDTFPTXR'
|
|
}
|
|
},
|
|
// 认证分配填写人
|
|
assignedByHomo() {
|
|
let sdtJurisdictionAssigned = this.sdtJurisdictionAssignedhomo()
|
|
// 工程接口人
|
|
if (sdtJurisdictionAssigned == 1) {
|
|
this.areaVisibleAssignedbyhomo = true
|
|
} else if (sdtJurisdictionAssigned == 0) {
|
|
this.visibleoperationFailed = true
|
|
this.jurisdiction = 'SDTFPTXRHOMO'
|
|
}
|
|
},
|
|
batchUpdateDeadlineClick() {
|
|
if (this.selectedRowKeysValue && this.selectedRowKeysValue.length > 0) {
|
|
this.$refs.batchUpdateDeadlineRef.getData(JSON.parse(JSON.stringify(this.selectedRowKeysValue)))
|
|
} else {
|
|
this.$message.warning(this.$t('selectLeastOne'))
|
|
}
|
|
},
|
|
batchUpdateDeadlineForm() {
|
|
this.GetgetTableList()
|
|
},
|
|
// 分配填写人确定后弹框关闭
|
|
areaVisibleAssignedbyflag(val) {
|
|
this.areaVisibleAssignedby = val
|
|
},
|
|
// 认证分配填写人确定后弹框关闭
|
|
areaVisibleAssignedbyflaghomo(val) {
|
|
this.areaVisibleAssignedbyhomo = val
|
|
},
|
|
// 截止时间
|
|
// TaskCutOffTimeLibrary() {
|
|
// let dreTaskCutOffTimeLibrary = this.dreTaskCutOffTimeLibrary()
|
|
// if (dreTaskCutOffTimeLibrary == 1) {
|
|
// this.areaVisibleTaskCutOffTime = true
|
|
// } else if (dreTaskCutOffTimeLibrary == 0) {
|
|
// this.visibleoperationFailed = true
|
|
// this.jurisdiction = 'HOMOJZSJ'
|
|
// }
|
|
// },
|
|
// 截至时间确定弹框关闭
|
|
areaVisibleTaskCutOffTimeflag(val) {
|
|
this.$refs.CollectionTabel.getTableList(this.queryParamQuery)
|
|
},
|
|
areaVisibleTaskCutOffTimeAll(val) {
|
|
this.$refs.CollectionTabel.getTableList(this.queryParamQuery)
|
|
},
|
|
AdjustareasofresponAll(val) {
|
|
console.log(val)
|
|
this.Adjustareasofrespon = val
|
|
this.$refs.CollectionTabel.getTableList(this.queryParamQuery)
|
|
},
|
|
//引用参数
|
|
referenceparameter() {
|
|
let dreJurisdictionreferenceParameter = this.dreJurisdictionreferenceParameter()
|
|
if (dreJurisdictionreferenceParameter == 1) {
|
|
this.areaVisiblereferenceparameter = true
|
|
} else if (dreJurisdictionreferenceParameter == 0) {
|
|
this.visibleoperationFailed = true
|
|
this.jurisdiction = 'DREYYCS'
|
|
}
|
|
},
|
|
listReset() {
|
|
this.formInline = {}
|
|
},
|
|
handleModule() {
|
|
|
|
},
|
|
handleCody() {
|
|
},
|
|
searchQuery() {
|
|
this.$refs.CollectionTabel.pageNo = 1
|
|
this.$refs.CollectionTabel.getTableList()
|
|
},
|
|
searchReset() {
|
|
this.formInline = {}
|
|
this.queryParamQuery = {}
|
|
this.$refs.CollectionTabel.pageNo = 1
|
|
this.$refs.CollectionTabel.getTableListReset()
|
|
this.$refs.globalAdvancedQueryRef.handleReset()
|
|
// this.$refs.globalAdvancedQueryRef.emitCallback()
|
|
},
|
|
// 批量删除 -- 与下发收集一致
|
|
handleDelJurisdiction() {
|
|
let homoJurisdictionBatchdelete = this.homoJurisdictionBatchdelete()
|
|
if (homoJurisdictionBatchdelete == 1) {
|
|
this.handleDel()
|
|
} else if (homoJurisdictionBatchdelete == 0) {
|
|
this.visibleoperationFailed = true
|
|
this.jurisdiction = 'HOMOZFSJ'
|
|
}
|
|
},
|
|
handleDel() {
|
|
let param = {
|
|
ids: this.selectedRowKeysArray,
|
|
paramsManifestId: this.$route.query.id
|
|
}
|
|
if (this.selectedRowKeys.length > 0) {
|
|
let _this = this
|
|
this.$confirm({
|
|
content: this.$t('ConfirmBatchDeletion'),
|
|
onOk() {
|
|
_this.textLoading = true
|
|
postAction('/params/collectManifest/deleteBatch', param).then((res) => {
|
|
if (res.success) {
|
|
_this.$message.success(_this.$t('OperationSuccessful'))
|
|
_this.selectedRowKeys = []
|
|
console.log(111)
|
|
_this.$refs.CollectionTabel.getTableList(_this.queryParamQuery)
|
|
_this.textLoading = false
|
|
} else {
|
|
_this.textLoading = false
|
|
_this.$message.warning(this.$t('operationFailed'))
|
|
}
|
|
})
|
|
}
|
|
})
|
|
} else {
|
|
this.$message.warning(this.$t('selectLeastOne'))
|
|
}
|
|
},
|
|
pageOnChange() {
|
|
|
|
},
|
|
SizeChange() {
|
|
|
|
}
|
|
},
|
|
destroyed() {
|
|
// 离开页面结束定时器
|
|
clearTimeout(this.timeBatch)
|
|
}
|
|
}
|
|
</script>
|
|
<style lang="less">
|
|
.popconfirmIndex {
|
|
z-index: 999;
|
|
}
|
|
|
|
.popconfirmIndex .ant-popover-buttons {
|
|
display: none !important;
|
|
}
|
|
|
|
.popconfirmIndex .anticon-exclamation-circle {
|
|
display: none !important;
|
|
}
|
|
|
|
::v-deep .ant-table-fixed-header .ant-table-body-inner {
|
|
overflow: visible;
|
|
}
|
|
|
|
popconfirmmize {
|
|
z-index: 999;
|
|
}
|
|
|
|
::v-deep .popconfirmmize .ant-popover-buttons {
|
|
display: none !important;
|
|
}
|
|
|
|
.popconfirmmize .anticon-exclamation-circle {
|
|
display: none !important;
|
|
}
|
|
|
|
.popconfirmmize .ant-popover-message {
|
|
padding: 4px 0 36px !important;
|
|
}
|
|
|
|
::v-deep .ant-popover-buttons {
|
|
display: none !important;
|
|
}
|
|
</style>
|
|
<style lang="less" scoped>
|
|
@import '~@assets/less/common.less';
|
|
|
|
.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;
|
|
}
|
|
|
|
.operator-text-title {
|
|
cursor: pointer;
|
|
margin-right: 22px;
|
|
font-size: 14px;
|
|
font-weight: 400;
|
|
color: #040B29;
|
|
margin-bottom: 22px;
|
|
}
|
|
|
|
.box-title-text-index {
|
|
line-height: 1.4;
|
|
display: flex;
|
|
}
|
|
|
|
.title-text-Comment {
|
|
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: 36px;
|
|
}
|
|
.itemModel {
|
|
width: 100%;
|
|
display: inline-block;
|
|
margin-top: 2px;
|
|
}
|
|
.box-input .ant-select-selection {
|
|
height: 38px !important;
|
|
}
|
|
|
|
.itemitem {
|
|
width: 250px;
|
|
}
|
|
|
|
.box-input .ant-select-selection__rendered {
|
|
line-height: 38px;
|
|
}
|
|
|
|
.Required {
|
|
color: red;
|
|
}
|
|
|
|
.customize-text {
|
|
/*height: 1533px;*/
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: flex-start;
|
|
}
|
|
|
|
.customize-text-title {
|
|
margin-left: 0;
|
|
font-size: 14px;
|
|
font-weight: 400;
|
|
color: #040B29;
|
|
margin-bottom: 22px;
|
|
}
|
|
|
|
.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;
|
|
}
|
|
|
|
.ant-table-placeholder {
|
|
padding: 0;
|
|
border-top: none;
|
|
}
|
|
|
|
.itemModelComment .ant-form-item-control-wrapper {
|
|
width: 100% !important;
|
|
}
|
|
|
|
.second {
|
|
padding: 0 !important;
|
|
}
|
|
|
|
.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 {
|
|
margin-top: 68px;
|
|
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;
|
|
}
|
|
}
|
|
|
|
.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;
|
|
z-index: 1000;
|
|
|
|
.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;
|
|
}
|
|
|
|
.Virtual-detail-title-right {
|
|
float: right;
|
|
}
|
|
|
|
.doc-detail-right {
|
|
width: 800px;
|
|
line-height: 68px;
|
|
display: flex;
|
|
}
|
|
}
|
|
|
|
.Virtual-detail-content {
|
|
padding: 0 32px 0 32px;
|
|
box-sizing: border-box;
|
|
font-size: 16px;
|
|
|
|
.box-title-text-add {
|
|
line-height: 1.4;
|
|
}
|
|
|
|
.title-text-add {
|
|
display: inline-block;
|
|
width: 100%;
|
|
font-weight: 500;
|
|
margin-right: 16px;
|
|
height: 42px;
|
|
line-height: 42px;
|
|
}
|
|
|
|
}
|
|
}
|
|
|
|
.text-wraning {
|
|
word-break: break-word;
|
|
}
|
|
|
|
.operator-text-title-color {
|
|
color: #00B3BE;
|
|
}
|
|
|
|
</style>
|
|
<style lang='less'>
|
|
.popconfirmIndex .ant-popover-message-title {
|
|
margin-bottom: 50px;
|
|
}
|
|
</style>
|
|
<style>
|
|
.popconfirmDetailsText {
|
|
z-index: 1000;
|
|
top: 42px !important;
|
|
}
|
|
|
|
.popconfirmDetailsText .ant-popover-buttons {
|
|
display: none !important;
|
|
}
|
|
|
|
.popconfirmDetailsText .anticon-exclamation-circle {
|
|
display: none !important;
|
|
}
|
|
</style> |