Commit aff6093e by 李伟康

feat(audio): 添加录音复盘功能和优化界面组件

- 新增录音复盘列表页面和详情页面
- 创建录音项目组件用于展示复盘记录
- 集成录音标签配置和提交复盘功能
- 优化录音详情页布局和交互体验
- 添加标签选择弹窗组件支持多选
- 实现录音下载和分享功能
- 重构API接口支持录音复盘相关操作
- 调整页面样式适配新的复盘流程
1 parent 3f2c25cf
......@@ -35,7 +35,8 @@ module.exports = {
/**
* 接待复盘列表
*/
getAudioReviewList(data) {
getAudioReviewList(data = {}) {
data.pageNum = 10
return api.post('dj.api.supervisor.mini.page.audioReview', data, [], '/rop-dj-supervisor-mini/router')
},
/**
......@@ -57,4 +58,16 @@ module.exports = {
findConversationDetailByBatchId(data) {
return api.gscPost('check/api/findConversationDetailByBatchId', data)
},
/**
* 查询录音标签配置
*/
getAudioReviewTag(data = {}) {
return api.post('dj.api.supervisor.mini.list.audioReviewTag', data, [], '/rop-dj-supervisor-mini/router')
},
/**
* 提交录音复盘/标签记录
*/
submitAudioReview(data) {
return api.post('dj.api.supervisor.mini.submit.audioReview', data, [], '/rop-dj-supervisor-mini/router')
},
}
// packageIndex/pages/recordingReview/components/reviewItem/reviewItem.js
Component({
/**
* 组件的属性列表
*/
properties: {
record:Object,
showFooter:{
type:Boolean,
value:true
},
hasTag:Boolean
},
/**
* 组件的初始数据
*/
data: {
},
/**
* 组件的方法列表
*/
methods: {
reviewRecord() {
this.triggerEvent('reviewrecord', this.data.record);
}
}
})
\ No newline at end of file
{
"component": true,
"usingComponents": {}
}
\ No newline at end of file
/* packageIndex/pages/recordingReview/components/reviewItem/reviewItem.wxss */
.flex {
display: flex;
align-items: center;
}
.record-card {
background: #fff;
border-radius: 28rpx;
padding: 28rpx 32rpx;
position: relative;
.fixed-block {
position: absolute;
right: 24rpx;
top: 28rpx;
.user-role {
color: #222222;
font-size: 30rpx;
margin-right: 12rpx;
line-height: 44rpx;
}
.review-status {
padding: 6rpx 12rpx;
border-radius: 6rpx;
font-size: 24rpx;
&.reviewed {
background: #f6ffed;
color: #52c41a;
}
&.unreviewed {
background: #fff1f0;
color: #ff4d4f;
}
}
}
.card-header {
display: flex;
align-items: center;
margin-bottom: 4rpx;
.user-info {
flex: 1;
.user-name {
color: #222222;
font-size: 30rpx;
font-weight: 500;
max-width: 212rpx;
line-height: 44rpx;
}
.user-phone {
font-size: 26rpx;
color: #999;
flex-shrink: 0;
line-height: 40rpx;
margin-left: 12rpx;
}
}
}
.user-tag-box {
gap: 12rpx;
.tag {
padding: 0 8rpx;
border-radius: 4rpx;
color: #999999;
font-size: 22rpx;
border: 2rpx solid #e8ecf0;
}
}
.card-body {
.info-row {
display: flex;
align-items: center;
margin-top: 12rpx;
line-height: 40rpx;
.label {
color: #999999;
font-size: 28rpx;
width: 144rpx;
margin-right: 32rpx;
flex-shrink: 0;
}
.value {
font-size: 28rpx;
color: #222;
line-height: 40rpx;
}
}
.tag-box {
align-items: stretch;
.value {
flex-wrap: wrap;
gap: 12rpx;
.tag {
padding: 0 16rpx;
justify-content: center;
height: 52rpx;
border-radius: 12rpx;
background: #f7faff;
color: #000000;
font-size: 24rpx;
}
}
}
}
.card-footer {
display: flex;
justify-content: flex-end;
padding-top: 12rpx;
.action-btn {
display: flex;
align-items: center;
justify-content: center;
border-radius: 28rpx;
font-size: 26rpx;
font-weight: 500;
border: 2rpx solid #2C66F7;
color: #2C66F7;
background: #fff;
margin: 0;
width: 144rpx;
height: 60rpx;
padding: 0;
box-sizing: border-box;
}
.review-btn {
background: #2c66f71a;
border: none;
&::after {
display: none;
}
}
}
}
<view class="record-card">
<view class="fixed-block flex">
<view class="user-role">{{record.employeeName}}</view>
<view class="review-status {{record.reviewStatus == 1 ? 'reviewed' : 'unreviewed'}}">{{record.reviewStatus == 1 ? '已复盘' : '未复盘'}}</view>
</view>
<view class="card-header">
<view class="user-info flex">
<view class="user-name text-hide">{{record.customerName}}</view>
<view class="user-phone">{{record.phoneNumber}}</view>
</view>
</view>
<view class="user-tag-box flex">
<text class="tag" wx:if="{{record.carBrand}}">{{record.carBrand}}</text>
<text class="tag" wx:if="{{record.carModel}}">{{record.carModel}}</text>
<text class="tag" wx:if="{{record.customerType}}">{{record.customerType}}</text>
</view>
<view class="card-body">
<view class="info-row">
<text class="label">服务门店</text>
<text class="value">{{record.merchantName || '-'}}</text>
</view>
<view class="info-row">
<text class="label">质检评分</text>
<text class="value">{{record.qualityCheckScore != null ? record.qualityCheckScore : '-'}}</text>
</view>
<view class="info-row">
<text class="label">攻防评分</text>
<text class="value">{{record.attackScore != null ? record.attackScore : '-'}}</text>
</view>
<block wx:if="{{hasTag && record.tagList.length}}">
<view class="info-row tag-box">
<text class="label">录音标签</text>
<view class="value flex">
<block wx:for="{{record.tagList}}" wx:key="index">
<view class="tag flex">{{item}}</view>
</block>
</view>
</view>
</block>
</view>
<view class="card-footer" wx:if="{{showFooter}}">
<button class="action-btn {{record.reviewStatus == 0 ? 'review-btn' : ''}}" bindtap="reviewRecord">
{{record.actionBtn}}
</button>
</view>
</view>
\ No newline at end of file
......@@ -7,20 +7,20 @@ Page({
* 页面的初始数据
*/
data: {
dateGroups: []
records: [],
pageNum: 1
},
/**
* 生命周期函数--监听页面加载
*/
onLoad(options) {
this.getAudioReviewSummary()
this.getAudioReviewList()
},
getAudioReviewSummary() {
api.getAudioReviewSummary({
id: 16
id: this.options.id
}).then(({
data
}) => {
......@@ -36,30 +36,31 @@ Page({
})
},
getAudioReviewList() {
api.getAudioReviewList({
id: 16,
pageNum: 1,
pageSize: 10
}).then(({
data
}) => {
let {
async getAudioReviewList() {
const {
records,
pageNum
} = this.data, {
data: {
list,
total
} = data
}
} = await api.getAudioReviewList({
id: this.options.id,
pageNum
})
list && list.map(e => {
e.reviewText = e.reviewStatus == 1 ? '已复盘' : '未复盘'
e.actionBtn = e.reviewStatus == 1 ? '查看' : '录音复盘'
})
this.setData({
records: list
})
records: [...records, ...list],
total
})
},
reviewRecord(e){
const {record} = e.currentTarget.dataset
wx.$router._to('/packageIndex/pages/recordingReviewDetail/recordingReviewDetail', record, 'navigateTo')
reviewRecord({
detail
}) {
wx.$router._to('/packageIndex/pages/recordingReviewDetail/recordingReviewDetail', detail, 'navigateTo')
},
/**
* 生命周期函数--监听页面初次渲染完成
......@@ -72,7 +73,12 @@ Page({
* 生命周期函数--监听页面显示
*/
onShow() {
this.setData({
records: [],
pageNum: 1
})
this.getAudioReviewSummary()
this.getAudioReviewList()
},
/**
......@@ -100,13 +106,15 @@ Page({
* 页面上拉触底事件的处理函数
*/
onReachBottom() {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage() {
let {
pageNum,
total
} = this.data
wx.$util.onReachBottom({
pageNum,
total
}, () => {
this.getAudioReviewList()
})
}
})
{
"usingComponents": {},
"usingComponents": {
"review-item": "./components/reviewItem/reviewItem"
},
"navigationBarTitleText": "录音复盘",
"navigationBarBackgroundColor": "#F2F3F7",
"navigationBarTextStyle": "black"
......
......@@ -127,134 +127,5 @@ page {
}
}
.record-card {
background: #fff;
border-radius: 28rpx;
padding: 32rpx 28rpx;
position: relative;
.fixed-block {
position: absolute;
right: 24rpx;
top: 28rpx;
.user-role {
color: #222222;
font-size: 30rpx;
margin-right: 12rpx;
line-height: 44rpx;
}
.review-status {
padding: 6rpx 12rpx;
border-radius: 6rpx;
font-size: 24rpx;
&.reviewed {
background: #f6ffed;
color: #52c41a;
}
&.unreviewed {
background: #fff1f0;
color: #ff4d4f;
}
}
}
.card-header {
display: flex;
align-items: center;
margin-bottom: 4rpx;
.user-info {
flex: 1;
.user-name {
color: #222222;
font-size: 30rpx;
font-weight: 500;
max-width: 212rpx;
line-height: 44rpx;
}
.user-phone {
font-size: 26rpx;
color: #999;
flex-shrink: 0;
line-height: 40rpx;
margin-left: 12rpx;
}
}
}
.user-tag-box {
gap: 12rpx;
.tag {
padding: 0 8rpx;
border-radius: 4rpx;
color: #999999;
font-size: 22rpx;
border: 2rpx solid #e8ecf0;
}
}
.card-body {
.info-row {
display: flex;
align-items: center;
margin-top: 12rpx;
line-height: 40rpx;
.label {
color: #999999;
font-size: 28rpx;
width: 144rpx;
margin-right: 32rpx;
flex-shrink: 0;
}
.value {
font-size: 28rpx;
color: #222;
line-height: 40rpx;
}
}
}
.card-footer {
display: flex;
justify-content: flex-end;
padding-top: 12rpx;
.action-btn {
display: flex;
align-items: center;
justify-content: center;
border-radius: 28rpx;
font-size: 26rpx;
font-weight: 500;
border: 2rpx solid #2C66F7;
color: #2C66F7;
background: #fff;
margin: 0;
width: 144rpx;
height: 60rpx;
padding: 0;
box-sizing: border-box;
}
.review-btn{
background: #2c66f71a;
border: none;
&::after{
display: none;
}
}
}
}
}
......@@ -9,7 +9,7 @@
<view class="subtitle">请按以下要求提交实战效果录音复盘记录</view>
</view>
<!-- 日期分组列表 -->
<view class="date-group" >
<view class="date-group">
<view class="date-header">
<text class="date-text">{{summary.date}}</text>
<view class="stats">
......@@ -19,6 +19,7 @@
</view>
</view>
<!-- 录音记录卡片列表 -->
<block wx:if="{{records.length}}">
<block wx:for="{{records}}" wx:key="index" wx:for-item="record">
<view class="record-block">
<block wx:if="{{index != records.length - 1}}">
......@@ -29,45 +30,12 @@
{{index + 1}}
</view>
</view>
<view class="record-card">
<view class="fixed-block flex">
<view class="user-role">{{record.employeeName}}</view>
<view class="review-status {{record.reviewStatus == 1 ? 'reviewed' : 'unreviewed'}}">{{record.reviewText}}</view>
</view>
<view class="card-header">
<view class="user-info flex">
<view class="user-name text-hide">{{record.customerName}}</view>
<view class="user-phone">{{record.phoneNumber}}</view>
</view>
</view>
<view class="user-tag-box flex">
<text class="tag" v-if="{{record.carBrand}}">{{record.carBrand}}</text>
<text class="tag" v-if="{{record.carModel}}">{{record.carModel}}</text>
<text class="tag" v-if="{{record.customerType}}">{{record.customerType}}</text>
</view>
<view class="card-body">
<view class="info-row">
<text class="label">服务门店</text>
<text class="value">{{record.merchantName || '-'}}</text>
</view>
<view class="info-row">
<text class="label">质检评分</text>
<text class="value">{{record.qualityCheckScore != null ? record.qualityCheckScore : '-'}}</text>
</view>
<view class="info-row">
<text class="label">攻防评分</text>
<text class="value">{{record.attackScore != null ? record.attackScore : '-'}}</text>
</view>
</view>
<view class="card-footer">
<button class="action-btn {{record.reviewStatus == 0 ? 'review-btn' : ''}}" bindtap="reviewRecord" data-record="{{record}}">
{{record.actionBtn}}
</button>
</view>
</view>
<review-item record="{{record}}" bindreviewrecord="reviewRecord"></review-item>
</view>
</block>
</block>
<block wx:else>
<empty-data></empty-data>
</block>
</view>
</view>
\ No newline at end of file
......@@ -6,17 +6,17 @@
}
.view {
width: calc(100% - 56rpx);
left: 28rpx;
width: calc(100% - 48rpx);
left: 24rpx;
position: relative;
height: 100%;
background: #f5f8fc;
border-radius: 16rpx 16rpx 0 0;
border-radius: 32rpx;
.scroll-view {
height: 100%;
background-color: #fff;
animation: show-view .75s forwards;
border-radius: 16rpx 16rpx 0 0;
border-radius: 32rpx;
}
@keyframes show-view {
......
// packageReception/pages/detail/detail.js
import api from '~/api/index/index'
import dayjs from 'dayjs'
const IMG_URL = 'https://img02.glsx.com.cn/weapp/resource/miniprogram/regional-assistant/'
import {
getShortUrl
} from "~/api/crew/index"
Page({
......@@ -12,25 +17,69 @@ Page({
status: 'pause',
currentTime: '00:00', //当前音频的播放位置
isOperate: true,
IMG_URL,
reviewBtnText: '加载中...',
selectOptions: []
},
/**
* 生命周期函数--监听页面加载
*/
onLoad(options) {
let {
reviewTarget,
reviewStatus,
employeeName,
startTime
} = options
if (reviewTarget) options.tagList = reviewTarget.split(',')
this.setData({
record: options
record: options,
title: `${dayjs(startTime).format('M月D日')}${employeeName}接待`,
reviewBtnText: reviewStatus == 1 ? '查看复盘' : '提交复盘'
})
this.getAudioReviewTag()
this.setAudio()
this.getReceptionDetail()
this.setViewHeight()
},
setViewHeight() {
wx.$util.getViewInfo('.reception-wrap', ({
height
}) => {
let wrapHeight = `${height * 2}rpx`
wx.$util.getViewInfo('.footer', footer => {
let wrapHeight = `${((height || 0) + (footer.height || 0)) * 2}rpx`
this.setData({
receptionWrapStyle: `height:calc(100% - ${wrapHeight} - constant(safe-area-inset-bottom));height:calc(100% - ${wrapHeight} - env(safe-area-inset-bottom))`
receptionWrapStyle: `height:calc(100% - ${wrapHeight});`
})
})
})
},
async getAudioReviewTag() {
try {
const {
data
} = await api.getAudioReviewTag()
if (data && data.length) this.setData({
selectOptions: data.map(e => {
return {
name: e,
value: e
}
})
})
else throw false
} catch (error) {
this.setData({
tagLoadingComplete:true
})
console.log(error)
}
},
back() {
wx.navigateBack()
},
async getReceptionDetail() {
try {
......@@ -199,8 +248,44 @@ Page({
qualityRef() {
return this.selectComponent('#quality')
},
//屏幕是否常亮
setKeepScreenOn(keepScreenOn = false) {
wx.setKeepScreenOn({
keepScreenOn
})
},
async share(e) {
const {
record
} = this.data,
receptionStatus = {
1: '成交',
2: '战败',
3: '未知'
} [record.orderStatus], {
endTime,
totalDuration,
startTime,
merchantNo,
batchId,
merchantName
} = record
// 获取短链地址
const res = await getShortUrl({
merchantNo,
batchId,
receptionStartTime: startTime
})
if (res.code == '0') {
// 门店 - 接待开始时间 - 接待时长 - 员工标记的接待结果 - 接待录音mp3地址(更换成短链)
let text = [merchantName, wx.$util.tsFormatTime(startTime, 'Y年M月D日 h:m:s'), wx.$util.tsFormatTime(endTime, 'Y年M月D日 h:m:s'), this.format(totalDuration), receptionStatus, res.data].join(' - ')
wx.$util.setCopyData(text)
} else {
wx.$util.showToast('获取短链失败')
}
// wx.$util.showToast('复制成功')
},
format(seconds) {
seconds = Math.floor(seconds / 1000)
let formattedTime = ''
if (seconds < 60) return seconds + '秒'
else {
......@@ -213,12 +298,72 @@ Page({
return formattedTime
}
},
//屏幕是否常亮
setKeepScreenOn(keepScreenOn = false) {
wx.setKeepScreenOn({
keepScreenOn
// 下载录音
async download(e) {
let {
record
} = this.data
wx.showModal({
title: '温馨提示',
content: '如需下载录音,请复制下载地址后到手机浏览器中打开。',
confirmText: '复制地址',
confirmColor: '#2C66F7',
success(res) {
if (res.confirm) {
wx.setClipboardData({
data: record.fileUrl
})
}
}
})
},
openTag() {
const {
selectOptions,
record: {
reviewTarget
}
} = this.data
if (reviewTarget || !selectOptions.length) return
this.setData({
showSelectPopup: true
})
},
hideSelectPopup() {
this.setData({
showSelectPopup: false
})
},
async handlePopupConfirm(e) {
const {
values
} = e.detail, {
id
} = this.data.record
if (values && values.length) {
const {
data
} = await api.submitAudioReview({
id,
reviewTarget: values.join(',')
})
if (data) {
this.setData({
['record.tagList']: values
})
wx.$util.showToast('提交成功')
this.hideSelectPopup()
this.setViewHeight()
} else wx.$util.showToast('提交失败')
} else wx.$util.showToast('请选择标签')
},
reView(){
const {record} = this.data
wx.$router._to('/packageIndex/pages/submitRecordingReview/submitRecordingReview', record, 'navigateTo')
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
......
{
"usingComponents": {
"quality": "./components/quality/quality",
"dialogue":"./components/dialogue/dialogue"
"dialogue":"./components/dialogue/dialogue",
"review-item": "../recordingReview/components/reviewItem/reviewItem",
"select-popup": "/components/selectPopup/selectPopup"
},
"navigationStyle": "custom"
}
\ No newline at end of file
......@@ -70,73 +70,12 @@ page {
}
.customer-info-box {
height: 142rpx;
border-radius: 24rpx;
border-radius: 28rpx;
background: #ffffff;
margin: 0 32rpx;
padding: 24rpx;
margin: 0 24rpx;
// padding: 24rpx;
box-sizing: border-box;
position: relative;
.customer-icon {
width: 80rpx;
height: 80rpx;
margin-right: 16rpx;
}
.customer-info {
display: flex;
flex-direction: column;
height: 100%;
.customer-name {
color: #9d9fa3;
font-size: 24rpx;
.name {
color: #292d33;
font-size: 30rpx;
max-width: 360rpx;
font-weight: 500;
margin-right: 8rpx;
}
}
.customer-car {
margin-top: auto;
transform: translateY(-8rpx);
.customer-car-item {
margin-right: 12rpx;
padding: 0 8rpx;
height: 32rpx;
border-radius: 4rpx;
border: 2rpx solid #e8ecf0;
display: flex;
align-items: center;
color: #9d9fa3;
font-size: 22rpx;
box-sizing: border-box;
width: fit-content;
}
}
}
.customer-score {
position: absolute;
right: 24rpx;
bottom: 24rpx;
color: #292d33;
font-size: 24rpx;
font-weight: 500;
display: flex;
align-items: baseline;
.num {
font-size: 40rpx;
margin-right: 4rpx;
}
}
}
.reception-nav {
......@@ -165,7 +104,7 @@ page {
.active {
font-weight: 600;
color: #fff;
background: linear-gradient(135deg, #4f52ff 0%, #349bff 100%);
background: #2c66f7;
}
}
......@@ -221,3 +160,35 @@ page {
z-index: -1;
}
}
.footer {
position: fixed;
left: 0;
bottom: 0;
width: 100%;
box-sizing: border-box;
justify-content: space-between;
gap: 24rpx;
padding: 16rpx 32rpx calc(16rpx + var(--constantSafeAreaInsetBottom));
padding: 16rpx 32rpx calc(16rpx + var(--envSafeAreaInsetBottom));
background: #fff;
.btn {
justify-content: center;
height: 80rpx;
border-radius: 16rpx;
color: #2c66f7;
font-size: 32rpx;
font-weight: 500;
flex: 1;
background: #2c66f71a;
}
.full{
background: #2c66f7;
color: #fff;
}
.disabled{
background: #F4F5F7;
color: #ccc;
}
}
<navigation-bar bindnavbarReady="navbarReady" navStyle="background-color:transparent;" showBack>接待详情</navigation-bar>
<navigation-bar bindnavbarReady="navbarReady" navStyle="background-color:transparent;" showBack bindback="back">{{title||'加载中...'}}</navigation-bar>
<view class="layout" style="{{layoutStyle}}">
<view class="reception-wrap">
<view class="customer-info-box flex">
<!-- <image src="/assets/images/portrait.png" class="customer-icon" /> -->
<view class="customer-info">
<view class="customer-name flex">
<view class="name text-hide">{{record.customerName}}</view>
{{record.customerPhone}}
</view>
<view class="customer-car flex">
<block wx:if="{{record.carBrand}}">
<view class="customer-car-item">{{record.carBrand}}</view>
</block>
<block wx:if="{{record.carModel}}">
<view class="customer-car-item">{{record.carModel}}</view>
</block>
</view>
</view>
<view class="customer-score">
<view class="num">{{record.score}}</view>
分
</view>
<view class="customer-info-box">
<review-item record='{{record}}' showFooter="{{false}}" hasTag></review-item>
</view>
<view class="reception-nav">
<view class="reception-types">
......@@ -29,9 +11,11 @@
</block>
</view>
<view class="reception-operate">
<image class="img share" src="https://img02.glsx.com.cn/weapp/resource/miniprogram/supervisor-miniprogram/down-icon.png" bind:tap="download" mode=""/>
<image class="img share" src="{{IMG_URL}}share-icon.png" bind:tap="share" mode=""/>
<view class="audio-wrap" bind:tap="onHandle">
<!-- <image class="img" src="/assets/images/play.png" wx:if="{{status=='pause'||status=='ending'}}" />
<image class="img" src="/assets/images/stop.png" wx:else /> -->
<image class="img" src="{{IMG_URL}}play-icon.png" wx:if="{{status=='pause'||status=='ending'}}" />
<image class="img" src="{{IMG_URL}}stop-icon.png" wx:else />
<view class="time">{{currentTime}}</view>
</view>
</view>
......@@ -47,4 +31,10 @@
</view>
</block>
</view>
<view class="footer flex">
<view class="btn flex {{record.reviewTarget || !selectOptions.length?'disabled':''}}" bind:tap="openTag">{{selectOptions.length || tagLoadingComplete ? '添加标签':'加载中...'}}</view>
<view class="btn flex full" bindtap="reView">{{reviewBtnText}}</view>
</view>
</view>
<select-popup show="{{ showSelectPopup }}" options="{{ selectOptions }}" multiple values="{{ selectValues }}" bindconfirm="handlePopupConfirm" height="80%" title="标签选择" max="{{5}}" allowSearch bindcancel="hideSelectPopup"></select-popup>
\ No newline at end of file
// packageIndex/pages/submitRecordingReview/submitRecordingReview.js
import api from '~/api/index/index'
Page({
/**
* 页面的初始数据
*/
data: {
},
data: {},
/**
* 生命周期函数--监听页面加载
*/
onLoad(options) {
this.setData({
record: options
})
},
async handleSubmit() {
try {
const {
record: {
reviewContext,
id
}
} = this.data
if (reviewContext) {
wx.$util.showLoading('正在提交...')
const {
data,
message
} = await api.submitAudioReview({
id,
reviewContext
})
wx.hideLoading()
if (data) {
wx.$util.showToast('提交成功')
setTimeout(() => {
wx.$router.back(prevPage => {
prevPage.setData({
['record.reviewStatus']: 1,
reviewBtnText:'查看复盘'
})
})
}, 1e3);
} else wx.$util.showToast(message)
} else wx.$util.showToast('请完成所有必填项')
} catch (error) {
wx.$util.showToast(error)
}
},
handleBack() {
wx.navigateBack()
},
onTextareaInput(e) {
const {
value
} = e.detail
this.setData({
['record.reviewContext']: value
})
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
......
{
"usingComponents": {}
"usingComponents": {},
"navigationBarTitleText": "督导复盘",
"navigationBarBackgroundColor": "#F2F3F7",
"navigationBarTextStyle": "black"
}
\ No newline at end of file
/* packageIndex/pages/submitRecordingReview/submitRecordingReview.wxss */
page {
background: #F2F3F7;
}
.layout {
padding: 8rpx 20rpx;
.textarea-box{
border-radius: 24rpx;
background: #ffffff;
padding: 0 32rpx 28rpx;
}
}
// 页面标题
.page-title {
height: 84rpx;
.title-text {
color: #292d33;
font-size: 28rpx;
}
.required-mark {
color: #F24724;
margin-left: 8rpx;
}
}
// 输入框容器
.input-container {
background: #fff;
border-radius: 16rpx;
position: relative;
border: 2rpx solid #eff0f2;
padding: 24rpx 24rpx 52rpx;
.review-textarea {
height: 880rpx;
width: 100%;
font-size: 28rpx;
color: #222;
border: none;
outline: none;
}
.placeholder-style {
color: #999ea8;
}
.char-count {
position: absolute;
right: 26rpx;
bottom: 8rpx;
font-size: 28rpx;
color: #ccc;
line-height: 36rpx;
}
}
// 底部按钮组
.button-group {
display: flex;
flex-direction: column;
gap: 16rpx;
margin-top: 52rpx;
padding: 0 44rpx;
.flex{
justify-content: center;
}
.submit-btn {
width: 100%;
height: 88rpx;
background: #3772ff;
color: #fff;
font-size: 32rpx;
border-radius: 24rpx;
border: none;
&::after {
border: none;
}
}
.back-btn {
width: 100%;
height: 88rpx;
background: #fff;
color: #222;
font-size: 32rpx;
border-radius: 24rpx;
&::after {
border: none;
}
}
}
\ No newline at end of file
<!--packageIndex/pages/submitRecordingReview/submitRecordingReview.wxml-->
<text>packageIndex/pages/submitRecordingReview/submitRecordingReview.wxml</text>
\ No newline at end of file
<view class="layout">
<view class="textarea-box">
<!-- 页面标题 -->
<view class="page-title flex">
<text class="title-text">复盘填写</text>
<text class="required-mark">*</text>
</view>
<!-- 文本输入区域 -->
<view class="input-container">
<textarea class="review-textarea" disabled="{{record.reviewStatus == 1}}" placeholder="请输入" placeholder-class="placeholder-style" maxlength="500" bindinput="onTextareaInput" value="{{record.reviewContext}}" />
<view class="char-count">{{record.reviewContext.length}}/500</view>
</view>
</view>
<!-- 底部按钮组 -->
<view class="button-group">
<button wx:if="{{record && record.reviewStatus == 0}}" class="submit-btn flex" bindtap="handleSubmit">提交</button>
<button class="back-btn flex" bindtap="handleBack">返回</button>
</view>
</view>
\ No newline at end of file
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!