fanfan 1 year ago
commit 0c68ce0aa0
  1. 7
      api/help.js
  2. 30
      api/invoice.js
  3. 201
      pages/invoice/editset.vue
  4. 123
      pages/invoice/indexset.vue
  5. 314
      pages/news1/feedback.vue
  6. 14
      pages/news1/help.vue
  7. 721
      pages/news1/huoyuan.vue
  8. 44
      pages/news1/setting.vue
  9. 66
      pages/news1/text.vue

@ -8,9 +8,12 @@ const api = {
joinStore: 'store/joinStore',
getStoreType: 'store/getStoreType',
storeSet:'store/editStore',
storeInfo:'store/getStoreInfo'
storeInfo:'store/getStoreInfo',
getAgreement: 'user/getAgreement',
}
export const getAgreement = (data) => {
return request.get(api.getAgreement,data)
}
// 帮助中心列表
export const list = (param) => {
return request.get(api.list, param)

@ -10,8 +10,11 @@ const api = {
invoicingDetail: 'user/invoicingDetail',
invoicingAdd: 'user/invoicingAdd',
invoicingEdit: 'user/invoicingEdit',
invoicingDelNew: 'user/delInvoicing'
}
export const invoicingDelNew = (data) => {
return request.get(api.invoicingDelNew,data)
}
export const invoicingEdit = (orderGoodsId, data) => {
return request.post(api.invoicingEdit, {
orderGoodsId,
@ -24,28 +27,17 @@ export const invoicingAdd = (orderGoodsId, data) => {
form: data
})
}
export const addInvoicing = (orderGoodsId, data) => {
return request.post(api.addInvoicing, {
orderGoodsId,
form: data
})
export const addInvoicing = (data) => {
return request.post(api.addInvoicing,data)
}
export const myInvoicing = (orderGoodsId, data) => {
return request.get(api.myInvoicing, {
orderGoodsId,
form: data
})
return request.get(api.myInvoicing,data)
}
export const editInvoicing = (orderGoodsId, data) => {
return request.post(api.editInvoicing, {
form: data
})
export const editInvoicing = (data) => {
return request.post(api.editInvoicing,data)
}
export const invoicingLog = (orderGoodsId, data) => {
return request.get(api.invoicingLog, {
orderGoodsId,
form: data
})
export const invoicingLog = (data) => {
return request.get(api.invoicingLog,data)
}
export function invoicingDel(param, option) {
return request.get(api.invoicingDel, param, option)

@ -13,7 +13,8 @@
<view class="l">发票类型</view>
<view class="r">
<picker :value="index" :range="array" @change="bindPickerChange">
<view class="lx">{{ index == -1 ? '请选择' : array[index] }}</view>
<view class="lx" style="color: #888;" v-if="index == null">请选择发票类型</view>
<view class="lx" v-else>{{ array[index] }}</view>
</picker>
</view>
</view>
@ -24,17 +25,10 @@
<view class="li" :class="tabIndex == 2 ? 'li-on' : ''" @click="tabItem(2)">单位</view>
</view>
</view>
<view class="item" v-if="tabIndex != 2">
<view class="l">发票抬头</view>
<view class="r">
<input type="text" v-model="obj.header" placeholder="请输入个人姓名" />
</view>
</view>
<view class="item" v-if="tabIndex == 2">
<view class="item">
<view class="l">发票抬头</view>
<view class="r">
<input type="text" v-model="array1[index1]" placeholder="请输入单位名称" />
<!-- <view class="tt" @click="bindPickerChange1" style="color: rgb(58, 134, 255)">更改抬头</view> -->
<input type="text" v-model="obj.header" :placeholder="tabIndex == 2 ? '请输入单位名称' : '请输入个人姓名'" />
</view>
</view>
<view class="item" v-if="tabIndex == 2">
@ -77,7 +71,7 @@
</view>
</view>
<view class="invoice-btn">
<view class="invoice-fd" @click="toDetail()">
<view class="invoice-fd" @click="onSubmit()">
提交
</view>
</view>
@ -92,51 +86,66 @@ import * as InvoiceApi from '@/api/invoice'
export default {
data() {
return {
id: '',
content: "确认您的发票信息无误后再提交",
show: true,
toggleIndex: true,
index: -1,
index: null,
array: ['普通增值税发票'],
index1: -1,
array1: [],
tabIndex: 2,
tabIndex: null,
sourcePage: 0,
orderDetail: '',
orderId: '',
obj: {
header: '',
gongsi: '',
duty_no: '',
bank_name: '',
bank_no: '',
address: '',
phone: '',
type: '',
source: 2
type: 1,
source: ''
}
};
},
onLoad(op) {
let app = this;
app.orderId = op.orderId
app.sourcePage = op.source == 1 ? op.source : 0
if (op.source == 0) {
app.orderDetail = op.order ? JSON.parse(op.order) : '';
}
if (op.source == 2 || op.source == 1) {
let detail = op.detail ? JSON.parse(op.detail) : '';
app.index = detail.type == 1 ? 0 : 1;
app.tabIndex = detail.source
app.obj = detail
onLoad(op) {
if (op.detailObj && op.detailObj != 'null') {
let end = JSON.parse(op.detailObj)
this.index = 0
if (end.source == 1) {
this.tabIndex = 1
} else {
this.tabIndex = 2
}
this.obj = end
}
// let app = this;
// app.orderId = op.orderId
// app.sourcePage = op.source == 1 ? op.source : 0
// if (op.source == 0) {
// app.orderDetail = op.order ? JSON.parse(op.order) : '';
// }
// if (op.source == 2 || op.source == 1) {
// let detail = op.detail ? JSON.parse(op.detail) : '';
// app.index = detail.type == 1 ? 0 : 1;
// app.tabIndex = detail.source
// app.obj = detail
// }
},
methods: {
//
toDetail(canReset = false) {
const app = this
if (app.index == -1) {
//
onSubmit() {
if (this.obj.id) {
this.editeInvoice()
} else {
this.addInvoice()
}
},
async addInvoice(canReset = false) {
const app = this
if (app.index == null || !app.obj.source) {
uni.showToast({
title: '请选择发票类型',
icon: 'none',
@ -154,70 +163,67 @@ export default {
}
if (app.tabIndex == 2 && !app.obj.duty_no) {
uni.showToast({
title: '请输入抬头',
title: '请输入纳税人识别号',
icon: 'none',
duration: 2000
})
return
}
app.isLoading = true;
if (app.tabIndex == 1) {
app.obj.gongsi = '';
app.obj.duty_no = '';
app.obj.bank_name = '';
app.obj.bank_no = '';
app.obj.address = '';
app.obj.phone = '';
}
app.obj.type = app.index == 0 ? 1 : 2;
app.obj.source = app.tabIndex;
let url = ''
if (app.sourcePage == 0) { //addInvoicing editInvoicing invoicingAdd
url = InvoiceApi.invoicingAdd(app.orderId, app.obj)
let {
status,
data
} = await InvoiceApi.addInvoicing(app.obj);
if (status == 200) {
uni.showToast({
title: '新增成功!',
icon: 'none',
duration: 2000
})
app.index = null
app.tabIndex =null
app.obj = app.$options.data().obj
}
if (app.sourcePage == 1) { //使
app.obj.invoice_id = app.obj.id; //
url = InvoiceApi.invoicingAdd(app.orderId, app.obj)
},
async editeInvoice() {
const app = this
if (app.index == null || !app.obj.source) {
uni.showToast({
title: '请选择发票类型',
icon: 'none',
duration: 2000
})
return
}
if (app.sourcePage == 2) { //
url = InvoiceApi.invoicingEdit(app.orderId, app.obj)
if (!app.obj.header) {
uni.showToast({
title: '请输入抬头',
icon: 'none',
duration: 2000
})
return
}
if (app.sourcePage == 3) { //
url = InvoiceApi.addInvoicing(app.orderId, app.obj)
if (app.tabIndex == 2 && !app.obj.duty_no) {
uni.showToast({
title: '请输入抬头',
icon: 'none',
duration: 2000
})
return
}
if (app.sourcePage == 4) { //
url = InvoiceApi.editInvoicing(app.orderId, app.obj)
let {
status,
data
} = await InvoiceApi.editInvoicing(app.obj);
if (status == 200) {
uni.showToast({
title: '编辑成功!',
icon: 'none',
duration: 2000
})
app.index = null
app.tabIndex =null
app.obj = app.$options.data().obj
}
debugger
url.then(result => {
if (result.status == 200) {
uni.showToast({
title: result.message,
icon: 'none',
duration: 2000
})
if (result.data.list.length.length > 0) {
uni.navigateTo({
url: "/pages/invoice/detail?id=" + result.data.list[0].id
})
} else {
uni.showToast({
title: '请求成功无返回详情',
icon: 'none',
duration: 2000
})
}
} else {
uni.showToast({
title: result.message,
icon: 'none',
duration: 2000
})
}
})
// :
canReset && uni.$emit('syncRefresh', true, true)
},
//
@ -237,11 +243,11 @@ export default {
},
onClose() { },
tabItem(i) {
this.tabIndex = i;
this.tabIndex = i;
this.obj.source = i
},
toggleItem(i) {
this.toggleIndex = !this.toggleIndex;
this.pamres.invoiceUnit = this.toggleIndex
toggleItem(i) {
this.toggleIndex = !this.toggleIndex;
},
bindPickerChange(e) {
this.index = e.detail.value;
@ -256,20 +262,23 @@ export default {
</script>
<style lang="scss" scoped>
.invoice-btn{
.invoice-btn {
width: 100%;
position: fixed;
bottom: 0;
left: 0;
padding: 30rpx 44rpx;
z-index: 8;
background: #F5F5F5;
background: #fafafa;
}
.invoice-company{
.invoice-company {
margin-bottom: 170rpx;
}
.invoice {
padding-bottom: 1rpx;
&-goods {
padding: 0 20rpx 0 40rpx;
overflow: hidden;
@ -475,7 +484,7 @@ export default {
&-fd {
height: 104rpx;
background: #F55349;
border-radius: 8rpx;
border-radius: 8rpx;
font-size: 32rpx;
font-weight: 500;
color: #FFFFFF;

@ -15,31 +15,40 @@
<view class="bill-record" v-else>
<view class="bill-item" v-for="(item, index) in recordList" :key="index">
<view class="bill-item-left">
<view class="commpany-name">飞科网络科技有限公司</view>
<view class="commpany-name">{{ item.header }}</view>
<view class="bill-price">
<text>¥</text>150
<text>¥</text>{{ item.price }}
</view>
</view>
<text class="bill-time">2023-12-31</text>
<text class="bill-time">{{ item.created_at }}</text>
</view>
</view>
</view>
<!-- 发票抬头 -->
<view v-if="tabIndex == 1">
<view class="invoice-header">
<view class="bill-header-item" @click="onAddInvoice" v-for="(item, index) in recordList" :key="index">
<view class="bill-header-left">
<view class="header-type">普通发票抬头-个人</view>
<view class="bill-header">
王大幅
<view class="empty" v-if="recordHeaderList.length == 0">
<u-empty text="暂无信息" mode="list"></u-empty>
</view>
<view v-else class="invoice-header">
<u-swipe-action :show="item.show" :options="options" @click="onActionClick(index)"
v-for="(item, index) in recordHeaderList" :key="index" @open="onActionOpen(index)">
<view class="bill-header-item" @click="onAddInvoice(item)">
<view class="bill-header-left">
<view class="header-type"> 普通增值税发票-{{ item.source == 1 ? '个人' : '单位' }}</view>
<view class="bill-header">
{{ item.header }}
</view>
<view class="bill-header" style="margin-top:18rpx" v-if="item.source == 2">
税号{{ item.duty_no }}
</view>
</view>
<u-icon name="edit-pen" size="30" color="#838383"></u-icon>
</view>
<u-icon name="edit-pen" size="30" color="#838383"></u-icon>
</view>
</u-swipe-action>
</view>
<view class="invoice-btn-box">
<view class="invoice-btn" @click="onAddInvoice">
<view class="invoice-btn" @click="onAddInvoice(null)">
<text>+</text>添加发票抬头
</view>
</view>
@ -56,30 +65,98 @@ export default {
data() {
return {
tabIndex: 0,
invoicList: [],
recordList: [1, 2]
recordList: [],
recordHeaderList: [],
options: [
{
text: '删除',
style: {
backgroundColor: '#dd524d'
}
}
]
};
},
onLoad() {
this.getRecordList()
},
methods: {
onTabClick(index) {
this.tabIndex = index
if (index == 1) {
this.recordHeaderList = []
this.getHeaderList()
} else {
this.recordList = []
this.getRecordList()
}
},
onEdit(item) {
uni.navigateTo({
url: "/pages/invoice/editset?detail=" + JSON.stringify(item) + '&source=' + 4
//
async getRecordList() {
uni.showLoading({
title: "加载中"
})
let {
status,
data
} = await InvoiceApi.invoicingLog({});
if (status == 200) {
uni.hideLoading();
this.recordList = data.list
}
},
//
async getHeaderList() {
uni.showLoading({
title: "加载中"
})
let {
status,
data
} = await InvoiceApi.myInvoicing({});
if (status == 200) {
uni.hideLoading();
this.recordHeaderList = data.list
this.recordHeaderList.map(item => {
item.show = false
})
}
},
onAddInvoice() {
//
async onActionClick(index) {
let that = this
let {
status,
data
} = await InvoiceApi.invoicingDelNew({ id: that.recordHeaderList[index].id});
if (status == 200) {
that.getHeaderList()
uni.showToast({
title: '删除成功!',
icon: 'none',
duration: 2000
})
}
},
onActionOpen(index) {
this.recordHeaderList[index].show = true;
this.recordHeaderList.map((val, idx) => {
if (index != idx) this.recordHeaderList[idx].show = false;
})
},
onAddInvoice(item) {
uni.navigateTo({
url: "/pages/invoice/editset?source=" + 3
url: "/pages/invoice/editset?detailObj=" + JSON.stringify(item)
})
},
}
}
</script>
<style lang="scss" scoped>
page {
background: red;
}
.invoice-btn-box {
width: 100%;
position: fixed;
@ -87,10 +164,10 @@ export default {
left: 0;
padding: 30rpx 44rpx;
z-index: 8;
background: #F5F5F5;
background: #fafafa;
.invoice-btn {
height: 104rpx;
height: 104rpx;
background: #F55349;
color: #fff;
font-size: 32rpx;
@ -109,12 +186,14 @@ export default {
.invoice-header {
background: #fff;
padding-bottom: 164rpx;
.bill-header-item {
display: flex;
justify-content: space-between;
align-items: flex-end;
padding: 54rpx 46rpx 120rpx 64rpx;
padding: 40rpx 46rpx 40rpx 64rpx;
font-size: 32rpx;
}
.header-type {

@ -17,12 +17,12 @@
</view>
<view class="section1" v-if="OrderType == 0">
<u-form :model="form" ref="uForm">
<view class="section1Item">
<view class="section1Item c">
<u-form-item label="反馈类型" label-width="170">
<u-radio-group v-model="form.type">
<u-radio active-color="#FF4434" v-for="(item, index) in checkboxList1" :key="index"
:name="item.name">
:name="item.val">
{{ item.name }}
</u-radio>
</u-radio-group>
@ -31,7 +31,7 @@
<u-form-item label="反馈类型" label-width="170">
<u-radio-group v-model="form.shop">
<u-radio active-color="#FF4434" v-for="(item, index) in checkboxList2" :key="index"
:name="item.name">
:name="item.val">
{{ item.name }}
</u-radio>
</u-radio-group>
@ -39,21 +39,31 @@
</u-form-item>
<u-form-item label="反馈类型" label-width="170" @click="typeShow = true">
<u-input v-model="form.shopText" placeholder="请选择门店" type="select" @click="typeShow = true" />
<u-action-sheet :list="shopList" :cancel-btn="false" v-model="typeShow"
@click="actionSheetCallback"></u-action-sheet>
<!-- <u-action-sheet :list="shopList" :cancel-btn="false" v-model="typeShow"
@click="actionSheetCallback"></u-action-sheet> -->
<u-picker :range="shopList" range-key="text" @confirm="actionSheetCallback($event)"
v-model="typeShow" mode="selector"></u-picker>
</u-form-item>
<u-form-item label="投诉内容" required label-width="150" label-position="top">
<u-input v-model="form.comment" class="textarea" placeholder="请填写投诉内容" type="textarea" />
<u-input v-model="form.comment" height="228" class="realAddr" placeholder="请填写投诉内容"
type="textarea"></u-input>
</u-form-item>
<u-upload :fileList="finishImageList" :previewFullImage="true" @afterRead="afterRead" :maxCount="8"
width="180" height="180" upload-text="上传照片" @delete="deletePic" name="1" multiple></u-upload>
<u-upload :action="action" :header="header" @on-uploaded="transferSuccess" @on-remove="transferRemove"
width="180" height="180" :file-list="finishImageList" :custom-btn="true" max-count="6">
<template v-slot:addBtn>
<view class="slot-btn" hover-class="slot-btn__hover" hover-stay-time="150">
<image :src="$picUrl + '/static/news/icon-upload.png'"></image>
<view class="1">上传照片</view>
</view>
</template>
</u-upload>
</view>
<view class="section1Item" style="margin-top:20rpx;">
<u-form-item label="您的称呼" label-width="170">
<u-input placeholder="请输入您的称呼" v-model="form.name" />
<u-input placeholder="请输入您的称呼" v-model="form.user_name" />
</u-form-item>
<u-form-item label="手机号码" label-width="170">
<u-input placeholder="请输入手机号" v-model="form.phone" />
<u-input placeholder="请输入手机号" v-model="form.mobile" />
</u-form-item>
</view>
</u-form>
@ -62,19 +72,26 @@
<view class="introText">1.工作人员将于1小时内与您联系解决您的问题(工作时间为周一至周日09:00~21:30)</view>
<view class="introText">2.有效投诉奖励最高奖励200元现金/代金券</view>
</view>
<view class="submitBtn" @click="submit">
提交
<view class="submitBtn-box">
<view class="submitBtn" @click="submit">
提交
</view>
</view>
</view>
<view class="section2" v-if="OrderType == 1 && feedBackList.length > 0">
<view class="section2" v-if="OrderType != 0 && feedBackList.length > 0">
<view class="feedShow" v-for="(item, index) in feedBackList" :key="index">
<view class="feedbackItem">
<view class="feedbackContent">
<view class="fbTitle">
<view class="fbFlag">
<text v-if="item.type == 1">投诉</text>
<text v-if="item.type == 2">建议</text>
<text v-if="item.type == 3">表扬</text>
<view class="fbFlag" v-if="item.type == 1">
<text>投诉</text>
</view>
<view class="fbFlag fbFlag2" v-if="item.type == 2">
<text>建议</text>
</view>
<view class="fbFlag fbFlag3" v-if="item.type == 3">
<text>表扬</text>
</view>
<view class="fbTitleText">
{{ item.shop_name }}
@ -86,24 +103,30 @@
</view>
<u-read-more showHeight="160" textIndent="0" fontSize="26rpx" color="#9E9E9E" :toggle="true"
close-text="展开">
<rich-text v-if="index != 0" :nodes="item.content"></rich-text>
<rich-text v-else
nodes="投诉内容投诉内容投诉内容投诉内容投诉内容投诉内容投诉内容投诉内容投诉内容投诉内容投诉内容投诉内容投诉内容投诉内容投诉内容投诉内容投诉内容"></rich-text>
<rich-text :nodes="item.content"></rich-text>
<view v-if="item.file_path">
<u-upload width="180" height="180" max-count="1" :file-list="item.file_paths" :deletable="false">
</u-upload>
</view>
</u-read-more>
<view class="timefb" v-if="OrderType == 1">
<text>反馈人</text> {{ item.user_name }}
</view>
<view class="timefb">
{{ item.created_at }}
<text>反馈时间</text> {{ item.created_at }}
</view>
</view>
<view class="feedbackResult">
<view class="feedbackResult" v-if="item.status">
<u-collapse>
<u-collapse-item :open="true" title="处理结果">
<u-collapse-item :open="false" title="处理结果">
<u-form :model="item" ref="item" class="selfForm">
<u-form-item label="处理时间:" label-width="150" prop="time">
{{ item.replay_at }}
</u-form-item>
<u-form-item label="反馈内容:" label-width="150" prop="feedback">
{{ item.content }}
{{ item.reply }}
</u-form-item>
</u-form>
</u-collapse-item>
@ -112,7 +135,7 @@
</view>
</view>
</view>
<view class="section2" v-if="OrderType == 2 && feedBackList.length > 0">
<!-- <view class="section2" v-if="OrderType == 2 && feedBackList.length > 0">
<view class="feedShow" style="padding: 0;" v-for="(item, index) in feedBackList" :key="index">
<view class="feedbackResult">
<u-collapse>
@ -122,41 +145,47 @@
{{ item.replay_at }}
</u-form-item>
<u-form-item label="反馈内容:" label-width="150" prop="feedback">
{{ item.content }}
{{ item.reply }}
</u-form-item>
</u-form>
</u-collapse-item>
</u-collapse>
</view>
</view>
</view> -->
<view class="empty" v-if="OrderType != 0 && total == 0">
<u-empty text="暂无信息" mode="list"></u-empty>
</view>
<view class="empty" v-if="OrderType == 2">
<!-- <view class="empty" v-if="OrderType == 2">
<image class="emptyImg" :src="$picUrl + '/static/news1/feedbackempty.png'" mode="widthFix"></image>
<view class="emptytext">
还没有反馈内容
</view>
</view>
</view> -->
</view>
</template>
<script>
import Config from '@/core/config'
import * as feedback from '@/api/feedback'
export default {
data() {
return {
return {
action: '',
header: '',
OrderType: 0,
shop_id: '',
total: 1,
form: {
type: '',
shop: '',
shopText: '',
comment: '',
name: '',
user_name: '',
phone: ''
},
feedBackList: [],
page: 1,
checkboxList1: [{
name: '投诉',
val: 1
@ -171,10 +200,12 @@ export default {
}
],
checkboxList2: [{
name: '门店'
name: '门店',
val: 1
},
{
name: '其他'
name: '其他',
val: 2
},
],
typeShow: false,
@ -184,11 +215,25 @@ export default {
result: {}
};
},
onReady() {
this.action = (Config.get('apiUrl') + 'upload/image').replace("index.php?s=/", "")
this.header = {
'Storeid': uni.getStorageSync('Store').storeInfo.store_id,
'Access-Token': uni.getStorageSync('AccessToken'),
'platform': "MP-WEIXIN",
}
},
onShow() {
this.getShopList()
},
onLoad(params) {
},
onReachBottom() {
if (this.feedBackList.length < this.total && this.OrderType != 0) {
this.pageNum++;
this.getFeedBack(this.OrderType)
}
},
methods: {
getShopList() {
@ -210,6 +255,35 @@ export default {
.catch(reject)
})
},
//
transferSuccess(list) {
if (list.length > 0) {
const {
response
} = list[0];
if (response.status == 200) {
uni.showToast({
title: "上传成功"
})
let idList = []
list.forEach(item => {
idList.push(item.response.data.fileInfo.file_id)
});
this.image_id = idList.join(',');
}
}
},
transferRemove(file, fileList) {
this.image_id = this.handleRemove(file, fileList);
},
handleRemove: function (file, fileList) {
let idList = []
fileList.forEach(item => {
idList.push(item.response.data.fileInfo.file_id)
});
return idList.join(',')
},
submit() {
const that = this
if (that.form.comment == '') {
@ -220,7 +294,7 @@ export default {
})
return
}
if (this.form.phone && (!/^\+?\d[\d -]{8,12}\d/.test(this.form.phone))) {
if (this.form.mobile && (!/^\+?\d[\d -]{8,12}\d/.test(this.form.mobile))) {
uni.showToast({
title: '手机号格式不正确!',
icon: 'none',
@ -232,7 +306,10 @@ export default {
shop_id: that.shop_id,
type: that.form.type,
object_type: that.form.shop,
content: that.form.comment
content: that.form.comment,
user_name: that.form.user_name,
mobile: that.form.mobile,
image_id: that.image_id
}
return new Promise((resolve, reject) => {
feedback.add(params)
@ -250,6 +327,7 @@ export default {
*/
onOrderTab(type) {
this.OrderType = type;
this.pageNum = 1
this.feedBackList = []
if (type != 0) {
this.getFeedBack(type)
@ -261,14 +339,27 @@ export default {
const that = this
let params = {
is_my: 0,
page: that.page
page: that.pageNum
}
params.is_my = type == 1 ? 0 : 1
return new Promise((resolve, reject) => {
feedback.list(params)
.then(res => {
if (res.status == 200) {
that.feedBackList = res.data.list.data
that.total = res.data.list.total
let end = res.data.list.data
end.map(itme=>{
if(itme.file_path){
itme.file_paths = []
let img_arr = itme.file_path.split(',')
img_arr.map(src=>{
itme.file_paths.push({
url:src
})
})
}
})
that.feedBackList = that.feedBackList.concat(end)
}
})
.catch(reject)
@ -279,70 +370,7 @@ export default {
this.form.shopText = this.shopList[index].text;
this.shop_id = this.shopList[index].id
},
//
async afterRead(event) {
let lists = [].concat(event.file)
let fileListLen = this[`fileList${event.name}`].length
lists.map((item) => {
this[`fileList${event.name}`].push({
...item,
status: 'uploading',
message: '上传中'
})
})
for (let i = 0; i < lists.length; i++) {
const result = await this.uploadFilePromise(lists[i].url)
if (JSON.parse(result).code == 1) {
let item = this[`fileList${event.name}`][fileListLen]
this[`fileList${event.name}`].splice(fileListLen, 1, Object.assign(item, {
status: 'success',
message: '',
url: result
}))
fileListLen++
} else {
this[`fileList${event.name}`].splice(fileListLen, 1)
}
}
},
//
uploadFilePromise(url) {
return new Promise((resolve, reject) => {
let a = uni.uploadFile({
url: this.baseUrl + '/api/common/upload', //
filePath: url,
name: 'file',
formData: {
user: 'test',
token: getToken()
},
success: (res) => {
if (JSON.parse(res.data).code == 1) {
setTimeout(() => {
this.finishImageList.push({ url: JSON.parse(res.data).data.fullurl, path: JSON.parse(res.data).data.url })
resolve(res.data)
}, 1000)
} else {
uni.$u.toast(JSON.parse(res.data).msg)
resolve(res.data)
}
},
fail: (res) => {
console.log(res, "rrr")
}
});
})
},
//
deletePic(event) {
this.finishImageList.splice(event.index, 1)
},
}
}
</script>
@ -355,6 +383,45 @@ page {
}
.c {
padding-top: 20rpx;
overflow: hidden;
.slot-btn {
width: 180rpx;
height: 180rpx;
background: #F6F6F6;
border-radius: 10rpx;
border: 1px solid #C0C0C0;
text-align: center;
font-size: 28rpx;
font-weight: 500;
color: #6D6D6D;
.l {
line-height: 30rpx;
margin-top: 10rpx;
}
image {
width: 50rpx;
height: 50rpx;
display: block;
margin: 0 auto;
margin-top: 30rpx;
}
}
}
.realAddr {
::v-deep .u-input {
padding: 10rpx 22upx !important;
background: #F7F8FA;
border-radius: 6rpx !important;
}
}
/* 订单tab */
.order-tab {
@ -431,20 +498,13 @@ page {
border: none;
}
// .textarea {
// height: 258rpx;
// border-radius: 3px;
// border: solid 1upx #F7F8FA;
// }
::v-deep .u-input__textarea {
padding: 26rpx;
}
.introContent {
margin-top: 16rpx;
margin: 16rpx 30rpx 30rpx 30rpx;
padding-bottom: 160rpx;
.introText {
font-size: 26rpx;
@ -455,16 +515,24 @@ page {
}
.submitBtn-box {
width: 100%;
position: fixed;
left: 0;
z-index: 88;
bottom: 0;
padding: 30rpx 32rpx;
background: #fafafa;
}
.submitBtn {
height: 100rpx;
background: linear-gradient(180deg, #FE7E71 0%, #FF4434 100%);
border-radius: 52px 52px 52px 52px;
opacity: 1;
font-size: 32rpx;
font-family: PingFang SC, PingFang SC;
font-weight: 500;
color: #FFFFFF;
margin: 32rpx 30rpx 30rpx 30rpx;
text-align: center;
line-height: 100rpx;
}
@ -516,7 +584,6 @@ page {
.fbFlag {
background: #FFFFFF;
border-radius: 3px;
opacity: 1;
padding: 5rpx;
border: 1px solid #FF4D4D;
font-size: 26rpx;
@ -524,6 +591,17 @@ page {
font-weight: 500;
color: #FF4D4D;
flex-shrink: 1;
margin-right: 20rpx;
}
.fbFlag2 {
border: 1px solid #41B4EC;
color: #41B4EC;
}
.fbFlag3 {
border: 1px solid #2DC37F;
color: #2DC37F
}
.fbTitleText {
@ -534,7 +612,6 @@ page {
text-overflow: ellipsis;
color: #000;
font-weight: bold;
margin-left: 20rpx;
}
}
@ -581,18 +658,5 @@ page {
justify-content: center;
flex-direction: column;
height: calc(100vh - 102rpx);
.emptyImg {
width: 210rpx;
}
.emptytext {
font-size: 32rpx;
font-family: PingFang SC, PingFang SC;
font-weight: 500;
color: #717171;
margin-top: 36rpx;
}
}
</style>

@ -90,11 +90,13 @@
border-radius: 20upx;
overflow: hidden;
padding: 20upx;
padding-bottom: 160rpx;
.helpTitle {
font-size: 32upx;
color: #000000;
padding: 20upx 0;
font-weight: bold;
// border-bottom: 3upx solid #dfdbdb;
}
@ -184,18 +186,15 @@
bottom: 0;
width: 100%;
background-color: #fff;
padding: 30rpx;
.btn {
height: 100upx;
margin: 10upx 30upx;
height: 100upx;
background: #FE6048;
border-radius: 28px 28px 28px 28px;
opacity: 1;
display: flex;
align-items: center;
justify-content: center;
align-items: center;
justify-content: center;
image {
width: 54upx;
height: auto;
@ -213,6 +212,7 @@
image {
width: 54upx;
height: auto;
margin-right: 100rpx;
}
text-align: center;
display: flex;

@ -6,32 +6,32 @@
</view>
</view>
<image :src="$picUrl+'/static/news1/walletBg.png'" class="bgImg" mode="widthFix"></image>
<image :src="$picUrl + '/static/news1/walletBg.png'" class="bgImg" mode="widthFix"></image>
<view style="border:1px solid transparent;margin-top:-190px;position: relative;z-index: 9;">
<view class="process">
<view class="pItem" v-for="(item,index) in list" :key="index">
<view class="pItem" v-for="(item, index) in list" :key="index">
<image :src="item.icon" mode="widthFix" class="icon"></image>
<view class="title">{{item.title}}</view>
<view class="subTitle">{{item.subTitle}}</view>
<view class="title">{{ item.title }}</view>
<view class="subTitle">{{ item.subTitle }}</view>
</view>
</view>
<view class="formContent">
<u-form :model="form" ref="uForm">
<u-form :model="form" ref="uForm" boder>
<u-form-item label="商品名称" label-width="150">
<u-input placeholder="请填写您求购的商品名称" v-model="form.name" />
</u-form-item>
<u-form-item label="产品描述" label-width="150">
<u-form-item label="产品描述" label-width="150">
<u-input maxlength="200" placeholder="如品牌、型号、参数 、配置、规格等,可复制电商标题、链接。" v-model="form.intro"
type="textarea" />
</u-form-item>
<u-form-item label="求购类型" label-width="150" @click="typeShow = true">
<u-input v-model="form.type" type="select" @click="typeShow = true" />
<u-action-sheet :list="type" :cancel-btn="false" v-model="typeShow"
@click="actionSheetCallback"></u-action-sheet>
<u-input v-model="form.type" placeholder="请选择求购类型" type="select" @click="typeShow = true" />
<u-picker :range="type" range-key="text" @confirm="actionSheetCallback($event)" v-model="typeShow"
mode="selector"></u-picker>
</u-form-item>
<u-form-item label="交货日期" label-width="150" @click="timeShow = true">
<u-input v-model="form.date" type="select" @click="timeShow = true" />
<u-input v-model="form.date" type="select" placeholder="请选择交货日期" @click="timeShow = true" />
<u-picker mode="time" v-model="timeShow" :params="timeParams" @confirm="timeChage"></u-picker>
</u-form-item>
<u-form-item label="求购数量" label-width="150">
@ -40,9 +40,9 @@
<u-form-item label="预估单价" label-width="150">
<view class="">
<view class="qujian">
<u-input placeholder="输入价格区间" border v-model="form.startNum" />
<u-input placeholder="输入价格区间" border v-model="form.startNum" />
<text style="margin:0 10upx;">-</text>
<u-input placeholder="输入价格区间" border v-model="form.endNum" />
<u-input placeholder="输入价格区间" border v-model="form.endNum" />
<text style="margin-left:10upx"></text>
</view>
<u-checkbox-group>
@ -54,397 +54,424 @@
</view>
</u-form-item>
<u-form-item label="上传照片" label-width="150">
<view class="photo">
<view class="file_img" v-for="(image, imageIndex) in imageList" :key="imageIndex">
<text class="image-delete iconfont icon-shanchu"
@click="deleteImage(imageIndex)"></text>
<image :src="image.path"></image>
</view>
<view @click="chooseImage" class="slot-btn" hover-class="slot-btn__hover"
hover-stay-time="150">
<image src="/static/news/icon-upload.png"></image>
<view class="1">上传图片</view>
<view class="1">{{imageList.length>0?imageList.length:0}}/{{maxImageLength}}</view>
</view>
</view>
<u-form-item label="上传照片" label-width="150" class="c">
<u-upload :action="action" :header="header" @on-uploaded="transferSuccess"
@on-remove="transferRemove" width="180" height="180" :file-list="transferList"
:custom-btn="true" max-count="6">
<template v-slot:addBtn>
<view class="slot-btn" hover-class="slot-btn__hover" hover-stay-time="150">
<image :src="$picUrl + '/static/news/icon-upload.png'"></image>
<view class="1">上传照片</view>
</view>
</template>
</u-upload>
</u-form-item>
<!-- <u-upload :fileList="finishImageList" :previewFullImage="true" @afterRead="afterRead" :maxCount="8"
width="180" height="180" upload-text="上传照片" @delete="deletePic" name="1" multiple></u-upload> -->
<u-form-item label="收货地址" label-width="150" @click="addrshow = true">
<u-input v-model="form.addr" type="select" @click="addrshow = true" />
<u-input v-model="form.addr" placeholder="请选择收货地址" type="select" @click="addrshow = true" />
<u-picker mode="region" v-model="addrshow" @confirm="getAddress"></u-picker>
</u-form-item>
<u-form-item label="备注" label-width="150" label-position="top">
<u-input v-model="form.remark" class="remarkInput" placeholder="请填写您要补充的内容,如规格、包装和运输等要求"
type="textarea" />
<u-form-item label="备注" class="self-form" label-width="150" label-position="top">
<u-input class="realAddr" height="258" type="textarea" placeholder="请填写您要补充的内容,如规格、包装和运输等要求"
v-model="form.remark">
</u-input>
</u-form-item>
</u-form>
<button class="submitBtn" @click="sureSubmit">确认发布</button>
<view class="submitBtn-box">
<button class="submitBtn" @click="sureSubmit">确认发布</button>
</view>
</view>
</view>
</view>
</template>
<script>
// import img from "@/static/news1/walletBg.png";
import * as help from '@/api/help'
import Config from '@/core/config'
import * as UploadApi from '@/api/upload'
export default {
data() {
let img= 'https://www.royaum.com.cn/static/news1/walletBg.png'
return {
background: {
background: 'url(' + img + ') center top no-repeat',
backgroundSize: '100%',
},
list: [{
icon: 'https://www.royaum.com.cn/static/news1/m1.png',
title: '发采购询价单',
subTitle: '填写所需信息一键发布询价'
},
{
icon: 'https://www.royaum.com.cn/static/news1/m2.png',
title: '卖家实时报价',
subTitle: '60分钟获取卖家报价'
},
{
icon: 'https://www.royaum.com.cn/static/news1/m3.png',
title: '卖家上架商品',
subTitle: '采购方案根据需要下单采购'
},
],
form: {
name: '',
intro: '',
type: '',
date: '',
num: '',
startNum: '',
endNum: '',
mianyi: true,
addr: '',
remark: ''
},
typeShow: false,
timeShow: false,
addrshow: false,
type: [{
text: '一件代发'
}],
timeParams: {
year: true,
month: true,
day: true,
hour: false,
minute: false,
second: false
},
radioList: [{
name: '面议'
},
],
radio: '',
//
imageList: [],
maxImageLength:6,
imgage_ids: []
}
},
methods: {
getAddress(e) {
this.form.addr = e.province.name + e.city.name + e.area.name;
this.address_id = e.province.code
// import img from "@/static/news1/walletBg.png";
import * as help from '@/api/help'
import Config from '@/core/config'
import * as UploadApi from '@/api/upload'
export default {
data() {
let img = 'https://www.royaum.com.cn/static/news1/walletBg.png'
return {
background: {
background: 'url(' + img + ') center top no-repeat',
backgroundSize: '100%',
},
timeChage(e) {
this.form.date = e.year + '-' + e.month + '-' + e.day
list: [{
icon: 'https://www.royaum.com.cn/static/news1/m1.png',
title: '发采购询价单',
subTitle: '填写所需信息一键发布询价'
},
sureSubmit() {
// 0000
const that = this;
that.uploadFile()
if (!that.form.name) {
return that.$toast('请输入商品名称')
}
if (!that.form.intro) {
return that.$toast('请输入商品信息')
}
if (!that.form.type) {
return that.$toast('请选择求购类型')
}
if (!that.form.date) {
return that.$toast('请选择交货日期')
}
if (!that.form.num) {
return that.$toast('请选择求购数量')
}
if (!that.form.startNum) {
return that.$toast('请输入最低价')
}
if (!that.form.endNum) {
return that.$toast('请输入最高价')
}
if (!that.form.mianyi) {
return that.$toast('请选择价格是否面议')
}
if (!that.form.mianyi) {
return that.$toast('请选择价格是否面议')
}
if (!that.form.remark) {
return that.$toast('请填写备注')
}
let params = {
goods_name: that.form.name,
goods_desc: that.form.intro,
type: that.form.type,
deliver_at: that.form.date,
num: that.form.num,
min_price: that.form.startNum,
max_price: that.form.endNum,
is_face: that.form.mianyi,
address_id: that.address_id,
remark: that.form.remark,
...that.imgage_ids
}
help.addGoodsSource(params)
.then(res => {
if (res.status) {
uni.showToast({
title: '发布成功',
icon: 'none',
duration: 2000
})
} else {
uni.showToast({
title: '发布失败',
icon: 'none',
duration: 2000
})
}
})
.finally()
{
icon: 'https://www.royaum.com.cn/static/news1/m2.png',
title: '卖家实时报价',
subTitle: '60分钟获取卖家报价'
},
actionSheetCallback(index) {
this.form.type = this.type[index].text;
{
icon: 'https://www.royaum.com.cn/static/news1/m3.png',
title: '卖家上架商品',
subTitle: '采购方案根据需要下单采购'
},
deleteImage(imageIndex) {
this.imageList.splice(imageIndex, 1)
],
form: {
name: '',
intro: '',
type: '',
date: '',
num: '',
startNum: '',
endNum: '',
mianyi: true,
addr: '',
remark: ''
},
//
chooseImage() {
const app = this
const oldImageList = app.imageList
//
uni.chooseImage({
count: app.maxImageLength - oldImageList.length,
sizeType: ['original', 'compressed'], //
sourceType: ['album', 'camera'], //
success({
tempFiles
}) {
app.imageList = oldImageList.concat(tempFiles)
}
});
typeShow: false,
timeShow: false,
addrshow: false,
type: [{
text: '一件代发'
}],
timeParams: {
year: true,
month: true,
day: true,
hour: false,
minute: false,
second: false
},
radioList: [{
name: '面议'
},
//
uploadFile() {
const app = this
],
radio: '',
//
imageList: [],
maxImageLength: 6,
imgage_ids: [],
action: '',
header: '',
transferList: []
}
},
onReady() {
this.action = (Config.get('apiUrl') + 'upload/image').replace("index.php?s=/", "")
this.header = {
'Storeid': uni.getStorageSync('Store').storeInfo.store_id,
'Access-Token': uni.getStorageSync('AccessToken'),
'platform': "MP-WEIXIN",
}
},
methods: {
//
transferSuccess(list) {
console.log(list)
if (list.length > 0) {
const {
imageList
} = app
//
return new Promise((resolve, reject) => {
if (imageList.length > 0) {
UploadApi.image(imageList)
.then(fileIds => {
app.imgage_ids = fileIds;
resolve(fileIds)
})
.catch(reject)
response
} = list[0];
if (response.status == 200) {
uni.showToast({
title: "上传成功"
})
let idList = []
list.forEach(item => {
idList.push(item.response.data.fileInfo.file_id)
});
this.imgage_ids = idList.join(',');
}
}
},
transferRemove(file, fileList) {
this.imgage_ids = this.handleRemove(file, fileList);
},
handleRemove: function (file, fileList) {
let idList = []
fileList.forEach(item => {
idList.push(item.response.data.fileInfo.file_id)
});
return idList.join(',')
},
getAddress(e) {
this.form.addr = e.province.name + e.city.name + e.area.name;
this.address_id = e.province.code
},
timeChage(e) {
this.form.date = e.year + '-' + e.month + '-' + e.day
},
sureSubmit() {
//
const that = this;
if (!that.form.name) {
return that.$toast('请输入商品名称')
}
if (!that.form.intro) {
return that.$toast('请输入商品信息')
}
if (!that.form.type) {
return that.$toast('请选择求购类型')
}
if (!that.form.date) {
return that.$toast('请选择交货日期')
}
if (!that.form.num) {
return that.$toast('请选择求购数量')
}
if (!that.form.startNum) {
return that.$toast('请输入最低价')
}
if (!that.form.endNum) {
return that.$toast('请输入最高价')
}
if (!that.form.mianyi) {
return that.$toast('请选择价格是否面议')
}
if (!that.form.mianyi) {
return that.$toast('请选择价格是否面议')
}
if (!that.form.remark) {
return that.$toast('请填写备注')
}
let params = {
goods_name: that.form.name,
goods_desc: that.form.intro,
type: that.form.type,
deliver_at: that.form.date,
num: that.form.num,
min_price: that.form.startNum,
max_price: that.form.endNum,
is_face: that.form.mianyi,
address_id: that.address_id,
remark: that.form.remark,
imgage_ids: that.imgage_ids
}
help.addGoodsSource(params)
.then(res => {
if (res.status) {
uni.showToast({
title: '发布成功',
icon: 'none',
duration: 2000
})
that.transferList = []
that.imgage_ids = []
that.form = that.$options.data().form
} else {
resolve()
uni.showToast({
title: '发布失败',
icon: 'none',
duration: 2000
})
}
})
},
.finally()
},
actionSheetCallback(index) {
this.form.type = this.type[index].text;
}
}
}
</script>
<style lang="scss" scoped>
page {
min-height: 100%;
padding-bottom: 100upx;
}
page {
min-height: 100%;
padding-bottom: 100upx;
}
.huoyuan {
.process {
height: 266upx;
background: #FFFFFF;
border-radius: 14upx;
opacity: 1;
display: flex;
align-items: center;
justify-content: space-between;
margin: 0 30upx;
// padding:0 28upx;
position: relative;
.pItem {
flex: 1;
height: 100%;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
image {
width: 56upx;
height: auto;
}
.c {
padding-top: 20rpx;
overflow: hidden;
.title {
font-size: 24upx;
font-family: PingFang SC, PingFang SC;
font-weight: 600;
color: #2D2D2D;
margin: 16upx 0;
}
.slot-btn {
width: 180rpx;
height: 180rpx;
background: #F6F6F6;
border-radius: 10rpx;
border: 1px solid #C0C0C0;
text-align: center;
font-size: 28rpx;
font-weight: 500;
color: #6D6D6D;
.subTitle {
font-size: 24upx;
font-family: PingFang SC, PingFang SC;
font-weight: 400;
color: #8A8A8A;
width: 75%;
text-align: center;
.l {
line-height: 30rpx;
}
}
}
image {
width: 50rpx;
height: 50rpx;
display: block;
margin: 0 auto;
margin-top: 30rpx;
}
}
}
.self-form {
::v-deep .u-form-item {
border: none !important;
;
}
}
.realAddr {
::v-deep .u-input {
padding: 10rpx 22upx !important;
background: #F7F8FA;
}
.formContent {
margin: 0 30upx;
background-color: #fff;
border-radius: 14upx;
margin-top: 20upx;
padding: 0 38upx;
padding-bottom: 64upx;
}
::v-deep .u-form-item--left {
align-items: flex-start;
.huoyuan {
.process {
height: 266upx;
background: #FFFFFF;
border-radius: 14upx;
opacity: 1;
display: flex;
align-items: center;
justify-content: space-between;
margin: 0 30upx;
// padding:0 28upx;
position: relative;
.pItem {
flex: 1;
height: 100%;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
image {
width: 56upx;
height: auto;
}
::v-deep .u-form-item--left__content__label {
.title {
font-size: 24upx;
font-family: PingFang SC, PingFang SC;
font-weight: 600;
color: #2D2D2D;
font-size: 28upx;
margin: 16upx 0;
}
.qujian {
width: 100%;
display: flex;
align-items: center;
.subTitle {
font-size: 24upx;
font-family: PingFang SC, PingFang SC;
font-weight: 400;
color: #8A8A8A;
width: 75%;
text-align: center;
}
}
}
.remarkInput {
width: 100%;
height: 246upx;
background: #F7F8FA;
border-radius: 3px 3px 3px 3px;
opacity: 1;
padding: 20upx !important;
.formContent {
margin: 0 30upx;
background-color: #fff;
border-radius: 14upx;
margin-top: 20upx;
padding: 0 38upx;
padding-bottom: 135upx;
::v-deep .u-form-item--left {
align-items: flex-start;
}
::v-deep .u-form-item--left__content__label {
color: #2D2D2D;
font-size: 28upx;
}
.qujian {
width: 100%;
display: flex;
align-items: center;
margin-bottom: 30rpx;
}
}
}
.submitBtn {
height: 88upx;
margin: 64upx 0;
margin-bottom: 0;
line-height: 88upx;
// background: #FFAAA4;
background: #FE483B;
border-radius: 36px 36px 36px 36px;
opacity: 1;
font-size: 28upx;
.remarkInput {
// width: 100%;
// height: 246upx;
background: green;
border-radius: 3px;
padding: 20upx !important;
}
.submitBtn-box {
position: fixed;
width: 100%;
left: 0;
bottom: 0;
padding: 30rpx 34rpx;
z-index: 88;
background: #fff;
}
.submitBtn {
height: 88upx;
line-height: 88upx;
// background: #FFAAA4;
background: #FE483B;
border-radius: 36px;
font-size: 28upx;
font-family: PingFang SC, PingFang SC;
font-weight: 500;
color: #FFFFFF;
text-align: center;
}
.navBarContent {
height: 88upx;
line-height: 88upx;
text-align: center;
position: relative;
text {
font-size: 32upx;
font-family: PingFang SC, PingFang SC;
font-weight: 500;
color: #FFFFFF;
text-align: center;
}
.navBarContent {
height: 88upx;
line-height: 88upx;
text-align: center;
position: relative;
}
text {
font-size: 32upx;
font-family: PingFang SC, PingFang SC;
font-weight: 500;
color: #FFFFFF;
}
.bgImg {
width: 100%;
}
}
.file_img {
overflow: hidden;
position: relative;
.bgImg {
width: 100%;
image {
width: 80px;
height: 80px;
margin-right: 10rpx;
}
.photo {
.image-delete {
position: absolute;
top: -10rpx;
right: -10rpx;
height: 42rpx;
width: 42rpx;
background: rgba(0, 0, 0, 0.64);
border-radius: 50%;
color: #fff;
font-weight: bolder;
font-size: 22rpx;
z-index: 10;
display: flex;
justify-content: flex-start;
padding: 20rpx 0;
overflow: hidden;
.slot-btn {
width: 80px;
height: 80px;
background: #FFFFFF;
border-radius: 10rpx;
border: 1px solid #C0C0C0;
text-align: center;
font-size: 24rpx;
font-weight: 500;
color: #D1D1D1;
image {
width: 50rpx;
height: 50rpx;
margin-top: 20rpx;
}
}
}
.file_img {
overflow: hidden;
position: relative;
image {
width: 80px;
height: 80px;
margin-right: 10rpx;
}
.image-delete {
position: absolute;
top: -10rpx;
right: -10rpx;
height: 42rpx;
width: 42rpx;
background: rgba(0, 0, 0, 0.64);
border-radius: 50%;
color: #fff;
font-weight: bolder;
font-size: 22rpx;
z-index: 10;
display: flex;
justify-content: center;
align-items: center;
}
justify-content: center;
align-items: center;
}
}
</style>

@ -30,12 +30,7 @@
<view class="name-text">
手机号
</view>
<input type="number" v-model="info.mobile" placeholder="请输入手机号">
<!-- <view>
<text>{{ info.mobile }}</text>
<u-icon style="margin-left: 5rpx; color: #8A8A8A" name="arrow-right"></u-icon>
</view> -->
<text>{{ info.mobile }}</text>
</view>
</view>
<view class="box">
@ -45,21 +40,21 @@
</view>
<u-icon style="margin-left: 5rpx; color: #8A8A8A" name="arrow-right"></u-icon>
</view>
<view class="box-avter conten-height">
<view class="box-avter conten-height" @click="toTextPage(1)">
<view class="name-text">
清除缓存
用户服务协议
</view>
<u-icon style="margin-left: 5rpx; color: #8A8A8A" name="arrow-right"></u-icon>
</view>
<view class="box-avter conten-height">
<view class="box-avter conten-height" @click="toTextPage(2)">
<view class="name-text">
隐私
隐私政策
</view>
<u-icon style="margin-left: 5rpx; color: #8A8A8A" name="arrow-right"></u-icon>
</view>
<view class="box-avter conten-height">
<view class="box-avter conten-height" @click="toTextPage(3)">
<view class="name-text">
关于
关于我们
</view>
<u-icon style="margin-left: 5rpx; color: #8A8A8A" name="arrow-right"></u-icon>
</view>
@ -74,7 +69,7 @@
<view class="bottomBtn">
<button class="submitBtn" @click="sureSubmit">确认修改</button>
</view>
</view>
</template>
@ -178,6 +173,8 @@ export default {
if (o.confirm) {
uni.removeStorage('token');
uni.removeStorage('userInfo');
uni.clearStorageSync()
uni.clearStorage()
uni.reLaunch({
url: '/pages/login/index'
})
@ -185,9 +182,14 @@ export default {
}
});
},
toTextPage(n) {
uni.navigateTo({
url: "/pages/news1/text?pageFlag=" + n
})
},
bindPickerInvoice() {
uni.navigateTo({
url: "/pages/invoice/index"
url: "/pages/invoice/indexset"
})
},
bindPickerChange(e) {
@ -219,7 +221,7 @@ page {
height: 28rpx;
}
.box-avter {
.box-avter {
width: 100%;
display: flex;
justify-content: space-between;
@ -254,21 +256,23 @@ page {
height: 114rpx;
border-radius: 50%;
}
.bottomBtn{
.bottomBtn {
width: 100%;
position: fixed;
bottom: 0;
left: 0;
height: 140upx;
z-index: 88;
background: #fff;
background: #fafafa;
}
.submitBtn {
height: 88upx;
.submitBtn {
height: 88upx;
line-height: 88upx;
background: #FFAAA4;
background: #FE483B;
border-radius: 36px;
border-radius: 36px;
font-size: 28upx;
font-family: PingFang SC, PingFang SC;
font-weight: 500;

@ -1,60 +1,52 @@
<template>
<view>
<view class="title">{{title}}</view>
<view class="con">用户服务协议用户服务协议用户服务协议用户服务协议用户服务协议用户服务协议用户服务协议用户服务协议用户服务协议用户服务协议用户服务协议用户服务协议用户服务协议用户服务协议</view>
<view>
<view class="con">{{ content }}</view>
</view>
</template>
<script>
import * as feedback from '@/api/feedback'
import * as help from '@/api/help'
export default {
data() {
return {
title:'用户协议'
pageFlag: 1,
content: ''
};
},
onShow() {
this.getShopList()
this.getTextData()
},
onLoad(params) {
let that = this
that.pageFlag = params.pageFlag
uni.setNavigationBarTitle({
title: that.pageFlag == 1 ? '用户服务协议' : that.pageFlag == 2 ? '隐私政策' : '关于我们'
})
},
methods: {
getShopList() {
const that = this
// that.shopList = []
// return new Promise((resolve, reject) => {
// feedback.shopList()
// .then(res => {
// if (res.data.length > 0) {
// for (var i = 0; i < res.data.length; i++) {
// let obj = {
// text: res.data[i].shop_name,
// id: res.data[i].shop_id
// }
// that.shopList.push(obj)
// }
// }
// })
// .catch(reject)
// })
async getTextData() {
uni.showLoading({
title: "加载中"
})
let typeVal = this.pageFlag == 1 ? 'user' : this.pageFlag == 2 ? 'policy' : 'about'
let {
status,
data
} = await help.getAgreement({ type: typeVal });
if (status == 200) {
uni.hideLoading();
this.content = data.detail.content
}
},
}
}
</script>
<style scoped lang="scss">
.title{
font-size: 30rpxrpx;
font-weight: bold;
text-align: center;
margin: 10rpx 20rpx;
}
.con{
<style scoped lang="scss">
.con {
font-size: 28rpx;
padding: 0 40rpx 40rpx;
padding: 20rpx 40rpx 40rpx;
line-height: 28px;
}
}
</style>

Loading…
Cancel
Save