!95 2022-1-24 Jiamin

Merge pull request !95 from Admin/sit-jiamin-v2
This commit is contained in:
Admin 2022-01-24 07:37:14 +00:00 committed by Gitee
commit 7b30bcfae8
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
5 changed files with 55 additions and 19 deletions

View File

@ -279,7 +279,7 @@
align-items: center; align-items: center;
height: 164px; height: 164px;
.rc-usercenter{ .rc-usercenter{
width: 25%; width: 27%;
em{ em{
font-size: 18px; font-size: 18px;
} }
@ -329,7 +329,7 @@
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
width: 58%; width: 56%;
font-size: 20px; font-size: 20px;
color: #E1001A; color: #E1001A;
font-weight: bold; font-weight: bold;

View File

@ -40,18 +40,18 @@
<div class="rc-center"> <div class="rc-center">
<div class="rc-usermain" v-for="(userlist,index) in item.orderDetailList" :key="index"> <div class="rc-usermain" v-for="(userlist,index) in item.orderDetailList" :key="index">
<div class="rc-image"> <div class="rc-image">
<img src="../../static/images/default.jpg" alt="" /> <img :src= userlist.picFile alt="" />
</div> </div>
<div class="rc-right"> <div class="rc-right">
<div class="rc-usercenter"> <div class="rc-usercenter">
<em>{{ userlist.productName }}</em> <em>{{ userlist.productName }}</em>
<div class="rc-userright"> <div class="rc-userright">
<span>规格:{{ item.productId }}</span> <span>规格:{{ userlist.specifications }}</span>
</div> </div>
</div> </div>
<div class="rc-userbottom"> <div class="rc-userbottom">
<span>数量:{{ item.pcs }}</span> <span>数量:{{ userlist.pcs }}</span>
<i>{{ 10 }}</i> <i>{{ userlist.ecPrice }}</i>
<div class="rc-bottom"> <div class="rc-bottom">
<span @click="userpay()">{{customer}}</span> <span @click="userpay()">{{customer}}</span>
</div> </div>
@ -96,7 +96,7 @@
</li> </li>
<li> <li>
<span>下单时间::</span> <span>下单时间::</span>
<i>{{ item.orderDate }}</i> <i>{{ logisticsDate }}</i>
</li> </li>
<li> <li>
<span>付款方式::</span> <span>付款方式::</span>
@ -147,8 +147,12 @@
import Myheader from "~/components/header.vue"; import Myheader from "~/components/header.vue";
import { mapMutations } from "vuex"; import { mapMutations } from "vuex";
import { userin} from "../../ajax/getData"; import { userin} from "../../ajax/getData";
import MyFooter from '~/components/rc-footer.vue' import MyFooter from '~/components/rc-footer.vue';
import Vue from 'vue';
let vm = new Vue();
import formatConversion from '../../static/js/date'
import {selectaddress,canceldanhao,generateOrderWX} from "../../ajax/getData"; import {selectaddress,canceldanhao,generateOrderWX} from "../../ajax/getData";
export default { export default {
data() { data() {
return { return {
@ -276,9 +280,7 @@ if(data){
else if(this.trackingstates==2){ else if(this.trackingstates==2){
this.trackingstates='未发货' this.trackingstates='未发货'
} }
console.log(this.goldmedal[i].orderDate); this.logisticsDate=this.formatConversion(this.goldmedal[i].orderDate)//
this.logisticsDate=new Date(this.goldmedal[i].orderDate.toLocaleString())//
console.log(this.logisticsDate);
this.logisticsCompany=this.goldmedal[i].orderDetailList[0].logisticsCompany; // this.logisticsCompany=this.goldmedal[i].orderDetailList[0].logisticsCompany; //
this.orderNumber=this.goldmedal[i].orderNumber this.orderNumber=this.goldmedal[i].orderNumber
this.usersalesAmount=this.goldmedal[i].salesAmount; this.usersalesAmount=this.goldmedal[i].salesAmount;

View File

@ -41,7 +41,7 @@
</div> </div>
<div class="rc-right"> <div class="rc-right">
<i :style='usercolor'> <i :style='usercolor'>
{{ item.couponName }} {{ item.couponDesc }}
</i> </i>
<div class="rc-userfont"> <div class="rc-userfont">
<strong>有效期</strong> <strong>有效期</strong>

View File

@ -44,23 +44,23 @@
</div> </div>
<div class="rc-usermain" > <div class="rc-usermain" >
<div class="rc-image"> <div class="rc-image">
<img src="../../static/images/default.jpg" alt="" /> <img :src= item.picFile alt="" />
</div> </div>
<div class="rc-right" @click="usertiaozhuan(item)"> <div class="rc-right" @click="usertiaozhuan(item)">
<div class="rc-usercenter"> <div class="rc-usercenter">
<em>{{ item.usereat }}</em> <em>{{ item.productName }}</em>
<div class="rc-userright"> <div class="rc-userright">
<span>规格:{{ item.num }}</span> <span>规格:{{ item.specifications }}</span>
</div> </div>
</div> </div>
<div class="rc-userbottom"> <div class="rc-userbottom">
<span>数量:{{ item.pcs }}</span> <span>数量:{{ item.pcs }}</span>
<i>10</i> <i>{{item.ecPrice}}</i>
</div> </div>
<div class="rc-userbottomm"> <div class="rc-userbottomm">
<i>{{ item.userprice }}</i> <i>{{ item.ecPrice }}</i>
<span>{{ item.orderstype }}</span> <span>{{ item.pcs }}</span>
<i>{{ item.userprice }}</i> <i>{{ item.salesAmount }}</i>
</div> </div>
</div> </div>
@ -322,6 +322,12 @@ export default {
this.useralllist[i].addressUserName = this.goldmedal[i].addressUserName; this.useralllist[i].addressUserName = this.goldmedal[i].addressUserName;
this.useralllist[i].phoneNumber = this.goldmedal[i].phoneNumber; this.useralllist[i].phoneNumber = this.goldmedal[i].phoneNumber;
this.useralllist[i].salesAmount = this.goldmedal[i].salesAmount; this.useralllist[i].salesAmount = this.goldmedal[i].salesAmount;
// this.useralllist[i].picFile = this.goldmedal[i].picFile; //
// this.useralllist[i].productName=this.goldmedal[i].productName;//
// this.useralllist[i].ecPrice=this.goldmedal[i].ecPrice//
// this.useralllist[i].pcs=this.goldmedal[i].pcs//
this.useralllist[i].lengthnum=this.goldmedal[i].orderDetailList.length this.useralllist[i].lengthnum=this.goldmedal[i].orderDetailList.length
} }
console.log(this.obligation) console.log(this.obligation)

View File

@ -0,0 +1,28 @@
//时间戳转化成格式时间
import Vue from 'vue';
Vue.prototype.formatConversion = function (te){
if(te == ''){
return '';
}else if(te.length == 10){
var time = new Date(te * 1000); //时间戳为10位需*1000时间戳为13位的话不需乘1000
var y = time.getFullYear();
var m = time.getMonth() < 9 ? '0' + (time.getMonth() + 1) : time.getMonth() + 1;
var d = time.getDate() < 10 ? '0' + time.getDate() : time.getDate();
var h = time.getHours() < 10 ? '0' + time.getHours() : time.getHours();
var mm = time.getMinutes() < 10 ? '0' + time.getMinutes() : time.getMinutes();
var s = time.getSeconds() < 10 ? '0' + time.getSeconds() : time.getSeconds();
var timedate = y + '-' + m + '-' + d + ' ' + h + ':' + mm + ':' + s;
return timedate;
}else{
var time = new Date(te);
var y = time.getFullYear();
var m = time.getMonth() < 9 ? '0' + (time.getMonth() + 1) : time.getMonth() + 1;
var d = time.getDate() < 10 ? '0' + time.getDate() : time.getDate();
var h = time.getHours() < 10 ? '0' + time.getHours() : time.getHours();
var mm = time.getMinutes() < 10 ? '0' + time.getMinutes() : time.getMinutes();
var s = time.getSeconds() < 10 ? '0' + time.getSeconds() : time.getSeconds();
var timedate = y + '-' + m + '-' + d + ' ' + h + ':' + mm + ':' + s;
return timedate;
}
}