Browse Source

隐私价格

xiaohaizhao 2 years ago
parent
commit
99a88ea7a1
3 changed files with 7 additions and 3 deletions
  1. 3 1
      pages/index/collect/index.js
  2. 3 1
      pages/index/market/index.js
  3. 1 1
      select/product/index.js

+ 3 - 1
pages/index/collect/index.js

@@ -12,7 +12,6 @@ Component({
 	},
 	properties: {},
 	data: {
-    hidePrice: wx.getStorageSync('hidePrice'),
 		list: [],
 		results: [], //选中结果
 		sa_brandid: null, //当前选中品牌id
@@ -24,6 +23,9 @@ Component({
 		init() {
 			this.getList()
 			this.selectComponent("#ListBox").setHeight(".head", this);
+			this.setData({
+        hidePrice: wx.getStorageSync('hidePrice'),
+      })
 			return true;
 		},
 		/* 获取列表 */

+ 3 - 1
pages/index/market/index.js

@@ -15,7 +15,6 @@ Component({
     addGlobalClass: true
   },
   data: {
-    hidePrice: wx.getStorageSync('hidePrice'),
     CustomBar: getApp().globalData.CustomBar,
     typeList: [],
     list: [],
@@ -47,6 +46,9 @@ Component({
     init() {
       this.getBrand();
       this.getTradefie();
+      this.setData({
+        hidePrice: wx.getStorageSync('hidePrice'),
+      })
       return true;
     },
     showModal(e) {

+ 1 - 1
select/product/index.js

@@ -26,7 +26,7 @@ Page({
 			radio: options.radio ? true : false,
 			idname: options.idname || this.data.idname,
 			showName: options.showName || this.data.showName,
-			newPrice: options.newprice || "marketprice", //红色价格
+			newPrice: options.newprice || "price", //红色价格
 		});
 		this.getList()
 	},