jie,iamtiaozheng
This commit is contained in:
parent
9b402fcaf3
commit
8375698ffe
|
@ -46,7 +46,7 @@ export function createInventory(data) {
|
|||
//仓库对应的物料
|
||||
export function getfifodetailList(query) {
|
||||
return request({
|
||||
url: '/inm/fifodetail/',
|
||||
url: '/inm/fifoitem/',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
|
@ -60,6 +60,14 @@ export function getfifoList(query) {
|
|||
params: query
|
||||
})
|
||||
}
|
||||
//出入库记录删除
|
||||
export function deleteFifoitem(id, data) {
|
||||
return request({
|
||||
url: `/inm/fifoitem/${id}/`,
|
||||
method: 'delete',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
//物料批次
|
||||
export function getmaterialbatchList(query) {
|
||||
|
@ -79,3 +87,11 @@ export function audit(id, data) {
|
|||
data
|
||||
})
|
||||
}
|
||||
//出入库检测
|
||||
export function createTestrecord(data) {
|
||||
return request({
|
||||
url: '/inm/fifoitem/test/',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
|
@ -57,11 +57,4 @@ export function deleteTestitem(id, data) {
|
|||
data
|
||||
})
|
||||
}
|
||||
//提交物料检查项目
|
||||
export function createTestrecord(data) {
|
||||
return request({
|
||||
url: '/qm/testrecord/',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
|
|
|
@ -34,11 +34,12 @@
|
|||
<el-table
|
||||
v-loading="listLoading"
|
||||
:data="equipmentList.results"
|
||||
border
|
||||
border
|
||||
fit
|
||||
stripe
|
||||
highlight-current-row
|
||||
max-height="600"
|
||||
height="100"
|
||||
v-el-height-adaptive-table="{bottomOffset: 50}"
|
||||
>
|
||||
<el-table-column type="index" width="50" />
|
||||
<el-table-column label="设备编号">
|
||||
|
|
|
@ -38,32 +38,33 @@
|
|||
fit
|
||||
stripe
|
||||
highlight-current-row
|
||||
max-height="600"
|
||||
height="100"
|
||||
v-el-height-adaptive-table="{bottomOffset: 50}"
|
||||
>
|
||||
<el-table-column type="index" width="50" />
|
||||
<el-table-column label="设备名称">
|
||||
<el-table-column label="设备名称" width="120" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.name }}</template>
|
||||
</el-table-column>
|
||||
|
||||
<el-table-column label="设备编号">
|
||||
<el-table-column label="设备编号" width="120">
|
||||
<template slot-scope="scope">{{ scope.row.number }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="型号规格">
|
||||
<el-table-column label="型号规格" width="120">
|
||||
<template slot-scope="scope">{{ scope.row.model }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="生产厂及国别">
|
||||
<el-table-column label="生产厂及国别" width="120" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.factory }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="生产日期">
|
||||
<el-table-column label="生产日期" width="120">
|
||||
<template slot-scope="scope">{{ scope.row.production_date }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="购置日期">
|
||||
<el-table-column label="购置日期" width="120">
|
||||
<template slot-scope="scope">{{ scope.row.buy_date }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="数量">
|
||||
<el-table-column label="数量" width="120">
|
||||
<template slot-scope="scope">{{ scope.row.count }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="状态">
|
||||
<el-table-column label="状态" width="120">
|
||||
<template slot-scope="scope">
|
||||
<el-tag v-if="scope.row.state===0" type="success">
|
||||
{{ state_[scope.row.state] }}
|
||||
|
@ -79,16 +80,16 @@
|
|||
</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="技术指标" show-overflow-tooltip>
|
||||
<el-table-column label="技术指标" width="120" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.parameter }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="保管人">
|
||||
<el-table-column label="保管人" width="120">
|
||||
<template slot-scope="scope" v-if="scope.row.keeper_">{{ scope.row.keeper_.username }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="存放位置">
|
||||
<el-table-column label="存放位置" width="120" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.place }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="绑定工序">
|
||||
<el-table-column label="绑定工序" width="120" show-overflow-tooltip>
|
||||
<template slot-scope="scope" v-if="scope.row.step_">
|
||||
<el-tag v-for="item in scope.row.step_"
|
||||
:key="item.number"
|
||||
|
@ -98,7 +99,7 @@
|
|||
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="备注">
|
||||
<el-table-column label="备注" width="120" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.description }}</template>
|
||||
</el-table-column>
|
||||
|
||||
|
@ -107,6 +108,7 @@
|
|||
align="center"
|
||||
label="操作"
|
||||
width="120px"
|
||||
fixed="right"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
|
||||
|
|
|
@ -41,15 +41,15 @@
|
|||
max-height="600"
|
||||
>
|
||||
<el-table-column type="index" width="50" />
|
||||
<el-table-column label="仓库">
|
||||
<el-table-column label="出入记录ID">
|
||||
<template slot-scope="scope">{{
|
||||
scope.row.warehouse_.name
|
||||
scope.row.id
|
||||
}}</template>
|
||||
</el-table-column>
|
||||
|
||||
<el-table-column label="出/入库人员">
|
||||
<el-table-column label="操作人员">
|
||||
<template slot-scope="scope">{{
|
||||
scope.row.operator_.username
|
||||
scope.row.create_by_.name
|
||||
}}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="出/入库时间">
|
||||
|
@ -105,34 +105,7 @@
|
|||
label-position="right"
|
||||
:rules="rule1"
|
||||
>
|
||||
<el-form-item label="仓库" prop="warehouse">
|
||||
<el-select
|
||||
v-model="inventory.warehouse"
|
||||
placeholder="请选择"
|
||||
filterable
|
||||
>
|
||||
<el-option
|
||||
v-for="item in warehouseData"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="操作人" prop="operator">
|
||||
<el-select
|
||||
v-model="inventory.operator"
|
||||
placeholder="请选择"
|
||||
filterable
|
||||
>
|
||||
<el-option
|
||||
v-for="item in userData"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="入库时间" prop="inout_date">
|
||||
<el-date-picker
|
||||
v-model="inventory.inout_date"
|
||||
|
@ -146,7 +119,25 @@
|
|||
|
||||
<div v-for="(item, index) in inventory.details" :key="index">
|
||||
<el-row>
|
||||
<el-col :span="8" style="margin-right: 10px">
|
||||
<el-col :span="6" style="margin-right: 10px">
|
||||
<el-form-item
|
||||
class="warehouse"
|
||||
label="仓库:"
|
||||
:prop="'details.' + index + '.warehouse'"
|
||||
>
|
||||
<el-select v-model="item.warehouse" size="small">
|
||||
<el-option
|
||||
v-for="item in warehouseData"
|
||||
:key="item.value"
|
||||
:value="item.value"
|
||||
:label="item.label"
|
||||
>
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<el-col :span="6" style="margin-right: 10px">
|
||||
<el-form-item
|
||||
class="material"
|
||||
label="物料:"
|
||||
|
@ -163,7 +154,8 @@
|
|||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8" style="margin-right: 10px">
|
||||
|
||||
<el-col :span="6" style="margin-right: 10px">
|
||||
<el-form-item
|
||||
class="count"
|
||||
label="数量"
|
||||
|
@ -245,6 +237,7 @@ import {
|
|||
getfifoList,
|
||||
createInventory,
|
||||
getWarehouseList,
|
||||
deleteFifoitem,
|
||||
audit,
|
||||
} from "@/api/inm";
|
||||
import checkPermission from "@/utils/permission";
|
||||
|
@ -255,6 +248,7 @@ import Pagination from "@/components/Pagination"; // secondary package based on
|
|||
const defaulteinventory = {
|
||||
details: [
|
||||
{
|
||||
warehouse:"",//仓库
|
||||
material: "", // 物料
|
||||
count: "", //数量
|
||||
batch: "", //批次
|
||||
|
@ -281,7 +275,7 @@ export default {
|
|||
},
|
||||
warehouseData: [],
|
||||
materialoptions: [],
|
||||
userData: [],
|
||||
|
||||
listLoading: true,
|
||||
dialogVisible: false,
|
||||
dialogType: "new",
|
||||
|
@ -295,7 +289,7 @@ export default {
|
|||
created() {
|
||||
this.getlists();
|
||||
this.getList();
|
||||
this.getUser();
|
||||
|
||||
this.getmaterialList();
|
||||
},
|
||||
methods: {
|
||||
|
@ -324,16 +318,11 @@ export default {
|
|||
this.listLoading = false;
|
||||
});
|
||||
},
|
||||
getUser() {
|
||||
getUserList({ page: 0 }).then((res) => {
|
||||
if (res.data) {
|
||||
this.userData = genTree(res.data);
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
addConditions() {
|
||||
if (this.inventory.details.length <= 10) {
|
||||
this.inventory.details.push({
|
||||
warehouse:"",//仓库
|
||||
material: "", // 物料
|
||||
count: "", //数量
|
||||
batch: "", // 批次
|
||||
|
@ -358,6 +347,7 @@ export default {
|
|||
handleCreate() {
|
||||
this.inventory.details = [
|
||||
{
|
||||
warehouse:"", // 仓库
|
||||
material: "", // 物料
|
||||
count: "", //数量
|
||||
batch: "", //批次
|
||||
|
@ -375,7 +365,7 @@ export default {
|
|||
this.$confirm("是否通过?", "提示", {
|
||||
confirmButtonText: "确认",
|
||||
cancelButtonText: "取消",
|
||||
type: "error",
|
||||
type: 'success',
|
||||
})
|
||||
.then(async () => {
|
||||
await audit(scope.row.id);
|
||||
|
@ -409,6 +399,22 @@ export default {
|
|||
}
|
||||
});
|
||||
},
|
||||
handleDelete(scope) {
|
||||
this.$confirm("确认删除?", "警告", {
|
||||
confirmButtonText: "确认",
|
||||
cancelButtonText: "取消",
|
||||
type: "error",
|
||||
})
|
||||
.then(async () => {
|
||||
await deleteFifoitem(scope.row.id);
|
||||
this.getList();
|
||||
this.$message.success("成功");
|
||||
})
|
||||
.catch((err) => {
|
||||
console.error(err);
|
||||
});
|
||||
},
|
||||
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
|
|
@ -204,7 +204,7 @@
|
|||
import { getfifodetailList } from "@/api/inm";
|
||||
import checkPermission from "@/utils/permission";
|
||||
import { getMaterialList, getrecordformList, getrffieldList } from "@/api/mtm";
|
||||
import { createTestrecord } from "@/api/qm";
|
||||
import { createTestrecord } from "@/api/inm";
|
||||
import { getUserList } from "@/api/user";
|
||||
import { genTree } from "@/utils";
|
||||
import Pagination from "@/components/Pagination"; // secondary package based on el-pagination
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<el-card >
|
||||
<el-row :gutter="24">
|
||||
<el-col :span="6" >
|
||||
<el-card >
|
||||
|
@ -390,9 +391,6 @@
|
|||
<template slot-scope="scope">{{ scope.row.material_.unit }}</template>
|
||||
</el-table-column>
|
||||
|
||||
<el-table-column label="单位消耗量" min-width="100">
|
||||
<template slot-scope="scope">{{ scope.row.count }}</template>
|
||||
</el-table-column>
|
||||
|
||||
|
||||
|
||||
|
@ -628,6 +626,7 @@
|
|||
</el-tabs>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-card >
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
|
|
|
@ -18,52 +18,53 @@
|
|||
|
||||
|
||||
|
||||
<el-table-column label="生产计划编号">
|
||||
<el-table-column label="生产计划编号" width="110">
|
||||
<template slot-scope="scope">{{ scope.row.number }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="生产订单编号">
|
||||
<el-table-column label="生产订单编号" width="110">
|
||||
<template slot-scope="scope">{{ scope.row.order_.number }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="合同编号">
|
||||
<el-table-column label="合同编号" width="110">
|
||||
<template slot-scope="scope">{{ scope.row.order_.contract_.number }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="客户名称">
|
||||
<el-table-column label="客户名称" width="110" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.order_.customer_.name }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="产品名称" width="130">
|
||||
<el-table-column label="产品名称" width="150" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.product_.number }}-{{ scope.row.product_.name }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="产品型号">
|
||||
<el-table-column label="产品型号" width="110">
|
||||
<template slot-scope="scope">{{ scope.row.product_.specification }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="产品单位">
|
||||
<el-table-column label="产品单位" width="110">
|
||||
<template slot-scope="scope">{{ scope.row.product_.unit }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="生产数量" width="60">
|
||||
<el-table-column label="生产数量" width="110">
|
||||
<template slot-scope="scope">{{ scope.row.count }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="计划开工时间">
|
||||
<el-table-column label="计划开工时间" width="110">
|
||||
<template slot-scope="scope">{{ scope.row.start_date }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="计划完工时间">
|
||||
<el-table-column label="计划完工时间" width="110">
|
||||
<template slot-scope="scope">{{ scope.row.end_date }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="交付截止时间">
|
||||
<el-table-column label="交付截止时间" width="110">
|
||||
<template slot-scope="scope">{{ scope.row.order_.delivery_date }}</template>
|
||||
</el-table-column>
|
||||
|
||||
<el-table-column label="是否生成子计划" width="60">
|
||||
<el-table-column label="是否生成子计划" width="120">
|
||||
<template slot-scope="scope" >
|
||||
<el-tag v-if="scope.row.is_planed==false">否</el-tag>
|
||||
<el-tag v-if="scope.row.is_planed==true">是</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="创建时间">
|
||||
<el-table-column label="创建时间" width="160">
|
||||
<template slot-scope="scope">{{ scope.row.create_time }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
align="center"
|
||||
label="操作"
|
||||
fixed="right"
|
||||
width="100px"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
|
@ -101,29 +102,29 @@
|
|||
>
|
||||
<el-table-column type="index" width="50" />
|
||||
|
||||
<el-table-column label="订单编号">
|
||||
<el-table-column label="订单编号" width="110">
|
||||
<template slot-scope="scope">{{ scope.row.number }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="客户">
|
||||
<template slot-scope="scope">{{ scope.row.customer_.name }}</template>
|
||||
<el-table-column label="客户" width="110">
|
||||
<template slot-scope="scope" show-overflow-tooltip>{{ scope.row.customer_.name }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="所属合同">
|
||||
<el-table-column label="所属合同" show-overflow-tooltip width="110">
|
||||
<template slot-scope="scope">{{ scope.row.contract_.name }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="所需产品">
|
||||
<el-table-column label="所需产品" show-overflow-tooltip width="150">
|
||||
<template slot-scope="scope">{{ scope.row.product_.name }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="产品型号">
|
||||
<el-table-column label="产品型号" width="110">
|
||||
<template slot-scope="scope">{{ scope.row.product_.specification }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="所需数量">
|
||||
<el-table-column label="所需数量" width="110">
|
||||
<template slot-scope="scope">{{ scope.row.count }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="已派数量">
|
||||
<el-table-column label="已派数量" width="110">
|
||||
<template slot-scope="scope">{{ scope.row.planed_count }}</template>
|
||||
</el-table-column>
|
||||
|
||||
<el-table-column label="交货日期">
|
||||
<el-table-column label="交货日期" width="110">
|
||||
<template slot-scope="scope">{{ scope.row.delivery_date }}</template>
|
||||
</el-table-column>
|
||||
|
||||
|
|
|
@ -15,19 +15,21 @@
|
|||
border
|
||||
fit
|
||||
stripe
|
||||
style="width: 100%"
|
||||
highlight-current-row
|
||||
height="100"
|
||||
v-el-height-adaptive-table="{bottomOffset: 50}"
|
||||
>
|
||||
<el-table-column
|
||||
type="selection"
|
||||
width="55">
|
||||
</el-table-column>
|
||||
<el-table-column type="index" width="50" />
|
||||
|
||||
<el-table-column label="订单编号">
|
||||
|
||||
<el-table-column label="订单编号" width="110">
|
||||
<template slot-scope="scope">{{ scope.row.number }}</template>
|
||||
</el-table-column>
|
||||
|
||||
<el-table-column label="所需产品">
|
||||
<el-table-column label="所需产品" show-overflow-tooltip width="150">
|
||||
<template slot-scope="scope">{{ scope.row.product_.name }}</template>
|
||||
</el-table-column>
|
||||
|
||||
|
@ -37,7 +39,23 @@
|
|||
<el-table-column label="已派数量">
|
||||
<template slot-scope="scope">{{ scope.row.planed_count }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="计划生产数" width="140px">
|
||||
|
||||
<el-table-column label="产品型号">
|
||||
<template slot-scope="scope">{{ scope.row.product_.specification }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="客户" show-overflow-tooltip width="150">
|
||||
<template slot-scope="scope">{{ scope.row.customer_.name }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="所属合同" show-overflow-tooltip width="150">
|
||||
<template slot-scope="scope">{{ scope.row.contract_.name }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="交货日期" width="110">
|
||||
<template slot-scope="scope">{{ scope.row.delivery_date }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="创建时间" width="110">
|
||||
<template slot-scope="scope">{{ scope.row.create_time }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="计划生产数" width="150px" fixed="right">
|
||||
<template slot-scope="scope" >
|
||||
<el-form :model="scope.row">
|
||||
<el-form-item size="mini">
|
||||
|
@ -46,23 +64,8 @@
|
|||
</el-form>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="产品型号">
|
||||
<template slot-scope="scope">{{ scope.row.product_.specification }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="客户">
|
||||
<template slot-scope="scope">{{ scope.row.customer_.name }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="所属合同">
|
||||
<template slot-scope="scope">{{ scope.row.contract_.name }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="交货日期">
|
||||
<template slot-scope="scope">{{ scope.row.delivery_date }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="创建时间">
|
||||
<template slot-scope="scope">{{ scope.row.create_time }}</template>
|
||||
</el-table-column>
|
||||
|
||||
</el-table>
|
||||
|
||||
<pagination
|
||||
v-show="orderList.count > 0"
|
||||
:total="orderList.count"
|
||||
|
|
|
@ -145,10 +145,10 @@
|
|||
|
||||
|
||||
|
||||
<el-table-column label="预计消耗/产出">
|
||||
<el-table-column label="预计产出/消耗">
|
||||
<template slot-scope="scope">{{ scope.row.count }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="实际消耗/产出">
|
||||
<el-table-column label="实际产出/消耗">
|
||||
<template slot-scope="scope">{{ scope.row.count_real }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="生产计划编号">
|
||||
|
@ -271,7 +271,7 @@ export default {
|
|||
this.$confirm("确定下达子计划?", "提醒", {
|
||||
confirmButtonText: "确认",
|
||||
cancelButtonText: "取消",
|
||||
type: "error",
|
||||
type: "warning",
|
||||
})
|
||||
.then(async () => {
|
||||
await issuesubplan(scope.row.id).then((res) => {
|
||||
|
|
|
@ -34,37 +34,38 @@
|
|||
<el-table
|
||||
v-loading="listLoading"
|
||||
:data="contractList.results"
|
||||
border
|
||||
border
|
||||
fit
|
||||
stripe
|
||||
highlight-current-row
|
||||
max-height="600"
|
||||
height="100"
|
||||
v-el-height-adaptive-table="{bottomOffset: 50}"
|
||||
>
|
||||
<el-table-column type="index" width="50" />
|
||||
<el-table-column label="合同名称">
|
||||
<el-table-column label="合同名称" width="130" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.name }}</template>
|
||||
</el-table-column>
|
||||
|
||||
<el-table-column label="合同编号">
|
||||
<el-table-column label="合同编号" width="130">
|
||||
<template slot-scope="scope">{{ scope.row.number }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="合同金额(元)">
|
||||
<el-table-column label="合同金额(元)" width="130">
|
||||
<template slot-scope="scope">{{ scope.row.amount }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="开票金额(元)">
|
||||
<el-table-column label="开票金额(元)" width="130">
|
||||
<template slot-scope="scope">{{ scope.row.invoice }}</template>
|
||||
</el-table-column>
|
||||
|
||||
<el-table-column label="客户名称">
|
||||
<el-table-column label="客户名称" width="130" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.customer_.name }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="签订日期">
|
||||
<el-table-column label="签订日期" width="130">
|
||||
<template slot-scope="scope">{{ scope.row.sign_date }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="描述">
|
||||
<el-table-column label="描述" width="130" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.description }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="创建时间">
|
||||
<el-table-column label="创建时间" width="160">
|
||||
<template slot-scope="scope">{{ scope.row.create_time }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
|
|
|
@ -38,32 +38,33 @@
|
|||
fit
|
||||
stripe
|
||||
highlight-current-row
|
||||
max-height="600"
|
||||
height="100"
|
||||
v-el-height-adaptive-table="{bottomOffset: 50}"
|
||||
>
|
||||
<el-table-column type="index" width="50" />
|
||||
<el-table-column label="客户名称">
|
||||
<el-table-column label="客户名称" width="200" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.name }}</template>
|
||||
</el-table-column>
|
||||
|
||||
<el-table-column label="详细地址">
|
||||
<el-table-column label="详细地址" width="200" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.address }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="联系人">
|
||||
<el-table-column label="联系人" width="130" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.contact }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="联系电话">
|
||||
<el-table-column label="联系电话" width="130" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.contact_phone }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="描述">
|
||||
<el-table-column label="描述" width="200" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.description }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="创建时间">
|
||||
<el-table-column label="创建时间" width="160" >
|
||||
<template slot-scope="scope">{{ scope.row.create_time }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
align="center"
|
||||
label="操作"
|
||||
width="220px"
|
||||
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
|
||||
|
|
|
@ -38,38 +38,40 @@
|
|||
fit
|
||||
stripe
|
||||
highlight-current-row
|
||||
max-height="600"
|
||||
height="100"
|
||||
v-el-height-adaptive-table="{bottomOffset: 50}"
|
||||
>
|
||||
<el-table-column type="index" width="50" />
|
||||
|
||||
<el-table-column label="订单编号">
|
||||
<el-table-column label="订单编号" width="160" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.number }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="客户">
|
||||
<el-table-column label="客户" width="200" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.customer_.name }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="所属合同">
|
||||
<el-table-column label="所属合同" width="200" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.contract_.name }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="所需产品">
|
||||
<el-table-column label="所需产品" width="200" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.product_.name }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="产品型号">
|
||||
<el-table-column label="产品型号" width="120" show-overflow-tooltip>
|
||||
<template slot-scope="scope">{{ scope.row.product_.specification }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="所需数量">
|
||||
<el-table-column label="所需数量" width="90" >
|
||||
<template slot-scope="scope">{{ scope.row.count }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="交货日期">
|
||||
<el-table-column label="交货日期" width="150" >
|
||||
<template slot-scope="scope">{{ scope.row.delivery_date }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="创建时间">
|
||||
<el-table-column label="创建时间" width="160" >
|
||||
<template slot-scope="scope">{{ scope.row.create_time }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
align="center"
|
||||
label="操作"
|
||||
width="220px"
|
||||
fixed="right"
|
||||
width="130"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
|
||||
|
|
|
@ -32,16 +32,8 @@
|
|||
}}</template>
|
||||
</el-table-column>
|
||||
|
||||
<el-table-column label="工序名">
|
||||
<template slot-scope="scope">{{
|
||||
scope.row.process_.name
|
||||
}}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="工序编号">
|
||||
<template slot-scope="scope">{{
|
||||
scope.row.process_.number
|
||||
}}</template>
|
||||
</el-table-column>
|
||||
|
||||
|
||||
|
||||
<el-table-column label="子工序" width="160">
|
||||
<template slot-scope="scope" v-if="scope.row.steps">
|
||||
|
@ -70,6 +62,11 @@
|
|||
<el-tag v-if="scope.row.is_picked == false">未领料</el-tag>
|
||||
<el-tag v-else>已领料</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="生产主产品">
|
||||
<template slot-scope="scope" v-if="main_product">{{
|
||||
scope.row.main_product_.name
|
||||
}}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="生产进度">
|
||||
<template slot-scope="scope">{{ scope.row.main_count_real }}/{{scope.row.main_count}}</template>
|
||||
|
@ -191,37 +188,7 @@
|
|||
</el-tab-pane>
|
||||
</el-tabs>
|
||||
|
||||
<el-dialog
|
||||
:visible.sync="dialogVisible"
|
||||
:title="dialogType === 'edit' ? '编辑领料' : '选择仓库领料'"
|
||||
>
|
||||
<el-form
|
||||
ref="Form"
|
||||
:model="need"
|
||||
label-width="80px"
|
||||
label-position="right"
|
||||
>
|
||||
<el-form-item label="仓库" prop="warehouse">
|
||||
<el-select
|
||||
style="width: 100%"
|
||||
v-model="need.warehouse"
|
||||
placeholder="请选择"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in warehouseoptions"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
>
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div style="text-align: right">
|
||||
<el-button type="danger" @click="dialogVisible = false">取消</el-button>
|
||||
<el-button type="primary" @click="confirm('Form')">确认</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
|
||||
<el-dialog :visible.sync="dialogVisiblenw" title="领料">
|
||||
<el-card class="box-card">
|
||||
<div slot="header" class="clearfix">
|
||||
|
@ -261,8 +228,7 @@
|
|||
<el-table-column prop="material_.name" label="物料名称">
|
||||
</el-table-column>
|
||||
<el-table-column prop="warehouse_.name" label="物料所在仓库">
|
||||
</el-table-column
|
||||
>\
|
||||
</el-table-column>
|
||||
<el-table-column prop="count" label="物料总数量"> </el-table-column>
|
||||
<el-table-column label="输入领料数量" width="140px">
|
||||
<template slot-scope="scope">
|
||||
|
@ -271,7 +237,6 @@
|
|||
<el-input-number
|
||||
v-model="scope.row.pick_count"
|
||||
:min="0"
|
||||
:precision="2"
|
||||
:controls="false"
|
||||
:value="0"
|
||||
></el-input-number>
|
||||
|
@ -312,11 +277,11 @@
|
|||
</el-steps>
|
||||
<el-row :gutter="24">
|
||||
<el-col :span="12">
|
||||
<el-card class="box-card" v-if="values === 0">
|
||||
<div slot="header" class="clearfix">
|
||||
<el-card class="box-card" v-if="showPrise1&&values === 0">
|
||||
<div slot="header" class="clearfix" >
|
||||
<span>消耗物料表</span>
|
||||
</div>
|
||||
<el-table :data="input" border style="width: 100%">
|
||||
|
||||
<el-table :data="input" border style="width: 100%">
|
||||
<el-table-column
|
||||
prop="material__name"
|
||||
label="物料名称"
|
||||
|
@ -324,7 +289,7 @@
|
|||
>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="material__batch"
|
||||
prop="batch"
|
||||
label="物料批次"
|
||||
width="180"
|
||||
>
|
||||
|
@ -345,16 +310,17 @@
|
|||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</div>
|
||||
</el-card>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-card class="box-card" v-if="values === 0">
|
||||
<div slot="header" class="clearfix">
|
||||
<el-card class="box-card" v-if="values === 0&&showPrise">
|
||||
<div slot="header" class="clearfix" >
|
||||
<span>产出物料表</span>
|
||||
</div>
|
||||
|
||||
<el-table
|
||||
:data="output"
|
||||
v-if="showPrise"
|
||||
|
||||
border
|
||||
style="width: 100%"
|
||||
>
|
||||
|
@ -379,6 +345,7 @@
|
|||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</div>
|
||||
</el-card>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
@ -391,7 +358,12 @@
|
|||
<el-input v-model="remark" width="300"></el-input>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
|
||||
<el-button
|
||||
style="margin-top: 12px"
|
||||
@click="next"
|
||||
v-if="values == 0 "
|
||||
>下一步</el-button
|
||||
>
|
||||
</el-card>
|
||||
<el-card
|
||||
class="box-card"
|
||||
|
@ -495,21 +467,23 @@
|
|||
</el-form-item>
|
||||
</el-row>
|
||||
</el-form>
|
||||
</el-card>
|
||||
|
||||
<el-button
|
||||
<el-button
|
||||
style="margin-top: 12px"
|
||||
@click="next"
|
||||
v-if="values == 0 || values == 1 || values == 2"
|
||||
v-if=" values == $index+2"
|
||||
>下一步</el-button
|
||||
>
|
||||
<el-button
|
||||
<el-button
|
||||
style="margin-top: 12px"
|
||||
@click="prev"
|
||||
v-if="values == 1 || values == 2 || values == 3"
|
||||
v-if="values == $index+1"
|
||||
>上一步</el-button
|
||||
>
|
||||
<div style="text-align: right">
|
||||
</el-card>
|
||||
|
||||
|
||||
|
||||
<div style="text-align: right;position:sticky">
|
||||
<el-button type="danger" @click="dialogVisiblework = false"
|
||||
>取消</el-button
|
||||
>
|
||||
|
@ -553,6 +527,7 @@ export default {
|
|||
havewl: "",
|
||||
needwl: "",
|
||||
showPrise: false,
|
||||
showPrise1:false,
|
||||
state_: {
|
||||
0: "制定中",
|
||||
1: "已下达",
|
||||
|
@ -563,7 +538,7 @@ export default {
|
|||
listLoading: true,
|
||||
listLoading: true,
|
||||
id: "",
|
||||
warehouseoptions: [],
|
||||
|
||||
dialogVisible: false,
|
||||
dialogType: "new",
|
||||
dialogVisiblework: false,
|
||||
|
@ -599,7 +574,6 @@ export default {
|
|||
watch: {},
|
||||
created() {
|
||||
this.getProcessList();
|
||||
this.getWarehouseLists();
|
||||
},
|
||||
methods: {
|
||||
checkPermission,
|
||||
|
@ -651,52 +625,41 @@ export default {
|
|||
});
|
||||
},
|
||||
|
||||
getWarehouseLists() {
|
||||
getWarehouseList({ page: 0 }).then((response) => {
|
||||
if (response.data) {
|
||||
this.warehouseoptions = response.data;
|
||||
}
|
||||
this.listLoading = false;
|
||||
});
|
||||
},
|
||||
|
||||
//领料
|
||||
handleNeed(scope) {
|
||||
this.need = Object.assign({}, defaulteneed);
|
||||
this.dialogType = "new";
|
||||
this.dialogVisible = true;
|
||||
this.dialogVisiblenw = true;
|
||||
this.id = scope.row.id;
|
||||
this.$nextTick(() => {
|
||||
this.$refs["Form"].clearValidate();
|
||||
});
|
||||
},
|
||||
async confirm(form) {
|
||||
createPick_need(this.id, this.need).then((res) => {
|
||||
if (res.code >= 200) {
|
||||
this.dialogVisible = false;
|
||||
this.dialogVisiblenw = true;
|
||||
this.havewl = res.data.have;
|
||||
this.needwl = res.data.need;
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
//确认领料
|
||||
handlePick() {
|
||||
let _this = this;
|
||||
_this.picks = []; //所需物料
|
||||
this.$refs.multipleTable.selection.forEach((item) => {
|
||||
_this.picks.push({
|
||||
warehouse:item.warehouse,
|
||||
material: item.material,
|
||||
batch: item.batch,
|
||||
pick_count: item.pick_count,
|
||||
});
|
||||
});
|
||||
this.pickData.subproduction_plan = this.id;
|
||||
this.pickData.warehouse = this.need.warehouse;
|
||||
this.pickData.picks = this.picks;
|
||||
|
||||
// console.log(this.pickData);
|
||||
|
||||
createPick(this.pickData).then((res) => {
|
||||
if (res.code >= 200) {
|
||||
this.dialogVisiblenw = false;
|
||||
|
||||
this.$message.success("领料成功!");
|
||||
}
|
||||
});
|
||||
|
@ -719,6 +682,7 @@ export default {
|
|||
handlework(item) {
|
||||
this.step = item.id;
|
||||
// console.log(this.wpID);
|
||||
this.values=0;
|
||||
createWork({
|
||||
step: item.id,
|
||||
wproducts: this.wpID,
|
||||
|
@ -730,14 +694,26 @@ export default {
|
|||
this.otherforms = res.data.forms.slice(0); //渲染生产表
|
||||
this.otherforms.shift();
|
||||
//console.log(this.otherforms)
|
||||
this.input = res.data.forms[0].input; //消耗
|
||||
if (
|
||||
res.data.forms[0].output !== undefined &&
|
||||
res.data.forms[0].output.length > 0
|
||||
) {
|
||||
|
||||
if ( res.data.forms[0].input !== undefined && res.data.forms[0].input.length > 0 )
|
||||
{
|
||||
this.input = res.data.forms[0].input; //消耗
|
||||
this.showPrise1 = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
this.showPrise1 = false;
|
||||
}
|
||||
if ( res.data.forms[0].output !== undefined && res.data.forms[0].output.length > 0 )
|
||||
{
|
||||
this.output = res.data.forms[0].output; //产出
|
||||
this.showPrise = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
this.showPrise = false;
|
||||
}
|
||||
|
||||
|
||||
this.wproducts = res.data.forms[0].wproducts;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue