Commit 78f531a0 authored by 康振飞's avatar 康振飞 Committed by 佟礼

班组长排产

parents 616958fa 2f9e8b9b
......@@ -74,7 +74,7 @@
</Header>
<div class="i-tabs">
<transition name="fade-quick">
<i-tabs v-if="tabs" v-show="showHeader" @on-reload="handleReload" />
<i-tabs v-show="showHeader" @on-reload="handleReload" />
</transition>
</div>
<Content class="i-layout-content">
......
......@@ -22,6 +22,10 @@ export default {
menus: []
};
},
async fetch({ store, params }) {
await store.dispatch("loadDictionary"); // 加载数据字典
await store.dispatch("loadUsers");//加载缓存的用户
},
created() {
// 处理路由 得到每一级的路由设置
this.$store.commit("admin/page/init", frameInRoutes);
......@@ -66,7 +70,6 @@ export default {
}
},
methods: {
getMenu() {
this.$http.sysUser.getusermenu().then(res => {
if (res.result) {
......
......@@ -592,9 +592,10 @@ export default {
okChai() {
var detail = this.$u.clone(this.listTask[this.rowIndex])
this.listTask[this.rowIndex].quantity -= this.chaiNum
// detail.id = 0
detail.pid = detail.id
detail.id = 0
// detail.pid = this.chaiId
detail.pid = this.$u.guid()
// detail.pid = this.$u.guid()
detail.quantity = this.chaiNum
this.listTask.splice(this.rowIndex + 1, 0, detail)
console.log("拆分后数据",this.listTask)
......
......@@ -7,13 +7,16 @@ export const state=()=>({
userInfo:{
userId:0,
userName:""
}
},
cart:[],
count: 0,
countAps:0,//aps排产
countAi:0,//智能排产
countAll:0,//整机排产
countRun:0,//流水排产
})
export const getters={
dictionaryByKey: (state) => (key) => {
if(state.dictionary){
return;
}
let result = [];
let items = state.dictionary.get(key);
if (items) {
......@@ -47,6 +50,24 @@ export const mutations={
setDictionary(state, dictionary) {
state.dictionary = dictionary;
},
setCart(state, cart) {
state.cart = cart;
},
setCartCount(state, count) {
state.count = count;
},
setCountAps(state, count) {//设置aps排产数量
state.countAps = count;
},
setCountAi(state, count) {//设置智能排产数量
state.countAi = count;
},
setCountAll(state, count) {//设置整机排产数量
state.countAll = count;
},
setCountRun(state, count) {//设置流水排产数量
state.countRun = count;
}
}
export const actions={
......
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