feat: 福安德智慧报价平台 - 完整业务模块
基于RuoYi-Vue2构建的智慧采购报价平台,包含: 后端(Spring Boot + MyBatis): - 物料管理 (BizMaterial) - 供应商管理 (BizSupplier) - 报价请求RFQ (BizRfq) - 供应商报价单 (BizQuotation) - 智慧比价分析 (BizComparison) - 采购单 (BizPurchaseOrder) - 供应商评价 (BizSupplierEvaluation) - 订单异议 (BizOrderObjection) - 交易记录 (BizTransaction) - 租户管理-SaaS数据隔离 (BizTenant) 前端(Vue2 + Element UI): - 10个业务模块完整页面 - ERPNext风格主题(蓝色系) - 福安德品牌logo 部署: - Docker Compose一键部署 - MySQL 8.0 + Redis 7 + Nginx - 前端端口 10031
This commit is contained in:
77
ruoyi-ui/src/views/bid/comparison/index.vue
Normal file
77
ruoyi-ui/src/views/bid/comparison/index.vue
Normal file
@@ -0,0 +1,77 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<div class="filter-bar">
|
||||
<el-form :inline="true" size="small">
|
||||
<el-form-item label="选择RFQ">
|
||||
<el-select v-model="selectedRfqId" placeholder="请选择要比价的RFQ" filterable style="width:320px">
|
||||
<el-option v-for="r in rfqOptions" :key="r.rfqId" :label="r.rfqNo+' — '+r.rfqTitle" :value="r.rfqId" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary" icon="el-icon-data-analysis" @click="doCompare" :loading="loading">开始比价</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</div>
|
||||
|
||||
<div v-if="result.length === 0 && !loading" class="empty-tip">
|
||||
<i class="el-icon-data-analysis" style="font-size:48px;color:#ddd"></i>
|
||||
<p>请选择RFQ并点击"开始比价"</p>
|
||||
</div>
|
||||
|
||||
<div v-for="(item, idx) in result" :key="item.rfqItemId" style="margin-bottom:24px">
|
||||
<div class="compare-header">
|
||||
<span class="item-no">物料 {{ idx+1 }}</span>
|
||||
<strong>{{ item.materialName }}</strong>
|
||||
<span v-if="item.spec" style="color:#909399;margin-left:8px">{{ item.spec }}</span>
|
||||
<span style="margin-left:16px;color:#606266">数量: {{ item.quantity }} {{ item.unit }}</span>
|
||||
</div>
|
||||
<el-table :data="item.prices || []" border size="small">
|
||||
<el-table-column label="供应商" prop="supplierName" min-width="140">
|
||||
<template slot-scope="scope">
|
||||
<i class="el-icon-star-on" style="color:#f7ba2a;margin-right:4px" v-if="scope.row.lowestPrice"></i>
|
||||
{{ scope.row.supplierName }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="报价单号" prop="quoteNo" width="140" />
|
||||
<el-table-column label="单价" prop="unitPrice" width="120" align="right">
|
||||
<template slot-scope="scope">
|
||||
<span :style="scope.row.lowestPrice ? 'color:#67C23A;font-weight:bold' : ''">
|
||||
¥{{ scope.row.unitPrice }}
|
||||
</span>
|
||||
<el-tag v-if="scope.row.lowestPrice" type="success" size="mini" style="margin-left:4px">最低</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="总价" prop="totalPrice" width="130" align="right">
|
||||
<template slot-scope="scope">¥{{ scope.row.totalPrice }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="交货期(天)" prop="deliveryDays" width="100" align="center" />
|
||||
</el-table>
|
||||
<div v-if="!item.prices || item.prices.length === 0" style="padding:12px;color:#909399;background:#fafafa;border:1px solid #eee">暂无供应商报价</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import { compareRfq } from "@/api/bid/comparison";
|
||||
import { listRfq } from "@/api/bid/rfq";
|
||||
export default {
|
||||
name: "Comparison",
|
||||
data() {
|
||||
return { selectedRfqId: null, loading: false, result: [], rfqOptions: [] };
|
||||
},
|
||||
created() {
|
||||
listRfq({ pageSize: 200, status: "published" }).then(r => { this.rfqOptions = r.rows || []; });
|
||||
},
|
||||
methods: {
|
||||
doCompare() {
|
||||
if (!this.selectedRfqId) { this.$message.warning("请先选择RFQ"); return; }
|
||||
this.loading = true;
|
||||
compareRfq(this.selectedRfqId).then(r => { this.result = r.data || []; this.loading = false; }).catch(() => { this.loading = false; });
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
<style scoped>
|
||||
.compare-header { background:#f5f7fa; padding:10px 16px; border-left:4px solid #409EFF; margin-bottom:8px; border-radius:2px; }
|
||||
.item-no { background:#409EFF; color:#fff; padding:2px 8px; border-radius:10px; font-size:12px; margin-right:8px; }
|
||||
.empty-tip { text-align:center; padding:80px; color:#909399; }
|
||||
</style>
|
||||
75
ruoyi-ui/src/views/bid/evaluation/index.vue
Normal file
75
ruoyi-ui/src/views/bid/evaluation/index.vue
Normal file
@@ -0,0 +1,75 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-table v-loading="loading" :data="list">
|
||||
<el-table-column label="供应商" prop="supplierName" />
|
||||
<el-table-column label="采购单" prop="poNo" width="140" />
|
||||
<el-table-column label="质量" width="70" align="center">
|
||||
<template slot-scope="scope"><el-rate :value="scope.row.qualityScore" disabled show-score /></template>
|
||||
</el-table-column>
|
||||
<el-table-column label="交期" width="70" align="center">
|
||||
<template slot-scope="scope"><el-rate :value="scope.row.deliveryScore" disabled show-score /></template>
|
||||
</el-table-column>
|
||||
<el-table-column label="服务" width="70" align="center">
|
||||
<template slot-scope="scope"><el-rate :value="scope.row.serviceScore" disabled show-score /></template>
|
||||
</el-table-column>
|
||||
<el-table-column label="价格" width="70" align="center">
|
||||
<template slot-scope="scope"><el-rate :value="scope.row.priceScore" disabled show-score /></template>
|
||||
</el-table-column>
|
||||
<el-table-column label="综合评分" width="90" align="center">
|
||||
<template slot-scope="scope"><span style="color:#F7BA2A;font-weight:bold">{{ scope.row.totalScore }}</span></template>
|
||||
</el-table-column>
|
||||
<el-table-column label="评价意见" prop="comment" :show-overflow-tooltip="true" />
|
||||
<el-table-column label="评价人" prop="evaluator" width="100" />
|
||||
<el-table-column label="评价时间" prop="evalTime" width="160" />
|
||||
</el-table>
|
||||
<pagination v-show="total>0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize" @pagination="getList" />
|
||||
|
||||
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd" style="margin-top:16px">添加评价</el-button>
|
||||
|
||||
<el-dialog title="供应商评价" :visible.sync="open" width="500px" append-to-body>
|
||||
<el-form ref="form" :model="form" label-width="100px">
|
||||
<el-form-item label="供应商">
|
||||
<el-select v-model="form.supplierId" placeholder="选择供应商" style="width:100%">
|
||||
<el-option v-for="s in supplierOptions" :key="s.supplierId" :label="s.supplierName" :value="s.supplierId" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="质量评分"><el-rate v-model="form.qualityScore" /></el-form-item>
|
||||
<el-form-item label="交期评分"><el-rate v-model="form.deliveryScore" /></el-form-item>
|
||||
<el-form-item label="服务评分"><el-rate v-model="form.serviceScore" /></el-form-item>
|
||||
<el-form-item label="价格评分"><el-rate v-model="form.priceScore" /></el-form-item>
|
||||
<el-form-item label="评价意见"><el-input v-model="form.comment" type="textarea" rows="3" /></el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer">
|
||||
<el-button @click="open=false">取消</el-button>
|
||||
<el-button type="primary" @click="submitForm">提交</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import { listEvaluation, addEvaluation } from "@/api/bid/evaluation";
|
||||
import { listSupplier } from "@/api/bid/supplier";
|
||||
export default {
|
||||
name: "Evaluation",
|
||||
data() {
|
||||
return {
|
||||
loading: false, total: 0, list: [], open: false,
|
||||
supplierOptions: [],
|
||||
queryParams: { pageNum: 1, pageSize: 10 },
|
||||
form: { qualityScore: 5, deliveryScore: 5, serviceScore: 5, priceScore: 5 }
|
||||
};
|
||||
},
|
||||
created() { this.getList(); listSupplier({ pageSize: 200 }).then(r => { this.supplierOptions = r.rows || []; }); },
|
||||
methods: {
|
||||
getList() {
|
||||
this.loading = true;
|
||||
listEvaluation(this.queryParams).then(r => { this.list = r.rows; this.total = r.total; this.loading = false; });
|
||||
},
|
||||
handleAdd() { this.form = { qualityScore: 5, deliveryScore: 5, serviceScore: 5, priceScore: 5 }; this.open = true; },
|
||||
submitForm() {
|
||||
this.form.totalScore = ((this.form.qualityScore + this.form.deliveryScore + this.form.serviceScore + this.form.priceScore) / 4).toFixed(1);
|
||||
addEvaluation(this.form).then(() => { this.$modal.msgSuccess("评价成功"); this.open = false; this.getList(); });
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
132
ruoyi-ui/src/views/bid/material/index.vue
Normal file
132
ruoyi-ui/src/views/bid/material/index.vue
Normal file
@@ -0,0 +1,132 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true">
|
||||
<el-form-item label="物料名称" prop="materialName">
|
||||
<el-input v-model="queryParams.materialName" 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>
|
||||
<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">新增</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-row>
|
||||
|
||||
<el-table v-loading="loading" :data="materialList" @selection-change="handleSelectionChange">
|
||||
<el-table-column type="selection" width="55" align="center" />
|
||||
<el-table-column label="物料编码" prop="materialCode" width="130" />
|
||||
<el-table-column label="物料名称" prop="materialName" :show-overflow-tooltip="true" />
|
||||
<el-table-column label="规格型号" prop="spec" :show-overflow-tooltip="true" />
|
||||
<el-table-column label="单位" prop="unit" width="80" />
|
||||
<el-table-column label="品牌" prop="brand" />
|
||||
<el-table-column label="状态" align="center" width="80">
|
||||
<template slot-scope="scope">
|
||||
<el-switch v-model="scope.row.status" active-value="0" inactive-value="1" @change="handleStatusChange(scope.row)" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="创建时间" align="center" prop="createTime" width="160" />
|
||||
<el-table-column label="操作" align="center" width="160">
|
||||
<template slot-scope="scope">
|
||||
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)">修改</el-button>
|
||||
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)">删除</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="600px" append-to-body>
|
||||
<el-form ref="form" :model="form" :rules="rules" label-width="100px">
|
||||
<el-form-item label="物料编码" prop="materialCode">
|
||||
<el-input v-model="form.materialCode" placeholder="请输入物料编码" />
|
||||
</el-form-item>
|
||||
<el-form-item label="物料名称" prop="materialName">
|
||||
<el-input v-model="form.materialName" placeholder="请输入物料名称" />
|
||||
</el-form-item>
|
||||
<el-form-item label="规格型号" prop="spec">
|
||||
<el-input v-model="form.spec" placeholder="请输入规格型号" />
|
||||
</el-form-item>
|
||||
<el-row>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="单位" prop="unit">
|
||||
<el-input v-model="form.unit" placeholder="如:台/件/米" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="品牌" prop="brand">
|
||||
<el-input v-model="form.brand" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-form-item label="描述" prop="description">
|
||||
<el-input v-model="form.description" type="textarea" rows="3" />
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer">
|
||||
<el-button @click="cancel">取消</el-button>
|
||||
<el-button type="primary" @click="submitForm">确定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { listMaterial, getMaterial, addMaterial, updateMaterial, delMaterial } from "@/api/bid/material";
|
||||
export default {
|
||||
name: "Material",
|
||||
data() {
|
||||
return {
|
||||
loading: false, multiple: true, total: 0, materialList: [],
|
||||
open: false, title: "",
|
||||
queryParams: { pageNum: 1, pageSize: 10, materialName: null, materialCode: null },
|
||||
form: {},
|
||||
rules: {
|
||||
materialCode: [{ required: true, message: "物料编码不能为空", trigger: "blur" }],
|
||||
materialName: [{ required: true, message: "物料名称不能为空", trigger: "blur" }],
|
||||
}
|
||||
};
|
||||
},
|
||||
created() { this.getList(); },
|
||||
methods: {
|
||||
getList() {
|
||||
this.loading = true;
|
||||
listMaterial(this.queryParams).then(res => {
|
||||
this.materialList = res.rows;
|
||||
this.total = res.total;
|
||||
this.loading = false;
|
||||
});
|
||||
},
|
||||
handleQuery() { this.queryParams.pageNum = 1; this.getList(); },
|
||||
resetQuery() { this.resetForm("queryForm"); this.handleQuery(); },
|
||||
handleSelectionChange(sel) { this.multiple = !sel.length; },
|
||||
handleAdd() { this.reset(); this.open = true; this.title = "新增物料"; },
|
||||
handleUpdate(row) {
|
||||
this.reset();
|
||||
getMaterial(row.materialId).then(res => { this.form = res.data; this.open = true; this.title = "修改物料"; });
|
||||
},
|
||||
handleDelete(row) {
|
||||
const ids = row.materialId || this.ids;
|
||||
this.$modal.confirm("确认删除?").then(() => delMaterial(ids)).then(() => { this.getList(); this.$modal.msgSuccess("删除成功"); });
|
||||
},
|
||||
handleStatusChange(row) { updateMaterial(row); },
|
||||
reset() { this.form = { status: "0" }; this.resetForm("form"); },
|
||||
cancel() { this.open = false; this.reset(); },
|
||||
submitForm() {
|
||||
this.$refs["form"].validate(valid => {
|
||||
if (!valid) return;
|
||||
const action = this.form.materialId ? updateMaterial : addMaterial;
|
||||
action(this.form).then(() => { this.$modal.msgSuccess("操作成功"); this.open = false; this.getList(); });
|
||||
});
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
106
ruoyi-ui/src/views/bid/objection/index.vue
Normal file
106
ruoyi-ui/src/views/bid/objection/index.vue
Normal file
@@ -0,0 +1,106 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-form :model="queryParams" size="small" :inline="true">
|
||||
<el-form-item label="状态">
|
||||
<el-select v-model="queryParams.status" clearable placeholder="全部" style="width:110px">
|
||||
<el-option label="待处理" value="pending"/>
|
||||
<el-option label="处理中" value="processing"/>
|
||||
<el-option label="已解决" value="resolved"/>
|
||||
<el-option label="已拒绝" value="rejected"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary" size="mini" @click="getList">搜索</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">提交异议</el-button>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
<el-table v-loading="loading" :data="list">
|
||||
<el-table-column label="采购单号" prop="poNo" width="150" />
|
||||
<el-table-column label="供应商" prop="supplierName" width="150" />
|
||||
<el-table-column label="异议原因" prop="reason" :show-overflow-tooltip="true" />
|
||||
<el-table-column label="状态" width="100">
|
||||
<template slot-scope="scope">
|
||||
<el-tag :type="{ pending:'warning', processing:'primary', resolved:'success', rejected:'danger' }[scope.row.status]">
|
||||
{{ { pending:'待处理', processing:'处理中', resolved:'已解决', rejected:'已拒绝' }[scope.row.status] || scope.row.status }}
|
||||
</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="处理结果" prop="resolution" :show-overflow-tooltip="true" />
|
||||
<el-table-column label="提交时间" prop="createTime" width="160" />
|
||||
<el-table-column label="操作" align="center" width="150">
|
||||
<template slot-scope="scope">
|
||||
<el-button size="mini" type="text" @click="handleResolve(scope.row)" v-if="scope.row.status==='pending'||scope.row.status==='processing'" style="color:#67C23A">处理</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="提交异议" :visible.sync="addOpen" width="500px" append-to-body>
|
||||
<el-form ref="addForm" :model="addForm" label-width="100px">
|
||||
<el-form-item label="采购单号"><el-input v-model="addForm.poId" placeholder="输入采购单ID" /></el-form-item>
|
||||
<el-form-item label="供应商">
|
||||
<el-select v-model="addForm.supplierId" placeholder="选择供应商" style="width:100%">
|
||||
<el-option v-for="s in supplierOptions" :key="s.supplierId" :label="s.supplierName" :value="s.supplierId" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="异议原因"><el-input v-model="addForm.reason" type="textarea" rows="4" /></el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer">
|
||||
<el-button @click="addOpen=false">取消</el-button>
|
||||
<el-button type="primary" @click="submitAdd">提交</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
|
||||
<el-dialog title="处理异议" :visible.sync="resolveOpen" width="460px" append-to-body>
|
||||
<el-form :model="resolveForm" label-width="90px">
|
||||
<el-form-item label="处理结果"><el-input v-model="resolveForm.resolution" type="textarea" rows="4" /></el-form-item>
|
||||
<el-form-item label="处理状态">
|
||||
<el-radio-group v-model="resolveForm.status">
|
||||
<el-radio label="resolved">已解决</el-radio>
|
||||
<el-radio label="rejected">拒绝</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer">
|
||||
<el-button @click="resolveOpen=false">取消</el-button>
|
||||
<el-button type="primary" @click="submitResolve">确认</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import { listObjection, addObjection, updateObjection } from "@/api/bid/objection";
|
||||
import { listSupplier } from "@/api/bid/supplier";
|
||||
export default {
|
||||
name: "Objection",
|
||||
data() {
|
||||
return {
|
||||
loading: false, total: 0, list: [],
|
||||
addOpen: false, resolveOpen: false,
|
||||
supplierOptions: [],
|
||||
queryParams: { pageNum: 1, pageSize: 10, status: null },
|
||||
addForm: {}, resolveForm: {}
|
||||
};
|
||||
},
|
||||
created() { this.getList(); listSupplier({ pageSize: 200 }).then(r => { this.supplierOptions = r.rows || []; }); },
|
||||
methods: {
|
||||
getList() {
|
||||
this.loading = true;
|
||||
listObjection(this.queryParams).then(r => { this.list = r.rows; this.total = r.total; this.loading = false; });
|
||||
},
|
||||
handleAdd() { this.addForm = {}; this.addOpen = true; },
|
||||
submitAdd() {
|
||||
addObjection(this.addForm).then(() => { this.$modal.msgSuccess("提交成功"); this.addOpen = false; this.getList(); });
|
||||
},
|
||||
handleResolve(row) { this.resolveForm = { objectionId: row.objectionId, status: "resolved" }; this.resolveOpen = true; },
|
||||
submitResolve() {
|
||||
updateObjection(this.resolveForm).then(() => { this.$modal.msgSuccess("处理成功"); this.resolveOpen = false; this.getList(); });
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
177
ruoyi-ui/src/views/bid/purchaseorder/index.vue
Normal file
177
ruoyi-ui/src/views/bid/purchaseorder/index.vue
Normal file
@@ -0,0 +1,177 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-form :model="queryParams" size="small" :inline="true" ref="queryForm">
|
||||
<el-form-item label="采购单号" prop="poNo">
|
||||
<el-input v-model="queryParams.poNo" placeholder="采购单号" clearable @keyup.enter.native="handleQuery" />
|
||||
</el-form-item>
|
||||
<el-form-item label="状态" prop="status">
|
||||
<el-select v-model="queryParams.status" placeholder="全部" clearable style="width:110px">
|
||||
<el-option label="草稿" value="draft"/>
|
||||
<el-option label="已确认" value="confirmed"/>
|
||||
<el-option label="已交付" value="delivered"/>
|
||||
<el-option label="已关闭" value="closed"/>
|
||||
<el-option label="异议中" value="disputed"/>
|
||||
</el-select>
|
||||
</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">新建采购单</el-button>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
<el-table v-loading="loading" :data="list">
|
||||
<el-table-column label="采购单号" prop="poNo" width="160" />
|
||||
<el-table-column label="供应商" prop="supplierName" />
|
||||
<el-table-column label="RFQ" prop="rfqTitle" :show-overflow-tooltip="true" />
|
||||
<el-table-column label="总金额" prop="totalAmount" width="130" align="right">
|
||||
<template slot-scope="scope"><span style="color:#409EFF;font-weight:bold">¥{{ scope.row.totalAmount }}</span></template>
|
||||
</el-table-column>
|
||||
<el-table-column label="交货日期" prop="deliveryDate" width="110" />
|
||||
<el-table-column label="状态" width="100">
|
||||
<template slot-scope="scope">
|
||||
<el-tag :type="statusType(scope.row.status)">{{ statusLabel(scope.row.status) }}</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="创建时间" prop="createTime" width="160" />
|
||||
<el-table-column label="操作" align="center" width="220">
|
||||
<template slot-scope="scope">
|
||||
<el-button size="mini" type="text" icon="el-icon-view" @click="handleView(scope.row)">详情</el-button>
|
||||
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)" v-if="scope.row.status==='draft'">编辑</el-button>
|
||||
<el-button size="mini" type="text" style="color:#67C23A" @click="handleConfirm(scope.row)" v-if="scope.row.status==='draft'">确认</el-button>
|
||||
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)" v-if="scope.row.status==='draft'">删除</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="960px" append-to-body>
|
||||
<el-form ref="form" :model="form" :rules="rules" label-width="100px">
|
||||
<el-row>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="供应商" prop="supplierId">
|
||||
<el-select v-model="form.supplierId" placeholder="选择供应商" filterable style="width:100%">
|
||||
<el-option v-for="s in supplierOptions" :key="s.supplierId" :label="s.supplierName" :value="s.supplierId" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="交货日期" prop="deliveryDate">
|
||||
<el-date-picker v-model="form.deliveryDate" type="date" placeholder="选择日期" value-format="yyyy-MM-dd" style="width:100%" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-form-item label="交货地址"><el-input v-model="form.deliveryAddr" /></el-form-item>
|
||||
|
||||
<el-divider content-position="left">采购明细</el-divider>
|
||||
<el-table :data="form.items || []" border size="small">
|
||||
<el-table-column label="物料名称" min-width="150">
|
||||
<template slot-scope="scope"><el-input v-model="scope.row.materialName" size="small" /></template>
|
||||
</el-table-column>
|
||||
<el-table-column label="规格" min-width="120">
|
||||
<template slot-scope="scope"><el-input v-model="scope.row.spec" size="small" /></template>
|
||||
</el-table-column>
|
||||
<el-table-column label="单位" width="80">
|
||||
<template slot-scope="scope"><el-input v-model="scope.row.unit" size="small" /></template>
|
||||
</el-table-column>
|
||||
<el-table-column label="数量" width="100">
|
||||
<template slot-scope="scope">
|
||||
<el-input-number v-model="scope.row.quantity" :min="0" :precision="2" size="small" style="width:90px" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="单价" width="130">
|
||||
<template slot-scope="scope">
|
||||
<el-input-number v-model="scope.row.unitPrice" :min="0" :precision="4" size="small" style="width:120px" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="金额" width="120" align="right">
|
||||
<template slot-scope="scope">
|
||||
<span style="color:#409EFF">{{ ((scope.row.quantity||0)*(scope.row.unitPrice||0)).toFixed(2) }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" width="60" align="center">
|
||||
<template slot-scope="scope">
|
||||
<el-button type="text" icon="el-icon-delete" @click="form.items.splice(scope.$index,1)" style="color:#f56c6c" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<el-button size="small" style="margin-top:8px" @click="form.items.push({materialName:'',unit:'',quantity:1,unitPrice:0})" icon="el-icon-plus">添加行</el-button>
|
||||
<el-form-item label="备注" style="margin-top:16px"><el-input v-model="form.remark" type="textarea" rows="2" /></el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer">
|
||||
<el-button @click="open=false">取消</el-button>
|
||||
<el-button type="primary" @click="submitForm">保存</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
|
||||
<el-drawer title="采购单详情" :visible.sync="detailOpen" size="720px">
|
||||
<div v-if="detailData" style="padding:20px">
|
||||
<el-descriptions :column="2" border>
|
||||
<el-descriptions-item label="采购单号">{{ detailData.poNo }}</el-descriptions-item>
|
||||
<el-descriptions-item label="供应商">{{ detailData.supplierName }}</el-descriptions-item>
|
||||
<el-descriptions-item label="总金额"><span style="color:#409EFF;font-size:18px;font-weight:bold">¥{{ detailData.totalAmount }}</span></el-descriptions-item>
|
||||
<el-descriptions-item label="状态"><el-tag :type="statusType(detailData.status)">{{ statusLabel(detailData.status) }}</el-tag></el-descriptions-item>
|
||||
<el-descriptions-item label="交货日期">{{ detailData.deliveryDate }}</el-descriptions-item>
|
||||
<el-descriptions-item label="交货地址">{{ detailData.deliveryAddr }}</el-descriptions-item>
|
||||
</el-descriptions>
|
||||
<el-divider>明细</el-divider>
|
||||
<el-table :data="detailData.items || []" border size="small">
|
||||
<el-table-column label="物料" prop="materialName" />
|
||||
<el-table-column label="规格" prop="spec" />
|
||||
<el-table-column label="数量" prop="quantity" align="right" />
|
||||
<el-table-column label="单价" prop="unitPrice" align="right" />
|
||||
<el-table-column label="金额" prop="totalPrice" align="right" />
|
||||
</el-table>
|
||||
</div>
|
||||
</el-drawer>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import { listPurchaseorder, getPurchaseorder, addPurchaseorder, updatePurchaseorder, confirmPurchaseorder, delPurchaseorder } from "@/api/bid/purchaseorder";
|
||||
import { listSupplier } from "@/api/bid/supplier";
|
||||
export default {
|
||||
name: "PurchaseOrder",
|
||||
data() {
|
||||
return {
|
||||
loading: false, total: 0, list: [],
|
||||
open: false, title: "", detailOpen: false, detailData: null,
|
||||
supplierOptions: [],
|
||||
queryParams: { pageNum: 1, pageSize: 10, poNo: null, status: null },
|
||||
form: { items: [], currency: "CNY" },
|
||||
rules: { supplierId: [{ required: true, message: "请选择供应商", trigger: "change" }] }
|
||||
};
|
||||
},
|
||||
created() { this.getList(); listSupplier({ pageSize: 200 }).then(r => { this.supplierOptions = r.rows || []; }); },
|
||||
methods: {
|
||||
getList() {
|
||||
this.loading = true;
|
||||
listPurchaseorder(this.queryParams).then(r => { this.list = r.rows; this.total = r.total; this.loading = false; });
|
||||
},
|
||||
handleQuery() { this.queryParams.pageNum = 1; this.getList(); },
|
||||
resetQuery() { this.resetForm("queryForm"); this.handleQuery(); },
|
||||
handleAdd() { this.form = { items: [], currency: "CNY", status: "draft" }; this.open = true; this.title = "新建采购单"; },
|
||||
handleUpdate(row) { getPurchaseorder(row.poId).then(r => { this.form = r.data; this.open = true; this.title = "编辑采购单"; }); },
|
||||
handleView(row) { getPurchaseorder(row.poId).then(r => { this.detailData = r.data; this.detailOpen = true; }); },
|
||||
handleConfirm(row) {
|
||||
this.$modal.confirm("确认提交采购单?").then(() => confirmPurchaseorder(row.poId))
|
||||
.then(() => { this.$modal.msgSuccess("已确认"); this.getList(); });
|
||||
},
|
||||
handleDelete(row) {
|
||||
this.$modal.confirm("确认删除?").then(() => delPurchaseorder(row.poId)).then(() => { this.getList(); this.$modal.msgSuccess("删除成功"); });
|
||||
},
|
||||
submitForm() {
|
||||
this.$refs["form"].validate(valid => {
|
||||
if (!valid) return;
|
||||
const action = this.form.poId ? updatePurchaseorder : addPurchaseorder;
|
||||
action(this.form).then(() => { this.$modal.msgSuccess("保存成功"); this.open = false; this.getList(); });
|
||||
});
|
||||
},
|
||||
statusType(s) { return { draft:"info", confirmed:"success", delivered:"", closed:"", disputed:"danger" }[s] || ""; },
|
||||
statusLabel(s) { return { draft:"草稿", confirmed:"已确认", delivered:"已交付", closed:"已关闭", disputed:"异议中" }[s] || s; }
|
||||
}
|
||||
};
|
||||
</script>
|
||||
210
ruoyi-ui/src/views/bid/quotation/index.vue
Normal file
210
ruoyi-ui/src/views/bid/quotation/index.vue
Normal file
@@ -0,0 +1,210 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-form :model="queryParams" size="small" :inline="true" ref="queryForm">
|
||||
<el-form-item label="状态" prop="status">
|
||||
<el-select v-model="queryParams.status" placeholder="全部" clearable style="width:120px">
|
||||
<el-option label="草稿" value="draft"/>
|
||||
<el-option label="已提交" value="submitted"/>
|
||||
<el-option label="已采纳" value="accepted"/>
|
||||
<el-option label="已拒绝" value="rejected"/>
|
||||
</el-select>
|
||||
</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">新增报价</el-button>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
<el-table v-loading="loading" :data="list">
|
||||
<el-table-column label="报价单号" prop="quoteNo" width="140" />
|
||||
<el-table-column label="RFQ编号" prop="rfqNo" width="140" />
|
||||
<el-table-column label="RFQ标题" prop="rfqTitle" :show-overflow-tooltip="true" />
|
||||
<el-table-column label="供应商" prop="supplierName" width="150" />
|
||||
<el-table-column label="总金额" prop="totalAmount" width="120" align="right">
|
||||
<template slot-scope="scope">
|
||||
<span style="color:#409EFF;font-weight:bold">¥{{ scope.row.totalAmount | numFormat }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="交期(天)" prop="deliveryDays" width="90" align="center" />
|
||||
<el-table-column label="状态" width="100">
|
||||
<template slot-scope="scope">
|
||||
<el-tag :type="statusType(scope.row.status)">{{ statusLabel(scope.row.status) }}</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="提交时间" prop="submitTime" width="160" />
|
||||
<el-table-column label="操作" align="center" width="200">
|
||||
<template slot-scope="scope">
|
||||
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)" v-if="scope.row.status==='draft'">编辑</el-button>
|
||||
<el-button size="mini" type="text" @click="handleSubmit(scope.row)" v-if="scope.row.status==='draft'" style="color:#67C23A">提交</el-button>
|
||||
<el-button size="mini" type="text" style="color:#67C23A" @click="handleAccept(scope.row)" v-if="scope.row.status==='submitted'">采纳</el-button>
|
||||
<el-button size="mini" type="text" style="color:#F56C6C" @click="handleReject(scope.row)" v-if="scope.row.status==='submitted'">拒绝</el-button>
|
||||
<el-button size="mini" type="text" icon="el-icon-view" @click="handleView(scope.row)">查看</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="960px" append-to-body>
|
||||
<el-form ref="form" :model="form" :rules="rules" label-width="100px">
|
||||
<el-row>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="关联RFQ" prop="rfqId">
|
||||
<el-select v-model="form.rfqId" placeholder="选择RFQ" filterable style="width:100%">
|
||||
<el-option v-for="r in rfqOptions" :key="r.rfqId" :label="r.rfqNo+' - '+r.rfqTitle" :value="r.rfqId" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="供应商" prop="supplierId">
|
||||
<el-select v-model="form.supplierId" placeholder="选择供应商" filterable style="width:100%">
|
||||
<el-option v-for="s in supplierOptions" :key="s.supplierId" :label="s.supplierName" :value="s.supplierId" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="有效期(天)" prop="validDays">
|
||||
<el-input-number v-model="form.validDays" :min="1" style="width:100%" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="交货期(天)" prop="deliveryDays">
|
||||
<el-input-number v-model="form.deliveryDays" :min="0" style="width:100%" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="币种" prop="currency">
|
||||
<el-select v-model="form.currency" style="width:100%">
|
||||
<el-option label="人民币 CNY" value="CNY"/>
|
||||
<el-option label="美元 USD" value="USD"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
<el-divider content-position="left">报价明细</el-divider>
|
||||
<el-table :data="form.items || []" border size="small">
|
||||
<el-table-column label="物料名称" min-width="150">
|
||||
<template slot-scope="scope"><el-input v-model="scope.row.materialName" size="small" /></template>
|
||||
</el-table-column>
|
||||
<el-table-column label="规格" min-width="120">
|
||||
<template slot-scope="scope"><el-input v-model="scope.row.spec" size="small" /></template>
|
||||
</el-table-column>
|
||||
<el-table-column label="单位" width="80">
|
||||
<template slot-scope="scope"><el-input v-model="scope.row.unit" size="small" /></template>
|
||||
</el-table-column>
|
||||
<el-table-column label="数量" width="100">
|
||||
<template slot-scope="scope">
|
||||
<el-input-number v-model="scope.row.quantity" :min="0" :precision="2" size="small" style="width:90px" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="单价" width="130">
|
||||
<template slot-scope="scope">
|
||||
<el-input-number v-model="scope.row.unitPrice" :min="0" :precision="4" size="small" style="width:120px" @change="calcTotal(scope.row)" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="金额" width="120" align="right">
|
||||
<template slot-scope="scope">
|
||||
<span style="color:#409EFF">{{ ((scope.row.quantity||0)*(scope.row.unitPrice||0)).toFixed(2) }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" width="60" align="center">
|
||||
<template slot-scope="scope">
|
||||
<el-button type="text" icon="el-icon-delete" @click="form.items.splice(scope.$index,1)" style="color:#f56c6c" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<el-button size="small" style="margin-top:8px" @click="form.items.push({ materialName:'',spec:'',unit:'',quantity:1,unitPrice:0,deliveryDays:0 })" icon="el-icon-plus">添加行</el-button>
|
||||
|
||||
<el-form-item label="备注" style="margin-top:16px"><el-input v-model="form.note" type="textarea" rows="2" /></el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer">
|
||||
<el-button @click="open=false">取消</el-button>
|
||||
<el-button type="primary" @click="submitForm">保存</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
|
||||
<!-- Detail drawer -->
|
||||
<el-drawer :title="'报价单详情'" :visible.sync="detailOpen" size="700px">
|
||||
<div v-if="detailData" style="padding:20px">
|
||||
<el-descriptions :column="2" border>
|
||||
<el-descriptions-item label="报价单号">{{ detailData.quoteNo }}</el-descriptions-item>
|
||||
<el-descriptions-item label="供应商">{{ detailData.supplierName }}</el-descriptions-item>
|
||||
<el-descriptions-item label="RFQ">{{ detailData.rfqNo }}</el-descriptions-item>
|
||||
<el-descriptions-item label="状态"><el-tag :type="statusType(detailData.status)">{{ statusLabel(detailData.status) }}</el-tag></el-descriptions-item>
|
||||
<el-descriptions-item label="总金额"><span style="color:#409EFF;font-size:18px;font-weight:bold">¥{{ detailData.totalAmount }}</span></el-descriptions-item>
|
||||
<el-descriptions-item label="交货期">{{ detailData.deliveryDays }} 天</el-descriptions-item>
|
||||
</el-descriptions>
|
||||
<el-divider>明细</el-divider>
|
||||
<el-table :data="detailData.items || []" border size="small">
|
||||
<el-table-column label="物料" prop="materialName" />
|
||||
<el-table-column label="规格" prop="spec" />
|
||||
<el-table-column label="数量" prop="quantity" align="right" />
|
||||
<el-table-column label="单价" prop="unitPrice" align="right" />
|
||||
<el-table-column label="金额" prop="totalPrice" align="right" />
|
||||
</el-table>
|
||||
</div>
|
||||
</el-drawer>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import { listQuotation, getQuotation, addQuotation, updateQuotation, submitQuotation, acceptQuotation, rejectQuotation } from "@/api/bid/quotation";
|
||||
import { listRfq } from "@/api/bid/rfq";
|
||||
import { listSupplier } from "@/api/bid/supplier";
|
||||
export default {
|
||||
name: "Quotation",
|
||||
filters: { numFormat: v => v ? Number(v).toFixed(2) : "0.00" },
|
||||
data() {
|
||||
return {
|
||||
loading: false, total: 0, list: [],
|
||||
open: false, title: "", detailOpen: false, detailData: null,
|
||||
rfqOptions: [], supplierOptions: [],
|
||||
queryParams: { pageNum: 1, pageSize: 10, status: null },
|
||||
form: { items: [], currency: "CNY", validDays: 30 },
|
||||
rules: {
|
||||
rfqId: [{ required: true, message: "请选择RFQ", trigger: "change" }],
|
||||
supplierId: [{ required: true, message: "请选择供应商", trigger: "change" }],
|
||||
}
|
||||
};
|
||||
},
|
||||
created() { this.getList(); this.loadOptions(); },
|
||||
methods: {
|
||||
getList() {
|
||||
this.loading = true;
|
||||
listQuotation(this.queryParams).then(r => { this.list = r.rows; this.total = r.total; this.loading = false; });
|
||||
},
|
||||
loadOptions() {
|
||||
listRfq({ pageSize: 200, status: "published" }).then(r => { this.rfqOptions = r.rows || []; });
|
||||
listSupplier({ pageSize: 200 }).then(r => { this.supplierOptions = r.rows || []; });
|
||||
},
|
||||
handleQuery() { this.queryParams.pageNum = 1; this.getList(); },
|
||||
resetQuery() { this.resetForm("queryForm"); this.handleQuery(); },
|
||||
handleAdd() { this.form = { items: [], currency: "CNY", validDays: 30, status: "draft" }; this.open = true; this.title = "新增报价"; },
|
||||
handleUpdate(row) { getQuotation(row.quotationId).then(r => { this.form = r.data; this.open = true; this.title = "编辑报价"; }); },
|
||||
handleView(row) { getQuotation(row.quotationId).then(r => { this.detailData = r.data; this.detailOpen = true; }); },
|
||||
handleSubmit(row) {
|
||||
this.$modal.confirm("确认提交报价?提交后不可修改").then(() => submitQuotation(row.quotationId))
|
||||
.then(() => { this.$modal.msgSuccess("提交成功"); this.getList(); });
|
||||
},
|
||||
handleAccept(row) { acceptQuotation(row.quotationId).then(() => { this.$modal.msgSuccess("已采纳"); this.getList(); }); },
|
||||
handleReject(row) { rejectQuotation(row.quotationId).then(() => { this.$modal.msgSuccess("已拒绝"); this.getList(); }); },
|
||||
submitForm() {
|
||||
this.$refs["form"].validate(valid => {
|
||||
if (!valid) return;
|
||||
const action = this.form.quotationId ? updateQuotation : addQuotation;
|
||||
action(this.form).then(() => { this.$modal.msgSuccess("保存成功"); this.open = false; this.getList(); });
|
||||
});
|
||||
},
|
||||
statusType(s) { return { draft:"info", submitted:"warning", accepted:"success", rejected:"danger" }[s] || ""; },
|
||||
statusLabel(s) { return { draft:"草稿", submitted:"已提交", accepted:"已采纳", rejected:"已拒绝" }[s] || s; },
|
||||
calcTotal(row) {}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
185
ruoyi-ui/src/views/bid/rfq/index.vue
Normal file
185
ruoyi-ui/src/views/bid/rfq/index.vue
Normal file
@@ -0,0 +1,185 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-form :model="queryParams" size="small" :inline="true" ref="queryForm">
|
||||
<el-form-item label="RFQ编号" prop="rfqNo">
|
||||
<el-input v-model="queryParams.rfqNo" placeholder="请输入RFQ编号" clearable @keyup.enter.native="handleQuery" />
|
||||
</el-form-item>
|
||||
<el-form-item label="标题" prop="rfqTitle">
|
||||
<el-input v-model="queryParams.rfqTitle" placeholder="请输入标题" clearable @keyup.enter.native="handleQuery" />
|
||||
</el-form-item>
|
||||
<el-form-item label="状态" prop="status">
|
||||
<el-select v-model="queryParams.status" placeholder="全部" clearable>
|
||||
<el-option label="草稿" value="draft"/>
|
||||
<el-option label="已发布" value="published"/>
|
||||
<el-option label="已关闭" value="closed"/>
|
||||
<el-option label="已完成" value="completed"/>
|
||||
</el-select>
|
||||
</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">新建报价请求</el-button>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
<el-table v-loading="loading" :data="list">
|
||||
<el-table-column label="RFQ编号" prop="rfqNo" width="150" />
|
||||
<el-table-column label="标题" prop="rfqTitle" :show-overflow-tooltip="true" />
|
||||
<el-table-column label="截止日期" prop="deadline" width="160" />
|
||||
<el-table-column label="状态" width="100">
|
||||
<template slot-scope="scope">
|
||||
<el-tag :type="statusType(scope.row.status)">{{ statusLabel(scope.row.status) }}</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="创建时间" prop="createTime" width="160" />
|
||||
<el-table-column label="操作" align="center" width="200">
|
||||
<template slot-scope="scope">
|
||||
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)" v-if="scope.row.status==='draft'">编辑</el-button>
|
||||
<el-button size="mini" type="text" icon="el-icon-s-promotion" @click="handlePublish(scope.row)" v-if="scope.row.status==='draft'">发布</el-button>
|
||||
<el-button size="mini" type="text" icon="el-icon-view" @click="handleView(scope.row)">详情</el-button>
|
||||
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)" v-if="scope.row.status==='draft'">删除</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" />
|
||||
|
||||
<!-- Create/Edit Dialog -->
|
||||
<el-dialog :title="title" :visible.sync="open" width="900px" append-to-body>
|
||||
<el-form ref="form" :model="form" :rules="rules" label-width="100px">
|
||||
<el-row>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="RFQ标题" prop="rfqTitle">
|
||||
<el-input v-model="form.rfqTitle" placeholder="请输入标题" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="截止日期" prop="deadline">
|
||||
<el-date-picker v-model="form.deadline" type="datetime" placeholder="选择截止日期" value-format="yyyy-MM-dd HH:mm:ss" style="width:100%" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-form-item label="交货地址" prop="deliveryAddr">
|
||||
<el-input v-model="form.deliveryAddr" placeholder="请输入交货地址" />
|
||||
</el-form-item>
|
||||
|
||||
<el-divider content-position="left">物料明细</el-divider>
|
||||
<el-table :data="form.items || []" border size="small">
|
||||
<el-table-column label="物料名称" min-width="150">
|
||||
<template slot-scope="scope">
|
||||
<el-input v-model="scope.row.materialName" size="small" placeholder="物料名称" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="规格型号" min-width="130">
|
||||
<template slot-scope="scope">
|
||||
<el-input v-model="scope.row.spec" size="small" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="单位" width="80">
|
||||
<template slot-scope="scope">
|
||||
<el-input v-model="scope.row.unit" size="small" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="数量" width="100">
|
||||
<template slot-scope="scope">
|
||||
<el-input-number v-model="scope.row.quantity" :min="0" :precision="2" size="small" style="width:90px" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="预期单价" width="120">
|
||||
<template slot-scope="scope">
|
||||
<el-input-number v-model="scope.row.expectedPrice" :min="0" :precision="2" size="small" style="width:110px" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" width="60" align="center">
|
||||
<template slot-scope="scope">
|
||||
<el-button type="text" icon="el-icon-delete" @click="removeItem(scope.$index)" style="color:#f56c6c" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<el-button size="small" style="margin-top:8px" @click="addItem" icon="el-icon-plus">添加物料行</el-button>
|
||||
|
||||
<el-form-item label="备注" prop="remark" style="margin-top:16px">
|
||||
<el-input v-model="form.remark" type="textarea" rows="2" />
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer">
|
||||
<el-button @click="open=false">取消</el-button>
|
||||
<el-button type="primary" @click="submitForm">保存草稿</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
|
||||
<!-- Publish Dialog -->
|
||||
<el-dialog title="发布报价请求" :visible.sync="publishOpen" width="500px" append-to-body>
|
||||
<p>选择要邀请报价的供应商:</p>
|
||||
<el-checkbox-group v-model="selectedSuppliers">
|
||||
<el-checkbox v-for="s in supplierOptions" :key="s.supplierId" :label="s.supplierId">{{ s.supplierName }}</el-checkbox>
|
||||
</el-checkbox-group>
|
||||
<div slot="footer">
|
||||
<el-button @click="publishOpen=false">取消</el-button>
|
||||
<el-button type="primary" @click="doPublish">确认发布</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { listRfq, getRfq, addRfq, updateRfq, publishRfq, delRfq } from "@/api/bid/rfq";
|
||||
import { listSupplier } from "@/api/bid/supplier";
|
||||
export default {
|
||||
name: "Rfq",
|
||||
data() {
|
||||
return {
|
||||
loading: false, total: 0, list: [],
|
||||
open: false, title: "",
|
||||
publishOpen: false, publishRfqId: null, selectedSuppliers: [], supplierOptions: [],
|
||||
queryParams: { pageNum: 1, pageSize: 10, rfqNo: null, rfqTitle: null, status: null },
|
||||
form: { items: [] },
|
||||
rules: { rfqTitle: [{ required: true, message: "标题不能为空", trigger: "blur" }] }
|
||||
};
|
||||
},
|
||||
created() { this.getList(); this.loadSuppliers(); },
|
||||
methods: {
|
||||
getList() {
|
||||
this.loading = true;
|
||||
listRfq(this.queryParams).then(r => { this.list = r.rows; this.total = r.total; this.loading = false; });
|
||||
},
|
||||
loadSuppliers() {
|
||||
listSupplier({ pageSize: 100 }).then(r => { this.supplierOptions = r.rows || []; });
|
||||
},
|
||||
handleQuery() { this.queryParams.pageNum = 1; this.getList(); },
|
||||
resetQuery() { this.resetForm("queryForm"); this.handleQuery(); },
|
||||
handleAdd() {
|
||||
this.form = { items: [], status: "draft" };
|
||||
this.open = true; this.title = "新建报价请求";
|
||||
},
|
||||
handleUpdate(row) {
|
||||
getRfq(row.rfqId).then(r => { this.form = r.data; this.open = true; this.title = "编辑报价请求"; });
|
||||
},
|
||||
handleView(row) { this.$router.push({ path: "/bid/rfq/detail", query: { rfqId: row.rfqId } }); },
|
||||
handlePublish(row) { this.publishRfqId = row.rfqId; this.selectedSuppliers = []; this.publishOpen = true; },
|
||||
doPublish() {
|
||||
publishRfq(this.publishRfqId, this.selectedSuppliers).then(() => {
|
||||
this.$modal.msgSuccess("发布成功"); this.publishOpen = false; this.getList();
|
||||
});
|
||||
},
|
||||
handleDelete(row) {
|
||||
this.$modal.confirm("确认删除?").then(() => delRfq(row.rfqId)).then(() => { this.getList(); this.$modal.msgSuccess("删除成功"); });
|
||||
},
|
||||
addItem() { if (!this.form.items) this.form.items = []; this.form.items.push({ materialName: "", spec: "", unit: "", quantity: 1, expectedPrice: null }); },
|
||||
removeItem(idx) { this.form.items.splice(idx, 1); },
|
||||
submitForm() {
|
||||
this.$refs["form"].validate(valid => {
|
||||
if (!valid) return;
|
||||
const action = this.form.rfqId ? updateRfq : addRfq;
|
||||
action(this.form).then(() => { this.$modal.msgSuccess("保存成功"); this.open = false; this.getList(); });
|
||||
});
|
||||
},
|
||||
statusType(s) { return { draft:"info", published:"warning", closed:"", completed:"success" }[s] || ""; },
|
||||
statusLabel(s) { return { draft:"草稿", published:"已发布", closed:"已关闭", completed:"已完成" }[s] || s; }
|
||||
}
|
||||
};
|
||||
</script>
|
||||
103
ruoyi-ui/src/views/bid/supplier/index.vue
Normal file
103
ruoyi-ui/src/views/bid/supplier/index.vue
Normal file
@@ -0,0 +1,103 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true">
|
||||
<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">新增</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-row>
|
||||
<el-table v-loading="loading" :data="list" @selection-change="s => { this.multiple = !s.length; this.ids = s.map(r => r.supplierId) }">
|
||||
<el-table-column type="selection" width="55" align="center" />
|
||||
<el-table-column label="供应商名称" prop="supplierName" />
|
||||
<el-table-column label="联系人" prop="contact" width="100" />
|
||||
<el-table-column label="手机" prop="phone" width="130" />
|
||||
<el-table-column label="邮箱" prop="email" />
|
||||
<el-table-column label="地址" prop="address" :show-overflow-tooltip="true" />
|
||||
<el-table-column label="状态" width="80">
|
||||
<template slot-scope="scope">
|
||||
<el-tag :type="scope.row.status === '0' ? 'success' : 'danger'">{{ scope.row.status === '0' ? '启用' : '禁用' }}</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" align="center" width="160">
|
||||
<template slot-scope="scope">
|
||||
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)">修改</el-button>
|
||||
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)">删除</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="580px" append-to-body>
|
||||
<el-form ref="form" :model="form" :rules="rules" label-width="90px">
|
||||
<el-form-item label="供应商名称" prop="supplierName">
|
||||
<el-input v-model="form.supplierName" placeholder="请输入供应商名称" />
|
||||
</el-form-item>
|
||||
<el-row>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="联系人" prop="contact"><el-input v-model="form.contact" /></el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="手机" prop="phone"><el-input v-model="form.phone" /></el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-form-item label="邮箱" prop="email"><el-input v-model="form.email" /></el-form-item>
|
||||
<el-form-item label="地址" prop="address"><el-input v-model="form.address" /></el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer">
|
||||
<el-button @click="cancel">取消</el-button>
|
||||
<el-button type="primary" @click="submitForm">确定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import { listSupplier, getSupplier, addSupplier, updateSupplier, delSupplier } from "@/api/bid/supplier";
|
||||
export default {
|
||||
name: "Supplier",
|
||||
data() {
|
||||
return {
|
||||
loading: false, multiple: true, total: 0, list: [], ids: [],
|
||||
open: false, title: "",
|
||||
queryParams: { pageNum: 1, pageSize: 10, supplierName: null },
|
||||
form: {},
|
||||
rules: { supplierName: [{ required: true, message: "供应商名称不能为空", trigger: "blur" }] }
|
||||
};
|
||||
},
|
||||
created() { this.getList(); },
|
||||
methods: {
|
||||
getList() {
|
||||
this.loading = true;
|
||||
listSupplier(this.queryParams).then(res => { this.list = res.rows; this.total = res.total; this.loading = false; });
|
||||
},
|
||||
handleQuery() { this.queryParams.pageNum = 1; this.getList(); },
|
||||
resetQuery() { this.resetForm("queryForm"); this.handleQuery(); },
|
||||
handleAdd() { this.form = { status: "0" }; this.open = true; this.title = "新增供应商"; },
|
||||
handleUpdate(row) {
|
||||
getSupplier(row.supplierId).then(res => { this.form = res.data; this.open = true; this.title = "修改供应商"; });
|
||||
},
|
||||
handleDelete(row) {
|
||||
const ids = row.supplierId || this.ids.join(",");
|
||||
this.$modal.confirm("确认删除?").then(() => delSupplier(ids)).then(() => { this.getList(); this.$modal.msgSuccess("删除成功"); });
|
||||
},
|
||||
cancel() { this.open = false; },
|
||||
submitForm() {
|
||||
this.$refs["form"].validate(valid => {
|
||||
if (!valid) return;
|
||||
const action = this.form.supplierId ? updateSupplier : addSupplier;
|
||||
action(this.form).then(() => { this.$modal.msgSuccess("操作成功"); this.open = false; this.getList(); });
|
||||
});
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
78
ruoyi-ui/src/views/bid/tenant/index.vue
Normal file
78
ruoyi-ui/src/views/bid/tenant/index.vue
Normal file
@@ -0,0 +1,78 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-row :gutter="10" class="mb8">
|
||||
<el-col :span="1.5">
|
||||
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd">新增租户</el-button>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-table v-loading="loading" :data="list">
|
||||
<el-table-column label="租户ID" prop="tenantId" width="80" />
|
||||
<el-table-column label="租户名称" prop="tenantName" />
|
||||
<el-table-column label="联系人" prop="contact" width="100" />
|
||||
<el-table-column label="手机" prop="phone" width="130" />
|
||||
<el-table-column label="邮箱" prop="email" />
|
||||
<el-table-column label="状态" width="80">
|
||||
<template slot-scope="scope">
|
||||
<el-tag :type="scope.row.status==='0' ? 'success' : 'danger'">{{ scope.row.status==='0' ? '正常' : '停用' }}</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="创建时间" prop="createTime" width="160" />
|
||||
<el-table-column label="操作" align="center" width="160">
|
||||
<template slot-scope="scope">
|
||||
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)">修改</el-button>
|
||||
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)">删除</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="90px">
|
||||
<el-form-item label="租户名称" prop="tenantName"><el-input v-model="form.tenantName" /></el-form-item>
|
||||
<el-row>
|
||||
<el-col :span="12"><el-form-item label="联系人" prop="contact"><el-input v-model="form.contact" /></el-form-item></el-col>
|
||||
<el-col :span="12"><el-form-item label="手机" prop="phone"><el-input v-model="form.phone" /></el-form-item></el-col>
|
||||
</el-row>
|
||||
<el-form-item label="邮箱" prop="email"><el-input v-model="form.email" /></el-form-item>
|
||||
<el-form-item label="备注" prop="remark"><el-input v-model="form.remark" type="textarea" rows="2" /></el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer">
|
||||
<el-button @click="open=false">取消</el-button>
|
||||
<el-button type="primary" @click="submitForm">确定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import { listTenant, getTenant, addTenant, updateTenant, delTenant } from "@/api/bid/tenant";
|
||||
export default {
|
||||
name: "Tenant",
|
||||
data() {
|
||||
return {
|
||||
loading: false, total: 0, list: [], open: false, title: "",
|
||||
queryParams: { pageNum: 1, pageSize: 10 },
|
||||
form: {},
|
||||
rules: { tenantName: [{ required: true, message: "租户名称不能为空", trigger: "blur" }] }
|
||||
};
|
||||
},
|
||||
created() { this.getList(); },
|
||||
methods: {
|
||||
getList() {
|
||||
this.loading = true;
|
||||
listTenant(this.queryParams).then(r => { this.list = r.rows; this.total = r.total; this.loading = false; });
|
||||
},
|
||||
handleAdd() { this.form = { status: "0" }; this.open = true; this.title = "新增租户"; },
|
||||
handleUpdate(row) { getTenant(row.tenantId).then(r => { this.form = r.data; this.open = true; this.title = "修改租户"; }); },
|
||||
handleDelete(row) {
|
||||
this.$modal.confirm("确认删除?").then(() => delTenant(row.tenantId)).then(() => { this.getList(); this.$modal.msgSuccess("删除成功"); });
|
||||
},
|
||||
submitForm() {
|
||||
this.$refs["form"].validate(v => {
|
||||
if (!v) return;
|
||||
const action = this.form.tenantId ? updateTenant : addTenant;
|
||||
action(this.form).then(() => { this.$modal.msgSuccess("操作成功"); this.open = false; this.getList(); });
|
||||
});
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
66
ruoyi-ui/src/views/bid/transaction/index.vue
Normal file
66
ruoyi-ui/src/views/bid/transaction/index.vue
Normal file
@@ -0,0 +1,66 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-form :model="queryParams" size="small" :inline="true">
|
||||
<el-form-item label="类型">
|
||||
<el-select v-model="queryParams.txType" clearable placeholder="全部" style="width:110px">
|
||||
<el-option label="RFQ" value="RFQ"/>
|
||||
<el-option label="报价" value="QUOTE"/>
|
||||
<el-option label="采购单" value="PO"/>
|
||||
<el-option label="评价" value="EVAL"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="时间范围">
|
||||
<el-date-picker v-model="dateRange" type="daterange" range-separator="-" start-placeholder="开始" end-placeholder="结束"
|
||||
value-format="yyyy-MM-dd" @change="handleDateRange" style="width:240px" />
|
||||
</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-table v-loading="loading" :data="list" stripe>
|
||||
<el-table-column label="交易编号" prop="txNo" width="160" />
|
||||
<el-table-column label="类型" width="90">
|
||||
<template slot-scope="scope">
|
||||
<el-tag size="small" :type="typeColor(scope.row.txType)">{{ scope.row.txType }}</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="供应商" prop="supplierName" width="150" />
|
||||
<el-table-column label="采购单号" prop="poNo" width="150" />
|
||||
<el-table-column label="金额" prop="amount" width="130" align="right">
|
||||
<template slot-scope="scope">
|
||||
<span v-if="scope.row.amount" style="color:#409EFF">¥{{ scope.row.amount }}</span>
|
||||
<span v-else style="color:#909399">-</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="描述" prop="description" :show-overflow-tooltip="true" />
|
||||
<el-table-column label="操作人" prop="operator" width="100" />
|
||||
<el-table-column label="交易时间" prop="txTime" width="160" />
|
||||
</el-table>
|
||||
<pagination v-show="total>0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize" @pagination="getList" />
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import { listTransaction } from "@/api/bid/transaction";
|
||||
export default {
|
||||
name: "Transaction",
|
||||
data() {
|
||||
return {
|
||||
loading: false, total: 0, list: [], dateRange: [],
|
||||
queryParams: { pageNum: 1, pageSize: 10, txType: null, beginTime: null, endTime: null }
|
||||
};
|
||||
},
|
||||
created() { this.getList(); },
|
||||
methods: {
|
||||
getList() {
|
||||
this.loading = true;
|
||||
listTransaction(this.queryParams).then(r => { this.list = r.rows; this.total = r.total; this.loading = false; });
|
||||
},
|
||||
handleQuery() { this.queryParams.pageNum = 1; this.getList(); },
|
||||
resetQuery() { this.dateRange = []; this.queryParams = { pageNum: 1, pageSize: 10, txType: null, beginTime: null, endTime: null }; this.getList(); },
|
||||
handleDateRange(v) { this.queryParams.beginTime = v ? v[0] : null; this.queryParams.endTime = v ? v[1] : null; },
|
||||
typeColor(t) { return { RFQ:"info", QUOTE:"warning", PO:"primary", EVAL:"success" }[t] || ""; }
|
||||
}
|
||||
};
|
||||
</script>
|
||||
Reference in New Issue
Block a user