NEX-717 fix:bug修改
This commit is contained in:
@@ -103,7 +103,7 @@
|
|||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</template>
|
</template>
|
||||||
<template v-else-if="label.type.toUpperCase() === assetConstants.labelTypeData.CHECKBOX">
|
<template v-else-if="label.type.toUpperCase() === assetConstants.labelTypeData.CHECKBOX">
|
||||||
<el-checkbox-group v-model="label.value[0]">
|
<el-checkbox-group v-model="label.value">
|
||||||
<el-checkbox v-for="item in JSON.parse(label.param).items" :key="item.name" :label="item.name" :value="item.name"></el-checkbox>
|
<el-checkbox v-for="item in JSON.parse(label.param).items" :key="item.name" :label="item.name" :value="item.name"></el-checkbox>
|
||||||
</el-checkbox-group>
|
</el-checkbox-group>
|
||||||
</template>
|
</template>
|
||||||
@@ -481,9 +481,27 @@ export default {
|
|||||||
},
|
},
|
||||||
blankLabelValue (label) {
|
blankLabelValue (label) {
|
||||||
if (label.type.toUpperCase() === this.assetConstants.labelTypeData.CHECKBOX) {
|
if (label.type.toUpperCase() === this.assetConstants.labelTypeData.CHECKBOX) {
|
||||||
return []
|
const arr = []
|
||||||
|
if (label.param && JSON.parse(label.param).items) {
|
||||||
|
JSON.parse(label.param).items.forEach(item => {
|
||||||
|
if (item.check) {
|
||||||
|
arr.push(item.name)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
return arr
|
||||||
} else if (label.type.toUpperCase() === this.assetConstants.labelTypeData.MULTITEXT || label.type.toUpperCase() === assetConstants.labelTypeData.TEXT || label.type.toUpperCase() === assetConstants.labelTypeData.TEXTAREA) {
|
} else if (label.type.toUpperCase() === this.assetConstants.labelTypeData.MULTITEXT || label.type.toUpperCase() === assetConstants.labelTypeData.TEXT || label.type.toUpperCase() === assetConstants.labelTypeData.TEXTAREA) {
|
||||||
return ['']
|
return ['']
|
||||||
|
} else if (label.type.toUpperCase() === this.assetConstants.labelTypeData.RADIO || label.type.toUpperCase() === assetConstants.labelTypeData.SELECT) {
|
||||||
|
const arr = ['']
|
||||||
|
if (label.param && JSON.parse(label.param).items) {
|
||||||
|
JSON.parse(label.param).items.forEach(item => {
|
||||||
|
if (item.check) {
|
||||||
|
arr[0] = item.name
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
return arr
|
||||||
} else {
|
} else {
|
||||||
return ['']
|
return ['']
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -279,6 +279,7 @@ export default {
|
|||||||
t.disabled = false
|
t.disabled = false
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
this.selectType(this.editAssetMeta.type, false)
|
||||||
},
|
},
|
||||||
clickOutside () {
|
clickOutside () {
|
||||||
this.esc(false)
|
this.esc(false)
|
||||||
|
|||||||
@@ -60,7 +60,14 @@
|
|||||||
<template v-else-if="item.prop === 'parent'">{{scope.row.parent ? scope.row.parent.name : '-'}}</template>
|
<template v-else-if="item.prop === 'parent'">{{scope.row.parent ? scope.row.parent.name : '-'}}</template>
|
||||||
<template v-else-if="item.prop === 'brand'">{{scope.row.brand ? scope.row.brand.name : '-'}}</template>
|
<template v-else-if="item.prop === 'brand'">{{scope.row.brand ? scope.row.brand.name : '-'}}</template>
|
||||||
<template v-else-if="item.prop === 'purchaseDate'">{{scope.row.purchaseDate ? scope.row.purchaseDate : '--'}}</template>
|
<template v-else-if="item.prop === 'purchaseDate'">{{scope.row.purchaseDate ? scope.row.purchaseDate : '--'}}</template>
|
||||||
<template v-else>{{scope.row[item.prop]}}</template>
|
<template v-else>
|
||||||
|
<span v-if="scope.row.fields&&scope.row.fields.find(field => field.name === item.prop)">
|
||||||
|
{{scope.row.fields.find(field => field.name === item.prop).value.join(',')}}
|
||||||
|
</span>
|
||||||
|
<span v-else>
|
||||||
|
{{scope.row[item.prop]}}
|
||||||
|
</span>
|
||||||
|
</template>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
|
|||||||
@@ -49,7 +49,7 @@
|
|||||||
active-color="#ee9d3f"
|
active-color="#ee9d3f"
|
||||||
active-value="ON"
|
active-value="ON"
|
||||||
inactive-value="OFF"
|
inactive-value="OFF"
|
||||||
@change="(val)=>{statusChange(scope.row)}"
|
@change="(val)=>{$emit('statusChange', scope.row)}"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
<template v-else-if="item.prop === 'longitude'">
|
<template v-else-if="item.prop === 'longitude'">
|
||||||
|
|||||||
@@ -362,7 +362,7 @@ export default {
|
|||||||
const data = []
|
const data = []
|
||||||
const searchableData = response.data.list.filter(d => d.search === 1)
|
const searchableData = response.data.list.filter(d => d.search === 1)
|
||||||
const showData = response.data.list.filter(d => d.display === 1).map(item => {
|
const showData = response.data.list.filter(d => d.display === 1).map(item => {
|
||||||
return { label: item.name, prop: 'Label', show: false, allowed: true, type: 'label' }
|
return { label: item.name, prop: item.name, show: false, allowed: true, type: 'label' }
|
||||||
})
|
})
|
||||||
searchableData.forEach(m => {
|
searchableData.forEach(m => {
|
||||||
if (m.param) {
|
if (m.param) {
|
||||||
|
|||||||
@@ -29,6 +29,7 @@
|
|||||||
@orderBy="tableDataSort"
|
@orderBy="tableDataSort"
|
||||||
@reload="getTableData"
|
@reload="getTableData"
|
||||||
@selectionChange="selectionChange"
|
@selectionChange="selectionChange"
|
||||||
|
@statusChange='statusChange'
|
||||||
@showBottomBox="(targetTab, object) => { $refs.dataList.showBottomBox(targetTab, object) }"></dc-table>
|
@showBottomBox="(targetTab, object) => { $refs.dataList.showBottomBox(targetTab, object) }"></dc-table>
|
||||||
</template>
|
</template>
|
||||||
<!-- 分页组件 -->
|
<!-- 分页组件 -->
|
||||||
|
|||||||
@@ -248,7 +248,7 @@
|
|||||||
<el-form-item v-show="editChart.type !='text' && editChart.type !=='url'&& editChart.type !=='group'" :label="$t('dashboard.panel.chartForm.unit')" class="form-item--half-width" prop="unit">
|
<el-form-item v-show="editChart.type !='text' && editChart.type !=='url'&& editChart.type !=='group'" :label="$t('dashboard.panel.chartForm.unit')" class="form-item--half-width" prop="unit">
|
||||||
<el-cascader id="chart-box-unit" v-model="editChart.unit" :options="unitOptions" :props="{ expandTrigger: 'hover',emitPath:false }" :show-all-levels="false" filterable
|
<el-cascader id="chart-box-unit" v-model="editChart.unit" :options="unitOptions" :props="{ expandTrigger: 'hover',emitPath:false }" :show-all-levels="false" filterable
|
||||||
placeholder=""
|
placeholder=""
|
||||||
popper-class="dc-dropdown prevent-clickoutside"
|
popper-class="dc-dropdown prevent-clickoutside chart-box-unit"
|
||||||
size="small"
|
size="small"
|
||||||
style="width: 100%"
|
style="width: 100%"
|
||||||
@change="unitSelected"
|
@change="unitSelected"
|
||||||
@@ -1787,4 +1787,8 @@ export default {
|
|||||||
.el-color-dropdown{
|
.el-color-dropdown{
|
||||||
z-index: 2200!important;
|
z-index: 2200!important;
|
||||||
}
|
}
|
||||||
|
.chart-box-unit .el-scrollbar{
|
||||||
|
height: 195px;
|
||||||
|
overflow-y: auto;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
Reference in New Issue
Block a user