Commit bfc8afc1 authored by 何远江's avatar 何远江

页面样式调整

parent 130d00b5
......@@ -16,7 +16,7 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="品牌名称" prop="brandName">
<el-form-item label="品牌名称" prop="brandName">
<el-input
v-model="queryParams.brandName"
placeholder="请输入品牌名称"
......@@ -136,7 +136,11 @@
row-key="brandQuotationId"
default-expand-all
>
<el-table-column label="品牌报价单编码" width="180" prop="brandQuotationCode">
<el-table-column
label="品牌报价单编码"
width="140"
prop="brandQuotationCode"
>
<template slot-scope="scope">
<el-button
size="mini"
......@@ -149,13 +153,18 @@
</el-table-column>
<el-table-column
label="品牌报价名称"
width="180"
align="center"
prop="brandQuotationName"
:show-overflow-tooltip="true"
/>
<el-table-column label="金额" width="180" align="center" prop="amount" :formatter="r => this.formatMoney(r.amount)"/>
<el-table-column
<el-table-column
label="金额"
width="120"
align="center"
prop="amount"
:formatter="(r) => this.formatMoney(r.amount)"
/>
<el-table-column
label="品牌名称"
width="120"
align="center"
......@@ -169,12 +178,13 @@
prop="itemName"
:show-overflow-tooltip="true"
/>
<el-table-column label="工艺路线名称" align="center" prop="routeName">
<el-table-column show-overflow-tooltip label="工艺路线名称" align="center" prop="routeName">
</el-table-column>
<el-table-column label="备注" align="center" prop="remark" />
<el-table-column show-overflow-tooltip label="备注" align="center" prop="remark" />
<el-table-column
label="操作"
width="200px"
fixed="right"
align="center"
class-name="small-padding fixed-width"
>
......@@ -241,7 +251,13 @@ import Treeselect from "@riophae/vue-treeselect";
import "@riophae/vue-treeselect/dist/vue-treeselect.css";
//导入品牌报价js
import { listBrandQuotation, getBrandQuotation, delBrandQuotation, addBrandQuotation, updateBrandQuotation } from "@/api/mes/dv/brandquotation";
import {
listBrandQuotation,
getBrandQuotation,
delBrandQuotation,
addBrandQuotation,
updateBrandQuotation,
} from "@/api/mes/dv/brandquotation";
export default {
name: "PrototypeRequest",
......@@ -412,7 +428,9 @@ export default {
/** 删除按钮操作 */
handleDelete(row) {
this.$modal
.confirm('是否确认删除编号为"' + row.brandQuotationId + '"的品牌报价单?')
.confirm(
'是否确认删除编号为"' + row.brandQuotationId + '"的品牌报价单?'
)
.then(function () {
return delBrandQuotation(row.brandQuotationId);
})
......@@ -455,15 +473,14 @@ export default {
.catch(() => {});
},
// 生成制作单
generatea(row) {
// 跳转到制作单界面
const prototypeRequestId = row.prototypeRequestId || this.ids;
this.$router.push(
"/mes/pro/prototypeMake/apply?prototypeRequestId=" + prototypeRequestId
);
return;
},
generatea(row) {
// 跳转到制作单界面
const prototypeRequestId = row.prototypeRequestId || this.ids;
this.$router.push(
"/mes/pro/prototypeMake/apply?prototypeRequestId=" + prototypeRequestId
);
return;
},
},
};
</script>
<template>
<div class="form-page" v-loading="loading">
<div v-loading="loading">
<PageTitle>
{{ pageTitle }}
<!-- 申请按钮显示 -->
......@@ -24,9 +24,8 @@
label-width="100px"
>
<el-row>
<el-col :md="6" :sm="12" :xs="12">
<el-form-item prop="brandQuotationCode">
<template slot="label"> 编码 </template>
<el-col :lg="6" :md="8" :sm="12" :xs="12">
<el-form-item label="编码" prop="brandQuotationCode">
<el-input
disabled
v-model="form.brandQuotationCode"
......@@ -35,7 +34,7 @@
</el-form-item>
</el-col>
<el-col :md="6" :sm="12" :xs="12">
<el-col :lg="6" :md="8" :sm="12" :xs="12">
<el-form-item label="名称" prop="brandQuotationName">
<el-input
v-model="form.brandQuotationName"
......@@ -43,53 +42,17 @@
></el-input>
</el-form-item>
</el-col>
<el-col :md="6" :sm="12" :xs="12">
<el-col :lg="6" :md="8" :sm="12" :xs="12">
<el-form-item label="总金额" prop="amount">
<el-input-money
v-model="form.amount"
v-bind:disabled="form.brandQuotationId==0"
placeholder="新增时不可输入,请修改时操作"/>
<el-input-money
v-model="form.amount"
v-bind:disabled="form.brandQuotationId == 0"
placeholder="新增时不可输入,请修改时操作"
/>
</el-form-item>
</el-col>
<!-- <el-col :span="6">
<el-form-item label="品牌" prop="brandCode">
<el-input v-model="form.brandName" readonly="readonly">
<el-button
slot="append"
icon="el-icon-search"
@click="handleBrandSelect"
placeholder="请选择品牌"
></el-button>
</el-input>
</el-form-item>
<BrandSelect
ref="brSelect"
@onSelected="onBrandSelected"
></BrandSelect>
</el-col> -->
<!-- <el-col :span="6">
<el-form-item label="品牌名称" prop="brandName">
<el-input v-model="form.brandName" readonly="readonly" />
</el-form-item>
</el-col> -->
<!-- <el-col :span="8">
<el-form-item label="品牌编码" prop="brandCode">
<el-input v-model="form.brandCode" readonly="readonly">
<el-button
slot="append"
icon="el-icon-search"
@click="handleBrandSelect"
:disabled="form.brandContactId"
></el-button>
</el-input>
</el-form-item>
<BrandSelect
ref="brSelect"
@onSelected="onBrandSelected"
></BrandSelect>
</el-col> -->
<el-col :md="6" :sm="12" :xs="12">
<el-col :lg="6" :md="8" :sm="12" :xs="12">
<el-form-item label="产品" prop="itemId">
<el-input
v-model="form.itemName"
......@@ -106,13 +69,17 @@
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="品牌名称" prop="brandName">
<el-input v-model="form.brandName" placeholder="请先将所选产品绑定品牌" disabled/>
</el-form-item>
</el-col>
<el-col :lg="6" :md="8" :sm="12" :xs="12">
<el-form-item label="品牌名称" prop="brandName">
<el-input
v-model="form.brandName"
placeholder="请先将所选产品绑定品牌"
disabled
/>
</el-form-item>
</el-col>
<el-col :md="6" :sm="12" :xs="12">
<el-col :lg="6" :md="8" :sm="12" :xs="12">
<el-form-item label="工艺路线" prop="routeId">
<el-input
v-model="form.routeName"
......@@ -133,7 +100,7 @@
</el-col>
</el-row>
<el-row>
<el-col :md="24" :sm="12" :xs="12">
<el-col :lg="6" :md="8" :sm="12" :xs="12">
<el-form-item label="备注" prop="remark">
<el-input
type="textarea"
......@@ -174,10 +141,22 @@ import {
// 导入品牌选择框
import BrandSelect from "@/components/brandSelect/single.vue";
//导入品牌报价js
import { listBrandQuotation, getBrandQuotation, delBrandQuotation, addBrandQuotation, updateBrandQuotation } from "@/api/mes/dv/brandquotation";
import {
listBrandQuotation,
getBrandQuotation,
delBrandQuotation,
addBrandQuotation,
updateBrandQuotation,
} from "@/api/mes/dv/brandquotation";
export default {
components: { ProogingBom, ProogingProcess, ItemSelect, RoutesProcessSelect, BrandSelect },
components: {
ProogingBom,
ProogingProcess,
ItemSelect,
RoutesProcessSelect,
BrandSelect,
},
dicts: [],
provide() {
return {
......@@ -205,9 +184,13 @@ export default {
// 表单校验
rules: {
brandId: [
{ required: true, message: "品牌不能为空,请先查验所选产品是否已绑定品牌", trigger: "blur" }
],
}
{
required: true,
message: "品牌不能为空,请先查验所选产品是否已绑定品牌",
trigger: "blur",
},
],
},
};
},
computed: {
......@@ -229,11 +212,11 @@ export default {
created() {
this.getFormInfo();
if (this.mode == "apply") {
this.gCode();
this.gCode();
}
},
methods: {
//选择品牌
//选择品牌
handleBrandSelect() {
this.$refs.brSelect.showFlag = true;
},
......@@ -322,8 +305,11 @@ export default {
this.loading = false;
this.$modal.msgSuccess("提交成功!");
// 关闭页签
tabPlugins.closeOpenPage();
this.$nextTick(() => {
// 关闭页签
tabPlugins.closeOpenPage();
this.$router.replace({ path: "/mes/dv/brandquotation/query" });
});
})
.catch(() => {
this.loading = false;
......
......@@ -15,12 +15,12 @@
v-if="mode != 'info'"
label="操作"
align="center"
width="150"
width="300"
fixed="right"
>
<template slot-scope="{ row, $index }">
<el-button
type="text"
icon="el-icon-edit"
size="small"
@click="openSetProd(row, $index)"
>
......@@ -42,7 +42,6 @@
</el-button>
<el-button
type="text"
icon="el-icon-edit"
size="small"
@click="updateRow(row, $index)"
>修改</el-button
......
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form
:model="queryParams"
ref="queryForm"
size="small"
:inline="true"
v-show="showSearch"
label-width="68px"
>
<el-form-item label="订单编号" prop="orderNo">
<el-input
v-model="queryParams.orderNo"
......@@ -10,16 +17,30 @@
/>
</el-form-item>
<el-form-item label="客户" prop="clientId">
<el-select v-model="queryParams.clientId" placeholder="请选择客户" clearable filterable remote :remote-method="getClientList">
<el-option v-for="item in clientList" :key="item.clientId" :value="item.clientId" :label="item.clientName"/>
<el-select
v-model="queryParams.clientId"
placeholder="请选择客户"
clearable
filterable
remote
:remote-method="getClientList"
>
<el-option
v-for="item in clientList"
:key="item.clientId"
:value="item.clientId"
:label="item.clientName"
/>
</el-select>
</el-form-item>
<el-form-item label="交货日期" prop="deliveryDate">
<el-date-picker clearable
v-model="queryParams.deliveryDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择交货日期">
<el-date-picker
clearable
v-model="queryParams.deliveryDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择交货日期"
>
</el-date-picker>
</el-form-item>
<el-form-item label="状态" prop="state">
......@@ -39,8 +60,16 @@
/>
</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-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>
......@@ -53,39 +82,81 @@
size="mini"
@click="handleExport"
v-hasPermi="['md:purchaseOrder:export']"
>导出</el-button>
>导出</el-button
>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
<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" />
<el-table-column label="订单编号" prop="orderNo" />
<el-table-column label="客户编号" prop="clientNo" />
<el-table-column label="客户名称" prop="clientName" />
<el-table
v-loading="loading"
:data="orderList"
@selection-change="handleSelectionChange"
>
<!-- <el-table-column type="selection" width="55" /> -->
<el-table-column label="订单编号" prop="orderNo" width="160" />
<el-table-column label="客户编号" prop="clientNo" width="120" />
<el-table-column
label="客户名称"
prop="clientName"
width="240"
show-overflow-tooltip
/>
<el-table-column label="交货日期" prop="deliveryDate" width="180">
<template slot-scope="{row}">
<span>{{ parseTime(row.deliveryDate, '{y}-{m}-{d}') }}</span>
<template slot-scope="{ row }">
<span>{{ parseTime(row.deliveryDate, "{y}-{m}-{d}") }}</span>
</template>
</el-table-column>
<el-table-column label="备注" prop="remark" />
<el-table-column label="订单状态" prop="state">
<template slot-scope="{row}">
{{ dict.type.sales_order_state.find(item => item.value == row.state).label }}
<el-table-column label="备注" prop="remark" min-width="200" />
<el-table-column label="订单状态" prop="state" width="100">
<template slot-scope="{ row }">
{{
dict.type.sales_order_state.find((item) => item.value == row.state)
.label
}}
</template>
</el-table-column>
<el-table-column label="来源文件" prop="source" />
<el-table-column label="操作" class-name="small-padding fixed-width" width="200">
<template slot-scope="{row}">
<el-button v-hasPermi="['md:order:query']" size="mini" type="text" icon="el-icon-search" @click="onShowDetail(row)">查看</el-button>
<el-button v-hasPermi="['md:order:edit']" size="mini" type="text" icon="el-icon-edit" @click="toSalesEdit(row)">生成订单</el-button>
<el-button v-hasPermi="['md:order:remove']" size="mini" type="text" icon="el-icon-delete" @click="handleDelete(row)">删除</el-button>
<el-table-column
label="来源文件"
prop="source"
width="300"
show-overflow-tooltip
/>
<el-table-column label="操作" width="200" fixed="right">
<template slot-scope="{ row }">
<el-button
v-hasPermi="['md:order:query']"
size="mini"
type="text"
icon="el-icon-search"
@click="onShowDetail(row)"
>查看</el-button
>
<el-button
v-hasPermi="['md:order:edit']"
size="mini"
type="text"
icon="el-icon-edit"
@click="toSalesEdit(row)"
>生成订单</el-button
>
<el-button
v-hasPermi="['md:order:remove']"
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(row)"
>删除</el-button
>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
v-show="total > 0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
......@@ -94,43 +165,132 @@
<el-dialog :visible.sync="showDetail" title="采订单详情" width="1200px">
<el-table :data="detailList" max-height="600" size="mini">
<el-table-column label="产品名称" prop="itemName" show-overflow-tooltip width="120"/>
<el-table-column label="客户单号" prop="poOrderNo" show-overflow-tooltip/>
<el-table-column label="客户产品代码" prop="poProductName" show-overflow-tooltip/>
<el-table-column label="客户产品名称" prop="poProductNo" show-overflow-tooltip/>
<el-table-column label="宝绅内部品名" prop="productName" show-overflow-tooltip/>
<el-table-column label="客户单位" prop="customerUnit" show-overflow-tooltip/>
<el-table-column label="指令号" prop="cmdNo" show-overflow-tooltip/>
<el-table-column label="型体号" prop="featureNo" show-overflow-tooltip/>
<el-table-column label="配色号" prop="poColorNo" show-overflow-tooltip/>
<el-table-column label="客户颜色" prop="poColor" show-overflow-tooltip/>
<el-table-column label="客户单重" prop="poKg" show-overflow-tooltip/>
<el-table-column label="销线" prop="salePath" show-overflow-tooltip/>
<el-table-column label="段别" prop="segment" show-overflow-tooltip/>
<el-table-column label="版面" prop="layout" show-overflow-tooltip/>
<el-table-column label="季度" prop="quarter" show-overflow-tooltip/>
<el-table-column label="整/半码" prop="wholeYard" show-overflow-tooltip/>
<el-table-column label="特殊SIZE" prop="specialSize" show-overflow-tooltip/>
<el-table-column label="PO号" prop="poNo" show-overflow-tooltip/>
<el-table-column label="WIP号" prop="wipNo" show-overflow-tooltip/>
<el-table-column label="装箱数" prop="packingNum" show-overflow-tooltip/>
<el-table-column label="产地" prop="region" show-overflow-tooltip/>
<el-table-column label="周期" prop="cycle" show-overflow-tooltip/>
<el-table-column label="SK编号" prop="skNo" show-overflow-tooltip/>
<el-table-column label="专利号" prop="patentNo" show-overflow-tooltip/>
<el-table-column label="材质描述" prop="materialDesc" show-overflow-tooltip/>
<el-table-column label="签收人" prop="" show-overflow-tooltip/>
<el-table-column label="shipToId" prop="shipToId" show-overflow-tooltip/>
<el-table-column label="交货日期" prop="deliveryDate" show-overflow-tooltip/>
<el-table-column label="备注" prop="remark" show-overflow-tooltip/>
<el-table-column label="尺码组" prop="sizeGroup" show-overflow-tooltip/>
<el-table-column label="尺码" prop="size" show-overflow-tooltip/>
<el-table-column label="订单量" prop="orderNum" show-overflow-tooltip/>
<el-table-column label="条码" prop="barCode" show-overflow-tooltip/>
<el-table-column label="印刷方向" prop="printingDirection" show-overflow-tooltip/>
<el-table-column label="产品规格" prop="productSize" show-overflow-tooltip/>
<el-table-column
label="产品名称"
prop="itemName"
show-overflow-tooltip
width="300"
/>
<el-table-column
label="客户单号"
prop="poOrderNo"
width="140"
show-overflow-tooltip
/>
<el-table-column
label="客户产品代码"
width="140"
prop="poProductName"
show-overflow-tooltip
/>
<el-table-column
label="客户产品名称"
prop="poProductNo"
width="140"
show-overflow-tooltip
/>
<el-table-column
label="宝绅内部品名"
prop="productName"
width="140"
show-overflow-tooltip
/>
<el-table-column
label="客户单位"
prop="customerUnit"
width="120"
show-overflow-tooltip
/>
<el-table-column
label="指令号"
width="120"
prop="cmdNo"
show-overflow-tooltip
/>
<el-table-column
label="型体号"
prop="featureNo"
width="100"
show-overflow-tooltip
/>
<el-table-column
label="配色号"
prop="poColorNo"
show-overflow-tooltip
/>
<el-table-column
label="客户颜色"
prop="poColor"
show-overflow-tooltip
/>
<el-table-column label="客户单重" prop="poKg" show-overflow-tooltip />
<el-table-column label="销线" prop="salePath" show-overflow-tooltip />
<el-table-column label="段别" prop="segment" show-overflow-tooltip />
<el-table-column label="版面" prop="layout" show-overflow-tooltip />
<el-table-column label="季度" prop="quarter" show-overflow-tooltip />
<el-table-column
label="整/半码"
prop="wholeYard"
show-overflow-tooltip
/>
<el-table-column
label="特殊SIZE"
prop="specialSize"
show-overflow-tooltip
/>
<el-table-column label="PO号" prop="poNo" show-overflow-tooltip />
<el-table-column label="WIP号" prop="wipNo" show-overflow-tooltip />
<el-table-column
label="装箱数"
prop="packingNum"
show-overflow-tooltip
/>
<el-table-column label="产地" prop="region" show-overflow-tooltip />
<el-table-column label="周期" prop="cycle" show-overflow-tooltip />
<el-table-column
width="120"
label="SK编号"
prop="skNo"
show-overflow-tooltip
/>
<el-table-column label="专利号" prop="patentNo" show-overflow-tooltip />
<el-table-column
label="材质描述"
prop="materialDesc"
show-overflow-tooltip
/>
<el-table-column label="签收人" prop="" show-overflow-tooltip />
<el-table-column
label="shipToId"
prop="shipToId"
show-overflow-tooltip
/>
<el-table-column
label="交货日期"
prop="deliveryDate"
show-overflow-tooltip
/>
<el-table-column label="备注" prop="remark" show-overflow-tooltip />
<el-table-column
label="尺码组"
prop="sizeGroup"
show-overflow-tooltip
/>
<el-table-column label="尺码" prop="size" show-overflow-tooltip />
<el-table-column label="订单量" prop="orderNum" show-overflow-tooltip />
<el-table-column label="条码" prop="barCode" show-overflow-tooltip />
<el-table-column
label="印刷方向"
prop="printingDirection"
show-overflow-tooltip
/>
<el-table-column
label="产品规格"
prop="productSize"
show-overflow-tooltip
/>
<el-table-column label="操作" fixed="right">
<template slot-scope="{row}">
<template slot-scope="{ row }">
<el-button type="text" @click="onShowSpec(row)">特性值</el-button>
</template>
</el-table-column>
......@@ -140,12 +300,16 @@
</div>
</el-dialog>
<el-dialog :visible.sync="showSpec" title="采购详情产品特性值" width="650px">
<el-dialog
:visible.sync="showSpec"
title="采购详情产品特性值"
width="650px"
>
<el-form label-width="100px">
<el-row :gutter="10">
<el-col :span="12" v-for="spec in specList" :key="spec.specKey">
<el-form-item :label="spec.specKey">
<el-input v-model="spec.specVal" readonly/>
<el-input v-model="spec.specVal" readonly />
</el-form-item>
</el-col>
</el-row>
......@@ -159,13 +323,13 @@
</template>
<script>
import { delOrder, listOrder } from '@/api/mes/od/purchaseOrder'
import { listDetail } from '@/api/mes/od/purchaseOrderDetail'
import { listClient } from '@/api/mes/md/client'
import { delOrder, listOrder } from "@/api/mes/od/purchaseOrder";
import { listDetail } from "@/api/mes/od/purchaseOrderDetail";
import { listClient } from "@/api/mes/md/client";
export default {
name: "PurchaseOrder",
dicts: ['mes_client_type','sys_yes_no', 'sales_order_state'],
dicts: ["mes_client_type", "sys_yes_no", "sales_order_state"],
data() {
return {
// 遮罩层
......@@ -192,26 +356,32 @@ export default {
queryParams: {
pageNum: 1,
pageSize: 10,
orderNo: null, clientId: null, deliveryDate: null, state: null, source: null
orderNo: null,
clientId: null,
deliveryDate: null,
state: null,
source: null,
},
};
},
created() {
this.getList();
this.getClientList()
this.getClientList();
},
methods: {
/** 查询客户采购订单列表 */
getList() {
this.loading = true;
listOrder(this.queryParams).then(response => {
listOrder(this.queryParams).then((response) => {
this.orderList = response.rows;
this.total = response.total;
this.loading = false;
});
},
getClientList(key) {
listClient({ clientName: key, pageNum: 1, pageSize: 100 }).then(res => this.clientList = res.rows)
listClient({ clientName: key, pageNum: 1, pageSize: 100 }).then(
(res) => (this.clientList = res.rows)
);
},
/** 搜索按钮操作 */
handleQuery() {
......@@ -225,40 +395,49 @@ export default {
},
// 多选框选中数据
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length!==1
this.multiple = !selection.length
this.ids = selection.map((item) => item.id);
this.single = selection.length !== 1;
this.multiple = !selection.length;
},
toSalesEdit(row) {
if (row.state != 0) return this.$message.error("该采购单单已生成销售订单")
let id = row ? row.id : this.ids[0]
this.$router.push('/order/sales/detail?purchaseId=' + id)
if (row.state != 0)
return this.$message.error("该采购单单已生成销售订单");
let id = row ? row.id : this.ids[0];
this.$router.push("/order/sales/detail?purchaseId=" + id);
},
onShowDetail(row) {
let id = row ? row.id : this.ids[0]
this.showDetail = true
listDetail({orderId: id}).then(res => this.detailList = res.rows)
let id = row ? row.id : this.ids[0];
this.showDetail = true;
listDetail({ orderId: id }).then((res) => (this.detailList = res.rows));
},
onShowSpec(row) {
this.showSpec = true
this.specList = JSON.parse(row.specJson)
this.showSpec = true;
this.specList = JSON.parse(row.specJson);
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除客户采购订单编号为"' + ids + '"的数据项?').then(function() {
return delOrder(ids);
}).then(() => {
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {});
this.$modal
.confirm('是否确认删除客户采购订单编号为"' + ids + '"的数据项?')
.then(function () {
return delOrder(ids);
})
.then(() => {
this.getList();
this.$modal.msgSuccess("删除成功");
})
.catch(() => {});
},
/** 导出按钮操作 */
handleExport() {
this.download('md/order/export', {
...this.queryParams
}, `order_${new Date().getTime()}.xlsx`)
}
}
this.download(
"md/order/export",
{
...this.queryParams,
},
`order_${new Date().getTime()}.xlsx`
);
},
},
};
</script>
......@@ -15,12 +15,12 @@
v-if="mode != 'info'"
label="操作"
align="center"
width="150"
width="300"
fixed="right"
>
<template slot-scope="{ row, $index }">
<el-button
type="text"
icon="el-icon-edit"
size="small"
@click="openSetProd(row, $index)"
>
......@@ -28,7 +28,6 @@
</el-button>
<el-button
type="text"
icon="el-icon-edit"
size="small"
@click="openSetQrindex(row, $index)"
>
......@@ -36,7 +35,6 @@
</el-button>
<el-button
type="text"
icon="el-icon-edit"
size="small"
@click="openSetTool(row, $index)"
>
......@@ -44,7 +42,6 @@
</el-button>
<el-button
type="text"
icon="el-icon-edit"
size="small"
@click="updateRow(row, $index)"
>修改</el-button
......
......@@ -53,10 +53,10 @@
icon="el-icon-search"
size="mini"
@click="handleQuery"
>搜索</el-button
>搜索</el-button
>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
>重置</el-button
>重置</el-button
>
</el-form-item>
</el-form>
......@@ -70,7 +70,7 @@
size="mini"
@click="handleAdd"
v-hasPermi="['mes:pro:productionRequest:add']"
>新增</el-button
>新增</el-button
>
</el-col>
<el-col :span="1.5">
......@@ -82,7 +82,7 @@
:disabled="single"
@click="handleUpdate"
v-hasPermi="['mes:pro:productionRequest:edit']"
>修改</el-button
>修改</el-button
>
</el-col>
<el-col :span="1.5">
......@@ -94,7 +94,7 @@
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['mes:pro:productionRequest:remove']"
>删除</el-button
>删除</el-button
>
</el-col>
<el-col :span="1.5">
......@@ -105,7 +105,7 @@
size="mini"
@click="handleExport"
v-hasPermi="['mes:pro:productionRequest:export']"
>导出</el-button
>导出</el-button
>
</el-col>
<right-toolbar
......@@ -120,14 +120,18 @@
row-key="productionRequestId"
default-expand-all
>
<el-table-column label="量产申请单编码" prop="productionRequestCode">
<el-table-column
label="申请单编码"
width="120"
prop="productionRequestCode"
>
<template slot-scope="scope">
<el-button
size="mini"
type="text"
@click="handleView(scope.row)"
v-hasPermi="['mes:pro:productionRequest:query']"
>{{ scope.row.productionRequestCode }}</el-button
>{{ scope.row.productionRequestCode }}</el-button
>
</template>
</el-table-column>
......@@ -168,25 +172,43 @@
label="是否要鞋图"
align="center"
prop="isNeedShoeImg"
width="100"
:formatter="yesNoFmt"
/>
<el-table-column
label="是否附样品"
align="center"
width="100"
prop="isNeedPrototype"
:formatter="yesNoFmt"
/>
<el-table-column label="唯一码产品" align="center" prop="isUniqueCode"
:formatter="yesNoFmt"/>
<el-table-column label="不考虑型体配色" align="center" prop="isConsiderColor"
:formatter="yesNoFmt"/>
<el-table-column label="是否禁用" align="center" prop="isDisabled"
:formatter="yesNoFmt"/>
<el-table-column
label="唯一码产品"
align="center"
width="100"
prop="isUniqueCode"
:formatter="yesNoFmt"
/>
<el-table-column
label="不考虑型体配色"
align="center"
width="130"
prop="isConsiderColor"
:formatter="yesNoFmt"
/>
<el-table-column
label="是否禁用"
align="center"
width="80"
prop="isDisabled"
:formatter="yesNoFmt"
/>
/>
<el-table-column
label="申请单状态"
align="center"
width="100"
prop="prototypeRequestStatus"
>
<template slot-scope="scope">
......@@ -200,6 +222,7 @@
label="操作"
width="200px"
align="center"
fixed="right"
class-name="small-padding fixed-width"
>
<template slot-scope="scope">
......@@ -210,7 +233,7 @@
v-if="scope.row.productionRequestStatus == '0'"
@click="handleUpdate(scope.row)"
v-hasPermi="['mes:pro:productionRequest:edit']"
>修改</el-button
>修改</el-button
>
<el-button
size="mini"
......@@ -219,15 +242,7 @@
v-if="scope.row.productionRequestStatus == '0'"
@click="handleFinish(scope.row)"
v-hasPermi="['mes:pro:productionRequest:update']"
>通过</el-button
>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['mes:pro:productionRequest:remove']"
>删除</el-button
>通过</el-button
>
<el-button
size="mini"
......@@ -236,7 +251,15 @@
v-if="scope.row.productionRequestStatus == '1'"
@click="generate(scope.row)"
v-hasPermi="['mes:pro:productionRequest:edit']"
>生成制作单</el-button
>生成制作单</el-button
>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['mes:pro:productionRequest:remove']"
>删除</el-button
>
</template>
</el-table-column>
......@@ -252,250 +275,255 @@
</template>
<script>
import {
listProductionRequest,
getProductionRequest,
delProductionRequest,
addProductionRequest,
updateProductionRequest,
dofinish,
} from "@/api/mes/pro/productionRequest";
import ItemSelect from "@/components/itemSelect/single.vue";
import ClientSelect from "@/components/clientSelect/single.vue";
import VendorSelect from "@/components/vendorSelect/single.vue";
import Treeselect from "@riophae/vue-treeselect";
import "@riophae/vue-treeselect/dist/vue-treeselect.css";
import {
listProductionRequest,
getProductionRequest,
delProductionRequest,
addProductionRequest,
updateProductionRequest,
dofinish,
} from "@/api/mes/pro/productionRequest";
import ItemSelect from "@/components/itemSelect/single.vue";
import ClientSelect from "@/components/clientSelect/single.vue";
import VendorSelect from "@/components/vendorSelect/single.vue";
import Treeselect from "@riophae/vue-treeselect";
import "@riophae/vue-treeselect/dist/vue-treeselect.css";
export default {
name: "ProductionRequest",
dicts: [
"sys_yes_no",
"mes_productionreq_status",
"mes_productionRequest_sourcetype",
"mes_productionRequest_type",
],
components: {
Treeselect,
ItemSelect,
ClientSelect,
VendorSelect,
},
data() {
return {
//自动生成编码
autoGenFlag: false,
optType: undefined,
// 遮罩层
loading: true,
// 选中数组
ids: [],
// 显示搜索条件
showSearch: true,
// 非单个禁用
single: true,
// 总条数
total: 0,
// 非多个禁用
multiple: true,
// 生产工单表格数据
productionRequestList: [],
// 生产工单树选项
productionRequestOptions: [],
// 弹出层标题
title: "",
// 是否显示弹出层
open: false,
// 查询参数
queryParams: {
pageNum: 1,
pageSize: 10,
itemName: null, // 可以查简称与英文名
productionRequestStatus: null,
},
options: [
{ value: 0, label: "审批中" },
{ value: 1, label: "待制作" },
{ value: 2, label: "量产中" },
{ value: 3, label: "待质检" },
{ value: 4, label: "待确认" },
{ value: 5, label: "已完成" },
],
export default {
name: "ProductionRequest",
dicts: [
"sys_yes_no",
"mes_productionreq_status",
"mes_productionRequest_sourcetype",
"mes_productionRequest_type",
],
components: {
Treeselect,
ItemSelect,
ClientSelect,
VendorSelect,
},
data() {
return {
//自动生成编码
autoGenFlag: false,
optType: undefined,
// 遮罩层
loading: true,
// 选中数组
ids: [],
// 显示搜索条件
showSearch: true,
// 非单个禁用
single: true,
// 总条数
total: 0,
// 非多个禁用
multiple: true,
// 生产工单表格数据
productionRequestList: [],
// 生产工单树选项
productionRequestOptions: [],
// 弹出层标题
title: "",
// 是否显示弹出层
open: false,
// 查询参数
queryParams: {
pageNum: 1,
pageSize: 10,
itemName: null, // 可以查简称与英文名
productionRequestStatus: null,
},
options: [
{ value: 0, label: "审批中" },
{ value: 1, label: "待制作" },
{ value: 2, label: "量产中" },
{ value: 3, label: "待质检" },
{ value: 4, label: "待确认" },
{ value: 5, label: "已完成" },
],
// 表单参数
form: {},
// 表单校验
rules: {
// productionRequestCode: [
// { required: true, message: "工单编码不能为空", trigger: "blur" }
// ],
},
// 表单参数
form: {},
// 表单校验
rules: {
// productionRequestCode: [
// { required: true, message: "工单编码不能为空", trigger: "blur" }
// ],
},
};
},
created() {
this.getList();
},
methods: {
/** 查询生产工单列表 */
getList() {
this.loading = true;
listProductionRequest(this.queryParams).then((response) => {
this.productionRequestList = response.rows;
this.total = response.total;
this.loading = false;
});
},
// 取消按钮
cancel() {
this.open = false;
this.reset();
},
// 表单重置
reset() {
this.form = {
productionRequestId: null,
productionRequestCode: 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,
productionRequestStatus: "0",
testStandard: null,
remark: null,
createBy: null,
createTime: null,
updateBy: null,
updateTime: null,
};
this.resetForm("form");
},
created() {
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
methods: {
/** 查询生产工单列表 */
getList() {
this.loading = true;
listProductionRequest(this.queryParams).then((response) => {
this.productionRequestList = response.rows;
this.total = response.total;
this.loading = false;
});
},
// 取消按钮
cancel() {
this.open = false;
this.reset();
},
// 表单重置
reset() {
this.form = {
productionRequestId: null,
productionRequestCode: 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,
productionRequestStatus: "0",
testStandard: null,
remark: null,
createBy: null,
createTime: null,
updateBy: null,
updateTime: null,
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
/** 新增按钮操作 */
handleAdd(row) {
// 跳转到申请单界面
this.$router.push("/mes/pro/productiorequest/apply");
return;
// this.reset();
// this.getTreeselect();
// if (row != null && row.productionRequestId) {
// this.form.parentId = row.productionRequestId;
// this.form.orderSource = row.orderSource;
// this.form.sourceCode = row.sourceCode;
// this.form.clientId = row.clientId;
// this.form.clientCode = row.clientCode;
// this.form.clientName = row.clientName;
// } else {
// this.form.parentId = 0;
// }
// this.open = true;
},
// 查询明细按钮操作
handleView(row) {
this.reset();
const productionRequestId = row.productionRequestId || this.ids;
this.$router.push(
"/mes/pro/productiorequest/info?productionRequestId=" + productionRequestId
);
// getproductionRequest(productionRequestId).then((response) => {
// this.form = response.data;
// this.open = true;
// this.title = "查看工单信息";
// this.optType = "view";
// });
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();
const productionRequestId = row.productionRequestId || this.ids;
this.$router.push(
"/mes/pro/productiorequest/edit?productionRequestId=" + productionRequestId
);
// getProductionRequest(productionRequestId).then((response) => {
// // this.form = response.data;
// // this.open = true;
// // this.title = "修改生产工单";
// // this.optType="edit";
// // 跳转修改
// });
},
/** 删除按钮操作 */
handleDelete(row) {
this.$modal
.confirm('是否确认删除编号为"' + row.productionRequestId + '"的量产单?')
.then(function () {
return delProductionRequest(row.productionRequestId);
})
.then(() => {
this.getList();
this.$modal.msgSuccess("删除成功");
})
.catch(() => {});
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
/** 新增按钮操作 */
handleAdd(row) {
// 跳转到申请单界面
this.$router.push("/mes/pro/productiorequest/apply");
return;
// this.reset();
// this.getTreeselect();
// if (row != null && row.productionRequestId) {
// this.form.parentId = row.productionRequestId;
// this.form.orderSource = row.orderSource;
// this.form.sourceCode = row.sourceCode;
// this.form.clientId = row.clientId;
// this.form.clientCode = row.clientCode;
// this.form.clientName = row.clientName;
// } else {
// this.form.parentId = 0;
// }
// this.open = true;
},
// 查询明细按钮操作
handleView(row) {
this.reset();
const productionRequestId = row.productionRequestId || this.ids;
this.$router.push(
"/mes/pro/productiorequest/info?productionRequestId=" +
productionRequestId
);
// getproductionRequest(productionRequestId).then((response) => {
// this.form = response.data;
// this.open = true;
// this.title = "查看工单信息";
// this.optType = "view";
// });
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();
const productionRequestId = row.productionRequestId || this.ids;
this.$router.push(
"/mes/pro/productiorequest/edit?productionRequestId=" +
productionRequestId
);
// getProductionRequest(productionRequestId).then((response) => {
// // this.form = response.data;
// // this.open = true;
// // this.title = "修改生产工单";
// // this.optType="edit";
// // 跳转修改
// });
},
/** 删除按钮操作 */
handleDelete(row) {
this.$modal
.confirm(
'是否确认删除编号为"' + row.productionRequestId + '"的量产单?'
)
.then(function () {
return delProductionRequest(row.productionRequestId);
})
.then(() => {
this.getList();
this.$modal.msgSuccess("删除成功");
})
.catch(() => {});
},
handleSelectProduct() {
this.$refs.itemSelect.showFlag = true;
},
handleSelectClient() {
this.$refs.clientSelect.showFlag = true;
},
/** 导出按钮操作 */
handleExport() {
this.download(
"mes/pro/productionRequest/export",
{
...this.queryParams,
},
`量产申请单_${new Date().getTime()}.xlsx`
);
},
handleSelectProduct() {
this.$refs.itemSelect.showFlag = true;
},
handleSelectClient() {
this.$refs.clientSelect.showFlag = true;
},
/** 导出按钮操作 */
handleExport() {
this.download(
"mes/pro/productionRequest/export",
{
...this.queryParams,
},
`量产申请单_${new Date().getTime()}.xlsx`
);
},
// 审批
handleFinish(row) {
row.productionRequestStatus = 1
this.$modal
.confirm("确认通过样品申请单?一旦完成,此工单将无法继续修改")
.then(function () {
return dofinish(row); //完成申请单审批
})
.then(() => {
this.getList();
this.$modal.msgSuccess("审批成功");
})
.catch(() => {});
},
yesNoFmt(row, column, cellValue){
if(cellValue==1){
return '是';
}else{
return '否';
}
},
// 生成制作单
generate(row) {
// 跳转到制作单界面
const prototypeRequestId = row.productionRequestId || this.ids;
this.$router.push(
"/mes/pro/productionMake/apply?productionRequestId=" + prototypeRequestId
);
return;
},
// 审批
handleFinish(row) {
row.productionRequestStatus = 1;
this.$modal
.confirm("确认通过样品申请单?一旦完成,此工单将无法继续修改")
.then(function () {
return dofinish(row); //完成申请单审批
})
.then(() => {
this.getList();
this.$modal.msgSuccess("审批成功");
})
.catch(() => {});
},
yesNoFmt(row, column, cellValue) {
if (cellValue == 1) {
return "是";
} else {
return "否";
}
},
// 生成制作单
generate(row) {
// 跳转到制作单界面
const prototypeRequestId = row.productionRequestId || this.ids;
this.$router.push(
"/mes/pro/productionMake/apply?productionRequestId=" +
prototypeRequestId
);
return;
},
};
},
};
</script>
......@@ -15,12 +15,12 @@
v-if="mode != 'info'"
label="操作"
align="center"
width="150"
width="300"
fixed="right"
>
<template slot-scope="{ row, $index }">
<el-button
type="text"
icon="el-icon-edit"
size="small"
@click="openSetProd(row, $index)"
>
......@@ -28,7 +28,6 @@
</el-button>
<el-button
type="text"
icon="el-icon-edit"
size="small"
@click="openSetQrindex(row, $index)"
>
......@@ -36,7 +35,6 @@
</el-button>
<el-button
type="text"
icon="el-icon-edit"
size="small"
@click="openSetTool(row, $index)"
>
......@@ -44,7 +42,6 @@
</el-button>
<el-button
type="text"
icon="el-icon-edit"
size="small"
@click="updateRow(row, $index)"
>修改</el-button
......@@ -59,7 +56,6 @@
ref="ProcessProdRef"
@updateItem="updateItem"
/>
/>
<ProcessQcindex
:process="currentRow"
ref="ProcessQcindexRef"
......
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form
:model="queryParams"
ref="queryForm"
size="small"
:inline="true"
v-show="showSearch"
label-width="68px"
>
<!-- <el-form-item label="工单编码" prop="workorderCode">
<el-input
v-model="queryParams.workorderCode"
......@@ -172,7 +179,8 @@
size="mini"
@click="handleImport"
v-hasPermi="['mes:pro:workorder:edit']"
>导入工单</el-button>
>导入工单</el-button
>
</el-col>
<right-toolbar
:showSearch.sync="showSearch"
......@@ -180,7 +188,6 @@
></right-toolbar>
</el-row>
<!-- 用户导入对话框 -->
<el-dialog title="导入工单" :visible.sync="upload.open" width="400px">
<el-upload
......@@ -199,7 +206,13 @@
<div class="el-upload__text">将文件拖到此处,或<em>点击上传</em></div>
<div class="el-upload__tip text-center" slot="tip">
<span>仅允许导入xls、xlsx格式文件。</span>
<el-link type="primary" :underline="false" style="font-size:12px;vertical-align: baseline;" @click="importTemplate">下载模板</el-link>
<el-link
type="primary"
:underline="false"
style="font-size: 12px; vertical-align: baseline"
@click="importTemplate"
>下载模板</el-link
>
</div>
</el-upload>
<div slot="footer" class="dialog-footer">
......@@ -254,9 +267,10 @@
</el-table-column>
<el-table-column
label="工艺名称"
width="140"
width="160"
align="center"
prop="routeName"
show-overflow-tooltip
/>
<el-table-column
label="订单编号"
......@@ -338,15 +352,17 @@
v-if="scope.row.status == 'PREPARE'"
@click="handleUpdate(scope.row)"
v-hasPermi="['mes:pro:workorder:edit']"
>修改</el-button>
<el-button
>修改</el-button
>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
v-if="scope.row.status == 'PREPARE'"
@click="handleDelete(scope.row)"
v-hasPermi="['mes:pro:workorder:remove']"
>删除</el-button>
>删除</el-button
>
<!-- <el-button
size="mini"
type="text"
......@@ -368,7 +384,7 @@
v-hasPermi="['mes:pro:workorder:update']"
>完成</el-button
> -->
<!-- <el-button
size="mini"
type="text"
......@@ -679,7 +695,7 @@ import VendorSelect from "@/components/vendorSelect/single.vue";
import { genCode } from "@/api/system/autocode/rule";
import Treeselect from "@riophae/vue-treeselect";
import "@riophae/vue-treeselect/dist/vue-treeselect.css";
import { getToken } from '@/utils/auth'
import { getToken } from "@/utils/auth";
export default {
name: "Workorder",
......@@ -728,7 +744,7 @@ export default {
// 设置上传的请求头部
headers: { Authorization: "Bearer " + getToken() },
// 上传的地址
url: process.env.VUE_APP_BASE_API + "/mes/pro/workorder/importData"
url: process.env.VUE_APP_BASE_API + "/mes/pro/workorder/importData",
},
// 查询参数
queryParams: {
......@@ -754,19 +770,19 @@ export default {
requestDate: null,
parentId: null,
ancestors: null,
status: 'PREPARE',
status: "PREPARE",
},
// 表单状态
// 表单状态
options: [
{ value: "PREPARE", label: "待确认" },
{ value: "CONFIRMED", label: "已确认" },
{ value: "APPROVING", label: "审批中" },
{ value: "APPROVED", label: "已审批" },
{ value: "FINISHED", label: "已完成" },
{ value: "TASKGENERATED", label: "已生成任务单" },
{ value: "ISSUEGENERATED", label: "已生成领料单" },
{ value: "PRODUCIONG", label: "生产中" },
],
{ value: "PREPARE", label: "待确认" },
{ value: "CONFIRMED", label: "已确认" },
{ value: "APPROVING", label: "审批中" },
{ value: "APPROVED", label: "已审批" },
{ value: "FINISHED", label: "已完成" },
{ value: "TASKGENERATED", label: "已生成任务单" },
{ value: "ISSUEGENERATED", label: "已生成领料单" },
{ value: "PRODUCIONG", label: "生产中" },
],
// 表单参数
form: {},
// 表单校验
......@@ -819,8 +835,11 @@ export default {
});
},
importTemplate() {
this.download('mes/pro/workorder/importTemplate', {
}, `work_order_template_${new Date().getTime()}.xlsx`)
this.download(
"mes/pro/workorder/importTemplate",
{},
`work_order_template_${new Date().getTime()}.xlsx`
);
},
/** 导入按钮操作 */
handleImport() {
......@@ -835,7 +854,13 @@ export default {
this.upload.open = false;
this.upload.isUploading = false;
this.$refs.upload.clearFiles();
this.$alert("<div style='overflow: auto;overflow-x: hidden;max-height: 70vh;padding: 10px 20px 0;'>" + response.msg + "</div>", "导入结果", { dangerouslyUseHTMLString: true });
this.$alert(
"<div style='overflow: auto;overflow-x: hidden;max-height: 70vh;padding: 10px 20px 0;'>" +
response.msg +
"</div>",
"导入结果",
{ dangerouslyUseHTMLString: true }
);
this.getList();
},
// 提交上传文件
......@@ -1123,12 +1148,18 @@ export default {
},
/** 完成任务单操作 */
confirmWorkorder(row) {
this.$modal.confirm('是否将工单编号"' + row.workorderCode + '"的草稿数据项改为已确认?').then(function() {
return confirmedWorkorder(row.workorderId);
}).then(() => {
this.getList();
this.$modal.msgSuccess("已确认成功");
}).catch(() => {});
this.$modal
.confirm(
'是否将工单编号"' + row.workorderCode + '"的草稿数据项改为已确认?'
)
.then(function () {
return confirmedWorkorder(row.workorderId);
})
.then(() => {
this.getList();
this.$modal.msgSuccess("已确认成功");
})
.catch(() => {});
},
//自动生成编码
handleAutoGenChange(autoGenFlag) {
......
......@@ -85,27 +85,27 @@
<el-table v-loading="loading" :data="factoryQuoteList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55"/>
<el-table-column label="客户编号" prop="clientCode"/>
<el-table-column label="客户名称" prop="clientName"/>
<el-table-column label="产品编号" prop="itemCode"/>
<el-table-column label="产品名称" prop="itemName"/>
<el-table-column label="价格" prop="price"/>
<el-table-column label="有效期起" prop="validFrom" width="180">
<el-table-column label="客户编号" width="120" prop="clientCode"/>
<el-table-column label="客户名称" width="180" prop="clientName"/>
<el-table-column label="产品编号" width="160" prop="itemCode"/>
<el-table-column label="产品名称" min-width="200" show-overflow-tooltip prop="itemName"/>
<el-table-column label="价格" width="100" prop="price"/>
<el-table-column label="有效期起" prop="validFrom" width="140">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.validFrom, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="有效期至" prop="validTo" width="180">
<el-table-column label="有效期至" prop="validTo" width="140">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.validTo, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="状态" prop="state">
<el-table-column label="状态" prop="state" width="100">
<template slot-scope="{row}">
{{ row.state === '0' ? '草稿' : row.state === '1' ? '审批中' : row.state === '2' ? '发布中' : '已发布'}}
</template>
</el-table-column>
<el-table-column label="操作" class-name="small-padding fixed-width">
<el-table-column width="120" fixed="right" label="操作" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
v-if="scope.row.state === '0' || scope.row.state === '2'"
......
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