234 lines
7.0 KiB
Vue
234 lines
7.0 KiB
Vue
|
|
<template>
|
|||
|
|
<div >
|
|||
|
|
<el-row :gutter="0">
|
|||
|
|
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
|||
|
|
<el-col :span="24">
|
|||
|
|
<el-form-item label="月结编号" prop="custNo">
|
|||
|
|
<el-input v-model="form.custNo" placeholder="请输入月结编号" />
|
|||
|
|
</el-form-item>
|
|||
|
|
</el-col>
|
|||
|
|
<el-col :span="24">
|
|||
|
|
<el-form-item label="申请客户编码" prop="customerCode">
|
|||
|
|
<el-input v-model="form.customerCode" placeholder="请输入申请客户编码" />
|
|||
|
|
</el-form-item>
|
|||
|
|
</el-col>
|
|||
|
|
<el-col :span="24">
|
|||
|
|
<el-form-item label="申请序号" prop="applySeq">
|
|||
|
|
<el-input v-model="form.applySeq" placeholder="请输入申请序号" />
|
|||
|
|
</el-form-item>
|
|||
|
|
</el-col>
|
|||
|
|
<el-col :span="24">
|
|||
|
|
<el-form-item label="申请时间" prop="applyDate">
|
|||
|
|
<el-date-picker clearable
|
|||
|
|
v-model="form.applyDate"
|
|||
|
|
type="date"
|
|||
|
|
value-format="yyyy-MM-dd"
|
|||
|
|
placeholder="请选择申请时间">
|
|||
|
|
</el-date-picker>
|
|||
|
|
</el-form-item>
|
|||
|
|
</el-col>
|
|||
|
|
<el-col :span="24">
|
|||
|
|
<el-form-item label="物料名称:电子面单" prop="applyName">
|
|||
|
|
<el-input v-model="form.applyName" placeholder="请输入物料名称:电子面单" />
|
|||
|
|
</el-form-item>
|
|||
|
|
</el-col>
|
|||
|
|
<el-col :span="24">
|
|||
|
|
<el-form-item label="审核时间" prop="auditDate">
|
|||
|
|
<el-date-picker clearable
|
|||
|
|
v-model="form.auditDate"
|
|||
|
|
type="date"
|
|||
|
|
value-format="yyyy-MM-dd"
|
|||
|
|
placeholder="请选择审核时间">
|
|||
|
|
</el-date-picker>
|
|||
|
|
</el-form-item>
|
|||
|
|
</el-col>
|
|||
|
|
<el-col :span="24">
|
|||
|
|
<el-form-item label="审核状态" prop="auditStatus">
|
|||
|
|
<el-input v-model="form.auditStatus" placeholder="请输入审核状态" />
|
|||
|
|
</el-form-item>
|
|||
|
|
</el-col>
|
|||
|
|
<el-col :span="24">
|
|||
|
|
<el-form-item label="审核原因" prop="auditReson">
|
|||
|
|
<el-input v-model="form.auditReson" placeholder="请输入审核原因" />
|
|||
|
|
</el-form-item>
|
|||
|
|
</el-col>
|
|||
|
|
<el-col :span="24">
|
|||
|
|
<el-form-item label="审核人编号" prop="auditBy">
|
|||
|
|
<el-input v-model="form.auditBy" placeholder="请输入审核人编号" />
|
|||
|
|
</el-form-item>
|
|||
|
|
</el-col>
|
|||
|
|
<el-col :span="24">
|
|||
|
|
<el-form-item label="审核验证码" prop="msgCode">
|
|||
|
|
<el-input v-model="form.msgCode" placeholder="请输入审核验证码" />
|
|||
|
|
</el-form-item>
|
|||
|
|
</el-col>
|
|||
|
|
<el-col :span="24">
|
|||
|
|
<el-form-item label="备注" prop="remark">
|
|||
|
|
<el-input v-model="form.remark" placeholder="请输入备注" />
|
|||
|
|
</el-form-item>
|
|||
|
|
</el-col>
|
|||
|
|
<el-col :span="24">
|
|||
|
|
<el-form-item label="删除标志(0代表存在" prop="delFlag">
|
|||
|
|
<el-input v-model="form.delFlag" placeholder="请输入删除标志(0代表存在" />
|
|||
|
|
</el-form-item>
|
|||
|
|
</el-col>
|
|||
|
|
|
|||
|
|
<!--
|
|||
|
|
<el-form-item label="上级字典">
|
|||
|
|
<treeselect
|
|||
|
|
ref="tree"
|
|||
|
|
v-model="form.parentId"
|
|||
|
|
:options="emisMonthpayUseApplyOptions"
|
|||
|
|
:normalizer="normalizer"
|
|||
|
|
:default-expand-level="1"
|
|||
|
|
:show-count="true"
|
|||
|
|
placeholder="选择上级"
|
|||
|
|
/>
|
|||
|
|
</el-form-item>
|
|||
|
|
-->
|
|||
|
|
|
|||
|
|
|
|||
|
|
</el-form>
|
|||
|
|
</el-row>
|
|||
|
|
<div style="text-align: center;margin-bottom: 10px;">
|
|||
|
|
<el-button type="primary" @click="submitForm">确 定</el-button>
|
|||
|
|
<el-button @click="cancel">取 消</el-button>
|
|||
|
|
</div>
|
|||
|
|
|
|||
|
|
</div>
|
|||
|
|
</template>
|
|||
|
|
|
|||
|
|
<script>
|
|||
|
|
import { listEmisMonthpayUseApply, getEmisMonthpayUseApply, delEmisMonthpayUseApply, addEmisMonthpayUseApply, updateEmisMonthpayUseApply } from "@/api/emis/emisMonthpayUseApply";
|
|||
|
|
|
|||
|
|
export default {
|
|||
|
|
name: "emisMonthpayUseApplyForm",
|
|||
|
|
props:{
|
|||
|
|
id:{
|
|||
|
|
type:Number
|
|||
|
|
}
|
|||
|
|
},
|
|||
|
|
components: { },
|
|||
|
|
dicts: [
|
|||
|
|
],
|
|||
|
|
data() {
|
|||
|
|
return {
|
|||
|
|
emisMonthpayUseApplyOptions: [],
|
|||
|
|
// 遮罩层
|
|||
|
|
loading: true,
|
|||
|
|
// 表单参数
|
|||
|
|
form: {},
|
|||
|
|
// 表单校验
|
|||
|
|
rules: {
|
|||
|
|
id: [
|
|||
|
|
{ required: true, message: "id不能为空", trigger: "blur" }
|
|||
|
|
],
|
|||
|
|
}
|
|||
|
|
};
|
|||
|
|
},
|
|||
|
|
watch: {
|
|||
|
|
"id": {
|
|||
|
|
handler (newValue, oldValue) {
|
|||
|
|
this.id = newValue;
|
|||
|
|
this.initData();
|
|||
|
|
},
|
|||
|
|
deep: true
|
|||
|
|
}
|
|||
|
|
},
|
|||
|
|
created() {
|
|||
|
|
this.initData();
|
|||
|
|
},
|
|||
|
|
|
|||
|
|
methods: {
|
|||
|
|
initData() {
|
|||
|
|
|
|||
|
|
if(this.id !=null) {
|
|||
|
|
this.loading = true;
|
|||
|
|
getEmisMonthpayUseApply(this.id).then(response => {
|
|||
|
|
this.form = response.data;
|
|||
|
|
this.loading = false;
|
|||
|
|
});
|
|||
|
|
}else{
|
|||
|
|
this.reset();
|
|||
|
|
}
|
|||
|
|
// this.getTreeselect();
|
|||
|
|
},
|
|||
|
|
// 取消按钮
|
|||
|
|
cancel() {
|
|||
|
|
this.reset();
|
|||
|
|
this.$emit("on-cancel");
|
|||
|
|
},
|
|||
|
|
// 表单重置
|
|||
|
|
reset() {
|
|||
|
|
this.form = {
|
|||
|
|
id: null,
|
|||
|
|
custNo: null,
|
|||
|
|
customerCode: null,
|
|||
|
|
applySeq: null,
|
|||
|
|
applyDate: null,
|
|||
|
|
applyName: null,
|
|||
|
|
auditDate: null,
|
|||
|
|
auditStatus: null,
|
|||
|
|
auditReson: null,
|
|||
|
|
auditBy: null,
|
|||
|
|
msgCode: null,
|
|||
|
|
remark: null,
|
|||
|
|
tenantId: null,
|
|||
|
|
delFlag: null,
|
|||
|
|
createBy: null,
|
|||
|
|
createTime: null,
|
|||
|
|
updateBy: null,
|
|||
|
|
updateTime: null,
|
|||
|
|
createSite: null,
|
|||
|
|
updateSite: null
|
|||
|
|
};
|
|||
|
|
this.resetForm("form");
|
|||
|
|
},
|
|||
|
|
/** 提交按钮 */
|
|||
|
|
submitForm() {
|
|||
|
|
this.$refs["form"].validate(valid => {
|
|||
|
|
if (valid) {
|
|||
|
|
if (this.form.id != null) {
|
|||
|
|
updateEmisMonthpayUseApply(this.form).then(response => {
|
|||
|
|
this.$modal.msgSuccess("修改成功");
|
|||
|
|
this.$emit("on-changed");
|
|||
|
|
});
|
|||
|
|
} else {
|
|||
|
|
addEmisMonthpayUseApply(this.form).then(response => {
|
|||
|
|
this.$modal.msgSuccess("修改成功");
|
|||
|
|
this.$emit("on-changed");
|
|||
|
|
});
|
|||
|
|
}
|
|||
|
|
}
|
|||
|
|
});
|
|||
|
|
},
|
|||
|
|
// /** 转换菜单数据结构 */
|
|||
|
|
// normalizer(node) {
|
|||
|
|
// if (node.children && !node.children.length) {
|
|||
|
|
// delete node.children;
|
|||
|
|
// }
|
|||
|
|
// return {
|
|||
|
|
// id: node.id,
|
|||
|
|
// label: node.idName,
|
|||
|
|
// children: node.children
|
|||
|
|
// };
|
|||
|
|
// },
|
|||
|
|
// /** 查询菜单下拉树结构 */
|
|||
|
|
// getTreeselect() {
|
|||
|
|
// const queryParams = {}
|
|||
|
|
// listEmisMonthpayUseApply(queryParams).then(response => {
|
|||
|
|
// this.emisMonthpayUseApplyOptions = [];
|
|||
|
|
// const rootItem = { idId: 0, emisMonthpayUseApplyName: '-', children: [] };
|
|||
|
|
// rootItem.children = this.handleTree(response.data, "id");
|
|||
|
|
// this.emisMonthpayUseApplyOptions.push(rootItem);
|
|||
|
|
|
|||
|
|
// if(this.parentId != undefined) {
|
|||
|
|
// this.form.parentId = this.parentId;
|
|||
|
|
// }
|
|||
|
|
|
|||
|
|
// });
|
|||
|
|
// },
|
|||
|
|
}
|
|||
|
|
};
|
|||
|
|
</script>
|