修改估分地区

This commit is contained in:
qiaocl 2024-10-11 17:23:56 +08:00
parent 73cfd5140b
commit cbad43df91
79 changed files with 309 additions and 282 deletions

View File

@ -11,7 +11,7 @@
<text class="mr-10">性别{{info.gender==1?'男':info.gender==2?'女':'未知'}}</text>
<text class="ml-10">年龄{{info.age}}</text>
</view>
<view class="mt-10">地区{{info.address}}</view>
<view class="mt-10">当前地区{{info.address}}</view>
</view>
<text class="t-icon t-icon-qiehuan1" @click="$store.commit('changeDrawe', true)" v-if="isLeft"></text>
</view>
@ -27,7 +27,7 @@
<!-- 地区 -->
<view class="cityList">
<view class="area" v-if="isArea" @click="visible = true">
<view>选择地区标准</view>
<view>中招地区标准</view>
<view>{{region?region:info.address}}<uni-icons type="bottom"></uni-icons></view>
</view>
<!-- -->
@ -86,8 +86,8 @@
userList() {
return this.familayList
},
userId() {
return this.user.id
userAddress() {
return this.user.address
},
},
props: {
@ -109,7 +109,7 @@
}, 1000);
},
watch: {
userId() {
userAddress() {
let that = this
that.region = that.user.address
that.handleCityList()

View File

@ -108,22 +108,12 @@
that.$store.commit("changeBluetooth", res.available);
})
},
// #ifdef APP-PLUS
onBackPress(options) {
let that = this
that.handleEnd()
innerAudioContext.stop();
console.log("PCT01返回onBackPress")
},
// #endif
// #ifndef APP-PLUS
onUnload: function() {
let that = this
that.handleEnd()
innerAudioContext.stop();
console.log("PCT01返回onUnload")
},
// #endif
watch: {
isConnected: function() {
let that = this
@ -185,7 +175,6 @@
let that = this
if (that.isStart) {
that.handleAudio()
console.log("11111111")
}
}
},
@ -293,8 +282,10 @@
cancelText: "返回",
success: function(res) {
if (res.cancel) {
that.handleEnd()
innerAudioContext.stop();
uni.navigateBack({ //
delta: 1
})
}
},
})
@ -341,6 +332,7 @@
if (res.code == 0) {
that.bpm = that.weight / (that.time / 60)
that.iswrapper = true
that.info.isSuccessful = true
that.$store.dispatch('getUserInfo', {
aud_id: uni.getStorageSync('userid')
})
@ -387,7 +379,6 @@
},
handleTarget() {
let that = this
uni.$emit('updateData', JSON.stringify(that.info))
uni.navigateBack({ //
delta: 1
})
@ -400,9 +391,7 @@
that.handleStart('结束')
}, 400)
setTimeout(function() {
uni.redirectTo({
url: "/pages/skiping/skip?info=" + JSON.stringify(that.info)
})
uni.$emit('updateData', JSON.stringify(that.info))
}, 600)
}
}

View File

@ -149,12 +149,13 @@
labelList() {
let that = this
if (that.PublicContent) {
that.labelName = that.PublicContent.label_list[0]
that.labelName = that.PublicContent.label_list[that.active]
that.lineList = that.PublicContent.line_list
that.label_data = that.PublicContent.label_data
that.chartData.series[0].data = Number(that.PublicContent.label_data[0].offset) / 100
that.offset = that.PublicContent.label_data[0].offset
that.chartData.series[0].data = Number(that.PublicContent.label_data[that.active].offset) / 100
that.offset = that.PublicContent.label_data[that.active].offset
}
console.log("11111", that.PublicContent, that.active, that.labelName)
return that.PublicContent ? that.PublicContent.label_list : []
},
},

View File

