zs il y a 1 an
Parent
commit
66935eadf6
1 fichiers modifiés avec 7 ajouts et 1 suppressions
  1. 7 1
      src/service/Cart.service.ts

+ 7 - 1
src/service/Cart.service.ts

@@ -154,15 +154,21 @@ export class CartService extends BaseService<modelType> {
         if (result.community) {
           ShopSetting = await this.shopModel.findOne({
             office: result.community,
+            is_use: '0',
           });
           Collection = await this.collModel.findOne({
             office: result.community,
+            is_use: '0',
           });
           res = await this.offModel.findById(result.community).lean();
         } else if (result.street) {
-          ShopSetting = await this.shopModel.findOne({ office: result.street });
+          ShopSetting = await this.shopModel.findOne({
+            office: result.street,
+            is_use: '0',
+          });
           Collection = await this.collModel.findOne({
             office: result.community,
+            is_use: '0',
           });
           res = await this.offModel.findById(result.street).lean();
         } else assert(result.street, '缺少街道信息或社区信息!');