Bläddra i källkod

1、修改查询条件日期组件
2、删除库存查询测试页

zhoux 2 år sedan
förälder
incheckning
f01ee59876

+ 4 - 4
components/dkbase/dk-dropdown-date/dk-dropdown-date.js

@@ -130,10 +130,10 @@ Component({
 
         let date = []
         if (item.value == 1) {
-          date = [util.formatTime(new Date()).substring(0, 10), util.formatTime(new Date()).substring(0, 10)]
+          date = [util.formatDataTime(new Date()).substring(0, 10), util.formatDataTime(new Date()).substring(0, 10)]
         }
         else if (item.value == 2) {
-          date = [util.formatTime(util.getCurrentWeek(0)).substring(0, 10), util.formatTime(util.getCurrentWeek(-6)).substring(0, 10)]
+          date = [util.formatDataTime(util.getCurrentWeek(0)).substring(0, 10), util.formatDataTime(util.getCurrentWeek(-6)).substring(0, 10)]
         }
         else if (item.value == 3) {
           date = util.getCurrentMonth();
@@ -142,8 +142,8 @@ Component({
           let startYear = util.getYear("s", 0)
           let endYear = util.getYear("e", 0)
           //本年
-          date = [util.formatTime(new Date(startYear)).substring(0, 10),
-          util.formatTime(new Date(endYear)).substring(0, 10)]
+          date = [util.formatDataTime(new Date(startYear)).substring(0, 10),
+          util.formatDataTime(new Date(endYear)).substring(0, 10)]
         }
         else if (item.value == 6) {
           //近30天

+ 2 - 0
components/dkbusiness/dk-dropdown-menu/dk-dropdown-menu.js

@@ -220,6 +220,7 @@ Component({
       let form = this.data.form
       form[code + 'Start'] = data[0]
       form[code + 'End'] = data[1]
+      console.log('rrr',data[0],typeof data[0],form);
       let menuList = this.data.menuList
       let dateDefault = e.detail.dateDefault
       if (this.data.index || this.data.index == 0) {
@@ -356,6 +357,7 @@ Component({
       form[this.data.dropDateCode] = date
       form[this.data.dropDateCode + 'Start'] = e.detail.date[0];
       form[this.data.dropDateCode + 'End'] = e.detail.date[1];
+      console.log('rre',e.detail.date[0]);
       this.setData({
         form: form,
         value: JSON.stringify(form)

+ 48 - 1161
package-sales/pages/inventory/inventory.js

@@ -1,1179 +1,66 @@
-const app = getApp();
-const api = require('../../../utils/api.js');
-const Constants = require('../../../utils/Constants.js');
+// package-sales/pages/inventory/inventory.js
 Page({
 
-  /**
-   * 页面的初始数据
-   */
-  data: {
-    LINK_PSI_SYSTEM: "WANWEI-PSI",
-    NOINVERTORY_Flag: true,
-    form: {
-      "whId": 552,
-      "whName": "钦州运营仓"
+    /**
+     * 页面的初始数据
+     */
+    data: {
+
     },
-    goodsList: [
-      {
-        "ascpId": 29195,
-        "balanceQuantity": 181,
-        "brandName": "恒洁卫浴",
-        "code": "CE551AS2200B01",
-        "codeName": "电控一体机HQ551\\地排\\305坑距",
-        "colorNumber": "-",
-        "cpId": 20760,
-        "cpName": "无库无ERP00001",
-        "flgValid": true,
-        "iconPathType": null,
-        "iconThumPath": null,
-        "inventoryQuantity": 193,
-        "ivtId": 217,
-        "ivtQty": 193,
-        "nonStdCode": "-",
-        "opApiId": "ebf22701-3e48-48b6-8bdd-703a58bc4e42",
-        "opAppId": "e8d25036-4b95-48d6-a77b-1cfb077dd3e6",
-        "opCreateTime": "2023-11-11 14:50:44",
-        "opCreateUserId": 937,
-        "opDbUser": "{\"usesysid\":\"6376246\",\"usename\":\"hgscrm\",\"application_name\":\"PostgreSQL JDBC Driver\",\"client_addr\":\"175.172.202.7\"}",
-        "opTimestamp": "2023-12-11 09:16:53",
-        "opUpdateTime": "2023-12-11 09:16:53",
-        "opUpdateUserId": 643,
-        "outGoingQty": 12,
-        "purNonEntry": 0,
-        "remarks": null,
-        "sale1Id": 20760,
-        "sale2Id": 29195,
-        "saleNonEntry": null,
-        "saleNonOut": 3,
-        "skuCode": "CE551AS2200B01",
-        "skuId": 9611250,
-        "skuModel": "HQ551",
-        "skuName": "电控一体机HQ551\\地排\\305坑距",
-        "specsList": [],
-        "specsValues": null,
-        "spuCategoryLevelName": "智能马桶\\电控坐便器",
-        "spuId": null,
-        "titleTag": null,
-        "usableQty": 181,
-        "warehouseName": "无库无ERP00001",
-        "whId": 616,
-        "whName": "无库无ERP00001"
-      },
-      {
-        "ascpId": 29195,
-        "balanceQuantity": 138,
-        "brandName": "恒洁卫浴",
-        "code": "EE920A00200B01",
-        "codeName": "【已淘汰】智能盖板HE920",
-        "colorNumber": "-",
-        "cpId": 20760,
-        "cpName": "无库无ERP00001",
-        "flgValid": true,
-        "iconPathType": null,
-        "iconThumPath": null,
-        "inventoryQuantity": 150,
-        "ivtId": 198,
-        "ivtQty": 150,
-        "nonStdCode": "-",
-        "opApiId": "ebf22701-3e48-48b6-8bdd-703a58bc4e42",
-        "opAppId": "5096ef17-ee97-47bc-ab99-1d6be28f4b66",
-        "opCreateTime": "2023-11-07 09:13:13",
-        "opCreateUserId": 254,
-        "opDbUser": "{\"usesysid\":\"6376246\",\"usename\":\"hgscrm\",\"application_name\":\"PostgreSQL JDBC Driver\",\"client_addr\":\"124.71.26.125\"}",
-        "opTimestamp": "2024-01-12 13:51:58",
-        "opUpdateTime": "2024-01-12 13:51:58",
-        "opUpdateUserId": 968,
-        "outGoingQty": 12,
-        "purNonEntry": 0,
-        "remarks": null,
-        "sale1Id": 20760,
-        "sale2Id": 29195,
-        "saleNonEntry": null,
-        "saleNonOut": 20,
-        "skuCode": "EE920A00200B01",
-        "skuId": 9537580,
-        "skuModel": "HE920",
-        "skuName": "【已淘汰】智能盖板HE920",
-        "specsList": [],
-        "specsValues": null,
-        "spuCategoryLevelName": "智能马桶\\智能盖板",
-        "spuId": null,
-        "titleTag": null,
-        "usableQty": 138,
-        "warehouseName": "无库无ERP00001",
-        "whId": 616,
-        "whName": "无库无ERP00001"
-      },
-      {
-        "ascpId": 29195,
-        "balanceQuantity": 134,
-        "brandName": "恒洁卫浴",
-        "code": "EE604A00200B01",
-        "codeName": "【已淘汰】智能盖板HE604A",
-        "colorNumber": "-",
-        "cpId": 20760,
-        "cpName": "无库无ERP00001",
-        "flgValid": true,
-        "iconPathType": null,
-        "iconThumPath": null,
-        "inventoryQuantity": 134,
-        "ivtId": 269,
-        "ivtQty": 134,
-        "nonStdCode": "-",
-        "opApiId": "ebf22701-3e48-48b6-8bdd-703a58bc4e42",
-        "opAppId": "e8d25036-4b95-48d6-a77b-1cfb077dd3e6",
-        "opCreateTime": "2023-11-20 09:15:59",
-        "opCreateUserId": 643,
-        "opDbUser": "{\"usesysid\":\"6376246\",\"usename\":\"hgscrm\",\"application_name\":\"PostgreSQL JDBC Driver\",\"client_addr\":\"113.225.142.137\"}",
-        "opTimestamp": "2024-01-09 13:09:40",
-        "opUpdateTime": "2024-01-09 13:09:40",
-        "opUpdateUserId": 937,
-        "outGoingQty": 0,
-        "purNonEntry": 0,
-        "remarks": null,
-        "sale1Id": 20760,
-        "sale2Id": 29195,
-        "saleNonEntry": null,
-        "saleNonOut": 0,
-        "skuCode": "EE604A00200B01",
-        "skuId": 9479830,
-        "skuModel": "HE604A",
-        "skuName": "【已淘汰】智能盖板HE604A",
-        "specsList": [],
-        "specsValues": null,
-        "spuCategoryLevelName": "智能马桶\\智能盖板",
-        "spuId": null,
-        "titleTag": null,
-        "usableQty": 134,
-        "warehouseName": "无库无ERP00001",
-        "whId": 616,
-        "whName": "无库无ERP00001"
-      },
-      {
-        "ascpId": 29195,
-        "balanceQuantity": 107,
-        "brandName": "恒洁卫浴",
-        "code": "CT962EN2200B01",
-        "codeName": "智能一体机陶瓷体HC0962\\地排305",
-        "colorNumber": "-",
-        "cpId": 20760,
-        "cpName": "无库无ERP00001",
-        "flgValid": true,
-        "iconPathType": null,
-        "iconThumPath": null,
-        "inventoryQuantity": 114,
-        "ivtId": 257,
-        "ivtQty": 114,
-        "nonStdCode": "-",
-        "opApiId": "ebf22701-3e48-48b6-8bdd-703a58bc4e42",
-        "opAppId": "5096ef17-ee97-47bc-ab99-1d6be28f4b66",
-        "opCreateTime": "2023-11-16 16:23:28",
-        "opCreateUserId": 1005,
-        "opDbUser": "{\"usesysid\":\"6376246\",\"usename\":\"hgscrm\",\"application_name\":\"PostgreSQL JDBC Driver\",\"client_addr\":\"113.225.142.137\"}",
-        "opTimestamp": "2024-01-09 11:48:56",
-        "opUpdateTime": "2024-01-09 11:48:56",
-        "opUpdateUserId": 1005,
-        "outGoingQty": 7,
-        "purNonEntry": 0,
-        "remarks": null,
-        "sale1Id": 20760,
-        "sale2Id": 29195,
-        "saleNonEntry": null,
-        "saleNonOut": 15,
-        "skuCode": "CT962EN2200B01",
-        "skuId": 9553940,
-        "skuModel": "HC0962",
-        "skuName": "智能一体机陶瓷体HC0962\\地排305",
-        "specsList": [],
-        "specsValues": null,
-        "spuCategoryLevelName": "智能马桶\\智能一体机陶瓷体",
-        "spuId": null,
-        "titleTag": null,
-        "usableQty": 107,
-        "warehouseName": "无库无ERP00001",
-        "whId": 616,
-        "whName": "无库无ERP00001"
-      },
-      {
-        "ascpId": 29195,
-        "balanceQuantity": 102,
-        "brandName": "恒洁卫浴",
-        "code": "EE605B00200B01",
-        "codeName": "【已淘汰】智能盖板HE605B",
-        "colorNumber": "-",
-        "cpId": 20760,
-        "cpName": "无库无ERP00001",
-        "flgValid": true,
-        "iconPathType": null,
-        "iconThumPath": null,
-        "inventoryQuantity": 102,
-        "ivtId": 273,
-        "ivtQty": 102,
-        "nonStdCode": "-",
-        "opApiId": "ebf22701-3e48-48b6-8bdd-703a58bc4e42",
-        "opAppId": "5096ef17-ee97-47bc-ab99-1d6be28f4b66",
-        "opCreateTime": "2023-11-20 10:58:51",
-        "opCreateUserId": 643,
-        "opDbUser": "{\"usesysid\":\"6376246\",\"usename\":\"hgscrm\",\"application_name\":\"PostgreSQL JDBC Driver\",\"client_addr\":\"124.71.26.125\"}",
-        "opTimestamp": "2023-12-20 10:37:24",
-        "opUpdateTime": "2023-12-20 10:37:24",
-        "opUpdateUserId": 1005,
-        "outGoingQty": 0,
-        "purNonEntry": 0,
-        "remarks": null,
-        "sale1Id": 20760,
-        "sale2Id": 29195,
-        "saleNonEntry": null,
-        "saleNonOut": 0,
-        "skuCode": "EE605B00200B01",
-        "skuId": 9446520,
-        "skuModel": "HE605B",
-        "skuName": "【已淘汰】智能盖板HE605B",
-        "specsList": [],
-        "specsValues": null,
-        "spuCategoryLevelName": "智能马桶\\智能盖板",
-        "spuId": null,
-        "titleTag": null,
-        "usableQty": 102,
-        "warehouseName": "无库无ERP00001",
-        "whId": 616,
-        "whName": "无库无ERP00001"
-      },
-      {
-        "ascpId": 29195,
-        "balanceQuantity": 101,
-        "brandName": "恒洁卫浴",
-        "code": "EE923A00200B01",
-        "codeName": "【已淘汰】智能盖板HE923",
-        "colorNumber": "-",
-        "cpId": 20760,
-        "cpName": "无库无ERP00001",
-        "flgValid": true,
-        "iconPathType": null,
-        "iconThumPath": null,
-        "inventoryQuantity": 101,
-        "ivtId": 272,
-        "ivtQty": 101,
-        "nonStdCode": "-",
-        "opApiId": "ebf22701-3e48-48b6-8bdd-703a58bc4e42",
-        "opAppId": "e8d25036-4b95-48d6-a77b-1cfb077dd3e6",
-        "opCreateTime": "2023-11-20 10:58:51",
-        "opCreateUserId": 643,
-        "opDbUser": "{\"usesysid\":\"6376246\",\"usename\":\"hgscrm\",\"application_name\":\"PostgreSQL JDBC Driver\",\"client_addr\":\"113.233.176.125\"}",
-        "opTimestamp": "2023-11-23 11:13:50",
-        "opUpdateTime": "2023-11-23 11:13:50",
-        "opUpdateUserId": 937,
-        "outGoingQty": 0,
-        "purNonEntry": 0,
-        "remarks": null,
-        "sale1Id": 20760,
-        "sale2Id": 29195,
-        "saleNonEntry": null,
-        "saleNonOut": 0,
-        "skuCode": "EE923A00200B01",
-        "skuId": 9473520,
-        "skuModel": "B923",
-        "skuName": "【已淘汰】智能盖板HE923",
-        "specsList": [],
-        "specsValues": null,
-        "spuCategoryLevelName": "智能马桶\\智能盖板",
-        "spuId": null,
-        "titleTag": null,
-        "usableQty": 101,
-        "warehouseName": "无库无ERP00001",
-        "whId": 616,
-        "whName": "无库无ERP00001"
-      },
-      {
-        "ascpId": 29195,
-        "balanceQuantity": 100,
-        "brandName": "恒洁卫浴",
-        "code": "CT978EN2100B02",
-        "codeName": "智能一体机陶瓷体HC0978A\\地排305\\不含直冲阀(通用)",
-        "colorNumber": "-",
-        "cpId": 20760,
-        "cpName": "无库无ERP00001",
-        "flgValid": true,
-        "iconPathType": null,
-        "iconThumPath": null,
-        "inventoryQuantity": 100,
-        "ivtId": 672,
-        "ivtQty": 100,
-        "nonStdCode": "-",
-        "opApiId": "ebf22701-3e48-48b6-8bdd-703a58bc4e42",
-        "opAppId": "5096ef17-ee97-47bc-ab99-1d6be28f4b66",
-        "opCreateTime": "2023-12-22 10:59:54",
-        "opCreateUserId": 1005,
-        "opDbUser": "{\"usesysid\":\"6376246\",\"usename\":\"hgscrm\",\"application_name\":\"PostgreSQL JDBC Driver\",\"client_addr\":\"113.225.168.193\"}",
-        "opTimestamp": "2023-12-22 10:59:55",
-        "opUpdateTime": "2023-12-22 10:59:54",
-        "opUpdateUserId": 1005,
-        "outGoingQty": 0,
-        "purNonEntry": 0,
-        "remarks": null,
-        "sale1Id": 20760,
-        "sale2Id": 29195,
-        "saleNonEntry": null,
-        "saleNonOut": 0,
-        "skuCode": "CT978EN2100B02",
-        "skuId": 9694350,
-        "skuModel": "HC0978A",
-        "skuName": "智能一体机陶瓷体HC0978A\\地排305\\不含直冲阀(通用)",
-        "specsList": [],
-        "specsValues": null,
-        "spuCategoryLevelName": "智能马桶\\智能一体机陶瓷体",
-        "spuId": null,
-        "titleTag": null,
-        "usableQty": 100,
-        "warehouseName": "无库无ERP00002仓",
-        "whId": 645,
-        "whName": "无库无ERP00002仓"
-      },
-      {
-        "ascpId": 29195,
-        "balanceQuantity": 100,
-        "brandName": "恒洁卫浴",
-        "code": "CT978EN4100B02",
-        "codeName": "智能一体机陶瓷体HC0978A\\地排400\\不含直冲阀(通用)",
-        "colorNumber": "-",
-        "cpId": 20760,
-        "cpName": "无库无ERP00001",
-        "flgValid": true,
-        "iconPathType": null,
-        "iconThumPath": null,
-        "inventoryQuantity": 100,
-        "ivtId": 669,
-        "ivtQty": 100,
-        "nonStdCode": "-",
-        "opApiId": "ebf22701-3e48-48b6-8bdd-703a58bc4e42",
-        "opAppId": "5096ef17-ee97-47bc-ab99-1d6be28f4b66",
-        "opCreateTime": "2023-12-22 10:59:54",
-        "opCreateUserId": 1005,
-        "opDbUser": "{\"usesysid\":\"6376246\",\"usename\":\"hgscrm\",\"application_name\":\"PostgreSQL JDBC Driver\",\"client_addr\":\"113.225.168.193\"}",
-        "opTimestamp": "2023-12-22 10:59:55",
-        "opUpdateTime": "2023-12-22 10:59:54",
-        "opUpdateUserId": 1005,
-        "outGoingQty": 0,
-        "purNonEntry": 0,
-        "remarks": null,
-        "sale1Id": 20760,
-        "sale2Id": 29195,
-        "saleNonEntry": null,
-        "saleNonOut": 0,
-        "skuCode": "CT978EN4100B02",
-        "skuId": 9694360,
-        "skuModel": "HC0978A",
-        "skuName": "智能一体机陶瓷体HC0978A\\地排400\\不含直冲阀(通用)",
-        "specsList": [],
-        "specsValues": null,
-        "spuCategoryLevelName": "智能马桶\\智能一体机陶瓷体",
-        "spuId": null,
-        "titleTag": null,
-        "usableQty": 100,
-        "warehouseName": "无库无ERP00002仓",
-        "whId": 645,
-        "whName": "无库无ERP00002仓"
-      },
-      {
-        "ascpId": 29195,
-        "balanceQuantity": 10,
-        "brandName": "恒洁卫浴",
-        "code": "EE931A00200B01",
-        "codeName": "【已淘汰】智能盖板HE931A",
-        "colorNumber": "-",
-        "cpId": 20760,
-        "cpName": "无库无ERP00001",
-        "flgValid": true,
-        "iconPathType": null,
-        "iconThumPath": null,
-        "inventoryQuantity": 11,
-        "ivtId": 220,
-        "ivtQty": 11,
-        "nonStdCode": "-",
-        "opApiId": "ebf22701-3e48-48b6-8bdd-703a58bc4e42",
-        "opAppId": "48849faf-8bbb-4a29-9548-0ba1c3df963f",
-        "opCreateTime": "2023-11-11 16:31:02",
-        "opCreateUserId": 254,
-        "opDbUser": "{\"usesysid\":\"6376246\",\"usename\":\"hgscrm\",\"application_name\":\"PostgreSQL JDBC Driver\",\"client_addr\":\"175.172.202.7\"}",
-        "opTimestamp": "2023-11-28 09:51:30",
-        "opUpdateTime": "2023-11-28 09:51:30",
-        "opUpdateUserId": 254,
-        "outGoingQty": 1,
-        "purNonEntry": 0,
-        "remarks": null,
-        "sale1Id": 20760,
-        "sale2Id": 29195,
-        "saleNonEntry": null,
-        "saleNonOut": 0,
-        "skuCode": "EE931A00200B01",
-        "skuId": 9497070,
-        "skuModel": "HE931A",
-        "skuName": "【已淘汰】智能盖板HE931A",
-        "specsList": [],
-        "specsValues": null,
-        "spuCategoryLevelName": "智能马桶\\智能盖板",
-        "spuId": null,
-        "titleTag": null,
-        "usableQty": 10,
-        "warehouseName": "无库无ERP00001",
-        "whId": 616,
-        "whName": "无库无ERP00001"
-      },
-      {
-        "ascpId": 29195,
-        "balanceQuantity": 10,
-        "brandName": "恒洁卫浴",
-        "code": "EE923C00200B01",
-        "codeName": "【已淘汰】智能盖板HE923C",
-        "colorNumber": "-",
-        "cpId": 20760,
-        "cpName": "无库无ERP00001",
-        "flgValid": true,
-        "iconPathType": null,
-        "iconThumPath": null,
-        "inventoryQuantity": 20,
-        "ivtId": 207,
-        "ivtQty": 20,
-        "nonStdCode": "-",
-        "opApiId": "ebf22701-3e48-48b6-8bdd-703a58bc4e42",
-        "opAppId": "e8d25036-4b95-48d6-a77b-1cfb077dd3e6",
-        "opCreateTime": "2023-11-08 16:55:25",
-        "opCreateUserId": 254,
-        "opDbUser": "{\"usesysid\":\"6376246\",\"usename\":\"hgscrm\",\"application_name\":\"PostgreSQL JDBC Driver\",\"client_addr\":\"124.71.26.125\"}",
-        "opTimestamp": "2024-01-09 10:00:48",
-        "opUpdateTime": "2024-01-09 10:00:48",
-        "opUpdateUserId": 937,
-        "outGoingQty": 10,
-        "purNonEntry": 0,
-        "remarks": null,
-        "sale1Id": 20760,
-        "sale2Id": 29195,
-        "saleNonEntry": null,
-        "saleNonOut": 0,
-        "skuCode": "EE923C00200B01",
-        "skuId": 9462290,
-        "skuModel": "HE923C",
-        "skuName": "【已淘汰】智能盖板HE923C",
-        "specsList": [],
-        "specsValues": null,
-        "spuCategoryLevelName": "智能马桶\\智能盖板",
-        "spuId": null,
-        "titleTag": null,
-        "usableQty": 10,
-        "warehouseName": "无库无ERP00001",
-        "whId": 616,
-        "whName": "无库无ERP00001"
-      }
-    ],
-    loading: false,
-    noMore: false,
-    orderBy: [
-      {
-        "text": "可售量升序",
-        "value": "balanceAsc"
-      },
-      {
-        "text": "可售量降序",
-        "value": "balanceDesc"
-      },
-      {
-        "text": "库存量升序",
-        "value": "inventoryAsc"
-      },
-      {
-        "text": "库存量降序",
-        "value": "inventoryDesc"
-      }
-    ],
-    "pageInfo": {
-      "currentPage": 1,
-      "pageSize": 10
+
+    /**
+     * 生命周期函数--监听页面加载
+     */
+    onLoad(options) {
+
     },
-    searchText: "",
-    sideKey: 1,
-    sidebarFlag: true,
-    typeList: [
-      {
-        "id": "",
-        "name": "全部分类"
-      },
-      {
-        "id": 51,
-        "name": "智能马桶"
-      },
-      {
-        "id": 52,
-        "name": "智能盖板"
-      },
-      {
-        "id": 53,
-        "name": "智能一体机"
-      },
-      {
-        "id": 84,
-        "name": "电控坐便器"
-      },
-      {
-        "id": 103,
-        "name": "智能一体机陶瓷体"
-      },
-      {
-        "id": 54,
-        "name": "陶瓷类"
-      },
-      {
-        "id": 55,
-        "name": "坐便器"
-      },
-      {
-        "id": 108,
-        "name": "电控坐便器"
-      },
-      {
-        "id": 56,
-        "name": "蹲便器"
-      },
-      {
-        "id": 57,
-        "name": "小便器"
-      },
-      {
-        "id": 58,
-        "name": "洗面器"
-      },
-      {
-        "id": 59,
-        "name": "其它陶瓷"
-      },
-      {
-        "id": 60,
-        "name": "浴室柜"
-      },
-      {
-        "id": 66,
-        "name": "定制浴室柜"
-      },
-      {
-        "id": 107,
-        "name": "轻定制浴室柜"
-      },
-      {
-        "id": 110,
-        "name": "定制柜非标组件"
-      },
-      {
-        "id": 63,
-        "name": "金属柜"
-      },
-      {
-        "id": 62,
-        "name": "生态实木柜"
-      },
-      {
-        "id": 61,
-        "name": "实木柜"
-      },
-      {
-        "id": 87,
-        "name": "金属柜镜柜"
-      },
-      {
-        "id": 119,
-        "name": "铝镜柜和智能镜"
-      },
-      {
-        "id": 65,
-        "name": "浴室柜配套品"
-      },
-      {
-        "id": 64,
-        "name": "柜盆"
-      },
-      {
-        "id": 97,
-        "name": "金属柜主柜"
-      },
-      {
-        "id": 102,
-        "name": "金属柜其它部件"
-      },
-      {
-        "id": 96,
-        "name": "生态实木柜主柜"
-      },
-      {
-        "id": 100,
-        "name": "生态实木柜镜柜"
-      },
-      {
-        "id": 101,
-        "name": "生态实木柜其它部件"
-      },
-      {
-        "id": 95,
-        "name": "实木柜主柜"
-      },
-      {
-        "id": 98,
-        "name": "实木柜镜柜"
-      },
-      {
-        "id": 99,
-        "name": "实木柜其它部件"
-      },
-      {
-        "id": 82,
-        "name": "花洒"
-      },
-      {
-        "id": 93,
-        "name": "明装花洒类"
-      },
-      {
-        "id": 123,
-        "name": "明装花洒类"
-      },
-      {
-        "id": 124,
-        "name": "暗装花洒类"
-      },
-      {
-        "id": 94,
-        "name": "暗装花洒类"
-      },
-      {
-        "id": 83,
-        "name": "龙头类"
-      },
-      {
-        "id": 67,
-        "name": "小五金类"
-      },
-      {
-        "id": 70,
-        "name": "挂件"
-      },
-      {
-        "id": 88,
-        "name": "地漏"
-      },
-      {
-        "id": 115,
-        "name": "地漏"
-      },
-      {
-        "id": 116,
-        "name": "角阀"
-      },
-      {
-        "id": 90,
-        "name": "角阀"
-      },
-      {
-        "id": 92,
-        "name": "下水器"
-      },
-      {
-        "id": 117,
-        "name": "下水器"
-      },
-      {
-        "id": 91,
-        "name": "水槽"
-      },
-      {
-        "id": 118,
-        "name": "水槽"
-      },
-      {
-        "id": 71,
-        "name": "其它小五金"
-      },
-      {
-        "id": 72,
-        "name": "淋浴房"
-      },
-      {
-        "id": 85,
-        "name": "定制淋浴房"
-      },
-      {
-        "id": 86,
-        "name": "标准淋浴房"
-      },
-      {
-        "id": 113,
-        "name": "定制淋浴房"
-      },
-      {
-        "id": 114,
-        "name": "标准淋浴房"
-      },
-      {
-        "id": 104,
-        "name": "功能型淋浴房"
-      },
-      {
-        "id": 105,
-        "name": "淋浴房石基"
-      },
-      {
-        "id": 73,
-        "name": "浴缸"
-      },
-      {
-        "id": 74,
-        "name": "配件"
-      },
-      {
-        "id": 75,
-        "name": "智能类配件"
-      },
-      {
-        "id": 76,
-        "name": "陶瓷类配件"
-      },
-      {
-        "id": 77,
-        "name": "浴室柜配件"
-      },
-      {
-        "id": 78,
-        "name": "五金类配件"
-      },
-      {
-        "id": 79,
-        "name": "休闲类配件"
-      },
-      {
-        "id": 80,
-        "name": "周边物料"
-      },
-      {
-        "id": 111,
-        "name": "赠品物料"
-      },
-      {
-        "id": -1,
-        "name": "广宣大类"
-      },
-      {
-        "id": -2,
-        "name": "广宣类"
-      },
-      {
-        "id": -3,
-        "name": "广告物料"
-      },
-      {
-        "id": -4,
-        "name": "礼品赠品"
-      },
-      {
-        "id": -5,
-        "name": "费用大类"
-      },
-      {
-        "id": -6,
-        "name": "费用类"
-      },
-      {
-        "id": -7,
-        "name": "虚拟产品"
-      }
-    ],
-    value: "balanceDesc",
-    windowHeight: 504,
-    windowWidth: 320,
-    specsId: 51,
-    whFlag: false
-    
-  },
 
-  /**
-   * 生命周期函数--监听页面加载
-   */
-  onLoad: function (options) {  },
- //获取库区数据源
- getWhName(){
-    let that = this
-   let param = {}
-   param.dataSourceCode = "warehouse" 
-   param.orgId = app.globalData.user.orgId
-   param.ascpId = app.globalData.user.ascpId
-   param.cpId = app.globalData.user.cpId
-   param.sale2OpeMode = app.globalData.user.sale2OpeMode 
-  api.request(Constants.BASIC_COMMON_API + 'get_wx_init_data', 'POST', param).then(res => {
-    if (res.data.code === 200) {
-      let list = res.data.data||[] 
-        if(list.length>0){
-          let form = this.data.form
-          list.forEach(it=>{
-            if(it.defId == it.id){
-              form.whId = it.id
-              form.whName = it.name
-            }
-          })
-        
-      
-          this.setData({
-           form
-          }) 
-            //that.doSearch()
-            
-        }
-    }
-  })
- },
-  /**
-   * @desc : 分类切换
-   * @author : 于继渤
-   * @date : 2022/5/26 20:16
-   */
-  changeSidebar(e) {
-    let id = this.data.typeList[e.detail].id
-    if (id == "" && typeof (id) != 'number') {
-      this.setData({
-        sideKey: null,
-        specsId: null
-      })
-    } else {
-      this.setData({
-        sideKey: e.detail,
-        specsId: id
-      })
-    }
-    this.setData({
-      searchText: ''
-    })
-    // 查询
-    this.doSearch()
-  },
+    /**
+     * 生命周期函数--监听页面初次渲染完成
+     */
+    onReady() {
 
-  /**
-   * @desc : 加载商品分类
-   * @date : 2022/5/15 16:49
-   * @author : 于继渤
-   */
-  getGoodsClassification() {
-    let param = {
-      dataSourceCode: 'hgSpuCategory',
-      cpId: app.globalData.user.cpId,
-    }
-    api.request(Constants.BASIC_COMMON_API + 'get_wx_init_data', 'POST', param).then(res => {
-      if (res.data.code === 200) {
-        let typeList = this.data.typeList
-        let list = res.data.data
-        list.forEach(item2 => {
-          let item = {
-            id: item2.categoryId,
-            name: item2.categoryName,
-          }
-          typeList.push(item)
-        })
-        this.setData({
-          typeList: typeList
-        })
-      }
-    })
-  },
+    },
 
-  /**
-   * @desc : 排序选择事件
-   * @author : 于继渤
-   * @date : 2022/9/3 9:24
-   */
-  onSwitchChange(e) {
-    this.setData({
-      value: e.detail
-    })
-    console.log( e.detail)
-    this.doSearch()
-  },
+    /**
+     * 生命周期函数--监听页面显示
+     */
+    onShow() {
 
-  /**
-   * @desc : 下拉多选事件
-   * @author : 于继渤
-   * @date : 2022/5/26 12:16
-   */
-  dropdowncommit(e) {
-    this.setData({
-      whFlag: true
-    })
-  },
-  dropdowncommitErp(){
-    this.setData({
-      whFlagErp: true
-    })
-  },
-  /**
-   * @desc : 下拉多选确定
-   * @author : 于继渤
-   * @date : 2022/5/26 12:16
-   */
-  mutiSearch(e) {
-    let id = e.target.id
-    let form = this.data.form
-    console.log(e)
-    if (id === 'warehouse') {
-      form.whId = e.detail.id
-      form.whName = e.detail.name
-      this.setData({
-        whFlag: false,
-        whFlagErp: false,
-        form: form
-      })
-      // this.selectComponent("#statusItemWareHouse").toggle(false)
-      if(this.data.LINK_PSI_SYSTEM !='WANWEI-PSI'){
-        this.selectComponent("#statusItemWareHouseErp").toggle(false)
-      }else{
-        this.selectComponent("#statusItemWareHouse").toggle(false)
-      }
-      
-      this.doSearch()
-    }
+    },
 
-    if (id === 'warehouse-orther') {
-      form.whId = e.detail.id
-      form.whName = e.detail.name
-      this.setData({
-        whFlag: false,
-        whFlagErp: false,
-        form: form
-      })
-      // this.selectComponent("#statusItemWareHouse").toggle(false)
-      if(this.data.LINK_PSI_SYSTEM !='WANWEI-PSI'){
-        this.selectComponent("#statusItemWareHouseErp").toggle(false)
-      }else{
-        this.selectComponent("#statusItemWareHouse").toggle(false)
-      }
-      
-      this.doSearch()
-    }
-  },
+    /**
+     * 生命周期函数--监听页面隐藏
+     */
+    onHide() {
 
-  /**
- * @desc : 下拉多选关闭
- * @author : 于继渤
- * @date : 2022/5/26 12:16
- */
-  muticlose(e) {
-    let id = e.currentTarget.id
-    if (id === 'warehouse') {
-      this.setData({
-        whFlag: false
-      })
-    }
-    if(this.data.LINK_PSI_SYSTEM !='WANWEI-PSI'){
-      this.selectComponent("#statusItemWareHouseErp").toggle(false)
-    }else{
-      this.selectComponent("#statusItemWareHouse").toggle(false)
-    }
-  },
+    },
 
-  /**
-   * @desc : 查询
-   * @author : 于继渤
-   * @date : 2022/5/24 08:49
-   */
-  doSearch() {
-    let pageInfo = this.data.pageInfo;
-    pageInfo.pageSize = 10;
-    pageInfo.currentPage = 1;
-    this.setData({
-      whFlag: false,
-      pageInfo: pageInfo,
-      goodsList: []
-    })
-    this.getData()
-  },
+    /**
+     * 生命周期函数--监听页面卸载
+     */
+    onUnload() {
 
-  /**
-   * @desc : 小程序库存明查询
-   * @author : 于继渤
-   * @date : 2022/9/1 8:53
-   */
-  getData(e) {
-    //查询前的校验
-    if (this.data.sidebarFlag) {
-      //分销用户 无ERP:动销数据,库存管理中库存明细表
-      this.getInventoryItem()
-    } else {
-      let flag = this.beforeSaveCheck()
-      if (flag) {
-        let param = {}
-        param.searchText = this.data.searchText ? this.data.searchText : '' //查询条件
-        param.warehouseName = this.data.form.whName//仓库名称
-        param.sort = this.data.value//排序方式
-        param.orgId = app.globalData.user.orgId
-        param.cpId = app.globalData.user.cpId
-        param.erpUserCode = app.globalData.user.erpUserCode
-        param.pageSize = this.data.pageInfo.pageSize
-        param.currentPage = this.data.pageInfo.currentPage
-        let linkPsiSystem = app.globalData.user.linkPsiSystem
-        this.setData({
-          loading: true
-        })
-        api.request(Constants.SALE_ORDER_SELECT_STOCK + 'select_stock', 'POST', param).then(res => {
-          this.setData({
-            loading: false
-          })
+    },
 
-          if (res.data.code === 200) {
-            let BigLlst = res.data.data
-            let list = [] //后台返回先定义[]
-            let goodsList = this.data.goodsList
-            if (linkPsiSystem == 'DK-IBOSS') {
-              list = BigLlst.datainfo
-            } else if (linkPsiSystem == 'WANWEI-PSI') {
-              list = BigLlst.data.details
-            } else {
-              list = []
-            }
-            if (!list || list.length == 0) {
-              // 如果不是翻页,需要清空
-              if (e != 'more') {
-                this.setData({
-                  list: [],
-                  noMore: false
-                })
-              } else {
-                this.setData({
-                  noMore: true
-                })
-              }
-              return
-            }
-            if (list.length < this.data.pageInfo.pageSize) {
-              this.setData({
-                noMore: false
-              })
-            }
-            goodsList = goodsList.concat(list)
-            this.setData({
-              goodsList: goodsList
-            })
-          }
-        })
-      }
-    }
-  },
+    /**
+     * 页面相关事件处理函数--监听用户下拉动作
+     */
+    onPullDownRefresh() {
+
+    },
 
-  /**
-  * @desc :分销用户 无ERP:动销数据,库存管理中库存明细表
-  * @author : 于继渤
-  * @date : 2023/10/08 10:49
-  */
-  getInventoryItem(e) {
-    //有分类模式
-    let param = {}
-    param.ascpId = app.globalData.user.ascpId
-    param.sort = this.data.value//排序方式
-    // param.customerId = app.globalData.user.sale2CustomerId
-    // param.orgId = app.globalData.user.sale2OrgId
-    param.searchText = this.data.searchText ? this.data.searchText  : ''
-    param.pageSize = this.data.pageInfo.pageSize
-    param.currentPage = this.data.pageInfo.currentPage
-    param.categoryId = this.data.specsId
-    this.setData({
-      loading: true
-    })
-    api.request(Constants.ORDER_REPORT + 'Inventory_item', 'POST', param).then(res => {
-      this.setData({
-        loading: false
-      })
+    /**
+     * 页面上拉触底事件的处理函数
+     */
+    onReachBottom() {
 
-      if (res.data.code === 200) {
-        let list = res.data.data.list
-        console.log(res)
-        list.forEach(item => {
-          item.code = item.skuCode
-          item.codeName = item.skuName
-          item.colorNumber = item.nonStdCode
-          item.warehouseName = item.whName
-          item.inventoryQuantity = item.ivtQty
-          item.balanceQuantity = item.usableQty
-        })
-        let goodsList = this.data.goodsList
-        if (!list || list.length == 0) {
-          // 如果不是翻页,需要清空
-          if (e != 'more') {
-            this.setData({
-              list: [],
-              noMore: false
-            })
-          } else {
-            this.setData({
-              noMore: true
-            })
-          }
-          return
-        }
-        if (list.length < this.data.pageInfo.pageSize) {
-          this.setData({
-            noMore: false
-          })
-        }
-        goodsList = goodsList.concat(list)
-        this.setData({
-          goodsList: goodsList
-        })
-      }
-    })
-  },
+    },
 
-  /**
-  * @desc : 页面上拉触底事件的处理函数
-  * @author : 于继渤
-  * @date : 2022/5/24 08:49
-  */
-  onReachBottom: function () {
-    if (this.data.loading || this.data.noMore) {
-      return;
-    }
-    this.setData({
-      pageInfo: {
-        pageSize: this.data.pageInfo.pageSize,
-        currentPage: this.data.pageInfo.currentPage + 1
-      }
-    })
-    this.getData('more')
-  },
-  /**
- * @desc : 保存前校验
- * @author : 于继渤
- * @date : 2022/9/1 9:00
- */
-  beforeSaveCheck() {
-    let erpUserCode = app.globalData.user.erpUserCode
-    if (!erpUserCode && !this.data.ErpFlag) {
-      wx.showToast({
-        title: '用户未绑定ERP编码',
-        icon: 'none'
-      })
-      return false
-    }
-    return true
-  },
+    /**
+     * 用户点击右上角分享
+     */
+    onShareAppMessage() {
 
-  /**
- * 页面相关事件处理函数--监听用户下拉动作
- */
-  onPullDownRefresh: function () {
-    let that = this
-    //调用刷新时将执行的方法
-    that.setData({
-      loadingShow: true,
-    })
-    this.doSearch()
-    //隐藏导航条加载动画
-    wx.hideNavigationBarLoading();
-    setTimeout(function () {
-      that.setData({
-        loadingShow: false,
-      })
-      //停止下拉刷新
-      wx.stopPullDownRefresh();
-    }, 800)
-  },
+    }
 })

+ 0 - 6
package-sales/pages/inventory/inventory.json

@@ -1,6 +0,0 @@
-{
-    "usingComponents": {},
-    "navigationBarTitleText":"库存明细",
-    "enablePullDownRefresh": true,
-    "backgroundTextStyle": "light"
-  }

+ 2 - 135
package-sales/pages/inventory/inventory.wxml

@@ -1,135 +1,2 @@
-<loading wx:if="{{loading}}" loadingName="加载中" backgroundColor="#f2f2f2;" opacity="0.8"></loading>
-
-
-<van-sticky scroll-top="0">
-  <view style="display:flex;">
-    <view style="width:75%;    padding-left: 23rpx;">
-      <van-search bind:search="doSearch" custom-class="search-class" model:value="{{ searchText }}" placeholder="商品名称/商品型号" use-right-icon-slot="{{true}}" placeholder-style="color:#95A8CB">
-      </van-search>
-    </view>
-    <view style="width:25%; background:#F8F9FD;">
-      <view class="scan-class">
-        <image class="scan-image" fit="fill" src="/static/img/Group.png"></image>
-      </view>
-    </view>
-
-  </view>
-  <van-dropdown-menu active-color="#1B365D" style=" width: calc(100% ) !important; ">
-
-      <!-- 库区 -->
-      <van-dropdown-item wx:if="{{!sidebarFlag && !NOINVERTORY_Flag && LINK_PSI_SYSTEM != 'WANWEI-PSI'}}" id="statusItemWareHouseErp" title="{{ form.whName ? form.whName:'仓库' }}" bind:open="dropdowncommitErp">
-    </van-dropdown-item>
-    <!-- 库区 -->
-    <van-dropdown-item wx:if="{{sidebarFlag && !NOINVERTORY_Flag || LINK_PSI_SYSTEM == 'WANWEI-PSI'}}" id="statusItemWareHouse" title="{{ form.whName ? form.whName:'仓库' }}" bind:open="dropdowncommit">
-    </van-dropdown-item>
-
-
-
-
-    <!-- 可售量排序 -->
-    <van-dropdown-item title="{{ orderBy.text }}" value="{{value}}" options="{{ orderBy }}" bind:change="onSwitchChange">
-    </van-dropdown-item>
-
-  </van-dropdown-menu>
-</van-sticky>
-
-<!-- 列表 -->
-<view wx:for="{{goodsList}}" data-item="{{item}}" wx:key="index" class="main-class" style="{{ sidebarFlag ? 'margin-left: 166rpx;' : ''}}">
-
-  <view class="main-foot" style="border-radius:15rpx;">
-    <view>
-      <view class="table-content-row">
-        <view style="display:flex;width:100%;">
-          <view data-item="{{item}}" style="display:flex;font-size: 15px;">
-            <dk-text style="font-size:30rpx;" fontWeight="nomal" value="{{item.code}}"></dk-text>
-          </view>
-
-        </view>
-      </view>
-
-      <!-- 商品名称 -->
-      <view class="table-row">
-        <view class="table-content-row">
-          <view style="display: flex;">
-            <view class="table-content-row-font">
-              <dk-text fontSize="14px" color="#95A8CB" fontWeight="nomal" value="商品名称" copyValue="{{item.codeName}}"></dk-text>
-            </view>
-            <view class="table-content-class">
-              {{item.codeName?item.codeName:''}}
-            </view>
-          </view>
-        </view>
-      </view>
-
-
-      <!-- 库区色号 -->
-      <view class="table-content-row">
-        <view style="display: flex;">
-          <view class="table-content-row-font">
-            <dk-text layoutFlag="{{true}}" fontSize="14px" color="#95A8CB" fontWeight="nomal" value="库区" copyValue="{{item.warehouseName}}"></dk-text>
-          </view>
-          <view class="table-content-class">
-            {{item.warehouseName}}{{item.colorNumber ? item.colorNumber + ' | 色号 ' : ''}}
-          </view>
-        </view>
-      </view>
-
-      <!-- 分割线 -->
-      <dk-divider marginTop="20rpx"></dk-divider>
-      <!-- 下半部分 -->
-      <view class="table-content-row">
-        <view style="display: flex;justify-content:space-between">
-          <view style="display: flex;">
-            <view class="table-content-row-font">
-              <dk-text layoutFlag="{{true}}" fontSize="14px" color="#95A8CB" fontWeight="nomal" value="库存量"></dk-text>
-            </view>
-            <view style="font-size: 13px;color: #CAA977;">
-              {{item.inventoryQuantity}}
-            </view>
-          </view>
-
-          <view style="display: flex;">
-            <view class="table-content-row-font">
-              <dk-text layoutFlag="{{true}}" fontSize="14px" color="#95A8CB" fontWeight="nomal" value="可售量"></dk-text>
-            </view>
-            <view style="font-size: 13px;color: #CAA977;">
-              {{item.balanceQuantity }}
-            </view>
-          </view>
-        </view>
-      </view>
-
-
-    </view>
-  </view>
-</view>
-
-<van-divider wx:if="{{noMore}}" contentPosition="center" borderColor="#DCDCDC">到底了~</van-divider>
-<van-cell wx:if="{{goodsList.length==0}}" border="{{ false }}">
-  <view style="width:100%;height:100%">
-    <van-empty description="暂无库存" />
-  </view>
-</van-cell>
-
-<view style="height: 20rpx;"></view>
-
-
-
-
-
-
-
-
-
-<van-sidebar wx:if="{{sidebarFlag}}" activeKey="{{sideKey}}" bindchange="changeSidebar" custom-class="left-class">
-  <view style="height:calc({{windowHeight+'px'}} - {{'200rpx'}});overflow: scroll;">
-    <van-sidebar-item wx:key="index" custom-class="{{sideKey - 1 == index? 'sidebar-item-before': (sideKey + 1 == index?'sidebar-item-next':'sidebar-item')}}" title="{{item.name}}" data-id="{{item.id}}" wx:for="{{typeList}}" />
-  </view>
-</van-sidebar>
-<!-- 仓库 -->
-<dk-single-dropdown-item show="{{whFlag}}" content="{{form.whName}}" id='warehouse-orther' typeName='warehouse-orther' bind:muticommit='mutiSearch' bind:muticlose='muticlose'>
-</dk-single-dropdown-item>
-
-<dk-single-dropdown-item show="{{whFlagErp}}" erpUserCode="true" content="{{form.whName}}" id='warehouse' typeName='erpWarehouse'
-    bind:muticommit='mutiSearch'  bind:muticlose='muticlose'>
-</dk-single-dropdown-item>
+<!--package-sales/pages/inventory/inventory.wxml-->
+<text>package-sales/pages/inventory/inventory.wxml</text>

+ 0 - 94
package-sales/pages/inventory/inventory.wxss

@@ -1,94 +0,0 @@
-/* package-sales/pages/inventory/inventory.wxss */page{
-  background-color: white;
-}
-.search-class {
-  height: 78rpx;
-}
-.left-class{
-  color:#0072ff;
-  position: fixed;
-  left:20rpx;
-  top: 196rpx;
-  width:130rpx !important;
-
-}
-
-.sidebar-item{
-  padding: 30rpx 25rpx 20rpx 35rpx !important;
-  font-size:13px !important;
-  background: #ECF2FF !important;
-  color: #95A8CB !important;
-}
-
-.sidebar-item-before{
-  padding: 30rpx 25rpx 20rpx 35rpx !important;
-  font-size:13px !important;
-  background: #ECF2FF !important;
-  border-bottom-right-radius: 30rpx;
-  color: #95A8CB !important;
-}
-
-.sidebar-item-next{
-  padding: 30rpx 25rpx 20rpx 35rpx !important;
-  font-size:13px !important;
-  background: #ECF2FF !important;
-  border-top-right-radius: 30rpx;
-  color: #95A8CB !important;
-}
-
-.van-sidebar-item--selected{
-  position: relative;
-  background: #fff !important;
-  border-radius: 15rpx 30rpx 30rpx 15rpx !important;
-  border: 0 !important;
-  color: black  !important;
-  /* border-top-left-radius: 0;
-  border-top-right-radius: 30rpx;
-  border-bottom-left-radius: 0;
-  border-bottom-right-radius: 30rpx; */
-}
-
-/**左侧字体样式*/
-.van-sidebar-item__text{
-  width: 70rpx !important;
-}
-
-.van-sidebar-item--selected::after{
-  content: '';
-  position: absolute;
-  left: 0;
-  height: 40rpx;
-  width: 6rpx;
-  background-color: #1B365D;
-  top: calc((100% - 40rpx)/2);
-}
-/**扫一扫**/
-.scan-class {
-  position: fixed;
-  top: 9rpx;
-  right: 34rpx;
-  width: 122rpx;
-  height: 65rpx;
-  background: #1B365D;
-  border-radius: 15rpx;
-  display: flex;
-  align-items: center;
-  justify-content: center;
-}
-
-.scan-image {
-  width: 48rpx;
-  height: 36rpx;
-}
-
-/** 查询**/
-.van-search {
-  background: #F8F9FD !important;
-  padding-left: 0 !important;
-}
-
-.customer-and-status {
-  display: flex;
-  width: 100%;
-  justify-content: space-around;
-}