|  |  | 
 |  |  |          return { | 
 |  |  |             baseUrl: '', | 
 |  |  |             token: '', | 
 |  |  |             icon: '', | 
 |  |  |             elements: [], | 
 |  |  |             elements2: [{ | 
 |  |  |             elements2: [ | 
 |  |  |                { | 
 |  |  |                   title: '组托入库', | 
 |  |  |                   name: 'pakin', | 
 |  |  |                   color: 'cyan', | 
 |  |  |                   color: 'orange', | 
 |  |  |                   cuIcon: 'pullup', | 
 |  |  |                   url: '/pakin/pakin' | 
 |  |  |                }, | 
 |  |  |                // { | 
 |  |  |                //    title: '订单组托', | 
 |  |  |                //    name: 'orderPakin', | 
 |  |  |                //    color: 'blue', | 
 |  |  |                //    cuIcon: 'pullup', | 
 |  |  |                //    url: '/order/orderPakin' | 
 |  |  |                // }, | 
 |  |  |                // { | 
 |  |  |                //    title: '组托上架', | 
 |  |  |                //    name: 'putOn', | 
 |  |  |                //    color: 'cyan', | 
 |  |  |                //    cuIcon: 'pullup', | 
 |  |  |                //    url: '/pakin/putOn' | 
 |  |  |                // }, | 
 |  |  |                { | 
 |  |  |                   title: '订单入库', | 
 |  |  |                   name: 'orderPakin', | 
 |  |  |                   color: 'blue', | 
 |  |  |                   title: '订单组托2', | 
 |  |  |                   name: 'putOn', | 
 |  |  |                   color: 'cyan', | 
 |  |  |                   cuIcon: 'pullup', | 
 |  |  |                   url: '/order/orderPakin' | 
 |  |  |                   url: '/order/orderPutOn2' | 
 |  |  |                }, | 
 |  |  |                { | 
 |  |  |                   title: '订单组托3', | 
 |  |  |                   name: 'putOn', | 
 |  |  |                   color: 'cyan', | 
 |  |  |                   cuIcon: 'pullup', | 
 |  |  |                   url: '/order/orderPutOn3' | 
 |  |  |                }, | 
 |  |  |                // { | 
 |  |  |                //    title: '打印', | 
 |  |  | 
 |  |  |                //    cuIcon: 'text', | 
 |  |  |                //    url: '/print/print' | 
 |  |  |                // }, | 
 |  |  |                { | 
 |  |  |                   title: '订单上架', | 
 |  |  |                   name: 'orderPutOn', | 
 |  |  |                   color: 'mauve', | 
 |  |  |                   cuIcon: 'pullup', | 
 |  |  |                   url: '/order/orderPutOn' | 
 |  |  |                }, | 
 |  |  |                { | 
 |  |  |                   title: '订单下架', | 
 |  |  |                   name: 'orderPutDown', | 
 |  |  |                   color: 'pink', | 
 |  |  |                   cuIcon: 'pulldown', | 
 |  |  |                   url: '/order/orderPutDown' | 
 |  |  |                }, | 
 |  |  |                { | 
 |  |  |                   title: '库存查询', | 
 |  |  |                   name: 'stockQuery', | 
 |  |  |                   color: 'brown', | 
 |  |  |                   cuIcon: 'check', | 
 |  |  |                   url: '/stock/stockQuery' | 
 |  |  |                }, | 
 |  |  |                { | 
 |  |  |                   title: '盘点', | 
 |  |  |                   name: 'stockCheck', | 
 |  |  |                   color: 'red', | 
 |  |  |                   cuIcon: 'post', | 
 |  |  |                   url: '/stock/stockCheck' | 
 |  |  |                }, | 
 |  |  |                { | 
 |  |  |                   title: '商品打印', | 
 |  |  |                   name: 'matList', | 
 |  |  |                   color: 'orange', | 
 |  |  |                   cuIcon: 'post', | 
 |  |  |                   url: '/mat/matList' | 
 |  |  |                }, | 
 |  |  |                { | 
 |  |  |                   title: '补货', | 
 |  |  |                   name: 'restock', | 
 |  |  |                   color: 'yellow', | 
 |  |  |                   cuIcon: 'punch', | 
 |  |  |                   url: '/stock/restock' | 
 |  |  |                }, | 
 |  |  |                { | 
 |  |  |                   title: '转全板', | 
 |  |  |                   name: 'piking', | 
 |  |  |                   color: 'olive', | 
 |  |  |                   cuIcon: 'order', | 
 |  |  |                   url: '/pakin/piking' | 
 |  |  |                }, | 
 |  |  |                { | 
 |  |  |                   title: '换板绑定', | 
 |  |  |                   name: 'changePallet', | 
 |  |  |                   color: 'green', | 
 |  |  |                   cuIcon: 'order', | 
 |  |  |                   url: '/stock/changePallet' | 
 |  |  |                }, | 
 |  |  |                // { | 
 |  |  |                //    title: '订单上架', | 
 |  |  |                //    name: 'orderPutOn', | 
 |  |  |                //    color: 'mauve', | 
 |  |  |                //    cuIcon: 'pullup', | 
 |  |  |                //    url: '/order/orderPutOn' | 
 |  |  |                // }, | 
 |  |  |                // { | 
 |  |  |                //    title: '订单下架', | 
 |  |  |                //    name: 'orderPutDown', | 
 |  |  |                //    color: 'pink', | 
 |  |  |                //    cuIcon: 'pulldown', | 
 |  |  |                //    url: '/order/orderPutDown' | 
 |  |  |                // }, | 
 |  |  |                // { | 
 |  |  |                //    title: '库存查询', | 
 |  |  |                //    name: 'stockQuery', | 
 |  |  |                //    color: 'brown', | 
 |  |  |                //    cuIcon: 'check', | 
 |  |  |                //    url: '/stock/stockQuery' | 
 |  |  |                // }, | 
 |  |  |                // { | 
 |  |  |                //    title: '盘点', | 
 |  |  |                //    name: 'stockCheck', | 
 |  |  |                //    color: 'red', | 
 |  |  |                //    cuIcon: 'post', | 
 |  |  |                //    url: '/stock/stockCheck' | 
 |  |  |                // }, | 
 |  |  |                // { | 
 |  |  |                //    title: '商品打印', | 
 |  |  |                //    name: 'matList', | 
 |  |  |                //    color: 'orange', | 
 |  |  |                //    cuIcon: 'post', | 
 |  |  |                //    url: '/mat/matList' | 
 |  |  |                // }, | 
 |  |  |                // { | 
 |  |  |                //    title: '补货', | 
 |  |  |                //    name: 'restock', | 
 |  |  |                //    color: 'yellow', | 
 |  |  |                //    cuIcon: 'punch', | 
 |  |  |                //    url: '/stock/restock' | 
 |  |  |                // }, | 
 |  |  |                // { | 
 |  |  |                //    title: '转全板', | 
 |  |  |                //    name: 'piking', | 
 |  |  |                //    color: 'olive', | 
 |  |  |                //    cuIcon: 'order', | 
 |  |  |                //    url: '/pakin/piking' | 
 |  |  |                // }, | 
 |  |  |                // { | 
 |  |  |                //    title: '换板绑定', | 
 |  |  |                //    name: 'changePallet', | 
 |  |  |                //    color: 'green', | 
 |  |  |                //    cuIcon: 'order', | 
 |  |  |                //    url: '/stock/changePallet' | 
 |  |  |                // }, | 
 |  |  |                { | 
 |  |  |                   title: '退出登录', | 
 |  |  |                   name: 'logOut', | 
 |  |  | 
 |  |  |                         if (res.data.length < 0) { | 
 |  |  |                            break; | 
 |  |  |                         } | 
 |  |  |                         that.getIcon(res.data[i].title) | 
 |  |  |                         that.elements.unshift({ | 
 |  |  |                            title: res.data[i].name, | 
 |  |  |                            name: res.data[i].title, | 
 |  |  |                            color: that.colorList[i], | 
 |  |  |                            cuIcon: 'safe', | 
 |  |  |                            cuIcon: that.icon, | 
 |  |  |                            url: res.data[i].action | 
 |  |  |                         }) | 
 |  |  |                      } | 
 |  |  | 
 |  |  |                         title: '退出登录', | 
 |  |  |                         name: 'logOut', | 
 |  |  |                         color: 'grey', | 
 |  |  |                         cuIcon: 'exit' | 
 |  |  |                         cuIcon: 'exit', | 
 |  |  |                         url: '/login/logOut' | 
 |  |  |                      }) | 
 |  |  |                   } else if (res.code === 403) { | 
 |  |  |                      uni.showToast({ | 
 |  |  | 
 |  |  |                         }); | 
 |  |  |                      }, 1000); | 
 |  |  |                   } else if(res.status === 404) { | 
 |  |  |                      uni.showToast({ | 
 |  |  |                         title: '404', | 
 |  |  |                         icon: "none", | 
 |  |  |                         position: 'top' | 
 |  |  |                      }) | 
 |  |  |                      that.elements = that.elements2 | 
 |  |  |                      // uni.showToast({ | 
 |  |  |                      //    title: '默认主页', | 
 |  |  |                      //    icon: "none", | 
 |  |  |                      //    position: 'top' | 
 |  |  |                      // }) | 
 |  |  |                   } else { | 
 |  |  |                      uni.showToast({ | 
 |  |  |                         title: res.msg, | 
 |  |  | 
 |  |  |                } | 
 |  |  |             }) | 
 |  |  |          }, | 
 |  |  |          getIcon(e) { | 
 |  |  |             const ways = ['pakin','orderPakin','orderPutOn'] | 
 |  |  |             if (ways.includes(e)) { | 
 |  |  |                this.icon = 'pullup' | 
 |  |  |             } | 
 |  |  |          } | 
 |  |  |       } | 
 |  |  |    } | 
 |  |  | </script> |