Commit d903206d authored by huangyecong's avatar huangyecong

添加体检机构列表

parent 07040959
......@@ -20,4 +20,24 @@ api.getPackageList = function (data) {
api.getAppointmentList = function (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
......@@ -52,7 +52,7 @@
:key="index"
:class="index === selectIndex ? 'active' : ''"
@click="clickTab(index)"
>{{ item }}</span
>{{ item.supplierName }}</span
>
</div>
</div>
......@@ -83,7 +83,7 @@
@cancleDate="getCancle"
@changeDay="
(date) => {
return dateChange(date, 0);
return dateChange(date, 0)
}
"
/>
......@@ -92,66 +92,123 @@
</template>
<script>
import reserveDate from "../../../components/reserve-date";
import api from '@/api/customer'
import reserveDate from '../../../components/reserve-date'
export default {
name: "selectInstitution",
name: 'selectInstitution',
components: {
reserveDate,
},
props: {},
props: {
id: {
type: String | Number,
default: '',
},
},
data() {
return {
datePickShow: false,
selectIndex: 0,
provinceList: ["上海市"],
provinceList: ["上海市"],
areaList: ["静安区"],
mechanismList: ["全部", "慈铭", "美年"],
provinceList: ['上海市'],
provinceList: ['上海市'],
areaList: ['静安区'],
mechanismList: [],
hospitalList: [
{
name: "上海张江分院",
address: "上海市浦东新区海科路777号",
name: '上海张江分院',
address: '上海市浦东新区海科路777号',
},
{
name: "上海张江分院",
address: "上海市浦东新区海科路777号",
name: '上海张江分院',
address: '上海市浦东新区海科路777号',
},
{
name: "上海张江分院",
address: "上海市浦东新区海科路777号",
name: '上海张江分院',
address: '上海市浦东新区海科路777号',
},
{
isDisabled: true,
name: "上海张江分院",
address: "上海市浦东新区海科路777号",
name: '上海张江分院',
address: '上海市浦东新区海科路777号',
},
],
};
}
},
created() {
this.getProvinceList()
this.getSupplierList() //获取体检机构
},
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) {
this.selectIndex = index;
this.selectIndex = index
},
// 打开日期弹框
openDatePicker(item) {
if (item.isDisabled) {
return;
return
}
this.datePickShow = true;
this.datePickShow = true
},
getConfirm(val) {
this.datePickShow = false;
this.datePickShow = false
},
getCancle(val) {
this.datePickShow = false;
this.datePickShow = false
},
dateChange(date, type) {
console.log(date);
console.log(date)
},
},
};
}
</script>
<style lang="less" scoped>
......
......@@ -6,22 +6,27 @@
<div class="info">
<div class="item">
<span class="label">姓名:</span>
<a-input readonly></a-input>
<a-input default-value="11111" disabled></a-input>
</div>
<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 class="item">
<span class="label">身份证:</span>
<a-input readonly>小京巴</a-input>
<a-input :default-value="customerInfo.idNo" disabled />
</div>
<div class="item">
<span class="label">手机号码:</span>
<a-input readonly>小京巴</a-input>
<a-input :default-value="customerInfo.phone" />
</div>
<div class="item">
<span class="label">出生日期:</span>
<a-input readonly>小京巴</a-input>
<a-input :default-value="customerInfo.birthDate" disabled />
</div>
</div>
<div class="reset">
......@@ -32,7 +37,7 @@
<div class="right">
<Combos v-if="false" />
<Detail v-if="!next" />
<SelectInstitution />
<SelectInstitution :id="id" />
</div>
</div>
<div class="btn">
......@@ -42,12 +47,12 @@
</template>
<script>
import SelectInstitution from "./components/selectInstitution.vue";
import Combos from "./components/combo.vue";
import Detail from "./components/detail.vue";
import SelectInstitution from './components/selectInstitution.vue'
import Combos from './components/combo.vue'
import Detail from './components/detail.vue'
import api from '@/api/customer'
export default {
name: "componentName",
name: 'componentName',
components: {
Combos,
Detail,
......@@ -57,13 +62,36 @@ export default {
data() {
return {
next: true,
};
id: '', //客户id
customerInfo: {
// name: '',
// sex: '',
// idNo: '',
// phone: '',
// birthDate: '',
}, //客户信息
}
},
created() {
const { id } = this.$route.query
this.id = id
this.getCustomerDetail() //客户信息
},
methods: {
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>
<style lang="less" scoped>
......
......@@ -22,7 +22,7 @@
>立即预约</a-button
>
<div class="date">
有效期至:{{ item.validityStart }} ~ {{ item.validityEnd }}
有效期至:{{ item.validityEnd }}
</div>
</div>
</div>
......
......@@ -92,7 +92,7 @@ export default {
created() {
const { id } = this.$route.query
this.id = id
this.getCustomerDetail()
this.getCustomerDetail()//客户信息
this.getPackageList() //待预约列表
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