Browse Source

上传

master
前端-胡立永 5 months ago
parent
commit
4c5825aa7e
14 changed files with 260 additions and 597 deletions
  1. +0
    -81
      components/bottom/bottomBtn.vue
  2. +3
    -0
      components/config/configPopup.vue
  3. +53
    -2
      components/tourGuide/locations.vue
  4. +158
    -0
      components/tourGuide/selectionPopup.vue
  5. +0
    -130
      components/userShop/userShopCommission.vue
  6. +0
    -12
      pages.json
  7. +1
    -0
      pages/index/tourGuide.vue
  8. +3
    -3
      pages_order/mine/purse.vue
  9. +0
    -366
      pages_order/order/refundsOrExchange.vue
  10. +13
    -0
      pages_order/service/situation.vue
  11. +27
    -3
      pages_order/service/tellList.vue
  12. BIN
      pages_order/static/applyRelic/2.png
  13. BIN
      pages_order/static/applyRelic/jdz.png
  14. +2
    -0
      store/store.js

+ 0
- 81
components/bottom/bottomBtn.vue View File

@ -1,81 +0,0 @@
<template>
<view @click="$emit('confirm')" :style="{
position: 'fixed',
display: 'flex',
justifyContent: 'center',
alignItems: 'center',
width: '100vw',
bottom: bottom
}">
<button :style="{
color: color,
backgroundColor: backgroundColor,
fontSize: fontSize,
width: width,
height: height,
borderRadius: borderRadius
}">
{{ text }}
</button>
</view>
</template>
<script>
export default {
props: {
color: {
default: '#000000' //
},
backgroundColor: {
default: '#FFFFFF' //
},
fontSize: {
default: '36rpx' //
},
text: {
default: '按钮' //
},
width: {
default: '150rpx' //
},
height: {
default: '60rpx' //
},
borderRadius: {
default: '40rpx' //
},
bottom: {
default: '40rpx' //
},
},
data() {
return {
}
},
methods: {
}
}
</script>
<style scoped lang="less">
// .container {
// position: fixed;
// display: flex;
// justify-content: center;
// /* */
// align-items: center;
// /* */
// width: 100%;
// /* 使 */
// }
button {
display: flex;
justify-content: center;
align-items: center;
}
</style>

+ 3
- 0
components/config/configPopup.vue View File

@ -40,6 +40,9 @@
.configPopup {
.content{
padding: 30rpx 20rpx;
overflow: scroll;
height: 100%;
box-sizing: border-box;
}
}
</style>

+ 53
- 2
components/tourGuide/locations.vue View File

@ -10,9 +10,19 @@
:markers="spotGuideMarkers"
:scale="scale"
@markertap="markertap"
id="mapId"
@callouttap='callouttap'>
</map>
<uv-tabs :list="areaList"
:activeStyle="{color : '#B12026', fontWeight : 600}"
lineColor="#B12026"
lineHeight="8rpx"
lineWidth="50rpx"
keyName="areaName"
:current="currentArea"
@click="clickTabs"></uv-tabs>
<view class="tabs">
<view class=""
v-for="(item, index) in tabs"
@ -69,11 +79,12 @@
v-if="show && spotGuide.length > 0">
<view class="main"
v-for="(item, index) in spotGuide"
@click.stop="toUrl(item)"
@click.stop="moveTolocation(item.spotLatitude ,item.spotLongitude)"
:key="index">
<image
class="main-image"
:src="item.spotImage"
@click.stop="toUrl(item)"
mode="aspectFill"></image>
<view class="info">
@ -147,13 +158,24 @@
// '',
'找美食'
, '找民宿', '找厕所'],
areaList : [],
currentArea : 0,
}
},
computed : {
// ...mapGetters(['spotGuide', 'spotGuideMarkers']),
...mapState(['position', 'spotGuideIndex']),
...mapState(['position', 'spotGuideIndex', 'areaId']),
},
created() {
this.queryAreaList()
},
methods: {
//tab
clickTabs({ index, name }) {
this.currentArea = index
this.$store.commit('setAreaId', this.areaList[index].id)
this.$emit('getData')
},
// 0- 1- 2-宿 3-
setSpotGuideIndex(index){
this.$store.commit('setSpotGuideIndex', index)
@ -205,6 +227,35 @@
this.$utils.navigateTo(`/pages_order/service/articleDetail?id=${item.id}&type=Inheritance`)
}
},
queryAreaList(){
this.$api('queryAreaList', res => {
if(res.code == 200){
this.areaList = res.result.records
this.areaList.forEach((n, i) => {
if(this.areaId == n.id){
this.currentArea = i
}
})
}
})
},
//
moveTolocation(latitude, longitude){
let mapObjs = uni.createMapContext('mapId', this)
mapObjs.moveToLocation(
{
latitude,
longitude
},
{
complete: res=>{
console.log('移动完成:', res)
}
})
// this.onRegionChange('',true)
},
}
}
</script>


