|
@ -1,6 +1,6 @@ |
|
|
<script setup lang="ts"> |
|
|
<script setup lang="ts"> |
|
|
import { list as listMatrix } from 'apis/matrix' |
|
|
import { list as listMatrix } from 'apis/matrix' |
|
|
import { getListByMatrixId } from 'apis/matrixCraft' |
|
|
|
|
|
|
|
|
import { getListByMatrixId, update } from 'apis/matrixCraft' |
|
|
import route from 'assets/images/route.png' |
|
|
import route from 'assets/images/route.png' |
|
|
import route_active from 'assets/images/route_active.png' |
|
|
import route_active from 'assets/images/route_active.png' |
|
|
import route_horizontal_active from 'assets/images/route_horizontal2.png' |
|
|
import route_horizontal_active from 'assets/images/route_horizontal2.png' |
|
@ -74,14 +74,14 @@ const form = ref({ |
|
|
matrixId: undefined, |
|
|
matrixId: undefined, |
|
|
matrixCraftId: undefined, |
|
|
matrixCraftId: undefined, |
|
|
matrixPathType: 'horizontal', // 路径类型 |
|
|
matrixPathType: 'horizontal', // 路径类型 |
|
|
motorZHeight: 15, // 高度 |
|
|
|
|
|
gasPressure: 1, // Mpa兆帕 |
|
|
|
|
|
volume: 10, // 单位uL微升 |
|
|
|
|
|
|
|
|
motorZHeight: undefined, // 高度 |
|
|
|
|
|
gasPressure: undefined, // Mpa兆帕 |
|
|
|
|
|
volume: undefined, // 单位uL微升 |
|
|
highVoltage: true, // 是否打开高压 |
|
|
highVoltage: true, // 是否打开高压 |
|
|
highVoltageValue: undefined, // 高压值 |
|
|
highVoltageValue: undefined, // 高压值 |
|
|
spacing: undefined, // 毫米 |
|
|
spacing: undefined, // 毫米 |
|
|
movingSpeed: 20, // 移动速度 |
|
|
|
|
|
times: 1, // 喷涂遍数 |
|
|
|
|
|
|
|
|
movingSpeed: undefined, // 移动速度 |
|
|
|
|
|
times: undefined, // 喷涂遍数 |
|
|
position: [{ select: true }, { select: false }, { select: false }, { select: false }], |
|
|
position: [{ select: true }, { select: false }, { select: false }, { select: false }], |
|
|
}) |
|
|
}) |
|
|
|
|
|
|
|
@ -149,29 +149,29 @@ const startWork = async () => { |
|
|
}) |
|
|
}) |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
const pauseWork = async () => { |
|
|
|
|
|
const params = { |
|
|
|
|
|
cmdName: 'matrix_spray_pause', |
|
|
|
|
|
cmdId: '', |
|
|
|
|
|
} |
|
|
|
|
|
await sendControl(params) |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
const continueWork = async () => { |
|
|
|
|
|
const params = { |
|
|
|
|
|
cmdName: 'matrix_spray_continue', |
|
|
|
|
|
cmdId: '', |
|
|
|
|
|
param: { |
|
|
|
|
|
motorZHeight: form.value.motorZHeight, // 高度 |
|
|
|
|
|
gasPressure: form.value.gasPressure, // Mpa兆帕 |
|
|
|
|
|
volume: form.value.volume, // 单位uL微升 |
|
|
|
|
|
highVoltage: form.value.highVoltage, // 是否打开高压 |
|
|
|
|
|
highVoltageValue: form.value.highVoltageValue, // 高压值 |
|
|
|
|
|
movingSpeed: form.value.movingSpeed, // 毫米 |
|
|
|
|
|
}, |
|
|
|
|
|
} |
|
|
|
|
|
await sendControl(params) |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
// const pauseWork = async () => { |
|
|
|
|
|
// const params = { |
|
|
|
|
|
// cmdName: 'matrix_spray_pause', |
|
|
|
|
|
// cmdId: '', |
|
|
|
|
|
// } |
|
|
|
|
|
// await sendControl(params) |
|
|
|
|
|
// } |
|
|
|
|
|
// |
|
|
|
|
|
// const continueWork = async () => { |
|
|
|
|
|
// const params = { |
|
|
|
|
|
// cmdName: 'matrix_spray_continue', |
|
|
|
|
|
// cmdId: '', |
|
|
|
|
|
// param: { |
|
|
|
|
|
// motorZHeight: form.value.motorZHeight, // 高度 |
|
|
|
|
|
// gasPressure: form.value.gasPressure, // Mpa兆帕 |
|
|
|
|
|
// volume: form.value.volume, // 单位uL微升 |
|
|
|
|
|
// highVoltage: form.value.highVoltage, // 是否打开高压 |
|
|
|
|
|
// highVoltageValue: form.value.highVoltageValue, // 高压值 |
|
|
|
|
|
// movingSpeed: form.value.movingSpeed, // 毫米 |
|
|
|
|
|
// }, |
|
|
|
|
|
// } |
|
|
|
|
|
// await sendControl(params) |
|
|
|
|
|
// } |
|
|
|
|
|
|
|
|
const stopWork = async () => { |
|
|
const stopWork = async () => { |
|
|
const params = { |
|
|
const params = { |
|
@ -226,28 +226,37 @@ const rules = { |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
const addVisible = ref(false) |
|
|
const addVisible = ref(false) |
|
|
const ok = () => { |
|
|
|
|
|
|
|
|
const ok = async () => { |
|
|
addVisible.value = false |
|
|
addVisible.value = false |
|
|
|
|
|
matrixCraftList.value = await getListByMatrixId(form.value.matrixId) |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
const upDateLoading = ref(false) |
|
|
const upDateLoading = ref(false) |
|
|
const updateCraft = () => { |
|
|
|
|
|
|
|
|
const updateCraft = async () => { |
|
|
|
|
|
if (!form.value.matrixCraftId) { |
|
|
|
|
|
FtMessage.error('请选择工艺') |
|
|
|
|
|
return |
|
|
|
|
|
} |
|
|
upDateLoading.value = true |
|
|
upDateLoading.value = true |
|
|
// const params = { |
|
|
|
|
|
// ...form.value, |
|
|
|
|
|
// id: form.value.matrixCraftId, |
|
|
|
|
|
// } |
|
|
|
|
|
setTimeout(() => { |
|
|
|
|
|
upDateLoading.value = false |
|
|
|
|
|
}, 3000) |
|
|
|
|
|
|
|
|
const params = { |
|
|
|
|
|
...form.value, |
|
|
|
|
|
id: form.value.matrixCraftId, |
|
|
|
|
|
} |
|
|
|
|
|
await update(params) |
|
|
|
|
|
FtMessage.success('保存成功') |
|
|
|
|
|
upDateLoading.value = false |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
const formData = ref({ |
|
|
const formData = ref({ |
|
|
}) |
|
|
}) |
|
|
const addCraft = () => { |
|
|
const addCraft = () => { |
|
|
|
|
|
console.log(form.value) |
|
|
formData.value = { |
|
|
formData.value = { |
|
|
...form.value, |
|
|
...form.value, |
|
|
|
|
|
id: undefined, |
|
|
|
|
|
name: undefined, |
|
|
} |
|
|
} |
|
|
|
|
|
console.log(formData.value) |
|
|
addVisible.value = true |
|
|
addVisible.value = true |
|
|
} |
|
|
} |
|
|
</script> |
|
|
</script> |
|
@ -263,12 +272,12 @@ const addCraft = () => { |
|
|
<ft-button type="primary" @click="updateParam"> |
|
|
<ft-button type="primary" @click="updateParam"> |
|
|
调整参数 |
|
|
调整参数 |
|
|
</ft-button> |
|
|
</ft-button> |
|
|
<ft-button @click="pauseWork"> |
|
|
|
|
|
暂停喷涂 |
|
|
|
|
|
</ft-button> |
|
|
|
|
|
<ft-button @click="continueWork"> |
|
|
|
|
|
继续喷涂 |
|
|
|
|
|
</ft-button> |
|
|
|
|
|
|
|
|
<!-- <ft-button @click="pauseWork"> --> |
|
|
|
|
|
<!-- 暂停喷涂 --> |
|
|
|
|
|
<!-- </ft-button> --> |
|
|
|
|
|
<!-- <ft-button @click="continueWork"> --> |
|
|
|
|
|
<!-- 继续喷涂 --> |
|
|
|
|
|
<!-- </ft-button> --> |
|
|
<ft-button @click="stopWork"> |
|
|
<ft-button @click="stopWork"> |
|
|
结束喷涂 |
|
|
结束喷涂 |
|
|
</ft-button> |
|
|
</ft-button> |
|
@ -325,11 +334,11 @@ const addCraft = () => { |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item label="氮气气压" prop="gasPressure"> |
|
|
<el-form-item label="氮气气压" prop="gasPressure"> |
|
|
<el-input v-model="form.gasPressure" type="number" /> |
|
|
<el-input v-model="form.gasPressure" type="number" /> |
|
|
<span class="unit-text">MPa</span> |
|
|
|
|
|
|
|
|
<span class="unit-text">Mpa</span> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item label="基质流速" prop="volume"> |
|
|
<el-form-item label="基质流速" prop="volume"> |
|
|
<el-input v-model="form.volume" type="number" /> |
|
|
<el-input v-model="form.volume" type="number" /> |
|
|
<span class="unit-text">UL/min</span> |
|
|
|
|
|
|
|
|
<span class="unit-text">uL/min</span> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item label="是否加电" prop="highVoltageValue"> |
|
|
<el-form-item label="是否加电" prop="highVoltageValue"> |
|
|
<div class="voltage-box"> |
|
|
<div class="voltage-box"> |
|
@ -374,11 +383,11 @@ const addCraft = () => { |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item label="氮气气压" prop="gasPressure"> |
|
|
<el-form-item label="氮气气压" prop="gasPressure"> |
|
|
<el-input v-model="updateForm.gasPressure" type="number" /> |
|
|
<el-input v-model="updateForm.gasPressure" type="number" /> |
|
|
<span class="unit-text">MPa</span> |
|
|
|
|
|
|
|
|
<span class="unit-text">Mpa</span> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item label="基质流速" prop="volume"> |
|
|
<el-form-item label="基质流速" prop="volume"> |
|
|
<el-input v-model="updateForm.volume" type="number" /> |
|
|
<el-input v-model="updateForm.volume" type="number" /> |
|
|
<span class="unit-text">UL/min</span> |
|
|
|
|
|
|
|
|
<span class="unit-text">uL/min</span> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item label="是否加电" prop="highVoltageValue"> |
|
|
<el-form-item label="是否加电" prop="highVoltageValue"> |
|
|
<div class="voltage-box"> |
|
|
<div class="voltage-box"> |
|
@ -402,7 +411,7 @@ const addCraft = () => { |
|
|
</el-form> |
|
|
</el-form> |
|
|
</el-drawer> |
|
|
</el-drawer> |
|
|
<start-spray v-if="visible" v-model="text" :source-data="form" @cancel="visible = false" /> |
|
|
<start-spray v-if="visible" v-model="text" :source-data="form" @cancel="visible = false" /> |
|
|
<Edit v-if="addVisible" :matrix-list :form-data @ok="ok" @cancel="addVisible = false" /> |
|
|
|
|
|
|
|
|
<Edit v-if="addVisible" :matrix-list :form-data other-page @ok="ok" @cancel="addVisible = false" /> |
|
|
</div> |
|
|
</div> |
|
|
</template> |
|
|
</template> |
|
|
|
|
|
|
|
|