diff --git a/pages/visitors/visitors.vue b/pages/visitors/visitors.vue index 7fbfce8..54b2071 100644 --- a/pages/visitors/visitors.vue +++ b/pages/visitors/visitors.vue @@ -25,11 +25,11 @@ - + {{item.real_name}} 身份证尾号:{{item.id_no}} - + {{item2.hospital_name}} {{item2.hospital_dept}} @@ -108,6 +108,44 @@ } }, methods: { + modifyVistor(visitor){ + + }, + delVistor(visitor){ + console.log(visitor) + var that = this + uni.showModal({ + title:'删除', + content:'确认删除就诊人('+visitor.real_name+')?', + success(res) { + if(!res.confirm) return + that.$http.req('client/user/visit_user/'+visitor.id, {}, 'DELETE').then(data=>{ + if(data == -1) return + that.getVisitors() + }); + } + }) + return; + }, + vistorOption(visitor){ + var that = this + uni.showActionSheet({ + itemList: ['修改就诊人信息', '删除就诊人'], + success: function (res) { + if(res.tapIndex == 0){ + that.modifyVistor(visitor) + return + } + if(res.tapIndex == 1){ + that.delVistor(visitor) + return + } + }, + fail: function (res) { + } + }); + console.log(visitor) + }, chooseVisitor(info, key){ this.selectCount = 0 this.visitUsers[key].select = !this.visitUsers[key].select