+ 158
- 0
components/tourGuide/selectionPopup.vue View File

@ -0,0 +1,158 @@
<template>
<uv-popup ref="popup" :round="30" :customStyle="{height: '60vh'}">
<view class="content">
<uv-vtabs
:chain="chain"
:list="areaList"
keyName="areaName"
:barItemBadgeStyle="{right:'20px',top:'12px'}"
@change="change">
<uv-vtabs-item>
<view class="category-title">
遗产点
</view>
<view class="list">
<view class="item" v-for="(item,index) in list" :key="index"
@click="select(item)">
<view class="item-image">
<image
:src="item.spotImage"
mode="aspectFill"></image>
</view>
<view class="item-unit">
<text class="text">{{item.spotName}}</text>
</view>
</view>
</view>
</uv-vtabs-item>
</uv-vtabs>
</view>
</uv-popup>
</template>
<script>
import { mapState, mapGetters } from 'vuex'
export default {
data() {
return {
chain: false,
areaList : [],
areaIndex: 0,
}
},
computed: {
list(){
return this.spotList.filter(n => {
if(0 != n.categoryId){
return false
}
if(!this.areaList[this.areaIndex]){
return false
}
if(this.areaList[this.areaIndex].id != n.areaId){
return false
}
return true
})
},
...mapState(['spotList']),
},
created() {
this.queryAreaList()
},
methods: {
change(index) {
this.areaIndex = index;
},
open(){
this.$refs.popup.open('bottom');
},
select(e){
this.$emit('select', e)
this.$refs.popup.close();
},
queryAreaList(){
this.$api('queryAreaList', res => {
if(res.code == 200){
this.areaList = res.result.records
}
})
},
}
}
</script>
<style scoped lang="scss">
.content{
/deep/ .uv-vtabs{
height: 60vh !important;
}
/deep/ .uv-vtabs__bar{
height: 60vh !important;
}
/deep/ .uv-vtabs__content{
height: 60vh !important;
}
.category-title{
position: relative;
display: flex;
justify-content: center;
align-items: center;
height: 120rpx;
&::before,
&::after {
position: absolute;
top: 50%;
content: '';
width: 10%;
border-top: 2rpx solid black;
}
&::before {
left: 25%;
}
&::after {
right: 25%;
}
}
.list{
display: flex;
flex-wrap: wrap;
margin: 0 auto;
width: 490rpx;
.item {
padding: 10rpx 20rpx;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
margin-bottom: 20rpx;
.item-image {
width: 120rpx;
height: 120rpx;
image{
height: 100%;
width: 100%;
border-radius: 50%;
}
}
.item-unit {
font-size: 24rpx;
margin-top: 15rpx;
color: #555;
}
}
.gap {
padding: 0 30rpx;
}
}
}
</style>

+ 0
- 130
components/userShop/userShopCommission.vue View File

@ -1,130 +0,0 @@
<template>
<view class="commission">
<image src="/static/image/center/10.png" mode=""></image>
<view class="price">
<view class="title">
总佣金
</view>
<view class="num">
7890.34
</view>
</view>
<view class="font-menu"
v-if="purse">
<view @click="toRunningWater(index)"
v-for="(item, index) in list"
:key="index">{{ item.name }}</view>
</view>
<view class="btn"
v-if="!purse"
@click="toPurse">
提现
</view>
</view>
</template>
<script>
export default {
name: "userShopCommission",
props : {
purse : {
default : false,
},
},
data() {
return {
list : [
{
name : '余额记录',
},
{
name : '提现记录',
},
{
name : '佣金记录',
},
],
};
},
methods : {
//
toPurse(){
uni.navigateTo({
url:'/pages_order/mine/purse'
})
},
//
toRunningWater(index){
uni.navigateTo({
url:'/pages_order/mine/runningWater?status=' + index
})
},
}
}
</script>
<style scoped lang="scss">
.commission {
width: 700rpx;
height: 300rpx;
position: relative;
margin: 20rpx auto;
color: #fff;
image {
width: 700rpx;
height: 300rpx;
position: absolute;
border-radius: 20rpx;
}
.price {
position: absolute;
left: 50rpx;
top: 80rpx;
font-weight: 900;
.title {
font-size: 32rpx;
}
.num {
font-size: 44rpx;
margin-top: 20rpx;
}
}
.font-menu {
font-size: 24rpx;
font-family: PingFang SC, PingFang SC-Regular;
font-weight: 500;
text-align: center;
color: #ffffff;
line-height: 24rpx;
width: 710rpx;
position: absolute;
left: 0;
bottom: 25rpx;
display: flex;
view{
width: 160rpx;
}
}
.btn {
position: absolute;
right: 50rpx;
bottom: 50rpx;
background-color: #FDC440;
width: 160rpx;
height: 60rpx;
display: flex;
justify-content: center;
align-items: center;
border-radius: 30rpx;
}
}
</style>

+ 0
- 12
pages.json View File

@ -33,12 +33,6 @@
"enablePullDownRefresh" : true
}
},
{
"path": "mine/purse"
},
{
"path": "mine/runningWater"
},
{
"path": "mine/address",
"style": {
@ -51,18 +45,12 @@
"enablePullDownRefresh" : true
}
},
{
"path": "order/refundsOrExchange"
},
{
"path": "auth/wxLogin"
},
{
"path": "auth/wxUserInfo"
},
{
"path": "auth/loginAndRegisterAndForgetPassword"
},
{
"path": "order/order"
},


+ 1
- 0
pages/index/tourGuide.vue View File

@ -16,6 +16,7 @@
:spotGuide="spotGuide"
:spotGuideMarkers="spotGuideMarkers"
:area="area"
@getData="queryAreaListById"
/>
<tabber select="1"/>


+ 3
- 3
pages_order/mine/purse.vue View File

@ -4,7 +4,7 @@
<!-- 水洗店 -->
<view class="userShop">
<userShopCommission purse />
<!-- <userShopCommission purse /> -->
</view>
<view class="from-body">
@ -37,10 +37,10 @@
</template>
<script>
import userShopCommission from '@/components/userShop/userShopCommission.vue'
// import userShopCommission from '@/components/userShop/userShopCommission.vue'
export default {
components: {
userShopCommission,
// userShopCommission,
},
data() {
return {


+ 0
- 366
pages_order/order/refundsOrExchange.vue View File

@ -1,366 +0,0 @@
<template>
<view class="refundsOrExchange">
<navbar :title="title[titleIndex]" leftClick @leftClick="$utils.navigateBack"/>
<view class="frame">
<!-- 商品简介 -->
<view class="itme1" @click="openSpPopup">
<view class="left">
<img src="../../static/image/center/1.png" alt="" style="width: 100%;height: 100%;">
</view>
<view class="center">
<view>{{ commodity.title }}</view>
<view>{{ commodity.smallTitle }}</view>
</view>
<view class="right">×{{ commodity.total }}</view>
</view>
<!--<commoditySelect ></commoditySelect>-->
<!-- 申请类型&申请原因 -->
<view class="item2">
<view class="type">
<span>申请类型</span>
<span>退货退款</span>
</view>
<uv-line></uv-line>
<view class="reason">
<view>申请原因</view>
<view>
<uv-input placeholder="请输入申请原因" border="none" clearable></uv-input>
</view>
</view>
</view>
<!-- 退货数量&申请金额-->
<view class="item3">
<view class="type">
<span>{{ titleIndex == 0 ? '退货数量' : '换货数量' }}</span>
<span>
<uv-number-box :min="1" :max="100"></uv-number-box>
</span>
</view>
<uv-line v-if='titleIndex == 0 ? true :false'></uv-line>
<view class="reason" v-if='titleIndex == 0 ? true :false'>
<view>申请原因</view>
<view>
<uv-input disabled placeholder="$" border="none" clearable></uv-input>
</view>
</view>
</view>
<!-- 申请说明 -->
<view class="item4">
<view>申请说明(选填)</view>
<view>
<uv-input placeholder="请您详细填写申请说明" border="none" clearable></uv-input>
</view>
<view>
<uv-upload :fileList="fileList" :maxCount="5" multiple width="150rpx" height="150rpx"
@delete="deleteImage" @afterRead="afterRead" :previewFullImage="true"></uv-upload>
</view>
</view>
<!-- 联系电话 -->
<view class="item5">
<view class="phone">
<view>联系电话</view>
<view>
<uv-input placeholder="请输入联系电话" border="none" clearable></uv-input>
</view>
</view>
</view>
</view>
<!-- 底部按钮 -->
<bottomBtn @confirm='confirm()' :color='bottomBtnStyle.color' :backgroundColor='bottomBtnStyle.backgroundColor'
:fontSize='bottomBtnStyle.fontSize' :text='bottomBtnStyle.text' :width="bottomBtnStyle.width"
:height="bottomBtnStyle.height" :borderRadius='bottomBtnStyle.borderRadius'
:bottom='bottomBtnStyle.bottom'
>
</bottomBtn>
<!--商品选择-->
<uv-popup ref="spPopup" :round="30">
<commoditySelect
:commodityList="commodityList"
@selectSp="selectCommodity"
/>
</uv-popup>
</view>
</template>
<script>
import bottomBtn from "../../components/bottom/bottomBtn.vue"
import commoditySelect from "../components/commodity/commoditySelect.vue"
export default {
onLoad(option) {
this.titleIndex = option.index
},
components: {
bottomBtn, commoditySelect
},
data() {
return {
titleIndex: 0,
title: ['申请换货', '申请退货'],
fileList: [],
bottomBtnStyle: {
color: '#FFF',
backgroundColor: '#fd5100',
fontSize: '34rpx',
text: '提交申请',
width: '400rpx',
height: '80rpx',
borderRadius: '100rpx',
bottom: '40rpx'
},
commodityList: [
{
title: '商品名称',
smallTitle: '产品规格:120*4*75【桌子尺寸】',
total:1,
},
{
title: '商品名称1',
smallTitle: '产品规格:120*4*75【桌子尺寸】',
total:1,
},
{
title: '商品名称2',
smallTitle: '产品规格:120*4*75【桌子尺寸】',
total:1,
}
],
commodity: {
title: '商品名称',
smallTitle: '产品规格:120*4*75【桌子尺寸】',
total:1,
},
}
},
mounted() {
},
methods: {
openSpPopup() {
this.$refs.spPopup.open('bottom');
},
// 退
selectCommodity(e) {
console.log(e, "selectCommodity--e")
this.commodity = e
this.$refs.spPopup.close()
},
confirm() {
console.log("===");
},
deleteImage(e) {
this.fileList.splice(e.index, 1)
},
afterRead(e) {
let self = this
e.file.forEach(file => {
self.$Oss.ossUpload(file.url).then(url => {
self.fileList.push({
url
})
})
})
},
}
}
</script>
<style lang="scss" scoped>
* {
box-sizing: border-box;
}
.refundsOrExchange {
.frame {
display: flex;
flex-direction: column;
gap: 30rpx;
width: 100%;
padding-top: 40rpx;
background-color: #f5f5f5;
.itme1 {
display: flex;
height: 200rpx;
background-color: #ffffff;
.left {
padding: 40rpx;
width: 20%;
border-radius: 10rpx;
background-color: #ffffff;
}
.center {
display: flex;
flex-direction: column;
justify-content: center;
gap: 20rpx;
width: 60%;
padding: 0rpx 0 0 20rpx;
background-color: #ffffff;
// view
> view:first-of-type {
font-size: 36rpx;
color: #333;
}
// view
> view:nth-of-type(2) {
font-size: 28rpx;
color: #666666;
}
}
.right {
display: flex;
justify-content: center;
align-items: center;
width: 10%;
color: #666666;
background-color: #ffffff;
}
}
.item2 {
width: 100vw;
.type {
display: flex;
align-items: center;
background-color: #FFF;
height: 80rpx;
padding: 0 0 0 20rpx;
> span:nth-of-type(1) {
width: 30%;
}
> span:nth-of-type(2) {
width: 70%;
}
}
.reason {
display: flex;
align-items: center;
background-color: #FFF;
height: 80rpx;
// margin: 10rpx 0 0 0;
padding: 10rpx 0 0 20rpx;
> view:nth-of-type(1) {
width: 30%;
}
> view:nth-of-type(2) {
width: 70%;
padding: 0 20rpx 0 0;
}
}
}
.item3 {
width: 100vw;
.type {
display: flex;
align-items: center;
background-color: #FFF;
height: 80rpx;
padding: 0 0 0 20rpx;
> span:nth-of-type(1) {
width: 70%;
}
> span:nth-of-type(2) {
width: 30%;
}
}
.reason {
display: flex;
align-items: center;
background-color: #FFF;
height: 80rpx;
// margin: 10rpx 0 0 0;
padding: 10rpx 0 0 20rpx;
> view:nth-of-type(1) {
width: 30%;
}
> view:nth-of-type(2) {
width: 70%;
padding: 0 20rpx 0 0;
}
}
}
.item4 {
display: flex;
flex-direction: column;
padding: 10rpx 0 0 20rpx;
background-color: #FFF;
> view:nth-of-type(1) {
background-color: #FFF;
}
> view:nth-of-type(2) {
margin: 10rpx 0 10rpx 0;
background-color: #FFF;
}
}
.item5 {
display: flex;
flex-direction: column;
padding: 0 0 0 20rpx;
background-color: #FFF;
.phone {
display: flex;
align-items: center;
background-color: #FFF;
height: 80rpx;
// margin: 10rpx 0 0 0;
padding: 10rpx 0 0 20rpx;
> view:nth-of-type(1) {
width: 30%;
}
> view:nth-of-type(2) {
width: 70%;
padding: 0 20rpx 0 0;
}
}
}
}
}
</style>

+ 13
- 0
pages_order/service/situation.vue View File

@ -2,6 +2,15 @@
<!-- 遗产概况 -->
<view class="situation">
<navbar title="遗产概况" leftClick @leftClick="$utils.navigateBack" />
<view class="top-img">
<uv-swiper
:list="banner.follow"
indicator
height="420rpx"
keyName="imageContent"></uv-swiper>
</view>
<view class="situation-imgs">
<view class="situation-imgs-one"
v-if="list[0].id"
@ -52,6 +61,7 @@
</template>
<script>
import { mapState } from 'vuex'
export default {
data() {
return {
@ -63,6 +73,9 @@
list : [],
}
},
computed : {
...mapState(['banner']),
},
onShow() {
this.queryAreaList()
},


+ 27
- 3
pages_order/service/tellList.vue View File

@ -19,7 +19,12 @@
:value="dropItem('level').value">
</uv-drop-down-item>
<uv-drop-down-item name="spot" type="2"
<!-- <uv-drop-down-item name="spot" type="2"
:label="dropItem('spot').label"
:value="dropItem('spot').value">
</uv-drop-down-item> -->
<uv-drop-down-item name="spot" type="1"
:label="dropItem('spot').label"
:value="dropItem('spot').value">
</uv-drop-down-item>
@ -34,16 +39,24 @@
</view>
<cardList :type="type" :result="result" :dict="dict" ref="cardList" :showRoleLevel="dict.showRoleLevel" />
<selectionPopup
ref="selectionPopup"
@select="select"/>
<tabber />
</view>
</template>
<script>
import cardList from '../components/list/cardList.vue'
import selectionPopup from '@/components/tourGuide/selectionPopup.vue'
import { mapState } from 'vuex'
export default {
components: {
cardList
cardList,
selectionPopup,
},
data() {
return {
@ -165,6 +178,11 @@
this.activeName = name;
if(type == 1){
this.$refs.selectionPopup.open()
return
}
const find = this.result.find(item => item.name == this.activeName);
if (find) {
const findIndex = this[this.activeName]
@ -216,7 +234,13 @@
this.$nextTick(() => {
this.$refs.cardList.getList()
})
}
},
select(n){
this.clickItem({
label : n.spotName,
value : n.spotName
})
},
}
}
</script>


BIN
pages_order/static/applyRelic/2.png View File

Before After
Width: 75  |  Height: 75  |  Size: 7.4 KiB Width: 150  |  Height: 150  |  Size: 25 KiB

BIN
pages_order/static/applyRelic/jdz.png View File

Before After
Width: 1360  |  Height: 906  |  Size: 674 KiB

+ 2
- 0
store/store.js View File

@ -23,6 +23,7 @@ const store = new Vuex.Store({
areaId : 0,//景区id
},
getters: {
// 当前分区景点
spotGuide(state){
return state.spotList.filter(n => {
@ -40,6 +41,7 @@ const store = new Vuex.Store({
return true
})
},
// 地图点位
spotGuideMarkers(state){
let list = []


Loading…
Cancel
Save