Commit d903206d authored by huangyecong's avatar huangyecong

添加体检机构列表

parent 07040959
...@@ -20,4 +20,24 @@ api.getPackageList = function (data) { ...@@ -20,4 +20,24 @@ api.getPackageList = function (data) {
api.getAppointmentList = function (data) { api.getAppointmentList = function (data) {
return req.post('/api/mn/mobile/getAppointmentList', data) return req.post('/api/mn/mobile/getAppointmentList', data)
} }
// 省
api.getProvinceList = function (data) {
return req.post('/api/mobile/getProvinceList', data)
}
// 市
api.getCityListByProvinceCode = function (data) {
return req.post('/api/mobile/getCityListByProvinceCode', data)
}
// 区/城市
api.getDistrictListByCityCode = function (data) {
return req.post('/api/mobile/getDistrictListByCityCode', data)
}
// 体检机构列表
api.getSupplierList = function (data) {
return req.post('/api/mn/mobile/getSupplierList', data)
}
// 体检中心列表
api.getShopByDistrictCode = function (data) {
return req.post('/api/mn/mobile/getShopByDistrictCode', data)
}
export default api export default api
...@@ -52,7 +52,7 @@ ...@@ -52,7 +52,7 @@
:key="index" :key="index"
:class="index === selectIndex ? 'active' : ''" :class="index === selectIndex ? 'active' : ''"
@click="clickTab(index)" @click="clickTab(index)"
>{{ item }}</span >{{ item.supplierName }}</span
> >
</div> </div>
</div> </div>
...@@ -83,7 +83,7 @@ ...@@ -83,7 +83,7 @@
@cancleDate="getCancle" @cancleDate="getCancle"
@changeDay=" @changeDay="
(date) => { (date) => {
return dateChange(date, 0); return dateChange(date, 0)
} }
" "
/> />
...@@ -92,66 +92,123 @@ ...@@ -92,66 +92,123 @@
</template> </template>
<script> <script>
import reserveDate from "../../../components/reserve-date"; import api from '@/api/customer'
import reserveDate from '../../../components/reserve-date'
export default { export default {
name: "selectInstitution", name: 'selectInstitution',
components: { components: {
reserveDate, reserveDate,
}, },
props: {}, props: {
id: {
type: String | Number,
default: '',
},
},
data() { data() {
return { return {
datePickShow: false, datePickShow: false,
selectIndex: 0, selectIndex: 0,
provinceList: ["上海市"], provinceList: ['上海市'],
provinceList: ["上海市"], provinceList: ['上海市'],
areaList: ["静安区"], areaList: ['静安区'],
mechanismList: ["全部", "慈铭", "美年"], mechanismList: [],
hospitalList: [ hospitalList: [
{ {
name: "上海张江分院", name: '上海张江分院',
address: "上海市浦东新区海科路777号", address: '上海市浦东新区海科路777号',
}, },
{ {
name: "上海张江分院", name: '上海张江分院',
address: "上海市浦东新区海科路777号", address: '上海市浦东新区海科路777号',
}, },
{ {
name: "上海张江分院", name: '上海张江分院',
address: "上海市浦东新区海科路777号", address: '上海市浦东新区海科路777号',
}, },
{ {
isDisabled: true, isDisabled: true,
name: "上海张江分院", name: '上海张江分院',
address: "上海市浦东新区海科路777号", address: '上海市浦东新区海科路777号',
}, },
], ],
}; }
},
created() {
this.getProvinceList()
this.getSupplierList() //获取体检机构
}, },
methods: { methods: {
// 省
async getProvinceList() {
const query = {
customerSex: '',
customerMaritalStatus: '',
chooseList: [],
payList: [],
}
await api.getProvinceList().then((res) => {
console.log('省=', res)
})
// await this.getCityListByProvinceCode()
// await this.getDistrictListByCityCode()
},
// 市
getCityListByProvinceCode() {
api.getCityListByProvinceCode().then((res) => {
console.log('市=', res)
})
},
// 区/城市
getDistrictListByCityCode() {
api.getDistrictListByCityCode().then((res) => {
console.log('区/城市=', res)
})
},
// 获取体检机构
getSupplierList() {
// this.id
api.getSupplierList({ servicepackageId: '1043' }).then((res) => {
if (res.returnCode == '0000') {
this.mechanismList = [
{
status: '0',
supplierName: '全部',
},
...res.content,
]
console.log('获取体检机构=',this.mechanismList)
} else {
this.$message.error(res.returnMsg)
}
})
},
// 选择体检机构 // 选择体检机构
clickTab(index) { clickTab(index) {
this.selectIndex = index; this.selectIndex = index
}, },
// 打开日期弹框 // 打开日期弹框
openDatePicker(item) { openDatePicker(item) {
if (item.isDisabled) { if (item.isDisabled) {
return; return
} }
this.datePickShow = true; this.datePickShow = true
}, },
getConfirm(val) { getConfirm(val) {
this.datePickShow = false; this.datePickShow = false
}, },
getCancle(val) { getCancle(val) {
this.datePickShow = false; this.datePickShow = false
}, },
dateChange(date, type) { dateChange(date, type) {
console.log(date); console.log(date)
}, },
}, },
}; }
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
......
...@@ -6,22 +6,27 @@ ...@@ -6,22 +6,27 @@
<div class="info"> <div class="info">
<div class="item"> <div class="item">
<span class="label">姓名:</span> <span class="label">姓名:</span>
<a-input readonly></a-input> <a-input default-value="11111" disabled></a-input>
</div> </div>
<div class="item"> <div class="item">
<span class="label">性别:</span> <a-input readonly></a-input> <span class="label">性别:</span>
<a-input :default-value="customerInfo.sex" disabled />
</div>
<div class="item">
<span class="label">婚姻状况</span>
<a-input :default-value="customerInfo.maritalStatus" />
</div> </div>
<div class="item"> <div class="item">
<span class="label">身份证:</span> <span class="label">身份证:</span>
<a-input readonly>小京巴</a-input> <a-input :default-value="customerInfo.idNo" disabled />
</div> </div>
<div class="item"> <div class="item">
<span class="label">手机号码:</span> <span class="label">手机号码:</span>
<a-input readonly>小京巴</a-input> <a-input :default-value="customerInfo.phone" />
</div> </div>
<div class="item"> <div class="item">
<span class="label">出生日期:</span> <span class="label">出生日期:</span>
<a-input readonly>小京巴</a-input> <a-input :default-value="customerInfo.birthDate" disabled />
</div> </div>
</div> </div>
<div class="reset"> <div class="reset">
...@@ -32,7 +37,7 @@ ...@@ -32,7 +37,7 @@
<div class="right"> <div class="right">
<Combos v-if="false" /> <Combos v-if="false" />
<Detail v-if="!next" /> <Detail v-if="!next" />
<SelectInstitution /> <SelectInstitution :id="id" />
</div> </div>
</div> </div>
<div class="btn"> <div class="btn">
...@@ -42,12 +47,12 @@ ...@@ -42,12 +47,12 @@
</template> </template>
<script> <script>
import SelectInstitution from "./components/selectInstitution.vue"; import SelectInstitution from './components/selectInstitution.vue'
import Combos from "./components/combo.vue"; import Combos from './components/combo.vue'
import Detail from "./components/detail.vue"; import Detail from './components/detail.vue'
import api from '@/api/customer'
export default { export default {
name: "componentName", name: 'componentName',
components: { components: {
Combos, Combos,
Detail, Detail,
...@@ -57,13 +62,36 @@ export default { ...@@ -57,13 +62,36 @@ export default {
data() { data() {
return { return {
next: true, next: true,
}; id: '', //客户id
customerInfo: {
// name: '',
// sex: '',
// idNo: '',
// phone: '',
// birthDate: '',
}, //客户信息
}
},
created() {
const { id } = this.$route.query
this.id = id
this.getCustomerDetail() //客户信息
}, },
methods: { methods: {
nextStep() {}, nextStep() {},
// 获取客户信息
getCustomerDetail() {
api.getCustomerDetail({ id: parseInt(this.id) }).then((res) => {
if (res.returnCode == '0000') {
this.customerInfo = res.content
} else {
this.$message.error(res.returnMsg)
}
})
}, },
}; },
}
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
>立即预约</a-button >立即预约</a-button
> >
<div class="date"> <div class="date">
有效期至:{{ item.validityStart }} ~ {{ item.validityEnd }} 有效期至:{{ item.validityEnd }}
</div> </div>
</div> </div>
</div> </div>
......
...@@ -92,7 +92,7 @@ export default { ...@@ -92,7 +92,7 @@ export default {
created() { created() {
const { id } = this.$route.query const { id } = this.$route.query
this.id = id this.id = id
this.getCustomerDetail() this.getCustomerDetail()//客户信息
this.getPackageList() //待预约列表 this.getPackageList() //待预约列表
this.getAppointmentList() //已预约列表 this.getAppointmentList() //已预约列表
}, },
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment