| | |
| | | </view> |
| | | </view> |
| | | </view> |
| | | <image class="card-icon" :src="imgSales" mode="widthFix" /> |
| | | </view> |
| | | |
| | | <view class="overview-card purchase"> |
| | |
| | | </view> |
| | | </view> |
| | | </view> |
| | | <image class="card-icon" :src="imgPurchase" mode="widthFix" /> |
| | | </view> |
| | | |
| | | <view class="overview-card stock"> |
| | |
| | | </view> |
| | | </view> |
| | | </view> |
| | | <image class="card-icon" :src="imgStock" mode="widthFix" /> |
| | | </view> |
| | | </view> |
| | | </view> |
| | |
| | | import { computed, onMounted, ref } from "vue"; |
| | | import { analysisCustomerContractAmounts, getBusiness } from "@/api/viewIndex"; |
| | | |
| | | const imgSales = "/static/images/index/xiaoshoushuju.png"; |
| | | const imgPurchase = "/static/images/index/caigoushuju.png"; |
| | | const imgStock = "/static/images/index/kucunshuju.png"; |
| | | const imgNum1 = "/static/images/index/num1.png"; |
| | | const imgNum2 = "/static/images/index/num2.png"; |
| | | const imgNum3 = "/static/images/index/num3.png"; |
| | |
| | | label: "生产报工", |
| | | icon: "/static/images/icon/shengchanbaogong@2x.png", |
| | | bgColor: "linear-gradient(135deg,#3b82f6,#2563eb)", |
| | | route: "/pages/productionManagement/productionReport/index", |
| | | action: "scan", |
| | | }, |
| | | { |
| | | label: "设备巡检", |
| | |
| | | } |
| | | |
| | | function handleQuickTool(item) { |
| | | if (item?.action === "scan") { |
| | | // 生产报工 - 调用扫码 |
| | | uni.scanCode({ |
| | | success: (res) => { |
| | | console.log("扫码结果:", res); |
| | | // 解析扫码结果并跳转到生产报工页面 |
| | | try { |
| | | const scanResult = JSON.parse(res.result); |
| | | uni.navigateTo({ |
| | | url: `/pages/productionManagement/productionReport/index?orderRow=${encodeURIComponent(JSON.stringify(scanResult))}` |
| | | }); |
| | | } catch (e) { |
| | | console.error("扫码结果解析失败:", e); |
| | | uni.showToast({ title: "无效的二维码", icon: "none" }); |
| | | } |
| | | }, |
| | | fail: (err) => { |
| | | console.error("扫码失败:", err); |
| | | } |
| | | }); |
| | | return; |
| | | } |
| | | if (!item?.route) return; |
| | | uni.navigateTo({ url: item.route }); |
| | | } |
| | |
| | | } |
| | | |
| | | .scroll { |
| | | height: calc(100vh - env(safe-area-inset-top) - 10px); |
| | | min-height: calc(100vh - env(safe-area-inset-top) - 10px); |
| | | } |
| | | |
| | | .section { |
| | |
| | | } |
| | | |
| | | .overview-card.sales { |
| | | background: linear-gradient(135deg, #e9fbff 0%, #d8fbff 100%); |
| | | background: url("/static/images/index/xiaoshoushuju.png") no-repeat center center; |
| | | background-size: cover; |
| | | } |
| | | .overview-card.purchase { |
| | | background: linear-gradient(135deg, #fff4e7 0%, #ffe7ce 100%); |
| | | background: url("/static/images/index/caigoushuju.png") no-repeat center center; |
| | | background-size: cover; |
| | | } |
| | | .overview-card.stock { |
| | | background: linear-gradient(135deg, #eaf0ff 0%, #dbe6ff 100%); |
| | | background: url("/static/images/index/kucunshuju.png") no-repeat center center; |
| | | background-size: cover; |
| | | } |
| | | |
| | | .card-left { |