wms部分页面代码

master
mengjiao 2 years ago
parent f946b6b825
commit 08ab0e2dc6

@ -0,0 +1,44 @@
import request from '@/utils/request'
// 查询生产报工列表
export function listBg(query) {
return request({
url: '/mes/bg/list',
method: 'get',
params: query
});
}
// 查询生产报工详细
export function getBg(ID) {
return request({
url: '/mes/bg/' + ID,
method: 'get'
});
}
// 新增生产报工
export function addBg(data) {
return request({
url: '/mes/bg',
method: 'post',
data: data
});
}
// 修改生产报工
export function updateBg(data) {
return request({
url: '/mes/bg',
method: 'put',
data: data
});
}
// 删除生产报工
export function delBg(ID) {
return request({
url: '/mes/bg/' + ID,
method: 'delete'
});
}

@ -0,0 +1,44 @@
import request from '@/utils/request'
// 查询车间/产线管理列表
export function listCopy1(query) {
return request({
url: '/mes/copy1/list',
method: 'get',
params: query
});
}
// 查询车间/产线管理详细
export function getCopy1(id) {
return request({
url: '/mes/copy1/' + id,
method: 'get'
});
}
// 新增车间/产线管理
export function addCopy1(data) {
return request({
url: '/mes/copy1',
method: 'post',
data: data
});
}
// 修改车间/产线管理
export function updateCopy1(data) {
return request({
url: '/mes/copy1',
method: 'put',
data: data
});
}
// 删除车间/产线管理
export function delCopy1(id) {
return request({
url: '/mes/copy1/' + id,
method: 'delete'
});
}

@ -0,0 +1,44 @@
import request from '@/utils/request'
// 查询粉料采购计划列表
export function listOrder(query) {
return request({
url: '/mes/order/list',
method: 'get',
params: query
});
}
// 查询粉料采购计划详细
export function getOrder(ID) {
return request({
url: '/mes/order/' + ID,
method: 'get'
});
}
// 新增粉料采购计划
export function addOrder(data) {
return request({
url: '/mes/order',
method: 'post',
data: data
});
}
// 修改粉料采购计划
export function updateOrder(data) {
return request({
url: '/mes/order',
method: 'put',
data: data
});
}
// 删除粉料采购计划
export function delOrder(ID) {
return request({
url: '/mes/order/' + ID,
method: 'delete'
});
}

@ -0,0 +1,44 @@
import request from '@/utils/request'
// 查询白胚盘点单列表
export function listInventory(query) {
return request({
url: '/wms/Inventory/list',
method: 'get',
params: query
});
}
// 查询白胚盘点单详细
export function getInventory(ID) {
return request({
url: '/wms/Inventory/' + ID,
method: 'get'
});
}
// 新增白胚盘点单
export function addInventory(data) {
return request({
url: '/wms/Inventory',
method: 'post',
data: data
});
}
// 修改白胚盘点单
export function updateInventory(data) {
return request({
url: '/wms/Inventory',
method: 'put',
data: data
});
}
// 删除白胚盘点单
export function delInventory(ID) {
return request({
url: '/wms/Inventory/' + ID,
method: 'delete'
});
}

@ -0,0 +1,44 @@
import request from '@/utils/request'
// 查询包材盘点单列表
export function listInventoryorder(query) {
return request({
url: '/wms/Inventoryorder/list',
method: 'get',
params: query
});
}
// 查询包材盘点单详细
export function getInventoryorder(ID) {
return request({
url: '/wms/Inventoryorder/' + ID,
method: 'get'
});
}
// 新增包材盘点单
export function addInventoryorder(data) {
return request({
url: '/wms/Inventoryorder',
method: 'post',
data: data
});
}
// 修改包材盘点单
export function updateInventoryorder(data) {
return request({
url: '/wms/Inventoryorder',
method: 'put',
data: data
});
}
// 删除包材盘点单
export function delInventoryorder(ID) {
return request({
url: '/wms/Inventoryorder/' + ID,
method: 'delete'
});
}

@ -0,0 +1,44 @@
import request from '@/utils/request'
// 查询粉料配料列表
export function listChargeorder(query) {
return request({
url: '/wms/chargeorder/list',
method: 'get',
params: query
});
}
// 查询粉料配料详细
export function getChargeorder(ID) {
return request({
url: '/wms/chargeorder/' + ID,
method: 'get'
});
}
// 新增粉料配料
export function addChargeorder(data) {
return request({
url: '/wms/chargeorder',
method: 'post',
data: data
});
}
// 修改粉料配料
export function updateChargeorder(data) {
return request({
url: '/wms/chargeorder',
method: 'put',
data: data
});
}
// 删除粉料配料
export function delChargeorder(ID) {
return request({
url: '/wms/chargeorder/' + ID,
method: 'delete'
});
}

@ -0,0 +1,44 @@
import request from '@/utils/request'
// 查询白胚出库单列表
export function listEmbryo(query) {
return request({
url: '/wms/embryo/list',
method: 'get',
params: query
});
}
// 查询白胚出库单详细
export function getEmbryo(ID) {
return request({
url: '/wms/embryo/' + ID,
method: 'get'
});
}
// 新增白胚出库单
export function addEmbryo(data) {
return request({
url: '/wms/embryo',
method: 'post',
data: data
});
}
// 修改白胚出库单
export function updateEmbryo(data) {
return request({
url: '/wms/embryo',
method: 'put',
data: data
});
}
// 删除白胚出库单
export function delEmbryo(ID) {
return request({
url: '/wms/embryo/' + ID,
method: 'delete'
});
}

@ -0,0 +1,44 @@
import request from '@/utils/request'
// 查询包材采购单列表
export function listOrder(query) {
return request({
url: '/wms/order/list',
method: 'get',
params: query
});
}
// 查询包材采购单详细
export function getOrder(ID) {
return request({
url: '/wms/order/' + ID,
method: 'get'
});
}
// 新增包材采购单
export function addOrder(data) {
return request({
url: '/wms/order',
method: 'post',
data: data
});
}
// 修改包材采购单
export function updateOrder(data) {
return request({
url: '/wms/order',
method: 'put',
data: data
});
}
// 删除包材采购单
export function delOrder(ID) {
return request({
url: '/wms/order/' + ID,
method: 'delete'
});
}

@ -0,0 +1,44 @@
import request from '@/utils/request'
// 查询包材出库单列表
export function listOutorder(query) {
return request({
url: '/wms/outorder/list',
method: 'get',
params: query
});
}
// 查询包材出库单详细
export function getOutorder(ID) {
return request({
url: '/wms/outorder/' + ID,
method: 'get'
});
}
// 新增包材出库单
export function addOutorder(data) {
return request({
url: '/wms/outorder',
method: 'post',
data: data
});
}
// 修改包材出库单
export function updateOutorder(data) {
return request({
url: '/wms/outorder',
method: 'put',
data: data
});
}
// 删除包材出库单
export function delOutorder(ID) {
return request({
url: '/wms/outorder/' + ID,
method: 'delete'
});
}

@ -0,0 +1,62 @@
import request from '@/utils/request'
// 查询粉料采购计划列表
export function listPowderOrder(query) {
return request({
url: '/wms/powderOrder/list',
method: 'get',
params: query
});
}
// 查询粉料采购计划详细
export function getPowderOrder(ID) {
return request({
url: '/wms/powderOrder/' + ID,
method: 'get'
});
}
// 新增粉料采购计划
export function addPowderOrder(data) {
return request({
url: '/wms/powderOrder',
method: 'post',
data: data
});
}
// 修改粉料采购计划
export function updatePowderOrder(data) {
return request({
url: '/wms/powderOrder',
method: 'put',
data: data
});
}
// 删除粉料采购计划
export function delPowderOrder(ID) {
return request({
url: '/wms/powderOrder/' + ID,
method: 'delete'
});
}
// 确认收货
export function confirmReceipt(data) {
return request({
url: '/wms/powderOrder/confirmReceipt',
method: 'post',
data: data
});
}
// 确认收货
export function powderReturn(data) {
return request({
url: '/wms/powderOrder/powderReturn',
method: 'post',
data: data
});
}

