فهرست منبع

合作商家去除合作详情按钮

zhaoxiaohai 3 سال پیش
والد
کامیت
b16b45f94f
4فایلهای تغییر یافته به همراه8 افزوده شده و 22 حذف شده
  1. 0 1
      components/My_UploadFiles/index.js
  2. 3 13
      pages/businessPartner/index.js
  3. 1 4
      pages/businessPartner/index.wxml
  4. 4 4
      pages/businessPartner/index.wxss

+ 0 - 1
components/My_UploadFiles/index.js

@@ -63,7 +63,6 @@ Component({
     /* 生命周期 */
     lifetimes: {
         attached: function () {
-            console.log(this.data.UploadShow)
             // 图片临时 id = 数字类型的 userid + 去掉前五位的时间戳
             const forTheTimeId = parseInt(wx.getStorageSync('userData').userid + (Date.parse(new Date()).toString().slice(5)));
             this.setData({

+ 3 - 13
pages/businessPartner/index.js

@@ -8,7 +8,6 @@ Page({
      * 页面的初始数据
      */
     data: {
-        showIndex: -1, //显示按钮的下标
         cooperationList: [], //合作列表
         condition: "", //模糊搜索条件
         pageNumber: 1, //请求分页
@@ -31,21 +30,12 @@ Page({
         })
         this.getList();
     },
-    /* 点击item */
-    showBtnIndex(e) {
+    /* 跳转商户 */
+    jumpForDetails(e) {
         const {
             index
         } = e.currentTarget.dataset;
-        this.setData({
-            showIndex: index
-        })
-    },
-    /* 跳转商户 */
-    jumpForDetails() {
-        const data = this.data.cooperationList[this.data.showIndex];
-        this.setData({
-            showIndex: -1
-        })
+        const data = this.data.cooperationList[index];
         wx.navigateTo({
             url: '/pages/businessPartner/details?data=' + JSON.stringify(data),
         })

+ 1 - 4
pages/businessPartner/index.wxml

@@ -5,7 +5,7 @@
 <My_DisplayBox title="商户列表" isMore="{{false}}">
     <image slot="display-box-img" class="display-title_image" src="/static/icon-05.png" mode="aspectFit"></image>
     <scroll-view class="list-scroll-view" scroll-y bindscrolltolower="scrolltolower">
-        <view class="company-data" wx:for="{{cooperationList}}" data-index="{{index}}" bindtap="showBtnIndex">
+        <view class="company-data" wx:for="{{cooperationList}}" data-index="{{index}}" catchtap="jumpForDetails">
             <image wx:if="{{item.attinfos[0]}}" class="company-data-image" src="{{item.attinfos[0].fobsurl}}" mode="aspectFill"></image>
             <image wx:else class="company-data-image" src="/static/tacitly-approve/MRuserImg.png" mode="aspectFill"></image>
             <view class="company-data-text">
@@ -14,9 +14,6 @@
                 <view wx:if="{{item.ftype==2}}">合作方式:下游</view>
                 <view wx:if="{{item.ftype==3}}">合作方式:双向合作</view>
             </view>
-            <view class="company-data-but">
-                <van-button wx:if="{{index==showIndex}}" custom-class="custom-class-company-data" catchtap="jumpForDetails">合作详情</van-button>
-            </view>
         </view>
         <My_pageReachBottom loadMore="{{pageNumber > pageTotal}}" dummyStatus="{{cooperationList.length!=0}}"></My_pageReachBottom>
     </scroll-view>

+ 4 - 4
pages/businessPartner/index.wxss

@@ -49,13 +49,13 @@
     color: #000000;
 }
 
-.company-data-but {
+/* .company-data-but {
     display: flex;
     align-items: center;
     height: 100%;
-}
+} */
 
-.custom-class-company-data {
+/* .custom-class-company-data {
     width: 138rpx !important;
     height: 46rpx !important;
     background: linear-gradient(180deg, #84E3EC 0%, #4DC2D4 100%) !important;
@@ -66,4 +66,4 @@
     font-weight: 500;
     font-size: 24rpx;
     text-shadow: 0px 0px 12px rgba(0, 0, 0, 0.1);
-}
+} */