|
|
|
|
@ -1,9 +1,9 @@
|
|
|
|
|
import Taro from "@tarojs/taro";
|
|
|
|
|
import classnames from "classnames";
|
|
|
|
|
import { Component, PropsWithChildren, useEffect, useState } from "react";
|
|
|
|
|
import { Progress } from "@antmjs/vantui";
|
|
|
|
|
import { Progress , Tab, Tabs, Dialog, Popup } from "@antmjs/vantui";
|
|
|
|
|
import { showModal } from "@/utils/traoAPI";
|
|
|
|
|
import { Tab, Tabs, Dialog, Popup } from "@antmjs/vantui";
|
|
|
|
|
|
|
|
|
|
import {
|
|
|
|
|
Block,
|
|
|
|
|
View,
|
|
|
|
|
@ -13,11 +13,11 @@ import {
|
|
|
|
|
Button,
|
|
|
|
|
Textarea,
|
|
|
|
|
} from "@tarojs/components";
|
|
|
|
|
import { date, getdates, previewImage } from "@/utils/util";
|
|
|
|
|
import { date, getdates, previewImage } from "../../../utils/util";
|
|
|
|
|
|
|
|
|
|
/** 自定义组件 **/
|
|
|
|
|
import Navbar from "@/components/navbar/navbar";
|
|
|
|
|
import { InstrumentInfo } from "@/utils/Interface";
|
|
|
|
|
import Navbar from "../../../components/navbar/navbar";
|
|
|
|
|
import { InstrumentInfo } from "../../../utils/Interface";
|
|
|
|
|
|
|
|
|
|
/** 自定义组件 **/
|
|
|
|
|
import "./face_report.less";
|
|
|
|
|
@ -298,18 +298,18 @@ export default class Index extends Component<any, any> {
|
|
|
|
|
} = this.state;
|
|
|
|
|
return (
|
|
|
|
|
<Block>
|
|
|
|
|
<Navbar isBack titleSlot="护理报告"></Navbar>
|
|
|
|
|
<View className="statistic m-x-30 flex aitems">
|
|
|
|
|
<View className="statistic_item">
|
|
|
|
|
<View className="statistic_title">
|
|
|
|
|
<Navbar isBack titleSlot='护理报告'></Navbar>
|
|
|
|
|
<View className='statistic m-x-30 flex aitems'>
|
|
|
|
|
<View className='statistic_item'>
|
|
|
|
|
<View className='statistic_title'>
|
|
|
|
|
<text>{statistics.nursingNum}</text>
|
|
|
|
|
<text className="num">天</text>
|
|
|
|
|
<text className='num'>天</text>
|
|
|
|
|
</View>
|
|
|
|
|
<View className="statistic_desc">本月护理天数</View>
|
|
|
|
|
<View className='statistic_desc'>本月护理天数</View>
|
|
|
|
|
</View>
|
|
|
|
|
<View className="statistic_item">
|
|
|
|
|
<View className="statistic_title">{statistics.nursingTime}</View>
|
|
|
|
|
<View className="statistic_desc">本月护理时间</View>
|
|
|
|
|
<View className='statistic_item'>
|
|
|
|
|
<View className='statistic_title'>{statistics.nursingTime}</View>
|
|
|
|
|
<View className='statistic_desc'>本月护理时间</View>
|
|
|
|
|
</View>
|
|
|
|
|
{/* </block> */}
|
|
|
|
|
</View>
|
|
|
|
|
@ -325,23 +325,23 @@ export default class Index extends Component<any, any> {
|
|
|
|
|
{recordData.online == 1 ? "在线" : "离线"}
|
|
|
|
|
</View>
|
|
|
|
|
</View>
|
|
|
|
|
<View className="products_middle flex">
|
|
|
|
|
<View className='products_middle flex'>
|
|
|
|
|
<Image
|
|
|
|
|
className="cover"
|
|
|
|
|
className='cover'
|
|
|
|
|
src={recordData.modeImage}
|
|
|
|
|
mode="aspectFill"
|
|
|
|
|
mode='aspectFill'
|
|
|
|
|
></Image>
|
|
|
|
|
<View className="content">
|
|
|
|
|
<View className="content_top">
|
|
|
|
|
<View className="title">{recordData.instrumentName}</View>
|
|
|
|
|
<View className="desc_box">
|
|
|
|
|
<View className="desc">模式:{recordData.modeName}</View>
|
|
|
|
|
<View className="desc">
|
|
|
|
|
<View className='content'>
|
|
|
|
|
<View className='content_top'>
|
|
|
|
|
<View className='title'>{recordData.instrumentName}</View>
|
|
|
|
|
<View className='desc_box'>
|
|
|
|
|
<View className='desc'>模式:{recordData.modeName}</View>
|
|
|
|
|
<View className='desc'>
|
|
|
|
|
护理时间:{recordData.nursingTime}
|
|
|
|
|
</View>
|
|
|
|
|
</View>
|
|
|
|
|
</View>
|
|
|
|
|
<View className="progress">
|
|
|
|
|
<View className='progress'>
|
|
|
|
|
完成度:
|
|
|
|
|
<Progress
|
|
|
|
|
percentage={
|
|
|
|
|
@ -349,10 +349,10 @@ export default class Index extends Component<any, any> {
|
|
|
|
|
? 100
|
|
|
|
|
: recordData.completionPercentage * 100
|
|
|
|
|
}
|
|
|
|
|
strokeWidth="12"
|
|
|
|
|
color="linearGradient(to right, #eecda1, #ffe9c7) !important"
|
|
|
|
|
strokeWidth='12'
|
|
|
|
|
color='linearGradient(to right, #eecda1, #ffe9c7) !important'
|
|
|
|
|
/>
|
|
|
|
|
<View className="percent">
|
|
|
|
|
<View className='percent'>
|
|
|
|
|
{" "}
|
|
|
|
|
{recordData.completionPercentage * 100 > 100
|
|
|
|
|
? 100
|
|
|
|
|
@ -363,11 +363,11 @@ export default class Index extends Component<any, any> {
|
|
|
|
|
</View>
|
|
|
|
|
</View>
|
|
|
|
|
</View>
|
|
|
|
|
<View className="main_title">历史记录</View>
|
|
|
|
|
<View className='main_title'>历史记录</View>
|
|
|
|
|
{recordList.map((item) => (
|
|
|
|
|
<View className="products_item" style="border: none" key={item.id}>
|
|
|
|
|
<View className="products_top flex aitems">
|
|
|
|
|
<View className="add_time">{item.createTime}</View>
|
|
|
|
|
<View className='products_item' style='border: none' key={item.id}>
|
|
|
|
|
<View className='products_top flex aitems'>
|
|
|
|
|
<View className='add_time'>{item.createTime}</View>
|
|
|
|
|
<View
|
|
|
|
|
className={classnames("tag", {
|
|
|
|
|
tag_active: item.online === 2,
|
|
|
|
|
@ -376,21 +376,21 @@ export default class Index extends Component<any, any> {
|
|
|
|
|
{item.online == 1 ? "在线" : "离线"}
|
|
|
|
|
</View>
|
|
|
|
|
</View>
|
|
|
|
|
<View className="products_middle flex">
|
|
|
|
|
<View className='products_middle flex'>
|
|
|
|
|
<Image
|
|
|
|
|
className="cover"
|
|
|
|
|
className='cover'
|
|
|
|
|
src={item.modeImage}
|
|
|
|
|
mode="aspectFill"
|
|
|
|
|
mode='aspectFill'
|
|
|
|
|
></Image>
|
|
|
|
|
<View className="content">
|
|
|
|
|
<View className="content_top">
|
|
|
|
|
<View className="title">{item.instrumentName}</View>
|
|
|
|
|
<View className="desc_box">
|
|
|
|
|
<View className="desc">模式:{item.modeName}</View>
|
|
|
|
|
<View className="desc">护理时间:{item.nursingTime}</View>
|
|
|
|
|
<View className='content'>
|
|
|
|
|
<View className='content_top'>
|
|
|
|
|
<View className='title'>{item.instrumentName}</View>
|
|
|
|
|
<View className='desc_box'>
|
|
|
|
|
<View className='desc'>模式:{item.modeName}</View>
|
|
|
|
|
<View className='desc'>护理时间:{item.nursingTime}</View>
|
|
|
|
|
</View>
|
|
|
|
|
</View>
|
|
|
|
|
<View className="progress">
|
|
|
|
|
<View className='progress'>
|
|
|
|
|
完成度:
|
|
|
|
|
<Progress
|
|
|
|
|
percentage={
|
|
|
|
|
@ -398,10 +398,10 @@ export default class Index extends Component<any, any> {
|
|
|
|
|
? 100
|
|
|
|
|
: item.completionPercentage * 100
|
|
|
|
|
}
|
|
|
|
|
strokeWidth="12"
|
|
|
|
|
color="linearGradient(to right, #eecda1, #ffe9c7) !important"
|
|
|
|
|
strokeWidth='12'
|
|
|
|
|
color='linearGradient(to right, #eecda1, #ffe9c7) !important'
|
|
|
|
|
/>
|
|
|
|
|
<View className="percent">
|
|
|
|
|
<View className='percent'>
|
|
|
|
|
{" "}
|
|
|
|
|
{item.completionPercentage * 100 > 100
|
|
|
|
|
? 100
|
|
|
|
|
@ -415,75 +415,75 @@ export default class Index extends Component<any, any> {
|
|
|
|
|
))}
|
|
|
|
|
</View>
|
|
|
|
|
{reportShow ? (
|
|
|
|
|
<View className="footer flex aitems">
|
|
|
|
|
<View className="btn" onClick={this.setShow.bind(this, true)}>
|
|
|
|
|
<View className='footer flex aitems'>
|
|
|
|
|
<View className='btn' onClick={this.setShow.bind(this, true)}>
|
|
|
|
|
前往打卡
|
|
|
|
|
</View>
|
|
|
|
|
<View className="text flex aitems">
|
|
|
|
|
<View className='text flex aitems'>
|
|
|
|
|
<View onClick={this.GoIndex}>跳过</View>
|
|
|
|
|
<Image src={require("@/img/right.png")} mode="aspectFill"></Image>
|
|
|
|
|
<Image src={require("@/img/right.png")} mode='aspectFill'></Image>
|
|
|
|
|
</View>
|
|
|
|
|
</View>
|
|
|
|
|
) : null}
|
|
|
|
|
<Popup show={show} onClose={() => this.setState({ show: false })}>
|
|
|
|
|
<View className="popBox">
|
|
|
|
|
<View className='popBox'>
|
|
|
|
|
<Image
|
|
|
|
|
className="close_icon"
|
|
|
|
|
className='close_icon'
|
|
|
|
|
src={require("@/img/close.png")}
|
|
|
|
|
mode="widthFix"
|
|
|
|
|
mode='widthFix'
|
|
|
|
|
onClick={this.setShow.bind(this, false)}
|
|
|
|
|
></Image>
|
|
|
|
|
<View className="popTitle">今日打卡</View>
|
|
|
|
|
<View className="popSubtitle">
|
|
|
|
|
<View className='popTitle'>今日打卡</View>
|
|
|
|
|
<View className='popSubtitle'>
|
|
|
|
|
本月您已打卡
|
|
|
|
|
<View className="bold">{clockStatistics[0]?.clockNum}</View>{" "}
|
|
|
|
|
<View className='bold'>{clockStatistics[0]?.clockNum}</View>{" "}
|
|
|
|
|
天,超越
|
|
|
|
|
<View className="bold">
|
|
|
|
|
<View className='bold'>
|
|
|
|
|
{(clockStatistics[0]?.percentage * 100).toFixed(1)}%
|
|
|
|
|
</View>
|
|
|
|
|
花至用户
|
|
|
|
|
</View>
|
|
|
|
|
<View className="img_box">
|
|
|
|
|
<View className='img_box'>
|
|
|
|
|
{punchInInfo.clockImageList.map((item, index) => (
|
|
|
|
|
<View key={item} className="img">
|
|
|
|
|
<Image className="showImg" src={item} mode="widthFix"></Image>
|
|
|
|
|
<View key={item} className='img'>
|
|
|
|
|
<Image className='showImg' src={item} mode='widthFix'></Image>
|
|
|
|
|
<Image
|
|
|
|
|
className="closeImg"
|
|
|
|
|
className='closeImg'
|
|
|
|
|
src={require("@/img/close1.png")}
|
|
|
|
|
mode="widthFix"
|
|
|
|
|
mode='widthFix'
|
|
|
|
|
onClick={this.delImg.bind(this, index)}
|
|
|
|
|
></Image>
|
|
|
|
|
</View>
|
|
|
|
|
))}
|
|
|
|
|
{punchInInfo.clockImageList.length < 3 && (
|
|
|
|
|
<View
|
|
|
|
|
className="addBox"
|
|
|
|
|
className='addBox'
|
|
|
|
|
onClick={this.handleChooseImage.bind(this)}
|
|
|
|
|
>
|
|
|
|
|
<Image
|
|
|
|
|
className="showImg"
|
|
|
|
|
className='showImg'
|
|
|
|
|
src={require("@/img/clock_in_upload/add-image.png")}
|
|
|
|
|
mode="widthFix"
|
|
|
|
|
mode='widthFix'
|
|
|
|
|
></Image>
|
|
|
|
|
</View>
|
|
|
|
|
)}
|
|
|
|
|
</View>
|
|
|
|
|
<View className="info4">
|
|
|
|
|
<View className="content">
|
|
|
|
|
<View className='info4'>
|
|
|
|
|
<View className='content'>
|
|
|
|
|
<Textarea
|
|
|
|
|
placeholderStyle="color: #ccc; font-size: 26rpx;font-weight: 400;font-family: PingFang SC;"
|
|
|
|
|
placeholder="请记录一下今天的护理心得吧"
|
|
|
|
|
placeholderStyle='color: #ccc; font-size: 26rpx;font-weight: 400;font-family: PingFang SC;'
|
|
|
|
|
placeholder='请记录一下今天的护理心得吧'
|
|
|
|
|
maxlength={120}
|
|
|
|
|
onInput={this.handleTextareaInput.bind(this)}
|
|
|
|
|
value={punchInInfo.clockContent}
|
|
|
|
|
></Textarea>
|
|
|
|
|
</View>
|
|
|
|
|
<View className="tip">
|
|
|
|
|
<View className='tip'>
|
|
|
|
|
{"(" + (punchInInfo.clockContent.length || 0) + "/120)"}
|
|
|
|
|
</View>
|
|
|
|
|
</View>
|
|
|
|
|
<View className="popbtnbox flex aitems jcenter">
|
|
|
|
|
<View className="btn1" onClick={this.submit.bind(this)}>
|
|
|
|
|
<View className='popbtnbox flex aitems jcenter'>
|
|
|
|
|
<View className='btn1' onClick={this.submit.bind(this)}>
|
|
|
|
|
确认提交
|
|
|
|
|
</View>
|
|
|
|
|
</View>
|
|
|
|
|
|