Commit f63aa323 authored by renjintao's avatar renjintao

Merge branch 'product' of git.mes123.com:zhouyx/mes-ui into product-rjt

parents da4e3a22 ab2e6068
......@@ -27,3 +27,33 @@
//弹框颜色
@modal-header-bg-color: #515A6E;
// //滚动条颜色
// @scrollbar-track-bg-color: rgb(239, 239, 239);
// @scrollbar-thumb-bg-color: rgba(38, 128, 235, 0.5);
// @scrollbar-thumb-bg-color-hover: rgba(38, 128, 235, 0.8);
// @scrollbar-corner-bg-color: rgba(38, 128, 235, 1);
// //顶部导航颜色
// @home-mene: #2680eb;
// @layout-header: #515A6E;
// //bady颜色
// @layout-content-bg-color: #fff;
// @card-bg: #fff;
// //收藏夹自体图标颜色
// @icon-color: #2680eb;
// //首页标题颜色
// @title-color: #0099ff;
// //表格、表单 以及其他字体颜色
// @table-color:#515A6E;
// //弹框颜色
// @modal-header-bg-color: #515A6E;
......@@ -143,7 +143,7 @@ export default {
oldScrollTop: 0,
isDelayHideSider: false, // hack,当从隐藏侧边栏的 header 切换到正常 header 时,防止 Logo 抖动
loadRouter: true,
showStar: null,
showStar: false,
content: "收藏",
menuId: null,
homeMenu: "",
......@@ -153,6 +153,9 @@ export default {
isStatic: false,
};
},
async fetch({ store, params }) {
await store.dispatch("collectList"); // 加载数据字典
},
computed: {
...mapState("admin/layout", [
"siderTheme",
......@@ -181,6 +184,7 @@ export default {
]),
...mapState("admin/page", ["keepAlive"]),
...mapGetters("admin/menu", ["hideSider", "filterSider"]),
...mapState({ collect: "collect" }),
// 如果开启 headerMenu,且当前 header 的 hideSider 为 true,则将顶部按 headerStick 处理
// 这时,即使没有开启 headerStick,仍然按开启处理
isHeaderStick() {
......@@ -266,19 +270,18 @@ export default {
this.handleReload();
}
}
console.warn("to-from", to, from, this.filterSider);
// console.warn("to-from", to, from, this.filterSider);
//获取收藏列表,判断的当前路由是否收藏
let star = false;
// console.warn("to-from======", this.$store.state.collect);
this.$store.state.collect.map((u) => {
// let star = false;
// console.warn("to-from======", this.collect);
this.collect.some((u) => {
if (u.url == to.path) {
star = true;
this.showStar = true;
return true;
} else {
star = false;
this.showStar = false;
}
});
this.showStar = star;
// alert(this.showStar);
//获取菜单path并与当前路由比对,获取当前菜单id
let dataTemp = this.$u.treeToList(this.filterSider);
......@@ -385,6 +388,7 @@ export default {
this.$api.post(url, menuId).then((r) => {
if (r.success) {
this.showStar = false;
this.$store.dispatch("collectList");
this.$Message.success("已取消收藏");
this.content = "收藏";
}
......@@ -399,6 +403,7 @@ export default {
this.$api.post(url, { menuId: this.menuId }).then((r) => {
if (r.result) {
this.showStar = true;
this.$store.dispatch("collectList");
this.$Message.success("收藏成功");
this.content = "取消收藏";
}
......
......@@ -31,6 +31,5 @@ export default {
// },
list(params) {
return Api.post(`${systemUrl}/newmessage/list`, params); //获取列表信息
},
},
}
\ No newline at end of file
......@@ -12,6 +12,7 @@
<span>{{userData.roleTitles}}</span>
</p>
</div>
<div class="incon-carousel">
<Icon
type="ios-arrow-back"
......@@ -211,9 +212,12 @@ export default {
};
},
async fetch({ store, params }) {
// console.warn("vvvvvv");
await store.dispatch("collectList"); // 加载数据字典
},
created() {
this.$store.dispatch("collectList");
this.get();
this.getUserInfoFn();
// console.log(this.$store.state.collect);
......
<template>
<div class="icon-font">
<ul>
<li v-for="(item,i) in iconList" :key="i" @click="setIcon(item.icon)" :title="item.icon">
<Icon :type="'icon iconfont '+item.icon" size="36"></Icon>
<p>{{item.title}}</p>
</li>
</ul>
</div>
</template>
<script>
export default {
// model: {
// prop: "value",
// event: "on-change",
// },
// props: {
// value: {
// type: String,
// },
// },
name: "Icons",
data() {
return {
// curModel: this.value,
// iconModal: true,
// icons:
// "icondaochu,iconbianji,icondaohang-banzupaigong,icondaohang-CRM,icondaohang-gongyisheji,icondaohang-gongyiguanli,icondaohang-gongzuoliu,icondaohang-dingdanguanli,icondaohang-chejianguanli,icondaohang-shujuchuanshu,icondaohang-shengchanzhihang,icondaohang-jihuaguanli,icondaohang-zhiliangguanli,icondaohang-ziyuanguanli,icongongdan-gongshifenpei,icondaoru,icongongdan-ceshishuju,icongongdan-gongyianli,icongongdan-gongyichakan,icongongdan-jinduhuibao,icongongdan-chanpinzhuangpei,icongongdan-shengchanzhunbei,icongongdan-wuliaolingyong,icongongdan-shujutianbao,iconpaichan-chadan,icongongdan-zhiliangpanding,iconlieshezhi,iconpaichan-gongxucanshu,iconpaichan-weichadan,iconpaichan-zidingyipaixu,iconrenyuan,iconshanchu,iconshebei,iconshezhi,iconshezhi-bukejian,iconshezhi-changkapianzhanshi,iconshezhi-kejian,iconshezhi-kapianzhanshi,iconshezhi-liebiaozhanshi,iconshouye-daishenpi,iconshouye-dianziduizhangdan,iconshouye-dingdanbaojia,iconshouye-tongjibiao,iconshouye-liuchengsheji,iconshouye-dingdanpaifa,iconshouye-renwupaichan,iconshouye-weiduxiaoxi,iconshouye-wuliaofuyan,iconshouye-zhanneiyoujian,iconxinzeng,iconshouye-zhiliangjianyan",
icons: [
{ icon: "icondaochu", title: "导出" },
{ icon: "iconbianji", title: "编辑" },
{ icon: "icondaohang-banzupaigong", title: "导航-班组派工" },
{ icon: "icondaohang-CRM", title: "导航-CRM" },
{ icon: "icondaohang-gongyisheji", title: "导航-工艺设计" },
{ icon: "icondaohang-gongyiguanli", title: "导航-工艺管理" },
{ icon: "icondaohang-gongzuoliu", title: "导航-工作流" },
{ icon: "icondaohang-dingdanguanli", title: "导航-订单管理" },
{ icon: "icondaohang-chejianguanli", title: "导航-车间管理" },
{ icon: "icondaohang-shujuchuanshu", title: "导航-数据传输" },
{ icon: "icondaohang-shengchanzhihang", title: "导航-生产执行" },
{ icon: "icondaohang-jihuaguanli", title: "导航-计划管理" },
{ icon: "icondaohang-zhiliangguanli", title: "导航-质量管理" },
{ icon: "icondaohang-ziyuanguanli", title: "导航-资源管理" },
{ icon: "icongongdan-gongshifenpei", title: "工单-工时分配" },
{ icon: "icondaoru", title: "导入" },
{ icon: "icongongdan-ceshishuju", title: "工单-测试数据" },
{ icon: "icongongdan-gongyianli", title: "工单-工艺案例" },
{ icon: "icongongdan-gongyichakan", title: "工单-工艺查看" },
{ icon: "icongongdan-jinduhuibao", title: "工单-进度汇报" },
{ icon: "icongongdan-chanpinzhuangpei", title: "工单-产品装配" },
{ icon: "icongongdan-shengchanzhunbei", title: "工单-生产准备" },
{ icon: "icongongdan-wuliaolingyong", title: "工单-物料领用" },
{ icon: "icongongdan-shujutianbao", title: "工单-数据填报" },
{ icon: "iconpaichan-chadan", title: "排产-插单" },
{ icon: "icongongdan-zhiliangpanding", title: "工单-质量判定" },
{ icon: "iconlieshezhi", title: "列设置" },
{ icon: "iconpaichan-gongxucanshu", title: "排产-工序参数" },
{ icon: "iconpaichan-weichadan", title: "排产-未插单" },
{ icon: "iconpaichan-zidingyipaixu", title: "排产-自定义排序" },
{ icon: "iconrenyuan", title: "人员" },
{ icon: "iconshanchu", title: "删除" },
{ icon: "iconshebei", title: "设备" },
{ icon: "iconshezhi", title: "设置" },
{ icon: "iconshezhi-bukejian", title: "设置-不可见" },
{ icon: "iconshezhi-changkapianzhanshi", title: "设置-长卡片展示" },
{ icon: "iconshezhi-kejian", title: "设置-可见" },
{ icon: "iconshezhi-kapianzhanshi", title: "导出" },
{ icon: "iconshezhi-liebiaozhanshi", title: "设置-卡片展示" },
{ icon: "iconshouye-daishenpi", title: "首页-待审批" },
{ icon: "iconshouye-dianziduizhangdan", title: "首页-电子对账单" },
{ icon: "iconshouye-dingdanbaojia", title: "首页-订单报价" },
{ icon: "iconshouye-tongjibiao", title: "首页-统计表" },
{ icon: "iconshouye-liuchengsheji", title: "首页-流程设计" },
{ icon: "iconshouye-dingdanpaifa", title: "首页-订单派发" },
{ icon: "iconshouye-renwupaichan", title: "首页-未读消息" },
{ icon: "iconshouye-weiduxiaoxi", title: "设置-列表展示" },
{ icon: "iconshouye-wuliaofuyan", title: "首页-物料复验" },
{ icon: "iconshouye-zhanneiyoujian", title: "首页-站内邮件" },
{ icon: "iconxinzeng", title: "新增" },
{ icon: "iconshouye-zhiliangjianyan", title: "首页-质量检验" },
],
};
},
computed: {
iconList() {
return this.icons;
},
// type() {
// if (this.curModel && this.curModel != "") {
// return this.curModel;
// } else {
// return "md-add";
// }
// },
},
methods: {
// setIcon(name) {
// this.curModel = name;
// this.iconModal = false;
// this.$emit("on-change", name);
// },
// change(name) {
// this.$emit("on-change", name);
// },
},
watch: {
// value: {
// handler(v, o) {
// this.curModel = v;
// },
// deep: true,
// },
},
};
</script>
<style lang="less" scoped>
.icon-font {
ul {
li {
text-align: center;
display: inline-block;
width: 125px;
height: 100px;
border: 1px solid transparent;
}
}
}
</style>
......@@ -3,9 +3,7 @@
<Sider hide-trigger v-if="showMenu" class="menu_side" width="300">
<StoreTree @on-hide="onHide" @on-select="productSearch" />
</Sider>
<Icon type="icon iconfont icondaochu" size="24" />
<!-- icon iconfont -->
<Icon type="icon iconfont icondaochu" size="24" />
<div v-if="!showMenu" class="show_menu">
<a class="menu_play fr" @click="showMenuFn" title="展开">
<Icon type="ios-arrow-forward" size="24" />
......
......@@ -70,6 +70,7 @@ export const mutations = {
state.userMap.push(user);
},
setCollect(state, collectData) {
state.collect = collectData;
},
setDictionary(state, dictionary) {
......@@ -128,7 +129,7 @@ export const actions = {
let {
result
} = await Api.post(`${systemUrl}/favorite/listbyuser`);
console.warn("result---", result)
commit("setCollect", result);
},
async loadUser({
......
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