update docs0918
This commit is contained in:
rodzic
3c44fbc636
commit
33d13b3eb4
@ -40,8 +40,8 @@
|
||||
// window.SITE_CONFIG['apiURL'] = 'http://192.168.1.103:8080/pms-am';
|
||||
// window.SITE_CONFIG['apiURL'] = 'http://192.168.1.49:8080/pms-am'; // tengyun
|
||||
// window.SITE_CONFIG['apiURL'] = 'http://192.168.1.67:8080/pms-am'; // wenzhang
|
||||
// window.SITE_CONFIG['apiURL'] = 'http://192.168.1.62:8080/pms-am'; // tao
|
||||
window.SITE_CONFIG['apiURL'] = 'http://192.168.1.21:8080/pms-am'; // xv
|
||||
window.SITE_CONFIG['apiURL'] = 'http://192.168.1.62:8080/pms-am'; // tao
|
||||
// window.SITE_CONFIG['apiURL'] = 'http://192.168.1.21:8080/pms-am'; // xv
|
||||
// window.SITE_CONFIG['apiURL'] = 'http://localhost:3000/p//////ms-am'; // xv
|
||||
</script>
|
||||
<% } %>
|
||||
|
@ -100,15 +100,6 @@ export default {
|
||||
methods: {
|
||||
/** init **/
|
||||
init(id) {
|
||||
if (!id) {
|
||||
this.$message({
|
||||
message: `没有传 id!`,
|
||||
type: "error",
|
||||
duration: 1500,
|
||||
});
|
||||
//console.log("[*] 传入car payload对话框的id是", id);
|
||||
return;
|
||||
}
|
||||
this.showPaination = false;
|
||||
this.id = id;
|
||||
this.getList();
|
||||
|
@ -659,6 +659,14 @@ export default {
|
||||
},
|
||||
|
||||
openCarPayloadDialog(id) {
|
||||
if (!id) {
|
||||
//console.log("[*] 传入car payload对话框的id是", id);
|
||||
return this.$message({
|
||||
message: `没有传 id!`,
|
||||
type: "error",
|
||||
duration: 1500,
|
||||
});
|
||||
}
|
||||
this.carPayloadDialogVisible = true;
|
||||
this.$nextTick(() => {
|
||||
this.$refs["car-payload-dialog"].init(id);
|
||||
|
143
src/views/modules/pms/agvList/config.js
Normal file
143
src/views/modules/pms/agvList/config.js
Normal file
@ -0,0 +1,143 @@
|
||||
import TableOperaionComponent from "@/components/noTemplateComponents/operationComponent";
|
||||
// import switchBtn from "@/components/noTemplateComponents/switchBtn";
|
||||
import TableTextComponent from '@/components/noTemplateComponents/detailComponent'
|
||||
import request from "@/utils/request";
|
||||
import { timeFilter, dictFilter } from "@/utils/filters";
|
||||
|
||||
export default function () {
|
||||
const tableProps = [
|
||||
{ type: "index", label: "序号" },
|
||||
{ prop: "name", label: "库位" },
|
||||
{ prop: "order", label: "订单" },
|
||||
{ prop: "orderSub", label: "子号" },
|
||||
{ prop: "batchNo", label: "批次号" },
|
||||
{ prop: "gradeId", label: "配方" },
|
||||
{ prop: "status", label: "状态", filter: val => (val != null) ? ['空库位', '满料盅', '空料盅'][val] : '-' },
|
||||
];
|
||||
|
||||
const now = new Date();
|
||||
const [y, m, d] = [now.getFullYear(), now.getMonth(), now.getDate()];
|
||||
const today = new Date(y, m, d, 0, 0, 0, 0).getTime();
|
||||
const headFormFields = [
|
||||
{
|
||||
// prop: "key",
|
||||
label: "AGV库位",
|
||||
},
|
||||
{
|
||||
button: {
|
||||
type: "primary",
|
||||
permission: 'pms:agvList:info',
|
||||
name: "刷新",
|
||||
},
|
||||
},
|
||||
// {
|
||||
// button: {
|
||||
// type: "primary",
|
||||
// name: "新增",
|
||||
// permission: "",
|
||||
// },
|
||||
// bind: {
|
||||
// plain: true,
|
||||
// },
|
||||
// },
|
||||
];
|
||||
|
||||
/**
|
||||
* dialog config 有两个版本,一个适用于 DialogWithMenu 组件,另一个适用于 DialogJustForm 组件
|
||||
* 适用于 DialogWithMenu 组件的配置示例详见 blenderStep/config.js
|
||||
* 此为后者的配置:
|
||||
*/
|
||||
const dialogJustFormConfigs = {
|
||||
form: {
|
||||
rows: [
|
||||
[
|
||||
{
|
||||
input: true,
|
||||
label: "批次号",
|
||||
prop: "batchNo",
|
||||
// rules: { required: true, message: "必填项不能为空", trigger: "blur" },
|
||||
elparams: { placeholder: "-" },
|
||||
},
|
||||
],
|
||||
[
|
||||
{
|
||||
input: true,
|
||||
label: "配方",
|
||||
prop: "bom",
|
||||
// rules: { required: true, message: "必填项不能为空", trigger: "blur" },
|
||||
elparams: { placeholder: "-" },
|
||||
},
|
||||
],
|
||||
[
|
||||
{
|
||||
input: true,
|
||||
label: "重量",
|
||||
prop: "batchSize",
|
||||
// rules: { required: true, message: "必填项不能为空", trigger: "blur" },
|
||||
elparams: { placeholder: "-" },
|
||||
},
|
||||
],
|
||||
// [
|
||||
// {
|
||||
// select: true,
|
||||
// label: "所属工厂",
|
||||
// prop: "factoryId",
|
||||
// fetchData: () => this.$http.get("/pms/factory/page", { params: { limit: 999, page: 1 } }),
|
||||
// options: [],
|
||||
// rules: { required: true, message: "必填项不能为空", trigger: "change" },
|
||||
// },
|
||||
// {
|
||||
// input: true,
|
||||
// label: "产线TT值",
|
||||
// prop: "tvalue",
|
||||
// rules: [
|
||||
// { required: true, message: "必填项不能为空", trigger: "blur" },
|
||||
// { type: "number", message: "数字", trigger: "blur", transform: (val) => Number(val) },
|
||||
// ],
|
||||
// elparams: { placeholder: "设定TT值(每小时下片数量)" },
|
||||
// },
|
||||
// ],
|
||||
// [
|
||||
// { input: true, label: "规格", prop: "specifications", elparams: { placeholder: "规格" } },
|
||||
// {
|
||||
// input: true,
|
||||
// label: "重量",
|
||||
// prop: "externalCode",
|
||||
// rules: [{ type: 'number', trigger: "blur", message: "请输入数字类型", transform: val => Number(val) }],
|
||||
// elparams: { placeholder: "外部编码" },
|
||||
// },
|
||||
// { input: true, label: "短描述", prop: "shortDesc", elparams: { placeholder: "短描述" } },
|
||||
// ],
|
||||
// [{ textarea: true, label: "描述", prop: "description", elparams: { placeholder: "描述" } }],
|
||||
// [{ input: true, label: "备注", prop: "remark", elparams: { placeholder: "备注" } }],
|
||||
],
|
||||
operations: [
|
||||
// { name: "add", label: "保存", type: "primary", permission: "pms:shape:save", showOnEdit: false },
|
||||
// { name: "update", label: "更新", type: "primary", permission: "pms:shape:update", showOnEdit: true },
|
||||
// { name: "reset", label: "重置", type: "warning", showAlways: true },
|
||||
// { name: 'cancel', label: '取消', showAlways: true },
|
||||
],
|
||||
},
|
||||
};
|
||||
// 备注:弹窗弹出的时间和网速有关......
|
||||
|
||||
return {
|
||||
dialogConfigs: dialogJustFormConfigs,
|
||||
tableConfig: {
|
||||
table: null, // 此处可省略,el-table 上的配置项
|
||||
column: tableProps, // el-column-item 上的配置项
|
||||
},
|
||||
headFormConfigs: {
|
||||
rules: null, // 名称是由 BaseSearchForm.vue 组件固定的
|
||||
fields: headFormFields, // 名称是由 BaseSearchForm.vue 组件固定的
|
||||
},
|
||||
urls: {
|
||||
base: "/pms/trans/agvVisual",
|
||||
page: "/pms/trans/agvVisual",
|
||||
// detach: "/pms/agvTrans/delivery"
|
||||
// subase: '/pms/blenderStepParam',
|
||||
// subpage: '/pms/blenderStepParam/page',
|
||||
// more...
|
||||
},
|
||||
};
|
||||
}
|
80
src/views/modules/pms/agvList/index.vue
Normal file
80
src/views/modules/pms/agvList/index.vue
Normal file
@ -0,0 +1,80 @@
|
||||
<template>
|
||||
<!-- <ListViewWithHead
|
||||
:table-config="tableConfig"
|
||||
:head-config="headFormConfigs"
|
||||
:dialog-configs="dialogConfigs" /> -->
|
||||
|
||||
<div class="list-view-with-head">
|
||||
<BaseSearchForm :head-config="headFormConfigs" @btn-click="handleBtnClick" />
|
||||
|
||||
<BaseListTable
|
||||
v-loading="tableLoading"
|
||||
:table-config="tableConfig.table"
|
||||
:column-config="tableConfig.column"
|
||||
:table-data="dataList"
|
||||
:refresh-layout-key="refreshLayoutKey" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import BaseListTable from "@/components/BaseListTable.vue";
|
||||
import initConfig from "./config";
|
||||
import BaseSearchForm from "@/components/BaseSearchForm.vue";
|
||||
|
||||
export default {
|
||||
name: "AGVList",
|
||||
components: { BaseListTable, BaseSearchForm },
|
||||
provide() {
|
||||
return {
|
||||
urls: this.allUrls,
|
||||
};
|
||||
},
|
||||
data() {
|
||||
const { tableConfig, headFormConfigs, urls, dialogConfigs } = initConfig.call(this);
|
||||
return {
|
||||
tableLoading: false,
|
||||
dataList: [],
|
||||
refreshLayoutKey: Math.random(),
|
||||
tableConfig,
|
||||
headFormConfigs,
|
||||
allUrls: urls,
|
||||
dialogConfigs,
|
||||
};
|
||||
},
|
||||
created() {},
|
||||
mounted() {
|
||||
this.getlist();
|
||||
},
|
||||
methods: {
|
||||
async getlist() {
|
||||
const { data: res } = await this.$http({
|
||||
url: this.allUrls.page,
|
||||
method: "get",
|
||||
});
|
||||
if (res.code == 0) {
|
||||
this.dataList = res.data;
|
||||
}
|
||||
},
|
||||
|
||||
handleBtnClick({ btnName, payload }) {
|
||||
switch (btnName) {
|
||||
case "查询": {
|
||||
this.getlist();
|
||||
break;
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.list-view-with-head {
|
||||
background: white;
|
||||
/* height: 100%; */
|
||||
min-height: inherit;
|
||||
border-radius: 6px;
|
||||
padding: 16px;
|
||||
box-shadow: 0 0 1.125px 0.125px rgba(0, 0, 0, 0.125);
|
||||
}
|
||||
</style>
|
@ -7,7 +7,7 @@ import initConfig from './config';
|
||||
import ListViewWithHead from '@/views/atomViews/ListViewWithHead.vue';
|
||||
|
||||
export default {
|
||||
name: 'ProductionLineView',
|
||||
name: 'AGVMission',
|
||||
components: { ListViewWithHead },
|
||||
provide() {
|
||||
return {
|
||||
|
@ -141,9 +141,9 @@ export default {
|
||||
};
|
||||
},
|
||||
inject: ["urls"],
|
||||
mounted() {
|
||||
this.initDataWhenLoad && this.getList();
|
||||
},
|
||||
// mounted() {
|
||||
// this.initDataWhenLoad && this.getList();
|
||||
// },
|
||||
methods: {
|
||||
/** 获取 列表数据 */
|
||||
getList(queryParams) {
|
||||
@ -170,6 +170,7 @@ export default {
|
||||
// if (this.urls.pageIsPostApi) {
|
||||
// } else {
|
||||
// 默认是 get 方式请求 page
|
||||
console.log("params: ", params);
|
||||
this.$http[this.urls.pageIsPostApi ? "post" : "get"](
|
||||
this.urls.page,
|
||||
this.urls.pageIsPostApi
|
||||
|
@ -96,6 +96,7 @@ export default function () {
|
||||
{ width: 80, prop: "orderCate", label: "订单子号" },
|
||||
{ prop: "bomCode", label: "配方" },
|
||||
{ prop: "shapeCode", label: "砖型" },
|
||||
{ prop: "weight", label: "重量" },
|
||||
{ width: 80, prop: "qty", label: "订单数量" },
|
||||
{ width: 72, prop: "goodqty", label: "合格数" },
|
||||
{ width: 72, prop: "badqty", label: "废砖数" },
|
||||
|
@ -27,7 +27,8 @@ export default {
|
||||
// },
|
||||
// },
|
||||
data() {
|
||||
const { tableConfig, headFormConfigs, carPayloadDialogConfigs, urls, dialogConfigs } = initConfig.call(this);
|
||||
const { tableConfig, headFormConfigs, carPayloadDialogConfigs, urls, dialogConfigs } =
|
||||
initConfig.call(this);
|
||||
return {
|
||||
carPayloadDialogConfigs,
|
||||
tableConfig,
|
||||
@ -39,7 +40,6 @@ export default {
|
||||
};
|
||||
},
|
||||
activated() {
|
||||
//console.log("activated", this.$route.query)
|
||||
this.code = this.$route.query.code || "";
|
||||
this.triggerUpdateKey = Math.random().toString();
|
||||
},
|
||||
|
@ -89,6 +89,7 @@ export default function () {
|
||||
{ width: 80, prop: "orderCate", label: "订单子号" },
|
||||
{ prop: "brand", label: "配方" },
|
||||
{ prop: "shapeCode", label: "砖型" },
|
||||
{ prop: "weight", label: "重量" },
|
||||
{ width: 80, prop: "qty", label: "订单数量" },
|
||||
{ width: 72, prop: "goodqty", label: "合格数" },
|
||||
{ width: 72, prop: "badqty", label: "废砖数" },
|
||||
|
@ -56,17 +56,17 @@ export default function () {
|
||||
prop: "operations",
|
||||
name: "操作",
|
||||
fixed: "right",
|
||||
width: 90,
|
||||
width: 128,
|
||||
subcomponent: TableOperaionComponent,
|
||||
options: [
|
||||
{ name: "edit", label: "编辑", icon: "edit-outline" }, // enable: (row) => row.report == 0 },
|
||||
// {
|
||||
// name: "delete",
|
||||
// icon: "delete",
|
||||
// label: "删除",
|
||||
// emitFull: true,
|
||||
// permission: "pms:workReport:delete",
|
||||
// },
|
||||
{
|
||||
name: "delete",
|
||||
icon: "delete",
|
||||
label: "删除",
|
||||
emitFull: true,
|
||||
permission: "pms:workReport:delete",
|
||||
},
|
||||
],
|
||||
},
|
||||
];
|
||||
|
Ładowanie…
Reference in New Issue
Block a user