@@ -1,6 +1,6 @@ | |||||
<template> | <template> | ||||
<view style="height: 100%"> | <view style="height: 100%"> | ||||
<view v-if="position === 'fixed'" :style="'height: calc(46px + 17rpx);'" /> | |||||
<view v-if="position === 'fixed'" :style="'height: calc(103px + 17rpx);'" /> | |||||
<view | <view | ||||
:class="'custom-nav-bar ' + (position === 'fixed' ? 'custom-nav-bar__fixed' : '') + ' ' + (position === 'absolute' ? 'custom-nav-bar__absolute' : '')" | :class="'custom-nav-bar ' + (position === 'fixed' ? 'custom-nav-bar__fixed' : '') + ' ' + (position === 'absolute' ? 'custom-nav-bar__absolute' : '')" | ||||
@@ -9,7 +9,7 @@ | |||||
zIndex + | zIndex + | ||||
';background-color: ' + | ';background-color: ' + | ||||
(color === 'white' ? 'transparent' : '#ffffff') + | (color === 'white' ? 'transparent' : '#ffffff') + | ||||
';height:calc(46px + 17rpx);' | |||||
';height:calc(103px + 17rpx);' | |||||
"> | "> | ||||
<view :class="'custom-nav-bar-content__content ' + (border ? 'custom-nav-bar__border-bottom' : '')"> | <view :class="'custom-nav-bar-content__content ' + (border ? 'custom-nav-bar__border-bottom' : '')"> | ||||
<view class="custom-nav-bar-content__left" @click="onClickLeft"> | <view class="custom-nav-bar-content__left" @click="onClickLeft"> | ||||
@@ -14,26 +14,35 @@ import env from './env'; | |||||
import amap from "@/lib/wx-map-sdk/amap-wx.130.js"; | import amap from "@/lib/wx-map-sdk/amap-wx.130.js"; | ||||
function getLocationInfo() { | function getLocationInfo() { | ||||
const info = {}; | const info = {}; | ||||
uni.getLocation(function(res) { | |||||
console.log('纬度:' + res.latitude); | |||||
console.log('经度:' + res.longitude); | |||||
}); | |||||
const myAmapFun = new amap.AMapWX({ | |||||
key: env.aMapKey | |||||
}); | |||||
myAmapFun.getRegeo({ | |||||
success: function (res) { | |||||
if (!res.length) { | |||||
return; | |||||
} | |||||
Object.assign(info, res[0]); | |||||
}, | |||||
fail: function (info) { | |||||
uni.showModal({ | |||||
title: info.errMsg | |||||
}); | |||||
} | |||||
}); | |||||
// uni.getLocation(function(res) { | |||||
// console.log('纬度:' + res.latitude); | |||||
// console.log('经度:' + res.longitude); | |||||
// }); | |||||
uni.request({ | |||||
url: 'https://www.cz88.net/api/cz88/ip/base?ip=', | |||||
success: (res) => { | |||||
console.log(res.data.data.locations); | |||||
let latitudObj = res.data.data.locations[0] | |||||
// this.text = 'request success'; | |||||
uni.setStorageSync('userLocation', latitudObj.latitude + ',' + latitudObj.longitude) | |||||
} | |||||
}) | |||||
// const myAmapFun = new amap.AMapWX({ | |||||
// key: env.aMapKey | |||||
// }); | |||||
// myAmapFun.getRegeo({ | |||||
// success: function (res) { | |||||
// if (!res.length) { | |||||
// return; | |||||
// } | |||||
// Object.assign(info, res[0]); | |||||
// }, | |||||
// fail: function (info) { | |||||
// uni.showModal({ | |||||
// title: info.errMsg | |||||
// }); | |||||
// } | |||||
// }); | |||||
return info; | return info; | ||||
} | } | ||||
export default { | export default { | ||||
@@ -1,12 +1,12 @@ | |||||
<template> | <template> | ||||
<view> | <view> | ||||
<custom-nav-bar position="fixed" color="black" :left-text="optin.name" left-arrow /> | |||||
<custom-nav-bar color="black" :left-text="optin.name" left-arrow /> | |||||
<view class="search"> | <view class="search"> | ||||
<view class="flex flex-between search-input"> | <view class="flex flex-between search-input"> | ||||
<input class="input" :value="searchValue" type="text" confirm-type="search" | <input class="input" :value="searchValue" type="text" confirm-type="search" | ||||
placeholder-class="placeholder-style" placeholder="请输入搜索商户名称" @input="onSearch" @confirm="onChange" /> | placeholder-class="placeholder-style" placeholder="请输入搜索商户名称" @input="onSearch" @confirm="onChange" /> | ||||
<view class="search-icon flex flex-center"> | |||||
<view class="search-icon flex flex-center" @click="onSearch"> | |||||
<image class="imgage" src="/static/images/search.png"></image> | <image class="imgage" src="/static/images/search.png"></image> | ||||
</view> | </view> | ||||
</view> | </view> | ||||
@@ -3,11 +3,11 @@ | |||||
<custom-nav-bar position="fixed" color="black" left-text="我的收藏" left-arrow /> | <custom-nav-bar position="fixed" color="black" left-text="我的收藏" left-arrow /> | ||||
<view class="life-section"> | <view class="life-section"> | ||||
<van-tabs :active="tabs.active" @change="onChange($event, { tagId: 'collectionTabs' })" id="collectionTabs" | |||||
<van-tabs :active="tabs.active" @click-tab="onChange($event, { tagId: 'collectionTabs' })" id="collectionTabs" | |||||
line-width="40px"> | line-width="40px"> | ||||
<van-tab :title="key.label" :data-item="key" v-for="(key, index) in tabs.typeList" :key="index"> | |||||
<view> | |||||
<view v-if="myInfoPageList.length !== 0" class="life-conent" @tap="headleDetails" :data-item="item" | |||||
<van-tab :title="key.label" :name="key.value" :data-item="key" v-for="(key, index) in tabs.typeList" :key="index"> | |||||
<view v-if="myInfoPageList.length !== 0"> | |||||
<view class="life-conent" @tap="headleDetails" :data-item="item" | |||||
v-for="(item, index1) in myInfoPageList" :key="index1"> | v-for="(item, index1) in myInfoPageList" :key="index1"> | ||||
<image class="life-conent-image" :src="item.merchantPhoto"></image> | <image class="life-conent-image" :src="item.merchantPhoto"></image> | ||||
@@ -92,15 +92,16 @@ | |||||
onChange(event, _dataset) { | onChange(event, _dataset) { | ||||
/* ---处理dataset begin--- */ | /* ---处理dataset begin--- */ | ||||
this.handleDataset(event, _dataset); | |||||
// this.handleDataset(event, _dataset); | |||||
/* ---处理dataset end--- */ | /* ---处理dataset end--- */ | ||||
console.log(event) | |||||
const { | const { | ||||
typeList | typeList | ||||
} = this.tabs; | } = this.tabs; | ||||
this.tabs = { | this.tabs = { | ||||
typeList: typeList, | typeList: typeList, | ||||
active: event.detail.index, | |||||
merchantType: typeList[event.detail.name].value | |||||
active: event.name, | |||||
merchantType: typeList[event.name].value | |||||
} | } | ||||
this.myInfoPageApi(); | this.myInfoPageApi(); | ||||
}, | }, | ||||
@@ -1,5 +1,5 @@ | |||||
<strong></strong><template> | |||||
<view style="height: 100%"> | |||||
<template> | |||||
<view> | |||||
<custom-nav-bar position="fixed" color="black" left-text="设置" left-arrow /> | <custom-nav-bar position="fixed" color="black" left-text="设置" left-arrow /> | ||||
<view class="page-content"> | <view class="page-content"> | ||||
@@ -82,9 +82,7 @@ | |||||
}, | }, | ||||
async onLoad() {}, | async onLoad() {}, | ||||
onShow() { | onShow() { | ||||
this.setData({ | |||||
userInfo: uni.getStorageSync('userInfoData') | |||||
}); | |||||
this.userInfo = uni.getStorageSync('userInfoData') | |||||
}, | }, | ||||
methods: { | methods: { | ||||
signOut() { | signOut() { | ||||
@@ -55,7 +55,7 @@ | |||||
<view class="section-item-left flex1 flex flex-between flex-col"> | <view class="section-item-left flex1 flex flex-between flex-col"> | ||||
<view class="consult-content-title text-line-1">{{ item.title }}</view> | <view class="consult-content-title text-line-1">{{ item.title }}</view> | ||||
<view class="consult-content-block"> | <view class="consult-content-block"> | ||||
<!-- <text>{{ toods.getDateTime(item.createTime) }}</text> --> | |||||
<text>{{ getDateTime(item.createTime) }}</text> | |||||
<text class="ml-30">{{ item.publisher }}</text> | <text class="ml-30">{{ item.publisher }}</text> | ||||
</view> | </view> | ||||
</view> | </view> | ||||
@@ -87,7 +87,7 @@ | |||||
<view class="section-item-left flex1 flex flex-between flex-col"> | <view class="section-item-left flex1 flex flex-between flex-col"> | ||||
<view class="consult-content-title multi-line">{{ item.title }}</view> | <view class="consult-content-title multi-line">{{ item.title }}</view> | ||||
<view class="consult-content-block"> | <view class="consult-content-block"> | ||||
<text>{{ toods.getDateTime(item.createTime) }}</text> | |||||
<text>{{ getDateTime(item.createTime) }}</text> | |||||
<text class="ml-30">{{ item.publisher }}</text> | <text class="ml-30">{{ item.publisher }}</text> | ||||
</view> | </view> | ||||
</view> | </view> | ||||
@@ -122,7 +122,8 @@ | |||||
import * as peopleApi from '@/api/peopleApi'; | import * as peopleApi from '@/api/peopleApi'; | ||||
import * as publicApi from '@/api/publicApi'; | import * as publicApi from '@/api/publicApi'; | ||||
import * as enterprise from '@/api/enterprise'; | import * as enterprise from '@/api/enterprise'; | ||||
import utils from '@/utils/util.js' | |||||
import utils from '@/utils/util.map' | |||||
import util from '@/utils/util' | |||||
// 民生 - 家庭医生列表 / 党建引领 复用 | // 民生 - 家庭医生列表 / 党建引领 复用 | ||||
export default { | export default { | ||||
@@ -169,6 +170,10 @@ | |||||
updateQuery(url, name) { | updateQuery(url, name) { | ||||
return utils.updateQuery(url, name); | return utils.updateQuery(url, name); | ||||
}, | }, | ||||
getDateTime(tiem){ | |||||
console.log(time) | |||||
return utils.getDateTime(tiem) | |||||
}, | |||||
/** | /** | ||||
* 接口 | * 接口 | ||||
*/ | */ | ||||
@@ -232,7 +237,7 @@ | |||||
} = await peopleApi.hospitalPageApi(param); | } = await peopleApi.hospitalPageApi(param); | ||||
if (list.length) { | if (list.length) { | ||||
list.forEach((e) => { | list.forEach((e) => { | ||||
e.createTime = utils.timeFormat(e.createTime, 'yyyy-mm-ss'); | |||||
e.createTime = util.timeFormat(e.createTime, 'yyyy-mm-ss'); | |||||
}); | }); | ||||
this.newsPageList = list | this.newsPageList = list | ||||
} | } | ||||
@@ -308,7 +313,6 @@ | |||||
const { | const { | ||||
list = [], total = 0 | list = [], total = 0 | ||||
} = res.data; | } = res.data; | ||||
console.log(list) | |||||
if (reset) { | if (reset) { | ||||
_goodsList = list; | _goodsList = list; | ||||
} else { | } else { | ||||
@@ -375,7 +379,6 @@ | |||||
item | item | ||||
} = event.currentTarget.dataset; | } = event.currentTarget.dataset; | ||||
let orgId = event.currentTarget.dataset.item.orgId; | let orgId = event.currentTarget.dataset.item.orgId; | ||||
console.log(item); | |||||
uni.navigateTo({ | uni.navigateTo({ | ||||
url: `/packages/people/pages/second/second-community?name=${name}&key=${key}&orgId=${orgId}&gridId=${item.id}` | url: `/packages/people/pages/second/second-community?name=${name}&key=${key}&orgId=${orgId}&gridId=${item.id}` | ||||
}); | }); | ||||
@@ -1,6 +1,6 @@ | |||||
<template> | <template> | ||||
<view> | <view> | ||||
<custom-nav-bar position="absolute" color="black" :left-text="optins.name" left-arrow /> | |||||
<custom-nav-bar position="fixed" color="black" :left-text="optins.name" left-arrow /> | |||||
<web-view v-if="optins.name === '手机充值' || optins.name === '生活缴费'" :src="url"></web-view> | <web-view v-if="optins.name === '手机充值' || optins.name === '生活缴费'" :src="url"></web-view> | ||||
<image v-else class="img" mode="aspectFit" src="/static/packages/public/pages/web-view/img.jpg" | <image v-else class="img" mode="aspectFit" src="/static/packages/public/pages/web-view/img.jpg" | ||||
@@ -33,7 +33,9 @@ | |||||
}, | }, | ||||
{ | { | ||||
"path": "pages/phone/index", | "path": "pages/phone/index", | ||||
"style": {} | |||||
"style": { | |||||
"navigationStyle": "custom" | |||||
} | |||||
}, | }, | ||||
{ | { | ||||
"path": "pages/agreement/user-agreement", | "path": "pages/agreement/user-agreement", | ||||
@@ -220,7 +220,7 @@ export default { | |||||
} = this; | } = this; | ||||
if (!isLogin) { | if (!isLogin) { | ||||
uni.navigateTo({ | uni.navigateTo({ | ||||
url: '/pages/authorize/authorize' | |||||
url: '/pages/phone/index' | |||||
}); | }); | ||||
return false; | return false; | ||||
} | } | ||||
@@ -6,7 +6,7 @@ | |||||
:indicator-active-color="indicatorActiveColor"> | :indicator-active-color="indicatorActiveColor"> | ||||
<block v-for="(item, index) in imageList" :key="index"> | <block v-for="(item, index) in imageList" :key="index"> | ||||
<swiper-item> | <swiper-item> | ||||
<navigator v-if="item.clickUrl" class="line-navigator" :url="updateQuery(itemName.clickUrl,item)" hover-class="none"></navigator> | |||||
<navigator v-if="item.clickUrl" class="line-navigator" :url="updateQuery(itemName.clickUrl,itemName)" hover-class="none"></navigator> | |||||
<image class="custom-swiper-img" :src="item.pic"></image> | <image class="custom-swiper-img" :src="item.pic"></image> | ||||
</swiper-item> | </swiper-item> | ||||
</block> | </block> | ||||
@@ -20,7 +20,7 @@ | |||||
<view class="menu flex flex-v-center flex-between" v-if="index === 0"> | <view class="menu flex flex-v-center flex-between" v-if="index === 0"> | ||||
<view class="menu-item" :style="itemName.cssStyle" v-for="(itemName, idx) in item.children" :key="idx"> | <view class="menu-item" :style="itemName.cssStyle" v-for="(itemName, idx) in item.children" :key="idx"> | ||||
<navigator v-if="itemName.clickUrl" class="line-navigator" :url="updateQuery(itemName.clickUrl,item)" hover-class="none"> | |||||
<navigator v-if="itemName.clickUrl" class="line-navigator" :url="updateQuery(itemName.clickUrl,itemName)" hover-class="none"> | |||||
</navigator> | </navigator> | ||||
<image class="menu-item-ic-img" :src="itemName.icon"></image> | <image class="menu-item-ic-img" :src="itemName.icon"></image> | ||||
@@ -32,7 +32,7 @@ | |||||
<view class="second-model flex flex-v-center flex-between" v-else> | <view class="second-model flex flex-v-center flex-between" v-else> | ||||
<view :class="'second-line flex flex-col ' + (idx === 0 ? 'line1' : '')" :style="itemName.cssStyle" | <view :class="'second-line flex flex-col ' + (idx === 0 ? 'line1' : '')" :style="itemName.cssStyle" | ||||
v-for="(itemName, idx) in item.children" :key="idx"> | v-for="(itemName, idx) in item.children" :key="idx"> | ||||
<navigator v-if="itemName.clickUrl" class="line-navigator" :url="updateQuery(itemName.clickUrl,item)" hover-class="none"> | |||||
<navigator v-if="itemName.clickUrl" class="line-navigator" :url="updateQuery(itemName.clickUrl,itemName)" hover-class="none"> | |||||
</navigator> | </navigator> | ||||
<!-- <image ></image> --> | <!-- <image ></image> --> | ||||
<image class="line-bg" :src="itemName.icon"></image> | <image class="line-bg" :src="itemName.icon"></image> | ||||
@@ -17,7 +17,7 @@ | |||||
<view class="name" @tap="login" v-else>请登录</view> | <view class="name" @tap="login" v-else>请登录</view> | ||||
<!-- <view class="role" wx:if="{{role}}">{{role}}</view> --> | <!-- <view class="role" wx:if="{{role}}">{{role}}</view> --> | ||||
</view> | </view> | ||||
<image class="top-right" @tap="toSetup" | |||||
<image class="top-right" @click="toSetup" | |||||
src="https://zongzhi.xuqidata.com:5009/xq-ssg/bc0a28c4073688213c2dbf320d21d24048fab2f9a36d2afec51e831591e58188.png"> | src="https://zongzhi.xuqidata.com:5009/xq-ssg/bc0a28c4073688213c2dbf320d21d24048fab2f9a36d2afec51e831591e58188.png"> | ||||
</image> | </image> | ||||
</view> | </view> | ||||
@@ -294,21 +294,22 @@ | |||||
* 接口 | * 接口 | ||||
*/ | */ | ||||
async login() { | async login() { | ||||
// 我的诉求 | |||||
const res = await app.globalData.register({ | |||||
code: this.code | |||||
}); | |||||
if (res) { | |||||
uni.showToast({ | |||||
title: '登录成功', | |||||
icon: 'none' | |||||
}); | |||||
this.getInitData(); | |||||
} else { | |||||
uni.navigateTo({ | |||||
uni.navigateTo({ | |||||
url: '/pages/phone/index' | url: '/pages/phone/index' | ||||
}); | |||||
} | |||||
}); | |||||
// 我的诉求 | |||||
// const res = await app.globalData.register({ | |||||
// code: this.code | |||||
// }); | |||||
// if (res) { | |||||
// uni.showToast({ | |||||
// title: '登录成功', | |||||
// icon: 'none' | |||||
// }); | |||||
// this.getInitData(); | |||||
// } else { | |||||
// } | |||||
}, | }, | ||||
// 获取我的信息 | // 获取我的信息 | ||||
@@ -1,5 +1,7 @@ | |||||
<template> | <template> | ||||
<view style="height: 100%"> | |||||
<view> | |||||
<custom-nav-bar left-text="登陆" left-arrow /> | |||||
<view | <view | ||||
class="container" | class="container" | ||||
style=" | style=" | ||||
@@ -194,6 +196,7 @@ export default { | |||||
}) | }) | ||||
uni.setStorageSync("userId", res.data.userId); | uni.setStorageSync("userId", res.data.userId); | ||||
uni.setStorageSync("token", res.data.accessToken); | uni.setStorageSync("token", res.data.accessToken); | ||||
uni.setStorageSync("isLogin", true); | |||||
uni.switchTab({ | uni.switchTab({ | ||||
url: "/pages/my/my", | url: "/pages/my/my", | ||||
}); | }); | ||||
@@ -306,7 +309,7 @@ export default { | |||||
.add-commutnity { | .add-commutnity { | ||||
position: absolute; | position: absolute; | ||||
top: 35%; | |||||
top: 45%; | |||||
left: 0; | left: 0; | ||||
} | } | ||||