lanan-old/detection-business/pages/my/rwmlist.vue
愉快的大福 7dc28dc701 init
2024-07-17 14:16:22 +08:00

339 lines
6.2 KiB
Vue
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!-- -->
<template>
<view class="content">
<view style="width: 100%; height: 44px;"></view>
<view class="top-heder">
<view class="t-left" @click="getfan()">
<uni-icons type="left" size="18"></uni-icons>
</view>
<view class="t-input">
<uni-icons type="search" color="#BCBCBC" size="22"></uni-icons>
<input type="text" v-model="searchValue" placeholder="请输入手机号/核销人">
</view>
<view class="sou" @click="getindex()">搜索</view>
</view>
<view class="mub">
<view class="top-ail">
<view class="jsy" v-if="goodsList.length == 0">
<image src="http://www.nuoyunr.com/lananRsc/detection/qs.png" mode=""></image>
</view>
<view class="a-box" v-for="(item,index) in goodsList" :key="index">
<view class="t-box">
<view class="s-right">
<view class="s-title">{{item.goodsTitle}}</view>
<view class="s-hui">订单号{{item.orderNo}}</view>
<view class="s-hui">客户{{item.realName}}</view>
<view class="s-hui">手机号{{item.phonenumber}}</view>
<view class="s-hui">核销人{{item.validationRealName}}</view>
<view class="s-hui">核销人手机号{{item.phonenumber}}</view>
<view class="s-hui">{{item.validationTime}}</view>
<view class="s-ju">
<text>{{(item.payMoney + item.balance)/100}}</text>
</view>
</view>
</view>
</view>
</view>
</view>
<!-- 底部 -->
</view>
</template>
<script>
import config from '@/config'
import request from '../../utils/request';
export default {
data() {
return {
msg:'3',
goodsList:[],
baseUrl:"http://192.168.1.4:8080/lanan",
partnerId:'',
isListing:1,
searchValue:'',
goodsTitle:"",
taplist:[
{Text:'已发布',id:1},
{Text:'待上架',id:0},
],
pageNum: 1,//第几页
pageSize: 20,//一页多少张
totalPages: 0,//总数
}
},
onLoad() {
},
onPullDownRefresh() {
uni.showLoading()
setTimeout(() => {
uni.hideLoading()
uni.stopPullDownRefresh()
}, 500)
},
onReachBottom() {
console.log(111)
if (this.pageNum >= this.totalPages) {
uni.showToast({
title: '没有下一页数据',
icon: 'none'
})
} else {
this.pageNum++
console.log(222)
this.getindex()
}
},
onShow() {
// this.baseUrl = this.$baseUrl
this.partnerId = uni.getStorageSync('partnerId')
this.getindex()
},
methods: {
async getindex(){
//
let data = {
partnerId:this.partnerId,
searchValue:this.searchValue,
pageSize:this.pageSize,
pageNum:this.pageNum
}
let res = await request({
url:'/partnerOwn/partner/validationList',
method: 'get',
params: data
})
if(res.code == 200){
this.goodsList = res.rows
let total = res.total
this.totalPages = Math.ceil(total / this.pageSize);
}
},
// 去编辑
getedit(id){
uni.navigateTo({
url:'/pages/order/editorder?id='+id
})
},
// 下架
async getxia(id){
let data ={
goodsId :id
}
let res = await request({
url:'/partnerOwn/partner/changeListing',
method: 'post',
params: data
})
if(res.code == 200){
uni.showToast({
title:"操作成功",
})
this.getindex()
}
},
// 删除
async getdelete(id){
let data ={
goodsId :id
}
let res = await request({
url:'/partnerOwn/partner/delGoods',
method: 'post',
params: data
})
if(res.code == 200){
uni.showToast({
title:"操作成功",
})
this.getindex()
}
},
gettapindex(index,id){
this.isListing = id
this.getindex()
},
getfan(){
uni.navigateBack()
}
}
}
</script>
<style scoped lang="scss">
.content {
box-sizing: border-box;
width: 100%;
height: calc(100vh);
background: white;
}
.dis{
width: 100%;
display: flex;
align-items: center;
}
.top-heder{
width: 100%;
height: 46px;
background: white;
display: flex;
justify-content: space-between;
align-items: center;
box-sizing: border-box;
padding: 5px 15px;
}
.t-left{
width: 10%;
}
.t-input{
width: 75%;
height: 36px;
background: #F0F0F0;
border-radius: 50px;
box-sizing: border-box;
padding: 0 15px;
display: flex;
align-items: center;
}
.top-ail{
width: 100%;
box-sizing: border-box;
padding: 15px;
background-color: #F4F4F4;
}
.sou{
width: 10%;
margin-left: 5px;
}
.mub{
background-color: #F4F4F4;
height: calc(100vh);
}
.dix{
display: flex;
align-items: center;
}
.top-tap{
width: 100%;
height: 44px;
display: flex;
justify-content: space-between;
align-items: center;
}
.tap-box{
width: 50%;
height: 100%;
text-align: center;
font-size: 16px;
font-weight: 400;
color: #606266;
box-sizing: border-box;
padding-top: 10px;
}
.gang{
width: 30px;
height: 4px;
background: #0D2E8D;
border-radius: 4px;
margin: 4px auto;
}
.a-box{
width: 100%;
border-radius: 8px;
background-color: white;
box-sizing: border-box;
padding: 15px;
margin-bottom: 10px;
}
.t-box{
width: 100%;
box-sizing: border-box;
padding-bottom: 15px;
display: flex;
border-bottom: 1px solid #EEEEEE;
}
.s-img{
width: 110px;
height: 110px;
margin-right: 10px;
overflow: hidden;
border-radius: 8px;
image{
width: 100%;
height: 100%;
}
}
.s-right{
width: 100%;
}
.s-title{
font-size: 18px;
font-weight: bold;
color: #333333;
}
.s-hui{
font-size: 15px;
font-weight: 400;
color: #999999;
}
.s-ju{
text-align: right;
font-size: 18px;
font-weight: bold;
color: #FF571A;
}
.d-bottom{
width: 100%;
box-sizing: border-box;
padding-top: 10px;
display: flex;
align-items: center;
justify-content: flex-end;
}
.bottom-box{
width: 66px;
height: 31px;
background: #DAE1F8;
display: flex;
justify-content: center;
align-items: center;
border-radius: 50px;
font-size: 15px;
font-weight: 400;
color: #0D2E8D;
margin-left: 5px;
}
.lan{
color: #0D2E8D !important;
}
.jsy{
width: 100%;
margin-top: 20px;
text-align: center;
color: #0D2E8D !important;
}
</style>