@ -0,0 +1,381 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<!-- <el-form-item label="主键" prop="ID">-->
<!-- <el-input-->
<!-- v-model="queryParams.ID"-->
<!-- placeholder="请输入主键"-->
<!-- clearable-->
<!-- @keyup.enter.native="handleQuery"-->
<!-- />-->
<!-- </el-form-item>-->
<el-form-item label="报工类型" prop="siteCode">
<el-input
v-model="queryParams.siteCode"
placeholder="请输入报工类型"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="工位" prop="OrderID">
<el-input
v-model="queryParams.OrderID"
placeholder="请输入工位"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="产品编码" prop="Code">
<el-input
v-model="queryParams.Code"
placeholder="请输入产品编码"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="工单编码" prop="CSA">
<el-input
v-model="queryParams.CSA"
placeholder="请输入工单编码"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="产品名称" prop="COS">
<el-input
v-model="queryParams.COS"
placeholder="请输入产品名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="规格型号" prop="Name">
<el-input
v-model="queryParams.Name"
placeholder="请输入规格型号"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="报工数量" prop="prodId">
<el-input
v-model="queryParams.prodId"
placeholder="请输入报工数量"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="报工人" prop="prodCode">
<el-input
v-model="queryParams.prodCode"
placeholder="请输入报工人"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="报工时间" prop="barcodeClearDate">
<el-date-picker clearable
v-model="queryParams.barcodeClearDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择报工时间">
</el-date-picker>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"></el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button>
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['mes:bg:add']"
>新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['mes:bg:edit']"
>修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['mes:bg:remove']"
>删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['mes:bg:export']"
>导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="bgList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<!-- <el-table-column label="主键" align="center" prop="ID" />-->
<el-table-column label="报工类型" align="center" prop="siteCode" />
<el-table-column label="工位" align="center" prop="OrderID" />
<el-table-column label="产品编码" align="center" prop="Code" />
<el-table-column label="工单编码" align="center" prop="CSA" />
<el-table-column label="产品名称" align="center" prop="COS" />
<el-table-column label="规格型号" align="center" prop="Name" />
<el-table-column label="报工数量" align="center" prop="prodId" />
<el-table-column label="报工人" align="center" prop="prodCode" />
<el-table-column label="报工时间" align="center" prop="barcodeClearDate" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.barcodeClearDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['mes:bg:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['mes:bg:remove']"
>删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 添加或修改生产报工对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
<!-- <el-form-item label="主键" prop="ID">-->
<!-- <el-input v-model="form.ID" placeholder="请输入主键" />-->
<!-- </el-form-item>-->
<el-form-item label="报工类型" prop="siteCode">
<el-input v-model="form.siteCode" placeholder="请输入报工类型" />
</el-form-item>
<el-form-item label="工位" prop="OrderID">
<el-input v-model="form.OrderID" placeholder="请输入工位" />
</el-form-item>
<el-form-item label="产品编码" prop="Code">
<el-input v-model="form.Code" placeholder="请输入产品编码" />
</el-form-item>
<el-form-item label="工单编码" prop="CSA">
<el-input v-model="form.CSA" placeholder="请输入工单编码" />
</el-form-item>
<el-form-item label="产品名称" prop="COS">
<el-input v-model="form.COS" placeholder="请输入产品名称" />
</el-form-item>
<el-form-item label="规格型号" prop="Name">
<el-input v-model="form.Name" placeholder="请输入规格型号" />
</el-form-item>
<el-form-item label="报工数量" prop="prodId">
<el-input v-model="form.prodId" placeholder="请输入报工数量" />
</el-form-item>
<el-form-item label="报工人" prop="prodCode">
<el-input v-model="form.prodCode" placeholder="请输入报工人" />
</el-form-item>
<el-form-item label="报工时间" prop="barcodeClearDate">
<el-date-picker clearable
v-model="form.barcodeClearDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择报工时间">
</el-date-picker>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button>
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listBg, getBg, delBg, addBg, updateBg } from "@/api/mes/bg";
export default {
name: "Bg",
data() {
return {
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
bgList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
ID: null,
siteCode: null,
OrderID: null,
Code: null,
CSA: null,
COS: null,
Name: null,
prodId: null,
prodCode: null,
barcodeClearDate: null
},
//
form: {},
//
rules: {
ID: [
{ required: true, message: "主键不能为空", trigger: "blur" }
],
}
};
},
created() {
this.getList();
},
methods: {
/** 查询生产报工列表 */
getList() {
this.loading = true;
listBg(this.queryParams).then(response => {
this.bgList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
ID: null,
siteCode: null,
OrderID: null,
Code: null,
CSA: null,
COS: null,
Name: null,
prodId: null,
prodCode: null,
barcodeClearDate: null
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.ID)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加生产报工";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();
const ID = row.ID || this.ids
getBg(ID).then(response => {
this.form = response.data;
this.open = true;
this.title = "修改生产报工";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
if (this.form.ID != null) {
updateBg(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
});
} else {
addBg(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const IDs = row.ID || this.ids;
this.$modal.confirm('是否确认删除生产报工编号为"' + IDs + '"的数据项?').then(function() {
return delBg(IDs);
}).then(() => {
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {});
},
/** 导出按钮操作 */
handleExport() {
this.download('mes/bg/export', {
...this.queryParams
}, `bg_${new Date().getTime()}.xlsx`)
}
}
};
</script>

@ -0,0 +1,305 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="部门名称" prop="baofeiCode">
<el-input
v-model="queryParams.baofeiCode"
placeholder="请输入部门名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="排序" prop="baofeiDesc">
<el-input
v-model="queryParams.baofeiDesc"
placeholder="请输入排序"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="状态" prop="chejian">
<el-input
v-model="queryParams.chejian"
placeholder="请输入状态"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="创建时间" prop="createTime">
<el-input
v-model="queryParams.createTime"
placeholder="请输入创建时间"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<!-- <el-form-item label="操作" prop="reason">-->
<!-- <el-input-->
<!-- v-model="queryParams.reason"-->
<!-- placeholder="请输入操作"-->
<!-- clearable-->
<!-- @keyup.enter.native="handleQuery"-->
<!-- />-->
<!-- </el-form-item>-->
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"></el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button>
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['mes:copy1:add']"
>新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['mes:copy1:edit']"
>修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['mes:copy1:remove']"
>删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['mes:copy1:export']"
>导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="copy1List" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<!-- <el-table-column label="${comment}" align="center" prop="id" />-->
<el-table-column label="部门名称" align="center" prop="baofeiCode" />
<el-table-column label="排序" align="center" prop="baofeiDesc" />
<el-table-column label="状态" align="center" prop="chejian" />
<el-table-column label="创建时间" align="center" prop="createTime" />
<!-- <el-table-column label="操作" align="center" prop="reason" />-->
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['mes:copy1:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['mes:copy1:remove']"
>删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 添加或修改车间/产线管理对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-form-item label="部门名称" prop="baofeiCode">
<el-input v-model="form.baofeiCode" placeholder="请输入部门名称" />
</el-form-item>
<el-form-item label="排序" prop="baofeiDesc">
<el-input v-model="form.baofeiDesc" placeholder="请输入排序" />
</el-form-item>
<el-form-item label="状态" prop="chejian">
<el-input v-model="form.chejian" placeholder="请输入状态" />
</el-form-item>
<el-form-item label="创建时间" prop="createTime">
<el-input v-model="form.createTime" placeholder="请输入创建时间" />
</el-form-item>
<!-- <el-form-item label="操作" prop="reason">-->
<!-- <el-input v-model="form.reason" placeholder="请输入操作" />-->
<!-- </el-form-item>-->
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button>
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listCopy1, getCopy1, delCopy1, addCopy1, updateCopy1 } from "@/api/mes/copy1";
export default {
name: "Copy1",
data() {
return {
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
// /线
copy1List: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
baofeiCode: null,
baofeiDesc: null,
chejian: null,
createTime: null,
reason: null,
},
//
form: {},
//
rules: {
baofeiCode: [
{ required: true, message: "部门名称不能为空", trigger: "blur" }
],
}
};
},
created() {
this.getList();
},
methods: {
/** 查询车间/产线管理列表 */
getList() {
this.loading = true;
listCopy1(this.queryParams).then(response => {
this.copy1List = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: null,
baofeiCode: null,
baofeiDesc: null,
chejian: null,
xianti: null,
reason: null,
createTime: null
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加车间/产线管理";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();
const id = row.id || this.ids
getCopy1(id).then(response => {
this.form = response.data;
this.open = true;
this.title = "修改车间/产线管理";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
if (this.form.id != null) {
updateCopy1(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
});
} else {
addCopy1(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除车间/产线管理编号为"' + ids + '"的数据项?').then(function() {
return delCopy1(ids);
}).then(() => {
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {});
},
/** 导出按钮操作 */
handleExport() {
this.download('mes/copy1/export', {
...this.queryParams
}, `copy1_${new Date().getTime()}.xlsx`)
}
}
};
</script>

@ -0,0 +1,401 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="采购单号" prop="orderCode">
<el-input
v-model="queryParams.orderCode"
placeholder="请输入采购单号"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="物料编码" prop="materialCode">
<el-input
v-model="queryParams.materialCode"
placeholder="请输入物料编码"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="物料描述" prop="materialDesc">
<el-input
v-model="queryParams.materialDesc"
placeholder="请输入物料描述"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="计划日期" prop="planDate">
<el-date-picker clearable
v-model="queryParams.planDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择计划日期">
</el-date-picker>
</el-form-item>
<el-form-item label="供应商编码" prop="supplierCode">
<el-input
v-model="queryParams.supplierCode"
placeholder="请输入供应商编码"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<!-- <el-form-item label="供应商名称" prop="supplierName">-->
<!-- <el-input-->
<!-- v-model="queryParams.supplierName"-->
<!-- placeholder="请输入供应商名称"-->
<!-- clearable-->
<!-- @keyup.enter.native="handleQuery"-->
<!-- />-->
<!-- </el-form-item>-->
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"></el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button>
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['mes:order:add']"
>新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['mes:order:edit']"
>修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['mes:order:remove']"
>删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['mes:order:export']"
>导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="orderList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="工厂编码" align="center" prop="siteCode" v-if="false" />
<el-table-column label="id" align="center" prop="id" v-if="false" />
<el-table-column label="采购单号" align="center" prop="orderCode" />
<el-table-column label="物料编码" align="center" prop="materialCode" />
<el-table-column label="物料描述" align="center" prop="materialDesc" />
<el-table-column label="计划日期" align="center" prop="planDate" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.planDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="计划数量" align="center" prop="planNumber" />
<el-table-column label="单位" align="center" prop="unit" />
<el-table-column label="订单状态" align="center" prop="orderStatus" />
<el-table-column label="供应商编码" align="center" prop="supplierCode" />
<el-table-column label="供应商名称" align="center" prop="supplierName" />
<el-table-column label="创建人" align="center" prop="createBy" />
<el-table-column label="创建时间" align="center" prop="createDate" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.createDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['mes:order:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['mes:order:remove']"
>删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 添加或修改粉料采购计划对话框 -->
<el-dialog :title="title" :visible.sync="open" width="700px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-form-item label="物料编码" prop="materialCode">
<el-input v-model="form.materialCode" placeholder="请输入物料编码" />
</el-form-item>
<el-form-item label="物料描述" prop="materialDesc">
<el-input v-model="form.materialDesc" placeholder="请输入物料描述" />
</el-form-item>
<el-form-item label="计划日期" prop="planDate">
<el-date-picker clearable
v-model="form.planDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择计划日期">
</el-date-picker>
</el-form-item>
<el-form-item label="计划数量" prop="planNumber">
<el-input v-model="form.planNumber" placeholder="请输入计划数量" />
</el-form-item>
<el-form-item label="单位" prop="unit">
<el-input v-model="form.unit" placeholder="请输入单位" />
</el-form-item>
<el-form-item label="供应商编码" prop="supplierCode">
<el-input v-model="form.supplierCode" placeholder="请输入供应商编码" />
</el-form-item>
<el-form-item label="供应商名称" prop="supplierName">
<el-input v-model="form.supplierName" placeholder="请输入供应商名称" />
</el-form-item>
<el-form-item label="备注" prop="remark">
<el-input v-model="form.remark" placeholder="请输入备注" />
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button>
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listOrder, getOrder, delOrder, addOrder, updateOrder } from "@/api/mes/order";
export default {
name: "Order",
data() {
return {
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
orderList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
siteCode: null,
orderCode: null,
materialCode: null,
materialDesc: null,
planDate: null,
planNumber: null,
unit: null,
realityNumber: null,
orderStatus: null,
userDefined1: null,
userDefined2: null,
userDefined3: null,
userDefined4: null,
userDefined5: null,
userDefined6: null,
userDefined7: null,
userDefined8: null,
userDefined9: null,
userDefined10: null,
userDefined11: null,
supplierCode: null,
supplierName: null,
remark: null,
createBy: null,
createDate: null,
lastUpdateBy: null,
lastUpdateDate: null,
Active: null,
enterpriseId: null,
enterpriseCode: null,
lssuedNumber: null
},
//
form: {},
//
rules: {
}
};
},
created() {
this.getList();
},
methods: {
/** 查询粉料采购计划列表 */
getList() {
this.loading = true;
listOrder(this.queryParams).then(response => {
this.orderList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
siteCode: null,
id: null,
orderCode: null,
materialCode: null,
materialDesc: null,
planDate: null,
planNumber: null,
unit: null,
realityNumber: null,
orderStatus: null,
userDefined1: null,
userDefined2: null,
userDefined3: null,
userDefined4: null,
userDefined5: null,
userDefined6: null,
userDefined7: null,
userDefined8: null,
userDefined9: null,
userDefined10: null,
userDefined11: null,
supplierCode: null,
supplierName: null,
remark: null,
createBy: null,
createDate: null,
lastUpdateBy: null,
lastUpdateDate: null,
Active: null,
enterpriseId: null,
enterpriseCode: null,
lssuedNumber: null
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "新增";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();
const ID = row.ID || this.ids
getOrder(ID).then(response => {
this.form = response.data;
this.open = true;
this.title = "修改粉料采购计划";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
if (this.form.id != null) {
updateOrder(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
});
} else {
addOrder(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const IDs = row.id || this.ids;
this.$modal.confirm('是否确认删除粉料采购计划编号为"' + IDs + '"的数据项?').then(function() {
return delOrder(IDs);
}).then(() => {
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {});
},
/** 导出按钮操作 */
handleExport() {
this.download('mes/order/export', {
...this.queryParams
}, `order_${new Date().getTime()}.xlsx`)
}
}
};
</script>

@ -0,0 +1,449 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="盘点单号" prop="orderCode">
<el-input
v-model="queryParams.orderCode"
placeholder="请输入盘点单号"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="型号编码" prop="materialCode">
<el-input
v-model="queryParams.materialCode"
placeholder="请输入型号编码"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="型号名称" prop="materialDesc">
<el-input
v-model="queryParams.materialDesc"
placeholder="请输入型号名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="库位" prop="locCode">
<el-input
v-model="queryParams.locCode"
placeholder="请输入库位"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"></el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button>
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['wms:Inventory:add']"
>新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['wms:Inventory:edit']"
>修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['wms:Inventory:remove']"
>删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['wms:Inventory:export']"
>导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="InventoryList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="序号" type="index" :index='indexMethod'> </el-table-column>
<el-table-column label="工厂编码" align="center" prop="siteCode" v-if="false" />
<el-table-column label="ID" align="center" prop="ID" v-if="false" />
<el-table-column label="盘点单号" align="center" prop="orderCode" />
<el-table-column label="型号编码" align="center" prop="materialCode" />
<el-table-column label="型号名称" align="center" prop="materialDesc" />
<el-table-column label="计划日期" align="center" prop="planDate" width="180" v-if="false" >
<template slot-scope="scope">
<span>{{ parseTime(scope.row.planDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="库存数量" align="center" prop="locNumber" />
<el-table-column label="实际数量" align="center" prop="realityNumber" />
<el-table-column label="库位" align="center" prop="locCode" />
<el-table-column label="订单状态" align="center" prop="orderStatus" />
<el-table-column label="备注" align="center" prop="Remark" />
<el-table-column label="创建人" align="center" prop="createBy" />
<el-table-column label="创建时间" align="center" prop="createDate" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.createDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['wms:Inventory:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['wms:Inventory:remove']"
>删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 添加或修改白胚盘点单对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-form-item label="工厂编码" prop="siteCode">
<el-input v-model="form.siteCode" placeholder="请输入工厂编码" />
</el-form-item>
<el-form-item label="盘点单号" prop="orderCode">
<el-input v-model="form.orderCode" placeholder="请输入盘点单号" />
</el-form-item>
<el-form-item label="型号编码" prop="materialCode">
<el-input v-model="form.materialCode" placeholder="请输入型号编码" />
</el-form-item>
<el-form-item label="型号名称" prop="materialDesc">
<el-input v-model="form.materialDesc" placeholder="请输入型号名称" />
</el-form-item>
<el-form-item label="计划日期" prop="planDate">
<el-date-picker clearable
v-model="form.planDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择计划日期">
</el-date-picker>
</el-form-item>
<el-form-item label="库存数量" prop="locNumber">
<el-input v-model="form.locNumber" placeholder="请输入库存数量" />
</el-form-item>
<el-form-item label="单位" prop="Unit">
<el-input v-model="form.Unit" placeholder="请输入单位" />
</el-form-item>
<el-form-item label="实际数量" prop="realityNumber">
<el-input v-model="form.realityNumber" placeholder="请输入实际数量" />
</el-form-item>
<el-form-item label="用户自定义属性2" prop="userDefined1">
<el-input v-model="form.userDefined1" placeholder="请输入用户自定义属性2" />
</el-form-item>
<el-form-item label="库位" prop="locCode">
<el-input v-model="form.locCode" placeholder="请输入库位" />
</el-form-item>
<el-form-item label="用户自定义属性2" prop="userDefined2">
<el-input v-model="form.userDefined2" placeholder="请输入用户自定义属性2" />
</el-form-item>
<el-form-item label="用户自定义属性3" prop="userDefined3">
<el-input v-model="form.userDefined3" placeholder="请输入用户自定义属性3" />
</el-form-item>
<el-form-item label="用户自定义属性4" prop="userDefined4">
<el-input v-model="form.userDefined4" placeholder="请输入用户自定义属性4" />
</el-form-item>
<el-form-item label="用户自定义属性5" prop="userDefined5">
<el-input v-model="form.userDefined5" placeholder="请输入用户自定义属性5" />
</el-form-item>
<el-form-item label="用户自定义属性6" prop="userDefined6">
<el-input v-model="form.userDefined6" placeholder="请输入用户自定义属性6" />
</el-form-item>
<el-form-item label="用户自定义属性7" prop="userDefined7">
<el-input v-model="form.userDefined7" placeholder="请输入用户自定义属性7" />
</el-form-item>
<el-form-item label="用户自定义属性8" prop="userDefined8">
<el-input v-model="form.userDefined8" placeholder="请输入用户自定义属性8" />
</el-form-item>
<el-form-item label="用户自定义属性9" prop="userDefined9">
<el-input v-model="form.userDefined9" placeholder="请输入用户自定义属性9" />
</el-form-item>
<el-form-item label="用户自定义属性10" prop="userDefined10">
<el-input v-model="form.userDefined10" placeholder="请输入用户自定义属性10" />
</el-form-item>
<el-form-item label="用户自定义属性11" prop="userDefined11">
<el-input v-model="form.userDefined11" placeholder="请输入用户自定义属性11" />
</el-form-item>
<el-form-item label="备注" prop="Remark">
<el-input v-model="form.Remark" placeholder="请输入备注" />
</el-form-item>
<el-form-item label="创建时间" prop="createDate">
<el-date-picker clearable
v-model="form.createDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择创建时间">
</el-date-picker>
</el-form-item>
<el-form-item label="最后更新人" prop="lastUpdateBy">
<el-input v-model="form.lastUpdateBy" placeholder="请输入最后更新人" />
</el-form-item>
<el-form-item label="最后更新时间" prop="lastUpdateDate">
<el-date-picker clearable
v-model="form.lastUpdateDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择最后更新时间">
</el-date-picker>
</el-form-item>
<el-form-item label="可用标识" prop="Active">
<el-input v-model="form.Active" placeholder="请输入可用标识" />
</el-form-item>
<el-form-item label="企业主键" prop="enterpriseId">
<el-input v-model="form.enterpriseId" placeholder="请输入企业主键" />
</el-form-item>
<el-form-item label="企业编码" prop="enterpriseCode">
<el-input v-model="form.enterpriseCode" placeholder="请输入企业编码" />
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button>
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listInventory, getInventory, delInventory, addInventory, updateInventory } from "@/api/wms/Inventory";
export default {
name: "Inventory",
data() {
return {
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
InventoryList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
siteCode: null,
orderCode: null,
materialCode: null,
materialDesc: null,
planDate: null,
locNumber: null,
Unit: null,
realityNumber: null,
orderStatus: null,
userDefined1: null,
locCode: null,
userDefined2: null,
userDefined3: null,
userDefined4: null,
userDefined5: null,
userDefined6: null,
userDefined7: null,
userDefined8: null,
userDefined9: null,
userDefined10: null,
userDefined11: null,
Remark: null,
createBy: null,
createDate: null,
lastUpdateBy: null,
lastUpdateDate: null,
Active: null,
enterpriseId: null,
enterpriseCode: null
},
//
form: {},
//
rules: {
}
};
},
created() {
this.getList();
},
methods: {
/** 查询白胚盘点单列表 */
getList() {
this.loading = true;
listInventory(this.queryParams).then(response => {
this.InventoryList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
siteCode: null,
ID: null,
orderCode: null,
materialCode: null,
materialDesc: null,
planDate: null,
locNumber: null,
Unit: null,
realityNumber: null,
orderStatus: null,
userDefined1: null,
locCode: null,
userDefined2: null,
userDefined3: null,
userDefined4: null,
userDefined5: null,
userDefined6: null,
userDefined7: null,
userDefined8: null,
userDefined9: null,
userDefined10: null,
userDefined11: null,
Remark: null,
createBy: null,
createDate: null,
lastUpdateBy: null,
lastUpdateDate: null,
Active: null,
enterpriseId: null,
enterpriseCode: null
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.ID)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加白胚盘点单";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();
const ID = row.ID || this.ids
getInventory(ID).then(response => {
this.form = response.data;
this.open = true;
this.title = "修改白胚盘点单";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
if (this.form.ID != null) {
updateInventory(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
});
} else {
addInventory(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const IDs = row.ID || this.ids;
this.$modal.confirm('是否确认删除白胚盘点单编号为"' + IDs + '"的数据项?').then(function() {
return delInventory(IDs);
}).then(() => {
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {});
},
/** 导出按钮操作 */
handleExport() {
this.download('wms/Inventory/export', {
...this.queryParams
}, `Inventory_${new Date().getTime()}.xlsx`)
}
}
};
</script>

@ -0,0 +1,436 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="盘点单号" prop="orderInventCode">
<el-input
v-model="queryParams.orderInventCode"
placeholder="请输入盘点单号"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="型号编码" prop="materialCode">
<el-input
v-model="queryParams.materialCode"
placeholder="请输入型号编码"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="型号名称" prop="materialDesc">
<el-input
v-model="queryParams.materialDesc"
placeholder="请输入型号名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="库位" prop="locCode">
<el-input
v-model="queryParams.locCode"
placeholder="请输入库位"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"></el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button>
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['wms:Inventoryorder:add']"
>新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['wms:Inventoryorder:edit']"
>修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['wms:Inventoryorder:remove']"
>删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['wms:Inventoryorder:export']"
>导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="InventoryorderList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="序号" type="index" :index='indexMethod'> </el-table-column>
<el-table-column label="工厂编码" align="center" prop="siteCode" v-if="false" />
<el-table-column label="ID" align="center" prop="ID" v-if="false" />
<el-table-column label="盘点单号" align="center" prop="orderInventCode" />
<el-table-column label="型号编码" align="center" prop="materialCode" />
<el-table-column label="型号名称" align="center" prop="materialDesc" />
<el-table-column label="计划日期" align="center" prop="planDate" width="180" v-if="false" >
<template slot-scope="scope">
<span>{{ parseTime(scope.row.planDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="库存数量" align="center" prop="locNumber" />
<el-table-column label="实际数量" align="center" prop="realityNumber" />
<el-table-column label="库位" align="center" prop="locCode" />
<el-table-column label="订单状态" align="center" prop="orderStatus" />
<el-table-column label="创建人" align="center" prop="createBy" />
<el-table-column label="创建时间" align="center" prop="createDate" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.createDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['wms:Inventoryorder:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['wms:Inventoryorder:remove']"
>删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 添加或修改包材盘点单对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-form-item label="工厂编码" prop="siteCode">
<el-input v-model="form.siteCode" placeholder="请输入工厂编码" />
</el-form-item>
<el-form-item label="盘点单号" prop="orderInventCode">
<el-input v-model="form.orderInventCode" placeholder="请输入盘点单号" />
</el-form-item>
<el-form-item label="型号编码" prop="materialCode">
<el-input v-model="form.materialCode" placeholder="请输入型号编码" />
</el-form-item>
<el-form-item label="型号名称" prop="materialDesc">
<el-input v-model="form.materialDesc" placeholder="请输入型号名称" />
</el-form-item>
<el-form-item label="计划日期" prop="planDate">
<el-date-picker clearable
v-model="form.planDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择计划日期">
</el-date-picker>
</el-form-item>
<el-form-item label="库存数量" prop="locNumber">
<el-input v-model="form.locNumber" placeholder="请输入库存数量" />
</el-form-item>
<el-form-item label="实际数量" prop="realityNumber">
<el-input v-model="form.realityNumber" placeholder="请输入实际数量" />
</el-form-item>
<el-form-item label="用户自定义属性2" prop="userDefined1">
<el-input v-model="form.userDefined1" placeholder="请输入用户自定义属性2" />
</el-form-item>
<el-form-item label="库位" prop="locCode">
<el-input v-model="form.locCode" placeholder="请输入库位" />
</el-form-item>
<el-form-item label="用户自定义属性2" prop="userDefined2">
<el-input v-model="form.userDefined2" placeholder="请输入用户自定义属性2" />
</el-form-item>
<el-form-item label="用户自定义属性3" prop="userDefined3">
<el-input v-model="form.userDefined3" placeholder="请输入用户自定义属性3" />
</el-form-item>
<el-form-item label="用户自定义属性4" prop="userDefined4">
<el-input v-model="form.userDefined4" placeholder="请输入用户自定义属性4" />
</el-form-item>
<el-form-item label="用户自定义属性5" prop="userDefined5">
<el-input v-model="form.userDefined5" placeholder="请输入用户自定义属性5" />
</el-form-item>
<el-form-item label="用户自定义属性6" prop="userDefined6">
<el-input v-model="form.userDefined6" placeholder="请输入用户自定义属性6" />
</el-form-item>
<el-form-item label="用户自定义属性7" prop="userDefined7">
<el-input v-model="form.userDefined7" placeholder="请输入用户自定义属性7" />
</el-form-item>
<el-form-item label="用户自定义属性8" prop="userDefined8">
<el-input v-model="form.userDefined8" placeholder="请输入用户自定义属性8" />
</el-form-item>
<el-form-item label="用户自定义属性9" prop="userDefined9">
<el-input v-model="form.userDefined9" placeholder="请输入用户自定义属性9" />
</el-form-item>
<el-form-item label="用户自定义属性10" prop="userDefined10">
<el-input v-model="form.userDefined10" placeholder="请输入用户自定义属性10" />
</el-form-item>
<el-form-item label="用户自定义属性11" prop="userDefined11">
<el-input v-model="form.userDefined11" placeholder="请输入用户自定义属性11" />
</el-form-item>
<el-form-item label="备注" prop="Remark">
<el-input v-model="form.Remark" placeholder="请输入备注" />
</el-form-item>
<el-form-item label="创建时间" prop="createDate">
<el-date-picker clearable
v-model="form.createDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择创建时间">
</el-date-picker>
</el-form-item>
<el-form-item label="最后更新人" prop="lastUpdateBy">
<el-input v-model="form.lastUpdateBy" placeholder="请输入最后更新人" />
</el-form-item>
<el-form-item label="最后更新时间" prop="lastUpdateDate">
<el-date-picker clearable
v-model="form.lastUpdateDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择最后更新时间">
</el-date-picker>
</el-form-item>
<el-form-item label="可用标识" prop="Active">
<el-input v-model="form.Active" placeholder="请输入可用标识" />
</el-form-item>
<el-form-item label="企业主键" prop="enterpriseId">
<el-input v-model="form.enterpriseId" placeholder="请输入企业主键" />
</el-form-item>
<el-form-item label="企业编码" prop="enterpriseCode">
<el-input v-model="form.enterpriseCode" placeholder="请输入企业编码" />
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button>
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listInventoryorder, getInventoryorder, delInventoryorder, addInventoryorder, updateInventoryorder } from "@/api/wms/Inventoryorder";
export default {
name: "Inventoryorder",
data() {
return {
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
InventoryorderList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
siteCode: null,
orderInventCode: null,
materialCode: null,
materialDesc: null,
planDate: null,
locNumber: null,
realityNumber: null,
orderStatus: null,
userDefined1: null,
locCode: null,
userDefined2: null,
userDefined3: null,
userDefined4: null,
userDefined5: null,
userDefined6: null,
userDefined7: null,
userDefined8: null,
userDefined9: null,
userDefined10: null,
userDefined11: null,
Remark: null,
createBy: null,
createDate: null,
lastUpdateBy: null,
lastUpdateDate: null,
Active: null,
enterpriseId: null,
enterpriseCode: null
},
//
form: {},
//
rules: {
}
};
},
created() {
this.getList();
},
methods: {
/** 查询包材盘点单列表 */
getList() {
this.loading = true;
listInventoryorder(this.queryParams).then(response => {
this.InventoryorderList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
siteCode: null,
ID: null,
orderInventCode: null,
materialCode: null,
materialDesc: null,
planDate: null,
locNumber: null,
realityNumber: null,
orderStatus: null,
userDefined1: null,
locCode: null,
userDefined2: null,
userDefined3: null,
userDefined4: null,
userDefined5: null,
userDefined6: null,
userDefined7: null,
userDefined8: null,
userDefined9: null,
userDefined10: null,
userDefined11: null,
Remark: null,
createBy: null,
createDate: null,
lastUpdateBy: null,
lastUpdateDate: null,
Active: null,
enterpriseId: null,
enterpriseCode: null
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.ID)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加包材盘点单";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();
const ID = row.ID || this.ids
getInventoryorder(ID).then(response => {
this.form = response.data;
this.open = true;
this.title = "修改包材盘点单";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
if (this.form.ID != null) {
updateInventoryorder(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
});
} else {
addInventoryorder(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const IDs = row.ID || this.ids;
this.$modal.confirm('是否确认删除包材盘点单编号为"' + IDs + '"的数据项?').then(function() {
return delInventoryorder(IDs);
}).then(() => {
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {});
},
/** 导出按钮操作 */
handleExport() {
this.download('wms/Inventoryorder/export', {
...this.queryParams
}, `Inventoryorder_${new Date().getTime()}.xlsx`)
}
}
};
</script>

@ -0,0 +1,360 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="配料单号" prop="orderCode">
<el-input
v-model="queryParams.orderCode"
placeholder="请输入配料单号"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="物料编码" prop="materialCode">
<el-input
v-model="queryParams.materialCode"
placeholder="请输入物料编码"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="物料描述" prop="materialDesc">
<el-input
v-model="queryParams.materialDesc"
placeholder="请输入物料描述"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"></el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button>
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['wms:chargeorder:add']"
>新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['wms:chargeorder:edit']"
>修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['wms:chargeorder:remove']"
>删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['wms:chargeorder:export']"
>导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="chargeorderList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="序号" type="index" :index='indexMethod'> </el-table-column>
<el-table-column label="工厂编码" align="center" prop="siteCode"v-if="false" />
<el-table-column label="ID" align="center" prop="ID" v-if="false" />
<el-table-column label="配料单号" align="center" prop="orderCode" />
<el-table-column label="物料编码" align="center" prop="materialCode" />
<el-table-column label="物料描述" align="center" prop="materialDesc" />
<
<el-table-column label="数量" align="center" prop="planNumber" />
<el-table-column label="单位" align="center" prop="Unit" />
<el-table-column label="实际数量" align="center" prop="realityNumber" />
<el-table-column label="订单状态" align="center" prop="orderStatus" />
<el-table-column label="供应商编码" align="center" prop="supplierCode" v-if="false" />
<el-table-column label="供应商名称" align="center" prop="supplierName" />
<el-table-column label="创建人" align="center" prop="createBy" />
<el-table-column label="创建时间" align="center" prop="createDate" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.createDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 添加或修改粉料配料对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-form-item label="计划日期" prop="planDate">
<el-date-picker clearable
v-model="form.planDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择计划日期">
</el-date-picker>
</el-form-item>
<el-form-item label="备注" prop="Remark">
<el-input v-model="form.Remark" placeholder="请输入备注" />
</el-form-item>
</el-form>
<div class="dialog-footer">
<el-button type="primary" @click="submitFormOne"></el-button>
<el-button @click="cancel"></el-button>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button>
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listChargeorder, getChargeorder, delChargeorder, addChargeorder, updateChargeorder } from "@/api/wms/chargeorder";
export default {
name: "Chargeorder",
data() {
return {
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
chargeorderList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
siteCode: null,
orderCode: null,
materialCode: null,
materialDesc: null,
planDate: null,
planNumber: null,
Unit: null,
realityNumber: null,
orderStatus: null,
userDefined1: null,
userDefined2: null,
userDefined3: null,
userDefined4: null,
userDefined5: null,
userDefined6: null,
userDefined7: null,
userDefined8: null,
userDefined9: null,
userDefined10: null,
userDefined11: null,
supplierCode: null,
supplierName: null,
Remark: null,
createBy: null,
createDate: null,
lastUpdateBy: null,
lastUpdateDate: null,
Active: null,
enterpriseId: null,
enterpriseCode: null
},
//
form: {},
//
rules: {
},
addDialogTitle: '添加项目',
addDialogVisible: false,
newItemForm: {
name: ''
//
},
};
},
created() {
this.getList();
},
methods: {
showAddDialog() {
this.addDialogVisible = true;
},
cancelAddDialog() {
this.addDialogVisible = false;
},
confirmAddDialog() {
// API
//
this.addDialogVisible = false;
},
/** 查询粉料配料列表 */
getList() {
this.loading = true;
listChargeorder(this.queryParams).then(response => {
this.chargeorderList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
siteCode: null,
ID: null,
orderCode: null,
materialCode: null,
materialDesc: null,
planDate: null,
planNumber: null,
Unit: null,
realityNumber: null,
orderStatus: null,
userDefined1: null,
userDefined2: null,
userDefined3: null,
userDefined4: null,
userDefined5: null,
userDefined6: null,
userDefined7: null,
userDefined8: null,
userDefined9: null,
userDefined10: null,
userDefined11: null,
supplierCode: null,
supplierName: null,
Remark: null,
createBy: null,
createDate: null,
lastUpdateBy: null,
lastUpdateDate: null,
Active: null,
enterpriseId: null,
enterpriseCode: null
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.ID)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加粉料配料单";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();
const ID = row.ID || this.ids
getChargeorder(ID).then(response => {
this.form = response.data;
this.open = true;
this.title = "修改粉料配料";
});
},
/** 提交按钮 */One
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
if (this.form.ID != null) {
updateChargeorder(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
});
} else {
addChargeorder(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const IDs = row.ID || this.ids;
this.$modal.confirm('是否确认删除粉料配料编号为"' + IDs + '"的数据项?').then(function() {
return delChargeorder(IDs);
}).then(() => {
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {});
},
/** 导出按钮操作 */
handleExport() {
this.download('wms/chargeorder/export', {
...this.queryParams
}, `chargeorder_${new Date().getTime()}.xlsx`)
}
}
};
</script>

@ -0,0 +1,458 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="出库单号" prop="orderCode">
<el-input
v-model="queryParams.orderCode"
placeholder="请输入出库单号"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="型号编码" prop="materialCode">
<el-input
v-model="queryParams.materialCode"
placeholder="请输入型号编码"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="型号名称" prop="materialDesc">
<el-input
v-model="queryParams.materialDesc"
placeholder="请输入型号名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"></el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button>
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['wms:embryo:add']"
>新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['wms:embryo:edit']"
>修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['wms:embryo:remove']"
>删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['wms:embryo:export']"
>导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="embryoList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="序号" type="index" :index='indexMethod'> </el-table-column>
<el-table-column label="工厂编码" align="center" prop="siteCode" v-if="false" />
<el-table-column label="ID" align="center" prop="ID" v-if="false" />
<el-table-column label="出库单号" align="center" prop="orderCode" />
<el-table-column label="型号编码" align="center" prop="materialCode" />
<el-table-column label="型号名称" align="center" prop="materialDesc" />
<el-table-column label="计划日期" align="center" prop="planDate" width="180" v-if="false" >
<template slot-scope="scope">
<span>{{ parseTime(scope.row.planDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="计划数量" align="center" prop="planNumber" />
<el-table-column label="单位" align="center" prop="Unit" v-if="false" />
<el-table-column label="已出库数量" align="center" prop="realityNumber" />
<el-table-column label="订单状态" align="center" prop="orderStatus" />
<el-table-column label="批次号" align="center" prop="userDefined1" />
<el-table-column label="产线" align="center" prop="productionLineDesc" />
<el-table-column label="产线编号" align="center" prop="productionLineCode" v-if="false" />
<el-table-column label="库位" align="center" prop="locCode" />
<el-table-column label="备注" align="center" prop="Remark" />
<el-table-column label="创建人" align="center" prop="createBy" />
<el-table-column label="创建时间" align="center" prop="createDate" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.createDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['wms:embryo:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['wms:embryo:remove']"
>删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 添加或修改白胚出库单对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-form-item label="工厂编码" prop="siteCode">
<el-input v-model="form.siteCode" placeholder="请输入工厂编码" />
</el-form-item>
<el-form-item label="出库单号" prop="orderCode">
<el-input v-model="form.orderCode" placeholder="请输入出库单号" />
</el-form-item>
<el-form-item label="型号编码" prop="materialCode">
<el-input v-model="form.materialCode" placeholder="请输入型号编码" />
</el-form-item>
<el-form-item label="型号名称" prop="materialDesc">
<el-input v-model="form.materialDesc" placeholder="请输入型号名称" />
</el-form-item>
<el-form-item label="计划日期" prop="planDate">
<el-date-picker clearable
v-model="form.planDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择计划日期">
</el-date-picker>
</el-form-item>
<el-form-item label="计划数量" prop="planNumber">
<el-input v-model="form.planNumber" placeholder="请输入计划数量" />
</el-form-item>
<el-form-item label="单位" prop="Unit">
<el-input v-model="form.Unit" placeholder="请输入单位" />
</el-form-item>
<el-form-item label="已出库数量" prop="realityNumber">
<el-input v-model="form.realityNumber" placeholder="请输入已出库数量" />
</el-form-item>
<el-form-item label="批次号" prop="userDefined1">
<el-input v-model="form.userDefined1" placeholder="请输入批次号" />
</el-form-item>
<el-form-item label="产线名称" prop="productionLineDesc">
<el-input v-model="form.productionLineDesc" placeholder="请输入产线名称" />
</el-form-item>
<el-form-item label="产线编号" prop="productionLineCode">
<el-input v-model="form.productionLineCode" placeholder="请输入产线编号" />
</el-form-item>
<el-form-item label="库位" prop="locCode">
<el-input v-model="form.locCode" placeholder="请输入库位" />
</el-form-item>
<el-form-item label="用户自定义属性2" prop="userDefined2">
<el-input v-model="form.userDefined2" placeholder="请输入用户自定义属性2" />
</el-form-item>
<el-form-item label="用户自定义属性3" prop="userDefined3">
<el-input v-model="form.userDefined3" placeholder="请输入用户自定义属性3" />
</el-form-item>
<el-form-item label="用户自定义属性4" prop="userDefined4">
<el-input v-model="form.userDefined4" placeholder="请输入用户自定义属性4" />
</el-form-item>
<el-form-item label="用户自定义属性5" prop="userDefined5">
<el-input v-model="form.userDefined5" placeholder="请输入用户自定义属性5" />
</el-form-item>
<el-form-item label="用户自定义属性6" prop="userDefined6">
<el-input v-model="form.userDefined6" placeholder="请输入用户自定义属性6" />
</el-form-item>
<el-form-item label="用户自定义属性7" prop="userDefined7">
<el-input v-model="form.userDefined7" placeholder="请输入用户自定义属性7" />
</el-form-item>
<el-form-item label="用户自定义属性8" prop="userDefined8">
<el-input v-model="form.userDefined8" placeholder="请输入用户自定义属性8" />
</el-form-item>
<el-form-item label="用户自定义属性9" prop="userDefined9">
<el-input v-model="form.userDefined9" placeholder="请输入用户自定义属性9" />
</el-form-item>
<el-form-item label="用户自定义属性10" prop="userDefined10">
<el-input v-model="form.userDefined10" placeholder="请输入用户自定义属性10" />
</el-form-item>
<el-form-item label="用户自定义属性11" prop="userDefined11">
<el-input v-model="form.userDefined11" placeholder="请输入用户自定义属性11" />
</el-form-item>
<el-form-item label="供应商编码" prop="supplierCode">
<el-input v-model="form.supplierCode" placeholder="请输入供应商编码" />
</el-form-item>
<el-form-item label="供应商名称" prop="supplierName">
<el-input v-model="form.supplierName" placeholder="请输入供应商名称" />
</el-form-item>
<el-form-item label="备注" prop="Remark">
<el-input v-model="form.Remark" placeholder="请输入备注" />
</el-form-item>
<el-form-item label="创建时间" prop="createDate">
<el-date-picker clearable
v-model="form.createDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择创建时间">
</el-date-picker>
</el-form-item>
<el-form-item label="最后更新人" prop="lastUpdateBy">
<el-input v-model="form.lastUpdateBy" placeholder="请输入最后更新人" />
</el-form-item>
<el-form-item label="最后更新时间" prop="lastUpdateDate">
<el-date-picker clearable
v-model="form.lastUpdateDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择最后更新时间">
</el-date-picker>
</el-form-item>
<el-form-item label="可用标识" prop="Active">
<el-input v-model="form.Active" placeholder="请输入可用标识" />
</el-form-item>
<el-form-item label="企业主键" prop="enterpriseId">
<el-input v-model="form.enterpriseId" placeholder="请输入企业主键" />
</el-form-item>
<el-form-item label="企业编码" prop="enterpriseCode">
<el-input v-model="form.enterpriseCode" placeholder="请输入企业编码" />
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button>
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listEmbryo, getEmbryo, delEmbryo, addEmbryo, updateEmbryo } from "@/api/wms/embryo";
export default {
name: "Embryo",
data() {
return {
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
embryoList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
siteCode: null,
orderCode: null,
materialCode: null,
materialDesc: null,
planDate: null,
planNumber: null,
Unit: null,
realityNumber: null,
orderStatus: null,
userDefined1: null,
productionLineDesc: null,
productionLineCode: null,
locCode: null,
userDefined2: null,
userDefined3: null,
userDefined4: null,
userDefined5: null,
userDefined6: null,
userDefined7: null,
userDefined8: null,
userDefined9: null,
userDefined10: null,
userDefined11: null,
supplierCode: null,
supplierName: null,
Remark: null,
createBy: null,
createDate: null,
lastUpdateBy: null,
lastUpdateDate: null,
Active: null,
enterpriseId: null,
enterpriseCode: null
},
//
form: {},
//
rules: {
}
};
},
created() {
this.getList();
},
methods: {
/** 查询白胚出库单列表 */
getList() {
this.loading = true;
listEmbryo(this.queryParams).then(response => {
this.embryoList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
siteCode: null,
ID: null,
orderCode: null,
materialCode: null,
materialDesc: null,
planDate: null,
planNumber: null,
Unit: null,
realityNumber: null,
orderStatus: null,
userDefined1: null,
productionLineDesc: null,
productionLineCode: null,
locCode: null,
userDefined2: null,
userDefined3: null,
userDefined4: null,
userDefined5: null,
userDefined6: null,
userDefined7: null,
userDefined8: null,
userDefined9: null,
userDefined10: null,
userDefined11: null,
supplierCode: null,
supplierName: null,
Remark: null,
createBy: null,
createDate: null,
lastUpdateBy: null,
lastUpdateDate: null,
Active: null,
enterpriseId: null,
enterpriseCode: null
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.ID)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加白胚出库单";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();
const ID = row.ID || this.ids
getEmbryo(ID).then(response => {
this.form = response.data;
this.open = true;
this.title = "修改白胚出库单";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
if (this.form.ID != null) {
updateEmbryo(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
});
} else {
addEmbryo(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const IDs = row.ID || this.ids;
this.$modal.confirm('是否确认删除白胚出库单编号为"' + IDs + '"的数据项?').then(function() {
return delEmbryo(IDs);
}).then(() => {
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {});
},
/** 导出按钮操作 */
handleExport() {
this.download('wms/embryo/export', {
...this.queryParams
}, `embryo_${new Date().getTime()}.xlsx`)
}
}
};
</script>

@ -0,0 +1,462 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="采购单号" prop="procureCode">
<el-input
v-model="queryParams.procureCode"
placeholder="请输入采购单号"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="物料编码" prop="materialCode">
<el-input
v-model="queryParams.materialCode"
placeholder="请输入物料编码"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="物料描述" prop="materialDesc">
<el-input
v-model="queryParams.materialDesc"
placeholder="请输入物料描述"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="计划日期" prop="planDate">
<el-date-picker clearable
v-model="queryParams.planDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择计划日期">
</el-date-picker>
</el-form-item>
<el-form-item label="供应商" prop="supplierCode">
<el-input
v-model="queryParams.supplierCode"
placeholder="请输入供应商"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"></el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button>
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['wms:order:add']"
>新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['wms:order:edit']"
>修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['wms:order:remove']"
>删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['wms:order:export']"
>导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="orderList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="序号" type="index" :index='indexMethod'> </el-table-column>
<el-table-column label="工厂编码" align="center" prop="siteCode" v-if="false" />
<el-table-column label="ID" align="center" prop="ID" v-if="false" />
<el-table-column label="采购单号" align="center" prop="procureCode" />
<el-table-column label="物料编码" align="center" prop="materialCode" />
<el-table-column label="物料描述" align="center" prop="materialDesc" />
<el-table-column label="计划日期" align="center" prop="planDate" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.planDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="计划数量" align="center" prop="planNumber" />
<el-table-column label="单位" align="center" prop="Unit" />
<el-table-column label="已入库数量" align="center" prop="realityNumber" v-if="false" />
<el-table-column label="订单状态" align="center" prop="orderStatus" />
<el-table-column label="供应商编码" align="center" prop="supplierCode" />
<el-table-column label="供应商名称" align="center" prop="supplierName" />
<el-table-column label="备注" align="center" prop="Remark" />
<el-table-column label="创建人" align="center" prop="createBy" />
<el-table-column label="创建时间" align="center" prop="createDate" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.createDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['wms:order:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['wms:order:remove']"
>删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 添加或修改包材采购单对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-form-item label="工厂编码" prop="siteCode">
<el-input v-model="form.siteCode" placeholder="请输入工厂编码" />
</el-form-item>
<el-form-item label="采购单号" prop="procureCode">
<el-input v-model="form.procureCode" placeholder="请输入采购单号" />
</el-form-item>
<el-form-item label="物料编码" prop="materialCode">
<el-input v-model="form.materialCode" placeholder="请输入物料编码" />
</el-form-item>
<el-form-item label="物料描述" prop="materialDesc">
<el-input v-model="form.materialDesc" placeholder="请输入物料描述" />
</el-form-item>
<el-form-item label="计划日期" prop="planDate">
<el-date-picker clearable
v-model="form.planDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择计划日期">
</el-date-picker>
</el-form-item>
<el-form-item label="计划数量" prop="planNumber">
<el-input v-model="form.planNumber" placeholder="请输入计划数量" />
</el-form-item>
<el-form-item label="单位" prop="Unit">
<el-input v-model="form.Unit" placeholder="请输入单位" />
</el-form-item>
<el-form-item label="已入库数量" prop="realityNumber">
<el-input v-model="form.realityNumber" placeholder="请输入已入库数量" />
</el-form-item>
<el-form-item label="用户自定义属性1" prop="userDefined1">
<el-input v-model="form.userDefined1" placeholder="请输入用户自定义属性1" />
</el-form-item>
<el-form-item label="用户自定义属性2" prop="userDefined2">
<el-input v-model="form.userDefined2" placeholder="请输入用户自定义属性2" />
</el-form-item>
<el-form-item label="用户自定义属性3" prop="userDefined3">
<el-input v-model="form.userDefined3" placeholder="请输入用户自定义属性3" />
</el-form-item>
<el-form-item label="用户自定义属性4" prop="userDefined4">
<el-input v-model="form.userDefined4" placeholder="请输入用户自定义属性4" />
</el-form-item>
<el-form-item label="用户自定义属性5" prop="userDefined5">
<el-input v-model="form.userDefined5" placeholder="请输入用户自定义属性5" />
</el-form-item>
<el-form-item label="用户自定义属性6" prop="userDefined6">
<el-input v-model="form.userDefined6" placeholder="请输入用户自定义属性6" />
</el-form-item>
<el-form-item label="用户自定义属性7" prop="userDefined7">
<el-input v-model="form.userDefined7" placeholder="请输入用户自定义属性7" />
</el-form-item>
<el-form-item label="用户自定义属性8" prop="userDefined8">
<el-input v-model="form.userDefined8" placeholder="请输入用户自定义属性8" />
</el-form-item>
<el-form-item label="用户自定义属性9" prop="userDefined9">
<el-input v-model="form.userDefined9" placeholder="请输入用户自定义属性9" />
</el-form-item>
<el-form-item label="用户自定义属性10" prop="userDefined10">
<el-input v-model="form.userDefined10" placeholder="请输入用户自定义属性10" />
</el-form-item>
<el-form-item label="用户自定义属性11" prop="userDefined11">
<el-input v-model="form.userDefined11" placeholder="请输入用户自定义属性11" />
</el-form-item>
<el-form-item label="供应商编码" prop="supplierCode">
<el-input v-model="form.supplierCode" placeholder="请输入供应商编码" />
</el-form-item>
<el-form-item label="供应商名称" prop="supplierName">
<el-input v-model="form.supplierName" placeholder="请输入供应商名称" />
</el-form-item>
<el-form-item label="备注" prop="Remark">
<el-input v-model="form.Remark" placeholder="请输入备注" />
</el-form-item>
<el-form-item label="创建时间" prop="createDate">
<el-date-picker clearable
v-model="form.createDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择创建时间">
</el-date-picker>
</el-form-item>
<el-form-item label="最后更新人" prop="lastUpdateBy">
<el-input v-model="form.lastUpdateBy" placeholder="请输入最后更新人" />
</el-form-item>
<el-form-item label="最后更新时间" prop="lastUpdateDate">
<el-date-picker clearable
v-model="form.lastUpdateDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择最后更新时间">
</el-date-picker>
</el-form-item>
<el-form-item label="可用标识" prop="Active">
<el-input v-model="form.Active" placeholder="请输入可用标识" />
</el-form-item>
<el-form-item label="企业主键" prop="enterpriseId">
<el-input v-model="form.enterpriseId" placeholder="请输入企业主键" />
</el-form-item>
<el-form-item label="企业编码" prop="enterpriseCode">
<el-input v-model="form.enterpriseCode" placeholder="请输入企业编码" />
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button>
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listOrder, getOrder, delOrder, addOrder, updateOrder } from "@/api/wms/order";
export default {
name: "Order",
data() {
return {
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
orderList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
siteCode: null,
procureCode: null,
materialCode: null,
materialDesc: null,
planDate: null,
planNumber: null,
Unit: null,
realityNumber: null,
orderStatus: null,
userDefined1: null,
userDefined2: null,
userDefined3: null,
userDefined4: null,
userDefined5: null,
userDefined6: null,
userDefined7: null,
userDefined8: null,
userDefined9: null,
userDefined10: null,
userDefined11: null,
supplierCode: null,
supplierName: null,
Remark: null,
createBy: null,
createDate: null,
lastUpdateBy: null,
lastUpdateDate: null,
Active: null,
enterpriseId: null,
enterpriseCode: null
},
//
form: {},
//
rules: {
}
};
},
created() {
this.getList();
},
methods: {
/** 查询包材采购单列表 */
getList() {
this.loading = true;
listOrder(this.queryParams).then(response => {
this.orderList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
siteCode: null,
ID: null,
procureCode: null,
materialCode: null,
materialDesc: null,
planDate: null,
planNumber: null,
Unit: null,
realityNumber: null,
orderStatus: null,
userDefined1: null,
userDefined2: null,
userDefined3: null,
userDefined4: null,
userDefined5: null,
userDefined6: null,
userDefined7: null,
userDefined8: null,
userDefined9: null,
userDefined10: null,
userDefined11: null,
supplierCode: null,
supplierName: null,
Remark: null,
createBy: null,
createDate: null,
lastUpdateBy: null,
lastUpdateDate: null,
Active: null,
enterpriseId: null,
enterpriseCode: null
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.ID)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加包材采购单";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();
const ID = row.ID || this.ids
getOrder(ID).then(response => {
this.form = response.data;
this.open = true;
this.title = "修改包材采购单";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
if (this.form.ID != null) {
updateOrder(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
});
} else {
addOrder(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const IDs = row.ID || this.ids;
this.$modal.confirm('是否确认删除包材采购单编号为"' + IDs + '"的数据项?').then(function() {
return delOrder(IDs);
}).then(() => {
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {});
},
/** 导出按钮操作 */
handleExport() {
this.download('wms/order/export', {
...this.queryParams
}, `order_${new Date().getTime()}.xlsx`)
}
}
};
</script>

@ -0,0 +1,459 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="出库单号" prop="produceCode">
<el-input
v-model="queryParams.produceCode"
placeholder="请输入出库单号"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="型号编码" prop="materialCode">
<el-input
v-model="queryParams.materialCode"
placeholder="请输入型号编码"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="型号名称" prop="materialDesc">
<el-input
v-model="queryParams.materialDesc"
placeholder="请输入型号名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"></el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button>
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['wms:outorder:add']"
>新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['wms:outorder:edit']"
>修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['wms:outorder:remove']"
>删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['wms:outorder:export']"
>导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="outorderList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="序号" type="index" :index='indexMethod'> </el-table-column>
<el-table-column label="工厂编码" align="center" prop="siteCode" v-if="false" />
<el-table-column label="ID" align="center" prop="ID" v-if="false" />
<el-table-column label="生产订单" align="center" prop="produceCode" />
<el-table-column label="型号编码" align="center" prop="materialCode" />
<el-table-column label="型号名称" align="center" prop="materialDesc" />
<el-table-column label="批次号" align="center" prop="userDefined1" />
<el-table-column label="计划日期" align="center" prop="planDate" width="180"v-if="false" >
<template slot-scope="scope">
<span>{{ parseTime(scope.row.planDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="计划数量" align="center" prop="planNumber" />
<el-table-column label="单位" align="center" prop="Unit" v-if="false" />
<el-table-column label="已出库数量" align="center" prop="outNumber" />
<el-table-column label="库位" align="center" prop="locCode" />
<el-table-column label="库位名称" align="center" prop="locDesc"v-if="false" />
<el-table-column label="产线名称" align="center" prop="productionLineDesc" v-if="false" />
<el-table-column label="产线" align="center" prop="productionLineCode" />
<el-table-column label="订单状态" align="center" prop="orderStatus" />
<el-table-column label="创建人" align="center" prop="createBy" />
<el-table-column label="创建时间" align="center" prop="createDate" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.createDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['wms:outorder:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['wms:outorder:remove']"
>删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 添加或修改包材出库单对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-form-item label="工厂编码" prop="siteCode">
<el-input v-model="form.siteCode" placeholder="请输入工厂编码" />
</el-form-item>
<el-form-item label="生成订单" prop="produceCode">
<el-input v-model="form.produceCode" placeholder="请输入生成订单" />
</el-form-item>
<el-form-item label="型号编码" prop="materialCode">
<el-input v-model="form.materialCode" placeholder="请输入型号编码" />
</el-form-item>
<el-form-item label="型号名称" prop="materialDesc">
<el-input v-model="form.materialDesc" placeholder="请输入型号名称" />
</el-form-item>
<el-form-item label="计划日期" prop="planDate">
<el-date-picker clearable
v-model="form.planDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择计划日期">
</el-date-picker>
</el-form-item>
<el-form-item label="计划数量" prop="planNumber">
<el-input v-model="form.planNumber" placeholder="请输入计划数量" />
</el-form-item>
<el-form-item label="单位" prop="Unit">
<el-input v-model="form.Unit" placeholder="请输入单位" />
</el-form-item>
<el-form-item label="已出库数量" prop="outNumber">
<el-input v-model="form.outNumber" placeholder="请输入已出库数量" />
</el-form-item>
<el-form-item label="库位编号" prop="locCode">
<el-input v-model="form.locCode" placeholder="请输入库位编号" />
</el-form-item>
<el-form-item label="库位名称" prop="locDesc">
<el-input v-model="form.locDesc" placeholder="请输入库位名称" />
</el-form-item>
<el-form-item label="产线名称" prop="productionLineDesc">
<el-input v-model="form.productionLineDesc" placeholder="请输入产线名称" />
</el-form-item>
<el-form-item label="产线编号" prop="productionLineCode">
<el-input v-model="form.productionLineCode" placeholder="请输入产线编号" />
</el-form-item>
<el-form-item label="批次号" prop="userDefined1">
<el-input v-model="form.userDefined1" placeholder="请输入批次号" />
</el-form-item>
<el-form-item label="用户自定义属性2" prop="userDefined2">
<el-input v-model="form.userDefined2" placeholder="请输入用户自定义属性2" />
</el-form-item>
<el-form-item label="用户自定义属性3" prop="userDefined3">
<el-input v-model="form.userDefined3" placeholder="请输入用户自定义属性3" />
</el-form-item>
<el-form-item label="用户自定义属性4" prop="userDefined4">
<el-input v-model="form.userDefined4" placeholder="请输入用户自定义属性4" />
</el-form-item>
<el-form-item label="用户自定义属性5" prop="userDefined5">
<el-input v-model="form.userDefined5" placeholder="请输入用户自定义属性5" />
</el-form-item>
<el-form-item label="用户自定义属性6" prop="userDefined6">
<el-input v-model="form.userDefined6" placeholder="请输入用户自定义属性6" />
</el-form-item>
<el-form-item label="用户自定义属性7" prop="userDefined7">
<el-input v-model="form.userDefined7" placeholder="请输入用户自定义属性7" />
</el-form-item>
<el-form-item label="用户自定义属性8" prop="userDefined8">
<el-input v-model="form.userDefined8" placeholder="请输入用户自定义属性8" />
</el-form-item>
<el-form-item label="用户自定义属性9" prop="userDefined9">
<el-input v-model="form.userDefined9" placeholder="请输入用户自定义属性9" />
</el-form-item>
<el-form-item label="用户自定义属性10" prop="userDefined10">
<el-input v-model="form.userDefined10" placeholder="请输入用户自定义属性10" />
</el-form-item>
<el-form-item label="用户自定义属性11" prop="userDefined11">
<el-input v-model="form.userDefined11" placeholder="请输入用户自定义属性11" />
</el-form-item>
<el-form-item label="供应商编码" prop="supplierCode">
<el-input v-model="form.supplierCode" placeholder="请输入供应商编码" />
</el-form-item>
<el-form-item label="供应商名称" prop="supplierName">
<el-input v-model="form.supplierName" placeholder="请输入供应商名称" />
</el-form-item>
<el-form-item label="创建时间" prop="createDate">
<el-date-picker clearable
v-model="form.createDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择创建时间">
</el-date-picker>
</el-form-item>
<el-form-item label="最后更新人" prop="lastUpdateBy">
<el-input v-model="form.lastUpdateBy" placeholder="请输入最后更新人" />
</el-form-item>
<el-form-item label="最后更新时间" prop="lastUpdateDate">
<el-date-picker clearable
v-model="form.lastUpdateDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择最后更新时间">
</el-date-picker>
</el-form-item>
<el-form-item label="可用标识" prop="Active">
<el-input v-model="form.Active" placeholder="请输入可用标识" />
</el-form-item>
<el-form-item label="企业主键" prop="enterpriseId">
<el-input v-model="form.enterpriseId" placeholder="请输入企业主键" />
</el-form-item>
<el-form-item label="企业编码" prop="enterpriseCode">
<el-input v-model="form.enterpriseCode" placeholder="请输入企业编码" />
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button>
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listOutorder, getOutorder, delOutorder, addOutorder, updateOutorder } from "@/api/wms/outorder";
export default {
name: "Outorder",
data() {
return {
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
outorderList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
siteCode: null,
produceCode: null,
materialCode: null,
materialDesc: null,
planDate: null,
planNumber: null,
Unit: null,
outNumber: null,
locCode: null,
locDesc: null,
productionLineDesc: null,
productionLineCode: null,
orderStatus: null,
userDefined1: null,
userDefined2: null,
userDefined3: null,
userDefined4: null,
userDefined5: null,
userDefined6: null,
userDefined7: null,
userDefined8: null,
userDefined9: null,
userDefined10: null,
userDefined11: null,
supplierCode: null,
supplierName: null,
createBy: null,
createDate: null,
lastUpdateBy: null,
lastUpdateDate: null,
Active: null,
enterpriseId: null,
enterpriseCode: null
},
//
form: {},
//
rules: {
}
};
},
created() {
this.getList();
},
methods: {
/** 查询包材出库单列表 */
getList() {
this.loading = true;
listOutorder(this.queryParams).then(response => {
this.outorderList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
siteCode: null,
ID: null,
produceCode: null,
materialCode: null,
materialDesc: null,
planDate: null,
planNumber: null,
Unit: null,
outNumber: null,
locCode: null,
locDesc: null,
productionLineDesc: null,
productionLineCode: null,
orderStatus: null,
userDefined1: null,
userDefined2: null,
userDefined3: null,
userDefined4: null,
userDefined5: null,
userDefined6: null,
userDefined7: null,
userDefined8: null,
userDefined9: null,
userDefined10: null,
userDefined11: null,
supplierCode: null,
supplierName: null,
createBy: null,
createDate: null,
lastUpdateBy: null,
lastUpdateDate: null,
Active: null,
enterpriseId: null,
enterpriseCode: null
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.ID)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加包材出库单";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();
const ID = row.ID || this.ids
getOutorder(ID).then(response => {
this.form = response.data;
this.open = true;
this.title = "修改包材出库单";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
if (this.form.ID != null) {
updateOutorder(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
});
} else {
addOutorder(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const IDs = row.ID || this.ids;
this.$modal.confirm('是否确认删除包材出库单编号为"' + IDs + '"的数据项?').then(function() {
return delOutorder(IDs);
}).then(() => {
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {});
},
/** 导出按钮操作 */
handleExport() {
this.download('wms/outorder/export', {
...this.queryParams
}, `outorder_${new Date().getTime()}.xlsx`)
}
}
};
</script>

@ -0,0 +1,430 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="采购单号" prop="orderCode">
<el-input
v-model="queryParams.orderCode"
placeholder="请输入采购单号"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="物料编码" prop="materialCode">
<el-input
v-model="queryParams.materialCode"
placeholder="请输入物料编码"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="物料描述" prop="materialDesc">
<el-input
v-model="queryParams.materialDesc"
placeholder="请输入物料描述"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="计划日期" prop="planDate">
<el-date-picker clearable
v-model="queryParams.planDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择计划日期">
</el-date-picker>
</el-form-item>
<el-form-item label="供应商编码" prop="supplierCode">
<el-input
v-model="queryParams.supplierCode"
placeholder="请输入供应商编码"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="库位名称" prop="locDesc">
<el-input
v-model="queryParams.locDesc"
placeholder="请输入库位名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="库位编号" prop="locCode">
<el-input
v-model="queryParams.locCode"
placeholder="请输入库位编号"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"></el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button>
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['wms:powderOrder:add']"
>新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['wms:powderOrder:edit']"
>修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['wms:powderOrder:remove']"
>删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['wms:powderOrder:export']"
>导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="powderOrderList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="工厂编码" align="center" prop="siteCode" v-if="false" />
<el-table-column label="id" align="center" prop="id" v-if="false" />
<el-table-column label="采购单号" align="center" prop="orderCode" />
<el-table-column label="物料编码" align="center" prop="materialCode" />
<el-table-column label="物料描述" align="center" prop="materialDesc" />
<el-table-column label="计划日期" align="center" prop="planDate" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.planDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="计划数量" align="center" prop="planNumber" />
<el-table-column label="单位" align="center" prop="unit" />
<el-table-column label="实际数量" align="center" prop="realityNumber" />
<el-table-column label="库位编号" align="center" prop="locCode" v-if="false" />
<el-table-column label="库位名称" align="center" prop="locDesc" />
<el-table-column label="订单状态" align="center" prop="orderStatus">
<template slot-scope="scope">
<span v-if="scope.row.orderStatus === '1'"></span>
<span v-else-if="scope.row.orderStatus === '2'">收货退回</span>
<span v-else-if="scope.row.orderStatus === '3'">收货完成</span>
</template>
</el-table-column>
<el-table-column label="供应商编码" align="center" prop="supplierCode" />
<el-table-column label="供应商名称" align="center" prop="supplierName" />
<el-table-column label="备注" align="center" prop="remark" />
<el-table-column label="创建人" align="center" prop="createBy" />
<el-table-column label="创建时间" align="center" prop="createDate" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.createDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['wms:powderOrder:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['wms:powderOrder:remove']"
>删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 添加或修改粉料采购计划对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-form-item label="物料编码" prop="materialCode">
<el-input v-model="form.materialCode" placeholder="请输入物料编码" />
</el-form-item>
<el-form-item label="物料描述" prop="materialDesc">
<el-input v-model="form.materialDesc" placeholder="请输入物料描述" />
</el-form-item>
<el-form-item label="计划日期" prop="planDate">
<el-date-picker clearable
v-model="form.planDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择计划日期">
</el-date-picker>
</el-form-item>
<el-form-item label="计划数量" prop="planNumber">
<el-input v-model="form.planNumber" placeholder="请输入计划数量" />
</el-form-item>
<el-form-item label="单位" prop="unit">
<el-input v-model="form.unit" placeholder="请输入单位" />
</el-form-item>
<el-form-item label="库位编号" prop="locCode">
<el-input v-model="form.locCode" placeholder="请输入库位编号" />
</el-form-item>
<el-form-item label="库位名称" prop="locDesc">
<el-input v-model="form.locDesc" placeholder="请输入库位名称" />
</el-form-item>
<el-form-item label="供应商编码" prop="supplierCode">
<el-input v-model="form.supplierCode" placeholder="请输入供应商编码" />
</el-form-item>
<el-form-item label="供应商名称" prop="supplierName">
<el-input v-model="form.supplierName" placeholder="请输入供应商名称" />
</el-form-item>
<el-form-item label="备注" prop="remark">
<el-input v-model="form.remark" placeholder="请输入备注" />
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button>
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listPowderOrder, getPowderOrder, delPowderOrder, addPowderOrder, updatePowderOrder } from "@/api/wms/powderOrder";
export default {
name: "PowderOrder",
data() {
return {
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
powderOrderList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
siteCode: null,
orderCode: null,
materialCode: null,
materialDesc: null,
planDate: null,
planNumber: null,
unit: null,
realityNumber: null,
orderStatus: null,
userDefined1: null,
userDefined2: null,
userDefined3: null,
userDefined4: null,
userDefined5: null,
userDefined6: null,
userDefined7: null,
userDefined8: null,
userDefined9: null,
userDefined10: null,
userDefined11: null,
supplierCode: null,
locCode:null,
locDesc: null,
supplierName: null,
remark: null,
createBy: null,
createDate: null,
lastUpdateBy: null,
lastUpdateDate: null,
Active: null,
enterpriseId: null,
enterpriseCode: null,
lssuedNumber: null
},
//
form: {},
//
rules: {
}
};
},
created() {
this.getList();
},
methods: {
/** 查询粉料采购计划列表 */
getList() {
this.loading = true;
listPowderOrder(this.queryParams).then(response => {
this.powderOrderList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
siteCode: null,
id: null,
orderCode: null,
materialCode: null,
materialDesc: null,
planDate: null,
planNumber: null,
unit: null,
realityNumber: null,
orderStatus: null,
userDefined1: null,
userDefined2: null,
userDefined3: null,
userDefined4: null,
userDefined5: null,
userDefined6: null,
userDefined7: null,
userDefined8: null,
userDefined9: null,
userDefined10: null,
userDefined11: null,
supplierCode: null,
supplierName: null,
remark: null,
createBy: null,
createDate: null,
lastUpdateBy: null,
lastUpdateDate: null,
Active: null,
enterpriseId: null,
enterpriseCode: null,
lssuedNumber: null
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();
const id = row.id || this.ids
getPowderOrder(id).then(response => {
this.form = response.data;
this.open = true;
this.title = "修改粉料采购计划";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
const User = this.$store.state;
console.log("--------"+User)
if (valid) {
if (this.form.id != null) {
updatePowderOrder(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
});
} else {
addPowderOrder(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const IDs = row.id || this.ids;
this.$modal.confirm('是否确认删除粉料采购计划编号为"' + IDs + '"的数据项?').then(function() {
return delPowderOrder(IDs);
}).then(() => {
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {});
},
/** 导出按钮操作 */
handleExport() {
this.download('wms/powderOrder/export', {
...this.queryParams
}, `powderOrder_${new Date().getTime()}.xlsx`)
}
}
};
</script>

@ -0,0 +1,379 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="采购单号" prop="orderCode">
<el-input
v-model="queryParams.orderCode"
placeholder="请输入采购单号"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="物料编码" prop="materialCode">
<el-input
v-model="queryParams.materialCode"
placeholder="请输入物料编码"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="物料描述" prop="materialDesc">
<el-input
v-model="queryParams.materialDesc"
placeholder="请输入物料描述"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="计划日期" prop="planDate">
<el-date-picker clearable
v-model="queryParams.planDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择计划日期">
</el-date-picker>
</el-form-item>
<el-form-item label="供应商编码" prop="supplierCode">
<el-input
v-model="queryParams.supplierCode"
placeholder="请输入供应商编码"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"></el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button>
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
>收货确认</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
>不合格退回</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['wms:powderOrder:export']"
>导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="powderOrderList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="工厂编码" align="center" prop="siteCode" v-if="false" />
<el-table-column label="id" align="center" prop="id" v-if="false" />
<el-table-column label="采购单号" align="center" prop="orderCode" />
<el-table-column label="物料编码" align="center" prop="materialCode" />
<el-table-column label="物料描述" align="center" prop="materialDesc" />
<el-table-column label="计划数量" align="center" prop="planNumber" />
<el-table-column label="单位" align="center" prop="unit" />
<el-table-column label="整车重量" align="center" prop="comNumber" />
<el-table-column label="空车重量" align="center" prop="emptyNumber" />
<el-table-column label="送货数量" align="center" prop="realityNumber" />
<el-table-column label="订单状态" align="center" prop="orderStatus">
<template slot-scope="scope">
<span v-if="scope.row.orderStatus === '1'"></span>
<span v-else-if="scope.row.orderStatus === '2'">收货退回</span>
<span v-else-if="scope.row.orderStatus === '3'">收货完成</span>
</template>
</el-table-column>
<el-table-column label="检验状态" align="center" prop="userDefined2">
<template slot-scope="scope">
<span v-if="scope.row.userDefined2 === '1'"></span>
<span v-else-if="scope.row.userDefined2 === '2'">不合格</span>
</template>
</el-table-column>
<el-table-column label="供应商编码" align="center" prop="supplierCode" />
<el-table-column label="供应商名称" align="center" prop="supplierName" />
<el-table-column label="备注" align="center" prop="remark" />
<el-table-column label="创建人" align="center" prop="createBy" />
<el-table-column label="创建时间" align="center" prop="createDate" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.createDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 添加或修改粉料采购计划对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-form-item label="采购单号" prop="orderCode">
<el-input v-model="form.orderCode" placeholder="请输入采购单号" :readonly="true" />
</el-form-item>
<el-form-item label="物料编码" prop="materialCode">
<el-input v-model="form.materialCode" placeholder="请输入物料编码" :readonly="true" />
</el-form-item>
<el-form-item label="物料描述" prop="materialDesc">
<el-input v-model="form.materialDesc" placeholder="请输入物料描述":readonly="true" />
</el-form-item>
<el-form-item label="供应商" prop="supplierName">
<el-input v-model="form.supplierName" placeholder="请输入供应商名称" :readonly="true" />
</el-form-item>
<el-form-item label="整车重量" prop="comNumber">
<el-input v-model="form.comNumber" placeholder="请输入整车重量" />
</el-form-item>
<el-form-item label="空车重量" prop="emptyNumber">
<el-input v-model="form.emptyNumber" placeholder="请输入空车重量" />
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button>
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listPowderOrder, getPowderOrder, delPowderOrder, addPowderOrder, updatePowderOrder,confirmReceipt,powderReturn } from "@/api/wms/powderOrder";
export default {
name: "PowderOrder",
data() {
return {
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
powderOrderList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
siteCode: null,
orderCode: null,
materialCode: null,
materialDesc: null,
planDate: null,
planNumber: null,
unit: null,
realityNumber: null,
orderStatus: null,
userDefined1: null,
userDefined2: null,
userDefined3: null,
userDefined4: null,
userDefined5: null,
userDefined6: null,
userDefined7: null,
userDefined8: null,
userDefined9: null,
userDefined10: null,
userDefined11: null,
supplierCode: null,
supplierName: null,
remark: null,
createBy: null,
createDate: null,
lastUpdateBy: null,
lastUpdateDate: null,
Active: null,
enterpriseId: null,
enterpriseCode: null,
lssuedNumber: null
},
//
form: {},
//
rules: {
}
};
},
created() {
this.getList();
},
methods: {
/** 查询粉料采购计划列表 */
getList() {
this.loading = true;
listPowderOrder(this.queryParams).then(response => {
this.powderOrderList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
siteCode: null,
id: null,
orderCode: null,
materialCode: null,
materialDesc: null,
planDate: null,
planNumber: null,
unit: null,
realityNumber: null,
orderStatus: null,
userDefined1: null,
userDefined2: null,
userDefined3: null,
userDefined4: null,
userDefined5: null,
userDefined6: null,
userDefined7: null,
userDefined8: null,
userDefined9: null,
userDefined10: null,
userDefined11: null,
supplierCode: null,
supplierName: null,
comNumber: null,
emptyNumber: null,
remark: null,
createBy: null,
createDate: null,
lastUpdateBy: null,
lastUpdateDate: null,
Active: null,
enterpriseId: null,
enterpriseCode: null,
lssuedNumber: null
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();
const id = row.id || this.ids
getPowderOrder(id).then(response => {
this.form = response.data;
this.open = true;
this.title = "收货确认";
});
},
handleUpdateFK(row) {
this.reset();
const id = row.id || this.ids
getPowderOrder(id).then(response => {
this.form = response.data;
this.open = true;
this.title = "收货确认";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
const User = this.$store.state;
console.log("--------"+User)
if (valid) {
confirmReceipt(this.form).then(response => {
this.$modal.msgSuccess("收货成功");
this.open = false;
this.getList();
});
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const IDs = row.id || this.ids;
this.$modal.confirm('是否确认退回该粉料收货单').then(function() {
return powderReturn(IDs);
}).then(() => {
this.getList();
this.$modal.msgSuccess("退回成功");
}).catch(() => {});
},
/** 导出按钮操作 */
handleExport() {
this.download('wms/powderOrder/export', {
...this.queryParams
}, `powderOrder_${new Date().getTime()}.xlsx`)
}
}
};
</script>
Loading…
Cancel
Save