瀏覽代碼

权益卡相关修改

zhanghui 2 年之前
父節點
當前提交
15600c66f1

+ 41 - 2
myPages/ServiceObjectManagement/index.vue

@@ -6,7 +6,7 @@
         <view class="service-object-list" >
           <view v-for="(item,index) in serviceObjectList" class="store-content" :key="index">
             <view class="store-img">
-              <image  :src="item.facePhotoUrl || '/static/logo.png'" mode="aspectFill"></image>
+              <image  :src="item.facePhotoUrl || '/static/logo.png'" mode="aspectFill" @click="magnify(item.facePhotoUrl)"></image>
             </view>
             <view class="content">
               <view class="title-price">
@@ -18,12 +18,15 @@
                 </view>
               </view>
               <view class="desc">
-                <view class="in-progress">关系:{{item.blood}}</view>
+                <view class="in-progress">
+                  <text>关系:{{item.blood}}</text> <text v-if="item.haveEquityCard" class="b">88卡</text>
+                </view>
                 <view class="completed" >
                   备注:<text>{{item.remark || '无'}}</text>
                 </view>
               </view>
             </view>
+
           </view>
         </view>
       </view>
@@ -32,6 +35,13 @@
     <view @click="gotoAddServiceObject()" class="add">
       +<text class="name">添加服务对象</text>
     </view>
+
+    <uni-popup ref="popup">
+      <view class="magnifyUrlView">
+        <image :src="magnifyUrl" mode="widthFix"></image>
+      </view>
+    </uni-popup>
+
   </view>
 </template>
 
