新增预订商城项目
This commit is contained in:
211
pages/me/RealInfo.vue
Normal file
211
pages/me/RealInfo.vue
Normal file
@@ -0,0 +1,211 @@
|
||||
<template>
|
||||
|
||||
<view>
|
||||
|
||||
<NavBar ref="nav" navTitle="真实信息" :showIcon="true" :supportChange="false">
|
||||
</NavBar>
|
||||
|
||||
<loading-state ref="pageView" @request="request">
|
||||
|
||||
<view @click="remark()" class="menu-item">
|
||||
<text class="text">姓名</text>
|
||||
<text class="explain">{{page.realName}}</text>
|
||||
<image class="more" src="../../static/more.png"></image>
|
||||
</view>
|
||||
|
||||
<view class="line-thin"></view>
|
||||
|
||||
<view @click="clickSex()" class="menu-item">
|
||||
<text class="text">性别</text>
|
||||
<text class="explain">{{page.sex}}</text>
|
||||
<image class="more" src="../../static/more.png"></image>
|
||||
</view>
|
||||
|
||||
<view class="line-thin"></view>
|
||||
|
||||
<uni-datetime-picker style="flex: 1;margin-top: 1px;" type="date" :value="page.birthDay" :start="startDate"
|
||||
:end="endData" v-model="page.birthDay">
|
||||
<view class="menu-item">
|
||||
<text class="text">生日</text>
|
||||
<text class="explain">{{stringIsEmpty(page.birthDay) ?"请选择生日":page.birthDay}}</text>
|
||||
<image class="more" src="../../static/more.png"></image>
|
||||
</view>
|
||||
</uni-datetime-picker>
|
||||
|
||||
<view class="line-thin"></view>
|
||||
<pick-regions :defaultRegion="defaultRegionCode" @getRegion="handleGetRegion">
|
||||
<view class="menu-item">
|
||||
<text class="text">地区</text>
|
||||
<text class="explain">{{stringIsEmpty(page.regionName) ?"请选择地区":page.regionName}}</text>
|
||||
<image class="more" src="../../static/more.png"></image>
|
||||
</view>
|
||||
</pick-regions>
|
||||
|
||||
<view style="background: -webkit-linear-gradient(left,#61CB29,#60CA2C); position: absolute; bottom: 30px;
|
||||
width: 90%;border-radius: 100rpx;height: 80rpx;display: flex;margin-left: 5%;
|
||||
flex-direction: column;align-items: center;line-height: 80rpx;color: #FFFFFF;font-size: 36rpx;"
|
||||
@click="realInfoAttestation">
|
||||
保存</view>
|
||||
|
||||
</loading-state>
|
||||
|
||||
<uni-popup ref="inputDialog" type="dialog">
|
||||
<uni-popup-dialog ref="inputClose" mode="input" title="修改姓名" :value="page.realName" placeholder="请输入内容"
|
||||
@confirm="dialogInputConfirm"></uni-popup-dialog>
|
||||
</uni-popup>
|
||||
|
||||
</view>
|
||||
|
||||
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import pickRegions from '@/components/pick-regions/pick-regions.vue'
|
||||
export default {
|
||||
components: {
|
||||
pickRegions
|
||||
},
|
||||
created() {
|
||||
this.startDate = this.TimeFormat(this.CurrentMillions() - 100 * 365 * 24 * 60 * 60 * 1000);
|
||||
this.endData = this.TimeFormat(this.CurrentMillions());
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
region: [],
|
||||
defaultRegion: ['北京市', '市辖区', '东城区'],
|
||||
defaultRegionCode: '110101',
|
||||
region_sid_path: "",
|
||||
address_path: "北京市/市辖区/东城区",
|
||||
startDate: "1921-01-01",
|
||||
endData: "",
|
||||
pickerDate: "",
|
||||
page: {
|
||||
"birthDay": "",
|
||||
"realName": "",
|
||||
"regionCode": "",
|
||||
"regionName": "",
|
||||
"sex": ""
|
||||
},
|
||||
contorl: {
|
||||
listSex: ["男", "女"]
|
||||
},
|
||||
}
|
||||
},
|
||||
onLoad(options) {
|
||||
this.request()
|
||||
},
|
||||
methods: {
|
||||
// 修改姓名
|
||||
remark() {
|
||||
this.$refs.inputDialog.open()
|
||||
},
|
||||
dialogInputConfirm(val) {
|
||||
this.page.realName = val
|
||||
},
|
||||
request() {
|
||||
let _this = this
|
||||
_this.$api.getRealInfo(getApp().globalData.sid).then((resp) => {
|
||||
console.log(JSON.stringify(resp));
|
||||
_this.page = resp
|
||||
_this.$nextTick(() => {
|
||||
_this.$refs.pageView.setLoadState(2)
|
||||
})
|
||||
}).catch(e => {
|
||||
_this.$nextTick(() => {
|
||||
_this.$refs.pageView.setLoadState(1)
|
||||
})
|
||||
})
|
||||
},
|
||||
clickSex() {
|
||||
let _this = this;
|
||||
uni.showActionSheet({
|
||||
itemList: this.contorl.listSex,
|
||||
success: function(res) {
|
||||
_this.selectSex(res.tapIndex + 1)
|
||||
}
|
||||
});
|
||||
},
|
||||
selectSex(id) {
|
||||
let _this = this
|
||||
switch (id) {
|
||||
case 1:
|
||||
this.page.sex = '男'
|
||||
break;
|
||||
case 2:
|
||||
this.page.sex = '女'
|
||||
break;
|
||||
case 3:
|
||||
break
|
||||
}
|
||||
},
|
||||
modibirthDay(e) {
|
||||
this.page.birthDay = e
|
||||
},
|
||||
realInfoAttestation() {
|
||||
this.page.userSid = getApp().globalData.sid
|
||||
let _this = this
|
||||
_this.$api.saveRealInfo(this.page).then((resp) => {
|
||||
uni.$emit("real-info")
|
||||
uni.navigateBack()
|
||||
}).catch(e => {
|
||||
console.log(e);
|
||||
})
|
||||
},
|
||||
// 获取选择的地区
|
||||
handleGetRegion(region) {
|
||||
let code = region.map(item => item.code)
|
||||
let name = region.map(item => item.name)
|
||||
this.page.regionCode = code[2]
|
||||
this.page.regionName = name[0] + "/" + name[1] + "/" + name[2]
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
page {
|
||||
background-color: #f1f2f3;
|
||||
}
|
||||
|
||||
|
||||
.menu-item {
|
||||
height: 112rpx;
|
||||
width: auto;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
background-color: #fff;
|
||||
align-items: center;
|
||||
padding-left: 36rpx;
|
||||
padding-right: 36rpx;
|
||||
}
|
||||
|
||||
.more {
|
||||
width: 35rpx;
|
||||
height: 35rpx;
|
||||
float: right;
|
||||
}
|
||||
|
||||
.menu-item .icon {
|
||||
width: 69rpx;
|
||||
height: 35rpx;
|
||||
}
|
||||
|
||||
.menu-item .text {
|
||||
font-size: 32rpx;
|
||||
color: #101010;
|
||||
flex: 1;
|
||||
float: left;
|
||||
}
|
||||
|
||||
.menu-item .explain {
|
||||
font-size: 28rpx;
|
||||
color: #828282;
|
||||
margin-right: 10rpx;
|
||||
}
|
||||
|
||||
.line-thin {
|
||||
height: 1rpx;
|
||||
width: 100%;
|
||||
background-color: #eee;
|
||||
}
|
||||
</style>
|
||||
338
pages/me/addInvoice.vue
Normal file
338
pages/me/addInvoice.vue
Normal file
@@ -0,0 +1,338 @@
|
||||
<template>
|
||||
<view class="page">
|
||||
|
||||
<view style="height: 80vh;overflow: hidden;overflow-y: auto;padding: 12px;">
|
||||
|
||||
<view class="top">
|
||||
|
||||
<view class="top-item">
|
||||
|
||||
<text class="item-text">发票类型</text>
|
||||
|
||||
<radio-group @change="radioChange">
|
||||
<radio style="transform:scale(0.8);font-size: 20px;" color="#61CB29" value="普通发票"
|
||||
:checked="info.invoiceType=='普通发票'">普通发票</radio>
|
||||
<radio style="transform:scale(0.8);font-size: 20px;" color="#61CB29" value="增值税发票"
|
||||
:checked="info.invoiceType=='增值税发票'">增值税发票</radio>
|
||||
</radio-group>
|
||||
</view>
|
||||
|
||||
<view class="top-item" style="margin-top: 24px;">
|
||||
|
||||
<text class="item-text">抬头类型</text>
|
||||
|
||||
<radio-group @change="radioChange2">
|
||||
<radio style="transform:scale(0.8);font-size: 20px;" color="#61CB29" value="个人或事业单位"
|
||||
:checked="info.headingType=='个人或事业单位'">个人或事业单位
|
||||
</radio>
|
||||
<radio style="transform:scale(0.8);font-size: 20px;" color="#61CB29" value="企业"
|
||||
:checked="info.headingType=='企业'">企业</radio>
|
||||
</radio-group>
|
||||
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
<view class="bom">
|
||||
|
||||
<view class="bom-item">
|
||||
|
||||
<text class="item-text">发票抬头</text>
|
||||
|
||||
<view class="item-right">
|
||||
<view style="width: 100%;margin-left: 20px;padding-left: 5px;">
|
||||
<input class="input" type="text" placeholder="填写抬头名称" v-model="info.invoiceHeader" />
|
||||
</view>
|
||||
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="bom-item" style="margin-top: 12px;">
|
||||
|
||||
<text class="item-text">电子邮箱</text>
|
||||
|
||||
<view class="item-right" style="width: 100%;margin-left: 20px;padding-left: 5px;">
|
||||
<input class="input" type="text" placeholder="选填" v-model="info.email" />
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
|
||||
<view v-if="isPerson">
|
||||
<view style="display: flex;flex-direction: column;" v-if="showDetail">
|
||||
|
||||
<view class="bom-item" style="margin-top: 12px;">
|
||||
|
||||
<text class="item-text">税号</text>
|
||||
|
||||
<view class="item-right" style="width: 100%;margin-left: 20px;padding-left: 5px;">
|
||||
<input class="input" type="text" placeholder="纳税人识别号或社会统一征信代码"
|
||||
v-model="info.dutyParagraph" />
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="bom-item" style="margin-top: 12px;">
|
||||
|
||||
<text class="item-text">开户银行</text>
|
||||
|
||||
<view class="item-right" style="width: 100%;margin-left: 20px;padding-left: 5px;">
|
||||
<input class="input" type="text" placeholder="选填" v-model="info.bankOfDeposit" />
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
<view class="bom-item" style="margin-top: 12px;">
|
||||
|
||||
<text class="item-text">银行账号</text>
|
||||
|
||||
<view class="item-right" style="width: 100%;margin-left: 20px;padding-left: 5px;">
|
||||
<input class="input" type="text" placeholder="选填" v-model="info.bankAccount" />
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
<view class="bom-item" style="margin-top: 12px;">
|
||||
|
||||
<text class="item-text">企业地址</text>
|
||||
|
||||
<view class="item-right" style="width: 100%;margin-left: 20px;padding-left: 5px;">
|
||||
<input class="input" type="text" placeholder="选填" v-model="info.enterpriseAddress" />
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
<view class="bom-item" style="margin-top: 12px;">
|
||||
|
||||
<text class="item-text">企业电话</text>
|
||||
|
||||
<view class="item-right" style="width: 100%;margin-left: 20px;padding-left: 5px;">
|
||||
<input class="input" type="text" placeholder="选填" v-model="info.enterprisePhone" />
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
</view>
|
||||
|
||||
<view class="item_btn" v-if="!showDetail" @click="showDetailClick(item)">
|
||||
<text style="font-size: 12px;color: #999; margin-right: 5px;">展开</text>
|
||||
<image src="../../static/zhankai.png" style="width: 15px;height: 15px;"></image>
|
||||
</view>
|
||||
|
||||
<view class="item_btn" v-if="showDetail" @click="showDetailClick(item)">
|
||||
<text style="font-size: 12px;color: #999; margin-right: 5px;">收起</text>
|
||||
<image src="../../static/shouqi.png" style="width: 15px;height: 15px;"></image>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
<view class="default">
|
||||
|
||||
<text class="item-text">设为默认</text>
|
||||
|
||||
<radio :checked="radioDefault" @click="radioDefaultClick" style="transform:scale(0.8);" color="#61CB29">
|
||||
</radio>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
<view style="position: absolute; bottom: 20px; display: flex;flex-direction: column;width: 100%;
|
||||
box-sizing: border-box;padding-left: 40px;padding-right: 40px; ">
|
||||
<view style="background: -webkit-linear-gradient(left,#61CB29,#60CA2C);
|
||||
width: 100%;border-radius: 25px;height: 50px;text-align: center;
|
||||
line-height: 50px;color: #FFFFFF;font-size: 16px;" @click="save">
|
||||
完成</view>
|
||||
</view>
|
||||
|
||||
|
||||
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
//引入bus
|
||||
import bus from '@/common/bus';
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
isPerson: true,
|
||||
showDetail: false,
|
||||
radioDefault: false,
|
||||
info: {
|
||||
sid: "",
|
||||
invoiceType: "", //发票类型
|
||||
headingType: "", //抬头类型
|
||||
invoiceHeader: "", //发票抬头
|
||||
dutyParagraph: "", //税号
|
||||
bankOfDeposit: "", //开户行
|
||||
bankAccount: "", //账号
|
||||
enterpriseAddress: "", //企业地址
|
||||
enterprisePhone: "", //企业电话
|
||||
isDefault: "0", //是否默认 1 为默认
|
||||
customerSid: getApp().globalData.sid,
|
||||
}
|
||||
}
|
||||
},
|
||||
onLoad(options) {
|
||||
console.log("options", options);
|
||||
|
||||
if (JSON.stringify(options) != '{}') {
|
||||
let userInfo = JSON.parse(decodeURIComponent(options.info));
|
||||
console.log('userInfo', userInfo);
|
||||
this.info = userInfo
|
||||
this.radioDefault = this.info.isDefault == '1'
|
||||
this.isPerson = this.info.headingType != '个人或事业单位'
|
||||
}
|
||||
|
||||
|
||||
},
|
||||
methods: {
|
||||
|
||||
radioChange(val) {
|
||||
console.log("radioChange", val);
|
||||
this.info.invoiceType = val.detail.value
|
||||
},
|
||||
radioChange2(val) {
|
||||
console.log("radioChange2", val);
|
||||
|
||||
this.info.headingType = val.detail.value
|
||||
|
||||
this.isPerson = val.detail.value != "个人或事业单位"
|
||||
|
||||
|
||||
},
|
||||
showDetailClick() {
|
||||
this.showDetail = !this.showDetail
|
||||
},
|
||||
radioDefaultClick() {
|
||||
this.radioDefault = !this.radioDefault
|
||||
|
||||
this.info.isDefault = this.radioDefault ? "1" : "0"
|
||||
|
||||
},
|
||||
save() {
|
||||
|
||||
console.log("save", this.info);
|
||||
|
||||
if (this.stringIsEmpty(this.info.invoiceType)) {
|
||||
this.shortToast('请选择发票类型')
|
||||
return
|
||||
}
|
||||
if (this.stringIsEmpty(this.info.headingType)) {
|
||||
this.shortToast('请选择抬头类型')
|
||||
return
|
||||
}
|
||||
if (this.stringIsEmpty(this.info.invoiceHeader)) {
|
||||
this.shortToast('发票抬头不能为空')
|
||||
return
|
||||
}
|
||||
|
||||
if (this.isPerson) {
|
||||
if (this.stringIsEmpty(this.info.dutyParagraph)) {
|
||||
this.shortToast('税号不能为空')
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
this.$api.saveOrUpdateInvoice(this.info).then((resp) => {
|
||||
this.info.sid = resp
|
||||
bus.$emit('invoice', this.info);
|
||||
uni.navigateBack()
|
||||
}).catch(e => {
|
||||
|
||||
})
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.page {
|
||||
background: #F7F7F7;
|
||||
height: 100vh;
|
||||
|
||||
.top {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
background: #fff;
|
||||
border-radius: 10px;
|
||||
padding: 16px 12px;
|
||||
|
||||
.top-item {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
|
||||
.item-text {
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
.item-right {
|
||||
flex: 1;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
.bom {
|
||||
margin-top: 12px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
background: #fff;
|
||||
border-radius: 10px;
|
||||
padding: 16px 12px;
|
||||
|
||||
.bom-item {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
|
||||
.item-text {
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
.item-right {
|
||||
flex: 1;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
justify-content: flex-end;
|
||||
|
||||
.input {
|
||||
width: 100%;
|
||||
text-align: right;
|
||||
pointer-events: auto;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.item_btn {
|
||||
margin-top: 10px;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
width: 100%;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
.default {
|
||||
margin-top: 12px;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
background: #fff;
|
||||
border-radius: 10px;
|
||||
padding: 16px 12px;
|
||||
|
||||
}
|
||||
}
|
||||
</style>
|
||||
200
pages/me/applyRefund.vue
Normal file
200
pages/me/applyRefund.vue
Normal file
@@ -0,0 +1,200 @@
|
||||
<template>
|
||||
|
||||
<view style="display: flex;flex-direction: column;height: 100vh; background: #F7F7F7;">
|
||||
<loading-state ref="pageView" @request="request">
|
||||
<view style="height: 100vh;overflow: hidden;overflow-y: auto;">
|
||||
<view
|
||||
style="background: #fff;border-radius: 10px;display: flex;flex-direction: column;padding: 15px;margin-top: 15px; margin-left: 10px;margin-right: 10px;">
|
||||
|
||||
<text style="font-size: 18px;font-weight: 600;font-family: serif;margin-bottom: 10px;">退款商品</text>
|
||||
|
||||
<view v-for="(item,index) in data.ordOrderDetails"
|
||||
style=" display: flex;flex-direction: row;align-items: center; margin-bottom: 10px;">
|
||||
|
||||
<image :src="item.picUrl" @click="itemClick(item.goodsSid)"
|
||||
style="width: 70px;height: 70px;border-radius: 15px;" mode="scaleToFill">
|
||||
</image>
|
||||
|
||||
<view style="margin-left: 10px;display: flex;flex-direction: column;flex: 1;">
|
||||
|
||||
<view style="display: flex;flex-direction: row;width: 100%;">
|
||||
|
||||
<text style="flex: 1;font-weight: 600;font-family: sans-serif;font-size: 14px;"
|
||||
@click="itemClick(item.goodsSid)">{{item.goodsName}}</text>
|
||||
<text
|
||||
style="font-weight: 600;font-family: sans-serif;font-size: 14px;">¥{{item.priceUnit}}</text>
|
||||
</view>
|
||||
|
||||
<!-- <text style="margin-top: 10px;font-size: 12px;color: #999;">{{item.remarks}}</text> -->
|
||||
|
||||
<view style="margin-top: 8px;display: flex;flex-direction: column;">
|
||||
|
||||
<view style="display: flex;flex-direction: row;align-items: center;">
|
||||
<!-- <text style="border: 1px #EE752F solid; border-radius: 5px; padding: 0px 8px;
|
||||
font-size: 10px;color: #EE752F;">{{item.priceUnit}}元/{{item.specificationUnit}}</text> -->
|
||||
<text
|
||||
style="border: 1px #EE752F solid; border-radius: 5px; padding: 0px 8px;
|
||||
font-size: 10px;color: #EE752F; argin-right: 10px; ">{{item.numofPart}}{{item.specificationUnit}}/{{item.unitName}}</text>
|
||||
</view>
|
||||
|
||||
<text
|
||||
style="margin-top: 12px;font-size: 12px;color: #999;">份数:{{item.partNumber}}</text>
|
||||
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
<view style="background: #fff;border-radius: 10px;margin-top: 12px;margin-left: 10px;margin-right: 10px;
|
||||
display: flex;flex-direction: column;padding: 12px 16px;">
|
||||
|
||||
<text style="font-size: 16px;">订单信息</text>
|
||||
|
||||
<view style="display: flex;flex-direction: column;margin-top: 15px; ">
|
||||
|
||||
<view style="display: flex;flex-direction: row;align-items: center;">
|
||||
|
||||
<text style="font-size: 14px;color: #999;">订单编号</text>
|
||||
<text
|
||||
style="margin-left: 15px;font-size: 14px;color: #333;word-break: break-all;">{{data.outTradeNo}}</text>
|
||||
</view>
|
||||
|
||||
<view style="display: flex;flex-direction: row;align-items: center;margin-top: 8px;">
|
||||
|
||||
<text style="font-size: 14px;color: #999;">下单时间</text>
|
||||
<text style="margin-left: 15px;font-size: 14px;color: #333;">{{data.createTime}}</text>
|
||||
</view>
|
||||
|
||||
<view style="display: flex;flex-direction: row;align-items: center;margin-top: 8px;">
|
||||
|
||||
<text style="font-size: 14px;color: #999;">支付方式</text>
|
||||
<text style="margin-left: 15px;font-size: 14px;color: #333;">{{data.payType}}</text>
|
||||
</view>
|
||||
|
||||
<view style="display: flex;flex-direction: row;align-items: center;margin-top: 8px;"
|
||||
v-if="data.payStatus=='4'">
|
||||
|
||||
<text style="font-size: 14px;color: #999;">付款时间</text>
|
||||
<text style="margin-left: 15px;font-size: 14px;color: #333;">{{data.payTime}}</text>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
<view style="background: #fff;border-radius: 10px;margin-top: 12px;margin-left: 10px;margin-right: 10px;
|
||||
display: flex;flex-direction: column;padding: 12px 16px;margin-bottom: 100px; box-sizing: border-box;">
|
||||
|
||||
<view style="display: flex;flex-direction: row; align-items: center;">
|
||||
<text style="font-size: 16px;font-weight: 600;font-family: serif;">退款原因</text>
|
||||
<text style="font-size: 16px;color: #FF9900;margin-left: 5px;">(必填)</text>
|
||||
|
||||
</view>
|
||||
|
||||
<textarea type="text" v-model="reason" placeholder="补充详细退款原因,有利于商家更快的帮您处理。"
|
||||
style="margin-top: 12px; box-sizing: border-box; width: 100%; background: #FAFAFA;color: #999;font-size: 16px;min-height: 150px; padding: 12px 16px;" />
|
||||
|
||||
</view>
|
||||
|
||||
</view>
|
||||
</loading-state>
|
||||
|
||||
<view
|
||||
style="position: absolute; bottom: 0px; display: flex;flex-direction: row;width: 100%;align-items: center;
|
||||
box-sizing: border-box; padding-left: 16px;padding-right: 16px;background: #fff; height: 8vh;border-top: 1px solid #EFEFEF;">
|
||||
|
||||
<view style="display: flex;flex-direction: row;align-items: center;flex: 1; margin-right: 20px;">
|
||||
<view style="flex: 1;"></view>
|
||||
<text style="font-size: 14px;">退款金额:</text>
|
||||
<text style="font-size: 18px;color: #FF5006;">¥{{data.totalTee}}</text>
|
||||
|
||||
</view>
|
||||
<text style="font-size: 16px;color: #fff; background-color: #FF9900; height: 5vh;line-height: 5vh;
|
||||
padding: 0px 20px;border-radius: 20px;" @click="submitApply">提交申请</text>
|
||||
|
||||
</view>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</view>
|
||||
|
||||
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
page: {
|
||||
sid: ""
|
||||
},
|
||||
data: {},
|
||||
reason: ""
|
||||
}
|
||||
},
|
||||
onLoad(options) {
|
||||
this.page.sid = options.sid
|
||||
this.request()
|
||||
},
|
||||
methods: {
|
||||
|
||||
// 获取数据
|
||||
request() {
|
||||
|
||||
let _this = this
|
||||
|
||||
_this.$api.orderDetails(_this.page.sid).then((resp) => {
|
||||
_this.data = resp
|
||||
_this.$nextTick(() => {
|
||||
_this.$refs.pageView.setLoadState(2)
|
||||
})
|
||||
|
||||
}).catch(e => {
|
||||
_this.$nextTick(() => {
|
||||
_this.$refs.pageView.setLoadState(1)
|
||||
})
|
||||
})
|
||||
},
|
||||
itemClick(goodsSid) {
|
||||
uni.navigateTo({
|
||||
url: '/pages/good/goodsDetail2?sid=' + goodsSid
|
||||
})
|
||||
},
|
||||
|
||||
submitApply() {
|
||||
let _this = this
|
||||
if (this.stringIsEmpty(this.reason)) {
|
||||
this.shortToast('请填写退款原图')
|
||||
return
|
||||
}
|
||||
|
||||
var params = {
|
||||
sid: this.page.sid,
|
||||
reason: this.reason,
|
||||
customerSid: getApp().globalData.sid
|
||||
}
|
||||
console.log("submitApply", params);
|
||||
|
||||
_this.$api.orderRetrun(params).then((resp) => {
|
||||
|
||||
uni.redirectTo({
|
||||
url: '/pages/me/refundDetail?sid=' + _this.page.sid
|
||||
})
|
||||
}).catch(e => {
|
||||
|
||||
})
|
||||
|
||||
},
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
</style>
|
||||
95
pages/me/authentication.vue
Normal file
95
pages/me/authentication.vue
Normal file
@@ -0,0 +1,95 @@
|
||||
<template>
|
||||
<view style="display: flex;flex-direction: column;width: 100%;height: 100vh;background: #FEA75E;">
|
||||
|
||||
<NavBar ref="nav" navTitle="企业认证" :showIcon="true" :supportChange="false">
|
||||
</NavBar>
|
||||
|
||||
<!-- <loading-state ref="pageView" @request="request"> -->
|
||||
|
||||
<view style="width: 100%;height: 100vh;background: #F7F7F7; border-radius: 20px;display: flex;flex-direction: column;
|
||||
padding-left: 16px;padding-right: 16px;padding-top: 8px;box-sizing: border-box;">
|
||||
|
||||
<text class="text">企业名称</text>
|
||||
<input placeholder="请输入" class="input" v-model="authenticationInfo.enterpriseName" />
|
||||
|
||||
<text class="text">配送地址</text>
|
||||
<input placeholder="请输入" class="input" v-model="authenticationInfo.shippingAddress" />
|
||||
|
||||
<text class="text">联系人</text>
|
||||
<input placeholder="请输入" class="input" v-model="authenticationInfo.contacts" />
|
||||
|
||||
<text class="text">联系电话</text>
|
||||
<input placeholder="请输入" class="input" v-model="authenticationInfo.telephone" />
|
||||
|
||||
|
||||
<!-- <text style="position: absolute; bottom: 24px; display: flex;flex-direction: column;width: 100%;text-align: center;
|
||||
|
||||
box-sizing: border-box;color: #fff;background: #FF9900; border-radius: 25px; line-height: 40px;height: 40px;">确认</text> -->
|
||||
|
||||
|
||||
|
||||
</view>
|
||||
|
||||
<view style="position: absolute; bottom: 24px; display: flex;flex-direction: column;width: 100%;
|
||||
box-sizing: border-box; padding-left: 16px;padding-right: 16px;">
|
||||
|
||||
<view style="background: -webkit-linear-gradient(left,#FFB176,#FE923B);
|
||||
width: 100%;border-radius: 25px;height: 50px;text-align: center;
|
||||
line-height: 50px;color: #FFFFFF;font-size: 16px;" @click="save">
|
||||
确认</view>
|
||||
</view>
|
||||
<!-- </loading-state> -->
|
||||
|
||||
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
authenticationInfo:{
|
||||
customerSid:getApp().globalData.sid,
|
||||
enterpriseName:"",
|
||||
shippingAddress:"",
|
||||
contacts:"",
|
||||
telephone:"",
|
||||
|
||||
},
|
||||
|
||||
}
|
||||
},
|
||||
|
||||
methods: {
|
||||
// 获取数据
|
||||
save() {
|
||||
|
||||
this.$api.saveAuthentication(this.authenticationInfo).then((resp) => {
|
||||
uni.navigateBack()
|
||||
}).catch(e => {
|
||||
|
||||
})
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
|
||||
.text{
|
||||
font-size: 16px;
|
||||
color: #101010;
|
||||
margin-top: 17px;
|
||||
font-weight: 600;
|
||||
font-family: sans-serif;
|
||||
}
|
||||
.input{
|
||||
margin-top: 12px;
|
||||
border: 1px #999999 solid;
|
||||
border-radius: 6px;
|
||||
font-size: 14px;
|
||||
height: 40px;
|
||||
line-height: 40px;
|
||||
padding-left: 10px;
|
||||
}
|
||||
</style>
|
||||
269
pages/me/base_info.vue
Normal file
269
pages/me/base_info.vue
Normal file
@@ -0,0 +1,269 @@
|
||||
<template>
|
||||
|
||||
<view style="display: flex;flex-direction: column;">
|
||||
|
||||
<NavBar ref="nav" navTitle="个人信息" :showIcon="true" :supportChange="false">
|
||||
</NavBar>
|
||||
|
||||
<loading-state ref="pageView" @request="request">
|
||||
|
||||
<view @click="uploadHeadImage()" class="menu-item">
|
||||
<text class="text">头像</text>
|
||||
<image :src="page.photo" style="width: 70rpx;height: 70rpx;margin-right: 10rpx;"></image>
|
||||
<image class="more" src="../../static/more.png"></image>
|
||||
</view>
|
||||
<view class="line-thin"></view>
|
||||
<view @click="remark()" class="menu-item">
|
||||
<text class="text">昵称</text>
|
||||
<text class="explain">{{page.nick}}</text>
|
||||
<image class="more" src="../../static/more.png"></image>
|
||||
</view>
|
||||
<view class="line-thin"></view>
|
||||
<view class="menu-item">
|
||||
<text class="text">手机号</text>
|
||||
<text class="explain"></text>
|
||||
<button open-type="getPhoneNumber" @getphonenumber="getPhoneNumber">{{page.phone}}</button>
|
||||
<image class="more" src="../../static/more.png"></image>
|
||||
</view>
|
||||
|
||||
<view class="line-thin"></view>
|
||||
<view @click="toRealInfo()" class="menu-item">
|
||||
<text class="text">实名信息</text>
|
||||
<text class="explain">{{page.realAttestationExplain}}</text>
|
||||
<image class="more" src="../../static/more.png"></image>
|
||||
</view>
|
||||
|
||||
<!-- <view class="line-thin"></view>
|
||||
<view @click="bank()" class="menu-item">
|
||||
<text class="text">推荐支行</text>
|
||||
|
||||
<zqs-select class="explain2" :multiple="false" :list="options" label-key="bankName" value-key="bankSid"
|
||||
title="选择支行" clearable v-model="page.customerBankName" placeholder=" 请选择支行" @search="searchEvent"
|
||||
@change="selectChange2"></zqs-select>
|
||||
|
||||
</view> -->
|
||||
|
||||
</loading-state>
|
||||
|
||||
<uni-popup ref="inputDialog" type="dialog">
|
||||
<uni-popup-dialog ref="inputClose" mode="input" title="修改昵称" :value="page.nick" placeholder="请输入内容"
|
||||
@confirm="dialogInputConfirm"></uni-popup-dialog>
|
||||
</uni-popup>
|
||||
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
options: [{
|
||||
label: '沃尔玛(WALMART)',
|
||||
value: '0',
|
||||
},
|
||||
{
|
||||
label: '国家电网有限公司(STATE GRID)',
|
||||
value: '1',
|
||||
},
|
||||
{
|
||||
label: '中国石油天然气集团有限公司',
|
||||
value: '2',
|
||||
},
|
||||
{
|
||||
label: '苹果公司(APPLE)',
|
||||
value: '3',
|
||||
},
|
||||
{
|
||||
label: 'CVSHealth公司(CVS HEALTH)',
|
||||
value: '4',
|
||||
},
|
||||
{
|
||||
label: '联合健康集团(UNITEDHEALTH GROUP)',
|
||||
value: '5',
|
||||
},
|
||||
{
|
||||
label: '丰田汽车公司(TOYOTA MOTOR)',
|
||||
value: '6',
|
||||
}
|
||||
],
|
||||
page: {}
|
||||
}
|
||||
},
|
||||
onLoad(options) {
|
||||
this.request()
|
||||
uni.$on("real-info", (e) => {
|
||||
this.$nextTick(() => {
|
||||
this.$refs.pageView.setLoadState(0)
|
||||
})
|
||||
this.request();
|
||||
})
|
||||
},
|
||||
onUnload() {
|
||||
uni.$off('real-info');
|
||||
},
|
||||
methods: {
|
||||
// 获取数据
|
||||
request() {
|
||||
let _this = this
|
||||
_this.$api.getBaseInfo(getApp().globalData.sid).then((resp) => {
|
||||
_this.page = resp
|
||||
_this.$nextTick(() => {
|
||||
_this.$refs.pageView.setLoadState(2)
|
||||
_this.options = resp.customerBankList
|
||||
})
|
||||
|
||||
}).catch(e => {
|
||||
_this.$nextTick(() => {
|
||||
_this.$refs.pageView.setLoadState(1)
|
||||
})
|
||||
})
|
||||
},
|
||||
uploadHeadImage() {
|
||||
let _this = this
|
||||
uni.chooseImage({
|
||||
success: (chooseImageRes) => {
|
||||
const tempFilePaths = chooseImageRes.tempFilePaths;
|
||||
uni.uploadFile({
|
||||
url: _this.$api.headerUpload,
|
||||
filePath: tempFilePaths[0],
|
||||
name: 'file',
|
||||
formData: {
|
||||
'userSid': getApp().globalData.sid
|
||||
},
|
||||
success: (uploadFileRes) => {
|
||||
_this.page.photo = JSON.parse(uploadFileRes.data).data;
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
// 修改昵称
|
||||
remark() {
|
||||
this.$refs.inputDialog.open()
|
||||
},
|
||||
dialogInputConfirm(val) {
|
||||
let _this = this
|
||||
_this.$api.changeNick({
|
||||
userSid: getApp().globalData.sid,
|
||||
userNickName: val
|
||||
}).then((resp) => {
|
||||
_this.page.nick = val
|
||||
}).catch(e => {
|
||||
console.log(e);
|
||||
})
|
||||
},
|
||||
getPhoneNumber(e) {
|
||||
let _this = this
|
||||
console.log(e.detail.code)
|
||||
_this.$api.getPhone({
|
||||
userSid: getApp().globalData.sid,
|
||||
code: e.detail.code
|
||||
}).then((resp) => {
|
||||
_this.page.phone = resp
|
||||
}).catch(e => {
|
||||
console.log(e);
|
||||
})
|
||||
},
|
||||
toRealInfo() {
|
||||
uni.navigateTo({
|
||||
url: '/pages/me/RealInfo'
|
||||
})
|
||||
},
|
||||
bank() {},
|
||||
selectChange2(e) {
|
||||
// 此处为点击的事件
|
||||
let param = {
|
||||
userSid: getApp().globalData.sid,
|
||||
customerBankSid: e.bankSid
|
||||
}
|
||||
let _this = this
|
||||
_this.$api.saveTuiJianZhiHang(param).then((resp) => {
|
||||
_this.request()
|
||||
}).catch(e => {
|
||||
_this.request()
|
||||
})
|
||||
},
|
||||
searchEvent(val) {
|
||||
let _this = this
|
||||
_this.$api.searchTuiJianZhiHang({
|
||||
name: val
|
||||
}).then((resp) => {
|
||||
_this.options = resp
|
||||
}).catch(e => {
|
||||
console.log("===", e);
|
||||
})
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
button {
|
||||
color: #828282;
|
||||
background-color: #fff;
|
||||
font-size: 28rpx;
|
||||
padding-right: 10rpx;
|
||||
}
|
||||
|
||||
|
||||
button::after {
|
||||
border: 0;
|
||||
}
|
||||
|
||||
// 修改点击时的样式
|
||||
.button-hover {
|
||||
color: #F85959;
|
||||
background-color: #fff;
|
||||
}
|
||||
|
||||
page {
|
||||
background-color: #f1f2f3;
|
||||
}
|
||||
|
||||
|
||||
.menu-item {
|
||||
height: 112rpx;
|
||||
width: auto;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
background-color: #fff;
|
||||
align-items: center;
|
||||
padding-left: 36rpx;
|
||||
padding-right: 36rpx;
|
||||
}
|
||||
|
||||
.more {
|
||||
width: 35rpx;
|
||||
height: 35rpx;
|
||||
float: right;
|
||||
}
|
||||
|
||||
.menu-item .icon {
|
||||
width: 69rpx;
|
||||
height: 35rpx;
|
||||
}
|
||||
|
||||
.menu-item .text {
|
||||
font-size: 32rpx;
|
||||
color: #101010;
|
||||
flex: 1;
|
||||
float: left;
|
||||
}
|
||||
|
||||
.menu-item .explain {
|
||||
font-size: 28rpx;
|
||||
color: #828282;
|
||||
margin-right: 10rpx;
|
||||
}
|
||||
|
||||
.menu-item .explain2 {
|
||||
font-size: 28rpx;
|
||||
color: #828282;
|
||||
}
|
||||
|
||||
.line-thin {
|
||||
height: 1rpx;
|
||||
width: 100%;
|
||||
background-color: #eee;
|
||||
}
|
||||
</style>
|
||||
486
pages/me/makeInvoice.vue
Normal file
486
pages/me/makeInvoice.vue
Normal file
@@ -0,0 +1,486 @@
|
||||
<template>
|
||||
<view class="page">
|
||||
|
||||
<view style="height: 80vh;overflow: hidden;overflow-y: auto;padding: 12px;">
|
||||
|
||||
<view class="top">
|
||||
|
||||
<view class="top-item" style="margin-top: 0px;">
|
||||
|
||||
<text class="item-text">发票类型</text>
|
||||
|
||||
<radio-group @change="radioChange">
|
||||
<radio style="transform:scale(0.8);font-size: 20px;" color="#61CB29" value="普通发票"
|
||||
:checked="info.invoiceType=='普通发票'">普通发票</radio>
|
||||
<radio style="transform:scale(0.8);font-size: 20px;" color="#61CB29" value="增值税发票"
|
||||
:checked="info.invoiceType=='增值税发票'">增值税发票</radio>
|
||||
</radio-group>
|
||||
</view>
|
||||
|
||||
<view class="top-item">
|
||||
|
||||
<text class="item-text">抬头类型</text>
|
||||
|
||||
<radio-group @change="radioChange2">
|
||||
<radio style="transform:scale(0.8);font-size: 20px;" color="#61CB29" value="个人或事业单位"
|
||||
:checked="info.headingType=='个人或事业单位'">个人或事业单位
|
||||
</radio>
|
||||
<radio style="transform:scale(0.8);font-size: 20px;" color="#61CB29" value="企业"
|
||||
:checked="info.headingType=='企业'">企业</radio>
|
||||
</radio-group>
|
||||
|
||||
</view>
|
||||
|
||||
<view class="top-item">
|
||||
|
||||
<text class="item-text">发票抬头</text>
|
||||
|
||||
<view class="item-right">
|
||||
<view style="width: 100%;margin-left: 20px;padding-left: 5px;">
|
||||
<input class="input" type="text" placeholder="填写抬头名称" v-model="info.invoiceHeader" />
|
||||
</view>
|
||||
<image src="../../static/more.png" style="width: 15px;height: 15px;margin-left: 5px;"
|
||||
@click="showList"></image>
|
||||
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="top-item">
|
||||
|
||||
<text class="item-text">电子邮箱</text>
|
||||
|
||||
<view class="item-right" style="width: 100%;margin-left: 20px;padding-left: 5px;">
|
||||
<input class="input" type="text" placeholder="选填" v-model="info.email" />
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view v-if="isPerson">
|
||||
<view style="display: flex;flex-direction: column;" v-if="showDetail">
|
||||
|
||||
<view class="top-item">
|
||||
|
||||
<text class="item-text">税号</text>
|
||||
|
||||
<view class="item-right" style="width: 100%;margin-left: 20px;padding-left: 5px;">
|
||||
<input class="input" type="text" placeholder="纳税人识别号或社会统一征信代码"
|
||||
v-model="info.dutyParagraph" />
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="top-item">
|
||||
|
||||
<text class="item-text">开户银行</text>
|
||||
|
||||
<view class="item-right" style="width: 100%;margin-left: 20px;padding-left: 5px;">
|
||||
<input class="input" type="text" placeholder="选填" v-model="info.bankOfDeposit" />
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
<view class="top-item">
|
||||
|
||||
<text class="item-text">银行账号</text>
|
||||
|
||||
<view class="item-right" style="width: 100%;margin-left: 20px;padding-left: 5px;">
|
||||
<input class="input" type="text" placeholder="选填" v-model="info.bankAccount" />
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
<view class="top-item">
|
||||
|
||||
<text class="item-text">企业地址</text>
|
||||
|
||||
<view class="item-right" style="width: 100%;margin-left: 20px;padding-left: 5px;">
|
||||
<input class="input" type="text" placeholder="选填" v-model="info.enterpriseAddress" />
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
<view class="top-item">
|
||||
|
||||
<text class="item-text">企业电话</text>
|
||||
|
||||
<view class="item-right" style="width: 100%;margin-left: 20px;padding-left: 5px;">
|
||||
<input class="input" type="text" placeholder="选填" v-model="info.enterprisePhone" />
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
<view class="item_btn" v-if="!showDetail" @click="showDetailClick(item)">
|
||||
<text style="font-size: 12px;color: #999; margin-right: 5px;">展开</text>
|
||||
<image src="../../static/zhankai.png" style="width: 15px;height: 15px;"></image>
|
||||
</view>
|
||||
|
||||
<view class="item_btn" v-if="showDetail" @click="showDetailClick(item)">
|
||||
<text style="font-size: 12px;color: #999; margin-right: 5px;">收起</text>
|
||||
<image src="../../static/shouqi.png" style="width: 15px;height: 15px;"></image>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
</view>
|
||||
<view style="position: absolute; bottom: 20px; display: flex;flex-direction: column;width: 100%;
|
||||
box-sizing: border-box;padding-left: 40px;padding-right: 40px; ">
|
||||
<view style="background: -webkit-linear-gradient(left,#61CB29,#60CA2C);
|
||||
width: 100%;border-radius: 25px;height: 50px;text-align: center;
|
||||
line-height: 50px;color: #FFFFFF;font-size: 16px;" @click="save">
|
||||
提交申请</view>
|
||||
</view>
|
||||
|
||||
<!-- 弹窗蒙版 -->
|
||||
<view class="model" catchtouchmove='preventTouchMove' v-if='showModal'></view>
|
||||
<view class="modalDlg" id="modalDlg" catchtouchmove='preventTouchMove' v-if='showModal'>
|
||||
|
||||
<view style="display: flex;flex-direction: column;padding: 12px;">
|
||||
|
||||
<view
|
||||
style="display: flex;flex-direction: row;align-items: center;justify-content: space-between; width: 100%;">
|
||||
|
||||
<text style="font-size: 16px;font-weight: 600;font-family: sans-serif;margin-left: 5px;">选择抬头</text>
|
||||
<image src="../../static/close2.png" style="width: 25px;height: 25px;" @click.stop="colseDialog()">
|
||||
</image>
|
||||
|
||||
</view>
|
||||
|
||||
<scroll-view scroll-y="true" :show-scrollbar="false"
|
||||
style="margin-top: 10px;padding-left: 12px;padding-right: 12px;box-sizing: border-box;"
|
||||
:style="'height:'+viewHeight+'px'">
|
||||
|
||||
<view v-for="(item,index) in data" :key="index" style="display: flex;flex-direction: column;"
|
||||
v-if="showData">
|
||||
|
||||
<view style="display: flex;flex-direction: row;justify-content: center;align-items: center;
|
||||
background: #fff; border-radius: 10px; margin-top: 12px;padding: 20px 12px;" @click="itemClick(item)">
|
||||
|
||||
<view style="flex: 1;display: flex;flex-direction: column;">
|
||||
|
||||
<view style="flex: 1;display: flex;flex-direction: row;align-items: center;">
|
||||
<text
|
||||
style="font-size: 16px;font-weight: 600;font-family: sans-serif;">{{item.invoiceHeader}}</text>
|
||||
<text v-if="item.isDefault==1" style="background: #FFF0DA; color: #61CB29;
|
||||
font-size: 10px;margin-left: 6px;border-radius: 5px;padding: 2px 5px;">默认</text>
|
||||
</view>
|
||||
|
||||
<text style="font-size: 12px;color: #999;margin-top: 5px;">
|
||||
{{item.invoiceType}} - {{item.headingType}}</text>
|
||||
|
||||
</view>
|
||||
|
||||
<text style="font-size: 12px;color: #999;" @click.stop="editItem(item)">编辑</text>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
<view v-if="notData" style="display: flex;flex-direction: column;align-items: center;">
|
||||
|
||||
<image src="https://supervise.yxtsoft.com/lpk/image/notData.png" mode="aspectFit"
|
||||
style="width: 100px;height: 100px;"></image>
|
||||
<view style="display: flex;flex-direction: column;align-items: center;margin-top: 10px;">
|
||||
<text style="font-size: 14px; color: #999;margin-right: 5px;">暂无数据</text>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
</scroll-view>
|
||||
|
||||
|
||||
</view>
|
||||
|
||||
<view style="position: absolute; bottom: 20px; display: flex;flex-direction: column;width: 100%;
|
||||
box-sizing: border-box;padding-left: 40px;padding-right: 40px; ">
|
||||
<view style="background: -webkit-linear-gradient(left,#61CB29,#60CA2C);
|
||||
width: 100%;border-radius: 25px;height: 50px;text-align: center;
|
||||
line-height: 50px;color: #FFFFFF;font-size: 16px;" @click="addInviice">
|
||||
添加新的抬头</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
showModal: false,
|
||||
showData: false,
|
||||
notData: true,
|
||||
viewHeight: "",
|
||||
page: {
|
||||
sid: ""
|
||||
},
|
||||
isPerson: true,
|
||||
showDetail: false,
|
||||
radioDefault: false,
|
||||
info: {
|
||||
sid: "",
|
||||
invoiceType: "", //发票类型
|
||||
headingType: "", //抬头类型
|
||||
invoiceHeader: "", //发票抬头
|
||||
dutyParagraph: "", //税号
|
||||
bankOfDeposit: "", //开户行
|
||||
bankAccount: "", //账号
|
||||
enterpriseAddress: "", //企业地址
|
||||
enterprisePhone: "", //企业电话
|
||||
email: "", //电子邮箱
|
||||
isDefault: "0", //是否默认 1 为默认
|
||||
customerSid: getApp().globalData.sid,
|
||||
orderSid: "" // 订单sid
|
||||
},
|
||||
data: []
|
||||
}
|
||||
},
|
||||
onLoad(options) {
|
||||
this.page.sid = options.sid
|
||||
this.getData()
|
||||
//隐藏加载框
|
||||
// uni.hideLoading();
|
||||
},
|
||||
onShow() {
|
||||
// this.getData()
|
||||
// //隐藏加载框
|
||||
// uni.hideLoading();
|
||||
},
|
||||
created() {
|
||||
var _this = this
|
||||
this.$bus.$on('invoice', msg => {
|
||||
console.log("aaaaaaaaaaa4", msg)
|
||||
|
||||
const index = _this.data.findIndex(item => item.sid == msg.sid)
|
||||
console.log(">>>>", index)
|
||||
if (index != -1) {
|
||||
// 替换 已修改过
|
||||
_this.data.splice(index, 1, msg)
|
||||
} else {
|
||||
// 刚新增的
|
||||
_this.data.push(msg)
|
||||
}
|
||||
|
||||
|
||||
});
|
||||
},
|
||||
methods: {
|
||||
getData() {
|
||||
|
||||
this.$api.getInvoiceList(getApp().globalData.sid).then((resp) => {
|
||||
console.log("getInvoiceList>>>" + resp);
|
||||
this.data = resp
|
||||
|
||||
const arr1 = this.data.filter(item => item.isDefault == 1)
|
||||
console.log(">>>>", arr1)
|
||||
|
||||
if (arr1.length > 0) {
|
||||
this.info = arr1[0]
|
||||
this.isPerson = this.info.headingType != '个人或事业单位'
|
||||
}
|
||||
|
||||
}).catch(e => {
|
||||
|
||||
})
|
||||
|
||||
},
|
||||
showList() {
|
||||
this.showModal = true
|
||||
uni.showLoading({
|
||||
title: '加载中'
|
||||
})
|
||||
setTimeout(() => {
|
||||
const query = uni.createSelectorQuery().in(this);
|
||||
query.select('.modalDlg').boundingClientRect(data => {
|
||||
console.log("得到布局位置信息" + JSON.stringify(data));
|
||||
console.log("节点离页面顶部的距离为" + data.top);
|
||||
console.log("节点离页面顶部的距离为" + data.height);
|
||||
this.viewHeight = data.height - 135
|
||||
this.showData = this.data.length > 0
|
||||
this.notData = this.data.length == 0
|
||||
|
||||
console.log("showData2" + this.showData);
|
||||
console.log("notData2" + this.notData);
|
||||
|
||||
//隐藏加载框
|
||||
uni.hideLoading();
|
||||
}).exec();
|
||||
|
||||
}, 500)
|
||||
|
||||
},
|
||||
|
||||
itemClick(item) {
|
||||
console.log("itemClick", item);
|
||||
|
||||
this.info = item
|
||||
this.isPerson = this.info.headingType != '个人或事业单位'
|
||||
this.colseDialog()
|
||||
|
||||
},
|
||||
editItem(item) {
|
||||
console.log("editItem", item);
|
||||
|
||||
uni.navigateTo({
|
||||
url: "/pages/me/addInvoice?info=" + encodeURIComponent(JSON.stringify(item))
|
||||
})
|
||||
},
|
||||
colseDialog() {
|
||||
this.showModal = false
|
||||
},
|
||||
addInviice() {
|
||||
uni.navigateTo({
|
||||
url: "/pages/me/addInvoice"
|
||||
})
|
||||
},
|
||||
radioChange(val) {
|
||||
console.log("radioChange", val);
|
||||
this.info.invoiceType = val.detail.value
|
||||
},
|
||||
radioChange2(val) {
|
||||
console.log("radioChange2", val);
|
||||
|
||||
this.info.headingType = val.detail.value
|
||||
|
||||
this.isPerson = val.detail.value != "个人或事业单位"
|
||||
|
||||
|
||||
},
|
||||
showDetailClick() {
|
||||
this.showDetail = !this.showDetail
|
||||
},
|
||||
radioDefaultClick() {
|
||||
this.radioDefault = !this.radioDefault
|
||||
|
||||
this.info.isDefault = this.radioDefault ? "1" : "0"
|
||||
|
||||
},
|
||||
save() {
|
||||
|
||||
console.log("save", this.info);
|
||||
|
||||
if (this.stringIsEmpty(this.info.invoiceType)) {
|
||||
this.shortToast('请选择发票类型')
|
||||
return
|
||||
}
|
||||
if (this.stringIsEmpty(this.info.headingType)) {
|
||||
this.shortToast('请选择抬头类型')
|
||||
return
|
||||
}
|
||||
if (this.stringIsEmpty(this.info.invoiceHeader)) {
|
||||
this.shortToast('发票抬头不能为空')
|
||||
return
|
||||
}
|
||||
|
||||
if (this.isPerson) {
|
||||
if (this.stringIsEmpty(this.info.dutyParagraph)) {
|
||||
this.shortToast('税号不能为空')
|
||||
return
|
||||
}
|
||||
}
|
||||
this.info.orderSid = this.page.sid
|
||||
|
||||
console.log("info", this.info);
|
||||
|
||||
this.$api.submitInvoice(this.info).then((resp) => {
|
||||
uni.navigateBack()
|
||||
}).catch(e => {
|
||||
|
||||
})
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
::-webkit-scrollbar {
|
||||
display: none;
|
||||
width: 0;
|
||||
height: 0;
|
||||
color: transparent;
|
||||
}
|
||||
|
||||
.page {
|
||||
background: #F7F7F7;
|
||||
height: 100vh;
|
||||
|
||||
.top {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
background: #fff;
|
||||
border-radius: 10px;
|
||||
padding: 16px 12px;
|
||||
|
||||
.top-item {
|
||||
margin-top: 24px;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
|
||||
.item-text {
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
.item-right {
|
||||
flex: 1;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
justify-content: flex-end;
|
||||
|
||||
.input {
|
||||
width: 100%;
|
||||
text-align: right;
|
||||
pointer-events: auto;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.item_btn {
|
||||
margin-top: 10px;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
width: 100%;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/* 弹窗样式 */
|
||||
.model {
|
||||
position: absolute;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background: #000;
|
||||
z-index: 1;
|
||||
opacity: 0.5;
|
||||
top: 0;
|
||||
left: 0;
|
||||
}
|
||||
|
||||
.modalDlg {
|
||||
/* 设置超出滚动 */
|
||||
overflow: auto;
|
||||
width: 100%;
|
||||
position: fixed;
|
||||
top: 70vw;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
z-index: 1000;
|
||||
background-color: #F7F7F7;
|
||||
border-top-right-radius: 20px;
|
||||
border-top-left-radius: 20px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
button::after {
|
||||
border: 0;
|
||||
}
|
||||
</style>
|
||||
181
pages/me/refundDetail.vue
Normal file
181
pages/me/refundDetail.vue
Normal file
@@ -0,0 +1,181 @@
|
||||
<template>
|
||||
|
||||
<view style="display: flex;flex-direction: column;height: 100vh; background: #F7F7F7;">
|
||||
<loading-state ref="pageView" @request="request">
|
||||
<view style="height: 100vh;overflow: hidden;overflow-y: auto;">
|
||||
|
||||
<view style="background: #fff;border-radius: 10px;margin-top: 12px;margin-left: 10px;margin-right: 10px;
|
||||
display: flex;flex-direction: column;padding: 12px 16px;">
|
||||
|
||||
<view
|
||||
style="display: flex;flex-direction: column; border-bottom: 1px #F7F7F7 solid; padding-bottom: 10px;">
|
||||
|
||||
<text style="font-size: 20px;color: #000;" v-show="data.payStatus=='5'">退款中</text>
|
||||
<text style="font-size: 14px;color: #999;margin-top: 5px;"
|
||||
v-show="data.payStatus=='5'">您已提交退款申请,请等待处理</text>
|
||||
|
||||
<text style="font-size: 20px;color: #000;" v-show="data.payStatus=='6'">退款成功</text>
|
||||
<text style="font-size: 14px;color: #999;margin-top: 5px;"
|
||||
v-show="data.payStatus=='6'">已退回至原支付方</text>
|
||||
|
||||
</view>
|
||||
|
||||
<view
|
||||
style="display: flex;flex-direction:row;justify-content: space-between;align-items: center;margin-top: 10px;">
|
||||
<text style="font-size: 16px;color: #666;">退款金额</text>
|
||||
<text style="font-size: 16px;color: #FF5006;">¥{{data.totalTee}}</text>
|
||||
</view>
|
||||
|
||||
<view
|
||||
style="display: flex;flex-direction:row;justify-content: space-between;align-items: center;margin-top: 10px;">
|
||||
<text style="font-size: 16px;color: #666;">退款账户</text>
|
||||
<text style="font-size: 13px;color: #999;">原支付账户</text>
|
||||
</view>
|
||||
|
||||
<view
|
||||
style="display: flex;flex-direction:row;justify-content: space-between;align-items: center;margin-top: 10px;">
|
||||
<text style="font-size: 16px;color: #666;">退款原因</text>
|
||||
<text style="font-size: 13px;color: #999;">{{data.reason}}</text>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
<view
|
||||
style="background: #fff;border-radius: 10px;display: flex;flex-direction: column;padding: 15px;margin-top: 15px; margin-left: 10px;margin-right: 10px;">
|
||||
|
||||
<text style="font-size: 18px;font-weight: 600;font-family: serif;margin-bottom: 10px;">退款商品</text>
|
||||
|
||||
<view v-for="(item,index) in data.ordOrderDetails"
|
||||
style=" display: flex;flex-direction: row;align-items: center; margin-bottom: 10px;">
|
||||
|
||||
<image :src="item.picUrl" @click="itemClick(item.goodsSid)"
|
||||
style="width: 70px;height: 70px;border-radius: 15px;" mode="scaleToFill">
|
||||
</image>
|
||||
|
||||
<view style="margin-left: 10px;display: flex;flex-direction: column;flex: 1;">
|
||||
|
||||
<view style="display: flex;flex-direction: row;width: 100%;">
|
||||
|
||||
<text style="flex: 1;font-weight: 600;font-family: sans-serif;font-size: 14px;"
|
||||
@click="itemClick(item.goodsSid)">{{item.goodsName}}</text>
|
||||
<text
|
||||
style="font-weight: 600;font-family: sans-serif;font-size: 14px;">¥{{item.priceUnit}}</text>
|
||||
</view>
|
||||
|
||||
<!-- <text style="margin-top: 10px;font-size: 12px;color: #999;">{{item.remarks}}</text> -->
|
||||
|
||||
<view style="margin-top: 8px;display: flex;flex-direction: column;">
|
||||
|
||||
<view style="display: flex;flex-direction: row;align-items: center;">
|
||||
<!-- <text style="border: 1px #EE752F solid; border-radius: 5px; padding: 0px 8px;
|
||||
font-size: 10px;color: #EE752F;">{{item.priceUnit}}元/{{item.specificationUnit}}</text> -->
|
||||
<text
|
||||
style="border: 1px #EE752F solid; border-radius: 5px; padding: 0px 8px;
|
||||
font-size: 10px;color: #EE752F; margin-right: 10px; ">{{item.numofPart}}{{item.specificationUnit}}/{{item.unitName}}</text>
|
||||
</view>
|
||||
|
||||
<text
|
||||
style="margin-top: 12px;font-size: 12px;color: #999;">份数:{{item.partNumber}}</text>
|
||||
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
<view style="background: #fff;border-radius: 10px;margin-top: 12px;margin-left: 10px;margin-right: 10px;
|
||||
display: flex;flex-direction: column;padding: 12px 16px;margin-bottom: 100px;">
|
||||
|
||||
<text style="font-size: 16px;">订单信息</text>
|
||||
|
||||
<view style="display: flex;flex-direction: column;margin-top: 15px; ">
|
||||
|
||||
<view style="display: flex;flex-direction: row;align-items: center;">
|
||||
|
||||
<text style="font-size: 14px;color: #999;">订单编号</text>
|
||||
<text
|
||||
style="margin-left: 15px;font-size: 14px;color: #333;word-break: break-all;">{{data.outTradeNo}}</text>
|
||||
</view>
|
||||
|
||||
<view style="display: flex;flex-direction: row;align-items: center;margin-top: 8px;">
|
||||
|
||||
<text style="font-size: 14px;color: #999;">下单时间</text>
|
||||
<text style="margin-left: 15px;font-size: 14px;color: #333;">{{data.createTime}}</text>
|
||||
</view>
|
||||
|
||||
<view style="display: flex;flex-direction: row;align-items: center;margin-top: 8px;">
|
||||
|
||||
<text style="font-size: 14px;color: #999;">支付方式</text>
|
||||
<text style="margin-left: 15px;font-size: 14px;color: #333;">{{data.payType}}</text>
|
||||
</view>
|
||||
|
||||
<view style="display: flex;flex-direction: row;align-items: center;margin-top: 8px;"
|
||||
v-if="data.payStatus=='4'">
|
||||
|
||||
<text style="font-size: 14px;color: #999;">付款时间</text>
|
||||
<text style="margin-left: 15px;font-size: 14px;color: #333;">{{data.payTime}}</text>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
</view>
|
||||
</loading-state>
|
||||
|
||||
|
||||
</view>
|
||||
|
||||
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
page: {
|
||||
sid: ""
|
||||
},
|
||||
data: {},
|
||||
reason: ""
|
||||
}
|
||||
},
|
||||
onLoad(options) {
|
||||
this.page.sid = options.sid
|
||||
this.request()
|
||||
},
|
||||
methods: {
|
||||
|
||||
// 获取数据
|
||||
request() {
|
||||
|
||||
|
||||
let _this = this
|
||||
|
||||
_this.$api.orderDetails(_this.page.sid).then((resp) => {
|
||||
_this.data = resp
|
||||
_this.$nextTick(() => {
|
||||
_this.$refs.pageView.setLoadState(2)
|
||||
})
|
||||
|
||||
}).catch(e => {
|
||||
_this.$nextTick(() => {
|
||||
_this.$refs.pageView.setLoadState(1)
|
||||
})
|
||||
})
|
||||
},
|
||||
itemClick(goodsSid) {
|
||||
uni.navigateTo({
|
||||
url: '/pages/good/goodsDetail2?sid=' + goodsSid
|
||||
})
|
||||
},
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
</style>
|
||||
Reference in New Issue
Block a user