NEZ-1664 feat: asset model 新增补充
This commit is contained in:
@@ -199,8 +199,9 @@ export function arrLength (rule, value, callback) { // 校验数组
|
||||
}
|
||||
|
||||
export function sysObjectIdInput (rule, value, callback) {
|
||||
const sysId = /^(\d+\.)+\d${color}/
|
||||
const sysId = /^(\d{1,9}\.){0,}[\d]+$/
|
||||
setTimeout(() => {
|
||||
if (value == '') return callback()
|
||||
if (sysId.test(value)) {
|
||||
callback()
|
||||
} else {
|
||||
|
||||
@@ -21,8 +21,8 @@
|
||||
</el-form-item>
|
||||
<!-- type -->
|
||||
<el-form-item :label='$t("overall.type")' prop="typeId">
|
||||
<el-select value-key="id" class="right-box__select" popper-class="right-box-select-top prevent-clickoutside" v-model="editModel.typeId" placeholder="" size="small">
|
||||
<el-option v-for="item in typeList" :key="item.id" :label="item.name" :value="item.id"></el-option>
|
||||
<el-select value-key="id" allow-create class="right-box__select" popper-class="right-box-select-top prevent-clickoutside" :filterable="true" v-model="editModel.typeId" placeholder="" size="small" id="module-box-input-project">
|
||||
<el-option :id="'module-project-'+item.type.id" v-for="(item, index) in typeDataList" :key="index" :label="item.type.name" :value="item.type.id"></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!-- ChartTemplate -->
|
||||
@@ -98,7 +98,7 @@ export default {
|
||||
editModel: {},
|
||||
brandList: [], // brand 列表数据
|
||||
editModule: {},
|
||||
typeList: [],
|
||||
typeDataList: [],
|
||||
chartlList: [], // chart 列表数据
|
||||
ChartSearchShowFields: [ // ChartSearch 下拉搜索表头
|
||||
{ title: 'ID', data: 'id' },
|
||||
@@ -131,6 +131,9 @@ export default {
|
||||
deep: true,
|
||||
immediate: true,
|
||||
handler (n) {
|
||||
if (n.id) {
|
||||
this.editModel.typeId = n.type.name
|
||||
}
|
||||
this.isEdit = true
|
||||
this.editModel = JSON.parse(JSON.stringify(n))
|
||||
}
|
||||
@@ -138,6 +141,7 @@ export default {
|
||||
},
|
||||
created () {
|
||||
this.getBrandList()
|
||||
this.modelTypeList()
|
||||
this.ChartTemplateList()
|
||||
},
|
||||
methods: {
|
||||
@@ -227,6 +231,11 @@ export default {
|
||||
this.$get('visual/panel/chart', { pageSize: -1, varType: 1, panelId: 0, groupId: 0 }).then(res => {
|
||||
this.chartlList = res.data.list
|
||||
})
|
||||
},
|
||||
modelTypeList () {
|
||||
this.$get('asset/model', { pageSize: -1, pageNo: 1 }).then(res => {
|
||||
this.typeDataList = res.data.list
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -44,6 +44,9 @@
|
||||
<template v-else-if="item.prop === 'brand'">
|
||||
{{scope.row.brand.name}}
|
||||
</template>
|
||||
<template v-else-if="item.prop === 'type'">
|
||||
{{scope.row.type.name}}
|
||||
</template>
|
||||
<span v-else-if="item.prop === 'createTime'">{{utcTimeToTimezoneStr(scope.row[item.prop])}}</span>
|
||||
<template v-else-if="item.prop === 'assetNum'">
|
||||
<span style="cursor: pointer" class="endpoint-num" @click="showBottomBox('asset', scope.row)">
|
||||
|
||||
13
nezha-fronted/src/components/page/config/licenseGen.vue
Normal file
13
nezha-fronted/src/components/page/config/licenseGen.vue
Normal file
@@ -0,0 +1,13 @@
|
||||
<template>
|
||||
$END$
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: "licenseGen"
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
|
||||
</style>
|
||||
Reference in New Issue
Block a user