Browse Source

病历接口联调

main
kola-web 4 months ago
parent
commit
f2b2e27396
  1. 6
      src/components/customRecord/index.ts
  2. 4
      src/components/uploadFile/index.ts
  3. BIN
      src/images/self.png
  4. 9
      src/module1/pages/casesDetail/index.scss
  5. 42
      src/module1/pages/casesDetail/index.ts
  6. 50
      src/module1/pages/casesDetail/index.wxml
  7. 2
      src/module1/pages/entryCases/index.ts
  8. 12
      src/module1/pages/entryCases/index.wxml
  9. 3
      src/pages/cases/index.json
  10. 14
      src/pages/cases/index.ts
  11. 6
      src/pages/cases/index.wxml

6
src/components/customRecord/index.ts

@ -144,12 +144,14 @@ Component({
success: (res) => { success: (res) => {
wx.hideLoading(); wx.hideLoading();
const data = JSON.parse(res.data); const data = JSON.parse(res.data);
const suffix = this.GetExtensionFileName(data.data.Url);
const expandJson = { const expandJson = {
fileId: "", fileId: "",
name: "文件", name: `病例相关文件.${suffix}`,
size: (item.size / 1024).toFixed(2), size: (item.size / 1024).toFixed(2),
fileUrl: data.data.Url, fileUrl: data.data.Url,
suffix: this.GetExtensionFileName(data.data.Url), suffix,
type: item.fileType, type: item.fileType,
imgUrl: "", imgUrl: "",
duration: 0, duration: 0,

4
src/components/uploadFile/index.ts

@ -148,10 +148,10 @@ Component({
const suffix = this.GetExtensionFileName(data.data.Url); const suffix = this.GetExtensionFileName(data.data.Url);
const expandJson = { const expandJson = {
fileId: "", fileId: "",
name: "文件", name: `病例相关文件.${suffix}`,
size: (item.size / 1024).toFixed(2), size: (item.size / 1024).toFixed(2),
fileUrl: data.data.Url, fileUrl: data.data.Url,
suffix: this.GetExtensionFileName(data.data.Url), suffix,
type: item.fileType, type: item.fileType,
imgUrl: "", imgUrl: "",
duration: 0, duration: 0,

BIN
src/images/self.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.3 KiB

9
src/module1/pages/casesDetail/index.scss

@ -331,7 +331,7 @@ page {
justify-content: space-between; justify-content: space-between;
.quality { .quality {
width: 136rpx; width: 136rpx;
height: 50rpx; height: 44rpx;
} }
.gather { .gather {
padding: 12rpx 32rpx; padding: 12rpx 32rpx;
@ -714,8 +714,8 @@ page {
.tip { .tip {
position: absolute; position: absolute;
top: -25rpx; top: -25rpx;
transform: translateY(-100%); transform: translate(-50%, -100%);
left: 0; left: 50%;
border-radius: 12rpx; border-radius: 12rpx;
width: 686rpx; width: 686rpx;
box-sizing: border-box; box-sizing: border-box;
@ -741,7 +741,8 @@ page {
&::after { &::after {
position: absolute; position: absolute;
bottom: -12rpx; bottom: -12rpx;
left: 20rpx; left: 50%;
transform: translateX(-50%);
content: ""; content: "";
width: 0; width: 0;
height: 0; height: 0;

42
src/module1/pages/casesDetail/index.ts

@ -40,11 +40,26 @@ Page({
} as any, } as any,
rejectReason: {}, rejectReason: {},
remark: "",
fold: false, fold: false,
}, },
onLoad(options) { onLoad(options) {
this.setData({ this.setData({
id: options.id, id: options.id,
beforeClose1: (e: any) => {
if (e === "confirm") {
if (!this.data.remark) {
wx.showToast({
title: "请输入驳回原因",
icon: "none",
});
return false;
}
this.handleRejectSubmit();
}
return true;
},
beforeClose2: (e: any) => { beforeClose2: (e: any) => {
if (e === "confirm") { if (e === "confirm") {
this.handleQualitySubmit(); this.handleQualitySubmit();
@ -452,6 +467,33 @@ Page({
}); });
}, },
handleReject() {
this.setData({
show1: true,
});
},
handleQuickRemark(e) {
const { value } = e.currentTarget.dataset;
this.setData({
remark: `${this.data.remark}${value}`,
});
},
handleRejectSubmit() {
const { id, remark } = this.data;
wx.ajax({
method: "POST",
url: "?r=takeda/case/reject-case",
data: {
caseId: id,
remark,
},
}).then(() => {
wx.reLaunch({
url: "/pages/cases/index",
});
});
},
handleFold() { handleFold() {
this.setData({ this.setData({
fold: !this.data.fold, fold: !this.data.fold,

50
src/module1/pages/casesDetail/index.wxml

@ -12,7 +12,7 @@
</view> </view>
<view class="fold" bind:tap="handleFold"> <view class="fold" bind:tap="handleFold">
{{fold ? '展开' : '收起'}} {{fold ? '展开' : '收起'}}
<image class="icon" src="{{imageUrl}}fold-{{fold ? 'down' :'up'}}.png?t={{Timestamp}}"></image> <image class="icon" src="{{imageUrl}}fold-{{fold ? 'down' :'top'}}.png?t={{Timestamp}}"></image>
</view> </view>
</view> </view>
<view class="li-row"> <view class="li-row">
@ -90,12 +90,12 @@
data-item="{{item}}" data-item="{{item}}"
src="{{imageUrl}}icon-eye.png?t={{Timestamp}}" src="{{imageUrl}}icon-eye.png?t={{Timestamp}}"
></image> ></image>
<image <!-- <image -->
bind:tap="handleDownloadFile" <!-- bind:tap="handleDownloadFile" -->
data-item="{{item}}" <!-- data-item="{{item}}" -->
class="icon" <!-- class="icon" -->
src="{{imageUrl}}icon-download.png?t={{Timestamp}}" <!-- src="{{imageUrl}}icon-download.png?t={{Timestamp}}" -->
></image> <!-- ></image> -->
</view> </view>
</view> </view>
</view> </view>
@ -104,9 +104,14 @@
</view> </view>
<view class="feedback-card" wx:for="{{detail.feedbackList}}" wx:key="index"> <view class="feedback-card" wx:for="{{detail.feedbackList}}" wx:key="index">
<view class="li-options"> <view class="li-options">
<image class="quality" src="{{imageUrl}}new.png?t={{Timestamp}}" mode="scaleToFill"></image>
<image <image
wx:if="{{item.canDel===1}}" wx:if="{{item.isSelf===1}}"
class="quality"
src="{{imageUrl}}self.png?t={{Timestamp}}"
mode="scaleToFill"
></image>
<image
wx:if="{{item.isSelf===1}}"
class="gather" class="gather"
src="{{imageUrl}}icon-gather.png?t={{Timestamp}}" src="{{imageUrl}}icon-gather.png?t={{Timestamp}}"
bind:tap="handleDelFeedBack" bind:tap="handleDelFeedBack"
@ -118,7 +123,7 @@
<view class="content">{{item.createTime}}</view> <view class="content">{{item.createTime}}</view>
<view class="fold" bind:tap="handleFeedBackFold" data-index="{{index}}"> <view class="fold" bind:tap="handleFeedBackFold" data-index="{{index}}">
{{item.fold ? '展开' : '收起'}} {{item.fold ? '展开' : '收起'}}
<image class="icon" src="{{imageUrl}}fold-{{item.fold ? 'down' :'up'}}.png?t={{Timestamp}}"></image> <image class="icon" src="{{imageUrl}}fold-{{item.fold ? 'down' :'top'}}.png?t={{Timestamp}}"></image>
</view> </view>
</view> </view>
<view class="user"> <view class="user">
@ -181,12 +186,12 @@
data-item="{{cItem}}" data-item="{{cItem}}"
src="{{imageUrl}}icon-eye.png?t={{Timestamp}}" src="{{imageUrl}}icon-eye.png?t={{Timestamp}}"
></image> ></image>
<image <!-- <image -->
bind:tap="handleDownloadFile" <!-- bind:tap="handleDownloadFile" -->
data-item="{{cItem}}" <!-- data-item="{{cItem}}" -->
class="icon" <!-- class="icon" -->
src="{{imageUrl}}icon-download.png?t={{Timestamp}}" <!-- src="{{imageUrl}}icon-download.png?t={{Timestamp}}" -->
></image> <!-- ></image> -->
</view> </view>
</view> </view>
</view> </view>
@ -227,7 +232,7 @@
</view> </view>
</view> </view>
</view> </view>
<view class="footer"> <view class="footer" wx:if="{{showMoreAuth > 0 || auth.canFeedback}}">
<view class="wrap {{!auth.canFeedback && 'all-wrap'}}" wx:if="{{showMoreAuth>0}}"> <view class="wrap {{!auth.canFeedback && 'all-wrap'}}" wx:if="{{showMoreAuth>0}}">
<view class="w-item" wx:if="{{more}}" bind:tap="handleToggleMore"> <view class="w-item" wx:if="{{more}}" bind:tap="handleToggleMore">
<image class="icon" src="{{imageUrl}}case-detail-footer-icon3.png?t={{Timestamp}}"></image> <image class="icon" src="{{imageUrl}}case-detail-footer-icon3.png?t={{Timestamp}}"></image>
@ -279,7 +284,7 @@
</view> </view>
</view> </view>
</view> </view>
<view class="w-item" wx:if="{{ auth.canReject }}"> <view class="w-item" wx:if="{{ auth.canReject }}" bind:tap="handleReject">
<image class="icon" src="{{imageUrl}}case-detail-footer-icon1.png?t={{Timestamp}}"></image> <image class="icon" src="{{imageUrl}}case-detail-footer-icon1.png?t={{Timestamp}}"></image>
<view class="name">驳回</view> <view class="name">驳回</view>
</view> </view>
@ -343,18 +348,19 @@
title="" title=""
show="{{ show1 }}" show="{{ show1 }}"
show-cancel-button show-cancel-button
bind:close="onClose"
confirm-button-color="rgba(0, 180, 197, 1)" confirm-button-color="rgba(0, 180, 197, 1)"
beforeClose="{{beforeClose1}}"
> >
<view class="dialog1"> <view class="dialog1">
<view class="title">驳回病历后您无需批注此病历</view> <view class="title">驳回病历后您无需批注此病历</view>
<view class="select-wrap"> <view class="select-wrap">
<view class="select">专长不符</view> <view class="select" bind:tap="handleQuickRemark" data-value="专长不符">专长不符</view>
<view class="select">资料待补充</view> <view class="select" bind:tap="handleQuickRemark" data-value="资料待补充">资料待补充</view>
<view class="select">重复病历</view> <view class="select" bind:tap="handleQuickRemark" data-value="重复病历">重复病历</view>
</view> </view>
<textarea <textarea
class="remark" class="remark"
model:value="{{remark}}"
placeholder="请输入驳回原因" placeholder="请输入驳回原因"
placeholder-style="color:rgba(205, 205, 205, 1);" placeholder-style="color:rgba(205, 205, 205, 1);"
auto-height auto-height

2
src/module1/pages/entryCases/index.ts

@ -51,7 +51,7 @@ Page({
description: res.description, description: res.description,
audios: res.caseAudios, audios: res.caseAudios,
files: res.caseFiles, files: res.caseFiles,
deptId: res.deptId, deptId: res.caseDeptId[0] || '',
labelIds: res.caseLabels.map((item) => item.labelId), labelIds: res.caseLabels.map((item) => item.labelId),
}); });
}); });

12
src/module1/pages/entryCases/index.wxml

@ -84,12 +84,12 @@
data-index="{{index}}" data-index="{{index}}"
src="{{imageUrl}}icon-eye.png?t={{Timestamp}}" src="{{imageUrl}}icon-eye.png?t={{Timestamp}}"
></image> ></image>
<image <!-- <image -->
bind:tap="handleDownloadFile" <!-- bind:tap="handleDownloadFile" -->
data-index="{{index}}" <!-- data-index="{{index}}" -->
class="icon" <!-- class="icon" -->
src="{{imageUrl}}icon-download.png?t={{Timestamp}}" <!-- src="{{imageUrl}}icon-download.png?t={{Timestamp}}" -->
></image> <!-- ></image> -->
</view> </view>
</view> </view>
</view> </view>

3
src/pages/cases/index.json

@ -5,6 +5,7 @@
"van-icon": "@vant/weapp/icon/index", "van-icon": "@vant/weapp/icon/index",
"van-popup": "@vant/weapp/popup/index", "van-popup": "@vant/weapp/popup/index",
"pagination": "/components/pagination/index", "pagination": "/components/pagination/index",
"van-cascader": "@vant/weapp/cascader/index" "van-cascader": "@vant/weapp/cascader/index",
"van-dialog": "@vant/weapp/dialog/index"
} }
} }

14
src/pages/cases/index.ts

@ -1,3 +1,4 @@
import Dialog from "@vant/weapp/dialog/dialog";
const app = getApp<IAppOption>(); const app = getApp<IAppOption>();
Page({ Page({
@ -385,6 +386,19 @@ Page({
}, },
}); });
}, },
handleQuestion(e) {
const { index } = e.currentTarget.dataset;
const message = {
1: "",
2: "",
}[index];
Dialog.confirm({
showCancelButton: false,
confirmButtonText: "知道了",
message,
});
},
}); });
export {}; export {};

6
src/pages/cases/index.wxml

@ -5,11 +5,11 @@
<view class="nav {{nav==='0' && 'active'}}" bind:tap="handleNav" data-nav="0">我的病历</view> <view class="nav {{nav==='0' && 'active'}}" bind:tap="handleNav" data-nav="0">我的病历</view>
<view class="nav {{nav==='1' && 'active'}}" bind:tap="handleNav" data-nav="1"> <view class="nav {{nav==='1' && 'active'}}" bind:tap="handleNav" data-nav="1">
公开病历 公开病历
<van-icon name="question" color="rgba(224, 224, 224, 1)" /> <van-icon name="question" catch:tap="handleQuestion" data-index="1" color="rgba(224, 224, 224, 1)" />
</view> </view>
<view class="nav {{nav==='2' && 'active'}}" bind:tap="handleNav" data-nav="2"> <view class="nav {{nav==='2' && 'active'}}" bind:tap="handleNav" data-nav="2">
优质病历 优质病历
<van-icon name="question" color="rgba(224, 224, 224, 1)" /> <van-icon name="question" catch:tap="handleQuestion" data-index="2" color="rgba(224, 224, 224, 1)" />
</view> </view>
</view> </view>
<view class="search"> <view class="search">
@ -353,3 +353,5 @@
bind:finish="onFinish" bind:finish="onFinish"
/> />
</van-popup> </van-popup>
<van-dialog id="van-dialog" />

Loading…
Cancel
Save