mirror of
https://gitee.com/java110/WechatOwnerService.git
synced 2026-02-23 13:26:40 +08:00
优化支持APP测试
This commit is contained in:
parent
2c136dc47a
commit
3ba56b4142
@ -74,7 +74,7 @@
|
||||
},
|
||||
speed: {
|
||||
// 默认1s滚动100px
|
||||
type: Number,
|
||||
type: String,
|
||||
default: 100
|
||||
},
|
||||
color: {
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
<template>
|
||||
<scroll-view @scrolltolower="lower" class="scroll-restaurants-list " scroll-y="true" style="height:300upx">
|
||||
<!-- @scrolltolower="lower" -->
|
||||
<scroll-view class="scroll-restaurants-list " scroll-y="true" style="height:300upx">
|
||||
<swiper class=" padding-top-xs margin-top-sm bg-white c-radius" style="height: 280upx;" indicator-dots="true" indicator-color="rgba(228,228,228,1)"
|
||||
indicator-active-color="#FECA49">
|
||||
<block v-for="(item, index) in categoryList" :key="index">
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<view>
|
||||
<view v-if="discounts.length > 0">
|
||||
<view v-if="discounts && discounts.length > 0">
|
||||
<view class="block__title">折扣信息</view>
|
||||
<view class="cu-list menu" v-if="discounts.length > 0" v-for="(discount, idx) in discounts" :key="idx" :data-item="discount"
|
||||
@click="_viewDiscountDetail(discount)">
|
||||
@ -16,7 +16,7 @@
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<blockExplain v-if="discounts.length > 0"></blockExplain>
|
||||
<blockExplain v-if="discounts && discounts.length > 0"></blockExplain>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<view v-if="products.length > 0">
|
||||
<view v-if="products && products.length > 0">
|
||||
|
||||
<view v-for="(item,indexs) in products" :key="indexs" class="margin-top recommend-block">
|
||||
<view class="text-left ">
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<view class="margin-top" v-if="products.length > 0">
|
||||
<view class="margin-top" v-if="products && products.length > 0">
|
||||
|
||||
<view v-for="(item,indexs) in products" :key="indexs">
|
||||
<view class="text-left ">
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<view class="vc-shop margin-top " v-if="shops.length>0">
|
||||
<view class="vc-shop margin-top " v-if="shops && shops.length>0">
|
||||
<view class="text-left margin-left-xs margin-bottom-sm">
|
||||
<text class="recommend-title">附近商家</text>
|
||||
</view>
|
||||
|
||||
@ -12,6 +12,12 @@
|
||||
// 服务器域名 公众号时,配置为 / 就可以
|
||||
const baseUrl = '/';
|
||||
// #endif
|
||||
|
||||
// #ifndef H5
|
||||
//服务器域名 小程序 或者 app 时 后端地址
|
||||
const baseUrl = 'http://demo.homecommunity.cn/';
|
||||
// #endif
|
||||
|
||||
const commonBaseUrl = 'http://demo.homecommunity.cn/';
|
||||
|
||||
//商城的url
|
||||
@ -22,10 +28,7 @@ const mallUrlIndexPage = mallUrl + '#/pages/index/index?mallFrom=HC';
|
||||
//商城token 刷新页面
|
||||
const mallUrlRefresh = mallUrl + "#/pages/mallTokenRefresh/mallTokenRefresh?mallFrom=HC"
|
||||
|
||||
// #ifndef H5
|
||||
//服务器域名 小程序 或者 app 时 后端地址
|
||||
const baseUrl = 'http://demo.homecommunity.cn/';
|
||||
// #endif
|
||||
|
||||
|
||||
//默认的小区ID和名称,用户还没有登录时显示的小区信息
|
||||
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
|
||||
import conf from '../conf/config.js'
|
||||
|
||||
import md5 from '../utils/md5Util.js'
|
||||
import md5 from '../lib/java110/utils/md5Util.js'
|
||||
/*
|
||||
* 生成订单信息
|
||||
* @params orderInfo: any 后端返回的数据,格式和上面一样
|
||||
|
||||
@ -1,10 +1,17 @@
|
||||
import {
|
||||
requestNoAuth
|
||||
} from '../java110Request.js'
|
||||
import {
|
||||
saveOwnerStorage,
|
||||
saveUserLoginInfo,
|
||||
getWAppId,
|
||||
saveWAppId
|
||||
saveWAppId,
|
||||
getLoginFlag,
|
||||
getOwnerKey
|
||||
} from '../utils/StorageUtil.js'
|
||||
|
||||
import conf from '../../../config.js'
|
||||
|
||||
import url from '../../../constant/url.js'
|
||||
export function pageOnLoad(options) {
|
||||
|
||||
@ -23,16 +30,16 @@ export function getPageWAppId() {
|
||||
|
||||
export function pageCheckSession(_pageUrl,_call) {
|
||||
let _that = this;
|
||||
let loginFlag = wx.getStorageSync(mapping.LOGIN_FLAG);
|
||||
let loginFlag = getLoginFlag();
|
||||
let nowDate = new Date();
|
||||
|
||||
if (loginFlag && loginFlag.expireTime > nowDate.getTime()) {
|
||||
call();
|
||||
_call();
|
||||
return;
|
||||
}
|
||||
|
||||
//查询临时钥匙
|
||||
let _key = wx.getStorageSync(mapping.OWNER_KEY);
|
||||
let _key = getOwnerKey();;
|
||||
if (_key) {
|
||||
doLoginOwnerByKey(_key, _call);
|
||||
} else {
|
||||
|
||||
@ -23,9 +23,9 @@ const ERROR = "ERROR";
|
||||
* @param {Object} msg 打印内容
|
||||
*/
|
||||
export function debug(fileName,method,msg) {
|
||||
if (logLevel == DEBUG) {
|
||||
//if (logLevel == DEBUG) {
|
||||
console.log(formatTimeNow()+' ' + '[java110-debug] - ' + fileName + ':'+method+' ',msg);
|
||||
}
|
||||
//}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -92,6 +92,11 @@ export function getLoginFlag(){
|
||||
return loginFlag;
|
||||
}
|
||||
|
||||
export function getOwnerKey(){
|
||||
let ownerKey = wx.getStorageSync(OWNER_KEY);
|
||||
return ownerKey;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取wAppId
|
||||
*/
|
||||
|
||||
@ -112,6 +112,8 @@
|
||||
that.roomIdArr = roomIdArr;
|
||||
that.userId = res.data.owner.appUserId;
|
||||
that.communityId = res.data.owner.communityId;
|
||||
that.complaintName = res.data.owner.appUserName;
|
||||
that.tel = res.data.owner.link;
|
||||
});
|
||||
},
|
||||
|
||||
|
||||
@ -3,8 +3,8 @@
|
||||
<view class="margin-bottom-xs">
|
||||
<uni-notice-bar showIcon="true" scrollable="true" single="true" speed="30" text="欢迎访问HC智慧家园"></uni-notice-bar>
|
||||
</view>
|
||||
|
||||
<scroll-view @scrolltolower="lower" class="scroll-restaurants-list" scroll-y="true" style="height:100%">
|
||||
<!--@scrolltolower="lower"-->
|
||||
<scroll-view class="scroll-restaurants-list" scroll-y="true" style="height:100%">
|
||||
<swiper class="categoryList padding-top-xs bg-white" indicator-dots="true" indicator-color="rgba(228,228,228,1)"
|
||||
indicator-active-color="#FECA49">
|
||||
<block v-for="(item, index) in categoryList" :key="index">
|
||||
@ -36,8 +36,8 @@
|
||||
</swiper-item>
|
||||
</block>
|
||||
</swiper>
|
||||
|
||||
<scroll-view scroll-x class="bg-white nav" scroll-with-animation :scroll-left="scrollLeft">
|
||||
<!--:scroll-left="scrollLeft"-->
|
||||
<scroll-view scroll-x class="bg-white nav" scroll-with-animation >
|
||||
<view class="cu-item" :class="item.typeCd==curTypeCd?'text-green cur':''" v-for="(item,index) in activitiTitle"
|
||||
:key="index" @tap="selectActiviti(item)" :data-id="index">
|
||||
{{item.typeName}}
|
||||
@ -106,7 +106,7 @@
|
||||
row: 7,
|
||||
activitiTitle: [],
|
||||
curTypeCd: '',
|
||||
categoryList: {},
|
||||
categoryList: [],
|
||||
selected: 0,
|
||||
mask1Hidden: true,
|
||||
mask2Hidden: true,
|
||||
|
||||
@ -11,7 +11,8 @@
|
||||
</view>
|
||||
</view>
|
||||
<view class="">
|
||||
<scroll-view scroll-x class="nav nav-scroll padding-bottom-xs" scroll-with-animation :scroll-left="scrollLeft">
|
||||
<!--:scroll-left="scrollLeft"-->
|
||||
<scroll-view scroll-x class="nav nav-scroll padding-bottom-xs" scroll-with-animation >
|
||||
<view class="cu-item text-white" :class="item.shopTypeId==shopTypeId?'nav-cur':''"
|
||||
v-for="(item,index) in navList" :key="index" @tap="selectType(index)" :data-id="index">
|
||||
{{item.typeName}}
|
||||
|
||||
@ -191,6 +191,8 @@
|
||||
that.roomIdArr = roomIdArr;
|
||||
that.userId = res.data.owner.userId;
|
||||
that.userName = res.data.owner.appUserName;
|
||||
that.bindRepairName = that.userName;
|
||||
that.bindTel = res.data.owner.link;
|
||||
that.communityId = res.data.owner.communityId;
|
||||
that.communityName = res.data.owner.communityName;
|
||||
});
|
||||
|
||||
Loading…
Reference in New Issue
Block a user