积分商城
This commit is contained in:
File diff suppressed because it is too large
Load Diff
@@ -10,16 +10,15 @@
|
||||
@click="selectOptions(index)">{{item.text}}<text>({{item.count}})</text></view>
|
||||
</view>
|
||||
<view class="search">
|
||||
<uni-easyinput prefixIcon="search" borderColor="#DCDFE6" v-model="paramter.params.productName" placeholder="请输入商品名称"
|
||||
@confirm="search" @clear="search" />
|
||||
<uni-easyinput prefixIcon="search" borderColor="#DCDFE6" v-model="paramter.params.productName"
|
||||
placeholder="请输入商品名称" @confirm="search" @clear="search" />
|
||||
</view>
|
||||
|
||||
|
||||
<scroll-view v-if="dataList.length" class="list" :scroll-y="true" @scrolltolower="lower">
|
||||
<view class="item" v-for="item,index in dataList" :key="index">
|
||||
<view class="header">
|
||||
<view class="identifying"
|
||||
:style="{background:identifying[item.productStatus].background,
|
||||
<view class="identifying" :style="{background:identifying[item.productStatus].background,
|
||||
opacity:identifying[item.productStatus].opacity}">{{item.productStatus =='1'?'已上架':'未上架'}}</view>
|
||||
</view>
|
||||
<view class="introduce">
|
||||
@@ -29,7 +28,8 @@
|
||||
<view>库存:{{item.totalStock}}</view>
|
||||
</view>
|
||||
<view class="examine" @click="examineDetail(item)"
|
||||
:style="{background:statusEnum[item.auditStatus].color}" >{{statusEnum[item.auditStatus].value}}</view>
|
||||
:style="{background:statusEnum[item.auditStatus].color}">{{statusEnum[item.auditStatus].value}}
|
||||
</view>
|
||||
<view class="footer">
|
||||
<view class="button" @click="orderDelete">删除</view>
|
||||
<view class="button" @click="toEditOrder(item)">编辑</view>
|
||||
@@ -128,7 +128,7 @@
|
||||
count: 0,
|
||||
value: ''
|
||||
}],
|
||||
identifying:{
|
||||
identifying: {
|
||||
1: {
|
||||
background: '#F83D3D',
|
||||
opacity: 1,
|
||||
@@ -154,8 +154,8 @@
|
||||
value: "已驳回"
|
||||
},
|
||||
},
|
||||
examineDetailList:[],
|
||||
productData:{}
|
||||
examineDetailList: [],
|
||||
productData: {}
|
||||
}
|
||||
},
|
||||
|
||||
@@ -167,17 +167,17 @@
|
||||
methods: {
|
||||
selectOptions(index) {
|
||||
this.currentIndex = index
|
||||
console.log(index,'index')
|
||||
if(index == 0){
|
||||
this.paramter.params ={}
|
||||
}else if(index ==1){
|
||||
this.paramter.params ={}
|
||||
console.log(index, 'index')
|
||||
if (index == 0) {
|
||||
this.paramter.params = {}
|
||||
} else if (index == 1) {
|
||||
this.paramter.params = {}
|
||||
this.paramter.params.productStatus = 1
|
||||
}else if(index ==2){
|
||||
this.paramter.params ={}
|
||||
} else if (index == 2) {
|
||||
this.paramter.params = {}
|
||||
this.paramter.params.productStatus = 2
|
||||
}else if(index ==3){
|
||||
this.paramter.params ={}
|
||||
} else if (index == 3) {
|
||||
this.paramter.params = {}
|
||||
this.paramter.params.auditStatus = 1
|
||||
}
|
||||
this.productByPage()
|
||||
@@ -197,7 +197,7 @@
|
||||
// url: `../orderDetails/index?orderId=${item.id}`
|
||||
// })
|
||||
// },
|
||||
getTopInfo(){
|
||||
getTopInfo() {
|
||||
serve.getTopInfo(this.paramter).then(res => {
|
||||
if (res.code === 20000) {
|
||||
this.optionsList[0].count = res.data.count
|
||||
@@ -233,16 +233,18 @@
|
||||
this.paramter.currentPage += 1
|
||||
this.productByPage()
|
||||
},
|
||||
examineDetail(item){
|
||||
serve.productAuditHistory({id:item.id}).then(res=>{
|
||||
examineDetail(item) {
|
||||
serve.productAuditHistory({
|
||||
id: item.id
|
||||
}).then(res => {
|
||||
this.examineDetailList = res.data
|
||||
})
|
||||
this.$refs.detail.open('center')
|
||||
},
|
||||
orderDelete(){
|
||||
orderDelete() {
|
||||
this.$refs.delete.open('center')
|
||||
},
|
||||
toEditOrder(item){
|
||||
toEditOrder(item) {
|
||||
uni.navigateTo({
|
||||
url: `../productUpdate/index?id=${item.id}`
|
||||
})
|
||||
@@ -252,16 +254,16 @@
|
||||
this.productData = item
|
||||
this.$refs.popup.open('center')
|
||||
},
|
||||
submitProduct(){
|
||||
submitProduct() {
|
||||
let data = {}
|
||||
data.id = this.productData.id
|
||||
if(this.productData.productStatus ==1){
|
||||
if (this.productData.productStatus == 1) {
|
||||
data.productStatus = 2
|
||||
}else if(this.productData.productStatus ==2){
|
||||
} else if (this.productData.productStatus == 2) {
|
||||
data.productStatus = 1
|
||||
}
|
||||
|
||||
serve.productStatus(data).then(res=>{
|
||||
serve.productStatus(data).then(res => {
|
||||
uni.showToast({
|
||||
title: res.msg,
|
||||
icon: 'none'
|
||||
@@ -297,6 +299,7 @@
|
||||
background: #FFF;
|
||||
|
||||
}
|
||||
|
||||
>.options-frame {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
@@ -354,7 +357,7 @@
|
||||
color: #666;
|
||||
border-top: 1rpx solid #D7D7D7;
|
||||
|
||||
.identifying{
|
||||
.identifying {
|
||||
width: 120rpx;
|
||||
height: 60rpx;
|
||||
line-height: 60rpx;
|
||||
@@ -404,7 +407,8 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
.examine{
|
||||
|
||||
.examine {
|
||||
width: 120rpx;
|
||||
height: 45rpx;
|
||||
color: #FFF;
|
||||
@@ -438,14 +442,16 @@
|
||||
border-radius: 10rpx;
|
||||
}
|
||||
|
||||
>.button{
|
||||
&:nth-of-type(1){
|
||||
>.button {
|
||||
&:nth-of-type(1) {
|
||||
right: 360rpx;
|
||||
}
|
||||
&:nth-of-type(2){
|
||||
|
||||
&:nth-of-type(2) {
|
||||
right: 200rpx;
|
||||
}
|
||||
&:nth-of-type(3){
|
||||
|
||||
&:nth-of-type(3) {
|
||||
right: 40rpx;
|
||||
}
|
||||
|
||||
@@ -467,30 +473,35 @@
|
||||
color: #000;
|
||||
margin-bottom: 20rpx;
|
||||
}
|
||||
>uni-icons{
|
||||
|
||||
>uni-icons {
|
||||
position: absolute;
|
||||
top: 30rpx;
|
||||
right: 30rpx;
|
||||
}
|
||||
>.item{
|
||||
|
||||
>.item {
|
||||
display: flex;
|
||||
justify-content: space-evenly;
|
||||
overflow-y: hidden;
|
||||
font-size: 22rpx;
|
||||
color: #666;
|
||||
padding: 10rpx;
|
||||
view{
|
||||
|
||||
view {
|
||||
width: 240rpx;
|
||||
line-height: 46rpx;
|
||||
}
|
||||
>.status{
|
||||
|
||||
>.status {
|
||||
width: 160rpx;
|
||||
>view{
|
||||
|
||||
>view {
|
||||
width: 160rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.header{
|
||||
.header {
|
||||
font-size: 32rpx;
|
||||
color: #000;
|
||||
}
|
||||
@@ -574,4 +585,4 @@
|
||||
}
|
||||
|
||||
}
|
||||
</style>
|
||||
</style>
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user