finish 完成上料信息“
This commit is contained in:
@@ -2,23 +2,23 @@ import TableOperaionComponent from "@/components/noTemplateComponents/operationC
|
||||
import switchBtn from "@/components/noTemplateComponents/switchBtn";
|
||||
import QuillRichInput from "@/components/noTemplateComponents/richInput";
|
||||
import request from "@/utils/request";
|
||||
import { timeFilter } from '@/utils/filters'
|
||||
import { timeFilter } from "@/utils/filters";
|
||||
|
||||
export default function () {
|
||||
const tableProps = [
|
||||
{ type: 'index', label: '序号' },
|
||||
{ type: "index", label: "序号" },
|
||||
{ prop: "createTime", label: "添加时间", filter: timeFilter },
|
||||
{ prop: "startTime", label: "上料时间", filter: timeFilter },
|
||||
{ prop: "endTime", label: "结束上料时间", filter: timeFilter },
|
||||
{ prop: "material", label: "物料" },
|
||||
{ prop: "qty", label: "上料数量" },
|
||||
{ prop: "storeCOde", label: "料仓" },
|
||||
{ prop: "storeCode", label: "料仓" },
|
||||
{ prop: "upPos", label: "上料位点" },
|
||||
// { prop: "typeDictValue", label: "过渡车", filter: val => ['否', '是'][val] },
|
||||
// { prop: "enabled", label: "状态", subcomponent: switchBtn }, // subcomponent
|
||||
// { prop: "currentQty", label: "载量" },
|
||||
// { prop: "currentPos", label: "当前位置" },
|
||||
{ prop: "description", label: "描述" },
|
||||
// { prop: "description", label: "描述" },
|
||||
{ prop: "remark", label: "备注" },
|
||||
{
|
||||
prop: "operations",
|
||||
@@ -32,38 +32,39 @@ export default function () {
|
||||
|
||||
const headFormFields = [
|
||||
{
|
||||
prop: 'materialId',
|
||||
prop: "materialId",
|
||||
label: "物料",
|
||||
// default: { value: "" },
|
||||
select: [],
|
||||
// 绑定数据获取函数
|
||||
fn: () => this.$http.get('/pms/material/page', { params: { page: 1, limit: 999 } }),
|
||||
fn: () => this.$http.get("/pms/material/page", { params: { page: 1, limit: 999 } }),
|
||||
bind: {
|
||||
placeholder: '请选择物料',
|
||||
filterable: true
|
||||
}
|
||||
placeholder: "请选择物料",
|
||||
filterable: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
prop: 'storeId',
|
||||
prop: "storeId",
|
||||
label: "日料仓",
|
||||
fieldOptionLabel: 'code', // 把料仓筛选条件的label改为展示code,而不是展示name
|
||||
select: [],
|
||||
// default: { value: "" },
|
||||
fn: () => this.$http.get('/pms/materialStorage/page', { params: { page: 1, limit: 999, typeDictValue: '1' } }),
|
||||
fn: () => this.$http.get("/pms/materialStorage/page", { params: { page: 1, limit: 999, typeDictValue: "1" } }),
|
||||
bind: {
|
||||
placeholder: '请选择日料仓',
|
||||
filterable: true
|
||||
}
|
||||
placeholder: "请选择日料仓",
|
||||
filterable: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
timerange: true,
|
||||
prop: 'timerange', // 应该是个数组,在提交数据时需单独处理
|
||||
label: '时间段',
|
||||
prop: "timerange", // 应该是个数组,在提交数据时需单独处理
|
||||
label: "时间段",
|
||||
bind: {
|
||||
placeholder: '选择日期时间',
|
||||
type: 'datetimerange',
|
||||
placeholder: "选择日期时间",
|
||||
type: "datetimerange",
|
||||
"start-placeholder": "开始时间",
|
||||
"end-placeholder": "结束时间",
|
||||
}
|
||||
},
|
||||
},
|
||||
{
|
||||
button: {
|
||||
@@ -75,11 +76,11 @@ export default function () {
|
||||
button: {
|
||||
type: "primary",
|
||||
name: "新增",
|
||||
permission: "pms:materialStorage:save"
|
||||
permission: "pms:materialStorage:save",
|
||||
},
|
||||
bind: {
|
||||
plain: true,
|
||||
}
|
||||
},
|
||||
},
|
||||
];
|
||||
|
||||
@@ -94,20 +95,19 @@ export default function () {
|
||||
rows: [
|
||||
[
|
||||
{
|
||||
input: true,
|
||||
datetime: true,
|
||||
label: "上料时间",
|
||||
prop: "name",
|
||||
prop: "startTime",
|
||||
rules: { required: true, message: "必填项不能为空", trigger: "blur" },
|
||||
elparams: { placeholder: "请输入上料时间" },
|
||||
elparams: { placeholder: "请选择上料时间", type: "datetime" },
|
||||
},
|
||||
|
||||
{
|
||||
input: true,
|
||||
datetime: true,
|
||||
label: "结束上料时间",
|
||||
prop: "name",
|
||||
prop: "endTime",
|
||||
rules: { required: true, message: "必填项不能为空", trigger: "blur" },
|
||||
elparams: { placeholder: "请输入结束上料时间" },
|
||||
}
|
||||
elparams: { placeholder: "请选择结束上料时间", type: "datetime" },
|
||||
},
|
||||
],
|
||||
[
|
||||
{
|
||||
@@ -115,7 +115,7 @@ export default function () {
|
||||
label: "物料",
|
||||
prop: "materialId",
|
||||
options: [],
|
||||
fetchData: () => this.$http('/pms/material/page', { params: { page: 1, size: 999 } }),
|
||||
fetchData: () => this.$http("/pms/material/page", { params: { page: 1, size: 999 } }),
|
||||
rules: { required: true, message: "必填项不能为空", trigger: "blur" },
|
||||
elparams: { placeholder: "请选择物料", filterable: true },
|
||||
},
|
||||
@@ -125,7 +125,10 @@ export default function () {
|
||||
prop: "qty",
|
||||
// options: [],
|
||||
// fetchData: () => this.$http('/pms/material/page', { params: { page: 1, size: 999 } }),
|
||||
rules: { required: true, message: "必填项不能为空", trigger: "blur" },
|
||||
rules: [
|
||||
{ required: true, message: "必填项不能为空", trigger: "blur" },
|
||||
{ type: "number", message: "请输入正确的数字", trigger: "blur", transform: (val) => Number(val) },
|
||||
],
|
||||
elparams: { placeholder: "请输入上料数量" },
|
||||
},
|
||||
],
|
||||
@@ -136,7 +139,7 @@ export default function () {
|
||||
label: "料仓",
|
||||
prop: "storeId",
|
||||
options: [],
|
||||
fetchData: () => this.$http('/pms/materialStorage/page', { params: { page: 1, size: 999 } }),
|
||||
fetchData: () => this.$http("/pms/materialStorage/page", { params: { page: 1, size: 999, typeDictValue: '1' } }),
|
||||
rules: { required: true, message: "必填项不能为空", trigger: "blur" },
|
||||
elparams: { placeholder: "请选择料仓", filterable: true },
|
||||
},
|
||||
@@ -185,4 +188,3 @@ export default function () {
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user