|
|
@ -1,91 +1,47 @@
|
|
|
|
<template>
|
|
|
|
<template>
|
|
|
|
<el-dialog
|
|
|
|
<el-dialog :title="!dataForm.id ? '新建' : '编辑'" :close-on-click-modal="false" append-to-body :visible.sync="visible"
|
|
|
|
:title="!dataForm.id ? '新建' : '编辑'"
|
|
|
|
class="JNPF-dialog JNPF-dialog_center" lock-scroll width="850px">
|
|
|
|
:close-on-click-modal="false"
|
|
|
|
|
|
|
|
append-to-body
|
|
|
|
|
|
|
|
:visible.sync="visible"
|
|
|
|
|
|
|
|
class="JNPF-dialog JNPF-dialog_center"
|
|
|
|
|
|
|
|
lock-scroll
|
|
|
|
|
|
|
|
width="600px"
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
<el-row :gutter="15" class="">
|
|
|
|
<el-row :gutter="15" class="">
|
|
|
|
<el-form
|
|
|
|
<el-form ref="formRef" :model="dataForm" :rules="dataRule" size="small" label-width="100px"
|
|
|
|
ref="formRef"
|
|
|
|
label-position="right">
|
|
|
|
:model="dataForm"
|
|
|
|
|
|
|
|
:rules="dataRule"
|
|
|
|
|
|
|
|
size="small"
|
|
|
|
|
|
|
|
label-width="100px"
|
|
|
|
|
|
|
|
label-position="right"
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
<template v-if="!loading">
|
|
|
|
<template v-if="!loading">
|
|
|
|
<!-- 具体表单 -->
|
|
|
|
<!-- 具体表单 -->
|
|
|
|
<el-col :span="24">
|
|
|
|
<el-col :span="24">
|
|
|
|
<jnpf-form-tip-item label="设备编号" prop="deviceCode">
|
|
|
|
<jnpf-form-tip-item label="设备编号" prop="deviceCode">
|
|
|
|
<JnpfInput
|
|
|
|
<JnpfInput v-model="dataForm.deviceCode" @change="changeData('deviceCode', -1)" placeholder="请输入设备编号"
|
|
|
|
v-model="dataForm.deviceCode"
|
|
|
|
clearable :style="{ width: '100%' }">
|
|
|
|
@change="changeData('deviceCode', -1)"
|
|
|
|
|
|
|
|
placeholder="请输入设备编号"
|
|
|
|
|
|
|
|
clearable
|
|
|
|
|
|
|
|
:style="{ width: '100%' }"
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
</JnpfInput>
|
|
|
|
</JnpfInput>
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
<el-col :span="24">
|
|
|
|
<el-col :span="24">
|
|
|
|
<jnpf-form-tip-item label="设备名称" prop="deviceName">
|
|
|
|
<jnpf-form-tip-item label="设备名称" prop="deviceName">
|
|
|
|
<JnpfInput
|
|
|
|
<JnpfInput v-model="dataForm.deviceName" @change="changeData('deviceName', -1)" placeholder="请输入设备名称"
|
|
|
|
v-model="dataForm.deviceName"
|
|
|
|
clearable :style="{ width: '100%' }">
|
|
|
|
@change="changeData('deviceName', -1)"
|
|
|
|
|
|
|
|
placeholder="请输入设备名称"
|
|
|
|
|
|
|
|
clearable
|
|
|
|
|
|
|
|
:style="{ width: '100%' }"
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
</JnpfInput>
|
|
|
|
</JnpfInput>
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
<el-col :span="24">
|
|
|
|
<el-col :span="24">
|
|
|
|
<jnpf-form-tip-item label="所属部门" prop="deviceDept">
|
|
|
|
<jnpf-form-tip-item label="所属部门" prop="deviceDept">
|
|
|
|
<JnpfDepSelect
|
|
|
|
<JnpfDepSelect v-model="dataForm.deviceDept" @change="changeData('deviceDept', -1)" placeholder="请选择所属部门"
|
|
|
|
v-model="dataForm.deviceDept"
|
|
|
|
selectType="all" :ableIds="ableAll.deviceDeptableIds" clearable :style="{ width: '100%' }">
|
|
|
|
@change="changeData('deviceDept', -1)"
|
|
|
|
|
|
|
|
placeholder="请选择所属部门"
|
|
|
|
|
|
|
|
selectType="all"
|
|
|
|
|
|
|
|
:ableIds="ableAll.deviceDeptableIds"
|
|
|
|
|
|
|
|
clearable
|
|
|
|
|
|
|
|
:style="{ width: '100%' }"
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
</JnpfDepSelect>
|
|
|
|
</JnpfDepSelect>
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
<el-col :span="24">
|
|
|
|
<el-col :span="24">
|
|
|
|
<jnpf-form-tip-item label="设备类型" prop="deivceType">
|
|
|
|
<jnpf-form-tip-item label="设备类型" prop="deivceType">
|
|
|
|
<JnpfSelect
|
|
|
|
<JnpfSelect v-model="dataForm.deivceType" @change="changeData('deivceType', -1)" placeholder="请选择"
|
|
|
|
v-model="dataForm.deivceType"
|
|
|
|
clearable :style="{ width: '100%' }" :options="deivceTypeOptions" :props="deivceTypeProps">
|
|
|
|
@change="changeData('deivceType', -1)"
|
|
|
|
|
|
|
|
placeholder="请选择"
|
|
|
|
|
|
|
|
clearable
|
|
|
|
|
|
|
|
:style="{ width: '100%' }"
|
|
|
|
|
|
|
|
:options="deivceTypeOptions"
|
|
|
|
|
|
|
|
:props="deivceTypeProps"
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
</JnpfSelect>
|
|
|
|
</JnpfSelect>
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
<el-col :span="24">
|
|
|
|
<el-col :span="24">
|
|
|
|
<jnpf-form-tip-item label="启用状态" prop="enabledStatus">
|
|
|
|
<jnpf-form-tip-item label="启用状态" prop="enabledStatus">
|
|
|
|
<JnpfSelect
|
|
|
|
<JnpfSelect v-model="dataForm.enabledStatus" @change="changeData('enabledStatus', -1)" placeholder="请选择"
|
|
|
|
v-model="dataForm.enabledStatus"
|
|
|
|
clearable :style="{ width: '100%' }" :options="enabledStatusOptions" :props="enabledStatusProps">
|
|
|
|
@change="changeData('enabledStatus', -1)"
|
|
|
|
|
|
|
|
placeholder="请选择"
|
|
|
|
|
|
|
|
clearable
|
|
|
|
|
|
|
|
:style="{ width: '100%' }"
|
|
|
|
|
|
|
|
:options="enabledStatusOptions"
|
|
|
|
|
|
|
|
:props="enabledStatusProps"
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
</JnpfSelect>
|
|
|
|
</JnpfSelect>
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
<el-col :span="24">
|
|
|
|
<!-- <el-col :span="24">
|
|
|
|
<jnpf-form-tip-item label="8小时产量" prop="eightOutput">
|
|
|
|
<jnpf-form-tip-item label="8小时产量" prop="eightOutput">
|
|
|
|
<JnpfInput
|
|
|
|
<JnpfInput
|
|
|
|
v-model="dataForm.eightOutput"
|
|
|
|
v-model="dataForm.eightOutput"
|
|
|
@ -108,7 +64,7 @@
|
|
|
|
>
|
|
|
|
>
|
|
|
|
</JnpfInput>
|
|
|
|
</JnpfInput>
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
</el-col>
|
|
|
|
</el-col> -->
|
|
|
|
<el-col :span="24">
|
|
|
|
<el-col :span="24">
|
|
|
|
<jnpf-form-tip-item label-width="0">
|
|
|
|
<jnpf-form-tip-item label-width="0">
|
|
|
|
<div class="JNPF-common-title">
|
|
|
|
<div class="JNPF-common-title">
|
|
|
@ -131,6 +87,20 @@
|
|
|
|
{{ scope.row.materialName }}
|
|
|
|
{{ scope.row.materialName }}
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table-column>
|
|
|
|
|
|
|
|
<el-table-column label="8小时产量">
|
|
|
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
|
|
|
|
<JnpfInputNumber v-model="scope.row.eightOutput" @change="changeData('eightOutput', -1)"
|
|
|
|
|
|
|
|
placeholder="请输入" clearable :style='{ "width": "100%" }' :precision="2" :step="1" :min="0">
|
|
|
|
|
|
|
|
</JnpfInputNumber>
|
|
|
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
</el-table-column>
|
|
|
|
|
|
|
|
<el-table-column label="12小时产量">
|
|
|
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
|
|
|
|
<JnpfInputNumber v-model="scope.row.twelveOutput" @change="changeData('twelveOutput', -1)"
|
|
|
|
|
|
|
|
placeholder="请输入" clearable :style='{ "width": "100%" }' :precision="2" :step="1" :min="0">
|
|
|
|
|
|
|
|
</JnpfInputNumber>
|
|
|
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
</el-table-column>
|
|
|
|
</el-table>
|
|
|
|
</el-table>
|
|
|
|
<div class="table-actions" @click="fnMaterialListDialog()">
|
|
|
|
<div class="table-actions" @click="fnMaterialListDialog()">
|
|
|
|
<el-button type="text" icon="el-icon-plus">物料绑定</el-button>
|
|
|
|
<el-button type="text" icon="el-icon-plus">物料绑定</el-button>
|
|
|
@ -140,35 +110,15 @@
|
|
|
|
<!-- 表单结束 -->
|
|
|
|
<!-- 表单结束 -->
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-form>
|
|
|
|
</el-form>
|
|
|
|
<SelectDialog
|
|
|
|
<SelectDialog v-if="selectDialogVisible" :config="currTableConf" :formData="dataForm" ref="selectDialog"
|
|
|
|
v-if="selectDialogVisible"
|
|
|
|
@select="addForSelect" @close="selectDialogVisible = false" />
|
|
|
|
:config="currTableConf"
|
|
|
|
|
|
|
|
:formData="dataForm"
|
|
|
|
|
|
|
|
ref="selectDialog"
|
|
|
|
|
|
|
|
@select="addForSelect"
|
|
|
|
|
|
|
|
@close="selectDialogVisible = false"
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
</el-row>
|
|
|
|
</el-row>
|
|
|
|
<span slot="footer" class="dialog-footer">
|
|
|
|
<span slot="footer" class="dialog-footer">
|
|
|
|
<!-- <div class="upAndDown-button" v-if="dataForm.id">
|
|
|
|
|
|
|
|
<el-button @click="prev" :disabled='prevDis'>
|
|
|
|
|
|
|
|
{{ '上一条' }}
|
|
|
|
|
|
|
|
</el-button>
|
|
|
|
|
|
|
|
<el-button @click="next" :disabled='nextDis'>
|
|
|
|
|
|
|
|
{{ '下一条' }}
|
|
|
|
|
|
|
|
</el-button>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<el-button type="primary" @click="dataFormSubmit(2)" :loading="continueBtnLoading">
|
|
|
|
|
|
|
|
{{ !dataForm.id ? '确定并新增' : '确定并继续' }}</el-button> -->
|
|
|
|
|
|
|
|
<el-button @click="visible = false"> 取 消</el-button>
|
|
|
|
<el-button @click="visible = false"> 取 消</el-button>
|
|
|
|
<el-button type="primary" @click="dataFormSubmit()" :loading="btnLoading">
|
|
|
|
<el-button type="primary" @click="dataFormSubmit()" :loading="btnLoading">
|
|
|
|
确 定</el-button
|
|
|
|
确 定</el-button>
|
|
|
|
>
|
|
|
|
|
|
|
|
</span>
|
|
|
|
</span>
|
|
|
|
<MaterialListDialog
|
|
|
|
<MaterialListDialog ref="materialListDialog" @cbSltdChg="fnSltdMaterialChg" />
|
|
|
|
ref="materialListDialog"
|
|
|
|
|
|
|
|
@cbSltdChg="fnSltdMaterialChg"
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
</el-dialog>
|
|
|
|
</el-dialog>
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
|
@ -188,6 +138,7 @@ import {
|
|
|
|
} from "@/components/Generator/utils/index.js";
|
|
|
|
} from "@/components/Generator/utils/index.js";
|
|
|
|
import { thousandsFormat } from "@/components/Generator/utils/index";
|
|
|
|
import { thousandsFormat } from "@/components/Generator/utils/index";
|
|
|
|
import MaterialListDialog from "@/views/yys/yysdevice/MaterialListDialog";
|
|
|
|
import MaterialListDialog from "@/views/yys/yysdevice/MaterialListDialog";
|
|
|
|
|
|
|
|
import { Input } from "element-ui";
|
|
|
|
export default {
|
|
|
|
export default {
|
|
|
|
components: {
|
|
|
|
components: {
|
|
|
|
MaterialListDialog
|
|
|
|
MaterialListDialog
|
|
|
@ -442,6 +393,7 @@ export default {
|
|
|
|
},
|
|
|
|
},
|
|
|
|
request() {
|
|
|
|
request() {
|
|
|
|
let _data = this.dataList();
|
|
|
|
let _data = this.dataList();
|
|
|
|
|
|
|
|
console.log(_data)
|
|
|
|
if (this.dataFormSubmitType == 2) {
|
|
|
|
if (this.dataFormSubmitType == 2) {
|
|
|
|
this.continueBtnLoading = true;
|
|
|
|
this.continueBtnLoading = true;
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|