|
@@ -17,11 +17,12 @@
|
|
</span>
|
|
</span>
|
|
|
|
|
|
<div class="operate-button-container" >
|
|
<div class="operate-button-container" >
|
|
|
|
+ <el-button size="mini" @click="handleCertificates()" v-hasPermi="['store:storeOrder:uploadCredentials']" >上传凭证</el-button>
|
|
<el-button size="mini" @click="handleEditAddress()" v-if="order.status==0||order.status==1" v-hasPermi="['store:storeOrder:editAddress']" >修改收货地址</el-button>
|
|
<el-button size="mini" @click="handleEditAddress()" v-if="order.status==0||order.status==1" v-hasPermi="['store:storeOrder:editAddress']" >修改收货地址</el-button>
|
|
<el-button size="mini" @click="handleBindCustomer()" v-hasPermi="['store:storeOrder:bindCustomer']" >关联客户</el-button>
|
|
<el-button size="mini" @click="handleBindCustomer()" v-hasPermi="['store:storeOrder:bindCustomer']" >关联客户</el-button>
|
|
<el-button size="mini" @click="editOrder()" v-hasPermi="['store:storeOrder:edit']" >修改订单</el-button>
|
|
<el-button size="mini" @click="editOrder()" v-hasPermi="['store:storeOrder:edit']" >修改订单</el-button>
|
|
<!-- <el-button size="mini" @click="handleEditUser()" v-hasPermi="['users:user:edit']" >修改会员修改</el-button> -->
|
|
<!-- <el-button size="mini" @click="handleEditUser()" v-hasPermi="['users:user:edit']" >修改会员修改</el-button> -->
|
|
- <el-button size="mini" v-if="order.customerId!=null&&order.customerId>0" @click="handleCustomer()" >查看客户详情</el-button>
|
|
|
|
|
|
+ <el-button size="mini" v-if="order.customerId!=null&&order.customerId>0" @click="handleCustomer()" >查看客户详情</el-button>
|
|
</div>
|
|
</div>
|
|
<div class="operate-button-container" v-hasPermi="['store:storeOrder:express']" >
|
|
<div class="operate-button-container" v-hasPermi="['store:storeOrder:express']" >
|
|
<el-button size="mini" @click="showExpress()" >查看物流</el-button>
|
|
<el-button size="mini" @click="showExpress()" >查看物流</el-button>
|
|
@@ -124,6 +125,21 @@
|
|
</el-descriptions-item>
|
|
</el-descriptions-item>
|
|
|
|
|
|
</el-descriptions>
|
|
</el-descriptions>
|
|
|
|
+ <div style="margin: 20px 0px" v-if="order!=null">
|
|
|
|
+ <span class="font-small">
|
|
|
|
+ 凭证信息
|
|
|
|
+ </span>
|
|
|
|
+ </div>
|
|
|
|
+ <el-image
|
|
|
|
+ v-if="certificates != ''"
|
|
|
|
+ :src="certificates"
|
|
|
|
+ :preview-src-list="[certificates]"
|
|
|
|
+ :style="{ width: '100px', height: '100px' }"
|
|
|
|
+ @click.native="showImageDialog"
|
|
|
|
+ ></el-image>
|
|
|
|
+ <el-dialog :visible.sync="dialogVisibleImage" width="10%">
|
|
|
|
+ <img :src="certificates" style="width: 100%" alt="">
|
|
|
|
+ </el-dialog>
|
|
|
|
|
|
<div style="margin-top: 20px">
|
|
<div style="margin-top: 20px">
|
|
<span class="font-small">商品信息</span>
|
|
<span class="font-small">商品信息</span>
|
|
@@ -399,6 +415,16 @@
|
|
<el-button type="primary" @click="submitBindCustomerForm">确 定</el-button>
|
|
<el-button type="primary" @click="submitBindCustomerForm">确 定</el-button>
|
|
</div>
|
|
</div>
|
|
</el-dialog>
|
|
</el-dialog>
|
|
|
|
+ <el-dialog :title="certificateDialig.title" :visible.sync="certificateDialig.open" append-to-body>
|
|
|
|
+ <el-form ref="certificateForm" :model="certificateForm" :rules="certificateRules" label-width="100px">
|
|
|
|
+ <el-form-item label="凭证" prop="certificates">
|
|
|
|
+ <ImageUpload v-model="photoArr" type="image" :num="10" :width="150" :height="150" />
|
|
|
|
+ </el-form-item>
|
|
|
|
+ </el-form>
|
|
|
|
+ <div slot="footer" class="dialog-footer">
|
|
|
|
+ <el-button type="primary" @click="handleConfirm">确 定</el-button>
|
|
|
|
+ </div>
|
|
|
|
+ </el-dialog>
|
|
<el-drawer
|
|
<el-drawer
|
|
:append-to-body="true"
|
|
:append-to-body="true"
|
|
size="75%"
|
|
size="75%"
|
|
@@ -413,20 +439,35 @@
|
|
import {updateUser,getUser } from "@/api/users/user";
|
|
import {updateUser,getUser } from "@/api/users/user";
|
|
|
|
|
|
import {getCustomerListBySearch } from "@/api/crm/customer";
|
|
import {getCustomerListBySearch } from "@/api/crm/customer";
|
|
-
|
|
|
|
-import {bindCustomer,getExpress, listStoreOrder, getStoreOrder, delStoreOrder, addStoreOrder, updateStoreOrder, exportStoreOrder } from "@/api/store/storeOrder";
|
|
|
|
|
|
+import ImageUpload from '@/components/ImageUpload'
|
|
|
|
+import {bindCustomer,getExpress, listStoreOrder, getStoreOrder, delStoreOrder, addStoreOrder, updateStoreOrder, exportStoreOrder,uploadCredentials } from "@/api/store/storeOrder";
|
|
import {getAllList} from "@/api/store/city";
|
|
import {getAllList} from "@/api/store/city";
|
|
import customerDetails from '../../crm/components/customerDetails.vue';
|
|
import customerDetails from '../../crm/components/customerDetails.vue';
|
|
export default {
|
|
export default {
|
|
name: "order",
|
|
name: "order",
|
|
- components: {customerDetails },
|
|
|
|
|
|
+ components: {customerDetails,
|
|
|
|
+ ImageUpload },
|
|
data() {
|
|
data() {
|
|
return {
|
|
return {
|
|
|
|
+ dialogVisibleImage: false,
|
|
customerInfo:null,
|
|
customerInfo:null,
|
|
customer:{
|
|
customer:{
|
|
title:"客户详情",
|
|
title:"客户详情",
|
|
open:false,
|
|
open:false,
|
|
},
|
|
},
|
|
|
|
+ photoArr:'',
|
|
|
|
+ certificateDialig:{
|
|
|
|
+ title:"上传凭证",
|
|
|
|
+ open:false,
|
|
|
|
+ },
|
|
|
|
+ certificateForm:{
|
|
|
|
+ certificates:null,
|
|
|
|
+ },
|
|
|
|
+ certificateRules:{
|
|
|
|
+ certificates:[
|
|
|
|
+ { required: true, message: "凭证不能为空", trigger: "change" }
|
|
|
|
+ ]
|
|
|
|
+ },
|
|
customers:[],
|
|
customers:[],
|
|
bindCustomerDialog:{
|
|
bindCustomerDialog:{
|
|
title:"关联客户",
|
|
title:"关联客户",
|
|
@@ -489,6 +530,7 @@ export default {
|
|
orderTypeOptions:[],
|
|
orderTypeOptions:[],
|
|
payTypeOptions:[],
|
|
payTypeOptions:[],
|
|
statusOptions:[],
|
|
statusOptions:[],
|
|
|
|
+ certificates:'',
|
|
order:null,
|
|
order:null,
|
|
user:{},
|
|
user:{},
|
|
logs:[],
|
|
logs:[],
|
|
@@ -514,6 +556,9 @@ export default {
|
|
|
|
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
|
|
+ showImageDialog() {
|
|
|
|
+ this.dialogVisible = true;
|
|
|
|
+ },
|
|
handleCustomer(){
|
|
handleCustomer(){
|
|
var that=this;
|
|
var that=this;
|
|
this.customer.open = true;
|
|
this.customer.open = true;
|
|
@@ -554,6 +599,20 @@ export default {
|
|
}
|
|
}
|
|
});
|
|
});
|
|
},
|
|
},
|
|
|
|
+ handleCertificates(){
|
|
|
|
+ this.certificateDialig.open = true;
|
|
|
|
+ },
|
|
|
|
+ handleConfirm(){
|
|
|
|
+ this.certificateForm.id = this.orderId;
|
|
|
|
+ this.certificateForm.certificates = this.photoArr;
|
|
|
|
+ uploadCredentials(this.certificateForm).then(response => {
|
|
|
|
+ if (response.code === 200) {
|
|
|
|
+ this.msgSuccess("上传成功");
|
|
|
|
+ this.certificateDialig.open = false;
|
|
|
|
+ this.getOrder(this.order.id);
|
|
|
|
+ }
|
|
|
|
+ });
|
|
|
|
+ },
|
|
showExpress(){
|
|
showExpress(){
|
|
this.expressDialog.open=true;
|
|
this.expressDialog.open=true;
|
|
getExpress(this.orderId).then(response => {
|
|
getExpress(this.orderId).then(response => {
|
|
@@ -694,12 +753,14 @@ export default {
|
|
this.orderId=orderId;
|
|
this.orderId=orderId;
|
|
getStoreOrder(orderId).then(response => {
|
|
getStoreOrder(orderId).then(response => {
|
|
this.order = response.order;
|
|
this.order = response.order;
|
|
|
|
+ if(response.order.certificates != null){
|
|
|
|
+ this.certificates = response.order.certificates;
|
|
|
|
+ }
|
|
this.user = response.user;
|
|
this.user = response.user;
|
|
this.logs = response.logs;
|
|
this.logs = response.logs;
|
|
this.items = response.items;
|
|
this.items = response.items;
|
|
this.payments=response.payments;
|
|
this.payments=response.payments;
|
|
this.customerInfo=response.customer;
|
|
this.customerInfo=response.customer;
|
|
-
|
|
|
|
});
|
|
});
|
|
}
|
|
}
|
|
}
|
|
}
|