version/0412
syt 11 months ago
commit 040efe44ac
  1. 8
      api/user/vip.js
  2. 98
      pages/news/user/index.vue
  3. 16
      pages/news/user/vip.vue
  4. 1
      pages/news3/shopDealerOrder.vue
  5. 32
      pages/news3/shopOrder.vue
  6. 59
      pages/news3/shopOrderDetails.vue
  7. 3
      pages/news3/updatePrice.vue
  8. 2
      pages/order/detail.vue
  9. 2
      pages/user/index.vue

@ -5,7 +5,8 @@ const api = {
brandList: 'goods/brandList',
category: 'category/list',
getImage: 'goods/getCommonConfig',
vipList:'user/list'
vipList:'user/list',
updateVip:'user/updateUser'
}
// 大牌
@ -24,3 +25,8 @@ export const getImage = (data) => {
export const getVipList = (data) => {
return request.get(api.vipList, data)
}
//修改会员信息
export const updateVip = (data) => {
return request.post(api.updateVip, data)
}

@ -1,7 +1,7 @@
<template>
<view class="user">
<view class="order-navbar">
<u-navbar title="会员管理" :border-bottom="false" :background="background"></u-navbar>
<u-navbar :title="title" :border-bottom="false" :background="background"></u-navbar>
</view>
<view class="user-hd">
<view class="avater">
@ -16,16 +16,16 @@
</view>
<view class="user-show">
<view class="a">
<text>余额(</text>¥{{form.expend_money?form.expend_money:0.00}}
<text>余额(</text>¥{{form.balance?form.balance:0.00}}
</view>
<view class="a">
<text>积分(</text>{{form.grade?form.grade:0.00}}
<text>积分(</text>{{form.points?form.points:0.00}}
</view>
</view>
<view class="user-order">
<view class="user-order" @click="goJump()">
<view class="a">关联订单</view>
<view class="b">
<view class="num">99+</view>
<view class="num" v-show="total>0">{{total}}</view>
<u-icon name="arrow-right"></u-icon>
</view>
</view>
@ -34,18 +34,18 @@
<view class="b">编辑信息</view>
</view>
<view class="user-bd">
<view class="item">
<!-- <view class="item">
<view class="a">登录密码</view>
<view class="b"><view class="select select-on">****</view></view>
</view>
</view> -->
<view class="item">
<view class="a">上级推广人</view>
<view class="b">
<view class="select select-on">张三</view>
<u-icon style="margin-left: 10rpx;" name="arrow-right"></u-icon>
<view class="select select-on">{{form.inviter?form.inviter.nick_name:''}}</view>
<!-- <u-icon style="margin-left: 10rpx;" name="arrow-right"></u-icon> -->
</view>
</view>
<view class="item">
<!-- <view class="item">
<view class="a">用户分组</view>
<view class="b">
<view class="select">请选择用户分组</view>
@ -65,10 +65,13 @@
<view class="b">
指定分销模式下开启或关闭用户的推广权限
</view>
</view>
</view> -->
<view class="items">
<view class="a">推广权限
<u-switch v-model="checked" active-color="#55BD6A" ></u-switch></view>
<u-switch v-model="form.is_allow_promotion"
:activeValue="1" :inactiveValue="0"
active-color="#55BD6A" ></u-switch>
</view>
<view class="b">
指定分销模式下开启或关闭用户的推广权限
</view>
@ -76,11 +79,13 @@
<view class="item">
<view class="a">用户状态</view>
<view class="b">
<u-switch v-model="checked" active-color="#55BD6A" ></u-switch>
<u-switch v-model="form.status"
:activeValue="1" :inactiveValue="0"
active-color="#55BD6A" ></u-switch>
</view>
</view>
</view>
<view class="user-fd">
<view class="user-fd" @click="updateVipHandle">
<view class="b">
确认修改
</view>
@ -89,6 +94,8 @@
</template>
<script>
import * as Vip from '@/api/user/vip'
import * as newFunApi from '@/api/newFun'
// import img from "@/static/news/login-bg.png"
export default {
data() {
@ -107,6 +114,8 @@
gender: "",
grade: null,
grade_id: null,
inviter:null,
is_allow_promotion:null,
is_delete: null,
last_login_time: null,
mobile: "",
@ -115,6 +124,7 @@
platform: "",
points: null,
province: null,
status:null,
store_id: null,
update_time: "",
user_id: null,
@ -128,6 +138,8 @@
// background: 'url('+ img+') center top no-repeat',
backgroundSize: '100% auto',
},
title:'会员管理',
total:0
}
},
@ -139,12 +151,55 @@
}
},
methods: {
goJump(){
if(this.title=='会员管理'){
uni.navigateTo({
url:"/pages/news3/shopOrder?user_id="+this.form.user_id
})
}else{
uni.navigateTo({
url:"/pages/news3/shopDealerOrder?user_id="+this.form.user_id
})
}
},
async updateVipHandle(){
let params={
"user_id":this.form.user_id,
"status":this.form.status?1:0,
"is_allow_promotion":this.form.is_allow_promotion?1:0,
}
let res = await Vip.updateVip(params)
if(res.status==200){
uni.showToast({
title: '修改成功'
});
}
},
onLoad(option) {
},
async onLoad(option) {
console.log(option)
this.form = Object.assign({},this.form,JSON.parse(option.item))
console.log(this.form)
this.form.is_allow_promotion = this.form.is_allow_promotion==1?true:false
this.form.status = this.form.status==1?true:false;
this.title = option.title;
if(this.title=='会员管理'){
let {
status,
message,
data
} = await newFunApi.shopOrderList({
dataType: 'all',
page: 1,
});
if (status == 200) {
this.total = data.list.total
}
}else{
this.total=0
}
}
}
</script>
@ -188,9 +243,10 @@
align-items: center;
text{
display: block;
width: 98rpx;
// width: 98rpx;
border: 1px solid #FFB950;
height: 40rpx;
// height: 40rpx;
padding:0 10rpx;
font-size: 28rpx;
font-weight: 400;
color: #FFB343;
@ -363,9 +419,11 @@
justify-content: space-between;
.b{
width: 630rpx;
// width: 630rpx;
width:100%;
line-height: 83rpx;
background: #FFAAA4;
// background: #FFAAA4;
background: #FF6257;
border-radius: 83rpx;
text-align: center;
font-size: 28rpx;

@ -5,7 +5,7 @@
<image src="/static/news/icon-search.png"></image>
<input type="search" placeholder="商品名称/编码" />
</view> -->
<u-search placeholder="输入用户昵称/姓名/手机号" shape="round" :show-action="false" height="60" bg-color="#ffffff" v-model="keyword"></u-search>
<u-search placeholder="输入用户昵称/姓名/手机号" @search="searchhandle" shape="round" :show-action="false" height="60" bg-color="#ffffff" v-model="keyword"></u-search>
</view>
<view class="user-bd">
<view class="li" v-for="i in list" :key="i.user_id" @click="goVipDetails(i)">
@ -22,9 +22,9 @@
<view class="n">
<view>
<text>{{i.mobile}}</text>
<image @click="copyText(i.mobile)" :src="$picUrl+'/static/news/icon-copy.png'" style="margin-top:-4rpx;"></image>
<image @click.stop="copyText(i.mobile)" :src="$picUrl+'/static/news/icon-copy.png'" style="margin-top:-4rpx;"></image>
</view>
<image :src="$picUrl+'/static/news/tel.png'" @click="makeCall(i.mobile)"></image>
<image :src="$picUrl+'/static/news/tel.png'" @click.stop="makeCall(i.mobile)"></image>
</view>
</view>
<!-- <view class="m">
@ -38,7 +38,7 @@
</view> -->
</view>
<view class="b">
<view class="l">余额(<text>¥{{i.points?i.points:0.00}}</text></view>
<view class="l">余额(<text>¥{{i.balance?i.balance:0.00}}</text></view>
<view class="l">积分(<text>{{i.points?i.points:0}}</text></view>
</view>
</view>
@ -79,6 +79,12 @@
};
},
methods: {
searchhandle(){
this.list=[]
this.page = 1;
this.getList()
},
async getList(){
let res = await Vip.getVipList({page:this.page,search:this.keyword,user_type:this.title=='会员管理'?"10,20":'30'})
console.log(res,"===")
@ -141,7 +147,7 @@
goVipDetails(item){
let details = JSON.stringify(item)
uni.navigateTo({
url:"/pages/news/user/index?item="+details
url:"/pages/news/user/index?item="+details+"&title="+this.title
})
}
},

@ -251,6 +251,7 @@ export default {
// console.log(options);
this.classifyShow=options.type;
this.getList();
console.log("会员管理带来的user_id",options.user_id)
},
onPageScroll(e){

@ -29,6 +29,8 @@
<view class="shopItemInfo" v-for="(p,i) in item.goods" :key="i"
@click="goJump('/pages/news3/shopOrderDetails',item,0)">
<image :src="p.goods_image"></image>
<view class="priceName">
<view class="title">{{p.goods_name}}</view>
<view class="priceCon">
<text class="num">x{{p.total_num}}</text>
<view class="priceText">
@ -37,6 +39,7 @@
</view>
</view>
</view>
</view>
<view class="totalNum">
<text>含运费¥{{item.express_price}}</text>
<text>共计</text>
@ -44,7 +47,7 @@
</view>
<view class="remark">
<view class="remarkTitle">
收件人姓名 {{item.address?item.address.name:''}}
收件人姓名 {{item.address?item.address.name:''}} {{item.address?item.address.phone:''}}
</view>
<view class="remarkContent">
{{item.remark}}
@ -52,7 +55,7 @@
</view>
<view class="btnGroup">
<view class="btn info"
v-show="(!item.order_refund_id&&item.order_status==10&&item.pay_status==10) || (!item.order_refund_id&& item.order_status==10&&item.pay_status==20&&item.delivery_status==30)"
v-show="!item.order_refund_id&& item.order_status==10&&item.pay_status==20&&item.delivery_status==30"
@click="goJump('/pages/news3/updateAddr',item,0)">修改地址</view>
<view class="btn primary" v-show="!item.order_refund_id&&item.order_status==10&&item.pay_status==10"
@click="goJump('/pages/news3/updatePrice',item)">修改价格</view>
@ -130,7 +133,7 @@
{{audit_status==20?'拒绝':'同意'}}转移至售后
</view>
<view class="filterItem c">
<view class="itemTitle">
<!-- <view class="itemTitle">
上传照片 <text style="color:#FF5042">*</text><text>最多可传5张图片</text>
</view>
<u-upload :action="action" :header="header" @on-uploaded="refundSuccess" @on-remove="refundRemove"
@ -141,7 +144,7 @@
<view class="1">上传图片</view>
</view>
</template>
</u-upload>
</u-upload> -->
<view class="filterItemContent">
<view class="itemTitle">
备注
@ -155,7 +158,8 @@
</view>
</view>
</u-popup>
<u-modal v-model="deleteShow" :show-cancel-button="true" :closable='false' @cancel="deleteShow=false" @confirm="handleOk" title="确认删除订单?" confirm-color="#F55349">
<u-modal v-model="deleteShow" :show-cancel-button="true" :closable='false' @cancel="deleteShow=false"
@confirm="handleOk" title="确认删除订单?" confirm-color="#F55349">
<view class="slot-content order-modal">
<view class="content">删除之后订单无法恢复无法处理您的售后问题 请慎重考虑</view>
<view class="desc" @click="toggleImage()">
@ -263,8 +267,8 @@
}
this.getList()
},
onLoad() {
onLoad(option) {
console.log("会员管理带来的user_id",option.user_id)
},
methods: {
reset() {
@ -635,6 +639,7 @@
.shopItemInfo {
display: flex;
margin-top: 40upx;
align-items: center;
image {
width: 180upx;
@ -642,12 +647,23 @@
flex-shrink: 0;
}
.priceName {
margin-left: 40upx;
.title {
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
overflow: hidden;
}
}
.priceCon {
flex: 1;
display: flex;
align-items: flex-end;
justify-content: space-between;
margin-left: 40upx;
margin-top: 30rpx;
.num {
font-size: 28upx;

@ -1,5 +1,5 @@
<template>
<view>
<view style="padding-bottom: 160rpx;">
<view class="park-navbar">
<u-navbar title="确认订单" :border-bottom="false" :background="background"></u-navbar>
</view>
@ -8,12 +8,23 @@
<!-- 订单状态 -->
<view class="order-status">
<view class="status">
<image :src="$picUrl+'/static/news3/time.png'" mode="widthFix"></image>
<!-- 待支付 -->
<image src="/static/order/status/wait_pay.png" mode="widthFix"
v-if="orderInfo.order_status == 10&&orderInfo.delivery_status==10"></image>
<!-- 待发货 -->
<image src="/static/order/status/wait_deliver.png" mode="widthFix"
v-else-if="orderInfo.order_status == 10 &&orderInfo.delivery_status==30"></image>
<!-- 待收货 -->
<image src="/static/order/status/wait_receipt.png" mode="widthFix"
v-else-if="orderInfo.order_status == 10 &&orderInfo.delivery_status==20 && orderInfo.receipt_status==10">
</image>
<!-- -->
<image src="/static/order/status/received.png" mode="widthFix" v-else></image>
<text>{{orderInfo.state_text}}</text>
</view>
<view class="reason"
v-if="(!orderInfo.order_refund_id&&orderInfo.order_status==10&&orderInfo.pay_status==10)||(!orderInfo.order_refund_id&&orderInfo.delivery_status==20&&orderInfo.order_status==10&&orderInfo.pay_status==20 && orderInfo.receipt_status==10)">
<u-count-down :timestamp="timestamp"></u-count-down>
v-if="(orderInfo.time_text>0&&!orderInfo.order_refund_id&&orderInfo.order_status==10&&orderInfo.pay_status==10)||(orderInfo.time_text>0&&!orderInfo.order_refund_id&&orderInfo.delivery_status==20&&orderInfo.order_status==10&&orderInfo.pay_status==20 && orderInfo.receipt_status==10)">
<u-count-down :timestamp="orderInfo.time_text" :show-days="false"></u-count-down>
<text style="color:#666666">
<text
v-if="!orderInfo.order_refund_id&&orderInfo.order_status==10&&orderInfo.pay_status==10">自动取消</text>
@ -94,7 +105,7 @@
<text>联系客户</text>
</view>
<view class="btnItem" style="border-left:1px solid #F4F4F4"
@click="callStore(order.storeInfo.phone)">
@click="callStore(order.storeInfo.store_phone)">
<image :src="$picUrl+'/static/news3/kefu.png'" mode="widthFix"></image>
<text>联系商家</text>
</view>
@ -106,20 +117,19 @@
<view class="remarkTitle">售后信息</view>
<view class="list">
<view class="title">退货类型:</view>
<view class="content">{{orderInfo.order_no}}</view>
<view class="content">{{orderInfo.refund_type_text}}</view>
</view>
<view class="list">
<view class="title">申请原因:</view>
<view class="content">{{orderInfo.apply_desc}}</view>
<view class="content">{{orderInfo.apply_desc||'-'}}</view>
</view>
<view class="list">
<view class="list" v-if="orderInfo.refuse_desc">
<view class="title">申请备注:</view>
<view class="content">{{orderInfo.order_no}}</view>
<view class="content">{{orderInfo.refuse_desc||'-'}}</view>
</view>
<view class="remarkText">申请图片</view>
<view class="img">
<image :src="$picUrl+'/static/news3/filter.png'" mode=""></image>
<image :src="$picUrl+'/static/news3/filter.png'" mode=""></image>
<view class="remarkText" v-if="orderInfo.images.length>0">申请图片</view>
<view class="img" v-if="orderInfo.images.length>0">
<image v-for="(item,index) in orderInfo.images" :src="item.image_url" mode=""></image>
</view>
</view>
<!-- 订单信息 -->
@ -160,7 +170,7 @@
<!-- 底部按钮 -->
<view class="footer-btn">
<view class="del"
v-show="(!orderInfo.order_refund_id&&orderInfo.order_status==10&&orderInfo.pay_status==10) || (!orderInfo.order_refund_id&&orderInfo.order_status==10&&orderInfo.pay_status==20&&orderInfo.delivery_status==30)"
v-show="!orderInfo.order_refund_id&&orderInfo.order_status==10&&orderInfo.pay_status==20&&orderInfo.delivery_status==30"
@click="goJump('/pages/news3/updateAddr',orderInfo,0)">修改地址</view>
<view class="btn"
v-show="!orderInfo.order_refund_id&&orderInfo.order_status==10&&orderInfo.pay_status==10"
@ -181,13 +191,13 @@
<u-popup v-model=" afterSale" width="80%" border-radius="10" :closeable="true" mode="center">
<view class="afterSales">
<view class="filterTitle">
{{audit_status==20?'拒绝':'同意'}}
{{audit_status==20?'拒绝':'同意'}}转移至售后
</view>
<view class="filterItem c">
<view class="itemTitle">
<!-- <view class="itemTitle">
上传照片 <text style="color:#FF5042">*</text><text>最多可传5张图片</text>
</view>
<u-upload :action="action" :header="header" @on-uploaded="refundSuccess" @on-remove="refundRemove"
</view> -->
<!-- <u-upload :action="action" :header="header" @on-uploaded="refundSuccess" @on-remove="refundRemove"
width="180" height="180" :file-list="transferList" :custom-btn="true" max-count="5">
<template v-slot:addBtn>
<view class="slot-btn" hover-class="slot-btn__hover" hover-stay-time="150">
@ -195,7 +205,7 @@
<view class="1">上传图片</view>
</view>
</template>
</u-upload>
</u-upload> -->
<view class="filterItemContent">
<view class="itemTitle">
审核备注
@ -339,14 +349,15 @@
page {
background-color: #F7F8FA;
min-height: 100%;
padding-bottom: 140upx;
padding-bottom: 140rpx;
}
.orderInfo {
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: 10rpx;
margin-bottom: 120rpx;
text {
font-size: 28upx;
color: #707070;
@ -367,7 +378,7 @@
position: relative;
z-index: 2;
margin: 0upx 26upx;
padding-top: 30upx;
padding-top: 20upx;
}
.navBarContent {
@ -406,8 +417,8 @@
width: 100%;
image {
width: 54upx;
height: auto;
width: 89upx;
height: 89upx;
}
text {

@ -23,7 +23,7 @@
</view>
</view>
</view>
<view class="selectContent" style="padding:36upx 0 10upx 0;" @click="setPrice(item)">
<view class="selectContent" style="padding:36rpx 0 10rpx 0;margin-top: 30rpx;" @click="setPrice(item)">
<view class="left">
修改单个商品价格
</view>
@ -142,6 +142,7 @@
::v-deep .u-input {
width: 300rpx !important;
text-align: right !important;
}
.updatePrice {

@ -160,7 +160,7 @@
支付方式
</view>
<view class="price">
{{order.pay_method}}
{{order.pay_method_text}}
</view>
</view>
<view class="orderTitle">

@ -115,7 +115,7 @@
<view class="sell">
会员分销
</view>
<view class="type" @click="goJump('/pages/news/user/vip')">
<view class="type" @click="goManagementHandle('/pages/news/user/vip','会员管理')">
<view class="typeLeft common">
会员管理<u-icon style="margin-left: 10rpx;" name="arrow-right"></u-icon>
</view>

Loading…
Cancel
Save