|
@@ -121,16 +121,6 @@
|
|
import empty from "@/components/empty";
|
|
import empty from "@/components/empty";
|
|
import shareAlert from '@/components/cm-module/modelAlert/shareAlert' //分享弹窗
|
|
import shareAlert from '@/components/cm-module/modelAlert/shareAlert' //分享弹窗
|
|
import authorize from '@/common/config/authorize.js'
|
|
import authorize from '@/common/config/authorize.js'
|
|
- import {
|
|
|
|
- searchOrderInfo,
|
|
|
|
- searchOrderHistory,
|
|
|
|
- clearOrderHistory,
|
|
|
|
- queryOrderList,
|
|
|
|
- cancelOrder,
|
|
|
|
- deleteOrder,
|
|
|
|
- confirmReceipt,
|
|
|
|
- affirmOrder
|
|
|
|
- } from "@/api/order.js"
|
|
|
|
export default {
|
|
export default {
|
|
components: {
|
|
components: {
|
|
orSearch,
|
|
orSearch,
|
|
@@ -193,7 +183,7 @@
|
|
initGetSerachRecord(){
|
|
initGetSerachRecord(){
|
|
this.$api.getStorage().then((resolve) =>{
|
|
this.$api.getStorage().then((resolve) =>{
|
|
this.userID = resolve.userID
|
|
this.userID = resolve.userID
|
|
- searchOrderHistory({userId:this.userID}).then(response =>{
|
|
|
|
|
|
+ this.OrderService.SearchOrderHistory({userId:this.userID}).then(response =>{
|
|
this.serachRecordList = response.data
|
|
this.serachRecordList = response.data
|
|
if(this.serachRecordList.length>0){
|
|
if(this.serachRecordList.length>0){
|
|
this.isSearchHistory = true
|
|
this.isSearchHistory = true
|
|
@@ -226,7 +216,7 @@
|
|
},
|
|
},
|
|
confirmDetele () {//清空历史记录
|
|
confirmDetele () {//清空历史记录
|
|
this.$util.modal('提示','确定删除历史记录?','确定','取消',true,() =>{
|
|
this.$util.modal('提示','确定删除历史记录?','确定','取消',true,() =>{
|
|
- clearOrderHistory({userId:this.userID}).then(response =>{
|
|
|
|
|
|
+ this.OrderService.ClearOrderHistory({userId:this.userID}).then(response =>{
|
|
this.$util.msg('删除记录成功',2000,true,'success')
|
|
this.$util.msg('删除记录成功',2000,true,'success')
|
|
this.serachRecordList=[]
|
|
this.serachRecordList=[]
|
|
}).catch(error =>{
|
|
}).catch(error =>{
|
|
@@ -252,7 +242,7 @@
|
|
* @param:organizeID(全局变量组织ID)
|
|
* @param:organizeID(全局变量组织ID)
|
|
*/
|
|
*/
|
|
let params = {searchWord:this.searchInputVal,userId:this.userID,pageNum:1,pageSize:this.pageSize};
|
|
let params = {searchWord:this.searchInputVal,userId:this.userID,pageNum:1,pageSize:this.pageSize};
|
|
- searchOrderInfo(params).then(response =>{
|
|
|
|
|
|
+ this.OrderService.SearchOrderInfo(params).then(response =>{
|
|
this.isShowWrapper = true
|
|
this.isShowWrapper = true
|
|
this.showSkeleton = true
|
|
this.showSkeleton = true
|
|
const _responseData = response.data.results;
|
|
const _responseData = response.data.results;
|
|
@@ -289,7 +279,7 @@
|
|
getOnReachBottomData(index){//上拉加载
|
|
getOnReachBottomData(index){//上拉加载
|
|
this.pageNum+=1
|
|
this.pageNum+=1
|
|
let params = {searchWord:this.searchInputVal,userId:this.userID,pageNum:this.pageNum,pageSize:this.pageSize}
|
|
let params = {searchWord:this.searchInputVal,userId:this.userID,pageNum:this.pageNum,pageSize:this.pageSize}
|
|
- searchOrderInfo(params).then(response =>{
|
|
|
|
|
|
+ this.OrderService.SearchOrderInfo(params).then(response =>{
|
|
let resData = response.data.results
|
|
let resData = response.data.results
|
|
this.hasNextPage = response.data.hasNextPage;
|
|
this.hasNextPage = response.data.hasNextPage;
|
|
this.orderList = this.orderList.concat(resData)
|
|
this.orderList = this.orderList.concat(resData)
|
|
@@ -345,7 +335,7 @@
|
|
},
|
|
},
|
|
handOrderConfirm (id){//确认收货
|
|
handOrderConfirm (id){//确认收货
|
|
this.$util.modal('提示','是否确认收货','确定','取消',true,() =>{
|
|
this.$util.modal('提示','是否确认收货','确定','取消',true,() =>{
|
|
- confirmReceipt({orderID:id}).then(response =>{
|
|
|
|
|
|
+ this.OrderService.ConfirmReceipt({orderID:id}).then(response =>{
|
|
this.$util.msg(response.msg,2000,true,'success');
|
|
this.$util.msg(response.msg,2000,true,'success');
|
|
this.getOrderDatainit()
|
|
this.getOrderDatainit()
|
|
}).catch(error =>{
|
|
}).catch(error =>{
|
|
@@ -355,7 +345,7 @@
|
|
},
|
|
},
|
|
handOrderConfirmation (id){//确认订单
|
|
handOrderConfirmation (id){//确认订单
|
|
this.$util.modal('提示','确认此订单?','确定','取消',true,() =>{
|
|
this.$util.modal('提示','确认此订单?','确定','取消',true,() =>{
|
|
- affirmOrder({orderID:id}).then(response =>{
|
|
|
|
|
|
+ this.OrderService.AffirmOrder({orderID:id}).then(response =>{
|
|
this.$util.msg(response.msg,2000,true,'success');
|
|
this.$util.msg(response.msg,2000,true,'success');
|
|
setTimeout(() => {
|
|
setTimeout(() => {
|
|
this.getOrderDatainit()
|
|
this.getOrderDatainit()
|
|
@@ -367,7 +357,7 @@
|
|
},
|
|
},
|
|
handOrderDetele(id){//删除订单
|
|
handOrderDetele(id){//删除订单
|
|
this.$util.modal('提示','确认删除该订单吗?','确定','取消',true,() =>{
|
|
this.$util.modal('提示','确认删除该订单吗?','确定','取消',true,() =>{
|
|
- deleteOrder({orderID:id}).then(response =>{
|
|
|
|
|
|
+ this.OrderService.DeleteOrder({orderID:id}).then(response =>{
|
|
this.$util.msg(response.msg,2000,true,'success');
|
|
this.$util.msg(response.msg,2000,true,'success');
|
|
setTimeout(() => {
|
|
setTimeout(() => {
|
|
this.getOrderDatainit()
|
|
this.getOrderDatainit()
|
|
@@ -379,7 +369,7 @@
|
|
},
|
|
},
|
|
handCenceConfirm(id){//取消订单
|
|
handCenceConfirm(id){//取消订单
|
|
this.$util.modal('提示','确认取消该订单吗?','确定','取消',true,() =>{
|
|
this.$util.modal('提示','确认取消该订单吗?','确定','取消',true,() =>{
|
|
- cancelOrder({orderID:id}).then(response =>{
|
|
|
|
|
|
+ this.OrderService.CancelOrder({orderID:id}).then(response =>{
|
|
this.$util.msg(response.msg,2000,true,'success');
|
|
this.$util.msg(response.msg,2000,true,'success');
|
|
setTimeout(() => {
|
|
setTimeout(() => {
|
|
this.getOrderDatainit()
|
|
this.getOrderDatainit()
|