[add] 参数项收集清单
This commit is contained in:
@@ -0,0 +1,97 @@
|
|||||||
|
<template>
|
||||||
|
<div style="height: 100%">
|
||||||
|
<div class='box'>
|
||||||
|
<!-- 纯文本-->
|
||||||
|
<div v-if='detailDate.controlType === "1"'>
|
||||||
|
<a-input class="box-input"
|
||||||
|
:disabled="disabled"
|
||||||
|
v-model="formInline.nioNumber"
|
||||||
|
:placeholder="$t('PleaseEnter')+$t('NiONumber')"/>
|
||||||
|
</div>
|
||||||
|
<!-- 纯下拉单选-->
|
||||||
|
<div v-if='detailDate.controlType === "2"'>
|
||||||
|
<a-select :placeholder="$t('PleaseSelect')+$t('controlType')" v-model="formInline.controlType">
|
||||||
|
<a-select-option v-for="(item, key) in detailDate.list" :key="key" :value="item.value">
|
||||||
|
<span style="display: inline-block;width: 100%" :title=" item.label ">
|
||||||
|
{{ item.label }}
|
||||||
|
</span>
|
||||||
|
</a-select-option>
|
||||||
|
</a-select>
|
||||||
|
<a-input class="box-input"
|
||||||
|
:disabled="disabled"
|
||||||
|
v-model="formInline.nioNumber"
|
||||||
|
:placeholder="$t('PleaseEnter')+$t('NiONumber')"/>
|
||||||
|
</div>
|
||||||
|
<!-- 纯下拉多选-->
|
||||||
|
<div v-if='detailDate.controlType === "3"'>22</div>
|
||||||
|
<!-- 纯附件-->
|
||||||
|
<div v-if='detailDate.controlType === "4"'>22</div>
|
||||||
|
<!-- 文本+下拉单选-->
|
||||||
|
<div v-if='detailDate.controlType === "5"'>22</div>
|
||||||
|
<!-- 文本+下拉多选-->
|
||||||
|
<div v-if='detailDate.controlType === "6"'>22</div>
|
||||||
|
<!-- 文本+附件-->
|
||||||
|
<div v-if='detailDate.controlType === "7"'>22</div>
|
||||||
|
<!-- 下拉单选+附件-->
|
||||||
|
<div v-if='detailDate.controlType === "8"'>22</div>
|
||||||
|
<!-- 下拉多选+附件-->
|
||||||
|
<div v-if='detailDate.controlType === "9"'>22</div>
|
||||||
|
<!-- 文本+下拉单选+附件-->
|
||||||
|
<div v-if='detailDate.controlType === "10"'>22</div>
|
||||||
|
</div>
|
||||||
|
<!-- {{ detailDate.controlType }}-->
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
|
||||||
|
|
||||||
|
export default {
|
||||||
|
name: 'index',
|
||||||
|
props: {
|
||||||
|
detailDate: {
|
||||||
|
type: Object,
|
||||||
|
default: {},
|
||||||
|
require: true
|
||||||
|
}
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
disabled: false,
|
||||||
|
formInline: {}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
|
||||||
|
},
|
||||||
|
watch: {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
<style>
|
||||||
|
.table .ant-table-column-title {
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ant-table td {
|
||||||
|
white-space: nowrap;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
<style scoped>
|
||||||
|
.box {
|
||||||
|
width: 100%;
|
||||||
|
height: calc(100% - 100px);
|
||||||
|
overflow: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.text {
|
||||||
|
margin-right: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.page {
|
||||||
|
text-align: right;
|
||||||
|
margin-top: 20px;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -27,41 +27,17 @@
|
|||||||
</a>
|
</a>
|
||||||
</span>
|
</span>
|
||||||
<span slot="detailClick" slot-scope="text,record">
|
<span slot="detailClick" slot-scope="text,record">
|
||||||
<a class="text" :title="text" @click="detailClick(record)">
|
<collection-type :detailDate='record' />
|
||||||
{{text && text.length > 18?text.slice(0,17)+'...':text}}
|
|
||||||
</a>
|
|
||||||
</span>
|
</span>
|
||||||
<span slot="urlClick" slot-scope="text,record">
|
|
||||||
<a class="text" :title="text" @click="urlClick(text)">
|
|
||||||
{{text && text.length > 18?text.slice(0,17)+'...':text}}
|
|
||||||
</a>
|
|
||||||
</span>
|
|
||||||
<span slot="detailText" slot-scope="text,record">
|
|
||||||
<span class="text" :title="text">
|
|
||||||
{{text && text.length > 18?text.slice(0,17)+'...':text}}
|
|
||||||
</span>
|
|
||||||
</span>
|
|
||||||
|
|
||||||
</a-table>
|
</a-table>
|
||||||
</div>
|
</div>
|
||||||
<div class="page" v-if="dataSource.length > 0">
|
|
||||||
<a-pagination
|
|
||||||
:show-total="total => $t('total')+` ${total} `+$t('strip')"
|
|
||||||
show-quick-jumper
|
|
||||||
show-size-changer
|
|
||||||
:page-size.sync="pageSize"
|
|
||||||
:total="total"
|
|
||||||
@change="onChange"
|
|
||||||
@showSizeChange="SizeChange"
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import eventBUs from '../../common/event'
|
import eventBUs from '../../common/event'
|
||||||
import { getAction, postAction } from '@/api/manage'
|
import { getAction, postAction } from '@/api/manage'
|
||||||
|
import CollectionType from '@/components/CollectionType'
|
||||||
export default {
|
export default {
|
||||||
name: 'index',
|
name: 'index',
|
||||||
props: {
|
props: {
|
||||||
@@ -75,16 +51,10 @@ export default {
|
|||||||
type: Object,
|
type: Object,
|
||||||
default: {},
|
default: {},
|
||||||
require: true
|
require: true
|
||||||
},
|
}
|
||||||
// flag: {
|
},
|
||||||
// type: String,
|
components: {
|
||||||
// default: ''
|
CollectionType
|
||||||
// },
|
|
||||||
// //是否显示操作;默认不显示
|
|
||||||
// showAction: {
|
|
||||||
// type: Boolean,
|
|
||||||
// default: false
|
|
||||||
// }
|
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
@@ -104,26 +74,7 @@ export default {
|
|||||||
orderByField: ''
|
orderByField: ''
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {},
|
||||||
// eventBUs.$on('searchQuery', search => {
|
|
||||||
// Object.keys(search).forEach(res => {
|
|
||||||
// if (search[res] instanceof Array) {
|
|
||||||
// search[res] = search[res].join(',')
|
|
||||||
// }
|
|
||||||
// })
|
|
||||||
// this.searchParmes = search
|
|
||||||
// this.getData()
|
|
||||||
// this.getTableList()
|
|
||||||
// })
|
|
||||||
// eventBUs.$on('searchReset', target => {
|
|
||||||
// this.searchParmes = {}
|
|
||||||
// this.selectedRowKeys = []
|
|
||||||
// this.getData()
|
|
||||||
// this.getTableList()
|
|
||||||
// })
|
|
||||||
// this.getData()
|
|
||||||
// this.getTableList()
|
|
||||||
},
|
|
||||||
methods: {
|
methods: {
|
||||||
|
|
||||||
getTextWith(text, fontStyle) {
|
getTextWith(text, fontStyle) {
|
||||||
@@ -138,13 +89,10 @@ export default {
|
|||||||
paramsManifestId: this.paramsManifest.id,
|
paramsManifestId: this.paramsManifest.id,
|
||||||
flag: '7'
|
flag: '7'
|
||||||
}
|
}
|
||||||
console.log(params,'paramsparams')
|
|
||||||
getAction(this.url.tableHeader, params).then((res) => {
|
getAction(this.url.tableHeader, params).then((res) => {
|
||||||
if (res.success) {
|
if (res.success) {
|
||||||
console.log(res,'res...头部')
|
|
||||||
var jsonHead = res.result
|
var jsonHead = res.result
|
||||||
this.columns = []
|
this.columns = []
|
||||||
// res.db_field_txt
|
|
||||||
jsonHead.forEach((res, index) => {
|
jsonHead.forEach((res, index) => {
|
||||||
this.columns.push({
|
this.columns.push({
|
||||||
title: res.db_field_txt,
|
title: res.db_field_txt,
|
||||||
@@ -153,26 +101,12 @@ export default {
|
|||||||
ellipsis: true,
|
ellipsis: true,
|
||||||
sorter: res.sort
|
sorter: res.sort
|
||||||
})
|
})
|
||||||
// if (res.click) {
|
if (res.type) {
|
||||||
// this.columns[index].scopedSlots = {
|
this.columns[index].scopedSlots = {
|
||||||
// customRender: 'detailClick'
|
customRender: 'detailClick'
|
||||||
// }
|
}
|
||||||
// } else if (res.urlClick) {
|
}
|
||||||
// this.columns[index].scopedSlots = {
|
|
||||||
// customRender: 'urlClick'
|
|
||||||
// }
|
|
||||||
// } else {
|
|
||||||
// this.columns[index].scopedSlots = {
|
|
||||||
// customRender: 'detailText'
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
})
|
})
|
||||||
// let width = 0
|
|
||||||
// if (this.OperationList.length > 0) {
|
|
||||||
// for (let i = 0; i < this.OperationList.length; i++) {
|
|
||||||
// width += this.getTextWith(this.OperationList[i].text)
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
if (this.showAction) {
|
if (this.showAction) {
|
||||||
this.columns.push({
|
this.columns.push({
|
||||||
title: this.$t('operation'),
|
title: this.$t('operation'),
|
||||||
@@ -192,18 +126,11 @@ export default {
|
|||||||
let params = {
|
let params = {
|
||||||
paramsManifestId: this.paramsManifest.id,
|
paramsManifestId: this.paramsManifest.id,
|
||||||
}
|
}
|
||||||
console.log(params,'paykkkkk')
|
|
||||||
this.loading = true
|
this.loading = true
|
||||||
getAction(this.url.tableList, params).then((res) => {
|
getAction(this.url.tableList, params).then((res) => {
|
||||||
if (res.success) {
|
if (res.success) {
|
||||||
console.log(res,'res...list')
|
this.dataSource = res.result
|
||||||
// if (res.result.current > 1 && res.result.records.length == 0) {
|
this.total = res.result.total
|
||||||
// this.pageNo = res.result.current - 1
|
|
||||||
// this.getTableList()
|
|
||||||
// return
|
|
||||||
// }
|
|
||||||
// this.dataSource = res.result.records
|
|
||||||
// this.total = res.result.total
|
|
||||||
this.loading = false
|
this.loading = false
|
||||||
} else {
|
} else {
|
||||||
this.loading = false
|
this.loading = false
|
||||||
@@ -214,11 +141,6 @@ export default {
|
|||||||
// this.pageNo = page
|
// this.pageNo = page
|
||||||
// this.getTableList()
|
// this.getTableList()
|
||||||
},
|
},
|
||||||
SizeChange(page, pageSize) {
|
|
||||||
// this.pageNo = 1
|
|
||||||
// this.pageSize = pageSize
|
|
||||||
// this.getTableList()
|
|
||||||
},
|
|
||||||
onSelectChange(value) {
|
onSelectChange(value) {
|
||||||
// this.selectedRowKeys = value
|
// this.selectedRowKeys = value
|
||||||
// this.$emit('onSelectChange', value)
|
// this.$emit('onSelectChange', value)
|
||||||
@@ -228,9 +150,6 @@ export default {
|
|||||||
},
|
},
|
||||||
detailClick(item, index) {
|
detailClick(item, index) {
|
||||||
// this.$emit('detailClick', item)
|
// this.$emit('detailClick', item)
|
||||||
},
|
|
||||||
urlClick(item) {
|
|
||||||
// window.open(item)
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
|
|||||||
@@ -80,17 +80,6 @@
|
|||||||
<div style="width: 100%">
|
<div style="width: 100%">
|
||||||
<table-collection ref="CollectionTabel" :url='url' :paramsManifest='paramsManifest'/>
|
<table-collection ref="CollectionTabel" :url='url' :paramsManifest='paramsManifest'/>
|
||||||
</div>
|
</div>
|
||||||
<div class="page">
|
|
||||||
<a-pagination
|
|
||||||
:show-total="total => $t('total')+` ${total} `+$t('strip')"
|
|
||||||
show-quick-jumper
|
|
||||||
show-size-changer
|
|
||||||
:page-size.sync="pageSize"
|
|
||||||
:total="total"
|
|
||||||
@change="pageOnChange"
|
|
||||||
@showSizeChange="SizeChange"
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
<a-modal v-model="areaVisible" :title="$t('parameterTemplate')" width='750px' :footer="null">
|
<a-modal v-model="areaVisible" :title="$t('parameterTemplate')" width='750px' :footer="null">
|
||||||
</a-modal>
|
</a-modal>
|
||||||
</a-card>
|
</a-card>
|
||||||
|
|||||||
@@ -74,7 +74,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<a-modal v-model="areaVisible" :title="$t('parameterTemplate')" width='750px' :footer="null">
|
<a-modal v-model="areaVisible" :title="$t('parameterTemplate')" width='750px' :footer="null">
|
||||||
<parameter-template v-if='areaVisible' @areaVisible='handleCancel' :templateTitle='templatetitle'
|
<parameter-template v-if='areaVisible' @areaVisible='handleCancel' :templateTitle='templatetitle'
|
||||||
:selectedRowKeyS='selectedRowKeys' :rowId='rowId' :version='version'></parameter-template>
|
:selectedRowKeyS='selectedRowKeys' :rowId='rowId' :version='version' :projectId='this.$route.query.id'></parameter-template>
|
||||||
</a-modal>
|
</a-modal>
|
||||||
<configure ref="configureRef" :url='url' :itemId='itemId'/>
|
<configure ref="configureRef" :url='url' :itemId='itemId'/>
|
||||||
</a-card>
|
</a-card>
|
||||||
|
|||||||
@@ -140,6 +140,11 @@ export default {
|
|||||||
type: Number,
|
type: Number,
|
||||||
default: '',
|
default: '',
|
||||||
required: false
|
required: false
|
||||||
|
},
|
||||||
|
projectId: {
|
||||||
|
type: String,
|
||||||
|
default: '',
|
||||||
|
require: true
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
@@ -200,7 +205,8 @@ export default {
|
|||||||
let postDate = {
|
let postDate = {
|
||||||
title: this.templatetitle,
|
title: this.templatetitle,
|
||||||
paramsTemplateId: this.rowId || this.selectedRowKeysDate[0].id,
|
paramsTemplateId: this.rowId || this.selectedRowKeysDate[0].id,
|
||||||
paramsTemplatePublishVersion: this.version || this.selectedRowKeysDate[0].version
|
paramsTemplatePublishVersion: this.version || this.selectedRowKeysDate[0].version,
|
||||||
|
projectId: this.projectId
|
||||||
}
|
}
|
||||||
if (this.rowId) {
|
if (this.rowId) {
|
||||||
//编辑
|
//编辑
|
||||||
|
|||||||
Reference in New Issue
Block a user