@@ -39,6 +49,7 @@
   export default {
     data() {
       return {
+        magnifyUrl:'',
         windowHeight:'',
         reqParm: {
           auth: true
@@ -58,6 +69,14 @@
       this.listServiceObject();
     },
     methods: {
+
+      magnify(url){
+        if (!url){
+          return
+        }
+        this.magnifyUrl = url
+        this.$refs.popup.open()
+      },
       // 查询服务对接信息列表
       listServiceObject(){
         this.$api.listServiceObject(this.reqParm).then((res)=>{
@@ -113,6 +132,11 @@
     border-top: 1px solid #f7f7f7;
   }
 
+  .magnifyUrlView{
+    border-radius: 20rpx;
+    overflow: hidden;
+  }
+
   .add{
     width: 686rpx;
     margin-left: 32rpx;
@@ -191,4 +215,19 @@
 
     }
   }
+  .in-progress{
+    display: flex;
+    flex-direction: row;
+    justify-content: space-between;
+  }
+
+  .b{
+    font-size: 24rpx;
+    font-family: PingFangSC-Regular, PingFang SC;
+    color: #9ed733;
+    background: #e9f6d1;
+    padding: 6rpx 16rpx;
+    margin-left: 16rpx;
+    border-radius: 12rpx;
+  }
 </style>

+ 1 - 0
myPages/serviceObjectAllInfo/index.vue

@@ -350,6 +350,7 @@
             },
             //头像上传
             uploadImg1(imgIndex) {
+                return //关闭头像上传
                 let that = this;
                 uni.chooseImage({
                     count: 1,

+ 1 - 0
myPages/serviceObjectInfo/index.vue

@@ -180,6 +180,7 @@
             },
             //头像上传
             uploadImg1(imgIndex) {
+                return //关闭头像上传
                 let that = this;
                 uni.chooseImage({
                     count: 1,

+ 4 - 2
orderPages/orderDetail/index.vue

@@ -389,7 +389,9 @@ export default {
           this.getUserInfo();
             let orderServiceIds = []
             this.order.child.forEach(i=>{
-                orderServiceIds.push(i.orderServiceId)
+                if (i.status !=5){ //排除审核通过的子订单
+                    orderServiceIds.push(i.orderServiceId)
+                }
             })
             this.$api.qenPayInfo({
                 orderServiceIds:orderServiceIds,
@@ -448,7 +450,7 @@ export default {
             this.allPrice = 0
             this.totalDiscount = 0;
             this.order.child.forEach(i=>{
-                if (i.status != 3 ){ //不在申诉的子订单
+                if (i.status != 3 || i.status !=5){ //不在申诉的子订单
                     this.totalDiscount += i.discountAmount * 1;
                     this.allPrice += i.payAmount *1;
                 }

+ 21 - 2
orderPages/serviceObject/index.vue

@@ -2,7 +2,7 @@
     <view class="page" >
         <view v-for="(item,index) in serviceObjectList" @click="chooseServiceObject(item)" class="h-item-row">
             <view class="h-img">
-                <image :src="item.facePhotoUrl || '/static/logo.png'" mode="aspectFill"></image>
+                <image :src="item.facePhotoUrl || '/static/logo.png'" mode="aspectFill" @click.stop="magnify(item.facePhotoUrl)"></image>
             </view>
             <view class="h-item-content">
                 <view class="h-title">
@@ -21,9 +21,15 @@
                 </view>
             </view>
             <view v-if="item.haveEquityCard" class="flex-col justify-center">
-                <text class="b">权益券</text>
+                <text class="b">88卡</text>
             </view>
         </view>
+
+        <uni-popup ref="popup">
+            <view class="magnifyUrlView">
+                <image :src="magnifyUrl" mode="widthFix"></image>
+            </view>
+        </uni-popup>
     </view>
 </template>
 
@@ -31,6 +37,7 @@
     export default {
         data() {
             return {
+                magnifyUrl:'',
                 serviceObjectList: [],
                 reqParm: {
                     auth: true
@@ -43,6 +50,14 @@
         },
 
         methods: {
+
+            magnify(url){
+                if (!url){
+                    return
+                }
+                this.magnifyUrl = url
+                this.$refs.popup.open()
+            },
             // 查询服务对接信息列表
             listServiceObject(){
                 this.$api.listServiceObject(this.reqParm).then((res)=>{
@@ -84,6 +99,10 @@
     .page{
         background: #F7F7F7;
     }
+    .magnifyUrlView{
+        border-radius: 20rpx;
+        overflow: hidden;
+    }
     .h-item-row{
         display: flex;
         font-family: PingFangSC-Medium, PingFang SC;

+ 9 - 0
storePages/myRights/index.rpx.scss

@@ -49,6 +49,15 @@
   width: 188rpx;
   height: 188rpx;
 }
+.h-right-content-img{
+  width: 188rpx;
+  height: 188rpx;
+  border-radius: 8rpx;
+}
+.magnifyUrlView{
+  border-radius: 20rpx;
+  overflow: hidden;
+}
 .money{
   height: 52rpx;
   font-size: 36rpx;

+ 31 - 5
storePages/myRights/index.vue

@@ -37,14 +37,17 @@
 
 				</view>
 
-<!--				<view class="h-right-content flex-col justify-center ">-->
-<!--					<view class="btn" @click="payRights(item)">-->
-<!--						<text>购买</text>-->
-<!--					</view>-->
-<!--				</view>-->
+				<view class="h-right-content flex-col justify-center">
+					<image class="h-right-content-img"  :src="item.facePhotoUrl || '/static/logo.png'" mode="aspectFill" @click="magnify(item.facePhotoUrl)"></image>
+				</view>
 
 			</view>
 		</scroll-view>
+		<uni-popup ref="popup">
+			<view class="magnifyUrlView">
+				<image :src="magnifyUrl" mode="widthFix"></image>
+			</view>
+		</uni-popup>
 
 
 	</view>
@@ -53,6 +56,7 @@
 	export default {
 		data() {
 			return {
+				magnifyUrl:'',
 				windowHeight:'',
 				userInfo:{},
 				equityList:[],
@@ -68,13 +72,35 @@
 
 		methods: {
 
+			magnify(url){
+				if (!url){
+					return
+				}
+				this.magnifyUrl = url
+				this.$refs.popup.open()
+			},
+
 			myEquityCardList(){
 				this.$api.myEquityCardList().then(res=>{
 					console.log(res)
 					this.equityList = res.data.data
+					this.getImgUrlByBannerOssId(this.equityList)
 				})
 			},
 
+			// 获取图片
+			getImgUrlByBannerOssId(items){
+				for(let i = 0; i <items.length; i++) {
+					if (items[i].facePhoto){
+						this.$api.getImgUrlByOssId({ossId:items[i].facePhoto}).then(res=>{
+							console.log('++++++++++++facePhotoUrl+++++++++',res.data.data[0].url.replace(/^http:/, "https:"))
+							items[i].facePhotoUrl = res.data.data[0].url.replace(/^http:/, "https:")
+							this.$set(this.equityList,i,items[i])
+						})
+					}
+				}
+			},
+
 		},
 	};
 </script>

+ 25 - 2
storePages/rights/index.vue

@@ -130,10 +130,10 @@
 			};
 		},
 		onLoad(option) {
+			this.userInfo = uni.getStorageSync('userInfo')
 			let sysInfo = uni.getSystemInfoSync()
 			this.windowHeight =sysInfo.windowHeight -50  +'px'//除标题栏栏外的屏幕可用高度
 			this.windowHeight1 =sysInfo.windowHeight  +'px'//除标题栏栏外的屏幕可用高度
-			this.userInfo = uni.getStorageSync('userInfo')
 			this.listServiceObject()
 			this.equityCardList()
 		},
@@ -242,8 +242,15 @@
 
 			// 查询服务对像信息列表
 			listServiceObject(){
+				let serviceObjectList =[]
 				this.$api.listServiceObject(this.reqParm).then((res)=>{
-					this.serviceObjectList[0] =res.data.data
+					res.data.data.forEach(i=>{
+						if (i.isSelf != 1){
+							serviceObjectList.push(i)
+						}
+					})
+					this.serviceObjectList[0] =serviceObjectList
+
 				})
 			},
 
@@ -259,6 +266,22 @@
 			},
 
 			payRights(item){
+				if (this.serviceObjectList[0].length===0){
+					uni.showModal({
+						title:'温馨提示',
+						content:'购买权益卡时须绑定服务对象,是否前往绑定服务对象',
+						success:res=>{
+							if (res.confirm){
+								uni.navigateTo({
+									url: '/myPages/ServiceObjectManagement/index',
+								})
+							}
+						}
+					})
+					return;
+				}
+
+
 				if(!this.selectIcon){
 					uni.$u.toast('请阅读并同意《娇骄儿88卡权益服务协议》')
 					return;