更新 省市区

main
鹿和sa0ChunLuyu 1 year ago
parent 0a7afdc786
commit df6eec8d4b

@ -35,54 +35,63 @@ class ApiMapController extends Controller
'GetGeJianButtonList' => $base_url . '/api/H5/GetGeJianButtonList',
'ArticleGetList' => $base_url . '/api/H5/ArticleGetList',
'ArticleGetDetail' => $base_url . '/api/H5/ArticleGetDetail',
'GetAllItems' => $base_url . '/api/H5/GetAllItems',//获取全部自选项目
'BuyInfo' => $base_url . '/api/H5/BuyInfo',//获取全部自选项目
'GetComboSort' => $base_url . '/api/H5/GetComboSort',//套餐排序、筛选标签
'GetPersonIntegralSaveMoneyCouponInfo' => $base_url . '/api/H5/GetPersonIntegralSaveMoneyCouponInfo',//获取就诊人基本信息和预存款、代金券、积分
'DoctorGetList' => $base_url . '/api/H5/DoctorGetList',//获取体检医生列表
'ComboRecommend' => $base_url . '/api/H5/ComboRecommend',//套餐推荐
'GetReadme' => $base_url . '/api/H5/GetReadme',//须知
'NMRGetMonthPlanCount' => $base_url . '/api/H5/NMRGetMonthPlanCount',//核磁每日号源
'NMRGetDayPlanList' => $base_url . '/api/H5/NMRGetDayPlanList',//核磁每日号源
'GetGroupUnit' => $base_url . '/api/H5/GetGroupUnit',//团检登记查询获取单位分组
'GetGroupCombo' => $base_url . '/api/H5/GetGroupCombo',//获取团检套餐
'OrderCreate' => $base_url . '/api/H5/OrderCreate',//创建订单
'GetReportList' => $base_url . '/api/H5/GetReportList',//获取关联的所有体检人报告列表
'GetReportJieLunJianYi' => $base_url . '/api/H5/GetReportJieLunJianYi',//获取报告结论建议页面数据
'GetReportDetaiList' => $base_url . '/api/H5/GetReportDetaiList',//完整报告中的列表
'GetReportDetai' => $base_url . '/api/H5/GetReportDetai',//完整报告中的详情
'StartPay' => $base_url . '/api/H5/StartPay',//开始支付
'CheckPay' => $base_url . '/api/H5/CheckPay',//支付查询
'Refund' => $base_url . '/api/H5/Refund',//退款
'GetMonthPlanCount' => $base_url . '/api/H5/GetMonthPlanCount',//按月获取每日号源
'GetDayPlanList' => $base_url . '/api/H5/GetDayPlanList',//获取每日号源
'ComboCompare' => $base_url . '/api/H5/ComboCompare',//套餐对比
'GetOrderDetail' => $base_url . '/api/H5/GetOrderDetail',//获取订单详情
'ReportContrast' => $base_url . '/api/H5/ReportContrast',//报告对比
'QuestionGetList' => $base_url . '/api/H5/QuestionGetList',//获取问卷
'QuestionSubmitAnswer' => $base_url . '/api/H5/QuestionSubmitAnswer',//提交问卷回答
'AnalysisTypeGetList' => $base_url . '/api/H5/AnalysisTypeGetList',//趋势分析项目列表
'ReportAnalysis' => $base_url . '/api/H5/ReportAnalysis',//报告趋势详情
'HunQianQuestionSubmit' => $base_url . '/api/H5/HunQianQuestionSubmit',//婚前问卷提交
'ChangeAppointment' => $base_url . '/api/H5/ChangeAppointment',//改约
'UsableIntegralSaveMoney' => $base_url . '/api/H5/UsableIntegralSaveMoney',//获取本单可用金额和积分
'GetAllItems' => $base_url . '/api/H5/GetAllItems', //获取全部自选项目
'BuyInfo' => $base_url . '/api/H5/BuyInfo', //获取全部自选项目
'GetComboSort' => $base_url . '/api/H5/GetComboSort', //套餐排序、筛选标签
'GetPersonIntegralSaveMoneyCouponInfo' => $base_url . '/api/H5/GetPersonIntegralSaveMoneyCouponInfo', //获取就诊人基本信息和预存款、代金券、积分
'DoctorGetList' => $base_url . '/api/H5/DoctorGetList', //获取体检医生列表
'ComboRecommend' => $base_url . '/api/H5/ComboRecommend', //套餐推荐
'GetReadme' => $base_url . '/api/H5/GetReadme', //须知
'NMRGetMonthPlanCount' => $base_url . '/api/H5/NMRGetMonthPlanCount', //核磁每日号源
'NMRGetDayPlanList' => $base_url . '/api/H5/NMRGetDayPlanList', //核磁每日号源
'GetGroupUnit' => $base_url . '/api/H5/GetGroupUnit', //团检登记查询获取单位分组
'GetGroupCombo' => $base_url . '/api/H5/GetGroupCombo', //获取团检套餐
'OrderCreate' => $base_url . '/api/H5/OrderCreate', //创建订单
'GetReportList' => $base_url . '/api/H5/GetReportList', //获取关联的所有体检人报告列表
'GetReportJieLunJianYi' => $base_url . '/api/H5/GetReportJieLunJianYi', //获取报告结论建议页面数据
'GetReportDetaiList' => $base_url . '/api/H5/GetReportDetaiList', //完整报告中的列表
'GetReportDetai' => $base_url . '/api/H5/GetReportDetai', //完整报告中的详情
'StartPay' => $base_url . '/api/H5/StartPay', //开始支付
'CheckPay' => $base_url . '/api/H5/CheckPay', //支付查询
'Refund' => $base_url . '/api/H5/Refund', //退款
'GetMonthPlanCount' => $base_url . '/api/H5/GetMonthPlanCount', //按月获取每日号源
'GetDayPlanList' => $base_url . '/api/H5/GetDayPlanList', //获取每日号源
'ComboCompare' => $base_url . '/api/H5/ComboCompare', //套餐对比
'GetOrderDetail' => $base_url . '/api/H5/GetOrderDetail', //获取订单详情
'ReportContrast' => $base_url . '/api/H5/ReportContrast', //报告对比
'QuestionGetList' => $base_url . '/api/H5/QuestionGetList', //获取问卷
'QuestionSubmitAnswer' => $base_url . '/api/H5/QuestionSubmitAnswer', //提交问卷回答
'AnalysisTypeGetList' => $base_url . '/api/H5/AnalysisTypeGetList', //趋势分析项目列表
'ReportAnalysis' => $base_url . '/api/H5/ReportAnalysis', //报告趋势详情
'HunQianQuestionSubmit' => $base_url . '/api/H5/HunQianQuestionSubmit', //婚前问卷提交
'ChangeAppointment' => $base_url . '/api/H5/ChangeAppointment', //改约
'UsableIntegralSaveMoney' => $base_url . '/api/H5/UsableIntegralSaveMoney', //获取本单可用金额和积分
'FenzhenAbandon' => $base_url . '/api/H5/Fenzhen/abandon',// 分诊弃检
'FenzhenList' => $base_url . '/api/H5/Fenzhen/list',// 分诊时间线
'FenzhenInfo' => $base_url . '/api/H5/Fenzhen/info',// 分诊项目详情
'FenzhenCheck' => $base_url . '/api/H5/Fenzhen/check',// 分诊检测
'FenzhenAbandon' => $base_url . '/api/H5/Fenzhen/abandon', // 分诊弃检
'FenzhenList' => $base_url . '/api/H5/Fenzhen/list', // 分诊时间线
'FenzhenInfo' => $base_url . '/api/H5/Fenzhen/info', // 分诊项目详情
'FenzhenCheck' => $base_url . '/api/H5/Fenzhen/check', // 分诊检测
'QuestionGet' => $base_url . '/api/H5/Question/get',// 问卷调查
'QuestionSubmit' => $base_url . '/api/H5/Question/submit',// 问卷提交
'QuestionLogInfo' => $base_url . '/api/H5/QuestionLog/info',// 提交信息
'QuestionLogList' => $base_url . '/api/H5/QuestionLog/list',// 问卷列表
'QuestionLogDelete' => $base_url . '/api/H5/QuestionLog/delete',// 问卷删除记录
'QuestionLogPush' => $base_url . '/api/H5/QuestionLog/push',// 上次答题记录
'QuestionChoose' => $base_url . '/api/H5/Question/choose',// 健康问卷列表
'QuestionGet' => $base_url . '/api/H5/Question/get', // 问卷调查
'QuestionSubmit' => $base_url . '/api/H5/Question/submit', // 问卷提交
'QuestionLogInfo' => $base_url . '/api/H5/QuestionLog/info', // 提交信息
'QuestionLogList' => $base_url . '/api/H5/QuestionLog/list', // 问卷列表
'QuestionLogDelete' => $base_url . '/api/H5/QuestionLog/delete', // 问卷删除记录
'QuestionLogPush' => $base_url . '/api/H5/QuestionLog/push', // 上次答题记录
'QuestionChoose' => $base_url . '/api/H5/Question/choose', // 健康问卷列表
'AddressData' => $base_url . '/api/H5/Address/data', // 省市区数据
];
}
public function address()
{
$address_data = file_get_contents(public_path('assets/address.json'));
return \Yz::Return(true, '获取成功', [
'data' => json_decode($address_data, true)
]);
}
public function test()
{
return \Yz::Return(true, '获取成功', [

File diff suppressed because one or more lines are too long

@ -27,5 +27,6 @@ Route::any("/api/H5/Config/config", [\App\Http\Controllers\API\H5\HomeController
Route::any("/api/Demo/pay_back", [\App\Http\Controllers\API\DemoController::class, 'pay_back']);
Route::any("/api/Demo/pay", [\App\Http\Controllers\API\DemoController::class, 'pay']);
Route::post("/api/H5/Address/data", [\App\Http\Controllers\API\ApiMapController::class, 'address']);
Route::any("/api/ApiMap/test", [\App\Http\Controllers\API\ApiMapController::class, 'test']);
Route::post("/api/ApiMap/{type}", [\App\Http\Controllers\API\ApiMapController::class, 'list']);

@ -8,6 +8,7 @@
ref
} from 'vue'
import {
$url,
$api,
$response
} from '@/api'
@ -19,9 +20,36 @@
} from '@/store'
const $store = useStore()
import TitleComponent from '../src/title.vue'
const address_data = ref([])
const getAddressData = async () => {
const response = await $api('AddressData')
$response(response, () => {
address_data.value = response.data.data.map((i) => {
return {
text: i.name,
value: i.code,
children: i.children.map((ii) => {
return {
text: ii.name,
value: ii.code,
children: ii.children.map((iii) => {
return {
text: iii.name,
value: iii.code
}
})
}
})
}
})
})
}
// const getAddressData = () => {
// address_data.value = $address
// }
const mountedAction = () => {
getAddressData()
}
const config_ref = ref(null)
@ -66,8 +94,47 @@
'姓名': "",
'生日': getEndDate(),
'民族': "",
'现地址省市区': [{
value: '11',
text: '北京市'
},
{
value: '1101',
text: '市辖区'
},
{
value: '110101',
text: '东城区'
},
],
'现地址': "",
'详细地址省市区': [{
value: '11',
text: '北京市'
},
{
value: '1101',
text: '市辖区'
},
{
value: '110101',
text: '东城区'
},
],
'详细地址': "",
'户籍地址省市区': [{
value: '11',
text: '北京市'
},
{
value: '1101',
text: '市辖区'
},
{
value: '110101',
text: '东城区'
},
],
'户籍地址': "",
'工作单位': "",
'文化程度': "",
@ -113,6 +180,10 @@
})
}
const addressChange = (e, key) => {
input_data.value[key] = e.detail.value
}
onShow(() => {
if (!!config_ref.value) {
mountedAction()
@ -146,6 +217,11 @@
<view>{{ input_data[k] }}</view>
</picker>
</template>
<template v-else-if="['','',''].includes(k)">
<uni-data-picker v-if="address_data.length !== 0" placeholder="请选择地址" popup-title=""
:localdata="address_data" :step-searh="true" @change="(e)=>{addressChange(e,k)}">
</uni-data-picker>
</template>
<template v-else-if="k === ''">
<view>
<radio-group class="radio_wrapper" @change="(e)=>{radioChange(e, k)}">
@ -169,7 +245,32 @@
</view>
</view>
</template>
<style>
.uni-data-tree-dialog {
z-index: 999;
}
.input-value-border {
border: none !important;
}
.input-value {
padding: 0 !important;
}
.selected-area {
font-size: 30rpx !important;
}
.icon-clear {
display: none !important;
}
</style>
<style scoped>
.address_item_wrapper {
margin-right: 5rpx;
}
.radio_item_wrapper {
margin-right: 30rpx;
display: flex;
@ -205,6 +306,7 @@
.form_input_wrapper {
width: calc(100% - 140rpx - 20px);
margin-left: 20px;
position: relative;
}
.form_title_wrapper {

Loading…
Cancel
Save