Commit 3c90421a authored by chenzj's avatar chenzj

生产方案功能

parent bd52093c
......@@ -3,7 +3,7 @@ import request from '@/utils/request'
// 查询生产方案列表
export function listProductionSolution(query) {
return request({
url: '/mes/pro/productionSolution/list',
url: 'pro/productionSolution/list',
method: 'get',
params: query
})
......@@ -12,7 +12,7 @@ export function listProductionSolution(query) {
// 查询生产方案详细
export function getProductionSolution(productionSolutionId) {
return request({
url: '/mes/pro/productionSolution/' + productionSolutionId,
url: 'pro/productionSolution/' + productionSolutionId,
method: 'get'
})
}
......@@ -20,7 +20,7 @@ export function getProductionSolution(productionSolutionId) {
// 新增生产方案
export function addProductionSolution(data) {
return request({
url: '/mes/pro/productionSolution',
url: 'pro/productionSolution',
method: 'post',
data: data
})
......@@ -29,7 +29,7 @@ export function addProductionSolution(data) {
// 修改生产方案
export function updateProductionSolution(data) {
return request({
url: '/mes/pro/productionSolution',
url: 'pro/productionSolution',
method: 'put',
data: data
})
......@@ -38,7 +38,7 @@ export function updateProductionSolution(data) {
// 删除生产方案
export function delProductionSolution(productionSolutionId) {
return request({
url: '/mes/pro/productionSolution/' + productionSolutionId,
url: 'pro/productionSolution/' + productionSolutionId,
method: 'delete'
})
}
......@@ -8,19 +8,19 @@
v-show="showSearch"
label-width="100px"
>
<el-form-item label="产品名称" prop="itemName">
<el-form-item label="生产方案名称" prop="productionSolutionName">
<el-input
v-model="queryParams.itemName"
placeholder="请输入产品名称"
placeholder="请输入方案名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="单据状态" prop="prototypeRequestStatus">
<el-form-item label="生产用途" prop="usageName">
<el-select
v-model="queryParams.prototypeRequestStatus"
clearable
placeholder="请选择单据状态"
placeholder="请输入生产用途"
>
<el-option
v-for="item in options"
......@@ -61,7 +61,7 @@
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<!-- <el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
......@@ -71,9 +71,9 @@
@click="handleAdd"
v-hasPermi="['mes:pro:prototypeRequest:add']"
>新增</el-button
>
</el-col>
<el-col :span="1.5">
>
</el-col>-->
<!-- <el-col :span="1.5">
<el-button
type="success"
plain
......@@ -83,9 +83,9 @@
@click="handleUpdate"
v-hasPermi="['mes:pro:prototypeRequest:edit']"
>修改</el-button
>
</el-col>
<el-col :span="1.5">
>
</el-col>-->
<!-- <el-col :span="1.5">
<el-button
type="danger"
plain
......@@ -96,8 +96,8 @@
v-hasPermi="['mes:pro:prototypeRequest:remove']"
>删除</el-button
>
</el-col>
<el-col :span="1.5">
</el-col> -->
<!-- <el-col :span="1.5">
<el-button
type="warning"
plain
......@@ -107,83 +107,41 @@
v-hasPermi="['mes:pro:prototypeRequest:export']"
>导出</el-button
>
</el-col>
<right-toolbar
</el-col> -->
<!-- <right-toolbar
:showSearch.sync="showSearch"
@queryTable="getList"
></right-toolbar>
</el-row>
</el-row> -->
<el-table
v-loading="loading"
:data="prototypeRequestList"
row-key="prototypeRequestId"
default-expand-all
>
<el-table-column label="样品编码" width="180" prop="prototypeRequestCode">
<el-table v-loading="loading" :data="productionSolutionList" row-key="productionSolutionId" default-expand-all >
<el-table-column label="生产方案编码" prop="productionSolutionCode">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
@click="handleView(scope.row)"
v-hasPermi="['mes:pro:prototypeRequest:query']"
>{{ scope.row.prototypeRequestCode }}</el-button
v-hasPermi="['mes:pro:productionSolutionCode:query']"
>{{ scope.row.productionSolutionCode }}</el-button
>
</template>
</el-table-column>
<el-table-column
label="产品名称"
width="120"
align="center"
prop="itemName"
:show-overflow-tooltip="true"
<el-table-column label="产品方案名称" align="center" prop="productionSolutionName" :show-overflow-tooltip="true"
/>
<el-table-column label="工艺路线名称" align="center" prop="routeName">
</el-table-column>
<el-table-column
label="计划完成日期"
align="center"
prop="plannedFinishDate"
width="180"
>
<template slot-scope="scope">
<span>{{
parseTime(scope.row.plannedFinishDate, "{y}-{m}-{d}")
}}</span>
</template>
</el-table-column>
<el-table-column
label="版面需求时间"
align="center"
prop="plannedLayoutDate"
width="180"
>
<template slot-scope="scope">
<span>{{
parseTime(scope.row.plannedLayoutDate, "{y}-{m}-{d}")
}}</span>
</template>
</el-table-column>
<el-table-column
label="申请单状态"
align="center"
prop="prototypeRequestStatus"
>
<template slot-scope="scope">
<dict-tag
:options="dict.type.mes_pr_status"
:value="scope.row.prototypeRequestStatus"
/>
</template>
</el-table-column>
<el-table-column label="备注" align="center" prop="remark" />
<el-table-column
<el-table-column label="生产用途" align="center" prop="usageName" />
<el-table-column label="备注" align="center" prop="remark" />
<!-- <el-table-column label="备注" align="center" prop="usageName" width="180"/> -->
<!-- <el-table-column
label="操作"
width="200px"
align="center"
class-name="small-padding fixed-width"
>
<template slot-scope="scope">
/> -->
<!-- <template slot-scope="scope">
<el-button
size="mini"
type="text"
......@@ -192,8 +150,8 @@
@click="handleUpdate(scope.row)"
v-hasPermi="['mes:pro:prototypeRequest:edit']"
>修改</el-button
>
<el-button
> -->
<!-- <el-button
size="mini"
type="text"
icon="el-icon-circle-check"
......@@ -201,16 +159,16 @@
@click="handleFinish(scope.row)"
v-hasPermi="['mes:pro:prototypeRequest:update']"
>通过</el-button
>
<el-button
> -->
<!-- <el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['mes:pro:prototypeRequest:remove']"
>删除</el-button
>
<el-button
> -->
<!-- <el-button
size="mini"
type="text"
icon="el-icon-edit"
......@@ -218,9 +176,9 @@
@click="generatea(scope.row)"
v-hasPermi="['mes:pro:prototypeRequest:edit']"
>生成制作单</el-button
>
</template>
</el-table-column>
> -->
<!-- </template> -->
<!-- </el-table-column>-->
</el-table>
<pagination
v-show="total > 0"
......@@ -230,17 +188,23 @@
@pagination="getList"
/>
</div>
</template>
<script>
import {
listPrototypeRequest,
getPrototypeRequest,
delPrototypeRequest,
addPrototypeRequest,
updatePrototypeRequest,
dofinish,
} from "@/api/mes/pro/prototypeRequest";
// listPrototypeRequest,
// getPrototypeRequest,
// delPrototypeRequest,
// addPrototypeRequest,
// updatePrototypeRequest,
// dofinish,
listProductionSolution,
getProductionSolution,
addProductionSolution,
updateProductionSolution,
delProductionSolution,
} from "@/api/mes/pro/productionSolution";
import ItemSelect from "@/components/itemSelect/single.vue";
import ClientSelect from "@/components/clientSelect/single.vue";
import VendorSelect from "@/components/vendorSelect/single.vue";
......@@ -289,8 +253,17 @@ export default {
queryParams: {
pageNum: 1,
pageSize: 10,
itemName: null, // 可以查简称与英文名
prototypeRequestStatus: null,
productionSolutionId: null, // 可以查简称与英文名
productionSolutionCode: null,
productionSolutionName: null,
itemId: null,
routeId: null,
usageId: null,
remark: null,
createBy: null,
createTime: null,
updateBy: null,
updateTime: null,
},
options: [
// { value: null, label: "全部订单" },
......@@ -319,8 +292,8 @@ export default {
/** 查询生产工单列表 */
getList() {
this.loading = true;
listPrototypeRequest(this.queryParams).then((response) => {
this.prototypeRequestList = response.rows;
listProductionSolution(this.queryParams).then((response) => {
this.productionSolutionList = response.rows;
this.total = response.total;
this.loading = false;
});
......@@ -333,23 +306,12 @@ export default {
// 表单重置
reset() {
this.form = {
prototypeRequestId: null,
prototypeRequestCode: null,
productionSolutionId: null,
productionSolutionCode: null,
productionSolutionName: null,
itemId: null,
itemName: null,
routeId: null,
routeName: null,
abbreviation: null,
enName: null,
num: null,
type: null,
modality: null,
surfaceTreatment: null,
ngReason: null,
plannedFinishDate: null,
plannedLayoutDate: null,
prototypeRequestStatus: null,
testStandard: null,
usageId: null,
remark: null,
createBy: null,
createTime: null,
......@@ -390,9 +352,9 @@ export default {
// 查询明细按钮操作
handleView(row) {
this.reset();
const prototypeRequestId = row.prototypeRequestId || this.ids;
const productionSolutionId = row.productionSolutionId || this.ids;
this.$router.push(
"/mes/proofing/info?prototypeRequestId=" + prototypeRequestId
"/mes/pro/productionSolution/info?productionSolutionId=" + productionSolutionId
);
// getprototypeRequest(prototypeRequestId).then((response) => {
// this.form = response.data;
......
......@@ -36,7 +36,14 @@
<el-col :md="8" :xs="12">
<el-form-item label="申请单编码" prop="prototypeRequestCode">
<el-input disabled v-model="form.prototypeRequestCode"></el-input>
<el-input
v-model="form.prototypeRequestCode"
readonly
disabled
:placeholder="mode=='edit' ? '':'请输入申请单编码'"
>
</el-input>
</el-form-item>
</el-col>
<el-col :md="8" :xs="12" style="height: 50.5px">
......@@ -45,7 +52,7 @@
v-model="form.itemName"
readonly
disabled
placeholder="请选择产品"
:placeholder="mode=='edit' ? '':'请选择产品'"
/>
<!-- <el-button
slot="append"
......@@ -64,7 +71,7 @@
v-model="form.routeName"
readonly
disabled
placeholder="请选择工艺路线"
:placeholder="mode=='edit' ? '':'请选择工艺路线'"
/>
<!-- <el-button
slot="append"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment