已添加37个文件
已删除1个文件
已修改42个文件
¶Ô±ÈÐÂÎļþ |
| | |
| | | import { request } from '../utils/request' |
| | | import { baseUrl } from '../utils/config' |
| | | |
| | | export const uploadUrl = baseUrl + '/public/upload' |
| | | // å°ç¨åºç»å½ |
| | | export const wxLoginCustomer = (data) => { |
| | | return request({ |
| | | url: '/web/customer/wxLoginCustomer', |
| | | data |
| | | }) |
| | | } |
| | | // è·åææºå· |
| | | export const getWxMiniPhone = (data) => { |
| | | return request({ |
| | | url: '/web/customer/getWxMiniPhone', |
| | | method: "POST", |
| | | data |
| | | }) |
| | | } |
| | | // è·ååå
¸å¼ |
| | | export const getDictData = (data) => { |
| | | return request({ |
| | | url: '/public/getDictData', |
| | | data, |
| | | loading: '0' |
| | | }) |
| | | } |
| | | // è·åä¼åä¿¡æ¯ |
| | | export const getMemberInfo = () => { |
| | | return request({ |
| | | url: '/web/customer/getMemberInfo', |
| | | }) |
| | | } |
| | | // è·åé¨åºå表 |
| | | export const getShopPage = (data) => { |
| | | return request({ |
| | | url: '/web/customer/shopPage', |
| | | method: 'POST', |
| | | data |
| | | }) |
| | | } |
| | | // è·åé¨åºè¯¦æ
|
| | | export const getShopDetail = (data) => { |
| | | return request({ |
| | | url: '/web/customer/shopDetail', |
| | | data |
| | | }) |
| | | } |
| | | // æ´æ°ä¼åä¿¡æ¯ |
| | | export const editMember = (data) => { |
| | | return request({ |
| | | url: '/web/customer/editMember', |
| | | method: 'POST', |
| | | data |
| | | }) |
| | | } |
| | | |
| | | // 0å
å®å¶ä¿¡æ¯ |
| | | export const saveFreeCustomizationApply = (data) => { |
| | | return request({ |
| | | url: '/web/customer/saveFreeCustomizationApply', |
| | | method: 'POST', |
| | | data |
| | | }) |
| | | } |
| | | // è·å计ç®å¨é
ç½® |
| | | export const getBjParamConfig = (data) => { |
| | | return request({ |
| | | url: '/web/customer/getBjParamConfig', |
| | | data |
| | | }) |
| | | } |
| | | // ä¿å计ç®å¨é
ç½® |
| | | export const saveRenovationCalculator = (data) => { |
| | | return request({ |
| | | url: '/web/customer/saveRenovationCalculator', |
| | | method: 'POST', |
| | | data |
| | | }) |
| | | } |
| | | // è·åçå¸åº |
| | | export const getArea = (data) => { |
| | | return request({ |
| | | url: '/web/common/getArea', |
| | | data |
| | | }) |
| | | } |
| | | // å°ç¨åºæ³¨é |
| | | export const wxLogOff = (data) => { |
| | | return request({ |
| | | url: '/web/customer/logOff', |
| | | data |
| | | }) |
| | | } |
| | |
| | | // app.js |
| | | import { wxLoginCustomer } from './api/index' |
| | | App({ |
| | | globalData: { |
| | | primary: '#B08771', |
| | |
| | | if (WindowInfo.safeArea.top > 20) { |
| | | this.globalData.bottomLift = WindowInfo.screenHeight - WindowInfo.safeArea.bottom; |
| | | } |
| | | // |
| | | const res = wx.getStorageSync('member') |
| | | if (res) { |
| | | this.globalData.userInfo = res |
| | | } else { |
| | | // ç»å½ |
| | | wx.login({ |
| | | timeout: 5000, |
| | | success(res) { |
| | | if (res.code) { |
| | | //åèµ·ç½ç»è¯·æ± |
| | | wxLoginCustomer({ |
| | | code: res.code |
| | | }).then(res => { |
| | | console.log(res) |
| | | if (res && res.data.member) { |
| | | wx.setStorageSync('member', res.data.member) |
| | | wx.setStorageSync('openid', res.data.member.openid) |
| | | wx.setStorageSync('sessionKey', res.data.sessionKey) |
| | | wx.setStorageSync('token', res.data.token) |
| | | } else { |
| | | console.log('ç»å½å¤±è´¥ï¼') |
| | | } |
| | | }) |
| | | } else { |
| | | console.log('ç»å½å¤±è´¥ï¼' + res) |
| | | } |
| | | }, |
| | | fail(err) { |
| | | console.log(err) |
| | | } |
| | | }) |
| | | } |
| | | } |
| | | }) |
| | | }) |
| | |
| | | "pages/store/staffList", |
| | | "pages/calculator/index", |
| | | "pages/webView/index", |
| | | "pages/productVideo/index", |
| | | "pages/homeId/index", |
| | | "pages/kefu/index", |
| | | "pages/detailDis/product", |
| | | "pages/detailDis/case", |
| | | "pages/detailDis/realpic", |
| | |
| | | }, |
| | | "requiredPrivateInfos": [ |
| | | "getLocation", |
| | | "chooseLocation" |
| | | "chooseLocation", |
| | | "getFuzzyLocation" |
| | | ], |
| | | "permission": { |
| | | "scope.userLocation": { |
| | |
| | | // components/authCard/authCard.js |
| | | import { getShopPage } from '../../api/index' |
| | | Component({ |
| | | /** |
| | | * ç»ä»¶ç屿§å表 |
| | |
| | | properties: { |
| | | type: { // 屿§å |
| | | type: String, |
| | | value: '0' |
| | | value: '0', |
| | | observer(val) { |
| | | if(val === '1'){ |
| | | this.getShops() |
| | | } |
| | | } |
| | | }, |
| | | }, |
| | | |
| | | /** |
| | | * ç»ä»¶çåå§æ°æ® |
| | | */ |
| | | data: { |
| | | |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * ç»ä»¶çæ¹æ³å表 |
| | | */ |
| | | methods: { |
| | | |
| | | getShops() { |
| | | getShopPage() |
| | | }, |
| | | jumpStore() { |
| | | wx.navigateTo({ |
| | | url: '/pages/store/store', |
| | | }) |
| | | } |
| | | } |
| | | }) |
| | |
| | | background: #B08771; |
| | | border-radius: 0rpx 8rpx 8rpx 0rpx; |
| | | } |
| | | } |
| | | .wrap2{ |
| | | .header{ |
| | | display: flex; |
| | | align-items: center; |
| | | .left{ |
| | | flex: 1; |
| | | .name{ |
| | | display: flex; |
| | | align-items: center; |
| | | font-weight: 600; |
| | | font-size: 36rpx; |
| | | .icon{ |
| | | width: 36rpx; |
| | | margin-right: 12rpx; |
| | | |
| | | } |
| | | } |
| | | .desc{ |
| | | margin-top: 10rpx; |
| | | font-weight: 300; |
| | | font-size: 26rpx; |
| | | color: #333333; |
| | | } |
| | | } |
| | | .right{ |
| | | width: 16rpx; |
| | | } |
| | | } |
| | | .list{ |
| | | padding: 40rpx 8rpx; |
| | | display: flex; |
| | | width: 710rpx; |
| | | overflow: auto; |
| | | .item{ |
| | | flex-shrink: 0; |
| | | width: 305rpx; |
| | | height: 184rpx; |
| | | background: rgba(176,135,113,0.05) #FFFFFF; |
| | | box-shadow: 0rpx 4rpx 12rpx 0rpx rgba(0,0,0,0.12); |
| | | border-radius: 8rpx; |
| | | padding: 20rpx; |
| | | margin-right: 20rpx; |
| | | .name{ |
| | | display: flex; |
| | | margin-bottom: 20rpx; |
| | | .icon{ |
| | | width: 60rpx; |
| | | height: 60rpx; |
| | | background: rgba(176,135,113,0.14); |
| | | border-radius: 50%; |
| | | display: flex; |
| | | justify-content: center; |
| | | align-items: center; |
| | | margin-right: 20rpx; |
| | | image{ |
| | | width: 36rpx; |
| | | } |
| | | } |
| | | } |
| | | .addr{ |
| | | display: flex; |
| | | justify-content: space-between; |
| | | align-items: center; |
| | | .left{ |
| | | display: flex; |
| | | align-items: center; |
| | | font-size: 24rpx; |
| | | color: #999999; |
| | | .icon{ |
| | | width: 24rpx; |
| | | } |
| | | } |
| | | .right{ |
| | | display: flex; |
| | | align-items: center; |
| | | color: #B08771; |
| | | font-size: 26rpx; |
| | | } |
| | | } |
| | | } |
| | | } |
| | | } |
| | | .wrap3{ |
| | | display: flex; |
| | | box-shadow: 0rpx 4rpx 16rpx 0rpx rgba(176,135,113,0.2); |
| | | border-radius: 8rpx; |
| | | padding: 30rpx; |
| | | height: 140rpx; |
| | | .ai{ |
| | | image{ |
| | | width: 40rpx; |
| | | height: 40rpx; |
| | | } |
| | | } |
| | | } |
| | |
| | | </view> |
| | | <!-- å·²ææ --> |
| | | <view wx:if="{{ type == '1' }}" class="wrap2"> |
| | | |
| | | <view class="header" bindtap="jumpStore"> |
| | | <view class="left"> |
| | | <view class="name"> |
| | | <image class="icon" src="../../static/icon/home_ic_zhutihuodong@2x.png" mode="widthFix"></image> |
| | | <text>éè¿é¨åº</text> |
| | | </view> |
| | | <view class="desc">æ¨èº«è¾¹çå
¨å±è®¾è®¡ä¸å®¶ï½</view> |
| | | </view> |
| | | <image class="right" src="../../static/icon/arrow_right.png" mode="widthFix"></image> |
| | | |
| | | </view> |
| | | <view class="list"> |
| | | <view class="item" wx:for="{{6}}"> |
| | | <view class="name"> |
| | | <view class="icon"> |
| | | <image src="../../static/icon/mendian_item.png" mode="widthFix"></image> |
| | | </view> |
| | | <text>åè¥çº¢ææ°åå
³</text> |
| | | </view> |
| | | <view class="addr"> |
| | | <view class="left"> |
| | | <image class="icon" src="../../static/icon/location.png" mode="widthFix"></image> |
| | | <text>3.9km</text> |
| | | </view> |
| | | <view class="right"> |
| | | <text>è¿å
¥é¨åº</text> |
| | | <van-icon name="arrow" /> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | <!-- å·²ææ å·²ç»å® --> |
| | | </view> |
| | | <view wx:if="{{ type == '2' }}" class="wrap1 wrap3"> |
| | | <view class="ai df_ct"> |
| | | <image src="../../static/icon/home_ic_guwen@2x.png" mode="widthFix"></image> |
| | | </view> |
| | | <view class="content"> |
| | | <view class="name">æ¨çä¸å±å®¶å±
顾é®</view> |
| | | <view class="desc">æ¨èº«è¾¹çå
¨å±è®¾è®¡ä¸å®¶</view> |
| | | </view> |
| | | <view class="btn"> |
| | | <view>å»</view> |
| | | <view>ç</view> |
| | | <view>ç</view> |
| | | </view> |
| | | </view> |
| | | </view> |
| | |
| | | background: #B08771; |
| | | border-radius: 0rpx 8rpx 8rpx 0rpx; |
| | | } |
| | | .wrap2 .header { |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | .wrap2 .header .left { |
| | | flex: 1; |
| | | } |
| | | .wrap2 .header .left .name { |
| | | display: flex; |
| | | align-items: center; |
| | | font-weight: 600; |
| | | font-size: 36rpx; |
| | | } |
| | | .wrap2 .header .left .name .icon { |
| | | width: 36rpx; |
| | | margin-right: 12rpx; |
| | | } |
| | | .wrap2 .header .left .desc { |
| | | margin-top: 10rpx; |
| | | font-weight: 300; |
| | | font-size: 26rpx; |
| | | color: #333333; |
| | | } |
| | | .wrap2 .header .right { |
| | | width: 16rpx; |
| | | } |
| | | .wrap2 .list { |
| | | padding: 40rpx 8rpx; |
| | | display: flex; |
| | | width: 710rpx; |
| | | overflow: auto; |
| | | } |
| | | .wrap2 .list .item { |
| | | flex-shrink: 0; |
| | | width: 305rpx; |
| | | height: 184rpx; |
| | | background: rgba(176, 135, 113, 0.05) #FFFFFF; |
| | | box-shadow: 0rpx 4rpx 12rpx 0rpx rgba(0, 0, 0, 0.12); |
| | | border-radius: 8rpx; |
| | | padding: 20rpx; |
| | | margin-right: 20rpx; |
| | | } |
| | | .wrap2 .list .item .name { |
| | | display: flex; |
| | | margin-bottom: 20rpx; |
| | | } |
| | | .wrap2 .list .item .name .icon { |
| | | width: 60rpx; |
| | | height: 60rpx; |
| | | background: rgba(176, 135, 113, 0.14); |
| | | border-radius: 50%; |
| | | display: flex; |
| | | justify-content: center; |
| | | align-items: center; |
| | | margin-right: 20rpx; |
| | | } |
| | | .wrap2 .list .item .name .icon image { |
| | | width: 36rpx; |
| | | } |
| | | .wrap2 .list .item .addr { |
| | | display: flex; |
| | | justify-content: space-between; |
| | | align-items: center; |
| | | } |
| | | .wrap2 .list .item .addr .left { |
| | | display: flex; |
| | | align-items: center; |
| | | font-size: 24rpx; |
| | | color: #999999; |
| | | } |
| | | .wrap2 .list .item .addr .left .icon { |
| | | width: 24rpx; |
| | | } |
| | | .wrap2 .list .item .addr .right { |
| | | display: flex; |
| | | align-items: center; |
| | | color: #B08771; |
| | | font-size: 26rpx; |
| | | } |
| | | .wrap3 { |
| | | display: flex; |
| | | box-shadow: 0rpx 4rpx 16rpx 0rpx rgba(176, 135, 113, 0.2); |
| | | border-radius: 8rpx; |
| | | padding: 30rpx; |
| | | height: 140rpx; |
| | | } |
| | | .wrap3 .ai image { |
| | | width: 40rpx; |
| | | height: 40rpx; |
| | | } |
| | |
| | | // pages/auth/auth.js |
| | | import { |
| | | wxLoginCustomer, |
| | | getDictData, |
| | | getWxMiniPhone |
| | | } from '../../api/index' |
| | | Page({ |
| | | |
| | | /** |
| | |
| | | */ |
| | | data: { |
| | | agreementFalg: false, |
| | | primary: '' |
| | | }, |
| | | primary: '', |
| | | |
| | | showModal: false, |
| | | serviceHtml: '', |
| | | title: '', |
| | | privacyHtml: '', |
| | | activeHtml: '' |
| | | }, |
| | | initData(){ |
| | | getDictData({ |
| | | code: 'ZBOM_CUSTOMIZED', |
| | | label: 'SERVER_AGREEMENT' |
| | | }).then(res => { |
| | | this.setData({ |
| | | serviceHtml: res.data.code |
| | | }) |
| | | }) |
| | | getDictData({ |
| | | code: 'ZBOM_CUSTOMIZED', |
| | | label: 'PRIVACY_AGREEMENT' |
| | | }).then(res => { |
| | | this.setData({ |
| | | privacyHtml: res.data.code |
| | | }) |
| | | }) |
| | | }, |
| | | getPhoneNumber (e) { |
| | | console.log(e.detail) |
| | | console.log(e.detail.iv) |
| | | console.log(e.detail.encryptedData) |
| | | const data = { ...e.detail } |
| | | getWxMiniPhone({ |
| | | encryptedData: data.encryptedData, |
| | | iv: data.iv, |
| | | sessionKey: wx.getStorageSync('sessionKey'), |
| | | }) |
| | | }, |
| | | loginIn() { |
| | | const { agreementFalg } = this.data |
| | | if(!agreementFalg) return wx.showToast({ |
| | | title: '请å
é
读并åæç¸å
³åè®®', |
| | | icon: 'none', |
| | | duration: 2000 |
| | | }) |
| | | wx.login({ |
| | | success: (res) => { |
| | | if (res.code) { |
| | | // è·åå°ç¨æ·ç»å½åè¯ code |
| | | const code = res.code; |
| | | wx.setStorageSync('code', res.code) |
| | | // å° code åéç»å端æå¡å¨ |
| | | wxLoginCustomer({code}).then(ress => { |
| | | wx.setStorageSync('token', ress.data.token) |
| | | wx.setStorageSync('member', ress.data.member) |
| | | wx.redirectTo({ |
| | | url: '/pages/index/index', |
| | | }) |
| | | }) |
| | | } else { |
| | | console.error('è·åç¨æ·ç»å½åè¯å¤±è´¥', res.errMsg); |
| | | } |
| | | }, |
| | | fail: (err) => { |
| | | console.error('è°ç¨ wx.login 失败', err); |
| | | }, |
| | | }) |
| | | }, |
| | | onOpen(e){ |
| | | console.log('e', e); |
| | | const { serviceHtml, privacyHtml } = this.data |
| | | const { index } = e.target.dataset |
| | | let activeHtml = index == '0' ? serviceHtml : privacyHtml |
| | | this.setData({ |
| | | activeHtml, |
| | | showModal: true |
| | | }) |
| | | }, |
| | | onClose(){ |
| | | this.setData({showModal: false}) |
| | | }, |
| | | agreementChange(e) { |
| | | this.setData({ |
| | | agreementFalg: e.detail, |
| | |
| | | this.setData({ |
| | | primary: app.primary |
| | | }) |
| | | this.initData() |
| | | }, |
| | | |
| | | /** |
| | |
| | | { |
| | | "usingComponents": { |
| | | "van-nav-bar": "@vant/weapp/nav-bar/index", |
| | | "van-checkbox": "@vant/weapp/checkbox/index" |
| | | } |
| | | "van-checkbox": "@vant/weapp/checkbox/index", |
| | | "van-popup": "@vant/weapp/popup/index" |
| | | }, |
| | | "navigationBarTitleText": "ææç»å½" |
| | | } |
| | |
| | | font-size: 30rpx; |
| | | } |
| | | } |
| | | .modal{ |
| | | width: 600rpx; |
| | | min-height: 600rpx; |
| | | padding: 30rpx; |
| | | } |
| | | .title{ |
| | | font-weight: 600; |
| | | font-size: 44rpx; |
| | |
| | | <view> |
| | | <van-nav-bar title="ææç»å½"> |
| | | <view slot="left"> |
| | | <van-icon name="arrow-left" size="22px" color="#000000" /> |
| | | </view> |
| | | </van-nav-bar> |
| | | <view class="container"> |
| | | <view class="logo_wrap"> |
| | | <image src="../../static/icon/logo.png"></image> |
| | | </view> |
| | | <view class="title">æ¬¢è¿æ¥å°å¿é¦å®¶å±
éå¿é¦ï¼å®ç°æ¨å¯¹å®¶çç¾å¥½æ³è±¡</view> |
| | | <view class="placeholder9">æ¨åæ¬¢çæ ·åï¼æé½æï½</view> |
| | | <view>{{ test }}</view> |
| | | <view class="main_footer"> |
| | | <view class="line"> |
| | | <van-checkbox value="{{ agreementFalg }}" checked-color="{{primary}}" shape="round" bind:change="agreementChange"></van-checkbox> |
| | | <view class="content"> |
| | | <text>æå·²é
读并åæ</text> |
| | | <text class="primary">ãZBOMç¨æ·æå¡åè®®ã</text> |
| | | <text data-index="0" bindtap="onOpen" class="primary">ãZBOMç¨æ·æå¡åè®®ã</text> |
| | | <text>å</text> |
| | | <text class="primary">ãZBOMç¨æ·éç§æ¿çã</text> |
| | | <text data-index="1" bindtap="onOpen" class="primary">ãZBOMç¨æ·éç§æ¿çã</text> |
| | | </view> |
| | | </view> |
| | | <view class="btn">ææºå·å¿«æ·ç»å½</view> |
| | | <button class="btn" open-type="getPhoneNumber" bindgetphonenumber="getPhoneNumber">ææºå·å¿«æ·ç»å½</button> |
| | | </view> |
| | | </view> |
| | | <!-- --> |
| | | <van-popup show="{{ showModal }}" round bind:close="onClose"> |
| | | <view class="modal"> |
| | | <rich-text nodes="{{activeHtml}}"></rich-text> |
| | | </view> |
| | | </van-popup> |
| | | </view> |
| | |
| | | font-weight: 500; |
| | | font-size: 30rpx; |
| | | } |
| | | .modal { |
| | | width: 600rpx; |
| | | min-height: 600rpx; |
| | | padding: 30rpx; |
| | | } |
| | | .title { |
| | | font-weight: 600; |
| | | font-size: 44rpx; |
| | |
| | | // pages/calculator/index.js |
| | | // import { imageUrl } from '../../utils/config' |
| | | // import { calculatorOption, calculatorSave, decodePhone, bindPhone } from '../../api/index' |
| | | import { getBjParamConfig, saveRenovationCalculator } from '../../api/index' |
| | | // import Ls from '../../utils/storage' |
| | | // let ls = new Ls |
| | | Page({ |
| | |
| | | containerContentStyle: 'hidden;' |
| | | }, |
| | | |
| | | onLoad: function (options) { |
| | | let that = this |
| | | this.getCalculatorOption() |
| | | const userInfo = wx.getStorageSync('member') |
| | | if (userInfo.phone) { |
| | | that.setData({ userPhone: userInfo.phone }) |
| | | } |
| | | }, |
| | | // è¿åä¸ä¸é¡µ |
| | | navigateBack () { |
| | | wx.navigateBack({ |
| | |
| | | let { activePicker, pickerIndex } = this.data |
| | | this.setData({ [activePicker]: pickerIndex, showPopup: false }) |
| | | }, |
| | | |
| | | |
| | | // è·åç¨æ·ææºå· |
| | | getPhoneNumber (e) { |
| | | // console.log(e) |
| | |
| | | submit () { |
| | | // console.log('ç«å³è®¡ç®') |
| | | let { userPhone } = this.data |
| | | ls.get('userInfo').then(res => { |
| | | // console.log(res) |
| | | if (userPhone) { |
| | | let { type, info, area, money, typeArray, infoArray, calculatorOptions: options } = this.data |
| | | let submitData = {} |
| | | submitData.name = res.name |
| | | submitData.phone = res.phone |
| | | |
| | | if (type === '') { |
| | | wx.showToast({ |
| | | title: 'è¯·éæ©æ¿å±ç±»å', |
| | | icon: 'none' |
| | | }) |
| | | return false |
| | | } |
| | | if (info === '') { |
| | | wx.showToast({ |
| | | title: 'è¯·éæ©æ·åä¿¡æ¯', |
| | | icon: 'none' |
| | | }) |
| | | return false |
| | | } |
| | | if (area === '') { |
| | | wx.showToast({ |
| | | title: '请è¾å
¥æ¿å±é¢ç§¯', |
| | | icon: 'none' |
| | | }) |
| | | return false |
| | | } |
| | | if (money === '') { |
| | | wx.showToast({ |
| | | title: '请è¾å
¥è£
ä¿®é¢ç®', |
| | | icon: 'none' |
| | | }) |
| | | return false |
| | | } |
| | | |
| | | submitData = ['æ¿å±ç±»åï¼' + typeArray[type], 'æ·åä¿¡æ¯ï¼' + infoArray[info], 'æ¿å±é¢ç§¯ï¼' + area + 'ã¡', 'è£
ä¿®é¢ç®ï¼' + money + 'ä¸å
'].join('-') |
| | | for (let i in options) { |
| | | options[i].money = (money * options[i].rate / 100).toFixed(2) |
| | | let childList = options[i].childList |
| | | for(let j in childList) { |
| | | childList[j].money = (money * childList[j].rate / 100).toFixed(2) |
| | | } |
| | | } |
| | | this.setData({ calculatorOptions: options, showResultMoney: true, containerContentStyle: 'auto' }) |
| | | this.submitCalculatorResult(submitData) |
| | | const res = wx.getStorageSync('member') |
| | | |
| | | if (userPhone) { |
| | | let { type, info, area, money, typeArray, infoArray, calculatorOptions: options } = this.data |
| | | let submitData = {} |
| | | submitData.name = res.name |
| | | submitData.phone = res.phone |
| | | |
| | | if (type === '') { |
| | | wx.showToast({ |
| | | title: 'è¯·éæ©æ¿å±ç±»å', |
| | | icon: 'none' |
| | | }) |
| | | return false |
| | | } |
| | | if (info === '') { |
| | | wx.showToast({ |
| | | title: 'è¯·éæ©æ·åä¿¡æ¯', |
| | | icon: 'none' |
| | | }) |
| | | return false |
| | | } |
| | | if (area === '') { |
| | | wx.showToast({ |
| | | title: '请è¾å
¥æ¿å±é¢ç§¯', |
| | | icon: 'none' |
| | | }) |
| | | return false |
| | | } |
| | | if (money === '') { |
| | | wx.showToast({ |
| | | title: '请è¾å
¥è£
ä¿®é¢ç®', |
| | | icon: 'none' |
| | | }) |
| | | return false |
| | | } |
| | | }) |
| | | |
| | | submitData = ['æ¿å±ç±»åï¼' + typeArray[type], 'æ·åä¿¡æ¯ï¼' + infoArray[info], 'æ¿å±é¢ç§¯ï¼' + area + 'ã¡', 'è£
ä¿®é¢ç®ï¼' + money + 'ä¸å
'].join('-') |
| | | for (let i in options) { |
| | | options[i].money = (money * options[i].rate / 100).toFixed(2) |
| | | let childList = options[i].childList |
| | | for(let j in childList) { |
| | | childList[j].money = (money * childList[j].rate / 100).toFixed(2) |
| | | } |
| | | } |
| | | this.setData({ calculatorOptions: options, showResultMoney: true, containerContentStyle: 'auto' }) |
| | | this.submitCalculatorResult(submitData) |
| | | } |
| | | }, |
| | | |
| | | // æäº¤è®¡ç®ç»æ |
| | | submitCalculatorResult (data) { |
| | | calculatorSave({ info: data }).then(res => { |
| | | saveRenovationCalculator({ info: data }).then(res => { |
| | | // console.log(res) |
| | | if (res.success) { |
| | | wx.showToast({ |
| | |
| | | |
| | | // è·å计ç®å¨é
ç½® |
| | | getCalculatorOption () { |
| | | calculatorOption().then(res => { |
| | | getBjParamConfig().then(res => { |
| | | this.setData({ calculatorOptions: res.data }) |
| | | }) |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢å è½½ |
| | | */ |
| | | onLoad: function (options) { |
| | | let that = this |
| | | // this.getCalculatorOption() |
| | | // ls.get('userInfo').then(res => { |
| | | // if (res.phone) { |
| | | // that.setData({ userPhone: res.phone }) |
| | | // } |
| | | // }) |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢å次渲æå®æ |
| | | */ |
| | | onReady: function () { |
| | | |
| | | }, |
| | |
| | | // pages/design/design.js |
| | | import { |
| | | getDictData, |
| | | saveFreeCustomizationApply |
| | | } from '../../api/index' |
| | | Page({ |
| | | |
| | | /** |
| | |
| | | data: { |
| | | name: '', |
| | | phone: '', |
| | | city: '' |
| | | city: '', |
| | | |
| | | showAreaList: false, |
| | | areaList: [], |
| | | DESIGN_BANNER: '', |
| | | WechatIMG558: '', |
| | | }, |
| | | onLoad(options) { |
| | | |
| | | this.initData() |
| | | }, |
| | | |
| | | onSubmit() { |
| | | console.log('dd', this.data.name); |
| | | console.log('dd', this.data.phone); |
| | | const { |
| | | name, |
| | | phone |
| | | } = this.data |
| | | if (!name) return wx.showToast({ |
| | | title: '请è¾å
¥å§å', |
| | | icon: 'none' |
| | | }) |
| | | if (!phone) return wx.showToast({ |
| | | title: '请è¾å
¥èç³»çµè¯', |
| | | icon: 'none' |
| | | }) |
| | | saveFreeCustomizationApply({ |
| | | name, |
| | | phone |
| | | }).then(res => { |
| | | wx.showToast({ |
| | | title: 'æ¥åæå' |
| | | }) |
| | | |
| | | }) |
| | | }, |
| | | selAddress() { |
| | | console.log('ç¹å»äº'); |
| | | wx.chooseLocation({ |
| | | type: 'wgs84', |
| | | success: (res)=> { |
| | | this.setData({ |
| | | city: res.name |
| | | }) |
| | | console.log('res', res); |
| | | } |
| | | // æ¾ç¤ºåæ¢åå¸å¼¹çª |
| | | chooseCity () { |
| | | this.setData({ showAreaList: !this.data.showAreaList }) |
| | | }, |
| | | // 忢åå¸ |
| | | confirmChange(e) { |
| | | let { |
| | | values |
| | | } = e.detail |
| | | let region = [] |
| | | for (let i in values) { |
| | | region.push(values[i].name) |
| | | } |
| | | this.setData({ |
| | | region, |
| | | cityCode: values[1].code |
| | | }) |
| | | this.getShopList() |
| | | this.chooseCity() |
| | | }, |
| | | initData() { |
| | | getDictData({ |
| | | code: 'WEIXIN_DEFAULT_IMGS', |
| | | label: 'DESIGN_BANNER' |
| | | }).then(res => { |
| | | this.setData({ |
| | | DESIGN_BANNER: res.data.code |
| | | }) |
| | | }) |
| | | getDictData({ |
| | | code: 'WEIXIN_DEFAULT_IMGS', |
| | | label: 'WechatIMG558' |
| | | }).then(res => { |
| | | this.setData({ |
| | | WechatIMG558: res.data.code |
| | | }) |
| | | }) |
| | | }, |
| | | onReady() { |
| | |
| | | { |
| | | "usingComponents": { |
| | | "van-field": "@vant/weapp/field/index" |
| | | "van-field": "@vant/weapp/field/index", |
| | | "van-area": "@vant/weapp/area/index", |
| | | "van-popup": "@vant/weapp/popup/index" |
| | | }, |
| | | "navigationStyle": "custom", |
| | | "navigationBarTextStyle": "white" |
| | | "navigationBarTitleText": "0å
å
费设计" |
| | | } |
| | |
| | | .banner { |
| | | width: 100%; |
| | | padding-bottom: 100rpx; |
| | | } |
| | | |
| | | .main_content { |
| | |
| | | margin-bottom: 34rpx; |
| | | text-align: center; |
| | | } |
| | | } |
| | | .area-list { |
| | | .van-picker__confirm{ |
| | | color: #B08771; |
| | | } |
| | | } |
| | |
| | | <view class="container"> |
| | | <navBar title="0å
å
费设计"></navBar> |
| | | <!-- <image class="banner" src="../../static/images/design_banner.png"></image> --> |
| | | <image class="banner" src="{{ DESIGN_BANNER }}" mode="widthFix"></image> |
| | | <view class="main_content"> |
| | | <view class="title">0å
å®å¶ | æ¨çæ·åè£
ä¿®æ¹æ¡</view> |
| | | <view class="line"> |
| | |
| | | <image class="icon" src="../../static/icon/design_ic_phone.png" mode="widthFix"></image> |
| | | <van-field type="number" class="input" custom-style="background-color: #F6F6F6;" model:value="{{ phone }}" placeholder="请è¾å
¥èç³»çµè¯" clearable maxlength="{{ 11 }}" /> |
| | | </view> |
| | | <view class="line" bindtap="selAddress"> |
| | | <view class="line" bindtap="chooseCity"> |
| | | <image class="icon" src="../../static/icon/design_ic_city.png" mode="widthFix"></image> |
| | | <view class="city">{{ city }}</view> |
| | | <image class="arrow_right" src="../../static/icon/arrow_right.png" mode="widthFix"></image> |
| | | </view> |
| | | <view class="btn" bindtap="onSubmit">ç«å³æ¥å</view> |
| | | </view> |
| | | <image class="banner" src="{{ WechatIMG558 }}" mode="widthFix"></image> |
| | | <!-- --> |
| | | <van-popup show="{{ showAreaList }}" position="bottom" round> |
| | | <van-area class="area-list" area-list="{{ areaList }}" bind:confirm="confirmChange" bind:cancel="chooseCity" /> |
| | | </van-popup> |
| | | </view> |
| | |
| | | .banner { |
| | | width: 100%; |
| | | padding-bottom: 100rpx; |
| | | } |
| | | .main_content { |
| | | width: 670rpx; |
| | |
| | | margin-bottom: 34rpx; |
| | | text-align: center; |
| | | } |
| | | .area-list .van-picker__confirm { |
| | | color: #B08771; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | // pages/consult/consult.js |
| | | Page({ |
| | | |
| | | /** |
| | | * 页é¢çåå§æ°æ® |
| | | */ |
| | | data: { |
| | | category: ['æ°åä¸å¸', 'ä¸å©è¯ä¹¦', 'å¤§çææ','æ°åä¸å¸', 'ä¸å©è¯ä¹¦', 'å¤§çææ'], |
| | | secondCategory: ['级åç±»','级åç±»','级åç±»','级åç±»','级åç±»','级åç±»'], |
| | | activeCate: '', |
| | | seActiveCate: '', |
| | | dataList: [] |
| | | }, |
| | | |
| | | itemClick(e) { |
| | | const { id } = e.target.dataset |
| | | console.log(e.target.dataset); |
| | | wx.navigateTo({ |
| | | url: '/pages/consult/detail', |
| | | }) |
| | | }, |
| | | cateClick(e) { |
| | | const { index } = e.target.dataset |
| | | console.log(index); |
| | | }, |
| | | seCateClick(e) { |
| | | const { index } = e.target.dataset |
| | | console.log(index); |
| | | }, |
| | | onLoad(options) { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢å次渲æå®æ |
| | | */ |
| | | onReady() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢æ¾ç¤º |
| | | */ |
| | | onShow() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢éè |
| | | */ |
| | | onHide() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢å¸è½½ |
| | | */ |
| | | onUnload() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * 页é¢ç¸å
³äºä»¶å¤ç彿°--çå¬ç¨æ·ä¸æå¨ä½ |
| | | */ |
| | | onPullDownRefresh() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * 页é¢ä¸æè§¦åºäºä»¶çå¤ç彿° |
| | | */ |
| | | onReachBottom() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * ç¨æ·ç¹å»å³ä¸è§å享 |
| | | */ |
| | | onShareAppMessage() { |
| | | |
| | | } |
| | | }) |
¶Ô±ÈÐÂÎļþ |
| | |
| | | { |
| | | "navigationBarTitleText": "å®¶çID" |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | .container { |
| | | background-color: #fff; |
| | | } |
| | | .search_wrap{ |
| | | width: 670rpx; |
| | | height: 72rpx; |
| | | margin: 24rpx auto; |
| | | background: #F7F7F7; |
| | | border-radius: 8rpx; |
| | | padding: 0 40rpx; |
| | | display: flex; |
| | | align-items: center; |
| | | background-color: #F7F7F7; |
| | | image{ |
| | | width: 28rpx; |
| | | margin-right: 16rpx; |
| | | } |
| | | } |
| | | .scroll_cate { |
| | | display: flex; |
| | | align-items: center; |
| | | margin-left: 40rpx; |
| | | height: 60rpx; |
| | | .item { |
| | | margin-right: 54rpx; |
| | | color: #666666; |
| | | flex-shrink: 0; |
| | | } |
| | | |
| | | .active { |
| | | color: #222222; |
| | | font-weight: 500; |
| | | font-size: 30rpx; |
| | | } |
| | | } |
| | | |
| | | .second_list { |
| | | .item { |
| | | padding: 0 40rpx; |
| | | display: flex; |
| | | align-items: center; |
| | | font-size: 24rpx; |
| | | color: #333333; |
| | | height: 60rpx; |
| | | background: #F7F7F7; |
| | | border-radius: 8rpx; |
| | | margin-right: 24rpx; |
| | | } |
| | | .active{ |
| | | background-color: var(--themeColor); |
| | | color: #fff; |
| | | font-size: 24rpx; |
| | | font-weight: 400; |
| | | } |
| | | } |
| | | .content{ |
| | | padding: 0 40rpx 40rpx; |
| | | .item{ |
| | | .img{ |
| | | width: 100%; |
| | | } |
| | | .title{ |
| | | font-size: 30rpx; |
| | | color: #111111; |
| | | margin: 24rpx 0 12rpx; |
| | | } |
| | | .static{ |
| | | font-size: 24rpx; |
| | | color: #999999; |
| | | .liulan{ |
| | | width: 26rpx; |
| | | margin-right: 10rpx; |
| | | } |
| | | } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <view class="container"> |
| | | |
| | | <!-- åç±» --> |
| | | <view> |
| | | <scroll-view scroll-x="true" style="weight: 710rpx;margin-bottom: 30rpx;"> |
| | | <view class="scroll_cate"> |
| | | <view bindtap="cateClick" data-index="{{index}}" wx:for="{{ category }}" class="item {{ index == 0 ? 'active': '' }}">{{ item }}</view> |
| | | </view> |
| | | </scroll-view> |
| | | </view> |
| | | <!-- content --> |
| | | <view class="content"> |
| | | <view class="item" bindtap="itemClick" data-abg="qwe"> |
| | | <image class="img" src="../../static/icon/test.png" mode="widthFix"></image> |
| | | <view class="title">åç¯å®ç¨ç¹è¾ | 䏿¥å¦ä¼çæ³å
å½±å¸å±</view> |
| | | <view class="df_sb static"> |
| | | <view>{{ '2021-08-21 12:00:00' }}</view> |
| | | <view class="df_sb"> |
| | | <image class="liulan" src="../../static/icon/zixun_ic_liulan.png" mode="widthFix"></image> |
| | | <text>1000</text> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | </view> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | .container { |
| | | background-color: #fff; |
| | | } |
| | | .search_wrap { |
| | | width: 670rpx; |
| | | height: 72rpx; |
| | | margin: 24rpx auto; |
| | | background: #F7F7F7; |
| | | border-radius: 8rpx; |
| | | padding: 0 40rpx; |
| | | display: flex; |
| | | align-items: center; |
| | | background-color: #F7F7F7; |
| | | } |
| | | .search_wrap image { |
| | | width: 28rpx; |
| | | margin-right: 16rpx; |
| | | } |
| | | .scroll_cate { |
| | | display: flex; |
| | | align-items: center; |
| | | margin-left: 40rpx; |
| | | height: 60rpx; |
| | | } |
| | | .scroll_cate .item { |
| | | margin-right: 54rpx; |
| | | color: #666666; |
| | | flex-shrink: 0; |
| | | } |
| | | .scroll_cate .active { |
| | | color: #222222; |
| | | font-weight: 500; |
| | | font-size: 30rpx; |
| | | } |
| | | .second_list .item { |
| | | padding: 0 40rpx; |
| | | display: flex; |
| | | align-items: center; |
| | | font-size: 24rpx; |
| | | color: #333333; |
| | | height: 60rpx; |
| | | background: #F7F7F7; |
| | | border-radius: 8rpx; |
| | | margin-right: 24rpx; |
| | | } |
| | | .second_list .active { |
| | | background-color: var(--themeColor); |
| | | color: #fff; |
| | | font-size: 24rpx; |
| | | font-weight: 400; |
| | | } |
| | | .content { |
| | | padding: 0 40rpx 40rpx; |
| | | } |
| | | .content .item .img { |
| | | width: 100%; |
| | | } |
| | | .content .item .title { |
| | | font-size: 30rpx; |
| | | color: #111111; |
| | | margin: 24rpx 0 12rpx; |
| | | } |
| | | .content .item .static { |
| | | font-size: 24rpx; |
| | | color: #999999; |
| | | } |
| | | .content .item .static .liulan { |
| | | width: 26rpx; |
| | | margin-right: 10rpx; |
| | | } |
| | |
| | | // pages/index/index.js |
| | | import { getDictData } from '../../api/index' |
| | | Page({ |
| | | |
| | | /** |
| | |
| | | interval: 3000, |
| | | duration: 500 |
| | | }, |
| | | HOME_CLASS_A: '', |
| | | HOME_CLASS_B: '', |
| | | HOME_CLASS_B2: '', |
| | | HOME_CLASS_C: '', |
| | | }, |
| | | |
| | | toSearch() {}, |
| | | onLoad(options) { |
| | | |
| | | this.initData() |
| | | }, |
| | | changePath(e) { |
| | | let index = e.currentTarget.dataset.type |
| | |
| | | success: function (res) { |
| | | // éè¿eventChannelå被æå¼é¡µé¢ä¼ éæ°æ® |
| | | res.eventChannel.emit('acceptDataFromOpenerPage', { link: 'https://m.zbom.com/mobile/styleTest.html?type=1' }) |
| | | saveBehavior({ type: 1 }) |
| | | // saveBehavior({ type: 1 }) |
| | | } |
| | | }) |
| | | break; |
| | |
| | | break; |
| | | } |
| | | }, |
| | | initData() { |
| | | getDictData({ |
| | | code: 'WEIXIN_DEFAULT_IMGS', |
| | | label: 'HOME_CLASS_A' |
| | | }).then(res => { |
| | | this.setData({ HOME_CLASS_A: res.data.code }) |
| | | }) |
| | | getDictData({ |
| | | code: 'WEIXIN_DEFAULT_IMGS', |
| | | label: 'HOME_CLASS_B' |
| | | }).then(res => { |
| | | this.setData({ HOME_CLASS_B: res.data.code }) |
| | | }) |
| | | getDictData({ |
| | | code: 'WEIXIN_DEFAULT_IMGS', |
| | | label: 'HOME_CLASS_B2' |
| | | }).then(res => { |
| | | this.setData({ HOME_CLASS_B2: res.data.code }) |
| | | }) |
| | | getDictData({ |
| | | code: 'WEIXIN_DEFAULT_IMGS', |
| | | label: 'HOME_CLASS_C' |
| | | }).then(res => { |
| | | this.setData({ HOME_CLASS_C: res.data.code }) |
| | | }) |
| | | }, |
| | | jumpProVideo() { |
| | | wx.navigateTo({ |
| | | url: '/pages/productVideo/index', |
| | | }) |
| | | }, |
| | | jumpProKefu() { |
| | | wx.navigateTo({ |
| | | url: '/pages/kefu/index', |
| | | }) |
| | | }, |
| | | jumpProConsult() { |
| | | wx.switchTab({ |
| | | url: '/pages/consult/consult', |
| | | }) |
| | | }, |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢å次渲æå®æ |
| | | */ |
| | |
| | | width: 72rpx; |
| | | height: 72rpx; |
| | | background: #FFFFFF; |
| | | border: 1px solid; |
| | | border-radius: 50%; |
| | | } |
| | | |
| | |
| | | <!-- --> |
| | | <view class="function_wrap"> |
| | | <view class="item" data-type="0" bindtap="changePath"> |
| | | <image class="img" src="../../static/icon/test.png"></image> |
| | | <image class="img" src="../../static/icon/home_ic_xuqiu@2x.png"></image> |
| | | <view class="name">éæ±</view> |
| | | <view class="placeholder9">åæå°å¸®æ</view> |
| | | </view> |
| | | <view class="item" data-type="2" bindtap="changePath"> |
| | | <image class="img" src="../../static/icon/test.png"></image> |
| | | <image class="img" src="../../static/icon/home_ic_liangchi@2x.png"></image> |
| | | <view class="name">å
è´¹éå°º</view> |
| | | <view class="placeholder9">åæå°å¸®æ</view> |
| | | </view> |
| | | <view class="item" data-type="1" bindtap="changePath"> |
| | | <image class="img" src="../../static/icon/test.png"></image> |
| | | <image class="img" src="../../static/icon/home_ic_yusuan@2x.png"></image> |
| | | <view class="name">é¢ç®</view> |
| | | <view class="placeholder9">å¿«éè·åæ¥ä»·</view> |
| | | </view> |
| | | </view> |
| | | <!-- --> |
| | | <authCard /> |
| | | <authCard type="1" /> |
| | | <!-- 产åè§é¢ --> |
| | | <view class="product_video"> |
| | | <view class="product_video" bindtap="jumpProVideo"> |
| | | <view class="com_header"> |
| | | <view class="left"> |
| | | <view class="name"> |
| | |
| | | </view> |
| | | <view class="line"> |
| | | <view class="line_left"> |
| | | <image src="../../static/images/home_class_a@2x.png"></image> |
| | | <image src="{{HOME_CLASS_A}}"></image> |
| | | </view> |
| | | <view class="line_right"> |
| | | <view class="item"><image src="../../static/images/home_class_b@2x.png"></image></view> |
| | | <view class="item"><image src="../../static/images/home_class_b2@2x.png"></image></view> |
| | | <view class="item"><image src="{{ HOME_CLASS_B }}"></image></view> |
| | | <view class="item"><image src="{{ HOME_CLASS_B2 }}"></image></view> |
| | | </view> |
| | | </view> |
| | | <view class="home_id"> |
| | | <image src="../../static/images/home_class_c@2x.png"></image> |
| | | <image src="{{HOME_CLASS_C}}"></image> |
| | | </view> |
| | | </view> |
| | | <!-- å¨è¯¢ --> |
| | | <view class="consult"> |
| | | <view class="consult" bindtap="jumpProConsult"> |
| | | <view class="com_header"> |
| | | <view class="left"> |
| | | <view class="name"> |
| | |
| | | </swiper> |
| | | </view> |
| | | <!-- service --> |
| | | <view class="consult"> |
| | | <view class="consult" bindtap="jumpProKefu"> |
| | | <view class="com_header"> |
| | | <view class="left"> |
| | | <view class="name"> |
| | |
| | | <image src="../../static/icon/home_logo@2x.png" class="logo" mode="widthFix"></image> |
| | | </view> |
| | | <!-- active --> |
| | | <image class="active_baoming" src="../../static/icon/ic_float_baoming@2x.png" mode="widthFix"></image> |
| | | <image class="active_baoming" data-type="2" bindtap="changePath" src="../../static/icon/ic_float_baoming@2x.png" mode="widthFix"></image> |
| | | |
| | | </view> |
| | |
| | | width: 72rpx; |
| | | height: 72rpx; |
| | | background: #FFFFFF; |
| | | border: 1px solid; |
| | | border-radius: 50%; |
| | | } |
| | | .container .function_wrap .item .name { |
¶Ô±ÈÐÂÎļþ |
| | |
| | | // pages/kefu/fond.js |
| | | Page({ |
| | | |
| | | /** |
| | | * 页é¢çåå§æ°æ® |
| | | */ |
| | | data: { |
| | | bottomLift: 0 |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢å è½½ |
| | | */ |
| | | onLoad(options) { |
| | | var app = getApp().globalData |
| | | this.setData({ |
| | | bottomLift: app.bottomLift |
| | | }) |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢å次渲æå®æ |
| | | */ |
| | | onReady() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢æ¾ç¤º |
| | | */ |
| | | onShow() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢éè |
| | | */ |
| | | onHide() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢å¸è½½ |
| | | */ |
| | | onUnload() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * 页é¢ç¸å
³äºä»¶å¤ç彿°--çå¬ç¨æ·ä¸æå¨ä½ |
| | | */ |
| | | onPullDownRefresh() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * 页é¢ä¸æè§¦åºäºä»¶çå¤ç彿° |
| | | */ |
| | | onReachBottom() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * ç¨æ·ç¹å»å³ä¸è§å享 |
| | | */ |
| | | onShareAppMessage() { |
| | | |
| | | } |
| | | }) |
¶Ô±ÈÐÂÎļþ |
| | |
| | | { |
| | | "usingComponents": {}, |
| | | "navigationBarTitleText": "客æ·å欢" |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | page{ |
| | | background-color: #f7f7f7; |
| | | padding-bottom: 220rpx; |
| | | } |
| | | .date_item{ |
| | | .date{ |
| | | display: flex; |
| | | font-weight: 500; |
| | | font-size: 32rpx; |
| | | color: #222222; |
| | | height: 108rpx; |
| | | align-items: center; |
| | | padding: 0 22rpx; |
| | | } |
| | | .list{ |
| | | padding: 30rpx 22rpx 1rpx; |
| | | background-color: #fff; |
| | | } |
| | | .line{ |
| | | display: flex; |
| | | align-items: center; |
| | | height: 120rpx; |
| | | margin-bottom: 30rpx; |
| | | .icon{ |
| | | width: 40rpx; |
| | | } |
| | | .content{ |
| | | flex: 1; |
| | | height: 100%; |
| | | display: flex; |
| | | flex-direction: column; |
| | | justify-content: space-between; |
| | | .name{ |
| | | width: 100%; |
| | | font-size: 30rpx; |
| | | overflow : hidden; |
| | | text-overflow: ellipsis; |
| | | display: -webkit-box; |
| | | -webkit-line-clamp: 2; |
| | | -webkit-box-orient: vertical; |
| | | } |
| | | .time{ |
| | | font-size: 24rpx; |
| | | color: #999999; |
| | | } |
| | | } |
| | | .img{ |
| | | width: 214rpx; |
| | | height: 120rpx; |
| | | border-radius: 8rpx; |
| | | margin-left: 26rpx; |
| | | margin-right: 20rpx; |
| | | border: 1px solid; |
| | | } |
| | | } |
| | | } |
| | | .footer { |
| | | position: fixed; |
| | | bottom: 0; |
| | | left: 0; |
| | | width: 750rpx; |
| | | background-color: #fff; |
| | | box-shadow: 0rpx -1rpx 0rpx 0rpx #EEEEEE; |
| | | .btns{ |
| | | display: flex; |
| | | align-items: center; |
| | | height: 100rpx; |
| | | padding: 12rpx 40rpx; |
| | | .all_sel{ |
| | | display: flex; |
| | | width: 160rpx; |
| | | .icon{ |
| | | width: 40rpx; |
| | | margin-right: 18rpx; |
| | | } |
| | | } |
| | | .list{ |
| | | flex: 1; |
| | | display: flex; |
| | | align-items: center; |
| | | .item { |
| | | display: flex; |
| | | justify-content: center; |
| | | align-items: center; |
| | | height: 72rpx; |
| | | width: 152rpx; |
| | | font-weight: 500; |
| | | color: #777777; |
| | | border: 1rpx solid #999999; |
| | | margin-left: 20rpx; |
| | | font-style: 28rpx; |
| | | border-radius: 8rpx; |
| | | } |
| | | .paina{ |
| | | color: var(--themeColor); |
| | | border: 1rpx solid var(--themeColor); |
| | | } |
| | | .primary{ |
| | | color: #fff !important; |
| | | border: 1rpx solid var(--themeColor); |
| | | background-color: var(--themeColor); |
| | | } |
| | | } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <view class="container"> |
| | | <view class="date_item"> |
| | | <view class="date">2024å¹´07æ10æ¥</view> |
| | | <view class="list"> |
| | | <view class="line"> |
| | | <image class="icon" src="../../static/icon/ic_select_sel@2x.png" mode="widthFix"></image> |
| | | <image class="icon" src="../../static/icon/ic_select@2x.png" mode="widthFix"></image> |
| | | <image class="img" src=""></image> |
| | | <view class="content"> |
| | | <view class="name">ç®çº¦è½»å¥¢ï½ä¸ç§å
¬åéï¼å·²å
为åªç®çº¦è½»å¥¢ï½ä¸ç§å
¬åéï¼å·²å
为åªç®çº¦è½»å¥¢ï½ä¸ç§å
¬åéï¼å·²å
为åª</view> |
| | | <view class="time">18:00</view> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | <!-- footer --> |
| | | <view class="footer" style="padding-bottom: {{bottomLift}}px;"> |
| | | <view class="btns"> |
| | | <view class="all_sel"> |
| | | <image class="icon" src="../../static/icon/ic_select_sel@2x.png" mode="widthFix"></image> |
| | | <text>å
¨é</text> |
| | | </view> |
| | | <view class="list"> |
| | | <view class="item">å é¤</view> |
| | | <view class="item paina">å
³è</view> |
| | | <view class="item primary">å享</view> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | </view> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | page { |
| | | background-color: #f7f7f7; |
| | | padding-bottom: 220rpx; |
| | | } |
| | | .date_item .date { |
| | | display: flex; |
| | | font-weight: 500; |
| | | font-size: 32rpx; |
| | | color: #222222; |
| | | height: 108rpx; |
| | | align-items: center; |
| | | padding: 0 22rpx; |
| | | } |
| | | .date_item .list { |
| | | padding: 30rpx 22rpx 1rpx; |
| | | background-color: #fff; |
| | | } |
| | | .date_item .line { |
| | | display: flex; |
| | | align-items: center; |
| | | height: 120rpx; |
| | | margin-bottom: 30rpx; |
| | | } |
| | | .date_item .line .icon { |
| | | width: 40rpx; |
| | | } |
| | | .date_item .line .content { |
| | | flex: 1; |
| | | height: 100%; |
| | | display: flex; |
| | | flex-direction: column; |
| | | justify-content: space-between; |
| | | } |
| | | .date_item .line .content .name { |
| | | width: 100%; |
| | | font-size: 30rpx; |
| | | overflow: hidden; |
| | | text-overflow: ellipsis; |
| | | display: -webkit-box; |
| | | -webkit-line-clamp: 2; |
| | | -webkit-box-orient: vertical; |
| | | } |
| | | .date_item .line .content .time { |
| | | font-size: 24rpx; |
| | | color: #999999; |
| | | } |
| | | .date_item .line .img { |
| | | width: 214rpx; |
| | | height: 120rpx; |
| | | border-radius: 8rpx; |
| | | margin-left: 26rpx; |
| | | margin-right: 20rpx; |
| | | border: 1px solid; |
| | | } |
| | | .footer { |
| | | position: fixed; |
| | | bottom: 0; |
| | | left: 0; |
| | | width: 750rpx; |
| | | background-color: #fff; |
| | | box-shadow: 0rpx -1rpx 0rpx 0rpx #EEEEEE; |
| | | } |
| | | .footer .btns { |
| | | display: flex; |
| | | align-items: center; |
| | | height: 100rpx; |
| | | padding: 12rpx 40rpx; |
| | | } |
| | | .footer .btns .all_sel { |
| | | display: flex; |
| | | width: 160rpx; |
| | | } |
| | | .footer .btns .all_sel .icon { |
| | | width: 40rpx; |
| | | margin-right: 18rpx; |
| | | } |
| | | .footer .btns .list { |
| | | flex: 1; |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | .footer .btns .list .item { |
| | | display: flex; |
| | | justify-content: center; |
| | | align-items: center; |
| | | height: 72rpx; |
| | | width: 152rpx; |
| | | font-weight: 500; |
| | | color: #777777; |
| | | border: 1rpx solid #999999; |
| | | margin-left: 20rpx; |
| | | font-style: 28rpx; |
| | | border-radius: 8rpx; |
| | | } |
| | | .footer .btns .list .paina { |
| | | color: var(--themeColor); |
| | | border: 1rpx solid var(--themeColor); |
| | | } |
| | | .footer .btns .list .primary { |
| | | color: #fff !important; |
| | | border: 1rpx solid var(--themeColor); |
| | | background-color: var(--themeColor); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | // pages/kefu/index.js |
| | | Page({ |
| | | |
| | | /** |
| | | * 页é¢çåå§æ°æ® |
| | | */ |
| | | data: { |
| | | bottomLift: 0 |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢å è½½ |
| | | */ |
| | | onLoad(options) { |
| | | var app = getApp().globalData |
| | | this.setData({ |
| | | bottomLift: app.bottomLift |
| | | }) |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢å次渲æå®æ |
| | | */ |
| | | onReady() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢æ¾ç¤º |
| | | */ |
| | | onShow() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢éè |
| | | */ |
| | | onHide() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢å¸è½½ |
| | | */ |
| | | onUnload() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * 页é¢ç¸å
³äºä»¶å¤ç彿°--çå¬ç¨æ·ä¸æå¨ä½ |
| | | */ |
| | | onPullDownRefresh() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * 页é¢ä¸æè§¦åºäºä»¶çå¤ç彿° |
| | | */ |
| | | onReachBottom() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * ç¨æ·ç¹å»å³ä¸è§å享 |
| | | */ |
| | | onShareAppMessage() { |
| | | |
| | | } |
| | | }) |
¶Ô±ÈÐÂÎļþ |
| | |
| | | { |
| | | "usingComponents": {}, |
| | | "navigationBarTitleText": "ä¸å±å®¢æ" |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | .footer { |
| | | position: fixed; |
| | | bottom: 0; |
| | | left: 0; |
| | | width: 750rpx; |
| | | background-color: #fff; |
| | | box-shadow: 0rpx -1rpx 0rpx 0rpx #EEEEEE; |
| | | .btns{ |
| | | display: flex; |
| | | align-items: center; |
| | | height: 100rpx; |
| | | padding: 12rpx 40rpx; |
| | | } |
| | | .sub_btn { |
| | | flex: 1; |
| | | display: flex; |
| | | justify-content: center; |
| | | align-items: center; |
| | | height: 72rpx; |
| | | width: 152rpx; |
| | | background-color: var(--themeColor); |
| | | font-weight: 500; |
| | | color: #FFFFFF; |
| | | font-style: 28rpx; |
| | | box-shadow: 0rpx 4rpx 16rpx 0rpx rgba(176,135,113,0.3), inset 0rpx 2rpx 2rpx 0rpx rgba(255,255,255,0.33); |
| | | border-radius: 8rpx; |
| | | .icon{ |
| | | width: 34rpx; |
| | | margin-right: 8rpx; |
| | | } |
| | | } |
| | | .item { |
| | | display: flex; |
| | | flex-direction: column; |
| | | justify-content: center; |
| | | align-items: center; |
| | | font-size: 20rpx; |
| | | color: #666666; |
| | | margin-right: 48rpx; |
| | | |
| | | .icon { |
| | | width: 44rpx; |
| | | } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <view class="container"> |
| | | <!-- footer --> |
| | | <view class="footer" style="padding-bottom: {{bottomLift}}px;"> |
| | | <view class="btns"> |
| | | <view class="item"> |
| | | <image class="icon" src="../../static/icon/detail_nav_share.png" mode="widthFix"></image> |
| | | <view class="name">å享</view> |
| | | </view> |
| | | <view class="sub_btn"> |
| | | <image class="icon" src="../../static/icon/home_ic_kefu.png" mode="widthFix"></image> |
| | | <view>ç«å³å¨è¯¢å®¢æ</view> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | </view> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | .footer { |
| | | position: fixed; |
| | | bottom: 0; |
| | | left: 0; |
| | | width: 750rpx; |
| | | background-color: #fff; |
| | | box-shadow: 0rpx -1rpx 0rpx 0rpx #EEEEEE; |
| | | } |
| | | .footer .btns { |
| | | display: flex; |
| | | align-items: center; |
| | | height: 100rpx; |
| | | padding: 12rpx 40rpx; |
| | | } |
| | | .footer .sub_btn { |
| | | flex: 1; |
| | | display: flex; |
| | | justify-content: center; |
| | | align-items: center; |
| | | height: 72rpx; |
| | | width: 152rpx; |
| | | background-color: var(--themeColor); |
| | | font-weight: 500; |
| | | color: #FFFFFF; |
| | | font-style: 28rpx; |
| | | box-shadow: 0rpx 4rpx 16rpx 0rpx rgba(176, 135, 113, 0.3), inset 0rpx 2rpx 2rpx 0rpx rgba(255, 255, 255, 0.33); |
| | | border-radius: 8rpx; |
| | | } |
| | | .footer .sub_btn .icon { |
| | | width: 34rpx; |
| | | margin-right: 8rpx; |
| | | } |
| | | .footer .item { |
| | | display: flex; |
| | | flex-direction: column; |
| | | justify-content: center; |
| | | align-items: center; |
| | | font-size: 20rpx; |
| | | color: #666666; |
| | | margin-right: 48rpx; |
| | | } |
| | | .footer .item .icon { |
| | | width: 44rpx; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | // pages/discover/discover.js |
| | | Page({ |
| | | |
| | | /** |
| | | * 页é¢çåå§æ°æ® |
| | | */ |
| | | data: { |
| | | activeTabs: '0', |
| | | bottomLift: 0 |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢å è½½ |
| | | */ |
| | | onLoad(options) { |
| | | var app = getApp().globalData |
| | | this.setData({ |
| | | bottomLift: app.bottomLift |
| | | }) |
| | | }, |
| | | tabsClick(e) { |
| | | const activeTabs = e.currentTarget.dataset.tab |
| | | this.setData({activeTabs}) |
| | | }, |
| | | handleSub() { |
| | | console.log('ç¹å»é¥¿äº'); |
| | | wx.canvasToTempFilePath({ |
| | | x: 100, |
| | | y: 200, |
| | | width: 50, |
| | | height: 50, |
| | | destWidth: 100, |
| | | destHeight: 100, |
| | | canvasId: 'myCanvas', |
| | | success(res) { |
| | | console.log(res.tempFilePath) |
| | | } |
| | | }) |
| | | }, |
| | | onReady() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢æ¾ç¤º |
| | | */ |
| | | onShow() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢éè |
| | | */ |
| | | onHide() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢å¸è½½ |
| | | */ |
| | | onUnload() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * 页é¢ç¸å
³äºä»¶å¤ç彿°--çå¬ç¨æ·ä¸æå¨ä½ |
| | | */ |
| | | onPullDownRefresh() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * 页é¢ä¸æè§¦åºäºä»¶çå¤ç彿° |
| | | */ |
| | | onReachBottom() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * ç¨æ·ç¹å»å³ä¸è§å享 |
| | | */ |
| | | onShareAppMessage() { |
| | | |
| | | } |
| | | }) |
¶Ô±ÈÐÂÎļþ |
| | |
| | | { |
| | | "usingComponents": {}, |
| | | "navigationBarTitleText": "鿩客æ·" |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | page{ |
| | | background-color: #f7f7f7; |
| | | } |
| | | .main_tab{ |
| | | width: 100%; |
| | | display: flex; |
| | | align-items: flex-end; |
| | | height: 88rpx; |
| | | background-color: #fff; |
| | | padding: 0 40rpx; |
| | | .item{ |
| | | flex: 1; |
| | | display: flex; |
| | | flex-direction: column; |
| | | justify-content: center; |
| | | align-items: center; |
| | | font-size: 32rpx; |
| | | color: #555555; |
| | | margin-right: 60rpx; |
| | | .name{} |
| | | .border{ |
| | | width: 40rpx; |
| | | height: 6rpx; |
| | | background-color: #fff; |
| | | border-radius: 3rpx; |
| | | margin-top: 16rpx; |
| | | } |
| | | } |
| | | .active{ |
| | | font-weight: 600; |
| | | font-size: 38rpx; |
| | | color: #222222; |
| | | .border{ |
| | | background: #F4CA1C; |
| | | } |
| | | } |
| | | } |
| | | .search_wrap { |
| | | width: 750rpx; |
| | | height: 100rpx; |
| | | padding: 0rpx 40rpx; |
| | | border-radius: 8rpx; |
| | | display: flex; |
| | | align-items: center; |
| | | background-color: #fff; |
| | | .input_wrap{ |
| | | flex: 1; |
| | | height: 72rpx; |
| | | background-color: #f7f7f7; |
| | | padding-left: 40rpx; |
| | | display: flex; |
| | | align-items: center; |
| | | font-size: 26rpx; |
| | | input{ |
| | | width: 100%; |
| | | } |
| | | .icon{ |
| | | width: 26rpx; |
| | | margin-top: 4rpx; |
| | | margin-right: 16rpx; |
| | | } |
| | | } |
| | | .kehu{ |
| | | width: 48rpx; |
| | | margin-left: 30rpx; |
| | | } |
| | | } |
| | | .list{ |
| | | padding: 0 40rpx; |
| | | background-color: #fff; |
| | | .line{ |
| | | display: flex; |
| | | align-items: center; |
| | | height: 148rpx; |
| | | border-bottom: 1rpx solid #e5e5e5; |
| | | &:nth-last-child(1){ |
| | | border: none; |
| | | } |
| | | .icon{ |
| | | width: 40rpx; |
| | | margin-right: 30rpx; |
| | | } |
| | | .avatar{ |
| | | width: 88rpx; |
| | | height: 88rpx; |
| | | border-radius: 50%; |
| | | border: 1px solid; |
| | | margin-right: 20rpx; |
| | | } |
| | | .content{ |
| | | flex: 1; |
| | | .header{ |
| | | display: flex; |
| | | justify-content: space-between; |
| | | .left{ |
| | | display: flex; |
| | | align-items: center; |
| | | .name{ |
| | | font-weight: 500; |
| | | font-size: 30rpx; |
| | | color: #111111; |
| | | margin-right: 10rpx; |
| | | } |
| | | .tag{ |
| | | font-size: 24rpx; |
| | | color: #57BE6A; |
| | | } |
| | | } |
| | | .remark{ |
| | | font-size: 26rpx; |
| | | color: #666666; |
| | | } |
| | | } |
| | | .desc{ |
| | | display: flex; |
| | | justify-content: space-between; |
| | | font-size: 24rpx; |
| | | color: #999999; |
| | | margin-top: 14rpx; |
| | | } |
| | | } |
| | | } |
| | | } |
| | | .footer { |
| | | position: fixed; |
| | | bottom: 0; |
| | | left: 0; |
| | | width: 750rpx; |
| | | background-color: #fff; |
| | | box-shadow: 0rpx -1rpx 0rpx 0rpx #EEEEEE; |
| | | .btns{ |
| | | background-color: #f7f7f7; |
| | | display: flex; |
| | | align-items: center; |
| | | height: 102rpx; |
| | | padding: 14rpx 40rpx 0; |
| | | .btn { |
| | | flex: 1; |
| | | display: flex; |
| | | justify-content: center; |
| | | align-items: center; |
| | | height: 88rpx; |
| | | width: 152rpx; |
| | | font-weight: 500; |
| | | color: #777777; |
| | | border: 1rpx solid #999999; |
| | | margin-left: 20rpx; |
| | | font-style: 28rpx; |
| | | border-radius: 8rpx; |
| | | color: #fff !important; |
| | | border: 1rpx solid var(--themeColor); |
| | | background-color: var(--themeColor); |
| | | } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <view class="container" id="myCanvas"> |
| | | <view class="main_tab"> |
| | | <view class="item {{ activeTabs == '0' ? 'active' : '' }}" data-tab="0" bindtap="tabsClick"> |
| | | <view class="name">客æ·å表</view> |
| | | <view class="border"></view> |
| | | </view> |
| | | <view class="item {{ activeTabs == '1' ? 'active' : '' }}" data-tab="1" bindtap="tabsClick"> |
| | | <view class="name">æ½å®¢å表</view> |
| | | <view class="border"></view> |
| | | </view> |
| | | </view> |
| | | <!-- --> |
| | | <view class="search_wrap"> |
| | | <view class="input_wrap"> |
| | | <image class="icon" src="../../static/icon/ic_search@2x.png" mode="widthFix"></image> |
| | | <input type="text" placeholder="æç´¢å®¢æ·æµç§°ã导è´ã夿³¨å" /> |
| | | </view> |
| | | <image class="kehu" src="../../static/icon/kehu_ic_new@2x.png" mode="widthFix"></image> |
| | | </view> |
| | | <!-- --> |
| | | <view class="list"> |
| | | <view class="line"> |
| | | <image class="icon" src="../../static/icon/ic_video@2x.png" mode="widthFix"></image> |
| | | <image class="icon" src="../../static/icon/ic_select@2x.png" mode="widthFix"></image> |
| | | <image class="avatar" src=""></image> |
| | | <view class="content"> |
| | | <view class="header"> |
| | | <view class="left"> |
| | | <view class="name">çå¾·å</view> |
| | | <view class="tag">@微信</view> |
| | | </view> |
| | | <view class="remark">夿³¨åï¼çå¥</view> |
| | | </view> |
| | | <view class="desc"> |
| | | <view>导è´ï¼çææ</view> |
| | | <view>å建æ¶é´ï¼2002</view> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | <view class="line"> |
| | | <image class="icon" src="../../static/icon/ic_video@2x.png" mode="widthFix"></image> |
| | | <image class="icon" src="../../static/icon/ic_select@2x.png" mode="widthFix"></image> |
| | | <image class="avatar" src=""></image> |
| | | <view class="content"> |
| | | <view class="header"> |
| | | <view class="left"> |
| | | <view class="name">çå¾·å</view> |
| | | <view class="tag">@微信</view> |
| | | </view> |
| | | <view class="remark">夿³¨åï¼çå¥</view> |
| | | </view> |
| | | <view class="desc"> |
| | | <view>导è´ï¼çææ</view> |
| | | <view>å建æ¶é´ï¼2002</view> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | <!-- footer --> |
| | | <view class="footer" style="padding-bottom: {{bottomLift}}px;"> |
| | | <view class="btns"> |
| | | <view class="btn" bindtap="handleSub">确认å
³è</view> |
| | | </view> |
| | | </view> |
| | | </view> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | page { |
| | | background-color: #f7f7f7; |
| | | } |
| | | .main_tab { |
| | | width: 100%; |
| | | display: flex; |
| | | align-items: flex-end; |
| | | height: 88rpx; |
| | | background-color: #fff; |
| | | padding: 0 40rpx; |
| | | } |
| | | .main_tab .item { |
| | | flex: 1; |
| | | display: flex; |
| | | flex-direction: column; |
| | | justify-content: center; |
| | | align-items: center; |
| | | font-size: 32rpx; |
| | | color: #555555; |
| | | margin-right: 60rpx; |
| | | } |
| | | .main_tab .item .border { |
| | | width: 40rpx; |
| | | height: 6rpx; |
| | | background-color: #fff; |
| | | border-radius: 3rpx; |
| | | margin-top: 16rpx; |
| | | } |
| | | .main_tab .active { |
| | | font-weight: 600; |
| | | font-size: 38rpx; |
| | | color: #222222; |
| | | } |
| | | .main_tab .active .border { |
| | | background: #F4CA1C; |
| | | } |
| | | .search_wrap { |
| | | width: 750rpx; |
| | | height: 100rpx; |
| | | padding: 0rpx 40rpx; |
| | | border-radius: 8rpx; |
| | | display: flex; |
| | | align-items: center; |
| | | background-color: #fff; |
| | | } |
| | | .search_wrap .input_wrap { |
| | | flex: 1; |
| | | height: 72rpx; |
| | | background-color: #f7f7f7; |
| | | padding-left: 40rpx; |
| | | display: flex; |
| | | align-items: center; |
| | | font-size: 26rpx; |
| | | } |
| | | .search_wrap .input_wrap input { |
| | | width: 100%; |
| | | } |
| | | .search_wrap .input_wrap .icon { |
| | | width: 26rpx; |
| | | margin-top: 4rpx; |
| | | margin-right: 16rpx; |
| | | } |
| | | .search_wrap .kehu { |
| | | width: 48rpx; |
| | | margin-left: 30rpx; |
| | | } |
| | | .list { |
| | | padding: 0 40rpx; |
| | | background-color: #fff; |
| | | } |
| | | .list .line { |
| | | display: flex; |
| | | align-items: center; |
| | | height: 148rpx; |
| | | border-bottom: 1rpx solid #e5e5e5; |
| | | } |
| | | .list .line:nth-last-child(1) { |
| | | border: none; |
| | | } |
| | | .list .line .icon { |
| | | width: 40rpx; |
| | | margin-right: 30rpx; |
| | | } |
| | | .list .line .avatar { |
| | | width: 88rpx; |
| | | height: 88rpx; |
| | | border-radius: 50%; |
| | | border: 1px solid; |
| | | margin-right: 20rpx; |
| | | } |
| | | .list .line .content { |
| | | flex: 1; |
| | | } |
| | | .list .line .content .header { |
| | | display: flex; |
| | | justify-content: space-between; |
| | | } |
| | | .list .line .content .header .left { |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | .list .line .content .header .left .name { |
| | | font-weight: 500; |
| | | font-size: 30rpx; |
| | | color: #111111; |
| | | margin-right: 10rpx; |
| | | } |
| | | .list .line .content .header .left .tag { |
| | | font-size: 24rpx; |
| | | color: #57BE6A; |
| | | } |
| | | .list .line .content .header .remark { |
| | | font-size: 26rpx; |
| | | color: #666666; |
| | | } |
| | | .list .line .content .desc { |
| | | display: flex; |
| | | justify-content: space-between; |
| | | font-size: 24rpx; |
| | | color: #999999; |
| | | margin-top: 14rpx; |
| | | } |
| | | .footer { |
| | | position: fixed; |
| | | bottom: 0; |
| | | left: 0; |
| | | width: 750rpx; |
| | | background-color: #fff; |
| | | box-shadow: 0rpx -1rpx 0rpx 0rpx #EEEEEE; |
| | | } |
| | | .footer .btns { |
| | | background-color: #f7f7f7; |
| | | display: flex; |
| | | align-items: center; |
| | | height: 102rpx; |
| | | padding: 14rpx 40rpx 0; |
| | | } |
| | | .footer .btns .btn { |
| | | flex: 1; |
| | | display: flex; |
| | | justify-content: center; |
| | | align-items: center; |
| | | height: 88rpx; |
| | | width: 152rpx; |
| | | font-weight: 500; |
| | | color: #777777; |
| | | border: 1rpx solid #999999; |
| | | margin-left: 20rpx; |
| | | font-style: 28rpx; |
| | | border-radius: 8rpx; |
| | | color: #fff !important; |
| | | border: 1rpx solid var(--themeColor); |
| | | background-color: var(--themeColor); |
| | | } |
| | |
| | | // pages/mine/mine.js |
| | | import { getMemberInfo, getDictData } from '../../api/index' |
| | | Page({ |
| | | |
| | | /** |
| | | * 页é¢çåå§æ°æ® |
| | | */ |
| | | data: { |
| | | clientHeight: 0, |
| | | clientTop: 0, |
| | | |
| | | member: {}, |
| | | housetype: '', |
| | | IMG_LIUCHENG: '', |
| | | MINE_BG: '' |
| | | }, |
| | | |
| | | /** |
| | |
| | | const res = wx.getMenuButtonBoundingClientRect() |
| | | this.setData({clientHeight: res.height}) |
| | | this.setData({clientTop: res.top}) |
| | | |
| | | this.initData() |
| | | }, |
| | | initData() { |
| | | getMemberInfo().then(res => { |
| | | this.setData({member: res.data}) |
| | | if(res.data.housetype){ |
| | | const temp = res.data.housetype.split('-') |
| | | let houseType = { |
| | | val1: temp[0], |
| | | val2: temp[1], |
| | | val3: temp[2], |
| | | val4: temp[3], |
| | | val5: temp[4], |
| | | } |
| | | this.setData({houseType}) |
| | | } |
| | | }) |
| | | getDictData({ |
| | | code: 'WEIXIN_DEFAULT_IMGS', |
| | | label: 'IMG_LIUCHENG' |
| | | }).then(res => { |
| | | this.setData({ IMG_LIUCHENG: res.data.code }) |
| | | }) |
| | | getDictData({ |
| | | code: 'WEIXIN_DEFAULT_IMGS', |
| | | label: 'MINE_BG' |
| | | }).then(res => { |
| | | this.setData({ MINE_BG: res.data.code }) |
| | | }) |
| | | }, |
| | | changePath(e) { |
| | | // 页é¢è·³è½¬ |
| | | let temp = ['mysub', 'collect', 'favorite', 'index'] |
| | | let temp = ['mysub', 'collect', 'favorite','index'] |
| | | const index = e.currentTarget.dataset.index |
| | | if(index == '4'){ |
| | | |
| | | } |
| | | if(index == '5'){ |
| | | wx.navigateTo({ |
| | | url: `/pages/sets/index`, |
| | | }) |
| | | } |
| | | wx.navigateTo({ |
| | | url: `/pages/userinfo/${temp[index]}`, |
| | | }) |
| | |
| | | .container { |
| | | background-color: #aca9a6; |
| | | |
| | | .mine_bg{ |
| | | width: 100%; |
| | | position: fixed; |
| | | top: 0; |
| | | left: 0; |
| | | z-index: -1; |
| | | } |
| | | .navbar { |
| | | padding-left: 30rpx; |
| | | font-weight: 600; |
| | |
| | | } |
| | | } |
| | | } |
| | | } |
| | | .liucheng{ |
| | | width: 100%; |
| | | padding: 0rpx 40rpx 120rpx; |
| | | text-align: center; |
| | | .h1{ |
| | | margin-bottom: 16rpx; |
| | | font-weight: 600; |
| | | font-size: 36rpx; |
| | | } |
| | | .h2{ |
| | | font-weight: 300; |
| | | font-size: 26rpx; |
| | | color: #333333; |
| | | margin-bottom: 40rpx; |
| | | } |
| | | .img{ |
| | | width: 100%; |
| | | } |
| | | } |
| | |
| | | <view class="container"> |
| | | <view class="navbar" style="padding-top: {{ clientTop }}px;height: {{clientHeight + clientTop}}px;">æçå®¶</view> |
| | | <image class="mine_bg" src="{{ MINE_BG }}" mode="widthFix"></image> |
| | | <view class="userinfo"> |
| | | <image class="avatar" src=""></image> |
| | | <image class="avatar" src="{{ imgurlFull ? imgurlFull : '../../static/images/default_avatar.png' }}"></image> |
| | | <view class="content"> |
| | | <view class="header"> |
| | | <view class="name">èç¿</view> |
| | | <view class="name">{{ member.nickname }}</view> |
| | | <view data-index="3" bindtap="changePath" class="edit">ç¼è¾</view> |
| | | </view> |
| | | <view class="addr">åè¥è²è±å°åº</view> |
| | | <view class="detail">120m² ï½3室1å
1å¨1å«</view> |
| | | <view class="addr">{{ member.district || '' }}</view> |
| | | <view class="detail"> |
| | | <text wx:if="{{member.housearea}}">{{ member.housearea }}m²ï½</text> |
| | | <text class="item" wx:if="{{ houseType.val1 }}">{{ houseType.val1 }}室</text> |
| | | <text class="item" wx:if="{{ houseType.val2 }}">{{ houseType.val2 }}å
</text> |
| | | <text class="item" wx:if="{{ houseType.val3 }}">{{ houseType.val3 }}å¨</text> |
| | | <text class="item" wx:if="{{ houseType.val4 }}">{{ houseType.val4 }}å«</text> |
| | | <text class="item" wx:if="{{ houseType.val5 }}">{{ houseType.val5 }}é³</text> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | <view class="main_content"> |
| | |
| | | </view> |
| | | </view> |
| | | <view class="func_list"> |
| | | <view class="line"> |
| | | <view class="line" data-index="4" bindtap="changePath"> |
| | | <view class="name">åå·¥ç»å®</view> |
| | | <image class="icon" src="../../static/icon/mine_ic_ar.png" mode="widthFix"></image> |
| | | </view> |
| | | <view class="line"> |
| | | <view class="line" data-index="5" bindtap="changePath"> |
| | | <view class="name">æ´å¤è®¾ç½®</view> |
| | | <image class="icon" src="../../static/icon/mine_ic_ar.png" mode="widthFix"></image> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | <view class="liucheng"> |
| | | <view class="h1">æå¡æµç¨</view> |
| | | <view class="h2">䏿³¨å¨æ¿ æ´æçæ´»</view> |
| | | <image class="img" src="{{ IMG_LIUCHENG }}" mode="widthFix"></image> |
| | | </view> |
| | | </view> |
| | |
| | | .container { |
| | | background-color: #aca9a6; |
| | | .container .mine_bg { |
| | | width: 100%; |
| | | position: fixed; |
| | | top: 0; |
| | | left: 0; |
| | | z-index: -1; |
| | | } |
| | | .container .navbar { |
| | | padding-left: 30rpx; |
| | |
| | | .container .main_content .func_list .line .icon { |
| | | width: 40rpx; |
| | | } |
| | | .liucheng { |
| | | width: 100%; |
| | | padding: 0rpx 40rpx 120rpx; |
| | | text-align: center; |
| | | } |
| | | .liucheng .h1 { |
| | | margin-bottom: 16rpx; |
| | | font-weight: 600; |
| | | font-size: 36rpx; |
| | | } |
| | | .liucheng .h2 { |
| | | font-weight: 300; |
| | | font-size: 26rpx; |
| | | color: #333333; |
| | | margin-bottom: 40rpx; |
| | | } |
| | | .liucheng .img { |
| | | width: 100%; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | // pages/consult/consult.js |
| | | Page({ |
| | | |
| | | /** |
| | | * 页é¢çåå§æ°æ® |
| | | */ |
| | | data: { |
| | | category: ['æ°åä¸å¸', 'ä¸å©è¯ä¹¦', 'å¤§çææ','æ°åä¸å¸', 'ä¸å©è¯ä¹¦', 'å¤§çææ'], |
| | | secondCategory: ['级åç±»','级åç±»','级åç±»','级åç±»','级åç±»','级åç±»'], |
| | | activeCate: '', |
| | | seActiveCate: '', |
| | | dataList: [] |
| | | }, |
| | | |
| | | itemClick(e) { |
| | | const { id } = e.target.dataset |
| | | console.log(e.target.dataset); |
| | | wx.navigateTo({ |
| | | url: '/pages/consult/detail', |
| | | }) |
| | | }, |
| | | cateClick(e) { |
| | | const { index } = e.target.dataset |
| | | console.log(index); |
| | | }, |
| | | seCateClick(e) { |
| | | const { index } = e.target.dataset |
| | | console.log(index); |
| | | }, |
| | | onLoad(options) { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢å次渲æå®æ |
| | | */ |
| | | onReady() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢æ¾ç¤º |
| | | */ |
| | | onShow() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢éè |
| | | */ |
| | | onHide() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢å¸è½½ |
| | | */ |
| | | onUnload() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * 页é¢ç¸å
³äºä»¶å¤ç彿°--çå¬ç¨æ·ä¸æå¨ä½ |
| | | */ |
| | | onPullDownRefresh() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * 页é¢ä¸æè§¦åºäºä»¶çå¤ç彿° |
| | | */ |
| | | onReachBottom() { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * ç¨æ·ç¹å»å³ä¸è§å享 |
| | | */ |
| | | onShareAppMessage() { |
| | | |
| | | } |
| | | }) |
¶Ô±ÈÐÂÎļþ |
| | |
| | | { |
| | | "navigationBarTitleText": "产åè§é¢" |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | .container { |
| | | background-color: #fff; |
| | | } |
| | | .search_wrap{ |
| | | width: 670rpx; |
| | | height: 72rpx; |
| | | margin: 24rpx auto; |
| | | background: #F7F7F7; |
| | | border-radius: 8rpx; |
| | | padding: 0 40rpx; |
| | | display: flex; |
| | | align-items: center; |
| | | background-color: #F7F7F7; |
| | | image{ |
| | | width: 28rpx; |
| | | margin-right: 16rpx; |
| | | } |
| | | } |
| | | .scroll_cate { |
| | | display: flex; |
| | | align-items: center; |
| | | margin-left: 40rpx; |
| | | height: 60rpx; |
| | | .item { |
| | | margin-right: 54rpx; |
| | | color: #666666; |
| | | flex-shrink: 0; |
| | | } |
| | | |
| | | .active { |
| | | color: #222222; |
| | | font-weight: 500; |
| | | font-size: 30rpx; |
| | | } |
| | | } |
| | | |
| | | .second_list { |
| | | .item { |
| | | padding: 0 40rpx; |
| | | display: flex; |
| | | align-items: center; |
| | | font-size: 24rpx; |
| | | color: #333333; |
| | | height: 60rpx; |
| | | background: #F7F7F7; |
| | | border-radius: 8rpx; |
| | | margin-right: 24rpx; |
| | | } |
| | | .active{ |
| | | background-color: var(--themeColor); |
| | | color: #fff; |
| | | font-size: 24rpx; |
| | | font-weight: 400; |
| | | } |
| | | } |
| | | .content{ |
| | | padding: 0 40rpx 40rpx; |
| | | .item{ |
| | | .img{ |
| | | width: 100%; |
| | | } |
| | | .title{ |
| | | font-size: 30rpx; |
| | | color: #111111; |
| | | margin: 24rpx 0 12rpx; |
| | | } |
| | | .static{ |
| | | font-size: 24rpx; |
| | | color: #999999; |
| | | .liulan{ |
| | | width: 26rpx; |
| | | margin-right: 10rpx; |
| | | } |
| | | } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <view class="container"> |
| | | <view class="search_wrap"> |
| | | <image src="../../static/icon/ic_search@2x.png" mode="widthFix"></image> |
| | | <input type="text" placeholder="æç´¢å¨è¯¢æ é¢" /> |
| | | </view> |
| | | <!-- åç±» --> |
| | | <view> |
| | | <scroll-view scroll-x="true" style="weight: 710rpx;margin-bottom: 30rpx;"> |
| | | <view class="scroll_cate"> |
| | | <view bindtap="cateClick" data-index="{{index}}" wx:for="{{ category }}" class="item {{ index == 0 ? 'active': '' }}">{{ item }}</view> |
| | | </view> |
| | | </scroll-view> |
| | | <scroll-view scroll-x="true" style="weight: 710rpx;margin-bottom: 28rpx;"> |
| | | <view class="scroll_cate second_list"> |
| | | <view bindtap="seCateClick" data-index="{{index}}" wx:for="{{ secondCategory }}" class="item {{ index == 0 ? 'active': '' }}">{{ index }}{{ item }}</view> |
| | | </view> |
| | | </scroll-view> |
| | | </view> |
| | | <!-- content --> |
| | | <view class="content"> |
| | | <view class="item" bindtap="itemClick" data-abg="qwe"> |
| | | <image class="img" src="../../static/icon/test.png" mode="widthFix"></image> |
| | | <view class="title">åç¯å®ç¨ç¹è¾ | 䏿¥å¦ä¼çæ³å
å½±å¸å±</view> |
| | | <view class="df_sb static"> |
| | | <view>{{ '2021-08-21 12:00:00' }}</view> |
| | | <view class="df_sb"> |
| | | <image class="liulan" src="../../static/icon/zixun_ic_liulan.png" mode="widthFix"></image> |
| | | <text>1000</text> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | </view> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | .container { |
| | | background-color: #fff; |
| | | } |
| | | .search_wrap { |
| | | width: 670rpx; |
| | | height: 72rpx; |
| | | margin: 24rpx auto; |
| | | background: #F7F7F7; |
| | | border-radius: 8rpx; |
| | | padding: 0 40rpx; |
| | | display: flex; |
| | | align-items: center; |
| | | background-color: #F7F7F7; |
| | | } |
| | | .search_wrap image { |
| | | width: 28rpx; |
| | | margin-right: 16rpx; |
| | | } |
| | | .scroll_cate { |
| | | display: flex; |
| | | align-items: center; |
| | | margin-left: 40rpx; |
| | | height: 60rpx; |
| | | } |
| | | .scroll_cate .item { |
| | | margin-right: 54rpx; |
| | | color: #666666; |
| | | flex-shrink: 0; |
| | | } |
| | | .scroll_cate .active { |
| | | color: #222222; |
| | | font-weight: 500; |
| | | font-size: 30rpx; |
| | | } |
| | | .second_list .item { |
| | | padding: 0 40rpx; |
| | | display: flex; |
| | | align-items: center; |
| | | font-size: 24rpx; |
| | | color: #333333; |
| | | height: 60rpx; |
| | | background: #F7F7F7; |
| | | border-radius: 8rpx; |
| | | margin-right: 24rpx; |
| | | } |
| | | .second_list .active { |
| | | background-color: var(--themeColor); |
| | | color: #fff; |
| | | font-size: 24rpx; |
| | | font-weight: 400; |
| | | } |
| | | .content { |
| | | padding: 0 40rpx 40rpx; |
| | | } |
| | | .content .item .img { |
| | | width: 100%; |
| | | } |
| | | .content .item .title { |
| | | font-size: 30rpx; |
| | | color: #111111; |
| | | margin: 24rpx 0 12rpx; |
| | | } |
| | | .content .item .static { |
| | | font-size: 24rpx; |
| | | color: #999999; |
| | | } |
| | | .content .item .static .liulan { |
| | | width: 26rpx; |
| | | margin-right: 10rpx; |
| | | } |
| | |
| | | // pages/sets/index.js |
| | | import { wxLogOff } from '../../api/index' |
| | | Page({ |
| | | |
| | | /** |
| | |
| | | onClose() { |
| | | this.setData({show: false}) |
| | | }, |
| | | changeDeal(){ |
| | | onSubLgout() { |
| | | wxLogOff().then(res => { |
| | | wx.removeStorageSync('token') |
| | | wx.removeStorageSync('member') |
| | | wx.removeStorageSync('code') |
| | | wx.redirectTo({ |
| | | url: '/pages/index/index', |
| | | }) |
| | | }) |
| | | }, |
| | | changeDeal(e){ |
| | | const { label } = e.currentTarget.dataset |
| | | wx.navigateTo({ |
| | | url: '/pages/sets/protocol', |
| | | url: '/pages/sets/protocol?label=' + label, |
| | | }) |
| | | }, |
| | | |
| | |
| | | <view class="container"> |
| | | <view class="list"> |
| | | <view class="line" bindtap="changeDeal"> |
| | | <view class="line" data-label="SERVER_AGREEMENT" bindtap="changeDeal"> |
| | | <view class="name">ãZBOMç¨æ·æå¡åè®®ã</view> |
| | | <image class="icon" src="../../static/icon/home_ar@2x.png" mode="widthFix"></image> |
| | | </view> |
| | | <view class="line" bindtap="changeDeal"> |
| | | <view class="line" data-label="PRIVACY_AGREEMENT" bindtap="changeDeal"> |
| | | <view class="name">ãZBOMç¨æ·éç§åè®®ã</view> |
| | | <image class="icon" src="../../static/icon/home_ar@2x.png" mode="widthFix"></image> |
| | | </view> |
| | |
| | | <view class="title">注éæé</view> |
| | | <view class="text">妿¨ä¸åä½¿ç¨æ¤è´¦å·ï¼å¯ä»¥å°å
¶æ³¨éãè´¦å·æåæ³¨éåï¼å
¶ä¸æææ°æ®å°ä¼è¢«å é¤å¹¶å°æ æ³æ¢å¤ï¼è¯·è°¨æ
æä½</view> |
| | | <view class="btns"> |
| | | <view class="btn">确认注é</view> |
| | | <view class="btn" bindtap="onSubLgout">确认注é</view> |
| | | <view class="btn cancel" bindtap="onClose">è¿æ¯ç®äº</view> |
| | | </view> |
| | | </view> |
| | |
| | | // pages/sets/protocol.js |
| | | import { |
| | | getDictData |
| | | } from '../../api/index' |
| | | Page({ |
| | | |
| | | /** |
| | | * 页é¢çåå§æ°æ® |
| | | */ |
| | | data: { |
| | | |
| | | label: '', |
| | | activeHtml: '' |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢å è½½ |
| | | */ |
| | | onLoad(options) { |
| | | |
| | | const { label } = options |
| | | this.initData(label) |
| | | }, |
| | | |
| | | /** |
| | | * çå½å¨æå½æ°--çå¬é¡µé¢å次渲æå®æ |
| | | */ |
| | | onReady() { |
| | | |
| | | initData(label){ |
| | | getDictData({ |
| | | code: 'ZBOM_CUSTOMIZED', |
| | | label |
| | | }).then(res => { |
| | | wx.setNavigationBarTitle({ |
| | | title: res.data.remark |
| | | }) |
| | | this.setData({ |
| | | activeHtml: res.data.code |
| | | }) |
| | | }) |
| | | }, |
| | | |
| | | /** |
| | |
| | | { |
| | | "usingComponents": {} |
| | | "usingComponents": {}, |
| | | "navigationBarTitleText": "" |
| | | } |
| | |
| | | <!--pages/sets/protocol.wxml--> |
| | | <text>pages/sets/protocol.wxml</text> |
| | | <view class="container"> |
| | | <rich-text nodes="{{ activeHtml }}"></rich-text> |
| | | </view> |
| | |
| | | /* pages/sets/protocol.wxss */ |
| | | .container{ |
| | | padding: 40rpx; |
| | | } |
| | |
| | | { |
| | | "usingComponents": {} |
| | | "usingComponents": {}, |
| | | "navigationBarTitleText": "æ¨èé¨åº" |
| | | } |
| | |
| | | overflow: hidden; |
| | | text-overflow: ellipsis; |
| | | margin: 0 10rpx; |
| | | font-weight: 500; |
| | | font-size: 30rpx; |
| | | } |
| | | |
| | | .right { |
| | | width: 42rpx; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: flex-end; |
| | | font-size: 26rpx; |
| | | width: 160rpx; |
| | | image{ |
| | | width: 28rpx; |
| | | margin-right: 10rpx; |
| | | } |
| | | } |
| | | } |
| | | |
| | |
| | | <view> |
| | | <navBar title="æ¨èé¨åº"></navBar> |
| | | <view class="app_header"> |
| | | <image class="location" src="../../static/icon/location.png" mode="widthFix"></image> |
| | | <view bindtap="selAddress" class="add">{{ 111 }}</view> |
| | | <image class="right" src="../../static/icon/home_ar@2x.png" mode="widthFix"></image> |
| | | <view bindtap="selAddress" class="add">{{ 111 }}é¿å¤§ä½¿å¤§èµçé¿å¤§ä½¿å¤§èµçé¿å¤§ä½¿å¤§èµçé¿å¤§ä½¿å¤§èµç</view> |
| | | <view class="right"> |
| | | <image src="../../static/icon/ic_dingwei@2x.png" mode="widthFix"></image> |
| | | <text class="primary">éæ°å®ä½</text> |
| | | </view> |
| | | </view> |
| | | <view class="main_content"> |
| | | <view class="app_title">AIä¸ºæ¨æ¨è以ä¸é¨åºï¼</view> |
| | |
| | | overflow: hidden; |
| | | text-overflow: ellipsis; |
| | | margin: 0 10rpx; |
| | | font-weight: 500; |
| | | font-size: 30rpx; |
| | | } |
| | | .app_header .right { |
| | | width: 42rpx; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: flex-end; |
| | | font-size: 26rpx; |
| | | width: 160rpx; |
| | | } |
| | | .app_header .right image { |
| | | width: 28rpx; |
| | | margin-right: 10rpx; |
| | | } |
| | | .main_content { |
| | | padding: 40rpx; |
| | |
| | | // pages/userinfo/index.js |
| | | import { |
| | | uploadUrl, |
| | | editMember, |
| | | getMemberInfo |
| | | } from '../../api/index' |
| | | Page({ |
| | | |
| | | /** |
| | | * 页é¢çåå§æ°æ® |
| | | */ |
| | | data: { |
| | | imgurl: "", |
| | | imgurlFull: "", |
| | | name: "", |
| | | nickname: "", |
| | | phone: "", |
| | | address: '', |
| | | latitude: '', |
| | | longitude: '', |
| | | district: '', |
| | | housearea: '', |
| | | // åå¸ãå°å |
| | | region: [], |
| | | address: '' |
| | | |
| | | showHouseType: false, |
| | | houseType: { |
| | | val1: '', |
| | | val2: '', |
| | | val3: '', |
| | | val4: '', |
| | | val5: '', |
| | | } |
| | | }, |
| | | onLoad(options) { |
| | | |
| | | this.initData() |
| | | }, |
| | | onSubmit() { |
| | | |
| | | const { |
| | | imgurl, |
| | | name, |
| | | nickname, |
| | | phone, |
| | | address, |
| | | latitude, |
| | | longitude, |
| | | district, |
| | | housearea, |
| | | houseType |
| | | } = this.data |
| | | if (!nickname) return wx.showToast({ |
| | | title: '请è¾å
¥æµç§°', |
| | | icon: 'none' |
| | | }) |
| | | editMember({ |
| | | imgurl: imgurl || '', |
| | | name: name || '', |
| | | nickname: nickname || '', |
| | | phone: phone || '', |
| | | address: address || '', |
| | | latitude: latitude || '', |
| | | longitude: longitude || '', |
| | | district: district || '', |
| | | housearea: housearea || '', |
| | | housetype: houseType.val1 + '-' + houseType.val2 + '-' + houseType.val3 + '-' + houseType.val4 + '-' + houseType.val5 |
| | | }).then(res => { |
| | | wx.showToast({ |
| | | title: 'ä¿åæå', |
| | | icon: 'none' |
| | | }) |
| | | }) |
| | | }, |
| | | initData() { |
| | | getMemberInfo().then(res => { |
| | | if(res.data.housetype){ |
| | | const temp = res.data.housetype.split('-') |
| | | let houseType = { |
| | | val1: temp[0], |
| | | val2: temp[1], |
| | | val3: temp[2], |
| | | val4: temp[3], |
| | | val5: temp[4], |
| | | } |
| | | this.setData({houseType}) |
| | | } |
| | | this.setData({ |
| | | imgurlFull: res.data.imgurl ? res.data.prefix + res.data.imgurl : '', |
| | | imgurl: res.data.imgurl, |
| | | name: res.data.name || '', |
| | | nickname: res.data.nickname || '', |
| | | phone: res.data.phone || '', |
| | | address: res.data.address || '', |
| | | latitude: res.data.latitude || '', |
| | | longitude: res.data.longitude || '', |
| | | district: res.data.district || '', |
| | | housearea: res.data.housearea || '', |
| | | }) |
| | | }) |
| | | }, |
| | | changeAddr() { |
| | | console.log('ç¹å»äº'); |
| | | // console.log('ç¹å»äº'); |
| | | wx.chooseLocation({ |
| | | type: 'wgs84', |
| | | success: (res) => { |
| | | console.log('res', res); |
| | | this.setData({ |
| | | longitude: res.longitude, |
| | | latitude: res.latitude, |
| | | address: res.address, |
| | | }) |
| | | } |
| | | }) |
| | | }, |
| | |
| | | region: e.detail.value |
| | | }) |
| | | }, |
| | | openHouse() { |
| | | this.setData({ |
| | | showHouseType: true |
| | | }) |
| | | }, |
| | | onClose() { |
| | | this.setData({ |
| | | showHouseType: false |
| | | }) |
| | | }, |
| | | houseBlur(e) { |
| | | const { |
| | | str |
| | | } = e.currentTarget.dataset |
| | | const { |
| | | value |
| | | } = e.detail |
| | | const houseType = { |
| | | ...this.data.houseType |
| | | } |
| | | houseType[str] = value |
| | | this.setData({ |
| | | houseType |
| | | }) |
| | | }, |
| | | selMedia() { |
| | | console.log('dianjile'); |
| | | wx.chooseMedia({ |
| | | count: 1, |
| | | mediaType: ['image'], |
| | | sourceType: ['album', 'camera'], |
| | | maxDuration: 16, |
| | | camera: 'back', |
| | | success(res) { |
| | | console.log(res.tempFiles[0].tempFilePath) |
| | | console.log(res.tempFiles[0].size) |
| | | success: (res) => { |
| | | // console.log(res.tempFiles[0].tempFilePath) |
| | | // console.log(res.tempFiles[0].size) |
| | | wx.uploadFile({ |
| | | url: uploadUrl, //ä»
为示ä¾ï¼éçå®çæ¥å£å°å |
| | | filePath: res.tempFiles[0].tempFilePath, |
| | | name: 'file', |
| | | formData: { |
| | | folder: 'member' |
| | | }, |
| | | header: { |
| | | token: wx.getStorageSync('token') |
| | | }, |
| | | success: (ress) => { |
| | | // console.log('ress', JSON.parse(ress.data)); |
| | | let data = JSON.parse(ress.data) |
| | | this.setData({ |
| | | imgurl: data.data.imgaddr, |
| | | imgurlFull: data.data.url, |
| | | }) |
| | | setTimeout(() => { |
| | | console.log('imgurlFull', this.data.imgurlFull); |
| | | }, 1000) |
| | | } |
| | | }) |
| | | } |
| | | }) |
| | | }, |
| | |
| | | { |
| | | "usingComponents": { |
| | | "van-field": "@vant/weapp/field/index" |
| | | "van-field": "@vant/weapp/field/index", |
| | | "van-popup": "@vant/weapp/popup/index" |
| | | }, |
| | | "navigationBarTitleText": "ä¸ªäººèµæ" |
| | | } |
| | |
| | | border-radius: 50%; |
| | | box-shadow: 0rpx 2rpx 12rpx 0rpx rgba(0,0,0,0.08); |
| | | border: 4rpx solid #FFFFFF; |
| | | border: 1px solid; |
| | | } |
| | | .avatar_btn{ |
| | | width: 168rpx; |
| | |
| | | .input{ |
| | | flex: 1; |
| | | color: #111111; |
| | | border-bottom: 1rpx solid #e5e5e5; |
| | | } |
| | | .icon{ |
| | | width: 40rpx; |
| | |
| | | } |
| | | .val{ |
| | | flex: 1; |
| | | height: 78rpx; |
| | | height: 100rpx; |
| | | border-bottom: 1rpx solid #e5e5e5; |
| | | padding-left: 32rpx; |
| | | border-bottom: 1rpx solid #f7f7f7; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: space-between; |
| | |
| | | font-weight: 500; |
| | | font-size: 32rpx; |
| | | } |
| | | } |
| | | .modal{ |
| | | padding: 40rpx 30rpx; |
| | | .label{ |
| | | font-size: 30rpx; |
| | | } |
| | | .val{ |
| | | display: flex; |
| | | align-items: center; |
| | | color: #999999; |
| | | .item{ |
| | | display: flex; |
| | | align-items: center; |
| | | .unit{ |
| | | font-size: 24rpx; |
| | | } |
| | | .input{ |
| | | flex: 1; |
| | | } |
| | | input{ |
| | | text-align: right; |
| | | } |
| | | } |
| | | } |
| | | } |
| | |
| | | <view class="container"> |
| | | <image class="avatar" src="" mode="widthFix"></image> |
| | | <image class="avatar" src="{{ imgurlFull ? imgurlFull : '../../static/images/default_avatar.png' }}" mode="widthFix"></image> |
| | | <view bindtap="selMedia" class="avatar_btn">æ´æ¢å¤´å</view> |
| | | <view class="list"> |
| | | <view class="line"> |
| | | <view class="label">æµç§°</view> |
| | | <van-field type="text" class="input" model:value="{{ name }}" maxlength="{{ 18 }}" clearable /> |
| | | <van-field type="text" class="input" model:value="{{ nickname }}" maxlength="{{ 18 }}" clearable /> |
| | | </view> |
| | | <view class="line"> |
| | | <view class="label">å§å</view> |
| | | <van-field type="text" class="input" model:value="{{ name }}" maxlength="{{ 18 }}" clearable /> |
| | | <van-field type="text" border="{{ false }}" class="input" model:value="{{ name }}" maxlength="{{ 18 }}" clearable /> |
| | | </view> |
| | | <view class="line"> |
| | | <view class="label">çµè¯</view> |
| | | <van-field type="number" class="input" model:value="{{ name }}" maxlength="{{ 11 }}" clearable /> |
| | | <van-field type="number" border="{{ false }}" class="input" model:value="{{ phone }}" maxlength="{{ 11 }}" clearable /> |
| | | </view> |
| | | <view class="line"> |
| | | <view class="label">åå¸</view> |
| | | <view class="val"> |
| | | <view class="input"> |
| | | <view class="df_ac"> |
| | | <picker mode="region" bindchange="bindRegionChange" value="{{region}}"> |
| | | <view class="picker {{ region.length > 0 ? '' : 'placeholder9' }}"> |
| | | {{ region.length == 0 ? 'éæ©åå¸' : '' }}{{region[0]}}{{region[1]}}{{region[2]}} |
| | |
| | | <view class="line"> |
| | | <view class="label">å°å</view> |
| | | <view class="val" bindtap="changeAddr"> |
| | | <view class="input">{{ address }}</view> |
| | | <view class="df_ac">{{ address }}</view> |
| | | <image class="icon" src="../../static/icon/home_ar@2x.png" mode="widthFix"></image> |
| | | </view> |
| | | </view> |
| | | <view class="line"> |
| | | <view class="label">å°åº</view> |
| | | <van-field type="text" class="input" model:value="{{ name }}" maxlength="{{ 15 }}" clearable /> |
| | | <van-field type="text" border="{{ false }}" class="input" model:value="{{ district }}" maxlength="{{ 15 }}" clearable /> |
| | | </view> |
| | | <view class="line"> |
| | | <view class="label">é¢ç§¯</view> |
| | | <van-field type="text" class="input" model:value="{{ name }}" maxlength="{{ 15 }}" clearable /> |
| | | <van-field type="text" border="{{ false }}" class="input" model:value="{{ housearea }}" maxlength="{{ 15 }}" clearable /> |
| | | <!-- <text>m²</text> --> |
| | | </view> |
| | | <view class="line"> |
| | | <view class="label">æ·å</view> |
| | | <van-field type="text" class="input" model:value="{{ name }}" maxlength="{{ 15 }}" clearable /> |
| | | <view class="val" bindtap="openHouse"> |
| | | <view class="df_ac"> |
| | | <text class="item" wx:if="{{ houseType.val1 }}">{{ houseType.val1 }}室</text> |
| | | <text class="item" wx:if="{{ houseType.val2 }}">{{ houseType.val2 }}å
</text> |
| | | <text class="item" wx:if="{{ houseType.val3 }}">{{ houseType.val3 }}å¨</text> |
| | | <text class="item" wx:if="{{ houseType.val4 }}">{{ houseType.val4 }}å«</text> |
| | | <text class="item" wx:if="{{ houseType.val5 }}">{{ houseType.val5 }}é³</text> |
| | | </view> |
| | | <image class="icon" src="../../static/icon/home_ar@2x.png" mode="widthFix"></image> |
| | | </view> |
| | | </view> |
| | | <view bindtap="onSubmit" class="save">ä¿å</view> |
| | | </view> |
| | | <!-- --> |
| | | <van-popup show="{{ showHouseType }}" round position="bottom" custom-style="height: 30%" bind:close="onClose"> |
| | | <view class="modal"> |
| | | <view class="label">æ¿å±æ·å</view> |
| | | <view class="val"> |
| | | <view class="item"> |
| | | <van-field data-str="val1" bind:blur="houseBlur" type="number" class="input" maxlength="{{ 3 }}" /> |
| | | <view class="unit">室</view> |
| | | </view> |
| | | <view class="item"> |
| | | <van-field data-str="val2" bind:blur="houseBlur" type="number" class="input" maxlength="{{ 3 }}" /> |
| | | <view class="unit">å
</view> |
| | | </view> |
| | | <view class="item"> |
| | | <van-field data-str="val3" bind:blur="houseBlur" type="number" class="input" maxlength="{{ 3 }}" /> |
| | | <view class="unit">å¨</view> |
| | | </view> |
| | | <view class="item"> |
| | | <van-field data-str="val4" bind:blur="houseBlur" type="number" class="input" maxlength="{{ 3 }}" /> |
| | | <view class="unit">å«</view> |
| | | </view> |
| | | <view class="item"> |
| | | <van-field data-str="val5" bind:blur="houseBlur" type="number" class="input" maxlength="{{ 3 }}" /> |
| | | <view class="unit">é³</view> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | </van-popup> |
| | | |
| | | </view> |
| | |
| | | border-radius: 50%; |
| | | box-shadow: 0rpx 2rpx 12rpx 0rpx rgba(0, 0, 0, 0.08); |
| | | border: 4rpx solid #FFFFFF; |
| | | border: 1px solid; |
| | | } |
| | | .avatar_btn { |
| | | width: 168rpx; |
| | |
| | | .list .line .input { |
| | | flex: 1; |
| | | color: #111111; |
| | | border-bottom: 1rpx solid #e5e5e5; |
| | | } |
| | | .list .line .icon { |
| | | width: 40rpx; |
| | | } |
| | | .list .val { |
| | | flex: 1; |
| | | height: 78rpx; |
| | | height: 100rpx; |
| | | border-bottom: 1rpx solid #e5e5e5; |
| | | padding-left: 32rpx; |
| | | border-bottom: 1rpx solid #f7f7f7; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: space-between; |
| | |
| | | font-weight: 500; |
| | | font-size: 32rpx; |
| | | } |
| | | .modal { |
| | | padding: 40rpx 30rpx; |
| | | } |
| | | .modal .label { |
| | | font-size: 30rpx; |
| | | } |
| | | .modal .val { |
| | | display: flex; |
| | | align-items: center; |
| | | color: #999999; |
| | | } |
| | | .modal .val .item { |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | .modal .val .item .unit { |
| | | font-size: 24rpx; |
| | | } |
| | | .modal .val .item .input { |
| | | flex: 1; |
| | | } |
| | | .modal .val .item input { |
| | | text-align: right; |
| | | } |
| | |
| | | { |
| | | "appid": "wx9c8b22ccc4642e07", |
| | | "appid": "wx208dd1edc0be24ee", |
| | | "compileType": "miniprogram", |
| | | "libVersion": "3.4.10", |
| | | "packOptions": { |
| | |
| | | "urlCheck": false |
| | | }, |
| | | "description": "项ç®ç§æé
ç½®æä»¶ãæ¤æä»¶ä¸çå
容å°è¦ç project.config.json ä¸çç¸ååæ®µã项ç®çæ¹å¨ä¼å
忥尿¤æä»¶ä¸ãè¯¦è§ææ¡£ï¼https://developers.weixin.qq.com/miniprogram/dev/devtools/projectconfig.html", |
| | | "libVersion": "2.22.1", |
| | | "libVersion": "2.30.4", |
| | | "condition": { |
| | | "miniprogram": { |
| | | "list": [ |
| | |
| | | }, |
| | | { |
| | | "name": "", |
| | | "pathName": "pages/sets/index", |
| | | "pathName": "pages/auth/auth", |
| | | "query": "", |
| | | "launchMode": "default", |
| | | "scene": null |
| | | }, |
| | | { |
| | | "name": "", |
| | | "pathName": "pages/calculator/index", |
| | | "pathName": "pages/store/store", |
| | | "query": "", |
| | | "launchMode": "default", |
| | | "scene": null |
¶Ô±ÈÐÂÎļþ |
| | |
| | | |
| | | |
| | | // export const baseUrl = 'https://jiaxuan.zbom.com/jx/wechat/' //æ£å¼æå¡å¨ |
| | | export const baseUrl = 'http://192.168.0.135:10027' // æ¬å° |
| | | // export const baseUrl = 'http://zbtest.ahapp.net/zbom_interface/jx/wechat/' //æµè¯æå¡å¨ |
| | | |
| | | // export const imageUrl = 'https://osswebcdn.zbom.com/jiaxuan/images/' |
| | | |
| | | // è
¾è®¯å°å¾å¼åè
key |
| | | export const qqMapKey = 'HIDBZ-2QXL4-TAWUD-XET6Q-EKTJE-CCBSQ' |
| | | |
| | | /** |
| | | * æ¬å°åå¨ç¨æ·ä¿¡æ¯æ°æ® 10天 |
| | | */ |
| | | export const userInfoExpire = 10 * 24 * 60 * 60 * 1000 |
¶Ô±ÈÐÂÎļþ |
| | |
| | | import { baseUrl } from "./config" |
| | | |
| | | export function request(options){ |
| | | let loading = options.loading || '1' // é»è®¤å¼1æ¾ç¤ºï¼å¦å䏿¾ç¤º |
| | | if(loading == '1'){ |
| | | wx.showLoading() |
| | | } |
| | | return new Promise(resolve => { |
| | | wx.request({ |
| | | url: baseUrl + options.url, |
| | | data: options.data || {}, |
| | | method: options.method || "GET", |
| | | header: { |
| | | 'content-type': 'application/json;charset=utf-8', |
| | | 'token': wx.getStorageSync('token') || '' |
| | | }, |
| | | timeout: 12000, |
| | | success: (res) => { |
| | | if (res.data.code === 200) { |
| | | resolve(res.data || true) |
| | | } else { |
| | | if(res.data.code && res.data.code == 5112){ |
| | | wx.navigateTo({ |
| | | url: '/pages/auth/auth', |
| | | }) |
| | | } |
| | | res.data.message && wx.showToast({ |
| | | title: res.data.message || 'åçé误', |
| | | icon: 'none' |
| | | }) |
| | | } |
| | | }, |
| | | fail(err) { |
| | | console.log('err', err); |
| | | err.message && wx.showToast({ |
| | | title: err.message || 'åçé误', |
| | | icon: 'none' |
| | | }) |
| | | }, |
| | | complete() { |
| | | if(loading == '1'){ |
| | | wx.hideLoading() |
| | | } |
| | | } |
| | | }) |
| | | } ) |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | |
| | | |
| | | // export const baseUrl = 'https://jiaxuan.zbom.com/jx/wechat/' //æ£å¼æå¡å¨ |
| | | export const baseUrl = 'http://192.168.0.124:8080/zbom/jx/wechat/' // æ¬å° |
| | | // export const baseUrl = 'http://zbtest.ahapp.net/zbom_interface/jx/wechat/' //æµè¯æå¡å¨ |
| | | |
| | | |
| | | // export const imageUrl = 'https://osswebcdn.zbom.com/jiaxuan/images/' |
| | | |
| | | // è
¾è®¯å°å¾å¼åè
key |
| | | export const qqMapKey = 'HIDBZ-2QXL4-TAWUD-XET6Q-EKTJE-CCBSQ' |
| | | |
| | | /** |
| | | * æ¬å°åå¨ç¨æ·ä¿¡æ¯æ°æ® 10天 |
| | | */ |
| | | export const userInfoExpire = 10 * 24 * 60 * 60 * 1000 |
¶Ô±ÈÐÂÎļþ |
| | |
| | | import { baseUrl } from "./config" |
| | | |
| | | export function request(options){ |
| | | return new Promise(resolve => { |
| | | wx.request({ |
| | | url: baseUrl + options.url, |
| | | data: options.options || {}, |
| | | method: options.method || "GET", |
| | | header: { |
| | | 'content-type': 'application/x-www-form-urlencoded', |
| | | }, |
| | | timeout: 12000, |
| | | success: (res) => { |
| | | if (res.code === 0) { |
| | | // res.msg && toast(res.msg) |
| | | resolve(res.data || true) |
| | | } else { |
| | | res.msg && toast(res.msg || 'åçé误', 'none') |
| | | resolve(res.data || false) |
| | | } |
| | | }, |
| | | fail() { |
| | | wxToast('ç½ç»é误', 'none') |
| | | } |
| | | }) |
| | | } ) |
| | | } |
| | | |