[add] 认证参数收集
This commit is contained in:
@@ -8,7 +8,7 @@
|
||||
<span>{{$t('title')}}</span>
|
||||
</div>
|
||||
<a-input class="box-input" :placeholder="$t('PleaseEnter')+$t('title')"
|
||||
v-model="queryParam.certificationType"></a-input>
|
||||
v-model="queryParam.title"></a-input>
|
||||
</div>
|
||||
</a-col>
|
||||
<span style="float: right;overflow: hidden;margin-right: 11px" class="table-page-search-submitButtons">
|
||||
@@ -49,7 +49,18 @@
|
||||
</span>
|
||||
</a-table>
|
||||
</div>
|
||||
<a-modal v-model="areaVisible">
|
||||
<div class="page">
|
||||
<a-pagination
|
||||
:show-total="total => $t('total')+` ${total} `+$t('strip')"
|
||||
show-quick-jumper
|
||||
show-size-changer
|
||||
:page-size.sync="pageSize"
|
||||
:total="total"
|
||||
@change="pageOnChange"
|
||||
@showSizeChange="SizeChange"
|
||||
/>
|
||||
</div>
|
||||
<a-modal v-model="areaVisible" :title="$t('parameterTemplate')" width='750px' :footer="null">
|
||||
<parameter-template v-if='areaVisible'></parameter-template>
|
||||
</a-modal>
|
||||
</a-card>
|
||||
@@ -58,6 +69,8 @@
|
||||
<script>
|
||||
import ImportFile from '@/components/ImportFile/index'
|
||||
import ParameterTemplate from '../dialog/ParameterTemplate'
|
||||
import { getAction } from '../../../api/manage'
|
||||
|
||||
export default {
|
||||
name: 'TaskParameterCollection',
|
||||
components:{
|
||||
@@ -75,32 +88,32 @@
|
||||
{
|
||||
title: this.$t('status'),
|
||||
align: 'center',
|
||||
dataIndex: 'title',
|
||||
dataIndex: 'state',
|
||||
},
|
||||
{
|
||||
title: this.$t('parameterTemplateName'),
|
||||
align: 'center',
|
||||
dataIndex: 'ParameterDescription',
|
||||
dataIndex: 'paramsTemplateName',
|
||||
},
|
||||
{
|
||||
title: this.$t('collectionCompletionTime'),
|
||||
align: 'center',
|
||||
dataIndex: 'title',
|
||||
dataIndex: 'finishTime',
|
||||
},
|
||||
{
|
||||
title: this.$t('Version'),
|
||||
align: 'center',
|
||||
dataIndex: 'title',
|
||||
dataIndex: 'version',
|
||||
},
|
||||
{
|
||||
title: this.$t('creator'),
|
||||
align: 'center',
|
||||
dataIndex: 'title',
|
||||
dataIndex: 'createBy',
|
||||
},
|
||||
{
|
||||
title: this.$t('createTime'),
|
||||
align: 'center',
|
||||
dataIndex: 'title',
|
||||
dataIndex: 'createTime',
|
||||
},
|
||||
{
|
||||
title: this.$t('operation'),
|
||||
@@ -112,20 +125,33 @@
|
||||
],
|
||||
selectedRowKeys: [],
|
||||
queryParam: {},
|
||||
url: {},
|
||||
url: {
|
||||
list: 'params/manifest/page',
|
||||
add: 'params/manifest/add',
|
||||
edit: 'params/manifest/edit',
|
||||
deleteBatch: 'params/manifest/delete',
|
||||
deleteAll: 'params/manifest/deleteBatch',
|
||||
},
|
||||
loading: false,
|
||||
dataSource: [],
|
||||
areaVisible: false, // 弹框的控制
|
||||
pageNo: 1,
|
||||
pageSize: 10,
|
||||
total: 0,
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.getlist()
|
||||
},
|
||||
methods:{
|
||||
searchQuery() {
|
||||
|
||||
this.pageNo = 1
|
||||
this.getlist()
|
||||
},
|
||||
searchReset() {
|
||||
|
||||
this.queryParam = {}
|
||||
this.pageNo = 1
|
||||
this.getlist()
|
||||
},
|
||||
onSelectChange() {
|
||||
|
||||
@@ -148,6 +174,29 @@
|
||||
getPersonnelList(){
|
||||
|
||||
},
|
||||
pageOnChange() {
|
||||
|
||||
},
|
||||
SizeChange() {
|
||||
|
||||
},
|
||||
getlist() {
|
||||
let query = {
|
||||
pageSize: this.pageSize,
|
||||
pageNo: this.pageNo,
|
||||
...this.queryParam
|
||||
}
|
||||
console.log(this.$route.query,'this.query')
|
||||
getAction(this.url.list, query).then((res) => {
|
||||
if(res.success) {
|
||||
this.total = res.result.total
|
||||
this.dataSource = res.result.records || []
|
||||
this.loading = false
|
||||
} else {
|
||||
this.loading = false
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -1,261 +1,245 @@
|
||||
<template>
|
||||
<div class="diolag-area">
|
||||
<div class="table-operator">
|
||||
<div class="operator-text">
|
||||
{{$t('parameterTemplate')}}
|
||||
</div>
|
||||
</div>
|
||||
<a-spin :spinning="spinLoading">
|
||||
<a-form-model
|
||||
class="tag-module"
|
||||
ref="ruleForm"
|
||||
:model="form"
|
||||
:rules="rules"
|
||||
:label-col="labelCol"
|
||||
:wrapper-col="wrapperCol"
|
||||
>
|
||||
<a-form-model-item :label="$t('Module')" prop="isModel">
|
||||
<j-dict-select-tag type="list" v-model="form.isModel" dictCode="module" :placeholder="$t('PleaseSelectModule')" />
|
||||
</a-form-model-item>
|
||||
<a-form-model-item ref="showArea" :label="$t('DisplayArea')" prop="showArea">
|
||||
<a-input
|
||||
v-model="form.showArea"
|
||||
@blur="
|
||||
() => {
|
||||
$refs.showArea.onFieldBlur();
|
||||
}
|
||||
"
|
||||
/>
|
||||
</a-form-model-item>
|
||||
<a-form-model-item ref="enName" :label="$t('enName')" prop="enName">
|
||||
<a-input
|
||||
v-model="form.enName"
|
||||
@blur="
|
||||
() => {
|
||||
$refs.enName.onFieldBlur();
|
||||
}
|
||||
"
|
||||
/>
|
||||
</a-form-model-item>
|
||||
<a-form-model-item ref="sort" :label="$t('SortNumber')" prop="sort">
|
||||
<a-input-number
|
||||
style="width:100%"
|
||||
v-model="form.sort"
|
||||
:min="1"
|
||||
:formatter="limitNumber"
|
||||
:parser="limitNumber"
|
||||
@blur="
|
||||
() => {
|
||||
$refs.sort.onFieldBlur();
|
||||
}
|
||||
"
|
||||
/>
|
||||
</a-form-model-item>
|
||||
</a-form-model>
|
||||
</a-spin>
|
||||
<div class='diolag-area'>
|
||||
<a-spin :spinning='spinLoading'>
|
||||
<a-form-model
|
||||
class='tag-module'
|
||||
ref='ruleForm'
|
||||
:model='form'
|
||||
:rules='rules'
|
||||
:label-col='labelCol'
|
||||
:wrapper-col='wrapperCol'
|
||||
>
|
||||
<a-row :gutter='24'>
|
||||
<a-col :span='9'>
|
||||
<a-form-model-item :label="$t('title')" prop='title'>
|
||||
<a-input style='width: 420px'
|
||||
v-model='title' />
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span='9'>
|
||||
</a-col>
|
||||
<a-col :span='6'>
|
||||
<a-button class="box-button" type="primary" @click="searchQuery">{{$t('query')}}</a-button>
|
||||
<a-button class="box-button" style="margin-left: 8px" @click="searchReset">{{$t('reset')}}</a-button>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter='24'>
|
||||
<a-col :span='9'>
|
||||
<a-form-model-item ref='region' :label="$t('zoneOfApplication')" prop='region'>
|
||||
<a-form-model-item class="itemModel" prop="region">
|
||||
<j-dict-select-tag class="box-input" v-model="form.region"
|
||||
:placeholder="$t('PleaseSelect')+$t('zoneOfApplication')"
|
||||
:type="'select'"
|
||||
:triggerChange="false" :dictCode="'region'"/>
|
||||
</a-form-model-item>
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
<a-col :span='9'>
|
||||
<a-form-model-item ref='paramsTemplateName' :label="$t('parameterTemplate')" prop='paramsTemplateName'>
|
||||
<a-input
|
||||
v-model='form.paramsTemplateName' />
|
||||
</a-form-model-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form-model>
|
||||
</a-spin>
|
||||
<a-table
|
||||
class="table-area"
|
||||
ref="table"
|
||||
size="middle"
|
||||
rowKey="id"
|
||||
:columns="columns"
|
||||
:dataSource="areaTable"
|
||||
:pagination="false"
|
||||
:loading="loading"
|
||||
:scroll="{x: 600}"
|
||||
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
|
||||
@change="handleTableChange">
|
||||
<a slot="name" slot-scope="text">{{ text }}</a>
|
||||
<span slot="action" slot-scope="text, record">
|
||||
<a class="action-edit" @click="editArea(record.id)" v-has="'area:edit'" >{{$t('edit')}}</a>
|
||||
<a style="color:red" href="javascript:;" @click=" deleteArea(record.id)" v-has="'area:delete'">{{$t('delete')}}</a>
|
||||
class='table-area'
|
||||
ref='table'
|
||||
size='middle'
|
||||
rowKey='id'
|
||||
:columns='columns'
|
||||
:dataSource='areaTable'
|
||||
:pagination='false'
|
||||
:loading='loading'
|
||||
:scroll='{x: 600}'
|
||||
:rowSelection='{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}'
|
||||
@change='handleTableChange'>
|
||||
<a slot='name' slot-scope='text'>{{ text }}</a>
|
||||
<span slot='action' slot-scope='text, record'>
|
||||
<a class='action-edit' @click='editArea(record.id)' v-has="'area:edit'">{{ $t('edit') }}</a>
|
||||
<a style='color:red' href='javascript:;' @click=' deleteArea(record.id)'
|
||||
v-has="'area:delete'">{{ $t('delete') }}</a>
|
||||
</span>
|
||||
</a-table>
|
||||
<div class="drawer-bootom-button">
|
||||
<a-button style="margin-right: .8rem" @click="handleCancel">{{$t('cancel')}}</a-button>
|
||||
<a-button @click="handleSubmit" type="primary" :loading="confirmLoading">{{$t('submit')}}</a-button>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { putAction,postAction,getAction,deleteAction } from '@/api/manage'
|
||||
import { putAction, postAction, getAction, deleteAction } from '@/api/manage'
|
||||
|
||||
export default {
|
||||
name: 'diolagArea',
|
||||
components:{
|
||||
|
||||
},
|
||||
data(){
|
||||
return{
|
||||
title:this.$t('add'),
|
||||
queryParams:{
|
||||
pageNo:1,
|
||||
pageSize:10
|
||||
},
|
||||
total:0,
|
||||
components: {},
|
||||
data() {
|
||||
return {
|
||||
title: this.$t('add'),
|
||||
total: 0,
|
||||
selectedRowKeys: [],
|
||||
loading: false,
|
||||
ipagination:true,
|
||||
editId:'',
|
||||
ipagination: true,
|
||||
editId: '',
|
||||
columns: [
|
||||
{
|
||||
title: this.$t('zoneOfApplication'),
|
||||
dataIndex: 'showArea',
|
||||
dataIndex: 'region_dictText',
|
||||
key: 'showArea',
|
||||
align: "center",
|
||||
ellipsis: true,
|
||||
align: 'center',
|
||||
ellipsis: true
|
||||
},
|
||||
{
|
||||
title: this.$t('parameterTemplate'),
|
||||
align: "center",
|
||||
dataIndex: 'enName',
|
||||
ellipsis: true,
|
||||
align: 'center',
|
||||
dataIndex: 'paramsTemplateName',
|
||||
ellipsis: true
|
||||
}
|
||||
],
|
||||
newVisible:false,
|
||||
newVisible: false,
|
||||
labelCol: {
|
||||
xs: { span: 24 },
|
||||
sm: { span: 7 },
|
||||
sm: { span: 7 }
|
||||
},
|
||||
wrapperCol: {
|
||||
xs: { span: 24 },
|
||||
sm: { span: 14 },
|
||||
},
|
||||
form: {
|
||||
isModel:'1',
|
||||
showArea:'',
|
||||
enName:'',
|
||||
sort:''
|
||||
sm: { span: 14 }
|
||||
},
|
||||
form: {},
|
||||
rules: {
|
||||
isModel:[
|
||||
{ required: true, message: this.$t('PleaseSelectModule'), trigger: 'change' },
|
||||
|
||||
],
|
||||
enName:[
|
||||
{ max: 100, message: this.$t('CannotExceed100characters'), trigger: 'blur' },
|
||||
|
||||
],
|
||||
showArea:[
|
||||
{ required: true, message: this.$t('enterDisplayArea'), trigger: 'blur' },
|
||||
{ min:1, max: 50, message: this.$t('charactersLength'), trigger: 'blur' },
|
||||
],
|
||||
sort:[
|
||||
{ required: true, message: this.$t('enterSortingNumber'), trigger: 'change' },
|
||||
title: [
|
||||
{ required: true, message: this.$t('enterTitle'), trigger: 'blur' },
|
||||
{ min: 1, max: 50, message: this.$t('charactersLength'), trigger: 'blur' }
|
||||
]
|
||||
},
|
||||
areaTable:[],
|
||||
flag:false, //表单提交标识
|
||||
spinLoading:false,
|
||||
areaTable: [],
|
||||
flag: false, //表单提交标识
|
||||
spinLoading: false,
|
||||
confirmLoading: false
|
||||
}
|
||||
},
|
||||
props:{
|
||||
// areaTable:Array
|
||||
},
|
||||
props: {},
|
||||
mounted() {
|
||||
this.loadData()
|
||||
},
|
||||
methods:{
|
||||
loadData(){
|
||||
this.loading=true
|
||||
let params={
|
||||
...this.queryParams
|
||||
methods: {
|
||||
loadData() {
|
||||
this.loading = true
|
||||
let params = {
|
||||
...this.form
|
||||
}
|
||||
postAction(`tag/onlCgformArea/page`,params).then(res=>{
|
||||
if(res.success){
|
||||
this.areaTable=[...res.result.records]
|
||||
this.total=res.result.total
|
||||
getAction(`params/manifest/getParamsTemplateList`, params).then(res => {
|
||||
if (res.success) {
|
||||
this.areaTable = [...res.result]
|
||||
this.total = res.result.total
|
||||
}
|
||||
}).finally(()=>{
|
||||
this.loading=false
|
||||
}).finally(() => {
|
||||
this.loading = false
|
||||
})
|
||||
},
|
||||
searchQuery() {
|
||||
this.loadData()
|
||||
},
|
||||
searchReset() {
|
||||
this.form = {}
|
||||
this.loadData()
|
||||
},
|
||||
handleCancel() {
|
||||
|
||||
},
|
||||
handleSubmit() {
|
||||
|
||||
},
|
||||
onSelectChange(selectedRowKeys) {
|
||||
// console.log('selectedRowKeys changed: ', selectedRowKeys);
|
||||
this.selectedRowKeys = selectedRowKeys;
|
||||
this.selectedRowKeys = selectedRowKeys
|
||||
},
|
||||
handleTableChange(){
|
||||
handleTableChange() {
|
||||
|
||||
},
|
||||
showModal() {
|
||||
this.title=this.$t('add')
|
||||
this.newVisible = true;
|
||||
this.form={
|
||||
|
||||
}
|
||||
this.title = this.$t('add')
|
||||
this.newVisible = true
|
||||
this.form = {}
|
||||
},
|
||||
//新增
|
||||
hideModal() {
|
||||
this.$refs.ruleForm.validate(valid => {
|
||||
if (valid) {
|
||||
this.flag=true
|
||||
this.spinLoading=true
|
||||
this.flag = true
|
||||
this.spinLoading = true
|
||||
//编辑
|
||||
if(this.form.id){
|
||||
putAction(`tag/onlCgformArea/edit`,this.form).then((res)=>{
|
||||
if(res.success){
|
||||
this.$message.success(this.$t('OperationSuccessful'));
|
||||
if (this.form.id) {
|
||||
putAction(`tag/onlCgformArea/edit`, this.form).then((res) => {
|
||||
if (res.success) {
|
||||
this.$message.success(this.$t('OperationSuccessful'))
|
||||
this.loadData()
|
||||
this.form={
|
||||
isModel:'',
|
||||
showArea:'',
|
||||
enName:'',
|
||||
sort:''
|
||||
this.form = {
|
||||
isModel: '',
|
||||
showArea: '',
|
||||
enName: '',
|
||||
sort: ''
|
||||
}
|
||||
}else{
|
||||
} else {
|
||||
this.$message.warning(res.message)
|
||||
this.form={
|
||||
isModel:'',
|
||||
showArea:'',
|
||||
enName:'',
|
||||
sort:''
|
||||
this.form = {
|
||||
isModel: '',
|
||||
showArea: '',
|
||||
enName: '',
|
||||
sort: ''
|
||||
}
|
||||
}
|
||||
}).finally(()=>{
|
||||
this.flag=false
|
||||
this.spinLoading=false
|
||||
this.newVisible = false;
|
||||
this.form={
|
||||
isModel:'',
|
||||
showArea:'',
|
||||
enName:'',
|
||||
sort:''
|
||||
}).finally(() => {
|
||||
this.flag = false
|
||||
this.spinLoading = false
|
||||
this.newVisible = false
|
||||
this.form = {
|
||||
isModel: '',
|
||||
showArea: '',
|
||||
enName: '',
|
||||
sort: ''
|
||||
}
|
||||
})
|
||||
}else{
|
||||
} else {
|
||||
//新增
|
||||
postAction(`/tag/onlCgformArea/add`,this.form).then(res=>{
|
||||
if(res.success){
|
||||
this.$message.success( this.$t('OperationSuccessful'));
|
||||
postAction(`/tag/onlCgformArea/add`, this.form).then(res => {
|
||||
if (res.success) {
|
||||
this.$message.success(this.$t('OperationSuccessful'))
|
||||
this.loadData()
|
||||
this.form={
|
||||
isModel:'',
|
||||
showArea:'',
|
||||
enName:'',
|
||||
sort:''
|
||||
this.form = {
|
||||
isModel: '',
|
||||
showArea: '',
|
||||
enName: '',
|
||||
sort: ''
|
||||
}
|
||||
}else{
|
||||
} else {
|
||||
// this.$message.warning(this.$t('operationFailed'))
|
||||
this.$message.warning(res.message)
|
||||
|
||||
}
|
||||
}
|
||||
).finally(()=>{
|
||||
this.flag=false
|
||||
this.spinLoading=false
|
||||
this.newVisible = false;
|
||||
).finally(() => {
|
||||
this.flag = false
|
||||
this.spinLoading = false
|
||||
this.newVisible = false
|
||||
})
|
||||
}
|
||||
|
||||
} else {
|
||||
// console.log('error submit!!');
|
||||
return false;
|
||||
return false
|
||||
}
|
||||
});
|
||||
})
|
||||
|
||||
},
|
||||
cancelModel(){
|
||||
this.newVisible=false
|
||||
this.$refs.ruleForm.resetFields();
|
||||
cancelModel() {
|
||||
this.newVisible = false
|
||||
this.$refs.ruleForm.resetFields()
|
||||
},
|
||||
//删除按钮
|
||||
deleteArea(val){
|
||||
deleteArea(val) {
|
||||
this.$confirm({
|
||||
title: this.$t('confirmDeletion'),
|
||||
content: '',
|
||||
@@ -263,17 +247,17 @@ export default {
|
||||
async () => {
|
||||
getAction(`tag/onlCgformArea/delete`, { id: val }).then((res) => {
|
||||
if (res.success) {
|
||||
this.$message.success(this.$t('OperationSuccessful'));
|
||||
if(this.areaTable.length==1&&this.queryParams.pageNo!=1){
|
||||
this.queryParams.pageNo=this.queryParams.pageNo-1
|
||||
this.$message.success(this.$t('OperationSuccessful'))
|
||||
if (this.areaTable.length == 1 && this.queryParams.pageNo != 1) {
|
||||
this.queryParams.pageNo = this.queryParams.pageNo - 1
|
||||
}
|
||||
this.loadData()
|
||||
}else{
|
||||
} else {
|
||||
// this.$message.warning(res.message)
|
||||
if(res.message=='该展示区域有关联数据,无法删除!'){
|
||||
if (res.message == '该展示区域有关联数据,无法删除!') {
|
||||
this.$message.warning(this.$t('noDelete'))
|
||||
}else{
|
||||
this.$message.warning(this.$t('operationFailed'));
|
||||
} else {
|
||||
this.$message.warning(this.$t('operationFailed'))
|
||||
}
|
||||
}
|
||||
})
|
||||
@@ -281,29 +265,29 @@ export default {
|
||||
})
|
||||
},
|
||||
//编辑按钮
|
||||
editArea(val){
|
||||
this.title=this.$t('edit')
|
||||
this.newVisible = true;
|
||||
let params={
|
||||
id:val
|
||||
editArea(val) {
|
||||
this.title = this.$t('edit')
|
||||
this.newVisible = true
|
||||
let params = {
|
||||
id: val
|
||||
}
|
||||
getAction(`tag/onlCgformArea/queryById`, params).then((res) => {
|
||||
if(res.success){
|
||||
this.form={...res.result}
|
||||
if (res.success) {
|
||||
this.form = { ...res.result }
|
||||
// this.$emit('updateOk',res.result)
|
||||
|
||||
}
|
||||
})
|
||||
},
|
||||
//点击页数
|
||||
onChangePage(page,pageSize){
|
||||
onChangePage(page, pageSize) {
|
||||
this.queryParams.pageNo = page
|
||||
this.loadData()
|
||||
},
|
||||
//一页显示条数
|
||||
SizeChange(page,pageSize){
|
||||
SizeChange(page, pageSize) {
|
||||
this.queryParams.pageSize = pageSize
|
||||
this.queryParams.pageNo=1
|
||||
this.queryParams.pageNo = 1
|
||||
this.loadData()
|
||||
},
|
||||
//正则替换小数点
|
||||
@@ -320,31 +304,38 @@ export default {
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
<style lang='less' scoped>
|
||||
@import '~@assets/less/common.less';
|
||||
.diolag-area{
|
||||
.table-area{
|
||||
|
||||
.diolag-area {
|
||||
.table-area {
|
||||
margin: 20px 0;
|
||||
.action-edit{
|
||||
|
||||
.action-edit {
|
||||
margin-right: 10px;
|
||||
}
|
||||
}
|
||||
.table-del{
|
||||
|
||||
.table-del {
|
||||
color: red;
|
||||
}
|
||||
}
|
||||
|
||||
</style>
|
||||
<style lang="less">
|
||||
.area-module{
|
||||
.ant-modal-wrap{
|
||||
.ant-modal{
|
||||
.ant-modal-content{
|
||||
.ant-modal-footer{
|
||||
<style lang='less'>
|
||||
.area-module {
|
||||
.ant-modal-wrap {
|
||||
.ant-modal {
|
||||
.ant-modal-content {
|
||||
.ant-modal-footer {
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.drawer-bootom-button{
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user