wewe
This commit is contained in:
parent
6f3401f501
commit
40eb50faf8
4
app.json
4
app.json
@ -68,6 +68,10 @@
|
|||||||
"root": "pages/AddTherapeuticRegimen",
|
"root": "pages/AddTherapeuticRegimen",
|
||||||
"name": "AddTherapeuticRegimen",
|
"name": "AddTherapeuticRegimen",
|
||||||
"pages": ["index"]
|
"pages": ["index"]
|
||||||
|
},{
|
||||||
|
"root": "pages/mmp-7",
|
||||||
|
"name": "mmp-7",
|
||||||
|
"pages": ["index"]
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"window": {
|
"window": {
|
||||||
|
|||||||
189
pages/mmp-7/index.js
Normal file
189
pages/mmp-7/index.js
Normal file
@ -0,0 +1,189 @@
|
|||||||
|
// pages/followUp/index.js
|
||||||
|
Page({
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 页面的初始数据
|
||||||
|
*/
|
||||||
|
data: {
|
||||||
|
style: 'border: 2rpx solid #efefef;border-radius: 12rpx;',
|
||||||
|
personInfo: {
|
||||||
|
name: '',
|
||||||
|
gender: 0,
|
||||||
|
birth: '',
|
||||||
|
address: [],
|
||||||
|
introduction: '',
|
||||||
|
yearType: 0,
|
||||||
|
|
||||||
|
// photos: [],
|
||||||
|
},
|
||||||
|
mode: '',
|
||||||
|
dateVisible: false,
|
||||||
|
date: new Date('2021-12-23').getTime(), // 支持时间戳传入
|
||||||
|
dateText: '',
|
||||||
|
filter(type, options) {
|
||||||
|
if (type === 'year') {
|
||||||
|
return options.sort((a, b) => b.value - a.value);
|
||||||
|
}
|
||||||
|
return options;
|
||||||
|
},
|
||||||
|
popupProps: {
|
||||||
|
usingCustomNavbar: true,
|
||||||
|
},
|
||||||
|
|
||||||
|
formatter(item, index) {
|
||||||
|
if (index === 1) {
|
||||||
|
const label = item.label.slice(0, -1);
|
||||||
|
return {
|
||||||
|
value: item.value,
|
||||||
|
label: calendarMonth[Number(label) - 1],
|
||||||
|
};
|
||||||
|
}
|
||||||
|
if (index === 2) {
|
||||||
|
const [dateValue, weekValue] = item.label.split(' ');
|
||||||
|
const dateSuffixes = {
|
||||||
|
1: 'st',
|
||||||
|
2: 'nd',
|
||||||
|
3: 'rd',
|
||||||
|
};
|
||||||
|
const weekMap = {
|
||||||
|
周一: 'Mon.',
|
||||||
|
周二: 'Tues.',
|
||||||
|
周三: 'Wed.',
|
||||||
|
周四: 'Thurs.',
|
||||||
|
周五: 'Fri.',
|
||||||
|
周六: 'Sat.',
|
||||||
|
周日: 'Sun.',
|
||||||
|
};
|
||||||
|
const label = dateValue.slice(0, -1);
|
||||||
|
|
||||||
|
return {
|
||||||
|
value: item.value,
|
||||||
|
label: `${label}${dateSuffixes[label] || 'th'} ${weekMap[weekValue]}`,
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
value: item.value,
|
||||||
|
label: item.label.slice(0, -1),
|
||||||
|
};
|
||||||
|
},
|
||||||
|
|
||||||
|
originFiles: [
|
||||||
|
{
|
||||||
|
url: 'https://tdesign.gtimg.com/mobile/demos/example4.png',
|
||||||
|
name: 'uploaded1.png',
|
||||||
|
type: 'image',
|
||||||
|
removeBtn: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
url: 'https://tdesign.gtimg.com/mobile/demos/example6.png',
|
||||||
|
name: 'uploaded2.png',
|
||||||
|
type: 'image',
|
||||||
|
removeBtn: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
url: 'https://tdesign.gtimg.com/mobile/demos/example5.png',
|
||||||
|
name: 'uploaded3.png',
|
||||||
|
type: 'image',
|
||||||
|
removeBtn: true,
|
||||||
|
},
|
||||||
|
],
|
||||||
|
gridConfig: {
|
||||||
|
column: 4,
|
||||||
|
width: 160,
|
||||||
|
height: 160,
|
||||||
|
},
|
||||||
|
config: {
|
||||||
|
count: 1,
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
},
|
||||||
|
showPicker(e) {
|
||||||
|
const { mode } = e.currentTarget.dataset;
|
||||||
|
this.setData({
|
||||||
|
[`${mode}Visible`]: true,
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
handleSuccess(e) {
|
||||||
|
console.log(e.detail)
|
||||||
|
const { files } = e.detail;
|
||||||
|
this.setData({
|
||||||
|
originFiles: files,
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleRemove(e) {
|
||||||
|
console.log(e.detail.file);
|
||||||
|
const { index } = e.detail;
|
||||||
|
const { originFiles } = this.data;
|
||||||
|
originFiles.splice(index, 1);
|
||||||
|
this.setData({
|
||||||
|
originFiles,
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleClick(e) {
|
||||||
|
console.log(e.detail.file);
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面加载
|
||||||
|
*/
|
||||||
|
onLoad(options) {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面初次渲染完成
|
||||||
|
*/
|
||||||
|
onReady() {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面显示
|
||||||
|
*/
|
||||||
|
onShow() {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面隐藏
|
||||||
|
*/
|
||||||
|
onHide() {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面卸载
|
||||||
|
*/
|
||||||
|
onUnload() {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 页面相关事件处理函数--监听用户下拉动作
|
||||||
|
*/
|
||||||
|
onPullDownRefresh() {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 页面上拉触底事件的处理函数
|
||||||
|
*/
|
||||||
|
onReachBottom() {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户点击右上角分享
|
||||||
|
*/
|
||||||
|
onShareAppMessage() {
|
||||||
|
|
||||||
|
}
|
||||||
|
})
|
||||||
15
pages/mmp-7/index.json
Normal file
15
pages/mmp-7/index.json
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
{
|
||||||
|
"usingComponents": {
|
||||||
|
"t-cell": "tdesign-miniprogram/cell/cell",
|
||||||
|
"t-input": "tdesign-miniprogram/input/input",
|
||||||
|
"t-date-time-picker": "tdesign-miniprogram/date-time-picker/date-time-picker",
|
||||||
|
"t-row": "tdesign-miniprogram/row/row",
|
||||||
|
"t-col": "tdesign-miniprogram/col/col",
|
||||||
|
"t-button": "tdesign-miniprogram/button/button",
|
||||||
|
"t-upload": "tdesign-miniprogram/upload/upload",
|
||||||
|
"t-radio": "tdesign-miniprogram/radio/radio",
|
||||||
|
"t-radio-group": "tdesign-miniprogram/radio-group/radio-group"
|
||||||
|
},
|
||||||
|
"navigationStyle": "default",
|
||||||
|
"navigationBarTitleText": "诊断信息录入"
|
||||||
|
}
|
||||||
42
pages/mmp-7/index.less
Normal file
42
pages/mmp-7/index.less
Normal file
@ -0,0 +1,42 @@
|
|||||||
|
/* pages/followUp/index.wxss */
|
||||||
|
.follow-up{
|
||||||
|
padding: 28rpx;
|
||||||
|
padding-bottom: 56rpx;
|
||||||
|
.follow-item{
|
||||||
|
background-color: #fff;
|
||||||
|
padding: 28rpx;
|
||||||
|
margin-bottom: 28rpx;
|
||||||
|
border-radius: 20rpx;
|
||||||
|
padding-bottom: 20rpx;
|
||||||
|
}
|
||||||
|
.custom-label {
|
||||||
|
display: inline-flex;
|
||||||
|
}
|
||||||
|
|
||||||
|
.custom-label::after, .input-example__label::after {
|
||||||
|
content: '*';
|
||||||
|
color: red;
|
||||||
|
font-size: 32rpx;
|
||||||
|
margin-left: 4rpx;
|
||||||
|
}
|
||||||
|
.t-overlay{
|
||||||
|
top: 0!important;
|
||||||
|
}
|
||||||
|
.input-example {
|
||||||
|
// background-color: var(--bg-color-demo);
|
||||||
|
padding: 10rpx 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.input-example__label {
|
||||||
|
color: var(--td-text-color-primary);
|
||||||
|
font-size: 24rpx;
|
||||||
|
line-height: 40rpx;
|
||||||
|
margin: 0 8rpx 16rpx;
|
||||||
|
}
|
||||||
|
.box{
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
flex-wrap: wrap;
|
||||||
|
padding-right: 60rpx;
|
||||||
|
}
|
||||||
|
}
|
||||||
225
pages/mmp-7/index.wxml
Normal file
225
pages/mmp-7/index.wxml
Normal file
@ -0,0 +1,225 @@
|
|||||||
|
<!--pages/followUp/index.wxml-->
|
||||||
|
<view class="follow-up">
|
||||||
|
|
||||||
|
<view class="follow-item">
|
||||||
|
<view>胆囊</view>
|
||||||
|
|
||||||
|
<view class="wrapper">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 请裁剪原始超声图像,使胆囊在画面中尽可能充满整个图像,如右图所示</view>
|
||||||
|
</view>
|
||||||
|
<t-upload media-type="{{['image']}}" files="{{originFiles}}" gridConfig="{{gridConfig}}" removeBtn="{{false}}" bind:success="handleSuccess" bind:remove="handleRemove" bind:click="handleClick" bind:sort-end="handleSortEnd" />
|
||||||
|
</view>
|
||||||
|
|
||||||
|
|
||||||
|
<view class="follow-item">
|
||||||
|
<view>
|
||||||
|
门静脉左右分支</view>
|
||||||
|
|
||||||
|
<view class="wrapper">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 请裁剪原始超声图像,使门静脉(cord sign)的左右分支或其潜在区域在画面中最大化填充,如右图所示</view>
|
||||||
|
</view>
|
||||||
|
<t-upload media-type="{{['image']}}" files="{{originFiles}}" gridConfig="{{gridConfig}}" removeBtn="{{false}}" bind:success="handleSuccess" bind:remove="handleRemove" bind:click="handleClick" bind:sort-end="handleSortEnd" />
|
||||||
|
</view>
|
||||||
|
|
||||||
|
|
||||||
|
</view>
|
||||||
|
<view class="follow-item">
|
||||||
|
<view>
|
||||||
|
门静脉右支横截</view>
|
||||||
|
|
||||||
|
<view class="wrapper">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 请裁剪原始超声图像,使肝门区(cord sign)的横切面或其潜在区域在画面中最大化填充,如右图所示</view>
|
||||||
|
</view>
|
||||||
|
<t-upload media-type="{{['image']}}" files="{{originFiles}}" gridConfig="{{gridConfig}}" removeBtn="{{false}}" bind:success="handleSuccess" bind:remove="handleRemove" bind:click="handleClick" bind:sort-end="handleSortEnd" />
|
||||||
|
</view>
|
||||||
|
|
||||||
|
<t-row gutter="12">
|
||||||
|
<t-col span="12">
|
||||||
|
<view class="dark">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 血小板(10^9/L) </view>
|
||||||
|
<t-input placeholder="请输入" size="small" borderless="{{true}}" style="{{style}}" />
|
||||||
|
</view>
|
||||||
|
|
||||||
|
</view>
|
||||||
|
</t-col>
|
||||||
|
<t-col span="12">
|
||||||
|
<view class="dark">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 血红蛋白(g/L)</view>
|
||||||
|
<t-input placeholder="请输入" borderless="{{true}}" style="{{style}}" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</t-col>
|
||||||
|
<t-col span="12">
|
||||||
|
<view class="dark">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 白细胞(10^9/L)</view>
|
||||||
|
<t-input placeholder="请输入" borderless="{{true}}" style="{{style}}" />
|
||||||
|
</view>
|
||||||
|
|
||||||
|
</view>
|
||||||
|
</t-col>
|
||||||
|
|
||||||
|
</t-row>
|
||||||
|
</view>
|
||||||
|
<view class="follow-item">
|
||||||
|
<view>
|
||||||
|
营养指标</view>
|
||||||
|
|
||||||
|
<view class="wrapper">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 上传营养指标检查报告(支持OCR识别)</view>
|
||||||
|
</view>
|
||||||
|
<t-upload media-type="{{['image']}}" files="{{originFiles}}" gridConfig="{{gridConfig}}" removeBtn="{{false}}" bind:success="handleSuccess" bind:remove="handleRemove" bind:click="handleClick" bind:sort-end="handleSortEnd" />
|
||||||
|
</view>
|
||||||
|
|
||||||
|
<t-row gutter="12">
|
||||||
|
<t-col span="12">
|
||||||
|
<view class="dark">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 25(OH)D3 (ng/ml) </view>
|
||||||
|
<t-input placeholder="请输入" size="small" borderless="{{true}}" style="{{style}}" />
|
||||||
|
</view>
|
||||||
|
|
||||||
|
</view>
|
||||||
|
</t-col>
|
||||||
|
<t-col span="12">
|
||||||
|
<view class="dark">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 维生素A (ng/ml)</view>
|
||||||
|
<t-input placeholder="请输入" borderless="{{true}}" style="{{style}}" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</t-col>
|
||||||
|
<t-col span="12">
|
||||||
|
<view class="dark">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 维生素K (ng/ml)</view>
|
||||||
|
<t-input placeholder="请输入" borderless="{{true}}" style="{{style}}" />
|
||||||
|
</view>
|
||||||
|
|
||||||
|
</view>
|
||||||
|
</t-col>
|
||||||
|
<t-col span="12">
|
||||||
|
<view class="dark">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 维生素E (ng/ml)</view>
|
||||||
|
<t-input placeholder="请输入" borderless="{{true}}" style="{{style}}" />
|
||||||
|
</view>
|
||||||
|
|
||||||
|
</view>
|
||||||
|
</t-col>
|
||||||
|
</t-row>
|
||||||
|
</view>
|
||||||
|
<view class="follow-item">
|
||||||
|
<view>
|
||||||
|
B超</view>
|
||||||
|
|
||||||
|
<view class="wrapper">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 上传B超报告(支持OCR识别)</view>
|
||||||
|
</view>
|
||||||
|
<t-upload media-type="{{['image']}}" files="{{originFiles}}" gridConfig="{{gridConfig}}" removeBtn="{{false}}" bind:success="handleSuccess" bind:remove="handleRemove" bind:click="handleClick" bind:sort-end="handleSortEnd" />
|
||||||
|
</view>
|
||||||
|
|
||||||
|
<t-row gutter="12">
|
||||||
|
<t-col span="12">
|
||||||
|
<view class="dark">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 肝肋下(mm)肝肋下(mm)</view>
|
||||||
|
<t-input placeholder="请输入" size="small" borderless="{{true}}" style="{{style}}" />
|
||||||
|
</view>
|
||||||
|
|
||||||
|
</view>
|
||||||
|
</t-col>
|
||||||
|
<t-col span="12">
|
||||||
|
<view class="dark">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 肝剑突下(mm)</view>
|
||||||
|
<t-input placeholder="请输入" borderless="{{true}}" style="{{style}}" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</t-col>
|
||||||
|
<t-col span="12">
|
||||||
|
<view class="dark">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 脾肋下(mm)</view>
|
||||||
|
<t-input placeholder="请输入" borderless="{{true}}" style="{{style}}" />
|
||||||
|
</view>
|
||||||
|
|
||||||
|
</view>
|
||||||
|
</t-col>
|
||||||
|
<t-col span="12">
|
||||||
|
<view class="dark">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 门静脉主干(mm)</view>
|
||||||
|
<t-input placeholder="请输入" borderless="{{true}}" style="{{style}}" />
|
||||||
|
</view>
|
||||||
|
|
||||||
|
</view>
|
||||||
|
</t-col>
|
||||||
|
<t-col span="12">
|
||||||
|
<view class="dark">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 门静脉流速</view>
|
||||||
|
<t-input placeholder="请输入" size="small" borderless="{{true}}" style="{{style}}" />
|
||||||
|
</view>
|
||||||
|
|
||||||
|
</view>
|
||||||
|
</t-col>
|
||||||
|
<t-col span="12">
|
||||||
|
<view class="dark">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 肝弹性值</view>
|
||||||
|
<t-input placeholder="请输入" borderless="{{true}}" style="{{style}}" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</t-col>
|
||||||
|
<t-col span="12">
|
||||||
|
<view class="dark">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 有无肝囊肿</view>
|
||||||
|
<t-radio-group default-value="0" borderless t-class="box">
|
||||||
|
<t-radio block="{{false}}" label="有" value="0" />
|
||||||
|
<t-radio block="{{false}}" label="无" value="1" />
|
||||||
|
</t-radio-group>
|
||||||
|
</view>
|
||||||
|
|
||||||
|
</view>
|
||||||
|
</t-col>
|
||||||
|
<t-col span="12">
|
||||||
|
<view class="dark">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 有无腹水</view>
|
||||||
|
<t-radio-group default-value="0" borderless t-class="box">
|
||||||
|
<t-radio block="{{false}}" label="有" value="0" />
|
||||||
|
<t-radio block="{{false}}" label="无" value="1" />
|
||||||
|
</t-radio-group>
|
||||||
|
</view>
|
||||||
|
|
||||||
|
</view>
|
||||||
|
</t-col>
|
||||||
|
</t-row>
|
||||||
|
</view>
|
||||||
|
<view class="follow-item">
|
||||||
|
<view>
|
||||||
|
MDT电子病历</view>
|
||||||
|
|
||||||
|
<view class="wrapper">
|
||||||
|
<view class="input-example">
|
||||||
|
<view class="input-example__label"> 上传本次随访的电子病历</view>
|
||||||
|
</view>
|
||||||
|
<t-upload media-type="{{['image']}}" files="{{originFiles}}" gridConfig="{{gridConfig}}" removeBtn="{{false}}" bind:success="handleSuccess" bind:remove="handleRemove" bind:click="handleClick" bind:sort-end="handleSortEnd" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
|
||||||
|
<t-button bindtap="clockIn" theme="primary" block bindtap="toQuestionnaire">提交</t-button>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<t-date-time-picker auto-close bind:cancel="hidePicker" bind:change="onPickerChange" cancelBtn="取消" confirmBtn="确认" data-mode="birth" defaultValue="{{personInfo.birth}}" end="{{birthEnd}}" filter="{{birthFilter}}" format="YYYY-MM-DD" mode="date" popup-props="{{ { usingCustomNavbar: true } }}" start="{{birthStart}}" title="选择生日" value="{{personInfo.birth}}" visible="{{birthVisible}}" />
|
||||||
|
</view>
|
||||||
@ -54,11 +54,11 @@ Page({
|
|||||||
|
|
||||||
async onShow() {
|
async onShow() {
|
||||||
const Token = wx.getStorageSync('access_token');
|
const Token = wx.getStorageSync('access_token');
|
||||||
// const personalInfo = await this.getPersonalInfo();
|
|
||||||
console.log(Token)
|
|
||||||
if (Token) {
|
if (Token) {
|
||||||
|
const personalInfo = await this.getPersonalInfo();
|
||||||
this.setData({
|
this.setData({
|
||||||
isLoad: false,
|
isLoad: false,
|
||||||
|
personalInfo: personalInfo,
|
||||||
settingList: [
|
settingList: [
|
||||||
{ label: '用药方案', path: '/pages/therapeuticRegimen/index', icon: 'service', type: 'text' },
|
{ label: '用药方案', path: '/pages/therapeuticRegimen/index', icon: 'service', type: 'text' },
|
||||||
{ label: '健康教育', path: '/pages/article/index', icon: 'setting', type: 'text' },
|
{ label: '健康教育', path: '/pages/article/index', icon: 'setting', type: 'text' },
|
||||||
@ -85,7 +85,7 @@ Page({
|
|||||||
},
|
},
|
||||||
|
|
||||||
async getPersonalInfo() {
|
async getPersonalInfo() {
|
||||||
const info = await request('/api/genPersonalInfo').then((res) => res.data.data);
|
const info = await request('patient/basic/0').then((res) => res);
|
||||||
return info;
|
return info;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|||||||
@ -7,17 +7,16 @@
|
|||||||
<t-cell wx:if="{{!isLoad}}" bordered="{{false}}">
|
<t-cell wx:if="{{!isLoad}}" bordered="{{false}}">
|
||||||
<t-avatar image="{{personalInfo.image}}" slot="left-icon" size="large" />
|
<t-avatar image="{{personalInfo.image}}" slot="left-icon" size="large" />
|
||||||
<view class="my-info__person" slot="description">
|
<view class="my-info__person" slot="description">
|
||||||
<view class="name">{{personalInfo.name}}
|
<view class="name">{{personalInfo.username}}
|
||||||
<text>男 1岁5个月</text>
|
<text>{{personalInfo.sex == 1 ? '男' : '女'}} {{personalInfo.age}}</text>
|
||||||
<t-icon class="edit" slot="right-icon" name="edit" size="36rpx" color="#000000e6" bindtap="onNavigateTo" />
|
<t-icon class="edit" slot="right-icon" name="edit" size="36rpx" color="#000000e6" bindtap="onNavigateTo" />
|
||||||
</view>
|
</view>
|
||||||
<view class="time">胆道闭锁手术时间:2024年12月15日</view>
|
<view class="time">胆道闭锁手术时间:{{personalInfo.operative_date}}</view>
|
||||||
<view class="peld">PELD评分:12
|
<view class="peld">PELD评分:{{personalInfo.risk_value}}
|
||||||
<t-tag class="tag" theme="danger" size="small">高危</t-tag></view>
|
<t-tag wx:if="{{personalInfo.risk_type == 1}}" class="tag" theme="success" size="small">低危</t-tag></view>
|
||||||
<!-- <view class="tags">
|
<t-tag wx:if="{{personalInfo.risk_type == 2}}" class="tag" theme="warning" size="small">中危</t-tag></view>
|
||||||
<t-tag class="tag" variant="light" icon="discount">{{personalInfo.star}}</t-tag>
|
<t-tag wx:if="{{personalInfo.risk_type == 3}}" class="tag" theme="danger" size="small">高危</t-tag></view>
|
||||||
<t-tag class="tag" variant="light" icon="location">{{personalInfo.city}}</t-tag>
|
|
||||||
</view> -->
|
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
|
|||||||
@ -5,17 +5,10 @@ Page({
|
|||||||
personInfo: {
|
personInfo: {
|
||||||
username: '',
|
username: '',
|
||||||
sex: 0,
|
sex: 0,
|
||||||
age: '',
|
|
||||||
id_number: '',
|
id_number: '',
|
||||||
birthday: '',
|
birthday: '',
|
||||||
operative_date: '',
|
operative_date: '',
|
||||||
|
|
||||||
|
|
||||||
birth: '',
|
|
||||||
address: [],
|
|
||||||
introduction: '',
|
|
||||||
yearType: 0
|
|
||||||
// photos: [],
|
|
||||||
},
|
},
|
||||||
genderOptions: [
|
genderOptions: [
|
||||||
{
|
{
|
||||||
@ -41,7 +34,7 @@ Page({
|
|||||||
],
|
],
|
||||||
birthVisible: false,
|
birthVisible: false,
|
||||||
birthStart: '1970-01-01',
|
birthStart: '1970-01-01',
|
||||||
birthEnd: '2025-03-01',
|
birthEnd: new Date().toISOString().split('T')[0],
|
||||||
birthTime: 0,
|
birthTime: 0,
|
||||||
birthFilter: (type, options) => (type === 'year' ? options.sort((a, b) => b.value - a.value) : options),
|
birthFilter: (type, options) => (type === 'year' ? options.sort((a, b) => b.value - a.value) : options),
|
||||||
addressText: '',
|
addressText: '',
|
||||||
@ -54,13 +47,27 @@ Page({
|
|||||||
width: 160,
|
width: 160,
|
||||||
height: 160,
|
height: 160,
|
||||||
},
|
},
|
||||||
|
|
||||||
|
defaultTime: '',
|
||||||
|
newTime: '',
|
||||||
},
|
},
|
||||||
|
|
||||||
onLoad() {
|
onLoad() {
|
||||||
// this.initAreaData();
|
// this.initAreaData();
|
||||||
|
this.getPersonalInfo()
|
||||||
|
},
|
||||||
|
async getPersonalInfo() {
|
||||||
|
const info = await request('patient/basic/0')
|
||||||
|
this.setData({
|
||||||
|
personInfo: {
|
||||||
|
username: info.username,
|
||||||
|
sex: info.sex,
|
||||||
|
id_number: info.id_number,
|
||||||
|
birthday: info.birthday,
|
||||||
|
operative_date: info.operative_date,
|
||||||
|
}
|
||||||
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
getAreaOptions(data, filter) {
|
getAreaOptions(data, filter) {
|
||||||
@ -93,9 +100,12 @@ Page({
|
|||||||
},
|
},
|
||||||
|
|
||||||
showPicker(e) {
|
showPicker(e) {
|
||||||
|
console.log(e)
|
||||||
const { mode } = e.currentTarget.dataset;
|
const { mode } = e.currentTarget.dataset;
|
||||||
this.setData({
|
this.setData({
|
||||||
[`${mode}Visible`]: true,
|
birthVisible: true,
|
||||||
|
defaultTime: e.detail.value,
|
||||||
|
newTime: e.detail.value,
|
||||||
});
|
});
|
||||||
|
|
||||||
},
|
},
|
||||||
@ -167,7 +177,11 @@ Page({
|
|||||||
// });
|
// });
|
||||||
},
|
},
|
||||||
|
|
||||||
onSaveInfo() {
|
async onSaveInfo() {
|
||||||
// console.log(this.data.personInfo);
|
// console.log(this.data.personInfo);
|
||||||
|
const res = await request('patient/set_personal_information', 'get', {
|
||||||
|
data: this.data.personInfo
|
||||||
|
})
|
||||||
|
wx.navigateBack()
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|||||||
@ -1,37 +1,28 @@
|
|||||||
<t-navbar left-arrow title="个人信息" />
|
<t-navbar left-arrow title="个人信息" />
|
||||||
<view class="info-edit">
|
<view class="info-edit">
|
||||||
<t-cell class="info-edit__cell" required title="姓名">
|
<t-cell class="info-edit__cell" required title="姓名">
|
||||||
<t-input bind:change="onNameChange" borderless placeholder="请输入姓名" slot="note" value="{{personInfo.name}}" />
|
<t-input bind:change="onNameChange" borderless placeholder="请输入姓名" slot="note" value="{{personInfo.username}}" />
|
||||||
</t-cell>
|
</t-cell>
|
||||||
<t-cell class="info-edit__cell" required title="性别">
|
<t-cell class="info-edit__cell" required title="性别">
|
||||||
<t-radio-group
|
<t-radio-group
|
||||||
bind:change="onGenderChange"
|
bind:change="onGenderChange"
|
||||||
borderless
|
borderless
|
||||||
defaultValue="{{personInfo.gender}}"
|
defaultValue="{{personInfo.sex}}"
|
||||||
options="{{genderOptions}}"
|
options="{{genderOptions}}"
|
||||||
slot="note"
|
slot="note"
|
||||||
t-class="info-edit__gender"
|
t-class="info-edit__gender"
|
||||||
value="{{personInfo.gender}}"
|
value="{{personInfo.sex}}"
|
||||||
/>
|
/>
|
||||||
</t-cell>
|
</t-cell>
|
||||||
<t-cell class="info-edit__cell" title="身份证号">
|
<t-cell class="info-edit__cell" title="身份证号">
|
||||||
<t-input bind:change="onNameChange" borderless placeholder="请输入身份证号" slot="note" value="{{personInfo.name}}" />
|
<t-input bind:change="onNameChange" borderless placeholder="请输入身份证号" slot="note" value="{{personInfo.id_number}}" />
|
||||||
</t-cell>
|
</t-cell>
|
||||||
<t-cell required arrow bind:click="showPicker" data-mode="birth" note="{{personInfo.birth || ''}}" title="出生日期" />
|
<t-cell required arrow bind:click="showPicker" data-mode="birth" note="{{personInfo.birthday || ''}}" title="出生日期" />
|
||||||
|
|
||||||
<t-cell class="info-edit__cell" required title="年龄">
|
<!-- <t-cell class="info-edit__cell" required title="年龄" note="{{personInfo.age}}">
|
||||||
<t-input bind:change="onNameChange" borderless placeholder="请输入年龄" slot="note" value="{{personInfo.name}}" />
|
|
||||||
<t-radio-group
|
</t-cell> -->
|
||||||
bind:change="onYearChange"
|
<t-cell required arrow bind:click="showPicker" data-mode="operative" note="{{personInfo.operative_date || ''}}" title="胆道闭锁手术时间" />
|
||||||
borderless
|
|
||||||
defaultValue="{{personInfo.yearType}}"
|
|
||||||
options="{{yearOptions}}"
|
|
||||||
slot="note"
|
|
||||||
t-class="info-edit__gender"
|
|
||||||
value="{{personInfo.yearType}}"
|
|
||||||
/>
|
|
||||||
</t-cell>
|
|
||||||
<t-cell required arrow bind:click="showPicker" data-mode="birth" note="{{personInfo.birth || ''}}" title="胆道闭锁手术时间" />
|
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
@ -46,7 +37,7 @@
|
|||||||
cancelBtn="取消"
|
cancelBtn="取消"
|
||||||
confirmBtn="确认"
|
confirmBtn="确认"
|
||||||
data-mode="birth"
|
data-mode="birth"
|
||||||
defaultValue="{{personInfo.birth}}"
|
defaultValue="{{defaultTime}}"
|
||||||
end="{{birthEnd}}"
|
end="{{birthEnd}}"
|
||||||
filter="{{birthFilter}}"
|
filter="{{birthFilter}}"
|
||||||
format="YYYY-MM-DD"
|
format="YYYY-MM-DD"
|
||||||
@ -54,7 +45,7 @@
|
|||||||
popup-props="{{ { usingCustomNavbar: true } }}"
|
popup-props="{{ { usingCustomNavbar: true } }}"
|
||||||
start="{{birthStart}}"
|
start="{{birthStart}}"
|
||||||
title="选择生日"
|
title="选择生日"
|
||||||
value="{{personInfo.birth}}"
|
value="{{newTime}}"
|
||||||
visible="{{birthVisible}}"
|
visible="{{birthVisible}}"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user