@ -40,16 +40,6 @@
</view>
</view>
</view>
<!-- <view class="list">
<view class="item border-bottom">
<view class="left">
<view class="name">意见反馈</view>
</view>
<view class="right">
<uni-icons type="right"></uni-icons>
</view>
</view>
</view> -->
<!-- #ifdef APP-PLUS -->
<view class="list" @click="navTo('/pageTwo/my/about')">
<view class="item border-bottom">
@ -62,16 +52,6 @@
</view>
</view>
<!-- #endif -->
<!-- <view class="list" @click="navTo('/pages/login/forgetPassword?type=forgetPassword')">
<view class="item border-bottom">
<view class="left">
<view class="name">重置密码</view>
</view>
<view class="right">
<uni-icons type="right"></uni-icons>
</view>
</view>
</view> -->
</view>
<view class="btn mb-15" v-if="token" @click="handleOutLogin">退出登录</view>
</view>
@ -207,9 +187,6 @@
overflow: hidden;
position: relative;
.item {
width: auto;
font-size: 32rpx;
@ -230,6 +207,14 @@
}
}
.href {
display: flex;
width: 100%;
color: #000;
text-decoration: none;
justify-content: space-between;
}
.btn {
width: auto;
background: $btncolor;

View File

@ -1,12 +1,12 @@
<template>
<view class="content">
<!-- 头部 -->
<headerIndex @getAciveCity="getAciveCity"></headerIndex>
<headerIndex @getAciveCity="getAciveCity" v-if="!isRefresh"></headerIndex>
<!-- 估分 -->
<view class="box">
<view class="title bold">本次估分成绩为</view>
<view class="charts mt-15">
<qiun-data-charts type="arcbar" :chartData="chartData" :Height="140" :Width="140"/>
<qiun-data-charts type="arcbar" :chartData="chartData" :Height="140" :Width="140" />
<view class="name">{{score?score:'--'}}</view>
</view>
<view class="btn history" @click="navTo('/pageTwo/score/history')">估分历史</view>
@ -83,8 +83,9 @@
<uni-icons :type="isActive.name==item.name?'circle-filled':'circle'" size="22"
:color="isActive.name==item.name?'#FEC407':'#dfdfdf'" v-if="choice==1"></uni-icons>
<!-- 多选 -->
<uni-icons :type="isActiveList.indexOf(item)!=-1?'checkbox-filled':'circle'" size="22"
:color="isActiveList.indexOf(item)!=-1?'#FEC407':'#dfdfdf'" v-if="choice>1"></uni-icons>
<uni-icons :type="isActiveNameList.indexOf(item.name)!=-1?'checkbox-filled':'circle'" size="22"
:color="isActiveNameList.indexOf(item.name)!=-1?'#FEC407':'#dfdfdf'"
v-if="choice>1"></uni-icons>
<!-- -->
<view class="name">
<view class="overflow">
@ -124,6 +125,7 @@
selectllist: [],
isActive: {},
isActiveList: [],
isActiveNameList: [],
region_list: {},
timeList: [],
timesTndex: [0, 0],
@ -131,14 +133,19 @@
msg: "暂无信息",
address: "",
isresult: false,
choice: 0
choice: 0,
isRefresh: false,
info: []
}
},
computed: {
...mapState(["user", "familayList"]),
userAddress() {
return this.user.address
},
userId() {
return this.user.id
}
},
},
components: {
uslider,
@ -155,6 +162,7 @@
that.address = that.user.address
that.getList()
}
console.log("onLoad")
},
onPullDownRefresh() {
let that = this
@ -163,14 +171,17 @@
that.Max_score = 0
that.selectllist = []
that.sportsList = []
that.isRefresh = true
that.timeList = that.$tools.gethms()
if (that.familayList.length) {
that.address = that.user.address
that.getList()
}
setTimeout(() => {
that.isRefresh = false
uni.stopPullDownRefresh()
}, 1000);
}, 200);
console.log("刷新")
},
onShow() {
let that = this
@ -182,19 +193,19 @@
that.selectllist = []
that.sportsList = []
that.isActiveList = []
that.isActiveNameList = []
that.chartData.series[0].data = 0.8
}
},
watch: {
// userId() {
// userAddress() {
// let that = this
// that.score = 0
// that.selectllist = []
// that.sportsList = []
// that.address = that.user.address
// that.getList()
// that.handleSportsList()
// console.log("user", that.sportsList, that.selectllist)
// console.log("user", that.sportsList, that.selectllist)
// },
},
methods: {
@ -207,6 +218,7 @@
that.selectllist = []
that.sportsList = []
that.isActiveList = []
that.isActiveNameList = []
that.getList()
},
//
@ -291,7 +303,7 @@
that.choice = item.is_choice
}
})
// console.log("", item)
console.log("添加项目", item)
that.isDrawe = true
},
bindTimeChange(e, it) {
@ -304,36 +316,49 @@
//
toggle(item) {
let that = this
//
if (that.choice == 1) {
that.isActive = that.isActive.name == item.name ? {} : item
return
}
if (that.isActiveList.indexOf(item.name) == -1) {
//
if (that.isActiveNameList.indexOf(item.name) == -1) {
that.isActiveNameList.push(item.name)
that.isActiveList.push(item)
} else {
that.isActiveList = that.isActiveList.filter(ite => ite.name !== item.name)
for (var n = 0; n < that.isActiveNameList.length; n++) {
if (item.name == that.isActiveNameList[n]) {
if (that.isActiveNameList.indexOf(item.name) == -1) {
that.isActiveNameList.push(item.name)
that.isActiveList.push(item);
}
that.isActiveNameList.splice(n, 1)
that.isActiveList.splice(n, 1);
}
}
}
if (that.isActiveList.length > that.choice) {
that.isActiveList.splice(0, 1)
that.isActiveNameList.splice(0, 1)
}
// console.log("isActiveList", that.selectllist, that.region_list, item)
console.log("isActiveList", item.name, that.isActiveList, that.region_list.list)
},
//
handleTarget() {
let that = this
// console.log('', that.selectllist, that.region_list)
that.selectllist.forEach(item => {
item.list.forEach(it => {
if (it.key == that.region_list.key) {
it.list = []
}
})
})
if (that.choice == 1) {
that.region_list.list.push(that.isActive)
} else {
that.region_list.list = that.isActiveList
}
that.selectllist.forEach(item => {
item.list.forEach(it => {
if (it.key == that.region_list.key) {
it.list = that.region_list.list
}
})
})
that.isDrawe = false
},
handleTips(text) {
@ -348,6 +373,11 @@
this.isActive = {}
this.isDrawe = false
},
handleTap() {
// this.isActive = {}
// this.isDrawe = false
console.log('quxiao', this.info)
},
navTo(url) {
uni.navigateTo({
url: url

View File

@ -126,7 +126,6 @@
active: 1,
acd_id: 6,
weight: 50,
Unload: false,
disabled: false,
isDevice: 0,
isConnection: false,
@ -167,18 +166,6 @@
that.handleisSdevice()
}, 1000)
}
//
if (options && options.info) {
let data = JSON.parse(options.info)
that.Unload = true
that.active = data.active
that.deviceId = data.deviceId
that.serviceId = data.serviceId
that.write = data.write
that.notify = data.notify
that.islink = !that.isConnected ? -1 : 1
that.notifyBLECharacteristicValue()
}
that.$store.dispatch("getSkipResult", {
aud_id: uni.getStorageSync('userid')
})
@ -196,56 +183,48 @@
onShow() {
let that = this
//
uni.$on('updateData', function(data) {
let info = JSON.parse(data)
that.acd_id = info.acd_id
that.isDevice = info.device
console.log('监听到事件来自 updateData ,携带参数为:' + info);
uni.$on('updateData', function(info) {
let data = JSON.parse(info)
that.acd_id = data.acd_id
that.isDevice = data.device
that.active = data.active
that.deviceId = data.deviceId
that.serviceId = data.serviceId
that.write = data.write
that.notify = data.notify
that.islink = !that.isConnected ? -1 : 1
that.isConnection = that.isConnected
that.notifyBLECharacteristicValue()
if (data.isSuccessful) {
that.$store.dispatch("getSkipResult", {
aud_id: uni.getStorageSync('userid')
})
}
that.$Bluetooth.onBLEConnectionStateChange()
uni.onBluetoothAdapterStateChange(function(res) {
that.$store.commit("changeBluetooth", res.available);
})
console.log('监听到事件来自 updateData', data);
})
},
// #ifdef APP-PLUS
onBackPress() {
onUnload: function() {
let that = this
that.islink = -1
clearTimeout(myTime);
that.islink = -1
that.isConnection = false
console.log("返回首页onBackPress")
that.$Bluetooth.closeBluetoothAdapter()
that.$Bluetooth.closeBLEConnection(that.deviceId)
that.$Bluetooth.stopBluetoothDevicesDiscovery()
that.$store.commit("changeBluetooth", false);
that.$store.commit("changeConnected", false);
uni.$off("updateData")
setTimeout(() => {
uni.switchTab({
url: '/pages/home/home'
})
}, 300)
return true
},
// #endif
// #ifndef APP-PLUS
onUnload: function() {
let that = this
// clearTimeout(myTime);
// that.islink = -1
// that.isConnection = false
// that.$Bluetooth.closeBluetoothAdapter()
// that.$Bluetooth.closeBLEConnection(that.deviceId)
// that.$Bluetooth.stopBluetoothDevicesDiscovery()
// that.$store.commit("changeBluetooth", false);
// that.$store.commit("changeConnected", false);
// setTimeout(() => {
uni.switchTab({
url: '/pages/home/home'
})
// }, 300)
let pages = getCurrentPages()
let prevPage = pages[pages.length - 2]
console.log("prevPage", prevPage)
uni.$off("updateData")
console.log("返回首页onUnload")
},
// #endif
watch: {
devicesList() {
let that = this
@ -426,7 +405,6 @@
success(res) {
uni.onBLECharacteristicValueChange(function(res) {
let value = that.$tools.ab2hex(res.value, "");
console.log("1111跳", value)
if (value == '5a05090169') { //
let info = {
active: that.active,
@ -435,9 +413,11 @@
notify: that.notify,
write: that.write,
acd_id: that.acd_id,
isDevice: that.isDevice
isDevice: that.isDevice,
isSuccessful: false
}
setTimeout(function() {
uni.$off("updateData")
uni.navigateTo({
url: "/pageTwo/devices/PCT01?info=" + JSON
.stringify(info)

View File

@ -9,7 +9,7 @@ export default {
return model.getAccountNumber({}).then(res => {
console.log("账户信息", res.data)
if (res.code != 0) {
that.$tools.msg(res.msg)
tools.msg(res.msg)
return
}
commit('changeAccountNumber', res.data)
@ -24,7 +24,7 @@ export default {
return model.getUserInfo(account).then(res => {
console.log("用户信息", res.data)
if (res.code != 0) {
that.$tools.msg(res.msg)
tools.msg(res.msg)
return
}
uni.setStorageSync('userid', res.data.id)
@ -40,7 +40,7 @@ export default {
account) {
return model.getUserList(account).then(res => {
if (res.code != 0) {
that.$tools.msg(res.msg)
tools.msg(res.msg)
return
}
commit('changeFamilay', res.data)

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -2556,7 +2556,7 @@ var render = function () {
_c(
"uni-view",
{ staticClass: _vm._$g(10, "sc"), attrs: { _i: 10 } },
[_vm._v("地区:" + _vm._$g(10, "t0-0"))]
[_vm._v("当前地区:" + _vm._$g(10, "t0-0"))]
),
],
1
@ -2621,7 +2621,7 @@ var render = function () {
},
[
_c("uni-view", { attrs: { _i: 17 } }, [
_vm._v("选择地区标准:"),
_vm._v("中招地区标准:"),
]),
_c(
"uni-view",
@ -16585,7 +16585,7 @@ if(false) {}
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ./node_modules/css-loader/dist/runtime/api.js */ 13);
exports = ___CSS_LOADER_API_IMPORT___(false);
// Module
exports.push([module.i, "@charset \"UTF-8\";\n/* 主题色 */\n.content[data-v-b74f0dfc] {\n background-color: #F3F4F6;\n padding: 15px;\n min-height: 100vh;\n}\n.top[data-v-b74f0dfc] {\n height: auto;\n background: #fff;\n border-radius: 10px;\n display: flex;\n padding: 10px;\n align-items: center;\n justify-content: space-between;\n}\n.top .headimg[data-v-b74f0dfc] {\n width: 80%;\n display: flex;\n align-items: center;\n}\n.top .headimg uni-view[data-v-b74f0dfc] {\n width: calc(100% - 70px);\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n.top uni-image[data-v-b74f0dfc] {\n width: 60px;\n height: 60px;\n border-radius: 50%;\n margin-right: 10px;\n}\n.wxlist[data-v-b74f0dfc] {\n height: auto;\n overflow: hidden;\n position: relative;\n}\n.wxlist .item[data-v-b74f0dfc] {\n width: auto;\n font-size: 32rpx;\n line-height: 45px;\n height: 45px;\n display: flex;\n margin-top: 15px;\n background: #fff;\n padding: 0 10px;\n border-radius: 10px;\n justify-content: space-between;\n align-items: center;\n}\n.wxlist .item .left[data-v-b74f0dfc] {\n display: flex;\n align-items: center;\n}\n.btn[data-v-b74f0dfc] {\n width: auto;\n background: #fea606;\n margin: 50px 15px 0 15px;\n}\n", ""]);
exports.push([module.i, "@charset \"UTF-8\";\n/* 主题色 */\n.content[data-v-b74f0dfc] {\n background-color: #F3F4F6;\n padding: 15px;\n min-height: 100vh;\n}\n.top[data-v-b74f0dfc] {\n height: auto;\n background: #fff;\n border-radius: 10px;\n display: flex;\n padding: 10px;\n align-items: center;\n justify-content: space-between;\n}\n.top .headimg[data-v-b74f0dfc] {\n width: 80%;\n display: flex;\n align-items: center;\n}\n.top .headimg uni-view[data-v-b74f0dfc] {\n width: calc(100% - 70px);\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n.top uni-image[data-v-b74f0dfc] {\n width: 60px;\n height: 60px;\n border-radius: 50%;\n margin-right: 10px;\n}\n.wxlist[data-v-b74f0dfc] {\n height: auto;\n overflow: hidden;\n position: relative;\n}\n.wxlist .item[data-v-b74f0dfc] {\n width: auto;\n font-size: 32rpx;\n line-height: 45px;\n height: 45px;\n display: flex;\n margin-top: 15px;\n background: #fff;\n padding: 0 10px;\n border-radius: 10px;\n justify-content: space-between;\n align-items: center;\n}\n.wxlist .item .left[data-v-b74f0dfc] {\n display: flex;\n align-items: center;\n}\n.href[data-v-b74f0dfc] {\n display: flex;\n width: 100%;\n color: #000;\n text-decoration: none;\n justify-content: space-between;\n}\n.btn[data-v-b74f0dfc] {\n width: auto;\n background: #fea606;\n margin: 50px 15px 0 15px;\n}\n", ""]);
// Exports
module.exports = exports;
@ -16700,14 +16700,16 @@ var render = function () {
"uni-view",
{ staticClass: _vm._$g(0, "sc"), attrs: { _i: 0 } },
[
_c("headerIndex", {
_vm._$g(1, "i")
? _c("headerIndex", {
attrs: { _i: 1 },
on: {
getAciveCity: function ($event) {
return _vm.$handleViewEvent($event)
},
},
}),
})
: _vm._e(),
_c(
"uni-view",
{ staticClass: _vm._$g(2, "sc"), attrs: { _i: 2 } },

View File

@ -10999,7 +10999,7 @@ var _default = {
return _model.default.getAccountNumber({}).then(function (res) {
console.log("账户信息", res.data);
if (res.code != 0) {
that.$tools.msg(res.msg);
_tools.default.msg(res.msg);
return;
}
commit('changeAccountNumber', res.data);
@ -11011,7 +11011,7 @@ var _default = {
return _model.default.getUserInfo(account).then(function (res) {
console.log("用户信息", res.data);
if (res.code != 0) {
that.$tools.msg(res.msg);
_tools.default.msg(res.msg);
return;
}
uni.setStorageSync('userid', res.data.id);
@ -11025,7 +11025,7 @@ var _default = {
var commit = _ref3.commit;
return _model.default.getUserList(account).then(function (res) {
if (res.code != 0) {
that.$tools.msg(res.msg);
_tools.default.msg(res.msg);
return;
}
commit('changeFamilay', res.data);

View File

@ -202,8 +202,8 @@ var _default = {
userList: function userList() {
return this.familayList;
},
userId: function userId() {
return this.user.id;
userAddress: function userAddress() {
return this.user.address;
}
}),
props: {
@ -225,7 +225,7 @@ var _default = {
}, 1000);
},
watch: {
userId: function userId() {
userAddress: function userAddress() {
var that = this;
that.region = that.user.address;
that.handleCityList();

View File

@ -1 +1 @@
<view class="data-v-ef249ed8"><view class="header data-v-ef249ed8"><block wx:if="{{$root.g0}}"><view class="top data-v-ef249ed8"><view data-event-opts="{{[['tap',[['handleAddUser',[1]]]]]}}" class="headimg data-v-ef249ed8" bindtap="__e"><image src="{{info.head_pic}}" class="data-v-ef249ed8"></image></view><view data-event-opts="{{[['tap',[['handleAddUser',[1]]]]]}}" class="info data-v-ef249ed8" bindtap="__e"><view class="size18 bold data-v-ef249ed8">{{info.nickname}}</view><view class="mt-10 data-v-ef249ed8"><text class="mr-10 data-v-ef249ed8">{{"性别:"+(info.gender==1?'男':info.gender==2?'女':'未知')}}</text><text class="ml-10 data-v-ef249ed8">{{"年龄:"+info.age+"岁"}}</text></view><view class="mt-10 data-v-ef249ed8">{{"地区:"+info.address}}</view></view><block wx:if="{{isLeft}}"><text data-event-opts="{{[['tap',[['e0',['$event']]]]]}}" class="t-icon t-icon-qiehuan1 data-v-ef249ed8" bindtap="__e"></text></block></view></block><block wx:else><view data-event-opts="{{[['tap',[['handleAddUser',[2]]]]]}}" class="top data-v-ef249ed8" bindtap="__e"><view class="info data-v-ef249ed8">暂无成员,请先添加~</view><view class="add data-v-ef249ed8">+</view></view></block></view><view class="cityList data-v-ef249ed8"><block wx:if="{{isArea}}"><view data-event-opts="{{[['tap',[['e1',['$event']]]]]}}" class="area data-v-ef249ed8" bindtap="__e"><view class="data-v-ef249ed8">选择地区标准:</view><view class="data-v-ef249ed8">{{region?region:info.address}}<uni-icons vue-id="f56e3a1c-1" type="bottom" class="data-v-ef249ed8" bind:__l="__l"></uni-icons></view></view></block><block wx:if="{{visible}}"><view data-event-opts="{{[['tap',[['e2',['$event']]]]]}}" class="visible data-v-ef249ed8" bindtap="__e"><view data-event-opts="{{[['tap',[['',['$event']]]]]}}" class="item data-v-ef249ed8" catchtap="__e"><view class="groupBtn data-v-ef249ed8"><view data-event-opts="{{[['tap',[['e3',['$event']]]]]}}" bindtap="__e" class="data-v-ef249ed8">取消</view><view data-event-opts="{{[['tap',[['handlesure']]]]}}" class="sure data-v-ef249ed8" bindtap="__e">确定</view></view><picker-view class="picker-view data-v-ef249ed8" value="{{value}}" indicator-style="{{indicatorStyle}}" data-event-opts="{{[['change',[['bindChange',['$event']]]]]}}" bindchange="__e"><picker-view-column class="data-v-ef249ed8"><block wx:for="{{province}}" wx:for-item="item" wx:for-index="index" wx:key="index"><view class="item data-v-ef249ed8">{{item.name}}</view></block></picker-view-column><picker-view-column class="data-v-ef249ed8"><block wx:for="{{city}}" wx:for-item="item" wx:for-index="index" wx:key="index"><view class="item data-v-ef249ed8">{{item}}</view></block></picker-view-column></picker-view></view></view></block></view><drawer vue-id="f56e3a1c-2" class="data-v-ef249ed8" bind:__l="__l"></drawer></view>
<view class="data-v-ef249ed8"><view class="header data-v-ef249ed8"><block wx:if="{{$root.g0}}"><view class="top data-v-ef249ed8"><view data-event-opts="{{[['tap',[['handleAddUser',[1]]]]]}}" class="headimg data-v-ef249ed8" bindtap="__e"><image src="{{info.head_pic}}" class="data-v-ef249ed8"></image></view><view data-event-opts="{{[['tap',[['handleAddUser',[1]]]]]}}" class="info data-v-ef249ed8" bindtap="__e"><view class="size18 bold data-v-ef249ed8">{{info.nickname}}</view><view class="mt-10 data-v-ef249ed8"><text class="mr-10 data-v-ef249ed8">{{"性别:"+(info.gender==1?'男':info.gender==2?'女':'未知')}}</text><text class="ml-10 data-v-ef249ed8">{{"年龄:"+info.age+"岁"}}</text></view><view class="mt-10 data-v-ef249ed8">{{"当前地区:"+info.address}}</view></view><block wx:if="{{isLeft}}"><text data-event-opts="{{[['tap',[['e0',['$event']]]]]}}" class="t-icon t-icon-qiehuan1 data-v-ef249ed8" bindtap="__e"></text></block></view></block><block wx:else><view data-event-opts="{{[['tap',[['handleAddUser',[2]]]]]}}" class="top data-v-ef249ed8" bindtap="__e"><view class="info data-v-ef249ed8">暂无成员,请先添加~</view><view class="add data-v-ef249ed8">+</view></view></block></view><view class="cityList data-v-ef249ed8"><block wx:if="{{isArea}}"><view data-event-opts="{{[['tap',[['e1',['$event']]]]]}}" class="area data-v-ef249ed8" bindtap="__e"><view class="data-v-ef249ed8">中招地区标准:</view><view class="data-v-ef249ed8">{{region?region:info.address}}<uni-icons vue-id="f56e3a1c-1" type="bottom" class="data-v-ef249ed8" bind:__l="__l"></uni-icons></view></view></block><block wx:if="{{visible}}"><view data-event-opts="{{[['tap',[['e2',['$event']]]]]}}" class="visible data-v-ef249ed8" bindtap="__e"><view data-event-opts="{{[['tap',[['',['$event']]]]]}}" class="item data-v-ef249ed8" catchtap="__e"><view class="groupBtn data-v-ef249ed8"><view data-event-opts="{{[['tap',[['e3',['$event']]]]]}}" bindtap="__e" class="data-v-ef249ed8">取消</view><view data-event-opts="{{[['tap',[['handlesure']]]]}}" class="sure data-v-ef249ed8" bindtap="__e">确定</view></view><picker-view class="picker-view data-v-ef249ed8" value="{{value}}" indicator-style="{{indicatorStyle}}" data-event-opts="{{[['change',[['bindChange',['$event']]]]]}}" bindchange="__e"><picker-view-column class="data-v-ef249ed8"><block wx:for="{{province}}" wx:for-item="item" wx:for-index="index" wx:key="index"><view class="item data-v-ef249ed8">{{item.name}}</view></block></picker-view-column><picker-view-column class="data-v-ef249ed8"><block wx:for="{{city}}" wx:for-item="item" wx:for-index="index" wx:key="index"><view class="item data-v-ef249ed8">{{item}}</view></block></picker-view-column></picker-view></view></view></block></view><drawer vue-id="f56e3a1c-2" class="data-v-ef249ed8" bind:__l="__l"></drawer></view>

View File

@ -1,6 +1,6 @@
{
"component": true,
"usingComponents": {
"uni-icons": "/uni_modules/uni-icons/components/uni-icons/uni-icons"
}
},
"component": true
}

View File

@ -1,6 +1,6 @@
{
"component": true,
"usingComponents": {
"uni-icons": "/uni_modules/uni-icons/components/uni-icons/uni-icons"
}
},
"component": true
}

View File

@ -266,7 +266,6 @@ var _default = {
var that = this;
if (that.isStart) {
that.handleAudio();
console.log("11111111");
}
}
},
@ -374,8 +373,11 @@ var _default = {
cancelText: "返回",
success: function success(res) {
if (res.cancel) {
that.handleEnd();
innerAudioContext.stop();
uni.navigateBack({
//返回
delta: 1
});
}
}
});
@ -421,6 +423,7 @@ var _default = {
if (res.code == 0) {
that.bpm = that.weight / (that.time / 60);
that.iswrapper = true;
that.info.isSuccessful = true;
that.$store.dispatch('getUserInfo', {
aud_id: uni.getStorageSync('userid')
});
@ -467,7 +470,6 @@ var _default = {
},
handleTarget: function handleTarget() {
var that = this;
uni.$emit('updateData', JSON.stringify(that.info));
uni.navigateBack({
//返回
delta: 1
@ -481,9 +483,7 @@ var _default = {
that.handleStart('结束');
}, 400);
setTimeout(function () {
uni.redirectTo({
url: "/pages/skiping/skip?info=" + JSON.stringify(that.info)
});
uni.$emit('updateData', JSON.stringify(that.info));
}, 600);
}
}

View File

@ -221,12 +221,13 @@ var _default = {
labelList: function labelList() {
var that = this;
if (that.PublicContent) {
that.labelName = that.PublicContent.label_list[0];
that.labelName = that.PublicContent.label_list[that.active];
that.lineList = that.PublicContent.line_list;
that.label_data = that.PublicContent.label_data;
that.chartData.series[0].data = Number(that.PublicContent.label_data[0].offset) / 100;
that.offset = that.PublicContent.label_data[0].offset;
that.chartData.series[0].data = Number(that.PublicContent.label_data[that.active].offset) / 100;
that.offset = that.PublicContent.label_data[that.active].offset;
}
console.log("11111", that.PublicContent, that.active, that.labelName);
return that.PublicContent ? that.PublicContent.label_list : [];
}
}),

View File

@ -53,6 +53,13 @@
display: flex;
align-items: center;
}
.href.data-v-0ac7a6b2 {
display: flex;
width: 100%;
color: #000;
text-decoration: none;
justify-content: space-between;
}
.btn.data-v-0ac7a6b2 {
width: auto;
background: #fea606;

View File

@ -150,8 +150,8 @@ var render = function () {
var l2 = _vm.isDrawe
? _vm.__map(_vm.List, function (item, index) {
var $orig = _vm.__get_orig(item)
var g3 = _vm.choice > 1 ? _vm.isActiveList.indexOf(item) : null
var g4 = _vm.choice > 1 ? _vm.isActiveList.indexOf(item) : null
var g3 = _vm.choice > 1 ? _vm.isActiveNameList.indexOf(item.name) : null
var g4 = _vm.choice > 1 ? _vm.isActiveNameList.indexOf(item.name) : null
return {
$orig: $orig,
g3: g3,
@ -256,6 +256,7 @@ var _default = {
selectllist: [],
isActive: {},
isActiveList: [],
isActiveNameList: [],
region_list: {},
timeList: [],
timesTndex: [0, 0],
@ -263,10 +264,15 @@ var _default = {
msg: "暂无信息",
address: "",
isresult: false,
choice: 0
choice: 0,
isRefresh: false,
info: []
};
},
computed: _objectSpread(_objectSpread({}, (0, _vuex.mapState)(["user", "familayList"])), {}, {
userAddress: function userAddress() {
return this.user.address;
},
userId: function userId() {
return this.user.id;
}
@ -286,6 +292,7 @@ var _default = {
that.address = that.user.address;
that.getList();
}
console.log("onLoad");
},
onPullDownRefresh: function onPullDownRefresh() {
var that = this;
@ -294,14 +301,17 @@ var _default = {
that.Max_score = 0;
that.selectllist = [];
that.sportsList = [];
that.isRefresh = true;
that.timeList = that.$tools.gethms();
if (that.familayList.length) {
that.address = that.user.address;
that.getList();
}
setTimeout(function () {
that.isRefresh = false;
uni.stopPullDownRefresh();
}, 1000);
}, 200);
console.log("刷新");
},
onShow: function onShow() {
var that = this;
@ -313,19 +323,19 @@ var _default = {
that.selectllist = [];
that.sportsList = [];
that.isActiveList = [];
that.isActiveNameList = [];
that.chartData.series[0].data = 0.8;
}
},
watch: {
// userId() {
// userAddress() {
// let that = this
// that.score = 0
// that.selectllist = []
// that.sportsList = []
// that.address = that.user.address
// that.getList()
// that.handleSportsList()
// console.log("user变了", that.sportsList, that.selectllist)
// console.log("user地址变了", that.sportsList, that.selectllist)
// },
},
methods: {
@ -338,6 +348,7 @@ var _default = {
that.selectllist = [];
that.sportsList = [];
that.isActiveList = [];
that.isActiveNameList = [];
that.getList();
},
//
@ -422,7 +433,7 @@ var _default = {
that.choice = item.is_choice;
}
});
// console.log("添加项目", item)
console.log("添加项目", item);
that.isDrawe = true;
},
bindTimeChange: function bindTimeChange(e, it) {
@ -435,38 +446,48 @@ var _default = {
// 选择项目
toggle: function toggle(item) {
var that = this;
// 单选
if (that.choice == 1) {
that.isActive = that.isActive.name == item.name ? {} : item;
return;
}
if (that.isActiveList.indexOf(item.name) == -1) {
// 多选
if (that.isActiveNameList.indexOf(item.name) == -1) {
that.isActiveNameList.push(item.name);
that.isActiveList.push(item);
} else {
that.isActiveList = that.isActiveList.filter(function (ite) {
return ite.name !== item.name;
});
for (var n = 0; n < that.isActiveNameList.length; n++) {
if (item.name == that.isActiveNameList[n]) {
if (that.isActiveNameList.indexOf(item.name) == -1) {
that.isActiveNameList.push(item.name);
that.isActiveList.push(item);
}
that.isActiveNameList.splice(n, 1);
that.isActiveList.splice(n, 1);
}
}
}
if (that.isActiveList.length > that.choice) {
that.isActiveList.splice(0, 1);
that.isActiveNameList.splice(0, 1);
}
// console.log("isActiveList", that.selectllist, that.region_list, item)
console.log("isActiveList", item.name, that.isActiveList, that.region_list.list);
},
// 确定选择项目
handleTarget: function handleTarget() {
var that = this;
// console.log('确定', that.selectllist, that.region_list)
that.selectllist.forEach(function (item) {
item.list.forEach(function (it) {
if (it.key == that.region_list.key) {
it.list = [];
}
});
});
if (that.choice == 1) {
that.region_list.list.push(that.isActive);
} else {
that.region_list.list = that.isActiveList;
}
that.selectllist.forEach(function (item) {
item.list.forEach(function (it) {
if (it.key == that.region_list.key) {
it.list = that.region_list.list;
}
});
});
that.isDrawe = false;
},
handleTips: function handleTips(text) {
@ -481,6 +502,11 @@ var _default = {
this.isActive = {};
this.isDrawe = false;
},
handleTap: function handleTap() {
// this.isActive = {}
// this.isDrawe = false
console.log('quxiao', this.info);
},
navTo: function navTo(url) {
uni.navigateTo({
url: url

File diff suppressed because one or more lines are too long

View File

@ -295,7 +295,6 @@ var _default = {
active: 1,
acd_id: 6,
weight: 50,
Unload: false,
disabled: false,
isDevice: 0,
isConnection: false,
@ -336,18 +335,6 @@ var _default = {
that.handleisSdevice();
}, 1000);
}
// 跳绳页返回
if (options && options.info) {
var data = JSON.parse(options.info);
that.Unload = true;
that.active = data.active;
that.deviceId = data.deviceId;
that.serviceId = data.serviceId;
that.write = data.write;
that.notify = data.notify;
that.islink = !that.isConnected ? -1 : 1;
that.notifyBLECharacteristicValue();
}
that.$store.dispatch("getSkipResult", {
aud_id: uni.getStorageSync('userid')
});
@ -365,32 +352,46 @@ var _default = {
onShow: function onShow() {
var that = this;
// 跳绳页返回
uni.$on('updateData', function (data) {
var info = JSON.parse(data);
that.acd_id = info.acd_id;
that.isDevice = info.device;
console.log('监听到事件来自 updateData ,携带参数为:' + info);
uni.$on('updateData', function (info) {
var data = JSON.parse(info);
that.acd_id = data.acd_id;
that.isDevice = data.device;
that.active = data.active;
that.deviceId = data.deviceId;
that.serviceId = data.serviceId;
that.write = data.write;
that.notify = data.notify;
that.islink = !that.isConnected ? -1 : 1;
that.isConnection = that.isConnected;
that.notifyBLECharacteristicValue();
if (data.isSuccessful) {
that.$store.dispatch("getSkipResult", {
aud_id: uni.getStorageSync('userid')
});
}
that.$Bluetooth.onBLEConnectionStateChange();
uni.onBluetoothAdapterStateChange(function (res) {
that.$store.commit("changeBluetooth", res.available);
});
console.log('监听到事件来自 updateData', data);
});
},
onUnload: function onUnload() {
var that = this;
// clearTimeout(myTime);
// that.islink = -1
// that.isConnection = false
// that.$Bluetooth.closeBluetoothAdapter()
// that.$Bluetooth.closeBLEConnection(that.deviceId)
// that.$Bluetooth.stopBluetoothDevicesDiscovery()
// that.$store.commit("changeBluetooth", false);
// that.$store.commit("changeConnected", false);
// setTimeout(() => {
clearTimeout(myTime);
that.islink = -1;
that.isConnection = false;
that.$Bluetooth.closeBluetoothAdapter();
that.$Bluetooth.closeBLEConnection(that.deviceId);
that.$Bluetooth.stopBluetoothDevicesDiscovery();
that.$store.commit("changeBluetooth", false);
that.$store.commit("changeConnected", false);
uni.$off("updateData");
setTimeout(function () {
uni.switchTab({
url: '/pages/home/home'
});
// }, 300)
var pages = getCurrentPages();
var prevPage = pages[pages.length - 2];
console.log("prevPage", prevPage);
uni.$off("updateData");
}, 300);
console.log("返回首页onUnload");
},
watch: {
@ -572,7 +573,6 @@ var _default = {
success: function success(res) {
uni.onBLECharacteristicValueChange(function (res) {
var value = that.$tools.ab2hex(res.value, "");
console.log("1111跳", value);
if (value == '5a05090169') {
//模式设置成功
var info = {
@ -582,9 +582,11 @@ var _default = {
notify: that.notify,
write: that.write,
acd_id: that.acd_id,
isDevice: that.isDevice
isDevice: that.isDevice,
isSuccessful: false
};
setTimeout(function () {
uni.$off("updateData");
uni.navigateTo({
url: "/pageTwo/devices/PCT01?info=" + JSON.stringify(info)
});