diff --git a/pages.json b/pages.json index fe916df..c118540 100644 --- a/pages.json +++ b/pages.json @@ -3,22 +3,14 @@ { "path": "pages/index/index", "style": { - "navigationBarTitleText": "" + "navigationBarTitleText": "预约就诊" } }, { "path" : "pages/prebook_list/prebook_list", - "style" : - { - "navigationBarTitleText": "预约列表", - "enablePullDownRefresh": false - } - }, - { - "path" : "pages/map/map", "style" : { - "navigationBarTitleText": "", + "navigationBarTitleText": "预约列表", "enablePullDownRefresh": false } }, @@ -60,30 +52,21 @@ "path" : "pages/prebook/prebook", "style" : { - "navigationBarTitleText": "", + "navigationBarTitleText": "预约就诊", "enablePullDownRefresh": false } }, { "path" : "pages/visitors/visitors", - "style" : - { - "navigationBarTitleText": "", - "enablePullDownRefresh": false - } - }, - { - "path" : "pages/login/login", "style" : { - "navigationBarTitleText": "", + "navigationBarTitleText": "就诊人", "enablePullDownRefresh": false - } - } + } + } ], "globalStyle": { "navigationBarTextStyle": "black", - "navigationBarTitleText": "", "navigationBarBackgroundColor": "#F8F8F8", "backgroundColor": "#F8F8F8", "navigationStyle":"custom" diff --git a/pages/index/index.vue b/pages/index/index.vue index 24dd3b8..a2b88df 100644 --- a/pages/index/index.vue +++ b/pages/index/index.vue @@ -107,11 +107,11 @@ // if(!rebackPagePath) } }, - onShow() { + async onShow() { this.doctor_id = getApp().globalData.doctorId if(!this.doctor_id) return - var title = '' + var title = '预约就诊' if(this.code) title = '登录' uni.setNavigationBarTitle({ title:title @@ -123,7 +123,7 @@ // this.login() // return // } - this.getDoctorInfo() + await this.getDoctorInfo() }, methods: { toLocation(hospital){ @@ -160,10 +160,9 @@ // } // }); }, - getDoctorInfo() { + async getDoctorInfo() { // if(this.loginToken) return; - - this.$http.req('index_info', {}, 'GET').then(data=>{ + await this.$http.req('index_info', {}, 'GET').then(data=>{ if(data == -1) return this.pageShow = true this.doctorInfo = data @@ -174,7 +173,7 @@ if(this.doctorInfo.hospital_list && this.doctorInfo.hospital_list.length>0){ this.hospitals = this.doctorInfo.hospital_list } - + var docname = this.doctorInfo.doctor_info.name if(this.doctorInfo.appoint_list && this.doctorInfo.appoint_list.length>0){ this.recentAppoint = this.doctorInfo.appoint_list } diff --git a/pages/login/login.vue b/pages/login/login.vue deleted file mode 100644 index 8183fd0..0000000 --- a/pages/login/login.vue +++ /dev/null @@ -1,22 +0,0 @@ - - - - - diff --git a/pages/map/map.vue b/pages/map/map.vue deleted file mode 100644 index 677f9a6..0000000 --- a/pages/map/map.vue +++ /dev/null @@ -1,47 +0,0 @@ - - - - diff --git a/pages/prebook/prebook.vue b/pages/prebook/prebook.vue index ccbf98f..2114723 100644 --- a/pages/prebook/prebook.vue +++ b/pages/prebook/prebook.vue @@ -51,9 +51,6 @@ import SliderBox from '@/components/sliderBox.vue' export default { onLoad(op) { - uni.setNavigationBarTitle({ - title:'李静医生预约就诊' - }) }, data() { return { diff --git a/pages/prebook_list/prebook_list.vue b/pages/prebook_list/prebook_list.vue index 9b8f194..6dfe0c4 100644 --- a/pages/prebook_list/prebook_list.vue +++ b/pages/prebook_list/prebook_list.vue @@ -42,11 +42,13 @@ var timerobj = setTimeout(function(){ uni.hideLoading() }, 3000) - this.$http.req('client/user/appoint/', param, 'GET', true).then(data=>{ + this.$http.req('get_appoints', param, 'POST', true).then(data=>{ clearTimeout(timerobj) uni.hideLoading() if(data == -1) return this.bookList = data.data + console.log(123) + // this.bookList = [ // { // "id": 27, @@ -254,7 +256,7 @@ var param = new Object() param.page = 1 param.limit = 10000 - this.$http.req('client/user/visit_user/', param, 'GET').then(data=>{ + this.$http.req('get_appoints', param).then(data=>{ if(data == -1) return this.getBookData() this.vistors = data.data diff --git a/pages/visitors/visitors.vue b/pages/visitors/visitors.vue index ee6821c..e4a9669 100644 --- a/pages/visitors/visitors.vue +++ b/pages/visitors/visitors.vue @@ -97,7 +97,7 @@ return } }, - onShow() { + onReady() { if(this.type == 2){ uni.setNavigationBarTitle({ title:'就诊人'