Merge branch 'develop-business-css' of http://121.37.111.42:3000/ThbTech/JavaProjectRepo into development-business-css
This commit is contained in:
commit
3e57f887fa
BIN
business-css/frontend/public/assets/8.png
Normal file
BIN
business-css/frontend/public/assets/8.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.4 KiB |
BIN
business-css/frontend/public/assets/88.png
Normal file
BIN
business-css/frontend/public/assets/88.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 19 KiB |
BIN
business-css/frontend/public/assets/9.png
Normal file
BIN
business-css/frontend/public/assets/9.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.4 KiB |
BIN
business-css/frontend/public/assets/99.png
Normal file
BIN
business-css/frontend/public/assets/99.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 20 KiB |
@ -1,6 +1,6 @@
|
|||||||
import request from '@/utils/request';
|
import request from '@/utils/request';
|
||||||
|
|
||||||
//获取所有项目列表
|
//获取临界数据分页列表
|
||||||
export function searchCriticalDataPage(queryParams:any){
|
export function searchCriticalDataPage(queryParams:any){
|
||||||
return request({
|
return request({
|
||||||
url: '/critical-data/by-device-type' ,
|
url: '/critical-data/by-device-type' ,
|
||||||
@ -12,7 +12,7 @@ export function searchCriticalDataPage(queryParams:any){
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
//新增项目
|
//新增临界数据
|
||||||
export function addCriticalData(data:any){
|
export function addCriticalData(data:any){
|
||||||
return request({
|
return request({
|
||||||
url:'/critical-data' ,
|
url:'/critical-data' ,
|
||||||
@ -22,7 +22,7 @@ export function addCriticalData(data:any){
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//更新项目信息
|
//更新临界数据信息
|
||||||
export function updateCriticalData (queryParams:any){
|
export function updateCriticalData (queryParams:any){
|
||||||
return request({
|
return request({
|
||||||
url:'/critical-data' ,
|
url:'/critical-data' ,
|
||||||
@ -32,7 +32,7 @@ export function updateCriticalData (queryParams:any){
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//单个删除项目
|
//单个删除临界数据
|
||||||
export function deleteCriticalData (queryParams:any){
|
export function deleteCriticalData (queryParams:any){
|
||||||
return request({
|
return request({
|
||||||
url:'/critical-data/'+queryParams.id ,
|
url:'/critical-data/'+queryParams.id ,
|
||||||
@ -40,7 +40,7 @@ export function deleteCriticalData (queryParams:any){
|
|||||||
// params: queryParams
|
// params: queryParams
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
//多选删除项目
|
//多选删除临界数据
|
||||||
export function deleteBatchCriticalData (queryParams:any){
|
export function deleteBatchCriticalData (queryParams:any){
|
||||||
return request({
|
return request({
|
||||||
url:'/critical-data',
|
url:'/critical-data',
|
||||||
@ -48,3 +48,13 @@ export function deleteBatchCriticalData (queryParams:any){
|
|||||||
data: queryParams
|
data: queryParams
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
// 导出临界数据
|
||||||
|
export function exportAllExports(deviceType:any){
|
||||||
|
let url = '/critical-data/v2/export/?deviceType='+deviceType
|
||||||
|
|
||||||
|
return request({
|
||||||
|
url: url ,
|
||||||
|
method: 'get',
|
||||||
|
responseType: 'arraybuffer'
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
import request from '@/utils/request';
|
import request from '@/utils/request';
|
||||||
|
|
||||||
//获取所有项目列表
|
//获取所有设备列表
|
||||||
export function searchDevicesPage(queryParams:any){
|
export function searchDevicesPage(queryParams:any){
|
||||||
return request({
|
return request({
|
||||||
url: '/devices/search' ,
|
url: '/devices/search' ,
|
||||||
@ -12,7 +12,7 @@ export function searchDevicesPage(queryParams:any){
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
//新增项目
|
//新增设备
|
||||||
export function addDevices(data:any){
|
export function addDevices(data:any){
|
||||||
return request({
|
return request({
|
||||||
url:'/devices' ,
|
url:'/devices' ,
|
||||||
@ -22,7 +22,7 @@ export function addDevices(data:any){
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//更新项目信息
|
//更新设备信息
|
||||||
export function updateDevices (queryParams:any){
|
export function updateDevices (queryParams:any){
|
||||||
return request({
|
return request({
|
||||||
url:'/devices' ,
|
url:'/devices' ,
|
||||||
@ -32,7 +32,7 @@ export function updateDevices (queryParams:any){
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//单个删除项目
|
//单个删除设备
|
||||||
export function deleteDevices (queryParams:any){
|
export function deleteDevices (queryParams:any){
|
||||||
return request({
|
return request({
|
||||||
url:'/devices/'+queryParams.id ,
|
url:'/devices/'+queryParams.id ,
|
||||||
@ -40,7 +40,7 @@ export function deleteDevices (queryParams:any){
|
|||||||
// params: queryParams
|
// params: queryParams
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
//多选删除项目
|
//多选删除设备
|
||||||
export function deleteBatchDevices (queryParams:any){
|
export function deleteBatchDevices (queryParams:any){
|
||||||
return request({
|
return request({
|
||||||
url:'/devices',
|
url:'/devices',
|
||||||
@ -50,7 +50,7 @@ export function deleteBatchDevices (queryParams:any){
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//获取所有项目列表
|
//获取所有设备列表
|
||||||
export function sizeSchemaAll(queryParams:any){
|
export function sizeSchemaAll(queryParams:any){
|
||||||
return request({
|
return request({
|
||||||
url: '/devices/v2/size-schema/all' ,
|
url: '/devices/v2/size-schema/all' ,
|
||||||
@ -59,4 +59,13 @@ export function sizeSchemaAll(queryParams:any){
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 导出全部结果
|
||||||
|
export function exportAllExports(deviceType:any){
|
||||||
|
let url = '/devices/v2/export/?deviceType='+deviceType
|
||||||
|
|
||||||
|
return request({
|
||||||
|
url: url ,
|
||||||
|
method: 'get',
|
||||||
|
responseType: 'arraybuffer'
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
import request from '@/utils/request';
|
import request from '@/utils/request';
|
||||||
|
|
||||||
//获取所有项目列表
|
//获取所有物料列表
|
||||||
export function searchMaterialsPage(queryParams:any){
|
export function searchMaterialsPage(queryParams:any){
|
||||||
return request({
|
return request({
|
||||||
url: '/materials/search' ,
|
url: '/materials/search' ,
|
||||||
@ -13,7 +13,7 @@ export function searchMaterialsPage(queryParams:any){
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
//拓扑图新增或更新项目
|
//拓扑图新增或更新物料
|
||||||
export function saveOrUpdate(data:any){
|
export function saveOrUpdate(data:any){
|
||||||
return request({
|
return request({
|
||||||
url:'/materials/saveOrUpdate' ,
|
url:'/materials/saveOrUpdate' ,
|
||||||
@ -23,7 +23,7 @@ export function saveOrUpdate(data:any){
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//新增项目
|
//新增物料
|
||||||
export function addMaterials(data:any){
|
export function addMaterials(data:any){
|
||||||
return request({
|
return request({
|
||||||
url:'/materials' ,
|
url:'/materials' ,
|
||||||
@ -33,7 +33,7 @@ export function addMaterials(data:any){
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//更新项目信息
|
//更新物料信息
|
||||||
export function updateMaterials (queryParams:any){
|
export function updateMaterials (queryParams:any){
|
||||||
return request({
|
return request({
|
||||||
url:'/materials' ,
|
url:'/materials' ,
|
||||||
@ -43,7 +43,7 @@ export function updateMaterials (queryParams:any){
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//单个删除项目
|
//单个删除物料
|
||||||
export function deleteMaterials (queryParams:any){
|
export function deleteMaterials (queryParams:any){
|
||||||
return request({
|
return request({
|
||||||
url:'/materials/'+queryParams.id ,
|
url:'/materials/'+queryParams.id ,
|
||||||
@ -51,7 +51,7 @@ export function deleteMaterials (queryParams:any){
|
|||||||
// params: queryParams
|
// params: queryParams
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
//多选删除项目
|
//多选删除物料
|
||||||
export function deleteBatchMaterials (queryParams:any){
|
export function deleteBatchMaterials (queryParams:any){
|
||||||
return request({
|
return request({
|
||||||
url:'/materials',
|
url:'/materials',
|
||||||
@ -59,3 +59,23 @@ export function deleteBatchMaterials (queryParams:any){
|
|||||||
data: queryParams
|
data: queryParams
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// 导出物料
|
||||||
|
export function exportAllExports(){
|
||||||
|
let url = '/materials/export'
|
||||||
|
return request({
|
||||||
|
url: url ,
|
||||||
|
method: 'get',
|
||||||
|
responseType: 'arraybuffer'
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
//查看物料
|
||||||
|
export function materialsById (id:any){
|
||||||
|
return request({
|
||||||
|
url:'/materials/'+id ,
|
||||||
|
method: 'get'
|
||||||
|
// params: queryParams
|
||||||
|
});
|
||||||
|
}
|
||||||
@ -16,6 +16,11 @@ const props = defineProps({
|
|||||||
type: Object,
|
type: Object,
|
||||||
default: {}
|
default: {}
|
||||||
},
|
},
|
||||||
|
sizeSchemaInfo: {
|
||||||
|
required: false,
|
||||||
|
type: Object,
|
||||||
|
default: {}
|
||||||
|
},
|
||||||
deviceId: {
|
deviceId: {
|
||||||
required: false,
|
required: false,
|
||||||
type: String,
|
type: String,
|
||||||
@ -27,6 +32,7 @@ const props = defineProps({
|
|||||||
default: ''
|
default: ''
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
const sourceTempData:any = ref([])
|
||||||
const input = ref('') // 设备名称
|
const input = ref('') // 设备名称
|
||||||
const loading = ref(false) // 加载中
|
const loading = ref(false) // 加载中
|
||||||
const tableData = ref([]) // 表格数据
|
const tableData = ref([]) // 表格数据
|
||||||
@ -44,55 +50,56 @@ if(deviceTypetype.value == ''){
|
|||||||
loading.value = true;
|
loading.value = true;
|
||||||
searchDevicesPage(params).then((result:any) => {
|
searchDevicesPage(params).then((result:any) => {
|
||||||
result.records.forEach((item:any) => {
|
result.records.forEach((item:any) => {
|
||||||
if(deviceTypetype.value == 'FlatTank'){ // 扁平槽
|
item.size = JSON.parse(item.size)
|
||||||
let sizeInfo =JSON.parse(item.size)
|
// if(deviceTypetype.value == 'FlatTank'){ // 扁平槽
|
||||||
item['length'] = sizeInfo.length
|
// let sizeInfo =JSON.parse(item.size)
|
||||||
item['width'] = sizeInfo.width
|
// item['length'] = sizeInfo.length
|
||||||
item['height'] = sizeInfo.height
|
// item['width'] = sizeInfo.width
|
||||||
}
|
// item['height'] = sizeInfo.height
|
||||||
if(deviceTypetype.value == 'CylindricalTank'){ // 圆柱槽
|
// }
|
||||||
let sizeInfo =JSON.parse(item.size)
|
// if(deviceTypetype.value == 'CylindricalTank'){ // 圆柱槽
|
||||||
item['diameter'] = sizeInfo.diameter
|
// let sizeInfo =JSON.parse(item.size)
|
||||||
item['height'] = sizeInfo.height
|
// item['diameter'] = sizeInfo.diameter
|
||||||
}
|
// item['height'] = sizeInfo.height
|
||||||
if(deviceTypetype.value == 'AnnularTank'){ // 环形槽
|
// }
|
||||||
let sizeInfo =JSON.parse(item.size)
|
// if(deviceTypetype.value == 'AnnularTank'){ // 环形槽
|
||||||
item['outer_diameter'] = sizeInfo.outer_diameter
|
// let sizeInfo =JSON.parse(item.size)
|
||||||
item['height'] = sizeInfo.height
|
// item['outer_diameter'] = sizeInfo.outer_diameter
|
||||||
}
|
// item['height'] = sizeInfo.height
|
||||||
|
// }
|
||||||
|
|
||||||
if(deviceTypetype.value == 'TubeBundleTank'){ // 管束槽
|
// if(deviceTypetype.value == 'TubeBundleTank'){ // 管束槽
|
||||||
let sizeInfo =JSON.parse(item.size)
|
// let sizeInfo =JSON.parse(item.size)
|
||||||
item['outer_diameter'] = sizeInfo.outer_diameter
|
// item['outer_diameter'] = sizeInfo.outer_diameter
|
||||||
item['height'] = sizeInfo.height
|
// item['height'] = sizeInfo.height
|
||||||
}
|
// }
|
||||||
if(deviceTypetype.value == 'ExtractionColumn'){ // 萃取柱
|
// if(deviceTypetype.value == 'ExtractionColumn'){ // 萃取柱
|
||||||
let sizeInfo =JSON.parse(item.size)
|
// let sizeInfo =JSON.parse(item.size)
|
||||||
item['upper_expanded_diameter'] = sizeInfo.upper_expanded.diameter
|
// item['upper_expanded_diameter'] = sizeInfo.upper_expanded.diameter
|
||||||
item['upper_expanded_height'] = sizeInfo.upper_expanded.height
|
// item['upper_expanded_height'] = sizeInfo.upper_expanded.height
|
||||||
item['tray_section_diameter'] = sizeInfo.tray_section.diameter
|
// item['tray_section_diameter'] = sizeInfo.tray_section.diameter
|
||||||
item['tray_section_height'] = sizeInfo.tray_section.height
|
// item['tray_section_height'] = sizeInfo.tray_section.height
|
||||||
item['lower_expanded_diameter'] = sizeInfo.lower_expanded.diameter
|
// item['lower_expanded_diameter'] = sizeInfo.lower_expanded.diameter
|
||||||
item['lower_expanded_height'] = sizeInfo.lower_expanded.height
|
// item['lower_expanded_height'] = sizeInfo.lower_expanded.height
|
||||||
}
|
// }
|
||||||
if(deviceTypetype.value == 'FluidizedBed'){ // 流化床
|
// if(deviceTypetype.value == 'FluidizedBed'){ // 流化床
|
||||||
let sizeInfo =JSON.parse(item.size)
|
// let sizeInfo =JSON.parse(item.size)
|
||||||
item['expanded_section_diameter'] = sizeInfo.expanded_section.diameter
|
// item['expanded_section_diameter'] = sizeInfo.expanded_section.diameter
|
||||||
item['expanded_section_height'] = sizeInfo.expanded_section.height
|
// item['expanded_section_height'] = sizeInfo.expanded_section.height
|
||||||
|
|
||||||
item['transition_section_height'] = sizeInfo.transition_section.height
|
// item['transition_section_height'] = sizeInfo.transition_section.height
|
||||||
|
|
||||||
|
|
||||||
item['reaction_section_diameter'] = sizeInfo.reaction_section.diameter
|
// item['reaction_section_diameter'] = sizeInfo.reaction_section.diameter
|
||||||
item['reaction_section_height'] = sizeInfo.reaction_section.height
|
// item['reaction_section_height'] = sizeInfo.reaction_section.height
|
||||||
}
|
// }
|
||||||
if(deviceTypetype.value == 'ACFTank'){ // 锥底环形槽
|
// if(deviceTypetype.value == 'ACFTank'){ // 锥底环形槽
|
||||||
let sizeInfo =JSON.parse(item.size)
|
// let sizeInfo =JSON.parse(item.size)
|
||||||
item['annular_cylinder_outer_diameter'] = sizeInfo.annular_cylinder.outer_diameter
|
// item['annular_cylinder_outer_diameter'] = sizeInfo.annular_cylinder.outer_diameter
|
||||||
item['annular_cylinder_height'] = sizeInfo.annular_cylinder.height
|
// item['annular_cylinder_height'] = sizeInfo.annular_cylinder.height
|
||||||
item['frustum_bottom_bottom_diameter'] = sizeInfo.frustum_bottom.bottom_diameter
|
// item['frustum_bottom_bottom_diameter'] = sizeInfo.frustum_bottom.bottom_diameter
|
||||||
item['frustum_bottom_height'] = sizeInfo.frustum_bottom.height
|
// item['frustum_bottom_height'] = sizeInfo.frustum_bottom.height
|
||||||
}
|
// }
|
||||||
|
|
||||||
})
|
})
|
||||||
tableData.value = result.records;
|
tableData.value = result.records;
|
||||||
@ -110,7 +117,7 @@ function confirmDevice(){ // 确定添加设备
|
|||||||
const params = {
|
const params = {
|
||||||
projectId: props.projectInfo.projectId,
|
projectId: props.projectInfo.projectId,
|
||||||
deviceId: props.deviceId,
|
deviceId: props.deviceId,
|
||||||
size: selectedDevice.value.size,
|
size: JSON.stringify(selectedDevice.value.size),
|
||||||
code: selectedDevice.value.code,
|
code: selectedDevice.value.code,
|
||||||
name: selectedDevice.value.name,
|
name: selectedDevice.value.name,
|
||||||
type: selectedDevice.value.type,
|
type: selectedDevice.value.type,
|
||||||
@ -130,7 +137,7 @@ function confirmClick(formEl: any) {
|
|||||||
if (valid) {
|
if (valid) {
|
||||||
const params = {
|
const params = {
|
||||||
...info.value,
|
...info.value,
|
||||||
size: JSON.stringify( josnInfo.value),
|
size: JSON.stringify( info.value.size),
|
||||||
projectId: props.projectInfo.projectId,
|
projectId: props.projectInfo.projectId,
|
||||||
deviceId: props.deviceId
|
deviceId: props.deviceId
|
||||||
}
|
}
|
||||||
@ -143,22 +150,28 @@ function confirmClick(formEl: any) {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
const info: any = ref({
|
||||||
|
name: "",
|
||||||
|
code: "",
|
||||||
|
type: null,
|
||||||
|
size: {},
|
||||||
|
volume: null,
|
||||||
|
flowRate: null,
|
||||||
|
pulseVelocity: null
|
||||||
|
});
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
|
// sizeSchemaInfo.value = props.sizeSchemaInfo
|
||||||
|
sourceTempData.value = props.sizeSchemaInfo[props.deviceTypetype].fields
|
||||||
|
sourceTempData.value.forEach((item:any) => {
|
||||||
|
info.value.size[item.key] = null
|
||||||
|
})
|
||||||
|
// sizeSchemaInfo.value[queryParams.value.type]
|
||||||
gettableData()
|
gettableData()
|
||||||
|
|
||||||
});
|
});
|
||||||
const infoForm = ref();
|
const infoForm = ref();
|
||||||
const isAdd = ref(false) // 是否添加设备
|
const isAdd = ref(false) // 是否添加设备
|
||||||
const info: any = ref({
|
|
||||||
name: "",
|
|
||||||
code: "",
|
|
||||||
type: null,
|
|
||||||
size: null,
|
|
||||||
volume: null,
|
|
||||||
flowRate: null,
|
|
||||||
pulseVelocity: null
|
|
||||||
});
|
|
||||||
const josnInfo: any = ref({}) // 设备信息
|
const josnInfo: any = ref({}) // 设备信息
|
||||||
const rules = ref({
|
const rules = ref({
|
||||||
name: [{ required: true, message: "请输入设备名称", trigger: "blur" }],
|
name: [{ required: true, message: "请输入设备名称", trigger: "blur" }],
|
||||||
@ -169,30 +182,30 @@ function addClick() {
|
|||||||
name: "",
|
name: "",
|
||||||
code: "",
|
code: "",
|
||||||
type: props.deviceTypetype,
|
type: props.deviceTypetype,
|
||||||
size: null,
|
size: {},
|
||||||
volume: null,
|
volume: null,
|
||||||
flowRate: null,
|
flowRate: null,
|
||||||
pulseVelocity: null
|
pulseVelocity: null
|
||||||
};
|
};
|
||||||
josnInfo.value = {}
|
// josnInfo.value = {}
|
||||||
if(props.deviceTypetype == 'ExtractionColumn'){
|
// if(props.deviceTypetype == 'ExtractionColumn'){
|
||||||
josnInfo.value = {
|
// josnInfo.value = {
|
||||||
tray_section:{},
|
// tray_section:{},
|
||||||
lower_expanded:{},
|
// lower_expanded:{},
|
||||||
upper_expanded:{}
|
// upper_expanded:{}
|
||||||
}
|
// }
|
||||||
}else if(props.deviceTypetype == 'FluidizedBed'){
|
// }else if(props.deviceTypetype == 'FluidizedBed'){
|
||||||
josnInfo.value = {
|
// josnInfo.value = {
|
||||||
expanded_section:{},
|
// expanded_section:{},
|
||||||
reaction_section:{},
|
// reaction_section:{},
|
||||||
transition_section:{}
|
// transition_section:{}
|
||||||
}
|
// }
|
||||||
}else if(props.deviceTypetype == 'ACFTank'){
|
// }else if(props.deviceTypetype == 'ACFTank'){
|
||||||
josnInfo.value = {
|
// josnInfo.value = {
|
||||||
frustum_bottom:{},
|
// frustum_bottom:{},
|
||||||
annular_cylinder:{}
|
// annular_cylinder:{}
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
isAdd.value = true
|
isAdd.value = true
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
@ -215,30 +228,11 @@ function addClick() {
|
|||||||
@cell-click="selectPatient" highlight-current-row row-key="id" :header-cell-style="{ background: 'rgb(250 250 250)', color: '#383838', height: '50px' }">
|
@cell-click="selectPatient" highlight-current-row row-key="id" :header-cell-style="{ background: 'rgb(250 250 250)', color: '#383838', height: '50px' }">
|
||||||
<el-table-column type="index" label="序号" width="70" align="center"></el-table-column>
|
<el-table-column type="index" label="序号" width="70" align="center"></el-table-column>
|
||||||
<el-table-column prop="name" label="设备名称" min-width="180"></el-table-column>
|
<el-table-column prop="name" label="设备名称" min-width="180"></el-table-column>
|
||||||
<el-table-column v-if="deviceTypetype == 'FlatTank'" prop="length" label="长度(cm)" min-width="100"></el-table-column>
|
<el-table-column v-for="(item,index) in sourceTempData" :label="item.label" min-width="100">
|
||||||
<el-table-column v-if="deviceTypetype == 'FlatTank'" prop="width" label="宽度(cm)" min-width="100"></el-table-column>
|
<template #default="scope">
|
||||||
<el-table-column v-if="deviceTypetype == 'FlatTank'" prop="height" label="高度(cm)" min-width="100"></el-table-column>
|
{{ scope.row.size[item.key] }}
|
||||||
<el-table-column v-if="deviceTypetype == 'CylindricalTank'" prop="diameter" label="直径(cm)" min-width="100"></el-table-column>
|
</template>
|
||||||
<el-table-column v-if="deviceTypetype == 'CylindricalTank'" prop="height" label="高度(cm)" min-width="100"></el-table-column>
|
</el-table-column>
|
||||||
<el-table-column v-if="deviceTypetype == 'AnnularTank'" prop="outer_diameter" label="环形槽外径(cm)" min-width="100"></el-table-column>
|
|
||||||
<el-table-column v-if="deviceTypetype == 'AnnularTank'" prop="height" label="环形槽高度(cm)" min-width="100"></el-table-column>
|
|
||||||
<el-table-column v-if="deviceTypetype == 'TubeBundleTank'" prop="outer_diameter" label="外径(cm)" min-width="100"></el-table-column>
|
|
||||||
<el-table-column v-if="deviceTypetype == 'TubeBundleTank'" prop="height" label="高度(cm)" min-width="100"></el-table-column>
|
|
||||||
<el-table-column v-if="deviceTypetype == 'ExtractionColumn'" prop="upper_expanded_diameter" label="上扩大段直径(cm)" min-width="100"></el-table-column>
|
|
||||||
<el-table-column v-if="deviceTypetype == 'ExtractionColumn'" prop="upper_expanded_height" label="上扩大段高度(cm)" min-width="100"></el-table-column>
|
|
||||||
<el-table-column v-if="deviceTypetype == 'ExtractionColumn'" prop="tray_section_diameter" label="板段直径(cm)" min-width="100"></el-table-column>
|
|
||||||
<el-table-column v-if="deviceTypetype == 'ExtractionColumn'" prop="tray_section_height" label="板段高度(cm)" min-width="100"></el-table-column>
|
|
||||||
<el-table-column v-if="deviceTypetype == 'ExtractionColumn'" prop="lower_expanded_diameter" label="下扩大段直径(cm)" min-width="100"></el-table-column>
|
|
||||||
<el-table-column v-if="deviceTypetype == 'ExtractionColumn'" prop="lower_expanded_height" label="下扩大段高度(cm)" min-width="100"></el-table-column>
|
|
||||||
<el-table-column v-if="deviceTypetype == 'FluidizedBed'" prop="expanded_section_diameter" label="扩大段直径(cm)" min-width="100"></el-table-column>
|
|
||||||
<el-table-column v-if="deviceTypetype == 'FluidizedBed'" prop="expanded_section_height" label="扩大段高度(cm)" min-width="100"></el-table-column>
|
|
||||||
<el-table-column v-if="deviceTypetype == 'FluidizedBed'" prop="transition_section_height" label="过渡段高度(cm)" min-width="100"></el-table-column>
|
|
||||||
<el-table-column v-if="deviceTypetype == 'FluidizedBed'" prop="reaction_section_diameter" label="反应段直径(cm)" min-width="100"></el-table-column>
|
|
||||||
<el-table-column v-if="deviceTypetype == 'FluidizedBed'" prop="reaction_section_height" label="反应段高度(cm)" min-width="100"></el-table-column>
|
|
||||||
<el-table-column v-if="deviceTypetype == 'ACFTank'" prop="annular_cylinder_outer_diameter" label="环形圆柱外径(cm)" min-width="100"></el-table-column>
|
|
||||||
<el-table-column v-if="deviceTypetype == 'ACFTank'" prop="annular_cylinder_height" label="环形圆柱高度(cm)" min-width="100"></el-table-column>
|
|
||||||
<el-table-column v-if="deviceTypetype == 'ACFTank'" prop="frustum_bottom_bottom_diameter" label="圆锥台底部直径(cm)" min-width="100"></el-table-column>
|
|
||||||
<el-table-column v-if="deviceTypetype == 'ACFTank'" prop="frustum_bottom_height" label="圆锥台底部高度(cm)" min-width="100"></el-table-column>
|
|
||||||
<el-table-column prop="volume" label="容量(L)" width="120"></el-table-column>
|
<el-table-column prop="volume" label="容量(L)" width="120"></el-table-column>
|
||||||
<el-table-column prop="flowRate" label="流量(m³/h)" width="120"></el-table-column>
|
<el-table-column prop="flowRate" label="流量(m³/h)" width="120"></el-table-column>
|
||||||
<el-table-column prop="pulseVelocity" label="脉冲速度(Hz)" width="120"></el-table-column>
|
<el-table-column prop="pulseVelocity" label="脉冲速度(Hz)" width="120"></el-table-column>
|
||||||
@ -246,341 +240,25 @@ function addClick() {
|
|||||||
</div>
|
</div>
|
||||||
<div v-if="isAdd == true">
|
<div v-if="isAdd == true">
|
||||||
<el-form ref="infoForm" :model="info" :rules="rules" label-width="120px" v-if="isAdd == true"
|
<el-form ref="infoForm" :model="info" :rules="rules" label-width="120px" v-if="isAdd == true"
|
||||||
style="width: 100%;height: calc(100vh - 340px);margin-top: 30px;">
|
style="width: 100%;max-height: calc(100vh - 300px);margin-top: 20px;overflow: auto;">
|
||||||
<el-form-item label="设备编号" prop="code" style="width: 100%;">
|
<el-form-item label="设备编号" prop="code" style="width: 100%;">
|
||||||
<el-input v-model="info.code" style="width: 100%" placeholder="请输入设备编号"></el-input>
|
<el-input v-model="info.code" style="width: 100%" placeholder="请输入设备编号"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="设备名称" prop="name" style="width: 100%;">
|
<el-form-item label="设备名称" prop="name" style="width: 100%;">
|
||||||
<el-input v-model="info.name" style="width: 100%" placeholder="请输入设备名称"></el-input>
|
<el-input v-model="info.name" style="width: 100%" placeholder="请输入设备名称"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<div v-if="deviceTypetype == 'FlatTank'">
|
<el-form-item :label="item.label" style="width: 100%;" v-for="item in sourceTempData">
|
||||||
<el-form-item label="长度" style="width: 100%;">
|
<el-input-number
|
||||||
<el-input-number
|
placeholder="请输入长度"
|
||||||
placeholder="请输入长度"
|
v-model="info.size[item.key]"
|
||||||
v-model="josnInfo['length']"
|
:min="0"
|
||||||
:min="0"
|
align="left"
|
||||||
align="left"
|
:controls="false"
|
||||||
:controls="false"
|
style="width: 100%"
|
||||||
style="width: 100%"
|
>
|
||||||
>
|
<template #suffix>{{item.unit}}</template>
|
||||||
<template #suffix>cm</template>
|
</el-input-number>
|
||||||
</el-input-number>
|
</el-form-item>
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="宽度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入宽度"
|
|
||||||
v-model="josnInfo.width"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div v-if="deviceTypetype == 'CylindricalTank'">
|
|
||||||
<el-form-item label="直径" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入直径"
|
|
||||||
v-model="josnInfo.diameter"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div v-if="deviceTypetype == 'AnnularTank'">
|
|
||||||
<el-form-item label="环形槽外径" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入直径"
|
|
||||||
v-model="josnInfo.outer_diameter"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="环形槽高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div v-if="deviceTypetype == 'TubeBundleTank'">
|
|
||||||
<el-form-item label="外径" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入直径"
|
|
||||||
v-model="josnInfo.outer_diameter"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
<div v-if="deviceTypetype == 'ExtractionColumn'">
|
|
||||||
<div class="flex">
|
|
||||||
<el-form-item label="上扩大段直径" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入直径"
|
|
||||||
v-model="josnInfo.upper_expanded.diameter"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="上扩大段高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.upper_expanded.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
<div class="flex">
|
|
||||||
<el-form-item label="板段直径" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入直径"
|
|
||||||
v-model="josnInfo.tray_section.diameter"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="板段高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.tray_section.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
<div class="flex">
|
|
||||||
<el-form-item label="下扩大段直径" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入直径"
|
|
||||||
v-model="josnInfo.lower_expanded.diameter"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
|
|
||||||
<el-form-item label="下扩大段高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.lower_expanded.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div v-if="deviceTypetype == 'FluidizedBed'">
|
|
||||||
<div class="flex">
|
|
||||||
<el-form-item label="扩大段直径" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入直径"
|
|
||||||
v-model="josnInfo.expanded_section.diameter"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="扩大段高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.expanded_section.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<el-form-item label="过渡段高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.transition_section.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<div class="flex">
|
|
||||||
<el-form-item label="反应段直径" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入直径"
|
|
||||||
v-model="josnInfo.reaction_section.diameter"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="反应段高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.reaction_section.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div v-if="deviceTypetype == 'ACFTank'">
|
|
||||||
<div class="flex">
|
|
||||||
<el-form-item label="环形圆柱外径" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入外径"
|
|
||||||
v-model="josnInfo.annular_cylinder.outer_diameter"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="环形圆柱高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.annular_cylinder.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
<div class="flex">
|
|
||||||
<el-form-item label="圆锥台底部直径" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入直径"
|
|
||||||
v-model="josnInfo.frustum_bottom.bottom_diameter"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="圆锥台底部高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.frustum_bottom.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<el-form-item label="容量" style="width: 100%;">
|
<el-form-item label="容量" style="width: 100%;">
|
||||||
<el-input-number
|
<el-input-number
|
||||||
placeholder="请输入容量"
|
placeholder="请输入容量"
|
||||||
@ -606,16 +284,16 @@ function addClick() {
|
|||||||
</el-input-number>
|
</el-input-number>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="脉冲速度" style="width: 100%;">
|
<el-form-item label="脉冲速度" style="width: 100%;">
|
||||||
<el-input-number
|
<el-input-number
|
||||||
placeholder="请输入脉冲速度"
|
placeholder="请输入脉冲速度"
|
||||||
v-model="info.pulseVelocity"
|
v-model="info.pulseVelocity"
|
||||||
:min="0"
|
:min="0"
|
||||||
align="left"
|
align="left"
|
||||||
:controls="false"
|
:controls="false"
|
||||||
style="width: 100%"
|
style="width: 100%"
|
||||||
>
|
>
|
||||||
<template #suffix>Hz</template>
|
<template #suffix>Hz</template>
|
||||||
</el-input-number>
|
</el-input-number>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- <span class="dialog-footer"
|
<!-- <span class="dialog-footer"
|
||||||
style="display: flex;display: -webkit-flex; justify-content: flex-end;-webkit-justify-content: flex-end;">
|
style="display: flex;display: -webkit-flex; justify-content: flex-end;-webkit-justify-content: flex-end;">
|
||||||
|
|||||||
@ -17,49 +17,56 @@ function getName(code:any) {
|
|||||||
key: '',
|
key: '',
|
||||||
type: ''
|
type: ''
|
||||||
}
|
}
|
||||||
|
if( getFormula(deviceType.value ,code).isDevice == true){
|
||||||
|
return tempInfo = {
|
||||||
|
name: getFormula(deviceType.value ,code).label,
|
||||||
|
key: getFormula(deviceType.value ,code).key,
|
||||||
|
type: 'device'
|
||||||
|
};
|
||||||
|
}
|
||||||
switch (code) {
|
switch (code) {
|
||||||
case 'width':
|
// case 'width':
|
||||||
return tempInfo = {
|
// return tempInfo = {
|
||||||
name: "宽度cm",
|
// name: "宽度cm",
|
||||||
key: 'width',
|
// key: 'width',
|
||||||
type: 'device'
|
// type: 'device'
|
||||||
};
|
// };
|
||||||
break;
|
// break;
|
||||||
case 'outer_diameter':
|
// case 'outer_diameter':
|
||||||
return tempInfo = {
|
// return tempInfo = {
|
||||||
name: "外径cm",
|
// name: "外径cm",
|
||||||
key: 'outer_diameter',
|
// key: 'outer_diameter',
|
||||||
type: 'device'
|
// type: 'device'
|
||||||
};
|
// };
|
||||||
break;
|
// break;
|
||||||
case 'height':
|
// case 'height':
|
||||||
return tempInfo = {
|
// return tempInfo = {
|
||||||
name: "高度cm",
|
// name: "高度cm",
|
||||||
key: 'height',
|
// key: 'height',
|
||||||
type: 'device'
|
// type: 'device'
|
||||||
};
|
// };
|
||||||
break;
|
// break;
|
||||||
case 'length':
|
// case 'length':
|
||||||
return tempInfo = {
|
// return tempInfo = {
|
||||||
name: "长度cm",
|
// name: "长度cm",
|
||||||
key: 'length',
|
// key: 'length',
|
||||||
type: 'device'
|
// type: 'device'
|
||||||
};
|
// };
|
||||||
break;
|
// break;
|
||||||
case 'diameter':
|
// case 'diameter':
|
||||||
return tempInfo = {
|
// return tempInfo = {
|
||||||
name: "外径cm",
|
// name: "外径cm",
|
||||||
key: 'diameter',
|
// key: 'diameter',
|
||||||
type: 'device'
|
// type: 'device'
|
||||||
};
|
// };
|
||||||
break;
|
// break;
|
||||||
case 'volume':
|
// case 'volume':
|
||||||
return tempInfo = {
|
// return tempInfo = {
|
||||||
name: "体积(单位:L)",
|
// name: "体积(单位:L)",
|
||||||
key: 'volume',
|
// key: 'volume',
|
||||||
type: 'device'
|
// type: 'device'
|
||||||
};
|
// };
|
||||||
break;
|
// break;
|
||||||
case 'flow_rate':
|
case 'flow_rate':
|
||||||
return tempInfo = {
|
return tempInfo = {
|
||||||
name: "流量(单位:m3/h)",
|
name: "流量(单位:m3/h)",
|
||||||
@ -90,7 +97,7 @@ function getName(code:any) {
|
|||||||
break;
|
break;
|
||||||
case 'u_enrichment':
|
case 'u_enrichment':
|
||||||
return tempInfo = {
|
return tempInfo = {
|
||||||
name: "铀富集度(%)",
|
name: "铀富集度",
|
||||||
key: 'u_enrichment',
|
key: 'u_enrichment',
|
||||||
type: 'material'
|
type: 'material'
|
||||||
};
|
};
|
||||||
@ -109,10 +116,39 @@ function getName(code:any) {
|
|||||||
type: 'material'
|
type: 'material'
|
||||||
};
|
};
|
||||||
break;
|
break;
|
||||||
case 'pu_isotope':
|
case 'e_pu238':
|
||||||
return tempInfo = {
|
return tempInfo = {
|
||||||
name: "钚同位素比例(PU-240占比)%",
|
name: "PU-238占比",
|
||||||
key: 'pu_isotope',
|
key: 'e_pu238',
|
||||||
|
type: 'material'
|
||||||
|
};
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 'e_pu239':
|
||||||
|
return tempInfo = {
|
||||||
|
name: "PU-239占比",
|
||||||
|
key: 'e_pu239',
|
||||||
|
type: 'material'
|
||||||
|
};
|
||||||
|
break;
|
||||||
|
case 'e_pu240':
|
||||||
|
return tempInfo = {
|
||||||
|
name: "PU-240占比",
|
||||||
|
key: 'e_pu240',
|
||||||
|
type: 'material'
|
||||||
|
};
|
||||||
|
break;
|
||||||
|
case 'e_pu241':
|
||||||
|
return tempInfo = {
|
||||||
|
name: "PU-241占比",
|
||||||
|
key: 'e_pu241',
|
||||||
|
type: 'material'
|
||||||
|
};
|
||||||
|
break;
|
||||||
|
case 'e_pu242':
|
||||||
|
return tempInfo = {
|
||||||
|
name: "PU-242占比",
|
||||||
|
key: 'e_pu242',
|
||||||
type: 'material'
|
type: 'material'
|
||||||
};
|
};
|
||||||
break;
|
break;
|
||||||
@ -132,14 +168,14 @@ function getName(code:any) {
|
|||||||
break;
|
break;
|
||||||
case 'organic_ratio':
|
case 'organic_ratio':
|
||||||
return tempInfo = {
|
return tempInfo = {
|
||||||
name: "有机相比例%",
|
name: "有机相比例",
|
||||||
key: 'organic_ratio',
|
key: 'organic_ratio',
|
||||||
type: 'material'
|
type: 'material'
|
||||||
};
|
};
|
||||||
break;
|
break;
|
||||||
case 'moisture_content':
|
case 'moisture_content':
|
||||||
return tempInfo = {
|
return tempInfo = {
|
||||||
name: "含水率%",
|
name: "含水率",
|
||||||
key: 'moisture_content',
|
key: 'moisture_content',
|
||||||
type: 'material'
|
type: 'material'
|
||||||
};
|
};
|
||||||
@ -154,12 +190,38 @@ function getName(code:any) {
|
|||||||
return tempInfo
|
return tempInfo
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const getFormula:any = (deviceType:any,code:any)=>{
|
||||||
|
let deviceTemp = {
|
||||||
|
isDevice: false,
|
||||||
|
label: '',
|
||||||
|
key: '',
|
||||||
|
}
|
||||||
|
let tempFields = props.sizeSchemaInfo[deviceType].fields
|
||||||
|
for(let i = 0; i < tempFields.length; i++){
|
||||||
|
if(tempFields[i].key == code){
|
||||||
|
deviceTemp = {
|
||||||
|
isDevice: true,
|
||||||
|
label:tempFields[i].label,
|
||||||
|
key: tempFields[i].key,
|
||||||
|
}
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return deviceTemp
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
projectInfo: {
|
projectInfo: {
|
||||||
required: false,
|
required: false,
|
||||||
type: Object,
|
type: Object,
|
||||||
default: {}
|
default: {}
|
||||||
},
|
},
|
||||||
|
sizeSchemaInfo:{
|
||||||
|
required: false,
|
||||||
|
type: Object,
|
||||||
|
default: {}
|
||||||
|
},
|
||||||
formula: {
|
formula: {
|
||||||
required: false,
|
required: false,
|
||||||
type: String,
|
type: String,
|
||||||
@ -196,7 +258,10 @@ function gettableData() {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
const deviceType:any = ref('')
|
||||||
function handleClick(item:any, index:any){
|
function handleClick(item:any, index:any){
|
||||||
|
deviceType.value = item.deviceType
|
||||||
|
|
||||||
attributeList.value = [];
|
attributeList.value = [];
|
||||||
if(item.deviceSize != "" && item.deviceSize != null){
|
if(item.deviceSize != "" && item.deviceSize != null){
|
||||||
let deviceSize = JSON.parse(item.deviceSize);
|
let deviceSize = JSON.parse(item.deviceSize);
|
||||||
|
|||||||
@ -18,7 +18,11 @@ const props = defineProps({
|
|||||||
type: Object,
|
type: Object,
|
||||||
default: {}
|
default: {}
|
||||||
},
|
},
|
||||||
|
sizeSchemaInfo:{
|
||||||
|
required: false,
|
||||||
|
type: Object,
|
||||||
|
default: {}
|
||||||
|
},
|
||||||
deviceInfo:{
|
deviceInfo:{
|
||||||
required: false,
|
required: false,
|
||||||
type: Object,
|
type: Object,
|
||||||
@ -93,7 +97,7 @@ function getInit(row:any){
|
|||||||
correlation: '',
|
correlation: '',
|
||||||
delay: '',
|
delay: '',
|
||||||
},{
|
},{
|
||||||
key: "铀富集度(%)",
|
key: "铀富集度",
|
||||||
name: "u_enrichment",
|
name: "u_enrichment",
|
||||||
value: row.uEnrichment,
|
value: row.uEnrichment,
|
||||||
unit: "%",
|
unit: "%",
|
||||||
@ -117,14 +121,48 @@ function getInit(row:any){
|
|||||||
correlation: '',
|
correlation: '',
|
||||||
delay: '',
|
delay: '',
|
||||||
},{
|
},{
|
||||||
key: "钚同位素比例(PU-240占比)%",
|
key: "PU-238占比",
|
||||||
name: "pu_isotope",
|
name: "e_pu238",
|
||||||
value: row.puIsotope,
|
value: row.ePu238,
|
||||||
unit: "%",
|
unit: "",
|
||||||
formula: '',
|
formula: '',
|
||||||
correlation: '',
|
correlation: '',
|
||||||
delay: '',
|
delay: '',
|
||||||
},{
|
},{
|
||||||
|
key: "PU-239占比",
|
||||||
|
name: "e_pu239",
|
||||||
|
value: row.ePu239,
|
||||||
|
unit: "",
|
||||||
|
formula: '',
|
||||||
|
correlation: '',
|
||||||
|
delay: '',
|
||||||
|
},{
|
||||||
|
key: "PU-240占比",
|
||||||
|
name: "e_pu240",
|
||||||
|
value: row.ePu240,
|
||||||
|
unit: "",
|
||||||
|
formula: '',
|
||||||
|
correlation: '',
|
||||||
|
delay: '',
|
||||||
|
},{
|
||||||
|
key: "PU-241占比",
|
||||||
|
name: "e_pu241",
|
||||||
|
value: row.ePu241,
|
||||||
|
unit: "",
|
||||||
|
formula: '',
|
||||||
|
correlation: '',
|
||||||
|
delay: '',
|
||||||
|
},{
|
||||||
|
key: "PU-242占比",
|
||||||
|
name: "e_pu242",
|
||||||
|
value: row.ePu242,
|
||||||
|
unit: "",
|
||||||
|
formula: '',
|
||||||
|
correlation: '',
|
||||||
|
delay: '',
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
key: "硝酸酸度(mol/L)",
|
key: "硝酸酸度(mol/L)",
|
||||||
name: "hno3_acidity",
|
name: "hno3_acidity",
|
||||||
value: row.hno3Acidity,
|
value: row.hno3Acidity,
|
||||||
@ -138,18 +176,18 @@ function getInit(row:any){
|
|||||||
correlation: '',
|
correlation: '',
|
||||||
delay: '',
|
delay: '',
|
||||||
},{
|
},{
|
||||||
key: "有机相比例%",
|
key: "有机相比例",
|
||||||
name: "organic_ratio",
|
name: "organic_ratio",
|
||||||
value: row.organicRatio,
|
value: row.organicRatio,
|
||||||
unit: "%",
|
unit: "",
|
||||||
formula: '',
|
formula: '',
|
||||||
correlation: '',
|
correlation: '',
|
||||||
delay: '',
|
delay: '',
|
||||||
},{
|
},{
|
||||||
key: "含水率%",
|
key: "含水率",
|
||||||
name: "moisture_content",
|
name: "moisture_content",
|
||||||
value: row.moistureContent,
|
value: row.moistureContent,
|
||||||
unit: "%",
|
unit: "",
|
||||||
formula: '',
|
formula: '',
|
||||||
correlation: '',
|
correlation: '',
|
||||||
delay: '',
|
delay: '',
|
||||||
@ -266,7 +304,7 @@ function closeChangeDialogsettings(e:any){ // 变动公式值设置关闭
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="table-box">
|
<div class="table-box">
|
||||||
<el-table :data="tableData" style="width: 100%" border>
|
<el-table :data="tableData" style="width: 100%;height: calc(100vh - 360px); overflow: auto;" border >
|
||||||
<el-table-column prop="key" label="属性" width="280"></el-table-column>
|
<el-table-column prop="key" label="属性" width="280"></el-table-column>
|
||||||
<el-table-column prop="value" label="值" width="150"></el-table-column>
|
<el-table-column prop="value" label="值" width="150"></el-table-column>
|
||||||
<el-table-column prop="formula" label="计算公式" min-width="100"></el-table-column>
|
<el-table-column prop="formula" label="计算公式" min-width="100"></el-table-column>
|
||||||
@ -360,7 +398,7 @@ function closeChangeDialogsettings(e:any){ // 变动公式值设置关闭
|
|||||||
<el-dialog v-model="isChangeDialogsettings" :close-on-click-modal="false" :modal="false" draggable
|
<el-dialog v-model="isChangeDialogsettings" :close-on-click-modal="false" :modal="false" draggable
|
||||||
:before-close="dialogChangeDialogsettings" title="变动公式值设置" append-to-body width="1280px" class="materialmodel-dialog-box">
|
:before-close="dialogChangeDialogsettings" title="变动公式值设置" append-to-body width="1280px" class="materialmodel-dialog-box">
|
||||||
<ChangeDialogsettings v-if="isChangeDialogsettings" :projectInfo="projectInfo"
|
<ChangeDialogsettings v-if="isChangeDialogsettings" :projectInfo="projectInfo"
|
||||||
:formula = "formula" :formulaData= "formulaData" :delayList="delayList"
|
:formula = "formula" :formulaData= "formulaData" :delayList="delayList" :sizeSchemaInfo="sizeSchemaInfo"
|
||||||
@closeChangeDialogsettings="closeChangeDialogsettings" />
|
@closeChangeDialogsettings="closeChangeDialogsettings" />
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
|
|
||||||
|
|||||||
@ -74,7 +74,7 @@ function getName(code:any) {
|
|||||||
return name = "氧化铀密度(g/cm3)";
|
return name = "氧化铀密度(g/cm3)";
|
||||||
break;
|
break;
|
||||||
case 'u_enrichment':
|
case 'u_enrichment':
|
||||||
return name = "铀富集度(%)";
|
return name = "铀富集度";
|
||||||
break;
|
break;
|
||||||
case 'pu_concentration':
|
case 'pu_concentration':
|
||||||
return name = "钚浓度(g/L)";
|
return name = "钚浓度(g/L)";
|
||||||
@ -83,7 +83,7 @@ function getName(code:any) {
|
|||||||
return name = "氧化钚密度(g/cm3)";
|
return name = "氧化钚密度(g/cm3)";
|
||||||
break;
|
break;
|
||||||
case 'pu_isotope':
|
case 'pu_isotope':
|
||||||
return name = "钚同位素比例(PU-240占比)%";
|
return name = "钚同位素比例(PU-240占比)";
|
||||||
break;
|
break;
|
||||||
case 'hno3_acidity':
|
case 'hno3_acidity':
|
||||||
return name = "硝酸酸度(mol/L)";
|
return name = "硝酸酸度(mol/L)";
|
||||||
@ -92,10 +92,10 @@ function getName(code:any) {
|
|||||||
return name = "草酸浓度(mol/L)";
|
return name = "草酸浓度(mol/L)";
|
||||||
break;
|
break;
|
||||||
case 'organic_ratio':
|
case 'organic_ratio':
|
||||||
return name = "有机相比例%";
|
return name = "有机相比例";
|
||||||
break;
|
break;
|
||||||
case 'moisture_content':
|
case 'moisture_content':
|
||||||
return name = "含水率%";
|
return name = "含水率";
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
return name = "";
|
return name = "";
|
||||||
|
|||||||
@ -16,6 +16,11 @@ const props = defineProps({
|
|||||||
type: Object,
|
type: Object,
|
||||||
default: {}
|
default: {}
|
||||||
},
|
},
|
||||||
|
sizeSchemaInfo: {
|
||||||
|
required: false,
|
||||||
|
type: Object,
|
||||||
|
default: {}
|
||||||
|
},
|
||||||
deviceInfo: {
|
deviceInfo: {
|
||||||
required: false,
|
required: false,
|
||||||
type: Object,
|
type: Object,
|
||||||
@ -37,7 +42,7 @@ function confirmClick(formEl: any) {
|
|||||||
if (valid) {
|
if (valid) {
|
||||||
const params = {
|
const params = {
|
||||||
...info.value,
|
...info.value,
|
||||||
size: JSON.stringify(josnInfo.value)
|
size: JSON.stringify(info.value.size)
|
||||||
}
|
}
|
||||||
|
|
||||||
updateDevices(params).then((res:any) => {
|
updateDevices(params).then((res:any) => {
|
||||||
@ -49,8 +54,9 @@ function confirmClick(formEl: any) {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
const sourceTempData:any = ref([])
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
|
sourceTempData.value = props.sizeSchemaInfo[props.deviceTypetype].fields
|
||||||
editClick(props.deviceInfo)
|
editClick(props.deviceInfo)
|
||||||
|
|
||||||
});
|
});
|
||||||
@ -59,12 +65,11 @@ const info: any = ref({
|
|||||||
name: "",
|
name: "",
|
||||||
code: "",
|
code: "",
|
||||||
type: null,
|
type: null,
|
||||||
size: null,
|
size: {},
|
||||||
volume: null,
|
volume: null,
|
||||||
flowRate: null,
|
flowRate: null,
|
||||||
pulseVelocity: null
|
pulseVelocity: null
|
||||||
});
|
});
|
||||||
const josnInfo: any = ref({}) // 设备信息
|
|
||||||
const rules = ref({
|
const rules = ref({
|
||||||
name: [{ required: true, message: "请输入设备名称", trigger: "blur" }],
|
name: [{ required: true, message: "请输入设备名称", trigger: "blur" }],
|
||||||
code: [{ required: true, message: "请输入设备编码", trigger: "blur" }],
|
code: [{ required: true, message: "请输入设备编码", trigger: "blur" }],
|
||||||
@ -72,10 +77,8 @@ const rules = ref({
|
|||||||
const isEdit = ref(false) // 是否编辑设备
|
const isEdit = ref(false) // 是否编辑设备
|
||||||
function editClick(row: any) {
|
function editClick(row: any) {
|
||||||
info.value = JSON.parse(JSON.stringify(row));
|
info.value = JSON.parse(JSON.stringify(row));
|
||||||
|
info.value.size = JSON.parse(row.size)
|
||||||
|
|
||||||
if(row.size != null){
|
|
||||||
josnInfo.value = JSON.parse(row.size);
|
|
||||||
}
|
|
||||||
isEdit.value = true;
|
isEdit.value = true;
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
@ -84,352 +87,38 @@ function editClick(row: any) {
|
|||||||
<div class="editdevice-box">
|
<div class="editdevice-box">
|
||||||
|
|
||||||
<el-form ref="infoForm" :model="info" :rules="rules" label-width="120px" v-if="isEdit"
|
<el-form ref="infoForm" :model="info" :rules="rules" label-width="120px" v-if="isEdit"
|
||||||
style="width: 100%;height: calc(100vh - 340px);margin-top: 30px;">
|
style="width: 100%;max-height: calc(100vh - 260px);margin-top: 20px;overflow: auto;">
|
||||||
<el-form-item label="设备编号" prop="code" style="width: 100%;">
|
<el-form-item label="设备编号" prop="code" style="width: 100%;">
|
||||||
<el-input v-model="info.code" style="width: 100%" placeholder="请输入设备编号" :disabled="true"></el-input>
|
<el-input v-model="info.code" style="width: 100%" placeholder="请输入设备编号" :disabled="true"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="设备名称" prop="name" style="width: 100%;">
|
<el-form-item label="设备名称" prop="name" style="width: 100%;">
|
||||||
<el-input v-model="info.name" style="width: 100%" placeholder="请输入设备名称"></el-input>
|
<el-input v-model="info.name" style="width: 100%" placeholder="请输入设备名称"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<div v-if="deviceTypetype == 'FlatTank'">
|
|
||||||
<el-form-item label="长度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入长度"
|
|
||||||
v-model="josnInfo['length']"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="宽度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入宽度"
|
|
||||||
v-model="josnInfo.width"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div v-if="deviceTypetype == 'CylindricalTank'">
|
|
||||||
<el-form-item label="直径" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入直径"
|
|
||||||
v-model="josnInfo.diameter"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div v-if="deviceTypetype == 'AnnularTank'">
|
|
||||||
<el-form-item label="环形槽外径" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入直径"
|
|
||||||
v-model="josnInfo.outer_diameter"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="环形槽高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div v-if="deviceTypetype == 'TubeBundleTank'">
|
|
||||||
<el-form-item label="外径" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入直径"
|
|
||||||
v-model="josnInfo.outer_diameter"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
<div v-if="deviceTypetype == 'ExtractionColumn'">
|
|
||||||
<div class="flex">
|
|
||||||
<el-form-item label="上扩大段直径" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入直径"
|
|
||||||
v-model="josnInfo.upper_expanded.diameter"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="上扩大段高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.upper_expanded.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
<div class="flex">
|
|
||||||
<el-form-item label="板段直径" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入直径"
|
|
||||||
v-model="josnInfo.tray_section.diameter"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="板段高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.tray_section.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
<div class="flex">
|
|
||||||
<el-form-item label="下扩大段直径" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入直径"
|
|
||||||
v-model="josnInfo.lower_expanded.diameter"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
|
|
||||||
<el-form-item label="下扩大段高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.lower_expanded.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div v-if="deviceTypetype == 'FluidizedBed'">
|
|
||||||
<div class="flex">
|
|
||||||
<el-form-item label="扩大段直径" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入直径"
|
|
||||||
v-model="josnInfo.expanded_section.diameter"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="扩大段高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.expanded_section.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<el-form-item label="过渡段高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.transition_section.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<div class="flex">
|
|
||||||
<el-form-item label="反应段直径" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入直径"
|
|
||||||
v-model="josnInfo.reaction_section.diameter"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="反应段高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.reaction_section.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
<el-form-item :label="item.label" style="width: 100%;" v-for="item in sourceTempData">
|
||||||
</div>
|
<el-input-number
|
||||||
|
placeholder="请输入长度"
|
||||||
<div v-if="deviceTypetype == 'ACFTank'">
|
v-model="info.size[item.key]"
|
||||||
<div class="flex">
|
:min="0"
|
||||||
<el-form-item label="环形圆柱外径" style="width: 100%;">
|
align="left"
|
||||||
<el-input-number
|
:controls="false"
|
||||||
placeholder="请输入外径"
|
style="width: 100%"
|
||||||
v-model="josnInfo.annular_cylinder.outer_diameter"
|
>
|
||||||
:min="0"
|
<template #suffix>{{item.unit}}</template>
|
||||||
align="left"
|
</el-input-number>
|
||||||
:controls="false"
|
</el-form-item>
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="环形圆柱高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.annular_cylinder.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
<div class="flex">
|
|
||||||
<el-form-item label="圆锥台底部直径" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入直径"
|
|
||||||
v-model="josnInfo.frustum_bottom.bottom_diameter"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="圆锥台底部高度" style="width: 100%;">
|
|
||||||
<el-input-number
|
|
||||||
placeholder="请输入高度"
|
|
||||||
v-model="josnInfo.frustum_bottom.height"
|
|
||||||
:min="0"
|
|
||||||
align="left"
|
|
||||||
:controls="false"
|
|
||||||
style="width: 100%"
|
|
||||||
>
|
|
||||||
<template #suffix>cm</template>
|
|
||||||
</el-input-number>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<el-form-item label="容量" style="width: 100%;">
|
<el-form-item label="容量" style="width: 100%;">
|
||||||
<el-input-number
|
<el-input-number
|
||||||
placeholder="请输入容量"
|
placeholder="请输入容量"
|
||||||
v-model="info.volume"
|
v-model="info.volume"
|
||||||
:min="0"
|
:min="0"
|
||||||
align="left"
|
align="left"
|
||||||
:controls="false"
|
:controls="false"
|
||||||
style="width: 100%"
|
style="width: 100%"
|
||||||
>
|
>
|
||||||
<template #suffix>L</template>
|
<template #suffix>L</template>
|
||||||
</el-input-number>
|
</el-input-number>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="流量" style="width: 100%;">
|
<el-form-item label="流量" style="width: 100%;">
|
||||||
<el-input-number
|
<el-input-number
|
||||||
|
|||||||
@ -19,9 +19,8 @@ import insertCss from 'insert-css'
|
|||||||
import { updateProjects} from "@/api/business/project";
|
import { updateProjects} from "@/api/business/project";
|
||||||
import Createscenario from '@/views/component/scenario/createscenario.vue'
|
import Createscenario from '@/views/component/scenario/createscenario.vue'
|
||||||
import ScenarioModel from '@/views/component/scenario/index.vue'
|
import ScenarioModel from '@/views/component/scenario/index.vue'
|
||||||
import { addDevices } from "@/api/business/database/device";
|
import { addDevices,sizeSchemaAll } from "@/api/business/database/device";
|
||||||
import { saveOrUpdate} from "@/api/business/database/material";
|
import { saveOrUpdate} from "@/api/business/database/material";
|
||||||
|
|
||||||
import { projectsById} from "@/api/business/project";
|
import { projectsById} from "@/api/business/project";
|
||||||
import line1 from '@/assets/x6/line1.png'
|
import line1 from '@/assets/x6/line1.png'
|
||||||
import line2 from '@/assets/x6/line2.png'
|
import line2 from '@/assets/x6/line2.png'
|
||||||
@ -44,6 +43,16 @@ const props = defineProps({
|
|||||||
default: {}
|
default: {}
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
//获取所有项目列表
|
||||||
|
const sizeSchemaInfo:any = ref({});
|
||||||
|
|
||||||
|
async function getSizeSchemaList(){
|
||||||
|
let result = await sizeSchemaAll({})
|
||||||
|
sizeSchemaInfo.value = result
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
const isLock = ref(false) // 是否锁定
|
const isLock = ref(false) // 是否锁定
|
||||||
const deviceTypetype:any = ref('') // 设备类型
|
const deviceTypetype:any = ref('') // 设备类型
|
||||||
const isAdddevice = ref(false) // 是否添加设备
|
const isAdddevice = ref(false) // 是否添加设备
|
||||||
@ -376,20 +385,22 @@ onMounted(() => {
|
|||||||
node.attr('label/refY', 140)
|
node.attr('label/refY', 140)
|
||||||
node.attr('label/refX', width/2)
|
node.attr('label/refX', width/2)
|
||||||
node.attr('label/textAnchor', 'middle')
|
node.attr('label/textAnchor', 'middle')
|
||||||
}else if(node.store.data.attrs.text.text == '萃取柱'){
|
}
|
||||||
deviceTypetype.value = 'ExtractionColumn'
|
// else if(node.store.data.attrs.text.text == '萃取柱'){
|
||||||
|
// deviceTypetype.value = 'ExtractionColumn'
|
||||||
|
|
||||||
node.size(30, 140)
|
// node.size(30, 140)
|
||||||
const width = node.size().width
|
// const width = node.size().width
|
||||||
node.attr('image/xlink:href', '/assets/55.png')
|
// node.attr('image/xlink:href', '/assets/55.png')
|
||||||
node.attr('image/width', 30)
|
// node.attr('image/width', 30)
|
||||||
node.attr('image/height', 135)
|
// node.attr('image/height', 135)
|
||||||
node.attr('label/refY', 140)
|
// node.attr('label/refY', 140)
|
||||||
node.attr('label/refX', width/2)
|
// node.attr('label/refX', width/2)
|
||||||
node.attr('label/textAnchor', 'middle')
|
// node.attr('label/textAnchor', 'middle')
|
||||||
|
|
||||||
|
|
||||||
}else if(node.store.data.attrs.text.text == '流化床'){
|
// }
|
||||||
|
else if(node.store.data.attrs.text.text == '流化床'){
|
||||||
deviceTypetype.value = 'FluidizedBed'
|
deviceTypetype.value = 'FluidizedBed'
|
||||||
node.size(60, 140)
|
node.size(60, 140)
|
||||||
const width = node.size().width
|
const width = node.size().width
|
||||||
@ -409,6 +420,26 @@ onMounted(() => {
|
|||||||
node.attr('label/refY', 140)
|
node.attr('label/refY', 140)
|
||||||
node.attr('label/refX', width/2)
|
node.attr('label/refX', width/2)
|
||||||
node.attr('label/textAnchor', 'middle')
|
node.attr('label/textAnchor', 'middle')
|
||||||
|
}else if(node.store.data.attrs.text.text == '圆柱脉冲柱'){
|
||||||
|
deviceTypetype.value = 'PulsedCylindricalColumn'
|
||||||
|
node.size(30, 140)
|
||||||
|
const width = node.size().width
|
||||||
|
node.attr('image/xlink:href', '/assets/88.png')
|
||||||
|
node.attr('image/width', 30)
|
||||||
|
node.attr('image/height', 135)
|
||||||
|
node.attr('label/refY', 140)
|
||||||
|
node.attr('label/refX', width/2)
|
||||||
|
node.attr('label/textAnchor', 'middle')
|
||||||
|
}else if(node.store.data.attrs.text.text == '环形脉冲柱'){
|
||||||
|
deviceTypetype.value = 'PulsedAnnularColumn'
|
||||||
|
node.size(40, 140)
|
||||||
|
const width = node.size().width
|
||||||
|
node.attr('image/xlink:href', '/assets/99.png')
|
||||||
|
node.attr('image/width', 40)
|
||||||
|
node.attr('image/height', 135)
|
||||||
|
node.attr('label/refY', 140)
|
||||||
|
node.attr('label/refX', width/2)
|
||||||
|
node.attr('label/textAnchor', 'middle')
|
||||||
}
|
}
|
||||||
// 设置固定大小
|
// 设置固定大小
|
||||||
|
|
||||||
@ -794,16 +825,22 @@ graph.on('blank:mouseup', (e) => {
|
|||||||
label: '管束槽',
|
label: '管束槽',
|
||||||
image: '/assets/4.png',
|
image: '/assets/4.png',
|
||||||
},
|
},
|
||||||
{
|
// {
|
||||||
label: '萃取柱',
|
// label: '萃取柱',
|
||||||
image: '/assets/5.png',
|
// image: '/assets/5.png',
|
||||||
},
|
// },
|
||||||
{
|
{
|
||||||
label: '流化床',
|
label: '流化床',
|
||||||
image: '/assets/6.png',
|
image: '/assets/6.png',
|
||||||
},{
|
},{
|
||||||
label: '锥底环形槽',
|
label: '锥底环形槽',
|
||||||
image: '/assets/7.png',
|
image: '/assets/7.png',
|
||||||
|
},{
|
||||||
|
label: '圆柱脉冲柱',
|
||||||
|
image: '/assets/8.png',
|
||||||
|
},{
|
||||||
|
label: '环形脉冲柱',
|
||||||
|
image: '/assets/9.png',
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
const imageNodes = imageShapes.map((item) =>
|
const imageNodes = imageShapes.map((item) =>
|
||||||
@ -940,12 +977,21 @@ graph.on('blank:mouseup', (e) => {
|
|||||||
const topology:any = JSON.parse(projectInfo.value.topology)
|
const topology:any = JSON.parse(projectInfo.value.topology)
|
||||||
if(!topology.designData)return
|
if(!topology.designData)return
|
||||||
graph.fromJSON(topology.designData);
|
graph.fromJSON(topology.designData);
|
||||||
|
let json = graph.toJSON()
|
||||||
|
tabDeviceNum.value = 0
|
||||||
|
for(let i = 0; i < json.cells.length; i++){
|
||||||
|
if(json.cells[i].shape == 'custom-image'){
|
||||||
|
tabDeviceNum.value++
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
})
|
})
|
||||||
|
getSizeSchemaList()
|
||||||
// #endregion
|
// #endregion
|
||||||
})
|
})
|
||||||
|
const tabDeviceNum = ref(0)
|
||||||
|
const antvStatus = ref('初始化')
|
||||||
function preWork() {
|
function preWork() {
|
||||||
// 这里协助演示的代码,在实际项目中根据实际情况进行调整
|
// 这里协助演示的代码,在实际项目中根据实际情况进行调整
|
||||||
const container = document.getElementById('container') as HTMLElement
|
const container = document.getElementById('container') as HTMLElement
|
||||||
@ -1020,7 +1066,15 @@ const isMenuShow = ref(false) // 是否显示右键菜单
|
|||||||
const selectedNode:any = ref(null)
|
const selectedNode:any = ref(null)
|
||||||
function deleteNode() { // 删除节点
|
function deleteNode() { // 删除节点
|
||||||
graph.removeNode(selectedNode.value)
|
graph.removeNode(selectedNode.value)
|
||||||
isMenuShow.value = false
|
let json = graph.toJSON()
|
||||||
|
tabDeviceNum.value = 0
|
||||||
|
for(let i = 0; i < json.cells.length; i++){
|
||||||
|
if(json.cells[i].shape == 'custom-image'){
|
||||||
|
tabDeviceNum.value++
|
||||||
|
}
|
||||||
|
}
|
||||||
|
antvStatus.value = '删除设备'
|
||||||
|
isMenuShow.value = false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -1161,6 +1215,7 @@ function closeConnectingwireModel(e:any){ // 关闭连接线弹窗
|
|||||||
zIndex: 0
|
zIndex: 0
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
antvStatus.value = '编辑连接线'
|
||||||
}
|
}
|
||||||
isConnectingwire.value = false;
|
isConnectingwire.value = false;
|
||||||
}
|
}
|
||||||
@ -1194,7 +1249,15 @@ function closeAdddevice(e:any){ // 关闭新增设备弹窗
|
|||||||
retrievedNode.attr('text/text', e.name)
|
retrievedNode.attr('text/text', e.name)
|
||||||
retrievedNode.attr('label/text', e.name)
|
retrievedNode.attr('label/text', e.name)
|
||||||
retrievedNode.store.data.deviceInfo = e
|
retrievedNode.store.data.deviceInfo = e
|
||||||
saveDesign(false)
|
saveDesign(false)
|
||||||
|
let json = graph.toJSON()
|
||||||
|
tabDeviceNum.value = 0
|
||||||
|
for(let i = 0; i < json.cells.length; i++){
|
||||||
|
if(json.cells[i].shape == 'custom-image'){
|
||||||
|
tabDeviceNum.value++
|
||||||
|
}
|
||||||
|
}
|
||||||
|
antvStatus.value = '新增设备'
|
||||||
isAdddevice.value = false;
|
isAdddevice.value = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1215,6 +1278,14 @@ function closeEditdevice(e:any){ // 关闭编辑设备弹窗
|
|||||||
retrievedNode.attr('text/text', e.name)
|
retrievedNode.attr('text/text', e.name)
|
||||||
retrievedNode.attr('label/text', e.name)
|
retrievedNode.attr('label/text', e.name)
|
||||||
isEditdevice.value = false;
|
isEditdevice.value = false;
|
||||||
|
let json = graph.toJSON()
|
||||||
|
tabDeviceNum.value = 0
|
||||||
|
for(let i = 0; i < json.cells.length; i++){
|
||||||
|
if(json.cells[i].shape == 'custom-image'){
|
||||||
|
tabDeviceNum.value++
|
||||||
|
}
|
||||||
|
}
|
||||||
|
antvStatus.value = '编辑设备'
|
||||||
saveDesign(false)
|
saveDesign(false)
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1251,6 +1322,14 @@ function closeMaterialModel(e:any){ // 关闭物料信息弹窗
|
|||||||
let retrievedNode:any = graph.getCellById(nodeId.value)
|
let retrievedNode:any = graph.getCellById(nodeId.value)
|
||||||
retrievedNode.store.data.materialInfo = e
|
retrievedNode.store.data.materialInfo = e
|
||||||
saveDesign(false)
|
saveDesign(false)
|
||||||
|
let json = graph.toJSON()
|
||||||
|
tabDeviceNum.value = 0
|
||||||
|
for(let i = 0; i < json.cells.length; i++){
|
||||||
|
if(json.cells[i].shape == 'custom-image'){
|
||||||
|
tabDeviceNum.value++
|
||||||
|
}
|
||||||
|
}
|
||||||
|
antvStatus.value = '编辑物料信息'
|
||||||
isMaterialModel.value = false;
|
isMaterialModel.value = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1300,6 +1379,15 @@ function closeChangesettingsModel(e:any){ // 关闭变动设置弹窗
|
|||||||
selectedMaterial.value = e
|
selectedMaterial.value = e
|
||||||
let retrievedNode:any = graph.getCellById(nodeId.value)
|
let retrievedNode:any = graph.getCellById(nodeId.value)
|
||||||
retrievedNode.store.data.changesettings = e
|
retrievedNode.store.data.changesettings = e
|
||||||
|
saveDesign(false)
|
||||||
|
let json = graph.toJSON()
|
||||||
|
tabDeviceNum.value = 0
|
||||||
|
for(let i = 0; i < json.cells.length; i++){
|
||||||
|
if(json.cells[i].shape == 'custom-image'){
|
||||||
|
tabDeviceNum.value++
|
||||||
|
}
|
||||||
|
}
|
||||||
|
antvStatus.value = '编辑变动设置'
|
||||||
isChangesettings.value = false;
|
isChangesettings.value = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1491,6 +1579,9 @@ function saveDesign(is:any) { // 保存设计
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
if(is == true){
|
||||||
|
antvStatus.value = '完成保存'
|
||||||
|
}
|
||||||
// 返回保存的数据
|
// 返回保存的数据
|
||||||
return saveData
|
return saveData
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
@ -1519,7 +1610,7 @@ const confirmCopyClick = async ()=>{
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
loading.value = true
|
loading.value = true
|
||||||
copyNodeInfo.value.store.data.attrs.label.text = copyDeviceInfo.value.name
|
copyNodeInfo.value.store.data.attrs.label.text = copyDeviceInfo.value.name
|
||||||
copyNodeInfo.value.store.data.deviceInfo.name = copyDeviceInfo.value.name
|
copyNodeInfo.value.store.data.deviceInfo.name = copyDeviceInfo.value.name
|
||||||
copyNodeInfo.value.store.data.deviceInfo.code = copyDeviceInfo.value.code + '-copy'
|
copyNodeInfo.value.store.data.deviceInfo.code = copyDeviceInfo.value.code + '-copy'
|
||||||
copyNodeInfo.value.store.data.deviceInfo.deviceId = copyNodeInfo.value.id
|
copyNodeInfo.value.store.data.deviceInfo.deviceId = copyNodeInfo.value.id
|
||||||
@ -1724,10 +1815,10 @@ function getName(code:any) {
|
|||||||
return name = "氧化铀密度(g/cm3)";
|
return name = "氧化铀密度(g/cm3)";
|
||||||
break;
|
break;
|
||||||
case 'u_enrichment':
|
case 'u_enrichment':
|
||||||
return name = "铀富集度(%)";
|
return name = "铀富集度";
|
||||||
break;
|
break;
|
||||||
case 'uEnrichment':
|
case 'uEnrichment':
|
||||||
return name = "铀富集度(%)";
|
return name = "铀富集度";
|
||||||
break;
|
break;
|
||||||
case 'pu_concentration':
|
case 'pu_concentration':
|
||||||
return name = "钚浓度(g/L)";
|
return name = "钚浓度(g/L)";
|
||||||
@ -1742,10 +1833,10 @@ function getName(code:any) {
|
|||||||
return name = "氧化钚密度(g/cm3)";
|
return name = "氧化钚密度(g/cm3)";
|
||||||
break;
|
break;
|
||||||
case 'pu_isotope':
|
case 'pu_isotope':
|
||||||
return name = "钚同位素比例(PU-240占比)%";
|
return name = "钚同位素比例(PU-240占比)";
|
||||||
break;
|
break;
|
||||||
case 'puIsotope':
|
case 'puIsotope':
|
||||||
return name = "钚同位素比例(PU-240占比)%";
|
return name = "钚同位素比例(PU-240占比)";
|
||||||
break;
|
break;
|
||||||
case 'hno3_acidity':
|
case 'hno3_acidity':
|
||||||
return name = "硝酸酸度(mol/L)";
|
return name = "硝酸酸度(mol/L)";
|
||||||
@ -1760,16 +1851,16 @@ function getName(code:any) {
|
|||||||
return name = "草酸浓度(mol/L)";
|
return name = "草酸浓度(mol/L)";
|
||||||
break;
|
break;
|
||||||
case 'organic_ratio':
|
case 'organic_ratio':
|
||||||
return name = "有机相比例%";
|
return name = "有机相比例";
|
||||||
break;
|
break;
|
||||||
case 'organicRatio':
|
case 'organicRatio':
|
||||||
return name = "有机相比例%";
|
return name = "有机相比例";
|
||||||
break;
|
break;
|
||||||
case 'moisture_content':
|
case 'moisture_content':
|
||||||
return name = "含水率%";
|
return name = "含水率";
|
||||||
break;
|
break;
|
||||||
case 'moistureContent':
|
case 'moistureContent':
|
||||||
return name = "含水率%";
|
return name = "含水率";
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
return name = "";
|
return name = "";
|
||||||
@ -1902,6 +1993,13 @@ function getName(code:any) {
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
<div class="tab-device-num">
|
||||||
|
<div style="margin-left: 10px; margin-right: 10px;"> 设备数量:<span style="color: #0089ff;">{{ tabDeviceNum }}个</span></div>
|
||||||
|
<div> 完成操作:
|
||||||
|
<span style="color: #0089ff;" v-if="antvStatus=='初始化'">{{ antvStatus }}</span>
|
||||||
|
<span style="color: red;" v-else>{{ antvStatus }}</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<Createscenario v-if="dialogVisible" :projectInfo="projectInfo" @closeCreatescenario ="closeCreatescenario"/>
|
<Createscenario v-if="dialogVisible" :projectInfo="projectInfo" @closeCreatescenario ="closeCreatescenario"/>
|
||||||
<el-dialog v-model="isScenario" :close-on-click-modal="false"
|
<el-dialog v-model="isScenario" :close-on-click-modal="false"
|
||||||
@ -1912,12 +2010,12 @@ function getName(code:any) {
|
|||||||
<el-dialog v-model="isAdddevice" :close-on-click-modal="false"
|
<el-dialog v-model="isAdddevice" :close-on-click-modal="false"
|
||||||
:modal="false" draggable :before-close="dialogAdddevice" title="添加设备"
|
:modal="false" draggable :before-close="dialogAdddevice" title="添加设备"
|
||||||
append-to-body width="1050px">
|
append-to-body width="1050px">
|
||||||
<AdddeviceModel v-if="isAdddevice == true" :deviceId="nodeId" :projectInfo="projectInfo"
|
<AdddeviceModel v-if="isAdddevice == true" :deviceId="nodeId" :projectInfo="projectInfo" :sizeSchemaInfo="sizeSchemaInfo"
|
||||||
:deviceTypetype="deviceTypetype" ref="Adddevice" @closeAdddevice="closeAdddevice"/>
|
:deviceTypetype="deviceTypetype" ref="Adddevice" @closeAdddevice="closeAdddevice"/>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
|
|
||||||
<el-dialog v-model="isEditdevice" :close-on-click-modal="false" :modal="false" draggable :before-close="dialogEditdevice" title="设备信息" append-to-body width="1050px">
|
<el-dialog v-model="isEditdevice" :close-on-click-modal="false" :modal="false" draggable :before-close="dialogEditdevice" title="设备信息" append-to-body width="1050px">
|
||||||
<EditdeviceModel v-if="isEditdevice == true" :deviceId="nodeId" :deviceInfo="deviceInfo"
|
<EditdeviceModel v-if="isEditdevice == true" :deviceId="nodeId" :deviceInfo="deviceInfo" :sizeSchemaInfo="sizeSchemaInfo"
|
||||||
:deviceTypetype="deviceTypetype" ref="Editdevice" @closeEditdevice="closeEditdevice"/>
|
:deviceTypetype="deviceTypetype" ref="Editdevice" @closeEditdevice="closeEditdevice"/>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
|
|
||||||
@ -1928,7 +2026,8 @@ function getName(code:any) {
|
|||||||
|
|
||||||
|
|
||||||
<el-dialog v-model="isChangesettings" :close-on-click-modal="false" :modal="false" draggable :before-close="dialogChangesettings" title="变动设置" append-to-body width="1014px">
|
<el-dialog v-model="isChangesettings" :close-on-click-modal="false" :modal="false" draggable :before-close="dialogChangesettings" title="变动设置" append-to-body width="1014px">
|
||||||
<ChangesettingsModels v-if="isChangesettings == true" :materialId="nodeId" :projectInfo="projectInfo" :changesettingsData="changesettingsData"
|
<ChangesettingsModels v-if="isChangesettings == true" :materialId="nodeId" :projectInfo="projectInfo"
|
||||||
|
:changesettingsData="changesettingsData" :sizeSchemaInfo="sizeSchemaInfo"
|
||||||
:materialInfo="materialInfo" :deviceInfo="deviceInfo" ref="ChangesettingsModel" @closeChangesettingsModel="closeChangesettingsModel"/>
|
:materialInfo="materialInfo" :deviceInfo="deviceInfo" ref="ChangesettingsModel" @closeChangesettingsModel="closeChangesettingsModel"/>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
|
|
||||||
@ -2295,4 +2394,18 @@ function getName(code:any) {
|
|||||||
.x6-widget-stencil .x6-node.x6-node-immovable{
|
.x6-widget-stencil .x6-node.x6-node-immovable{
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
.tab-device-num{
|
||||||
|
position: absolute;
|
||||||
|
left: 300px;
|
||||||
|
bottom: 0px;
|
||||||
|
font-size: 14px;
|
||||||
|
color: #808080;
|
||||||
|
width: calc(100% - 300px);
|
||||||
|
height: 60px;
|
||||||
|
border-top: 1px solid #cfcfcf;
|
||||||
|
z-index: 1;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
/* justify-content: center; */
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
@ -7,7 +7,7 @@ export default {
|
|||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { onMounted, ref, nextTick } from "vue";
|
import { onMounted, ref, nextTick } from "vue";
|
||||||
import { ElForm, ElMessage, ElMessageBox } from "element-plus";
|
import { ElForm, ElMessage, ElMessageBox } from "element-plus";
|
||||||
import { searchMaterialsPage, saveOrUpdate} from "@/api/business/database/material";
|
import { searchMaterialsPage, saveOrUpdate, materialsById} from "@/api/business/database/material";
|
||||||
|
|
||||||
const emit = defineEmits([ 'closeMaterialModel']);
|
const emit = defineEmits([ 'closeMaterialModel']);
|
||||||
|
|
||||||
@ -56,14 +56,23 @@ function confirmClick(formEl: any) {
|
|||||||
uEnrichment: info.value.uEnrichment,
|
uEnrichment: info.value.uEnrichment,
|
||||||
puConcentration: info.value.puConcentration,
|
puConcentration: info.value.puConcentration,
|
||||||
puo2Density: info.value.puo2Density,
|
puo2Density: info.value.puo2Density,
|
||||||
puIsotope: info.value.puIsotope,
|
ePu238: info.value.ePu238,
|
||||||
|
ePu239: info.value.ePu239,
|
||||||
|
ePu240: info.value.ePu240,
|
||||||
|
ePu241: info.value.ePu241,
|
||||||
|
ePu242: info.value.ePu242,
|
||||||
hno3Acidity: info.value.hno3Acidity,
|
hno3Acidity: info.value.hno3Acidity,
|
||||||
h2c2o4Concentration: info.value.h2c2o4Concentration,
|
h2c2o4Concentration: info.value.h2c2o4Concentration,
|
||||||
organicRatio: info.value.organicRatio,
|
organicRatio: info.value.organicRatio,
|
||||||
moistureContent: info.value.moistureContent,
|
moistureContent: info.value.moistureContent,
|
||||||
customAttrs: JSON.stringify(customAttrsData.value)
|
customAttrs: JSON.stringify(customAttrsData.value),
|
||||||
|
|
||||||
}
|
}
|
||||||
saveOrUpdate(params).then((res:any) => {
|
let data = {
|
||||||
|
...params,
|
||||||
|
iconBase64: iconBase64.value,
|
||||||
|
}
|
||||||
|
saveOrUpdate(data).then((res:any) => {
|
||||||
if(res == true){
|
if(res == true){
|
||||||
emit('closeMaterialModel', params)
|
emit('closeMaterialModel', params)
|
||||||
}
|
}
|
||||||
@ -73,7 +82,16 @@ function confirmClick(formEl: any) {
|
|||||||
}
|
}
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
deviceName.value = props.deviceInfo.name
|
deviceName.value = props.deviceInfo.name
|
||||||
editClick(props.materialInfo)
|
if(props.materialId != null){
|
||||||
|
materialsById(props.materialId).then((res:any) => {
|
||||||
|
editClick(res)
|
||||||
|
info.value.iconBase64 = res.iconBase64;
|
||||||
|
});
|
||||||
|
}else{
|
||||||
|
editClick(props.materialInfo)
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
});
|
});
|
||||||
const infoForm = ref();
|
const infoForm = ref();
|
||||||
@ -163,10 +181,10 @@ function gettableData() { // 获取物料列表
|
|||||||
}).catch((err) => {
|
}).catch((err) => {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
const iconBase64:any = ref("") // 物料图片
|
||||||
function handleClick(item:any, index:any){
|
function handleClick(item:any, index:any){
|
||||||
|
iconBase64.value = item.iconBase64
|
||||||
ingredientData.value = []
|
ingredientData.value = []
|
||||||
|
|
||||||
ingredientData.value.push({
|
ingredientData.value.push({
|
||||||
key: "铀浓度(g/L)",
|
key: "铀浓度(g/L)",
|
||||||
value: item.uConcentration,
|
value: item.uConcentration,
|
||||||
@ -176,7 +194,7 @@ function handleClick(item:any, index:any){
|
|||||||
value: item.uo2Density,
|
value: item.uo2Density,
|
||||||
unit: "",
|
unit: "",
|
||||||
},{
|
},{
|
||||||
key: "铀富集度(%)",
|
key: "铀富集度",
|
||||||
value: item.uEnrichment,
|
value: item.uEnrichment,
|
||||||
unit: "",
|
unit: "",
|
||||||
},{
|
},{
|
||||||
@ -188,8 +206,24 @@ function handleClick(item:any, index:any){
|
|||||||
value: item.puo2Density,
|
value: item.puo2Density,
|
||||||
unit: "",
|
unit: "",
|
||||||
},{
|
},{
|
||||||
key: "钚同位素比例(PU-240占比)%",
|
key: "PU-238占比",
|
||||||
value: item.puIsotope,
|
value: item.ePu238,
|
||||||
|
unit: "",
|
||||||
|
},{
|
||||||
|
key: "PU-239占比",
|
||||||
|
value: item.ePu239,
|
||||||
|
unit: "",
|
||||||
|
},{
|
||||||
|
key: "PU-240占比",
|
||||||
|
value: item.ePu240,
|
||||||
|
unit: "",
|
||||||
|
},{
|
||||||
|
key: "PU-241占比",
|
||||||
|
value: item.ePu241,
|
||||||
|
unit: "",
|
||||||
|
},{
|
||||||
|
key: "PU-242占比",
|
||||||
|
value: item.ePu242,
|
||||||
unit: "",
|
unit: "",
|
||||||
},{
|
},{
|
||||||
key: "硝酸酸度(mol/L)",
|
key: "硝酸酸度(mol/L)",
|
||||||
@ -200,11 +234,11 @@ function handleClick(item:any, index:any){
|
|||||||
value: item.h2c2o4Concentration,
|
value: item.h2c2o4Concentration,
|
||||||
unit: "",
|
unit: "",
|
||||||
},{
|
},{
|
||||||
key: "有机相比例%",
|
key: "有机相比例",
|
||||||
value: item.organicRatio,
|
value: item.organicRatio,
|
||||||
unit: "",
|
unit: "",
|
||||||
},{
|
},{
|
||||||
key: "含水率%",
|
key: "含水率",
|
||||||
value: item.moistureContent,
|
value: item.moistureContent,
|
||||||
unit: "",
|
unit: "",
|
||||||
})
|
})
|
||||||
@ -234,12 +268,17 @@ function confirmMaterial(){
|
|||||||
uEnrichment: selectedMaterial.value.uEnrichment,
|
uEnrichment: selectedMaterial.value.uEnrichment,
|
||||||
puConcentration: selectedMaterial.value.puConcentration,
|
puConcentration: selectedMaterial.value.puConcentration,
|
||||||
puo2Density: selectedMaterial.value.puo2Density,
|
puo2Density: selectedMaterial.value.puo2Density,
|
||||||
puIsotope: selectedMaterial.value.puIsotope,
|
ePu238: selectedMaterial.value.ePu238,
|
||||||
|
ePu239: selectedMaterial.value.ePu239,
|
||||||
|
ePu240: selectedMaterial.value.ePu240,
|
||||||
|
ePu241: selectedMaterial.value.ePu241,
|
||||||
|
ePu242: selectedMaterial.value.ePu242,
|
||||||
hno3Acidity: selectedMaterial.value.hno3Acidity,
|
hno3Acidity: selectedMaterial.value.hno3Acidity,
|
||||||
h2c2o4Concentration: selectedMaterial.value.h2c2o4Concentration,
|
h2c2o4Concentration: selectedMaterial.value.h2c2o4Concentration,
|
||||||
organicRatio: selectedMaterial.value.organicRatio,
|
organicRatio: selectedMaterial.value.organicRatio,
|
||||||
moistureContent: selectedMaterial.value.moistureContent,
|
moistureContent: selectedMaterial.value.moistureContent,
|
||||||
customAttrs: selectedMaterial.value.customAttrs,
|
customAttrs: selectedMaterial.value.customAttrs,
|
||||||
|
iconBase64: iconBase64.value,
|
||||||
}
|
}
|
||||||
customAttrsData.value = []
|
customAttrsData.value = []
|
||||||
if(selectedMaterial.value.customAttrs !=null && selectedMaterial.value.customAttrs != ""){
|
if(selectedMaterial.value.customAttrs !=null && selectedMaterial.value.customAttrs != ""){
|
||||||
@ -247,6 +286,21 @@ function confirmMaterial(){
|
|||||||
}
|
}
|
||||||
isDialogMaterial.value = false
|
isDialogMaterial.value = false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function uploadIconBaseChange(file:any){
|
||||||
|
var reader = new FileReader();
|
||||||
|
reader.readAsDataURL(file.raw);
|
||||||
|
reader.onload = () => {
|
||||||
|
info.value.iconBase64 =reader.result
|
||||||
|
};
|
||||||
|
reader.onerror = function(error) {
|
||||||
|
console.log("Error: ", error);
|
||||||
|
};
|
||||||
|
}
|
||||||
|
function delIconBase(){
|
||||||
|
info.value.iconBase64 = " "
|
||||||
|
}
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
@ -258,7 +312,7 @@ function confirmMaterial(){
|
|||||||
<el-input v-model="deviceName" style="width: 300px" placeholder="" :disabled="true"></el-input>
|
<el-input v-model="deviceName" style="width: 300px" placeholder="" :disabled="true"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="所属物料" prop="name" label-width="80px">
|
<el-form-item label="所属物料" prop="name" label-width="80px">
|
||||||
<el-input v-model="info.name" style="width: 300px" placeholder=""></el-input>
|
<el-input v-model="info.name" style="width: 280px" placeholder=""></el-input>
|
||||||
<el-button type="primary" style="margin-left: 10px" @click="dialogMaterialOpen">选择物料</el-button>
|
<el-button type="primary" style="margin-left: 10px" @click="dialogMaterialOpen">选择物料</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
@ -275,21 +329,39 @@ function confirmMaterial(){
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
<div class="materialmodel_dialog_display">
|
<div class="materialmodel_dialog_display">
|
||||||
<el-form-item label="铀富集度(%)" prop="uEnrichment">
|
<el-form-item label="铀富集度" prop="uEnrichment">
|
||||||
<el-input v-model="info.uEnrichment" style="width: 100%" placeholder="" @input="handleNumberInput('uEnrichment')"></el-input>
|
<el-input v-model="info.uEnrichment" style="width: 100%" placeholder="" @input="handleNumberInput('uEnrichment')"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="钚浓度(g/L)" prop="puConcentration">
|
<el-form-item label="钚浓度(g/L)" prop="puConcentration">
|
||||||
<el-input v-model="info.puConcentration" style="width: 100%" placeholder="" @input="handleNumberInput('puConcentration')"></el-input>
|
<el-input v-model="info.puConcentration" style="width: 100%" placeholder="" @input="handleNumberInput('puConcentration')"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
<div class="materialmodel_dialog_display">
|
<div class="materialmodel_dialog_display">
|
||||||
<el-form-item label="氧化钚密度(g/cm3)" prop="puo2Density">
|
<el-form-item label="氧化钚密度(g/cm3)" prop="puo2Density">
|
||||||
<el-input v-model="info.puo2Density" style="width: 100%" placeholder="" @input="handleNumberInput('puo2Density')"></el-input>
|
<el-input v-model="info.puo2Density" style="width: 100%" placeholder="" @input="handleNumberInput('puo2Density')"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="钚同位素比例(PU-240占比)%" prop="puIsotope">
|
<el-form-item label="PU-238占比" prop="ePu238">
|
||||||
<el-input v-model="info.puIsotope" style="width: 100%" placeholder="" @input="handleNumberInput('puIsotope')"></el-input>
|
<el-input v-model="info.ePu238" style="width: 100%" placeholder="" @input="handleNumberInput('ePu238')"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="materialmodel_dialog_display">
|
||||||
|
<el-form-item label="PU-239占比" prop="ePu239">
|
||||||
|
<el-input v-model="info.ePu239" style="width: 100%" placeholder="" @input="handleNumberInput('ePu239')"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="PU-240占比" prop="ePu240">
|
||||||
|
<el-input v-model="info.ePu240" style="width: 100%" placeholder="" @input="handleNumberInput('ePu240')"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</div>
|
||||||
|
<div class="materialmodel_dialog_display">
|
||||||
|
<el-form-item label="PU-241占比" prop="ePu241">
|
||||||
|
<el-input v-model="info.ePu241" style="width: 100%" placeholder="" @input="handleNumberInput('ePu241')"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="PU-242占比" prop="ePu242">
|
||||||
|
<el-input v-model="info.ePu242" style="width: 100%" placeholder="" @input="handleNumberInput('ePu242')"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="materialmodel_dialog_display">
|
<div class="materialmodel_dialog_display">
|
||||||
<el-form-item label="硝酸酸度(mol/L)" prop="hno3Acidity">
|
<el-form-item label="硝酸酸度(mol/L)" prop="hno3Acidity">
|
||||||
<el-input v-model="info.hno3Acidity" style="width: 100%" placeholder="" @input="handleNumberInput('hno3Acidity')"></el-input>
|
<el-input v-model="info.hno3Acidity" style="width: 100%" placeholder="" @input="handleNumberInput('hno3Acidity')"></el-input>
|
||||||
@ -299,13 +371,38 @@ function confirmMaterial(){
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
<div class="materialmodel_dialog_display">
|
<div class="materialmodel_dialog_display">
|
||||||
<el-form-item label="有机相比例%" prop="organicRatio">
|
<el-form-item label="有机相比例" prop="organicRatio">
|
||||||
<el-input v-model="info.organicRatio" style="width: 100%" placeholder="" @input="handleNumberInput('organicRatio')"></el-input>
|
<el-input v-model="info.organicRatio" style="width: 100%" placeholder="" @input="handleNumberInput('organicRatio')"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="含水率%" prop="moistureContent">
|
<el-form-item label="含水率" prop="moistureContent">
|
||||||
<el-input v-model="info.moistureContent" style="width: 100%" placeholder="" @input="handleNumberInput('moistureContent')"></el-input>
|
<el-input v-model="info.moistureContent" style="width: 100%" placeholder="" @input="handleNumberInput('moistureContent')"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
|
<el-form-item label="物料图片">
|
||||||
|
<el-upload
|
||||||
|
style="margin-left: 10px;"
|
||||||
|
class="avatar-uploader"
|
||||||
|
accept=".png, .jpg, .jpeg"
|
||||||
|
action=""
|
||||||
|
:show-file-list="false"
|
||||||
|
:auto-upload="false"
|
||||||
|
@change="uploadIconBaseChange"
|
||||||
|
>
|
||||||
|
<div style="width: 100px;height: 100px;position: relative;" v-if="info.iconBase64 != ''
|
||||||
|
&& info.iconBase64 != null && info.iconBase64 != ' '">
|
||||||
|
<img :src="info.iconBase64" class="avatar" />
|
||||||
|
<div style="position: absolute;top: 0px;left: 0px;z-index: 1;width: 100px;height: 100px;background: rgba(0,0,0,0.3);color: cornflowerblue;">
|
||||||
|
<el-icon style="position: absolute;top: 40px;left: 40px;z-index: 1;font-size: 20px;"
|
||||||
|
@click.stop="delIconBase"><Delete /></el-icon>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div v-else>
|
||||||
|
<el-icon class="newavatar-uploader-icon"><Plus /></el-icon>
|
||||||
|
<div class="newavatar-uploader-text">物料图片</div>
|
||||||
|
</div>
|
||||||
|
</el-upload>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
<div class="custom_attrs_box">
|
<div class="custom_attrs_box">
|
||||||
<div class="custom_attrs_header">
|
<div class="custom_attrs_header">
|
||||||
<div class="custom_attrs_header1">成分名称</div>
|
<div class="custom_attrs_header1">成分名称</div>
|
||||||
@ -355,11 +452,11 @@ function confirmMaterial(){
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div style="width: 100%;">
|
<div style="width: 100%; height: calc(100vh - 100px); overflow: auto;">
|
||||||
<div style="display: flex;justify-content: flex-end;padding-top: 20px;padding-right: 40px;padding-bottom: 20px;">
|
<div style="display: flex;justify-content: flex-end;padding-top: 20px;padding-right: 40px;padding-bottom: 20px;">
|
||||||
<el-button type="primary" @click="confirmMaterial">确 定</el-button>
|
<el-button type="primary" @click="confirmMaterial">确 定</el-button>
|
||||||
</div>
|
</div>
|
||||||
<div class="custom_attrs_box" style="width: 650px;margin-left: 20px;">
|
<div class="custom_attrs_box" style="width: 650px;margin-left: 20px;margin-bottom: 10px;">
|
||||||
<div class="custom_attrs_header">
|
<div class="custom_attrs_header">
|
||||||
<div class="custom_attrs_header1" style="width: 60%;">成分名称</div>
|
<div class="custom_attrs_header1" style="width: 60%;">成分名称</div>
|
||||||
<div class="custom_attrs_header2" style="width: 40%;" >成分参数</div>
|
<div class="custom_attrs_header2" style="width: 40%;" >成分参数</div>
|
||||||
@ -374,8 +471,30 @@ function confirmMaterial(){
|
|||||||
{{ item.value }}
|
{{ item.value }}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="custom_attrs_header" style="height: 90px;" v-if="ingredientData.length>0">
|
||||||
|
<div class="custom_attrs_content1" style="width: 60%;height: 90px;display: flex;align-items: center;justify-content: center;">图片</div>
|
||||||
|
<div class="custom_attrs_content2" style="width: 40%;height: 90px;display: flex;align-items: center;justify-content: center;" >
|
||||||
|
<el-image
|
||||||
|
v-if="iconBase64 != '' && iconBase64 != null && iconBase64 != ' '"
|
||||||
|
style="
|
||||||
|
max-width: 200px;
|
||||||
|
max-height: 80px;"
|
||||||
|
class="materialmodel-iconBase64"
|
||||||
|
:src="iconBase64"
|
||||||
|
:zoom-rate="1.2"
|
||||||
|
:max-scale="7"
|
||||||
|
:min-scale="0.2"
|
||||||
|
:preview-src-list="[iconBase64]"
|
||||||
|
show-progress
|
||||||
|
:initial-index="4"
|
||||||
|
fit="contain"
|
||||||
|
/>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
@ -593,7 +712,37 @@ function confirmMaterial(){
|
|||||||
.materialmodel-dialog-box.el-dialog .el-dialog__body{
|
.materialmodel-dialog-box.el-dialog .el-dialog__body{
|
||||||
padding: 0 !important;
|
padding: 0 !important;
|
||||||
}
|
}
|
||||||
|
.materialmodel-iconBase64 img{
|
||||||
|
max-width: 200px;
|
||||||
|
max-height: 80px;
|
||||||
|
}
|
||||||
|
|
||||||
|
</style>
|
||||||
|
<style>
|
||||||
|
.avatar-uploader .el-upload {
|
||||||
|
border: 1px dashed var(--el-border-color);
|
||||||
|
border-radius: 6px;
|
||||||
|
cursor: pointer;
|
||||||
|
position: relative;
|
||||||
|
overflow: hidden;
|
||||||
|
transition: var(--el-transition-duration-fast);
|
||||||
|
width: 100px;
|
||||||
|
height: 100px;
|
||||||
|
}
|
||||||
|
.newavatar-uploader-icon{
|
||||||
|
font-size: 28px;
|
||||||
|
color: #8c939d;
|
||||||
|
width: 100px;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
.newavatar-uploader-text{
|
||||||
|
width: 100%;text-align: center;line-height: 20px;
|
||||||
|
font-family: 'Arial Normal', 'Arial';
|
||||||
|
font-weight: 400;
|
||||||
|
font-style: normal;
|
||||||
|
font-size: 12px;
|
||||||
|
color: #949494;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -84,7 +84,7 @@ function downloadFile(obj :any, name :any, suffix :any) {
|
|||||||
document.body.removeChild(link)
|
document.body.removeChild(link)
|
||||||
}
|
}
|
||||||
|
|
||||||
function exportExportsClick(){
|
function exportExportsClick(){
|
||||||
exportAllExports(props.scenarioId,props.deviceId).then((response:any) => {
|
exportAllExports(props.scenarioId,props.deviceId).then((response:any) => {
|
||||||
downloadFile(response, '结果数据' , 'xlsx')
|
downloadFile(response, '结果数据' , 'xlsx')
|
||||||
});
|
});
|
||||||
@ -111,14 +111,14 @@ function downloadFile(obj :any, name :any, suffix :any) {
|
|||||||
<el-table-column v-if="getIf(selectData,'pulse_velocity')" prop="pulse_velocity" label="脉冲速度(单位:Hz)" min-width="160"></el-table-column>
|
<el-table-column v-if="getIf(selectData,'pulse_velocity')" prop="pulse_velocity" label="脉冲速度(单位:Hz)" min-width="160"></el-table-column>
|
||||||
<el-table-column v-if="getIf(selectData,'u_concentration')" prop="u_concentration" label="铀浓度(g/L)" min-width="160"></el-table-column>
|
<el-table-column v-if="getIf(selectData,'u_concentration')" prop="u_concentration" label="铀浓度(g/L)" min-width="160"></el-table-column>
|
||||||
<el-table-column v-if="getIf(selectData,'uo2_density')" prop="uo2_density" label="氧化铀密度(g/cm3)" min-width="160"></el-table-column>
|
<el-table-column v-if="getIf(selectData,'uo2_density')" prop="uo2_density" label="氧化铀密度(g/cm3)" min-width="160"></el-table-column>
|
||||||
<el-table-column v-if="getIf(selectData,'u_enrichment')" prop="u_enrichment" label="铀富集度(%)" min-width="160"></el-table-column>
|
<el-table-column v-if="getIf(selectData,'u_enrichment')" prop="u_enrichment" label="铀富集度" min-width="160"></el-table-column>
|
||||||
<el-table-column v-if="getIf(selectData,'pu_concentration')" prop="pu_concentration" label="钚浓度(g/L)" min-width="160"></el-table-column>
|
<el-table-column v-if="getIf(selectData,'pu_concentration')" prop="pu_concentration" label="钚浓度(g/L)" min-width="160"></el-table-column>
|
||||||
<el-table-column v-if="getIf(selectData,'puo2_density')" prop="puo2_density" label="氧化钚密度(g/cm3)" min-width="160"></el-table-column>
|
<el-table-column v-if="getIf(selectData,'puo2_density')" prop="puo2_density" label="氧化钚密度(g/cm3)" min-width="160"></el-table-column>
|
||||||
<el-table-column v-if="getIf(selectData,'pu_isotope')" prop="pu_isotope" label="钚同位素比例(PU-240占比)%" min-width="160"></el-table-column>
|
<el-table-column v-if="getIf(selectData,'pu_isotope')" prop="pu_isotope" label="钚同位素比例(PU-240占比)" min-width="160"></el-table-column>
|
||||||
<el-table-column v-if="getIf(selectData,'hno3_acidity')" prop="hno3_acidity" label="硝酸酸度(mol/L)" min-width="160"></el-table-column>
|
<el-table-column v-if="getIf(selectData,'hno3_acidity')" prop="hno3_acidity" label="硝酸酸度(mol/L)" min-width="160"></el-table-column>
|
||||||
<el-table-column v-if="getIf(selectData,'h2c2o4_concentration')" prop="h2c2o4_concentration" label="草酸浓度(mol/L)" min-width="160"></el-table-column>
|
<el-table-column v-if="getIf(selectData,'h2c2o4_concentration')" prop="h2c2o4_concentration" label="草酸浓度(mol/L)" min-width="160"></el-table-column>
|
||||||
<el-table-column v-if="getIf(selectData,'organic_ratio')" prop="organic_ratio" label="有机相比例%" min-width="160"></el-table-column>
|
<el-table-column v-if="getIf(selectData,'organic_ratio')" prop="organic_ratio" label="有机相比例" min-width="160"></el-table-column>
|
||||||
<el-table-column v-if="getIf(selectData,'moisture_content')" prop="moisture_content" label="含水率%" min-width="160"></el-table-column>
|
<el-table-column v-if="getIf(selectData,'moisture_content')" prop="moisture_content" label="含水率" min-width="160"></el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<div style="display: flex; justify-content: flex-end;">
|
<div style="display: flex; justify-content: flex-end;">
|
||||||
<Page :total="total" v-model:size="queryParams.size" v-model:current="queryParams.current" @pagination="getScenarioResults" ></Page>
|
<Page :total="total" v-model:size="queryParams.size" v-model:current="queryParams.current" @pagination="getScenarioResults" ></Page>
|
||||||
|
|||||||
@ -14,9 +14,10 @@ import {
|
|||||||
Snapline,
|
Snapline,
|
||||||
Transform
|
Transform
|
||||||
} from '@antv/x6'
|
} from '@antv/x6'
|
||||||
|
import { getDictItemById } from '@/api/dict';
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { updateProjects,projectsById} from "@/api/business/project";
|
import { updateProjects,projectsById} from "@/api/business/project";
|
||||||
|
import { sizeSchemaAll } from "@/api/business/database/device";
|
||||||
import { getByScenario } from "@/api/business/scenario";
|
import { getByScenario } from "@/api/business/scenario";
|
||||||
import textimg from '@/assets/x6/text.png'
|
import textimg from '@/assets/x6/text.png'
|
||||||
import echartsimg from '@/assets/x6/charts.png'
|
import echartsimg from '@/assets/x6/charts.png'
|
||||||
@ -44,6 +45,59 @@ const props = defineProps({
|
|||||||
default: ''
|
default: ''
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
const menuData:any = ref([])
|
||||||
|
|
||||||
|
// 查询字典项
|
||||||
|
function menuInit() {
|
||||||
|
let params = {
|
||||||
|
dictId: 'fe2c3418b8998f4e64d56ab46bfe0fed',
|
||||||
|
size:99,
|
||||||
|
current:1
|
||||||
|
}
|
||||||
|
getDictItemById(params).then((result: any) => {
|
||||||
|
|
||||||
|
menuData.value = result.data.records;
|
||||||
|
getSizeSchemaList()
|
||||||
|
}).catch((err: any) => {
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
//获取所有项目列表
|
||||||
|
const sizeSchemaInfo:any = ref({});
|
||||||
|
function getDeviceTypeName(deviceType:any){
|
||||||
|
let name:any = ""
|
||||||
|
for(let i = 0;i<menuData.value.length;i++){
|
||||||
|
if(menuData.value[i].itemCode == deviceType){
|
||||||
|
name = menuData.value[i].dictName
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
return name
|
||||||
|
}
|
||||||
|
|
||||||
|
async function getSizeSchemaList(){
|
||||||
|
let result:any = await sizeSchemaAll({})
|
||||||
|
for(let item in result){
|
||||||
|
result[item].deviceTypeName = getDeviceTypeName(result[item].deviceType)
|
||||||
|
result[item].fields.forEach((items:any) => {
|
||||||
|
items.name = items.label
|
||||||
|
items.code = items.key
|
||||||
|
items.checked = false
|
||||||
|
items.deviceType = result[item].deviceType,
|
||||||
|
items.deviceTypeName = getDeviceTypeName(result[item].deviceType)
|
||||||
|
})
|
||||||
|
// item.checked = true
|
||||||
|
// item.fields.forEach((items:any) => {
|
||||||
|
// items.checked = true
|
||||||
|
// }
|
||||||
|
// })
|
||||||
|
}
|
||||||
|
sizeSchemaInfo.value = result
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
const sliderIndex = ref<any>(0) // 选中时间
|
const sliderIndex = ref<any>(0) // 选中时间
|
||||||
const sliderValues = ref<any>([]) // 时间轴
|
const sliderValues = ref<any>([]) // 时间轴
|
||||||
const deviceTypetype:any = ref('') // 设备类型
|
const deviceTypetype:any = ref('') // 设备类型
|
||||||
@ -154,6 +208,7 @@ function addAttrText(item:any,index:any,useData:any){
|
|||||||
let tempData:any = []
|
let tempData:any = []
|
||||||
if(item.scenarioResults[index].attrState){
|
if(item.scenarioResults[index].attrState){
|
||||||
let attrState = JSON.parse(item.scenarioResults[index].attrState)
|
let attrState = JSON.parse(item.scenarioResults[index].attrState)
|
||||||
|
debugger
|
||||||
for (const key in attrState) {
|
for (const key in attrState) {
|
||||||
if (!Object.hasOwn(attrState, key)) continue;
|
if (!Object.hasOwn(attrState, key)) continue;
|
||||||
const element = attrState[key];
|
const element = attrState[key];
|
||||||
@ -200,7 +255,7 @@ function getName(code:any) {
|
|||||||
return name = "氧化铀密度(g/cm3)";
|
return name = "氧化铀密度(g/cm3)";
|
||||||
break;
|
break;
|
||||||
case 'u_enrichment':
|
case 'u_enrichment':
|
||||||
return name = "铀富集度(%)";
|
return name = "铀富集度";
|
||||||
break;
|
break;
|
||||||
case 'pu_concentration':
|
case 'pu_concentration':
|
||||||
return name = "钚浓度(g/L)";
|
return name = "钚浓度(g/L)";
|
||||||
@ -209,7 +264,7 @@ function getName(code:any) {
|
|||||||
return name = "氧化钚密度(g/cm3)";
|
return name = "氧化钚密度(g/cm3)";
|
||||||
break;
|
break;
|
||||||
case 'pu_isotope':
|
case 'pu_isotope':
|
||||||
return name = "钚同位素比例(PU-240占比)%";
|
return name = "钚同位素比例(PU-240占比)";
|
||||||
break;
|
break;
|
||||||
case 'hno3_acidity':
|
case 'hno3_acidity':
|
||||||
return name = "硝酸酸度(mol/L)";
|
return name = "硝酸酸度(mol/L)";
|
||||||
@ -218,10 +273,10 @@ function getName(code:any) {
|
|||||||
return name = "草酸浓度(mol/L)";
|
return name = "草酸浓度(mol/L)";
|
||||||
break;
|
break;
|
||||||
case 'organic_ratio':
|
case 'organic_ratio':
|
||||||
return name = "有机相比例%";
|
return name = "有机相比例";
|
||||||
break;
|
break;
|
||||||
case 'moisture_content':
|
case 'moisture_content':
|
||||||
return name = "含水率%";
|
return name = "含水率";
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
return name = "";
|
return name = "";
|
||||||
@ -296,7 +351,7 @@ function groupByDeviceId(data:any) { // 按设备id分组
|
|||||||
}
|
}
|
||||||
|
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
|
menuInit()
|
||||||
scenarioId.value = props.scenarioId
|
scenarioId.value = props.scenarioId
|
||||||
// #region 初始化画布
|
// #region 初始化画布
|
||||||
graph = new Graph({
|
graph = new Graph({
|
||||||
@ -804,10 +859,26 @@ function dialogAttributeDialog(){ // 关闭变动设置弹窗
|
|||||||
|
|
||||||
function confirmClick(){
|
function confirmClick(){
|
||||||
let tempData:any = []
|
let tempData:any = []
|
||||||
for(let i = 0;i<deviceList.value.length;i++){
|
// for(let i = 0;i<deviceList.value.length;i++){
|
||||||
if(deviceList.value[i].checked){
|
// if(deviceList.value[i].checked){
|
||||||
tempData.push(deviceList.value[i].code)
|
// tempData.push(deviceList.value[i].code)
|
||||||
}
|
// }
|
||||||
|
// }
|
||||||
|
|
||||||
|
// items.name = items.label
|
||||||
|
// items.code = items.key
|
||||||
|
// items.checked = false
|
||||||
|
// items.deviceType = result[item].deviceType,
|
||||||
|
// items.deviceTypeName = getDeviceTypeName(result[item].deviceType)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
for(let item in sizeSchemaInfo.value){
|
||||||
|
sizeSchemaInfo.value[item].fields.forEach((items:any) => {
|
||||||
|
if(items.checked == true){
|
||||||
|
tempData.push(items.deviceType+items.code)
|
||||||
|
}
|
||||||
|
})
|
||||||
}
|
}
|
||||||
for(let i = 0;i<materialList.value.length;i++){
|
for(let i = 0;i<materialList.value.length;i++){
|
||||||
if(materialList.value[i].checked){
|
if(materialList.value[i].checked){
|
||||||
@ -883,9 +954,24 @@ function dialogAttributeDialog(){ // 关闭变动设置弹窗
|
|||||||
</div>
|
</div>
|
||||||
<div style="width: 100%; height: calc(100vh - 300px);overflow: auto;">
|
<div style="width: 100%; height: calc(100vh - 300px);overflow: auto;">
|
||||||
<div class="deviceList-box" v-if="isTab == 0">
|
<div class="deviceList-box" v-if="isTab == 0">
|
||||||
<div v-for="(item,index) in deviceList" :key="index" class="deviceList-li">
|
|
||||||
<el-checkbox v-model="item.checked" :label="item.name"></el-checkbox>
|
<div v-for="(item,index) in sizeSchemaInfo" :key="index">
|
||||||
|
<div class="deviceList-li">
|
||||||
|
{{item.deviceTypeName}}({{item.deviceType}})
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div v-for="(items,index) in item.fields" :key="index" class="deviceList-li">
|
||||||
|
<el-checkbox v-model="items.checked" :label="items.name"></el-checkbox>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- <div v-for="(item,index) in deviceList" :key="index" class="deviceList-li">
|
||||||
|
<el-checkbox v-model="item.checked" :label="item.name"></el-checkbox>
|
||||||
|
</div> -->
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div class="deviceList-box" v-if="isTab == 1">
|
<div class="deviceList-box" v-if="isTab == 1">
|
||||||
<div v-for="(item,index) in materialList" :key="index" class="deviceList-li">
|
<div v-for="(item,index) in materialList" :key="index" class="deviceList-li">
|
||||||
|
|||||||
@ -7,7 +7,7 @@ export default {
|
|||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { onMounted, ref, nextTick } from "vue";
|
import { onMounted, ref, nextTick } from "vue";
|
||||||
import { ElForm, ElMessage, ElMessageBox } from "element-plus";
|
import { ElForm, ElMessage, ElMessageBox } from "element-plus";
|
||||||
import { searchCriticalDataPage,addCriticalData,updateCriticalData,deleteCriticalData,deleteBatchCriticalData} from "@/api/business/database/criticalData";
|
import { searchCriticalDataPage,addCriticalData,updateCriticalData,deleteCriticalData,deleteBatchCriticalData,exportAllExports} from "@/api/business/database/criticalData";
|
||||||
import { getDictItemById } from '@/api/dict';
|
import { getDictItemById } from '@/api/dict';
|
||||||
import { sizeSchemaAll } from "@/api/business/database/device";
|
import { sizeSchemaAll } from "@/api/business/database/device";
|
||||||
|
|
||||||
@ -309,6 +309,25 @@ onMounted(() => {
|
|||||||
getSizeSchemaList()
|
getSizeSchemaList()
|
||||||
menuInit()
|
menuInit()
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
|
function exportExportsClick(){
|
||||||
|
exportAllExports(queryParams.value.type).then((response:any) => {
|
||||||
|
downloadFile(response, '临界数据数据' , 'xlsx')
|
||||||
|
});
|
||||||
|
}
|
||||||
|
function downloadFile(obj :any, name :any, suffix :any) {
|
||||||
|
const url = window.URL.createObjectURL(new Blob([obj]))
|
||||||
|
const link = document.createElement('a')
|
||||||
|
link.style.display = 'none'
|
||||||
|
link.href = url
|
||||||
|
const fileName = name.trim() + '.' + suffix
|
||||||
|
link.setAttribute('download', fileName)
|
||||||
|
document.body.appendChild(link)
|
||||||
|
link.click()
|
||||||
|
document.body.removeChild(link)
|
||||||
|
}
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
@ -343,6 +362,7 @@ onMounted(() => {
|
|||||||
:on-error="handleError">
|
:on-error="handleError">
|
||||||
<el-button type="primary" style="margin: 0 10px;" v-hasPerm="['criticalData:import']">导入</el-button>
|
<el-button type="primary" style="margin: 0 10px;" v-hasPerm="['criticalData:import']">导入</el-button>
|
||||||
</el-upload>
|
</el-upload>
|
||||||
|
<el-button type="primary" @click="exportExportsClick">导出</el-button>
|
||||||
<el-button :type="multipleSelection.length > 0 ? 'primary' : ''"
|
<el-button :type="multipleSelection.length > 0 ? 'primary' : ''"
|
||||||
:disabled="multipleSelection.length <= 0" @click="delClick" v-hasPerm="['criticalData:del']">删除</el-button>
|
:disabled="multipleSelection.length <= 0" @click="delClick" v-hasPerm="['criticalData:del']">删除</el-button>
|
||||||
</div>
|
</div>
|
||||||
@ -388,7 +408,7 @@ onMounted(() => {
|
|||||||
:modal="false" draggable :before-close="handleClose" :title="title"
|
:modal="false" draggable :before-close="handleClose" :title="title"
|
||||||
append-to-body width="677px" height="530px">
|
append-to-body width="677px" height="530px">
|
||||||
|
|
||||||
<el-form ref="infoForm" :model="info" :rules="rules" label-width="100px" >
|
<el-form ref="infoForm" :model="info" :rules="rules" label-width="100px" style="height: calc(100vh - 160px);overflow: auto;">
|
||||||
<el-form-item :label="item.label" style="width: 100%;" v-for="item in sourceTempData">
|
<el-form-item :label="item.label" style="width: 100%;" v-for="item in sourceTempData">
|
||||||
<el-input-number
|
<el-input-number
|
||||||
placeholder="请输入长度"
|
placeholder="请输入长度"
|
||||||
|
|||||||
@ -7,7 +7,8 @@ export default {
|
|||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { onMounted, ref, nextTick } from "vue";
|
import { onMounted, ref, nextTick } from "vue";
|
||||||
import { ElForm, ElMessage, ElMessageBox } from "element-plus";
|
import { ElForm, ElMessage, ElMessageBox } from "element-plus";
|
||||||
import { searchDevicesPage,addDevices,updateDevices,deleteDevices,deleteBatchDevices,sizeSchemaAll} from "@/api/business/database/device";
|
import { searchDevicesPage,addDevices,updateDevices,deleteDevices,deleteBatchDevices,sizeSchemaAll,
|
||||||
|
exportAllExports} from "@/api/business/database/device";
|
||||||
import { getDictItemById } from '@/api/dict';
|
import { getDictItemById } from '@/api/dict';
|
||||||
import Page from '@/components/Pagination/page.vue'
|
import Page from '@/components/Pagination/page.vue'
|
||||||
import { getToken } from '@/utils/auth'
|
import { getToken } from '@/utils/auth'
|
||||||
@ -327,6 +328,24 @@ const handleInput = (val: string) => {
|
|||||||
val = value.slice(0, -1);
|
val = value.slice(0, -1);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
function exportExportsClick(){
|
||||||
|
exportAllExports(queryParams.value.type).then((response:any) => {
|
||||||
|
downloadFile(response, '设备数据' , 'xlsx')
|
||||||
|
});
|
||||||
|
}
|
||||||
|
function downloadFile(obj :any, name :any, suffix :any) {
|
||||||
|
const url = window.URL.createObjectURL(new Blob([obj]))
|
||||||
|
const link = document.createElement('a')
|
||||||
|
link.style.display = 'none'
|
||||||
|
link.href = url
|
||||||
|
const fileName = name.trim() + '.' + suffix
|
||||||
|
link.setAttribute('download', fileName)
|
||||||
|
document.body.appendChild(link)
|
||||||
|
link.click()
|
||||||
|
document.body.removeChild(link)
|
||||||
|
}
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
@ -356,7 +375,7 @@ const handleInput = (val: string) => {
|
|||||||
accept=".xlsx,.xls" v-hasPerm="['device:import']"
|
accept=".xlsx,.xls" v-hasPerm="['device:import']"
|
||||||
class="upload-demo"
|
class="upload-demo"
|
||||||
:data="{deviceType: queryParams.type}"
|
:data="{deviceType: queryParams.type}"
|
||||||
:action=" url + '/devices/import' "
|
:action=" url + '/devices/v2/import' "
|
||||||
:headers="{ token: getToken() }"
|
:headers="{ token: getToken() }"
|
||||||
:show-file-list="false"
|
:show-file-list="false"
|
||||||
:before-upload="handlePreview"
|
:before-upload="handlePreview"
|
||||||
@ -364,6 +383,7 @@ const handleInput = (val: string) => {
|
|||||||
:on-error="handleError">
|
:on-error="handleError">
|
||||||
<el-button type="primary" style="margin: 0 10px;">导入</el-button>
|
<el-button type="primary" style="margin: 0 10px;">导入</el-button>
|
||||||
</el-upload>
|
</el-upload>
|
||||||
|
<el-button type="primary" @click="exportExportsClick">导出</el-button>
|
||||||
<el-button :type="multipleSelection.length > 0 ? 'primary' : ''" v-hasPerm="['device:del']"
|
<el-button :type="multipleSelection.length > 0 ? 'primary' : ''" v-hasPerm="['device:del']"
|
||||||
:disabled="multipleSelection.length <= 0" @click="delClick">删除</el-button>
|
:disabled="multipleSelection.length <= 0" @click="delClick">删除</el-button>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@ -7,7 +7,7 @@ export default {
|
|||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { onMounted, ref, nextTick } from "vue";
|
import { onMounted, ref, nextTick } from "vue";
|
||||||
import { ElForm, ElMessage, ElMessageBox } from "element-plus";
|
import { ElForm, ElMessage, ElMessageBox } from "element-plus";
|
||||||
import { searchMaterialsPage,addMaterials,updateMaterials,deleteMaterials,deleteBatchMaterials} from "@/api/business/database/material";
|
import { searchMaterialsPage,addMaterials,updateMaterials,deleteMaterials,deleteBatchMaterials,exportAllExports} from "@/api/business/database/material";
|
||||||
import Page from '@/components/Pagination/page.vue'
|
import Page from '@/components/Pagination/page.vue'
|
||||||
import { getToken } from '@/utils/auth'
|
import { getToken } from '@/utils/auth'
|
||||||
const url = import.meta.env.VITE_APP_BASE_API;
|
const url = import.meta.env.VITE_APP_BASE_API;
|
||||||
@ -90,6 +90,7 @@ const info: any = ref({
|
|||||||
h2c2o4Concentration: "",
|
h2c2o4Concentration: "",
|
||||||
organicRatio: "",
|
organicRatio: "",
|
||||||
moistureContent: "",
|
moistureContent: "",
|
||||||
|
iconBase64: ""
|
||||||
});
|
});
|
||||||
|
|
||||||
const dialogVisible = ref(false);
|
const dialogVisible = ref(false);
|
||||||
@ -108,6 +109,7 @@ function addClick() {
|
|||||||
h2c2o4Concentration: "",
|
h2c2o4Concentration: "",
|
||||||
organicRatio: "",
|
organicRatio: "",
|
||||||
moistureContent: "",
|
moistureContent: "",
|
||||||
|
iconBase64: ""
|
||||||
};
|
};
|
||||||
customAttrsData.value = []
|
customAttrsData.value = []
|
||||||
dialogVisible.value = true;
|
dialogVisible.value = true;
|
||||||
@ -301,6 +303,38 @@ function handleError(file: any){
|
|||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
gettableData();
|
gettableData();
|
||||||
});
|
});
|
||||||
|
function exportExportsClick(){
|
||||||
|
exportAllExports().then((response:any) => {
|
||||||
|
downloadFile(response, '物料数据' , 'xlsx')
|
||||||
|
});
|
||||||
|
}
|
||||||
|
function downloadFile(obj :any, name :any, suffix :any) {
|
||||||
|
const url = window.URL.createObjectURL(new Blob([obj]))
|
||||||
|
const link = document.createElement('a')
|
||||||
|
link.style.display = 'none'
|
||||||
|
link.href = url
|
||||||
|
const fileName = name.trim() + '.' + suffix
|
||||||
|
link.setAttribute('download', fileName)
|
||||||
|
document.body.appendChild(link)
|
||||||
|
link.click()
|
||||||
|
document.body.removeChild(link)
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
function uploadIconBaseChange(file:any){
|
||||||
|
var reader = new FileReader();
|
||||||
|
reader.readAsDataURL(file.raw);
|
||||||
|
reader.onload = () => {
|
||||||
|
info.value.iconBase64 =reader.result
|
||||||
|
};
|
||||||
|
reader.onerror = function(error) {
|
||||||
|
console.log("Error: ", error);
|
||||||
|
};
|
||||||
|
}
|
||||||
|
function delIconBase(){
|
||||||
|
info.value.iconBase64 = " "
|
||||||
|
}
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
@ -327,6 +361,7 @@ onMounted(() => {
|
|||||||
:on-error="handleError">
|
:on-error="handleError">
|
||||||
<el-button type="primary" style="margin: 0 10px;" v-hasPerm="['material:import']">导入</el-button>
|
<el-button type="primary" style="margin: 0 10px;" v-hasPerm="['material:import']">导入</el-button>
|
||||||
</el-upload>
|
</el-upload>
|
||||||
|
<el-button type="primary" @click="exportExportsClick">导出</el-button>
|
||||||
<el-button :type="multipleSelection.length > 0 ? 'primary' : ''"
|
<el-button :type="multipleSelection.length > 0 ? 'primary' : ''"
|
||||||
:disabled="multipleSelection.length <= 0" @click="delClick" v-hasPerm="['material:del']">删除</el-button>
|
:disabled="multipleSelection.length <= 0" @click="delClick" v-hasPerm="['material:del']">删除</el-button>
|
||||||
</div>
|
</div>
|
||||||
@ -381,7 +416,7 @@ onMounted(() => {
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
<div class="Materials_dialog_display">
|
<div class="Materials_dialog_display">
|
||||||
<el-form-item label="铀富集度(%)" prop="uEnrichment">
|
<el-form-item label="铀富集度" prop="uEnrichment">
|
||||||
<el-input v-model="info.uEnrichment" style="width: 100%" placeholder="" @input="handleNumberInput('uEnrichment')"></el-input>
|
<el-input v-model="info.uEnrichment" style="width: 100%" placeholder="" @input="handleNumberInput('uEnrichment')"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="钚浓度(g/L)" prop="puConcentration">
|
<el-form-item label="钚浓度(g/L)" prop="puConcentration">
|
||||||
@ -392,10 +427,31 @@ onMounted(() => {
|
|||||||
<el-form-item label="氧化钚密度(g/cm3)" prop="puo2Density">
|
<el-form-item label="氧化钚密度(g/cm3)" prop="puo2Density">
|
||||||
<el-input v-model="info.puo2Density" style="width: 100%" placeholder="" @input="handleNumberInput('puo2Density')"></el-input>
|
<el-input v-model="info.puo2Density" style="width: 100%" placeholder="" @input="handleNumberInput('puo2Density')"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="钚同位素比例(PU-240占比)%" prop="puIsotope">
|
<el-form-item label="PU-238占比" prop="puIsotope">
|
||||||
<el-input v-model="info.puIsotope" style="width: 100%" placeholder="" @input="handleNumberInput('puIsotope')"></el-input>
|
<el-input v-model="info.ePu238" style="width: 100%" placeholder="" @input="handleNumberInput('ePu238')"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="Materials_dialog_display">
|
||||||
|
<el-form-item label="PU-239占比" prop="puIsotope">
|
||||||
|
<el-input v-model="info.ePu239" style="width: 100%" placeholder="" @input="handleNumberInput('ePu239')"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="PU-240占比" prop="puIsotope">
|
||||||
|
<el-input v-model="info.ePu240" style="width: 100%" placeholder="" @input="handleNumberInput('ePu240')"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</div>
|
||||||
|
<div class="Materials_dialog_display">
|
||||||
|
<el-form-item label="PU-241占比" prop="puIsotope">
|
||||||
|
<el-input v-model="info.ePu241" style="width: 100%" placeholder="" @input="handleNumberInput('ePu241')"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="PU-242占比" prop="puIsotope">
|
||||||
|
<el-input v-model="info.ePu242" style="width: 100%" placeholder="" @input="handleNumberInput('ePu242')"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<div class="Materials_dialog_display">
|
<div class="Materials_dialog_display">
|
||||||
<el-form-item label="硝酸酸度(mol/L)" prop="hno3Acidity">
|
<el-form-item label="硝酸酸度(mol/L)" prop="hno3Acidity">
|
||||||
<el-input v-model="info.hno3Acidity" style="width: 100%" placeholder="" @input="handleNumberInput('hno3Acidity')"></el-input>
|
<el-input v-model="info.hno3Acidity" style="width: 100%" placeholder="" @input="handleNumberInput('hno3Acidity')"></el-input>
|
||||||
@ -405,13 +461,39 @@ onMounted(() => {
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
<div class="Materials_dialog_display">
|
<div class="Materials_dialog_display">
|
||||||
<el-form-item label="有机相比例%" prop="organicRatio">
|
<el-form-item label="有机相比例" prop="organicRatio">
|
||||||
<el-input v-model="info.organicRatio" style="width: 100%" placeholder="" @input="handleNumberInput('organicRatio')"></el-input>
|
<el-input v-model="info.organicRatio" style="width: 100%" placeholder="" @input="handleNumberInput('organicRatio')"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="含水率%" prop="moistureContent">
|
<el-form-item label="含水率" prop="moistureContent">
|
||||||
<el-input v-model="info.moistureContent" style="width: 100%" placeholder="" @input="handleNumberInput('moistureContent')"></el-input>
|
<el-input v-model="info.moistureContent" style="width: 100%" placeholder="" @input="handleNumberInput('moistureContent')"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
|
<el-form-item label="物料图片">
|
||||||
|
<el-upload
|
||||||
|
style="margin-left: 10px;"
|
||||||
|
class="avatar-uploader"
|
||||||
|
accept=".png, .jpg, .jpeg"
|
||||||
|
action=""
|
||||||
|
:show-file-list="false"
|
||||||
|
:auto-upload="false"
|
||||||
|
@change="uploadIconBaseChange"
|
||||||
|
>
|
||||||
|
<div style="width: 100px;height: 100px;position: relative;" v-if="info.iconBase64 != ''
|
||||||
|
&& info.iconBase64 != null && info.iconBase64 != ' '">
|
||||||
|
<img :src="info.iconBase64" class="avatar" />
|
||||||
|
<div style="position: absolute;top: 0px;left: 0px;z-index: 1;width: 100px;height: 100px;background: rgba(0,0,0,0.3);color: cornflowerblue;">
|
||||||
|
<el-icon style="position: absolute;top: 40px;left: 40px;z-index: 1;font-size: 20px;"
|
||||||
|
@click.stop="delIconBase"><Delete /></el-icon>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div v-else>
|
||||||
|
<el-icon class="newavatar-uploader-icon"><Plus /></el-icon>
|
||||||
|
<div class="newavatar-uploader-text">物料图片</div>
|
||||||
|
</div>
|
||||||
|
</el-upload>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
|
||||||
<div class="Materials_dialog_titledisplay">
|
<div class="Materials_dialog_titledisplay">
|
||||||
<div class="Materials_dialog_titleline"></div>
|
<div class="Materials_dialog_titleline"></div>
|
||||||
<div>物料成分</div>
|
<div>物料成分</div>
|
||||||
@ -446,12 +528,13 @@ onMounted(() => {
|
|||||||
<svg t="1766543724217" style="margin-right: 5px;" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="6518" width="16" height="16"><path d="M105 480a8 8 0 0 1 8-8h799a8 8 0 0 1 8 8v64a8 8 0 0 1-8 8H113a8 8 0 0 1-8-8v-64z" fill="#266FFF" p-id="6519"></path><path d="M480 920a8 8 0 0 1-8-8V112a8 8 0 0 1 8-8h64a8 8 0 0 1 8 8v800a8 8 0 0 1-8 8h-64z" fill="#266FFF" p-id="6520"></path></svg>
|
<svg t="1766543724217" style="margin-right: 5px;" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="6518" width="16" height="16"><path d="M105 480a8 8 0 0 1 8-8h799a8 8 0 0 1 8 8v64a8 8 0 0 1-8 8H113a8 8 0 0 1-8-8v-64z" fill="#266FFF" p-id="6519"></path><path d="M480 920a8 8 0 0 1-8-8V112a8 8 0 0 1 8-8h64a8 8 0 0 1 8 8v800a8 8 0 0 1-8 8h-64z" fill="#266FFF" p-id="6520"></path></svg>
|
||||||
添加一行
|
添加一行
|
||||||
</div>
|
</div>
|
||||||
<span class="dialog-footer"
|
|
||||||
|
</el-form>
|
||||||
|
<span class="dialog-footer"
|
||||||
style="display: flex;display: -webkit-flex; justify-content: flex-end;-webkit-justify-content: flex-end;">
|
style="display: flex;display: -webkit-flex; justify-content: flex-end;-webkit-justify-content: flex-end;">
|
||||||
<el-button @click="handleClose">取 消</el-button>
|
<el-button @click="handleClose">取 消</el-button>
|
||||||
<el-button type="primary" @click="confirmClick(infoForm)">确 定</el-button>
|
<el-button type="primary" @click="confirmClick(infoForm)">确 定</el-button>
|
||||||
</span>
|
</span>
|
||||||
</el-form>
|
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
@ -722,5 +805,30 @@ onMounted(() => {
|
|||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.newavatar-uploader-icon{
|
||||||
|
font-size: 28px;
|
||||||
|
color: #8c939d;
|
||||||
|
width: 100px;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
.newavatar-uploader-text{
|
||||||
|
width: 100%;text-align: center;line-height: 20px;
|
||||||
|
font-family: 'Arial Normal', 'Arial';
|
||||||
|
font-weight: 400;
|
||||||
|
font-style: normal;
|
||||||
|
font-size: 12px;
|
||||||
|
color: #949494;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
<style>
|
||||||
|
.avatar-uploader .el-upload {
|
||||||
|
border: 1px dashed var(--el-border-color);
|
||||||
|
border-radius: 6px;
|
||||||
|
cursor: pointer;
|
||||||
|
position: relative;
|
||||||
|
overflow: hidden;
|
||||||
|
transition: var(--el-transition-duration-fast);
|
||||||
|
width: 100px;
|
||||||
|
height: 100px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
@ -198,7 +198,7 @@ public class MaterialController {
|
|||||||
"pu_concentration", "puo2_density", "pu_isotope",
|
"pu_concentration", "puo2_density", "pu_isotope",
|
||||||
"e_pu240", "e_pu242", "e_pu241", "e_pu239", "e_pu238",
|
"e_pu240", "e_pu242", "e_pu241", "e_pu239", "e_pu238",
|
||||||
"hno3_acidity", "h2c2o4_concentration", "organic_ratio", "moisture_content",
|
"hno3_acidity", "h2c2o4_concentration", "organic_ratio", "moisture_content",
|
||||||
"custom_attrs", "created_at", "updated_at", "modifier"
|
"custom_attrs", "created_at", "updated_at", "modifier", "icon_base64"
|
||||||
);
|
);
|
||||||
qw.eq("project_id", "-1");
|
qw.eq("project_id", "-1");
|
||||||
if (name != null && !name.isEmpty()) {
|
if (name != null && !name.isEmpty()) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user