货无忧
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

246 lines
8.8 KiB

2 years ago
"use strict";
const common_vendor = require("../../common/vendor.js");
const api_user = require("../../api/user.js");
require("../../utils/request.js");
require("../../store/index.js");
require("../../utils/functions.js");
require("../../utils/IDCardVerification.js");
require("../../utils/base64.js");
require("../../config/host.js");
require("../../utils/md5.js");
2 years ago
if (!Array) {
const _easycom_u_navbar2 = common_vendor.resolveComponent("u-navbar");
const _component_tips = common_vendor.resolveComponent("tips");
(_easycom_u_navbar2 + _component_tips)();
2 years ago
}
const _easycom_u_navbar = () => "../../uni_modules/uview-plus/components/u-navbar/u-navbar.js";
if (!Math) {
2 years ago
_easycom_u_navbar();
2 years ago
}
const _sfc_main = /* @__PURE__ */ common_vendor.defineComponent({
__name: "index",
setup(__props) {
const tip = common_vendor.ref(null);
let details = common_vendor.reactive({
tablist: [
// {
// type: 1,
// name: '工作台',
// minilist: [
// {
// icon: 'http://htys.oss-cn-chengdu.aliyuncs.com/htys/afb031efec7d2f8620ee68c71f87a80e.png',
// name: '订单查询',
// router: '/pagesHome/pages/orderInquiry/orderInquiry',
// },
// ]
// },
// {
// type: 1,
// name: '入库',
// minilist: [
// {
// icon: 'http://htys.oss-cn-chengdu.aliyuncs.com/htys/afb031efec7d2f8620ee68c71f87a80e.png',
// name: '码板打托',
// router: '/pagesHome/pages/codePlateBracket/codePlateBracket',
// },
// {
// icon: 'http://htys.oss-cn-chengdu.aliyuncs.com/htys/afb031efec7d2f8620ee68c71f87a80e.png',
// name: '入库扫描',
// router: '/pagesHome/pages/orderInquiry/orderInquiry',
// },
// {
// icon: 'http://htys.oss-cn-chengdu.aliyuncs.com/htys/afb031efec7d2f8620ee68c71f87a80e.png',
// name: '到车入库',
// router: '/pagesHome/pages/ArrivalList/ArrivalList',
// },
// ]
// },
// {
// type: 1,
// name: '库内',
// minilist: [
// {
// icon: 'http://htys.oss-cn-chengdu.aliyuncs.com/htys/afb031efec7d2f8620ee68c71f87a80e.png',
// name: '分拣打托',
// router: '/pagesHome/pages/scansorting/scansorting',
// },
// // {
// // icon: 'http://htys.oss-cn-chengdu.aliyuncs.com/htys/afb031efec7d2f8620ee68c71f87a80e.png',
// // name: '订单分拣',
// // router: '/pagesHome/pages/ordersorting/ordersorting',
// // },
// // {
// // icon: 'http://htys.oss-cn-chengdu.aliyuncs.com/htys/afb031efec7d2f8620ee68c71f87a80e.png',
// // name: '库存品分拣',
// // router: '/pagesHome/pages/lnventorysorting/lnventorysorting',
// // },
// {
// icon: 'http://htys.oss-cn-chengdu.aliyuncs.com/htys/afb031efec7d2f8620ee68c71f87a80e.png',
// name: '扫码上架',
// router: '/pagesHome/pages/ScanUpType/ScanUpType',
// },
// {
// icon: 'http://htys.oss-cn-chengdu.aliyuncs.com/htys/afb031efec7d2f8620ee68c71f87a80e.png',
// name: '手动上架',
// router: '/pagesHome/pages/PeopleScanUpType/PeopleScanUpType',
// },
// {
// icon: 'http://htys.oss-cn-chengdu.aliyuncs.com/htys/afb031efec7d2f8620ee68c71f87a80e.png',
// name: '移库',
// router: '/pagesHome/pages/RelocationType/RelocationType',
// },
// {
// icon: 'http://htys.oss-cn-chengdu.aliyuncs.com/htys/afb031efec7d2f8620ee68c71f87a80e.png',
// name: '滞留',
// router: '/pagesHome/pages/Retention/Retention',
// },
// {
// icon: 'http://htys.oss-cn-chengdu.aliyuncs.com/htys/afb031efec7d2f8620ee68c71f87a80e.png',
// name: '合托',
// router: '/pagesHome/pages/MergeTray/MergeTray',
// },
// {
// icon: 'http://htys.oss-cn-chengdu.aliyuncs.com/htys/afb031efec7d2f8620ee68c71f87a80e.png',
// name: '下架',
// router: '/pagesHome/pages/DownGoodsType/DownGoodsType',
// },
// {
// icon: 'http://htys.oss-cn-chengdu.aliyuncs.com/htys/afb031efec7d2f8620ee68c71f87a80e.png',
// name: '空置托盘',
// router: '/pagesHome/pages/RemoveTray/RemoveTray',
// },
// {
// icon: 'http://htys.oss-cn-chengdu.aliyuncs.com/htys/afb031efec7d2f8620ee68c71f87a80e.png',
// name: '复核',
// router: '/pagesHome/pages/Check/Check',
// },
// ]
// },
// {
// type: 1,
// name: '出库',
// minilist: [
// {
// icon: 'http://htys.oss-cn-chengdu.aliyuncs.com/htys/afb031efec7d2f8620ee68c71f87a80e.png',
// name: '拣货扫描',
// router: '/pagesHome/pages/pickingScan/pickingScan',
// },
// {
// icon: 'http://htys.oss-cn-chengdu.aliyuncs.com/htys/afb031efec7d2f8620ee68c71f87a80e.png',
// name: '自提扫描',
// router: '/pagesHome/pages/SelfPickupScan/SelfPickupScan',
// },
// {
// icon: 'http://htys.oss-cn-chengdu.aliyuncs.com/htys/afb031efec7d2f8620ee68c71f87a80e.png',
// name: '配载装车',
// router: '/pagesHome/pages/StowageList/StowageList',
// },
// {
// icon: 'http://htys.oss-cn-chengdu.aliyuncs.com/htys/afb031efec7d2f8620ee68c71f87a80e.png',
// name: '中转装车',
// router: '/pagesHome/pages/RelayScanList/RelayScanList',
// },
// ]
// },
{
type: 1,
name: "配送",
minilist: [
{
icon: "http://47.108.51.143:9000/basic/upload/20231012/1a9bbc8c842b8b7ef555d6cd79d421be.png",
name: "装车扫描",
router: "/pagesHome/pages/LoadingScan/LoadingScan"
},
{
icon: "http://47.108.51.143:9000/basic/upload/20231012/6956f6950cfc291e01c038ea5e13f984.png",
name: "签收扫描",
router: "/pagesHome/pages/signinScan/signinScan"
}
]
}
// {
// type: 1,
// name: '离线上传',
// minilist: [
// {
// icon: 'http://htys.oss-cn-chengdu.aliyuncs.com/htys/afb031efec7d2f8620ee68c71f87a80e.png',
// name: '离线上传',
// router: '/pagesHome/pages/OfflineUpload/OfflineUpload',
// },
// ]
// },
]
});
2 years ago
function gopathpage(path) {
common_vendor.index.navigateTo({
url: path
});
}
async function init() {
}
async function initbuts() {
let authbut = common_vendor.index.getStorageSync("authbuts");
console.log("authbut :>> ", authbut);
if (authbut) {
return;
}
let butres = await api_user.appbuttons({});
console.log(butres.data);
let qxan = [];
butres.data.map((item) => {
item.children.map((ite) => {
qxan.push({ name: ite.name, code: ite.code });
});
});
common_vendor.index.setStorageSync("authbuts", qxan);
}
common_vendor.onShow(() => {
init();
});
common_vendor.onLoad(() => {
initbuts();
});
common_vendor.onPullDownRefresh(() => {
const timer = setTimeout(() => {
init();
initbuts();
common_vendor.index.stopPullDownRefresh();
clearTimeout(timer);
}, 500);
});
common_vendor.watchEffect(() => {
if (details.tablist.length > 0) {
common_vendor.index.setStorageSync("homerouter", details.tablist);
}
});
2 years ago
const { tablist } = common_vendor.toRefs(details);
return (_ctx, _cache) => {
return {
a: common_vendor.p({
title: "工作台",
placeholder: true,
border: "true",
leftIcon: ""
}),
b: common_vendor.f(common_vendor.unref(tablist), (item, k0, i0) => {
return {
a: common_vendor.t(item.name),
b: common_vendor.f(item.minilist, (ite, k1, i1) => {
return {
a: ite.icon,
b: common_vendor.t(ite.name),
c: common_vendor.o(($event) => gopathpage(ite.router))
};
})
};
}),
c: common_vendor.sr(tip, "0c2ea314-1", {
"k": "tip"
2 years ago
})
};
};
}
});
const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__file", "D:/worksp/logpm/pages/index/index.vue"]]);
2 years ago
wx.createPage(MiniProgramPage);