spring
12 小时以前 3ea1ff641e1c680a5a1727fb4034797bfe65d93e
src/pages/consumablesLogistics/stockManagement/view.vue
@@ -64,7 +64,7 @@
const detail = ref(null);
const loading = ref(true);
function normalizeDetail(raw, type) {
function normalizeDetail(raw) {
  if (!raw) return null;
  const d = typeof raw === "object" ? raw : {};
  return {
@@ -76,7 +76,7 @@
    lockedQuantity: d.lockedQuantity,
    unLockedQuantity: d.unLockedQuantity ?? (d.qualitity - (d.lockedQuantity || 0)),
    updateTime: d.updateTime,
    typeLabel: type === "1" ? "不合格库存" : "合格库存",
    typeLabel: "合格库存",
  };
}
@@ -86,8 +86,7 @@
    try {
      const payload = typeof cached === "string" ? JSON.parse(cached) : cached;
      const item = payload && payload.item != null ? payload.item : payload;
      const type = payload && payload.type != null ? payload.type : "0";
      detail.value = normalizeDetail({ ...item, index: 1 }, type);
      detail.value = normalizeDetail({ ...item, index: 1 });
      uni.removeStorageSync("stockDetailItem");
    } catch (e) {
      uni.removeStorageSync("stockDetailItem");