diff --git a/pages.json b/pages.json index d8e0308..289ea33 100644 --- a/pages.json +++ b/pages.json @@ -9,20 +9,28 @@ "navigationBarTitleText": "", "navigationStyle": "custom" } - }, { + }, + { + "path": "pages/forgotPassword/forgotPassword", + "style": { + "navigationBarTitleText": "忘记密码", + "navigationBarBackgroundColor": "#ffffff" + } + }, + { "path": "pages/register/register", "style": { "navigationBarTitleText": "注册账号", "navigationBarBackgroundColor": "#ffffff" } - },{ + }, { "path": "pages/homepage/homepage", "style": { "navigationBarTitleText": "泉医到家", "enablePullDownRefresh": false, "navigationBarBackgroundColor": "#ffffff" } - }, { + }, { "path": "pages/login/login", "style": { "navigationBarTitleText": "", @@ -72,7 +80,7 @@ "navigationBarBackgroundColor": "#ffffff", //背景颜色 "enablePullDownRefresh": false } - },{ + }, { "path": "pages/Personal/Personal", "style": { "navigationBarTitleText": "个人中心", @@ -255,6 +263,14 @@ "enablePullDownRefresh": false, "navigationBarBackgroundColor": "#ffffff" } + }, { + "path": "pages/paysuccess/paysuccess", + "style": { + "navigationBarTitleText": "", + "enablePullDownRefresh": false, + "navigationStyle": "custom" + } + } ], "globalStyle": { diff --git a/pages/Aftersalesdetails/Aftersalesdetails.vue b/pages/Aftersalesdetails/Aftersalesdetails.vue index f828162..39625fb 100644 --- a/pages/Aftersalesdetails/Aftersalesdetails.vue +++ b/pages/Aftersalesdetails/Aftersalesdetails.vue @@ -67,13 +67,23 @@ this.goodsOrderId = options.goodsOrderId this.baseurl = baseurl let that = this - uni.getStorage({ - key: 'patientId', - success: function(res) { - that.patientId = res.data + try { + const value = uni.getStorageSync('patientId'); + if (value) { + that.patientId = value that.goodsOrderinfo(); } - }); + } catch (e) { + // error + } + + // uni.getStorage({ + // key: 'patientId', + // success: function(res) { + // that.patientId = res.data + // that.goodsOrderinfo(); + // } + // }); } } diff --git a/pages/Applforrefund/Applforrefund.vue b/pages/Applforrefund/Applforrefund.vue index 1cc27a6..f158ba2 100644 --- a/pages/Applforrefund/Applforrefund.vue +++ b/pages/Applforrefund/Applforrefund.vue @@ -59,6 +59,7 @@ methods: { //退款 refundinfo() { + this.order.updateTime = null refund(this.order).then( res => { console.log(res) @@ -73,14 +74,11 @@ type: 'success', duration: '1500' }) - setTimeout(() => { - // uni.navigateTo({ - // url: '/pages/Aftersalesdetails/Aftersalesdetails' - // }) - uni.navigateTo({ - url: '/pages/CommodityOrder/CommodityOrder' - }) - }, 1500); + setTimeout(e => { + uni.navigateBack({ + delta: 3 + }); + }, 1500) } }) }, diff --git a/pages/CommodityDetails/CommodityDetails.vue b/pages/CommodityDetails/CommodityDetails.vue index f701d93..802197d 100644 --- a/pages/CommodityDetails/CommodityDetails.vue +++ b/pages/CommodityDetails/CommodityDetails.vue @@ -124,6 +124,9 @@ import { AppIdentification } from '@/api/AppIdentification/index.js' + import { + goodPatientInfo + } from '@/api/modifyAddress/modifyAddress.js'; import baseurl from '@/api/baseurl.js' export default { data() { @@ -164,43 +167,61 @@ methods: { //跳转完善页面 goinformation() { + this.usershow = false uni.navigateTo({ url: '/pages/information/information' }) }, //立即购买跳转确认订单页面 tapbuy() { - AppIdentification(this.updata.patientId).then(res => { - console.log(res) - if (res.data.loginFlag) { - if (this.goodshow == true) { - if (this.updata.goodsAttributeName == '') { - this.$refs.uToast.show({ - title: '未选择商品', - type: 'error' - }) - } else if (this.updata.goodsStock == 0) { - this.$refs.uToast.show({ - title: '库存数量不足,无法购买', - type: 'error' - }) - } else { - this.updata.totalPrice = (this.updata.goodsPrice * this.updata.goodsCount).toFixed( - 2) - uni.navigateTo({ - url: `/pages/confirmOrder/confirmOrder?updata=${JSON.stringify(this.updata)}` - }) - } - } else { - uni.navigateTo({ - url: `/pages/confirmOrder/confirmOrder?updata=${JSON.stringify(this.updata)}` - }) + this.buyshow = false + let that = this + try { + const value = uni.getStorageSync('patientId'); + if (value) { + if (!that.updata.patientId) { + that.goodsList() } + that.updata.patientId = value + AppIdentification(value).then(res => { + if (res.data.loginFlag) { + if (that.goodshow == true) { + if (that.updata.goodsAttributeName == '') { + that.$refs.uToast.show({ + title: '未选择商品', + type: 'error' + }) + } else if (that.updata.goodsStock == 0) { + that.$refs.uToast.show({ + title: '库存数量不足,无法购买', + type: 'error' + }) + } else { + that.updata.totalPrice = (that.updata.goodsPrice * that.updata + .goodsCount).toFixed( + 2) + uni.navigateTo({ + url: `/pages/confirmOrder/confirmOrder?updata=${JSON.stringify(that.updata)}` + }) + } + } else { + uni.navigateTo({ + url: `/pages/confirmOrder/confirmOrder?updata=${JSON.stringify(that.updata)}` + }) + } + } else { + that.buyshow = false + that.usershow = true + } + }) } else { - this.buyshow = false - this.usershow = true + uni.navigateTo({ + url: '/pages/login/login' + }) } - }) + } catch (e) { + // error + } }, // tapbuy() { // this.goodsDetailslist.goodDetailsLists.forEach(e => { @@ -237,7 +258,6 @@ this.updata.goodsStock = item.goodsStock this.updata.goodsAttributeId = item.goodsAttributeId this.updata.goodsAttributeDetailsId = item.attributeDetailsId - this.updata.img = this.baseurl + item.attributePitureUrl } }, @@ -287,6 +307,7 @@ this.goodsDetailslist = res.data[0] this.updata.goodsName = this.goodsDetailslist.goodsName this.updata.nurseStationId = this.goodsDetailslist.nurseStationId + this.updata.img = res.data[0].goodsPictureUrl this.goodDetailsLists = res.data[0].goodDetailsLists // res.data[0].goodDetailsLists.forEach(e => { // e.goodAttributeDetailsLists.forEach(el => { @@ -301,22 +322,40 @@ // this.goodDetailsLists = res.data[0].goodDetailsLists }) }, + // 收件人 + goodsList() { + goodPatientInfo(this.updata.patientId).then(res => { + res.data.forEach(e => { + e.address = e.provinceName + e.cityName + e.regionName + e.streetName + e + .receiveAddress + }) + this.updata.receiver = res.data[0].receiveName + this.updata.receiveAddress = res.data[0].address + this.updata.phone = res.data[0].receivePhone + }) + }, }, onLoad(options) { //获取传值 this.updata.buySource = options.buySource - this.usershow = false - let that = this - uni.getStorage({ - key: 'patientId', - success: function(res) { - that.updata.patientId = res.data - console.log(that.updata) - } - }); this.goodsPrice = options.goodsPrice //页面价格 - this.baseurl = baseurl; this.goodsDetailsinfo(options.goodsInfoId) }, + onShow() { + this.baseurl = baseurl + this.usershow = false + this.baseurl = baseurl; + let that = this + try { + const value = uni.getStorageSync('patientId'); + if (value) { + that.updata.patientId = value + console.log(that.updata.patientId) + that.goodsList() + } else {} + } catch (e) { + // error + } + }, } diff --git a/pages/CommodityOrder/CommodityOrder.vue b/pages/CommodityOrder/CommodityOrder.vue index 529a6e8..d59bd68 100644 --- a/pages/CommodityOrder/CommodityOrder.vue +++ b/pages/CommodityOrder/CommodityOrder.vue @@ -74,7 +74,7 @@ export default { data() { return { - title:'商品订单',//导航标题 + title: '商品订单', //导航标题 baseurl: '', //url orderlist: [], //商品订单list total: 0, //list长度 @@ -127,26 +127,28 @@ title: this.title, }); }, - onLoad(options) { //开局调用 - if (options.orderStatus) { - this.orderStatus = options.orderStatus - if(options.orderStatus=='WAIT_PAY'){ - this.title='待付款' - }else if(options.orderStatus=='WAIT_RECEIVED_GOODS'){ - this.title='待收货' - }else if(options.orderStatus=='RECEIVED_GOODS'){ - this.title='已完成' - } - } + onShow() { let that = this - uni.getStorage({ - key: 'patientId', - success: function(res) { - that.patientId = res.data + try { + const value = uni.getStorageSync('patientId'); + if (value) { + that.patientId = value that.goodsOrderinfo(); } - }); + } catch (e) {} + }, + onLoad(options) { //开局调用 this.baseurl = baseurl; + if (options.orderStatus) { + this.orderStatus = options.orderStatus + if (options.orderStatus == 'WAIT_PAY') { + this.title = '待付款' + } else if (options.orderStatus == 'WAIT_RECEIVED_GOODS') { + this.title = '待收货' + } else if (options.orderStatus == 'RECEIVED_GOODS') { + this.title = '已完成' + } + } }, onReachBottom() { //下滑加载 if (this.orderlist.length >= this.total) {} else { diff --git a/pages/Nursingstationserviceorder/Nursingstationserviceorder.vue b/pages/Nursingstationserviceorder/Nursingstationserviceorder.vue index a28f0de..807863c 100644 --- a/pages/Nursingstationserviceorder/Nursingstationserviceorder.vue +++ b/pages/Nursingstationserviceorder/Nursingstationserviceorder.vue @@ -52,17 +52,18 @@ list: [], } }, - onLoad() { + onShow() { this.baseurl = baseurl let that = this - uni.getStorage({ - key: 'patientId', - success: function(res) { - that.patientId = res.data + try { + const value = uni.getStorageSync('patientId'); + if (value) { + that.patientId = value that.getinfo() } - }); + } catch (e) {} }, + onLoad() {}, methods: { //支付 buy(item) { diff --git a/pages/ServiceDetails/ServiceDetails.scss b/pages/ServiceDetails/ServiceDetails.scss index 03717d2..953f709 100644 --- a/pages/ServiceDetails/ServiceDetails.scss +++ b/pages/ServiceDetails/ServiceDetails.scss @@ -176,7 +176,7 @@ .model { position: absolute; left:35%; - top:20%; + top:8%; width: 65%; .top,.bottom{ view { @@ -186,6 +186,7 @@ overflow: hidden; text-overflow: ellipsis; white-space: nowrap; + word-break:break-all; } } diff --git a/pages/ServiceDetails/ServiceDetails.vue b/pages/ServiceDetails/ServiceDetails.vue index 1c5e301..3ab80bf 100644 --- a/pages/ServiceDetails/ServiceDetails.vue +++ b/pages/ServiceDetails/ServiceDetails.vue @@ -51,7 +51,7 @@ 备注: - + { - this.nursestationlist = res[0]; + this.nursestationlist = res.data; + console.log(this.nursestationlist) }) }, //获取耗材包详情 diff --git a/pages/appointmenttime/appointmenttime.vue b/pages/appointmenttime/appointmenttime.vue index 8c273f4..52366c8 100644 --- a/pages/appointmenttime/appointmenttime.vue +++ b/pages/appointmenttime/appointmenttime.vue @@ -105,23 +105,32 @@ consumableTotalPrice: '', totalPrice: '', remark: "", - orderConsumableList: [] + orderConsumableList: [], }, } }, + onShow() { + let that = this + uni.$on('updata', function(data) { + if (data.updata) { + that.orderlist = JSON.parse(data.updata) + } + if (data.useritem) { + that.useritem = JSON.parse(data.useritem) + that.orderlist.serviceAddress = that.useritem.address + that.personInfo.patientName = that.useritem.receiveName + that.personInfo.phone = that.useritem.receivePhone + that.personInfo.address = that.useritem.address + } else {} + }) + setTimeout(e => { + if (!that.useritem) { + that.userinfo(); + } + }, 500) + }, + onLoad(options) { - if (options.updata) { - this.orderlist = JSON.parse(options.updata) - } - if (options.useritem) { - let useritem = JSON.parse(options.useritem) - this.orderlist.serviceAddress = useritem.address - this.personInfo.patientName = useritem.receiveName - this.personInfo.phone = useritem.receivePhone - this.personInfo.address = useritem.address - } else { - this.userinfo(); - } //耗材包详情方法调用 this.getPatientInfo(options.stationId, options.stationItemId, options.stationItemPriceId) }, @@ -129,13 +138,12 @@ userinfo() { //取出patientId var that = this - uni.getStorage({ - key: 'patientId', - success: function(res) { - that.patientId = res.data - console.log(that.patientId) + try { + const value = uni.getStorageSync('patientId'); + if (value) { + that.patientId = value //被护理人信息 - getAppPatientList(that.patientId).then(response => { + getAppPatientList(value).then(response => { that.personInfo = response.data that.personInfo.address = response.data.provinceName + response.data .cityName + response.data.regionName + response.data.streetName + @@ -145,8 +153,29 @@ .cityName + response.data.regionName + response.data.streetName + response.data.address }) + console.log(that.orderlist) } - }); + } catch (e) { + // error + } + + // uni.getStorage({ + // key: 'patientId', + // success: function(res) { + // that.patientId = res.data + // //被护理人信息 + // getAppPatientList(that.patientId).then(response => { + // that.personInfo = response.data + // that.personInfo.address = response.data.provinceName + response.data + // .cityName + response.data.regionName + response.data.streetName + + // response.data.address + // that.orderlist.patientId = response.data.patientId + // that.orderlist.serviceAddress = response.data.provinceName + response.data + // .cityName + response.data.regionName + response.data.streetName + + // response.data.address + // }) + // } + // }); }, //获取耗材包详情 getPatientInfo(stationId, stationItemId, stationItemPriceId) { @@ -165,7 +194,10 @@ type: 'error', }) } else { + this.orderlist.orderChannel = "MOBILE_APP" + this.orderlist.buySource = "NURSE_STATION" this.orderlist.orderCount = 1; + console.log(this.orderlist) submitAppointment(this.orderlist).then(res => { if (res.code == 500) { this.$refs.uToast.show({ @@ -176,17 +208,12 @@ this.$refs.uToast.show({ title: '预约成功', type: 'success', + url:'/pages/paysuccess/paysuccess', toast: 1500 }) - setTimeout(() => { - uni.reLaunch({ - url: `/pages/Personal/Personal` - }) - }, 1500) } }) } - }, changeRadio() { if (this.radio == 1) { diff --git a/pages/cancelorder/cancelorder.vue b/pages/cancelorder/cancelorder.vue index 04c2197..59ada28 100644 --- a/pages/cancelorder/cancelorder.vue +++ b/pages/cancelorder/cancelorder.vue @@ -42,9 +42,13 @@ } else if (res.code == 200) { this.$refs.uToast.show({ title: '取消成功', - type: 'success', - url: '/pages/Nursingstationserviceorder/Nursingstationserviceorder' + type: 'success' }) + setTimeout(e => { + uni.navigateBack({ + delta: 2 + }); + }, 1500) } }) } diff --git a/pages/confirmOrder/confirmOrder.vue b/pages/confirmOrder/confirmOrder.vue index f942164..fc29d15 100644 --- a/pages/confirmOrder/confirmOrder.vue +++ b/pages/confirmOrder/confirmOrder.vue @@ -126,6 +126,10 @@ title: res.msg, type: 'error' }) + } else { + uni.navigateTo({ + url: `/pages/paysuccess/paysuccess` + }) } }) }, @@ -144,7 +148,8 @@ goodsList() { goodPatientInfo(this.updata.patientId).then(res => { res.data.forEach(e => { - e.address = e.provinceName + e.cityName + e.regionName + e.streetName + e.receiveAddress + e.address = e.provinceName + e.cityName + e.regionName + e.streetName + e + .receiveAddress }) this.updata.receiver = res.data[0].receiveName this.updata.receiveAddress = res.data[0].address @@ -154,16 +159,20 @@ }, onLoad(options) { this.updata = JSON.parse(options.updata) - if (options.useritem) { - let useritem = JSON.parse(options.useritem) - this.updata.receiver = useritem.receiveName - this.updata.phone = useritem.receivePhone - this.updata.receiveAddress = useritem.address - } else { - this.goodsList() - } - console.log(this.updata) - } + }, + onShow() { + var that = this + let useritem = null + uni.$on('updata', function(data) { + that.updata = JSON.parse(data.updata) + if (data.useritem) { + useritem = JSON.parse(data.useritem) + that.updata.receiver = useritem.receiveName + that.updata.phone = useritem.receivePhone + that.updata.receiveAddress = useritem.address + } + }) + }, } diff --git a/pages/detail/detail.vue b/pages/detail/detail.vue index 3cf3d37..b1747b2 100644 --- a/pages/detail/detail.vue +++ b/pages/detail/detail.vue @@ -3,7 +3,7 @@ - + 护理站是以维护社区人群健康、满足社区 人群基本医疗护理需求为宗旨,以护士为核心 的各类护理人员组成的团队,在一定社区范围 内,为长期卧床老人、患者、残疾人、临终患 diff --git a/pages/forgotPassword/forgotPassword.vue b/pages/forgotPassword/forgotPassword.vue index 5e0d0d4..b2db379 100644 --- a/pages/forgotPassword/forgotPassword.vue +++ b/pages/forgotPassword/forgotPassword.vue @@ -18,7 +18,7 @@ 手机号 - + @@ -52,22 +52,30 @@ }, methods: { pwdlogin() { - ForgotPassword(this.phone, this.password, this.verification).then(res => { - if (this.password !== this.newpassword) { - this.$refs.uToast.show({ - title: '密码输入不一致,请重新输入', - type: 'error', - duration: '1500' - }) - } else { - this.$refs.uToast.show({ - title: '密码修改成功', - type: 'success', - url: '/pages/login/login', - duration: '1500' - }) - } - }) + if (this.password !== this.newpassword) { + this.$refs.uToast.show({ + title: '密码输入不一致,请重新输入', + type: 'error', + duration: '1500' + }) + } else { + ForgotPassword(this.phone, this.password, this.verification).then(res => { + if (res.code == 200) { + this.$refs.uToast.show({ + title: '密码修改成功', + type: 'success', + url: '/pages/login/login', + duration: '1500' + }) + } else { + this.$refs.uToast.show({ + title: res.msg, + type: 'error', + duration: '1500' + }) + } + }) + } }, //点击获取验证码 getCode() { diff --git a/pages/information/information.scss b/pages/information/information.scss index 7d78073..a73a1ab 100644 --- a/pages/information/information.scss +++ b/pages/information/information.scss @@ -21,17 +21,25 @@ height: 70rpx; border-radius: 26rpx; margin: 0 20rpx 20rpx 0; + padding: 0 10rpx ; + white-space: nowrap; + text-overflow: ellipsis; + overflow: hidden; } - + .choice { display: inline-block; text-align: center; line-height: 70rpx; + padding: 0 10rpx ; width: 190rpx; height: 70rpx; background: #BFBFBF; border-radius: 26rpx; margin: 0 20rpx 20rpx 0; + white-space: nowrap; + text-overflow: ellipsis; + overflow: hidden; } } diff --git a/pages/information/information.vue b/pages/information/information.vue index a4d739a..7c42399 100644 --- a/pages/information/information.vue +++ b/pages/information/information.vue @@ -163,12 +163,21 @@ //进入界面加载 onLoad() { let that = this - uni.getStorage({ - key: 'patientId', - success: function(res) { - that.query.patientId = res.data + try { + const value = uni.getStorageSync('patientId'); + if (value) { + that.query.patientId = value } - }); + } catch (e) { + // error + } + + // uni.getStorage({ + // key: 'patientId', + // success: function(res) { + // that.query.patientId = res.data + // } + // }); this.areaInfo() this.getNurseTypeInfo(); }, diff --git a/pages/login/login.scss b/pages/login/login.scss index 70278c1..be97331 100644 --- a/pages/login/login.scss +++ b/pages/login/login.scss @@ -8,8 +8,7 @@ height: 100rpx; color: #46ABD7; position: absolute; - top: 67%; - left: 10%; + top: 70%; } .loginbtn { diff --git a/pages/login/login.vue b/pages/login/login.vue index 9caada9..4f5db8c 100644 --- a/pages/login/login.vue +++ b/pages/login/login.vue @@ -13,7 +13,10 @@ 登录 - + + 忘记密码 + + 没有账号,请先注册 @@ -38,13 +41,14 @@ appLoginpwd(this.phone, this.password).then(res => { if (res.code == 200) { if (res.data.registerFlag == false) { - uni.setStorage({ - key: 'patientId', - data: res.data.patientId, - success: function() { - console.log('patientId保存成功'); - } - }); + uni.setStorageSync("patientId", res.data.patientId) + // uni.setStorage({ + // key: 'patientId', + // data: res.data.patientId, + // success: function() { + // console.log('patientId保存成功'); + // } + // }); this.$refs.uToast.show({ title: res.data.message, type: 'success', @@ -75,6 +79,12 @@ url: '/pages/register/register' }) }, + //跳转忘记密码页面 + goforgotPassword() { + uni.navigateTo({ + url: "/pages/forgotPassword/forgotPassword" + }) + }, }, toLogin() { // uni.hideKeyboard() //隐藏已经显示的软键盘,如果软键盘没有显示则不做任何操作。 diff --git a/pages/modify/modify.vue b/pages/modify/modify.vue index 02898d0..cac1ee5 100644 --- a/pages/modify/modify.vue +++ b/pages/modify/modify.vue @@ -63,6 +63,7 @@ arealist: [], areashow: false, chooseLocation: '', + img: null, appPersonallist: { patientName: "", cardNo: "", @@ -88,47 +89,63 @@ this.patientDiseaseInfoList.forEach(e => { e.id = e.diseaseId }) - this.chooseLocation = '东经:' + this.appPersonallist.homeLongitude + '度' + ' 北纬:' + this.appPersonallist - .homeLatitude + '度'; + this.chooseLocation = '东经:' + this.appPersonallist.homeLongitude + ' 北纬:' + this.appPersonallist + .homeLatitude }, methods: { //上传图片+提交信息 informationinfo() { //上传图片 var that = this - uni.uploadFile({ - url: baseurl + '/nurseApplet/uploadFile/uploadHeadPictureUrl', - filePath: that.appPersonallist.headPictureUrl, - name: 'file', - formData: { - 'patientId': that.appPersonallist.patientId - }, - timeout: 5000, - success(res) { - that.appPersonallist.headPictureUrl = JSON.parse(res.data).imgUrl - //提交 - // that.appPersonallist.homeLongitude = '1' - // that.appPersonallist.homeLatitude = '1' - that.appPersonallist.diseaseInfoList = that.patientDiseaseInfoList - console.log(that.appPersonallist) - information(that.appPersonallist).then(res => { - if (res.code == 200) { - that.$refs.uToast.show({ - title: '修改信息成功', - type: 'success', - url: '/pages/user/user', - duration: '1500' - }) - } else if (res.code == 500) { - that.$refs.uToast.show({ - title: res.msg, - type: 'error', - url: '' - }) - } - }) - } - }) + if (this.img) { + uni.uploadFile({ + url: baseurl + '/nurseApplet/uploadFile/uploadHeadPictureUrl', + filePath: that.appPersonallist.headPictureUrl, + name: 'file', + formData: { + 'patientId': that.appPersonallist.patientId + }, + timeout: 5000, + success(res) { + that.appPersonallist.headPictureUrl = JSON.parse(res.data).imgUrl + that.appPersonallist.diseaseInfoList = that.patientDiseaseInfoList + information(that.appPersonallist).then(res => { + if (res.code == 200) { + that.$refs.uToast.show({ + title: '修改信息成功', + type: 'success', + url: '/pages/user/user', + duration: '1500' + }) + } else if (res.code == 500) { + that.$refs.uToast.show({ + title: res.msg, + type: 'error', + url: '' + }) + } + }) + } + }) + } else { + that.appPersonallist.diseaseInfoList = that.patientDiseaseInfoList + information(that.appPersonallist).then(res => { + if (res.code == 200) { + that.$refs.uToast.show({ + title: '修改信息成功', + type: 'success', + url: '/pages/user/user', + duration: '1500' + }) + } else if (res.code == 500) { + that.$refs.uToast.show({ + title: res.msg, + type: 'error', + url: '' + }) + } + }) + } }, //上传头像 uploadImag() { @@ -139,7 +156,7 @@ sourceType: ['album'], success(res) { that.appPersonallist.headPictureUrl = res.tempFilePaths[0] - console.log(that.appPersonallist.headPictureUrl) + that.img = res.tempFilePaths[0] } }) }, diff --git a/pages/modifyAddress/modifyAddress.scss b/pages/modifyAddress/modifyAddress.scss index a5d49e5..a8a4a3f 100644 --- a/pages/modifyAddress/modifyAddress.scss +++ b/pages/modifyAddress/modifyAddress.scss @@ -3,7 +3,7 @@ background-color: #F4F5F7; width: 100%; position: relative; - height: 100vh; + height: 100%; padding: 4%; padding-bottom: 100rpx; background-image: linear-gradient(to bottom, #F4F5F7, #ffffff); diff --git a/pages/modifyAddress/modifyAddress.vue b/pages/modifyAddress/modifyAddress.vue index 6616771..48fcf63 100644 --- a/pages/modifyAddress/modifyAddress.vue +++ b/pages/modifyAddress/modifyAddress.vue @@ -96,7 +96,6 @@ }, onLoad(options) { let that = this - console.log(options) this.url = options.url this.updata = JSON.parse(options.updata) //获取传值 @@ -106,24 +105,31 @@ methods: { //将信息携带至订单页面 goorder(item) { - if (this.url == "appointmenttime") { - uni.navigateTo({ - url: `/pages/appointmenttime/appointmenttime?updata=${JSON.stringify(this.updata)}&useritem=${JSON.stringify(item)}` - }) - } else { - uni.navigateTo({ - url: `/pages/confirmOrder/confirmOrder?updata=${JSON.stringify(this.updata)}&useritem=${JSON.stringify(item)}` - }) - } + // if (this.url == "appointmenttime") { + uni.$emit('updata', { + updata: JSON.stringify(this.updata), + useritem: JSON.stringify(item) + }) + uni.navigateBack({ + delta: 1 + }); + // uni.navigateTo({ + // url: `/pages/appointmenttime/appointmenttime?updata=${JSON.stringify(this.updata)}&useritem=${JSON.stringify(item)}` + // }) + // } else { + // uni.navigateTo({ + // url: `/pages/confirmOrder/confirmOrder?updata=${JSON.stringify(this.updata)}&useritem=${JSON.stringify(item)}` + // }) + // } }, // 查询地址信息 goodsList() { let that = this - uni.getStorage({ - key: 'patientId', - success: function(res) { - that.patientId = res.data - that.infolist.patientId = res.data + try { + const value = uni.getStorageSync('patientId'); + if (value) { + that.patientId = value + that.infolist.patientId = value goodPatientInfo(that.patientId).then(res => { res.data.forEach(e => { e.address = e.provinceName + e.cityName + e.regionName + e @@ -132,7 +138,21 @@ that.goodPatient = res.data }) } - }); + } catch (e) {} + // uni.getStorage({ + // key: 'patientId', + // success: function(res) { + // that.patientId = res.data + // that.infolist.patientId = res.data + // goodPatientInfo(that.patientId).then(res => { + // res.data.forEach(e => { + // e.address = e.provinceName + e.cityName + e.regionName + e + // .streetName + e.receiveAddress + // }) + // that.goodPatient = res.data + // }) + // } + // }); }, // 保存按钮 submit() { @@ -160,7 +180,6 @@ setTimeout(e => { that.goodsList() }, 1500) - }) } }, diff --git a/pages/nursestation/nursestation.scss b/pages/nursestation/nursestation.scss index af6dc51..c55e366 100644 --- a/pages/nursestation/nursestation.scss +++ b/pages/nursestation/nursestation.scss @@ -1,8 +1,8 @@ - .app{ - height: 100vh; - padding:0; - background-image: linear-gradient(to bottom, #F4F5F7, #ffffff); - } + .app{ + height: 100%; + padding:10rpx 0 0 0; + background-image: linear-gradient(to bottom, #F4F5F7, #ffffff); + } .mask { .information { width: 70%; @@ -49,7 +49,7 @@ } } -.content { + .content { font-size: 36rpx; padding-bottom: 10rpx; .tive { @@ -58,7 +58,7 @@ margin: 0 auto; margin-top: 20rpx; border-radius: 11px; - // padding-bottom: 60rpx; + padding-bottom: 60rpx; .item { width: 100%; height: 100%; @@ -153,6 +153,7 @@ } .Nursestationconfiguration { width: 94%; + height: 100%; background: #FFFFFF; border-radius: 20rpx; padding-bottom: 30rpx; @@ -162,11 +163,11 @@ color: #333333; padding: 3%; .text { - margin-top: 32rpx; - display: inline; + margin-top: 10rpx; + display: inline-block; padding: 10rpx 20rpx; - margin-right: 28rpx; - line-height: 50rpx; + margin-right: 18rpx; + line-height: 40rpx; background-color: #f6f6f6; border-radius: 34rpx; font-size: 24rpx; @@ -177,6 +178,7 @@ .detail { position: relative; width: 94%; + height: 100%; margin: 0 auto; background: #FFFFFF; border-radius: 20rpx; @@ -185,6 +187,7 @@ padding: 3%; padding-bottom: 50rpx; .textInfo { + word-break:break-all; font-size: 29rpx; text-indent: 2rem; line-height: 42rpx; @@ -202,10 +205,10 @@ .righttext { position: relative; width: 94%; - height: 252rpx; background-color: #ffffff; border-radius: 20rpx; margin: 10px auto; + padding-bottom: 20rpx; .picture { position: absolute; width: 170rpx; @@ -217,6 +220,9 @@ margin-left: 35%; line-height: 49px; font-size: 33rpx; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; } .call { // display: flex; @@ -268,6 +274,10 @@ margin-left: 35%; color: #999999; line-height: 37rpx; + word-break:break-all; + // overflow: hidden; + // text-overflow: ellipsis; + // white-space: nowrap; } } } diff --git a/pages/nursestation/nursestation.vue b/pages/nursestation/nursestation.vue index a4d9198..e0544f9 100644 --- a/pages/nursestation/nursestation.vue +++ b/pages/nursestation/nursestation.vue @@ -113,12 +113,14 @@ onLoad(options) { this.usershow = false let that = this - uni.getStorage({ - key: 'patientId', - success: function(res) { - that.patientId = res.data + try { + const value = uni.getStorageSync('patientId'); + if (value) { + that.patientId = value } - }); + } catch (e) { + // error + } this.nurseStationId = options.nurseStationId this.getInfo() this.serveinfo() diff --git a/pages/orderDetails/orderDetails.vue b/pages/orderDetails/orderDetails.vue index a4c211d..3de85e1 100644 --- a/pages/orderDetails/orderDetails.vue +++ b/pages/orderDetails/orderDetails.vue @@ -45,11 +45,12 @@ 收货信息:{{order.receiver}},{{order.phone}},{{order.receiveAddress}} 订单编号:{{order.goOrderNo}} - 付款时间:{{order.orderTime}} + 下单时间:{{order.orderTime}} + 退款时间:{{order.updateTime}} - + 去支付 @@ -95,13 +96,23 @@ onLoad(options) { this.baseurl = baseurl let that = this - uni.getStorage({ - key: 'patientId', - success: function(res) { - that.patientId = res.data + try { + const value = uni.getStorageSync('patientId'); + if (value) { + that.patientId = value that.goodsOrderinfo(options.goodsOrderId) } - }); + } catch (e) { + // error + } + + /* uni.getStorage({ + key: 'patientId', + success: function(res) { + that.patientId = res.data + that.goodsOrderinfo(options.goodsOrderId) + } + }); */ } } diff --git a/pages/paysuccess/paysuccess.vue b/pages/paysuccess/paysuccess.vue new file mode 100644 index 0000000..3eb16e7 --- /dev/null +++ b/pages/paysuccess/paysuccess.vue @@ -0,0 +1,81 @@ + + + + + diff --git a/pages/register/register.scss b/pages/register/register.scss index 143e574..7443a0b 100644 --- a/pages/register/register.scss +++ b/pages/register/register.scss @@ -50,16 +50,18 @@ } } .radio-content { + margin: 0 auto; + width: 70%; + text-align: center; padding-top: 50rpx; height: 80rpx; line-height: 11rpx; font-size: 28rpx; .agreement { color: #878987; - margin-left: 25%; } .radio-right { - margin-left: 20%; + margin-left: 30rpx; .radio-default { border: 2rpx solid #0fbda6; } @@ -69,7 +71,7 @@ border-radius: 70%; border: 2rpx solid #178ffb; margin: 6px 25px -20rpx -5rpx; - + .radio-active { width: 16rpx; height: 16rpx; diff --git a/pages/register/register.vue b/pages/register/register.vue index d4f9d18..93f5eed 100644 --- a/pages/register/register.vue +++ b/pages/register/register.vue @@ -17,7 +17,7 @@ 重复密码 - @@ -64,6 +64,7 @@ patientName: '', phone: '13645678913', password: '123456', + newpassword: '123456', verification: '111111', getCodeText: '获取验证码', //获取验证码的文字 getCodeBtnColor: "#4C7BC9", //获取验证码的color @@ -73,23 +74,30 @@ methods: { //注册功能 register() { - console.log(this.patientName) - appRegister(this.patientName, this.phone, this.password, this.verification).then(res => { - console.log(res) - if (res.code == 200) { - this.$refs.uToast.show({ - title: '注册成功,前往登录', - type: 'success', - url: '/pages/login/login', - duration: '1500' - }) - } else { - this.$refs.uToast.show({ - title: res.msg, - type: 'error' - }) - } - }) + if (this.password !== this.newpassword) { + this.$refs.uToast.show({ + title: '密码输入不一致,请重新输入', + type: 'error', + duration: '1500' + }) + } else { + appRegister(this.patientName, this.phone, this.password, this.verification).then(res => { + console.log(res) + if (res.code == 200) { + this.$refs.uToast.show({ + title: '注册成功,前往登录', + type: 'success', + url: '/pages/login/login', + duration: '1500' + }) + } else { + this.$refs.uToast.show({ + title: res.msg, + type: 'error' + }) + } + }) + } }, //跳转登录页 gologin() { diff --git a/pages/site/site.vue b/pages/site/site.vue index 3a95cc9..d468e84 100644 --- a/pages/site/site.vue +++ b/pages/site/site.vue @@ -6,8 +6,7 @@ + :markers="markers"> diff --git a/pages/startup/startup.vue b/pages/startup/startup.vue index 1ae11a7..5122861 100644 --- a/pages/startup/startup.vue +++ b/pages/startup/startup.vue @@ -1,6 +1,6 @@