This commit is contained in:
曹辉 2023-05-29 09:41:24 +08:00
parent 2e3f6ad519
commit 8ce5cb4323
3 changed files with 21 additions and 68 deletions

View File

@ -199,36 +199,6 @@
this.timevalue = starttime + ' - ' + endtime this.timevalue = starttime + ' - ' + endtime
this.timepicker = false this.timepicker = false
}, },
argAdd(arg1, arg2) {
//
var _this = this,
r1 = 0,
r2 = 0,
m = 0;
try {
r1 = arg1.toString().split(".")[1].length
} catch (e) {}
try {
r2 = arg2.toString().split(".")[1].length
} catch (e) {}
m = Math.pow(10, Math.max(r1, r2))
return _this.argDiv((_this.argMul(arg1, m) + _this.argMul(arg2, m)), m)
},
argSubtr(arg1, arg2) {
//
var _this = this,
r1 = 0,
r2 = 0,
m = 0;
try {
r1 = arg1.toString().split(".")[1].length
} catch (e) {}
try {
r2 = arg2.toString().split(".")[1].length
} catch (e) {}
m = Math.pow(10, Math.max(r1, r2));
return _this.argDiv((_this.argMul(arg1, m) - _this.argMul(arg2, m)), m)
},
argMul(arg1, arg2) { argMul(arg1, arg2) {
// //
var _this = this, var _this = this,
@ -243,22 +213,6 @@
} catch (e) {} } catch (e) {}
return Number(s1.replace(".", "")) * Number(s2.replace(".", "")) / Math.pow(10, m) return Number(s1.replace(".", "")) * Number(s2.replace(".", "")) / Math.pow(10, m)
}, },
argDiv(arg1, arg2) {
//
var _this = this,
t1 = 0,
t2 = 0,
r1, r2;
try {
t1 = arg1.toString().split(".")[1].length
} catch (e) {}
try {
t2 = arg2.toString().split(".")[1].length
} catch (e) {}
r1 = Number(arg1.toString().replace(".", ""))
r2 = Number(arg2.toString().replace(".", ""))
return _this.argMul((r1 / r2), Math.pow(10, t2 - t1));
},
} }
} }
</script> </script>

View File

@ -22,7 +22,7 @@
<!-- <view class="item"> <!-- <view class="item">
<span>电话:</span> <span>电话:</span>
<u-input :clearable='false' v-model="appPersonallist.phone" placeholder="请输入" maxlength='11' <u-input :clearable='false' v-model="appPersonallist.phone" placeholder="请输入" maxlength='11'
type="text" /> type="number" />
</view> --> </view> -->
<view class="item" @tap='timeshow=true'> <view class="item" @tap='timeshow=true'>
<span>出生日期</span> <span>出生日期</span>

View File

@ -329,21 +329,19 @@
const value = uni.getStorageSync('openid'); const value = uni.getStorageSync('openid');
const patientId = uni.getStorageSync('patientId'); const patientId = uni.getStorageSync('patientId');
if (value && patientId) { if (value && patientId) {
let that = this
AppIdentification(patientId).then(res => {
if (res.code == 200) {
if (res.data.loginFlag) {
that.usershow = false
const scenenurseStationId = uni.getStorageSync('scenenurseStationId'); const scenenurseStationId = uni.getStorageSync('scenenurseStationId');
if (that.list.nurseStationId == scenenurseStationId) { if (that.list.nurseStationId == scenenurseStationId) {
uni.navigateTo({ uni.navigateTo({
url: `/pages/hospitalcare/hospitalcare?stationId=${item.stationId}&stationItemId=${item.stationItemId}&stationItemPriceId=${item.stationItemPriceId}`, url: `/pages/hospitalcare/hospitalcare?stationId=${item.stationId}&stationItemId=${item.stationItemId}&stationItemPriceId=${item.stationItemPriceId}`,
}) })
} else { } else {
AppIdentification(patientId).then(res => {
if (res.code == 200) {
if (res.data.loginFlag) {
that.usershow = false
uni.navigateTo({ uni.navigateTo({
url: `/pages/appointmenttime/appointmenttime?stationId=${item.stationId}&stationItemId=${item.stationItemId}&stationItemPriceId=${item.stationItemPriceId}`, url: `/pages/appointmenttime/appointmenttime?stationId=${item.stationId}&stationItemId=${item.stationItemId}&stationItemPriceId=${item.stationItemPriceId}`,
}) })
}
} else { } else {
that.usershow = true that.usershow = true
} }
@ -355,6 +353,7 @@
}) })
} }
}) })
}
} else { } else {
that.$refs.uToast.show({ that.$refs.uToast.show({
title: '未登录,请先登录', title: '未登录,请先登录',