Commit 8e7600b5 by 张立顺

Merge branch 'SAAS+V4.49.0-0121' of http://192.168.3.233:8090/saas_plus/dj-car-b…

…outique-work-wechat into SAAS+V4.49.0-0121
2 parents cd6304ad e7ab55b6
...@@ -46,7 +46,7 @@ Component({ ...@@ -46,7 +46,7 @@ Component({
// 背景色 // 背景色
background: { background: {
type: String, type: String,
value: '#FFFFFF' value: 'transparent'
} }
}, },
...@@ -106,7 +106,7 @@ Component({ ...@@ -106,7 +106,7 @@ Component({
formDataList[idx].noPadding = true formDataList[idx].noPadding = true
formDataList[idx].cellStyle = 'display: block !important; height: auto !important; padding: 0 40rpx !important;' formDataList[idx].cellStyle = 'display: block !important; height: auto !important; padding: 0 40rpx !important;'
formDataList[idx].labelStyle = 'width: 100% !important; padding: 24rpx 0 16rpx 0;' formDataList[idx].labelStyle = 'width: 100% !important; padding: 24rpx 0 16rpx 0;'
formDataList[idx].cellValueStyle = `box-sizing: border-box; width: 100% !important; border: ${item.type == 'input' ? '2rpx': '0'} solid #ececec; padding: ${item.type == 'input' ? '16rpx 24rpx !important': '0'};` formDataList[idx].cellValueStyle = `box-sizing: border-box; width: 100% !important; border: ${item.type == 'input' ? '2rpx': '0'} solid #ececec; padding: ${item.type == 'input' ? '16rpx 24rpx !important': '0'}; border-radius: ${item.type == 'input' ? '8rpx': '0'} ;`
formDataList[idx].customStyle = `padding: 0 0; display: flex; align-items: center; justify-content: space-between;` formDataList[idx].customStyle = `padding: 0 0; display: flex; align-items: center; justify-content: space-between;`
formDataList[idx].inputCustomStyle = `width: ${item.suffix ? 'calc(100% - 4rpx)' : '100%'} !important; flex-shrink: 0; padding: 0 0;` formDataList[idx].inputCustomStyle = `width: ${item.suffix ? 'calc(100% - 4rpx)' : '100%'} !important; flex-shrink: 0; padding: 0 0;`
} }
......
...@@ -61,7 +61,6 @@ ...@@ -61,7 +61,6 @@
wx:if="{{item.type == 'select'}}" wx:if="{{item.type == 'select'}}"
bindchange="handlePickerChange" bindchange="handlePickerChange"
data-target="{{item}}" data-target="{{item}}"
value="{{index}}"
disabled="{{item.disabled||disable}}" disabled="{{item.disabled||disable}}"
range="{{item.optionList}}" range="{{item.optionList}}"
range-key="{{item.optionLabel}}"> range-key="{{item.optionLabel}}">
......
...@@ -152,9 +152,6 @@ Component({ ...@@ -152,9 +152,6 @@ Component({
active: true, active: true,
value: '' value: ''
}, { }, {
name: '无需上传',
value: '0'
}, {
name: '待上传', name: '待上传',
value: '1' value: '1'
}, { }, {
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
left: 0; left: 0;
bottom: 0; bottom: 0;
right: 0; right: 0;
background-color: rgba(0, 0, 0, .6); background-color: rgba(0, 0, 0, .7);
} }
.text-center { .text-center {
......
...@@ -47,15 +47,19 @@ Component({ ...@@ -47,15 +47,19 @@ Component({
let [tempFiles] = res.tempFilePaths let [tempFiles] = res.tempFilePaths
let imgType = tempFiles.split('.')[1] let imgType = tempFiles.split('.')[1]
let type = imgType == 'unknown' ? 'jpg' : imgType let type = imgType == 'unknown' ? 'jpg' : imgType
_this.setData({
loadingFlag: true
})
wx.getFileSystemManager().readFile({ wx.getFileSystemManager().readFile({
filePath: tempFiles, //选择图片返回的相对路径 filePath: tempFiles, //选择图片返回的相对路径
encoding: 'base64', //编码格式 encoding: 'base64', //编码格式
success(_res) { success(_res) {
wx.$util.showLoading('上传中...')
api.uploadImg({ api.uploadImg({
file: `${type}@${_res.data}` file: `${type}@${_res.data}`
}).then(img => { }).then(img => {
wx.$util.hideLoading() _this.setData({
loadingFlag: false
})
let { code, data, message } = img let { code, data, message } = img
if (code == 0) { if (code == 0) {
fileList.push({url: data}) fileList.push({url: data})
...@@ -68,6 +72,11 @@ Component({ ...@@ -68,6 +72,11 @@ Component({
wx.$util.showToast(message) wx.$util.showToast(message)
} }
}) })
},
fail() {
_this.setData({
loadingFlag: false
})
} }
}) })
} }
...@@ -97,16 +106,20 @@ Component({ ...@@ -97,16 +106,20 @@ Component({
let fileType = fileName.split('.').pop() // 获取文件扩展名 let fileType = fileName.split('.').pop() // 获取文件扩展名
// 读取文件 // 读取文件
if (fileType != 'pdf') return wx.$util.showToast('只可上传pdf类型文件') if (fileType != 'pdf') return wx.$util.showToast('只可上传pdf类型文件')
_this.setData({
loadingFlag: true
})
wx.getFileSystemManager().readFile({ wx.getFileSystemManager().readFile({
filePath: tempFile.path, // 使用正确的路径 filePath: tempFile.path, // 使用正确的路径
encoding: 'base64', encoding: 'base64',
success(_res) { success(_res) {
wx.$util.showLoading('上传中...');
// 调用上传接口 // 调用上传接口
api.uploadPdfAPI({ api.uploadPdfAPI({
file: `${fileType}@${_res.data}` // 处理文件类型 file: `${fileType}@${_res.data}` // 处理文件类型
}).then(img => { }).then(img => {
wx.$util.hideLoading(); _this.setData({
loadingFlag: false
})
let { code, data, message } = img; let { code, data, message } = img;
if (code == 0) { if (code == 0) {
...@@ -122,7 +135,9 @@ Component({ ...@@ -122,7 +135,9 @@ Component({
}); });
}, },
fail(err) { fail(err) {
wx.$util.hideLoading(); _this.setData({
loadingFlag: false
})
console.error('读取文件失败', err); console.error('读取文件失败', err);
} }
}); });
......
{ {
"component": true, "component": true,
"usingComponents": { "usingComponents": {
"popup": "../Popup/Popup" "popup": "../Popup/Popup",
"van-loading": "@vant/weapp/loading/index"
} }
} }
\ No newline at end of file \ No newline at end of file
...@@ -102,3 +102,9 @@ ...@@ -102,3 +102,9 @@
border-bottom: var(--fontSize1) solid #EBEDF0; border-bottom: var(--fontSize1) solid #EBEDF0;
} }
} }
.loading-box{
background-color: rgba(0, 0, 0, 0.7);
.van-loading__text{
color: #FFFFFF !important;
}
}
\ No newline at end of file \ No newline at end of file
<!--packageEquity/pages/carQuotation/components/zyPayPopup/zyPayPopup.wxml--> <!--packageEquity/pages/carQuotation/components/zyPayPopup/zyPayPopup.wxml-->
<glsx-privacy appletName="生意助手员工版" bind:agreeClick="agreeClick" bind:disagreeClick="disagreeClick"></glsx-privacy> <glsx-privacy appletName="生意助手员工版" bind:agreeClick="agreeClick" bind:disagreeClick="disagreeClick"></glsx-privacy>
<block wx:if="{{!showChangeFileType}}"> <block wx:if="{{!showChangeFileType && !loadingFlag}}">
<popup <popup
title="{{'上传延保协议'}}" title="{{'上传延保协议'}}"
show="{{show}}" show="{{show}}"
...@@ -39,7 +39,7 @@ ...@@ -39,7 +39,7 @@
</view> </view>
</popup> </popup>
</block> </block>
<block wx:else> <block wx:if="{{showChangeFileType && !loadingFlag}}">
<van-popup <van-popup
class="file-type-popup" class="file-type-popup"
show="{{show}}" show="{{show}}"
...@@ -54,4 +54,9 @@ ...@@ -54,4 +54,9 @@
</view> </view>
</van-popup> </van-popup>
</block> </block>
<block wx:if="{{loadingFlag}}">
<van-popup show="{{show}}" close-on-click-overlay="{{false}}" >
<van-loading custom-class="loading-box" color="#FFFFFF" type="spinner" size="45px" vertical>上传中</van-loading>
</van-popup>
</block>
...@@ -308,7 +308,7 @@ Page({ ...@@ -308,7 +308,7 @@ Page({
async handleSecondConfirm(e) { async handleSecondConfirm(e) {
// debugger // debugger
let { orderInfo, outTradeNo, confirmStatus, userInfo } = this.data; let { orderInfo, outTradeNo, confirmStatus, userInfo, carBrandList } = this.data;
let staffCheck = await this.staffDailyReportMerchantValid(userInfo); let staffCheck = await this.staffDailyReportMerchantValid(userInfo);
if (staffCheck) return false;; if (staffCheck) return false;;
...@@ -396,8 +396,18 @@ Page({ ...@@ -396,8 +396,18 @@ Page({
} else { } else {
console.log(message); console.log(message);
wx.hideLoading(); wx.hideLoading();
// 将延保协议弹窗关闭 清空延保协议上传内容,支付凭证内容清空
let owner = this.getOwnerInfo();
if (orderInfo.payType == 2 && carBrandList?.includes(owner?.carChildsBrandId)) {
this.setData({ this.setData({
confirmStatus: false, showZyPopup: false,
['orderInfo.zyPayUrl']: '',
['orderInfo.transactionNo']: '',
['orderInfo.paymentDocList']: []
})
}
this.setData({
confirmStatus: false
}); });
wx.$util.showToast(message || "报价失败"); wx.$util.showToast(message || "报价失败");
} }
...@@ -485,7 +495,7 @@ Page({ ...@@ -485,7 +495,7 @@ Page({
try { try {
return new Promise(async (resolve, reject) => { return new Promise(async (resolve, reject) => {
// 当延保协议弹窗点击稍后补录会传值detail:cancel, 提交表单时不会重复弹出延保协议弹出 // 当延保协议弹窗点击稍后补录会传值detail:cancel, 提交表单时不会重复弹出延保协议弹出
if (orderInfo.payType == 2 && carBrandList?.includes(orderInfo?.owner?.carChildsBrandId) && detail != 'cancel' && !orderInfo?.zyPayUrl) { if (check && orderInfo.payType == 2 && carBrandList?.includes(orderInfo?.owner?.carChildsBrandId) && detail != 'cancel' && !orderInfo?.zyPayUrl) {
wx.hideLoading() wx.hideLoading()
this.setData({ this.setData({
showPopup: false showPopup: false
......
...@@ -90,7 +90,7 @@ ...@@ -90,7 +90,7 @@
</block> </block>
<view class="header-status"> <view class="header-status">
<!-- 待上传延保协议且是已支付的订单 --> <!-- 待上传延保协议且是已支付的订单 -->
<block wx:if="{{item.zyPayStatus == 1 && item.orderStatus == 3}}"> <block wx:if="{{item.zyPayStatus == 1 && (item.orderStatus == 3 || item.orderStatus == 4)}}">
<view class="default-txt">待上传</view> <view class="default-txt">待上传</view>
</block> </block>
<block wx:else> <block wx:else>
...@@ -193,12 +193,11 @@ ...@@ -193,12 +193,11 @@
<view class="item-footer"> <view class="item-footer">
<!-- 超管isSuper/商户类型 userType 1账号不可操作 --> <!-- 超管isSuper/商户类型 userType 1账号不可操作 -->
<block wx:if="{{ !userInfo.isSuper && userInfo.userType == 2||staffUuid }}"> <block wx:if="{{ !userInfo.isSuper && userInfo.userType == 2||staffUuid }}">
<block wx:if="{{ item.zyPayStatus == 1 && item.orderStatus == 3 }}"> <block wx:if="{{ item.zyPayStatus == 1 && (item.orderStatus == 3 || item.orderStatus == 4) }}">
<view class="btn_class"> <view class="btn_class">
<block wx:if="{{ item.orderStatus != '0' }}"> <block wx:if="{{ item.orderStatus != '0' }}">
<view class="order-btn default-btn padding_20" bindtap="jumpReception" data-item="{{ item }}">接待记录</view> <view class="order-btn default-btn padding_20" bindtap="jumpReception" data-item="{{ item }}">接待记录</view>
</block> </block>
<view wx:if="{{ item.equityGoodsFlag == '1' }}" class="order-btn default-btn padding_20" bindtap="handleClickBtn" data-target="{{ item }}">客户签名</view>
<view class="order-btn" bindtap="handleClickBtn" data-target="{{ item }}" data-type="upload">上传协议</view> <view class="order-btn" bindtap="handleClickBtn" data-target="{{ item }}" data-type="upload">上传协议</view>
</view> </view>
</block> </block>
......
...@@ -25,6 +25,7 @@ Component({ ...@@ -25,6 +25,7 @@ Component({
yqMerchartBox: false, yqMerchartBox: false,
cellHeight:false, cellHeight:false,
cellStyle:"min-height:52px", cellStyle:"min-height:52px",
cellBoxStyle:' border-radius: 0 0 16rpx 16rpx',
requiredList: [], requiredList: [],
yqMerchartList: [], yqMerchartList: [],
staffObj: { staffObj: {
......
...@@ -61,3 +61,4 @@ ...@@ -61,3 +61,4 @@
display: block; display: block;
margin:0 auto; margin:0 auto;
} }
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
<view class="between">{{staffObj.merchantName}}{{staffObj.merchantId}}</view> <view class="between">{{staffObj.merchantName}}{{staffObj.merchantId}}</view>
</block> </block>
</gl-cell> </gl-cell>
<gl-cell valueAlign="right" label="关联账号" required cellHeight="{{cellHeight}}" cellStyle="{{cellStyle}}" requiredAfter labelWidth="var(--fontSize290)" haveArrow="{{yqMerchartList.length>1}}" bindclick="showPopup" data-show-name="yqMerchartBox" placeholder="点击选择" > <gl-cell valueAlign="right" label="关联账号" required cellHeight="{{cellHeight}}" cellBoxStyle="{{cellBoxStyle}}" cellStyle="{{cellStyle}}" requiredAfter labelWidth="var(--fontSize290)" haveArrow="{{yqMerchartList.length>1}}" bindclick="showPopup" data-show-name="yqMerchartBox" placeholder="点击选择" >
<block wx:if="{{ staffObj.yqMerchantName }}"> <block wx:if="{{ staffObj.yqMerchantName }}">
<view class="between">{{staffObj.yqMerchantName}}{{staffObj.yqMerchantId}}</view> <view class="between">{{staffObj.yqMerchantName}}{{staffObj.yqMerchantId}}</view>
</block> </block>
......
...@@ -45,7 +45,8 @@ Page({ ...@@ -45,7 +45,8 @@ Page({
attendingStaff: {} attendingStaff: {}
}, },
isChangeTab: false, isChangeTab: false,
isConfirm: false isConfirm: false,
tabChange: true
}, },
/** /**
...@@ -318,7 +319,12 @@ Page({ ...@@ -318,7 +319,12 @@ Page({
key key
} = e.currentTarget.dataset } = e.currentTarget.dataset
this.setData({ this.setData({
tabActive: key tabActive: key,
tabChange: false
}, () => {
this.setData({
tabChange: true
})
}) })
}, },
...@@ -504,7 +510,7 @@ Page({ ...@@ -504,7 +510,7 @@ Page({
secondConfirm(params) { secondConfirm(params) {
let that = this let that = this
wx.showModal({ wx.showModal({
title: "二次确认提示", title: "确认提示",
content: "日报提交后将无法二次修改并将触发群消息推送,是否确认提交?", content: "日报提交后将无法二次修改并将触发群消息推送,是否确认提交?",
// showCancel: false, // showCancel: false,
cancelText: '取消', // '取消 cancelText: '取消', // '取消
...@@ -517,7 +523,7 @@ Page({ ...@@ -517,7 +523,7 @@ Page({
}) })
if (res.confirm) { if (res.confirm) {
api.saveTempReport(params).then(res => { api.saveTempReport(params).then(res => {
if (res.code == '0') { if (res.code == '0' || res.code == '-3') {
that.getRecordDetail() that.getRecordDetail()
} }
wx.$util.showToast(res.code == '0' ? '提交成功' : res.message) wx.$util.showToast(res.code == '0' ? '提交成功' : res.message)
......
...@@ -46,56 +46,47 @@ page { ...@@ -46,56 +46,47 @@ page {
.main { .main {
padding: 0 var(--fontSize20) var(--fontSize136); padding: 0 var(--fontSize20) var(--fontSize136);
// .mainheader {
// margin: var(--fontSize20) var(--fontSize10) 0;
// display: flex;
// justify-content: space-between;
// align-items: center;
// .navigation-title-text {
// margin-right: var(--fontSize10);
// font-family: PingFangSC-Regular;
// font-weight: 400;
// font-size: var(--fontSize28);
// color: #347BFF;
// }
// @media screen and (min-device-width: 600px) and (-webkit-min-device-pixel-ratio: 1) {
// .navigation-title-text {
// font-size: var(--fontSize23);
// }
// }
// }
// .title {
// font-family: PingFangSC-SNaNrpxibold;
// font-weight: 500;
// font-size: var(--fontSize28);
// color: #292D33;
// }
.tab-box { .tab-box {
width: 100%; width: 100%;
height: 88rpx; height: var(--fontSize88);
line-height: 88rpx; line-height: var(--fontSize88);
display: flex; display: flex;
white-space: nowrap; white-space: nowrap;
box-sizing: border-box;
width: 100%;
font-size: 0;
.tab-item { .tab-item {
color: #5a5e66; color: #5a5e66;
font-size: 28rpx; font-weight: 600;
// margin-right: 64rpx; width: fit-content;
padding: 0 35rpx; min-width: var(--fontSize144);
height: 100%;
flex-shrink: 0;
font-size: var(--fontSize28);
text-align: center;
position: relative;
padding: 0 var(--fontSize10);
} }
.tab-item.active { .tab-item.active {
color: #347bff; color: #347bff;
border-bottom: 2rpx solid #347BFF; }
.tab-item.active::after {
position: absolute;
bottom: 0;
left: 50%;
transform: translateX(-50%);
width: 64rpx;
height: var(--fontSize4);
background-color: #347BFF;
content: '';
} }
} }
.cust-form-box { .cust-form-box {
box-sizing: border-box; box-sizing: border-box;
margin: 16rpx 20rpx; margin: 16rpx 0;
padding-bottom: 32rpx; padding-bottom: 32rpx;
background: #FFFFFF; background: #FFFFFF;
box-shadow: 0 4rpx 20rpx 0 #0000001a; box-shadow: 0 4rpx 20rpx 0 #0000001a;
...@@ -108,6 +99,7 @@ page { ...@@ -108,6 +99,7 @@ page {
border: 2rpx solid #ececec; border: 2rpx solid #ececec;
border-radius: 16rpx; border-radius: 16rpx;
margin-top: 16rpx; margin-top: 16rpx;
padding: 16rpx 24rpx !important;
} }
.van-field__control--textarea { .van-field__control--textarea {
min-height: var(--field-text-area-min-height,144rpx) !important; min-height: var(--field-text-area-min-height,144rpx) !important;
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
</scroll-view> </scroll-view>
<!-- 动态表单 --> <!-- 动态表单 -->
<view class="cust-form-box"> <view class="cust-form-box">
<gl-cust-form wx:if="{{tmlpObj}}" id="{{tabActive}}" formData="{{ tmlpFormData }}" disable="{{isDisable}}" dataAttrName="{{ dataAttrName }}" formDataList="{{ tmlpObj[tabActive] }}" bind:radioEvent="radioEvent"> <gl-cust-form wx:if="{{tmlpObj && tabChange}}" id="{{tabActive}}" formData="{{ tmlpFormData }}" disable="{{isDisable}}" dataAttrName="{{ dataAttrName }}" formDataList="{{ tmlpObj[tabActive] }}" bind:radioEvent="radioEvent">
<!-- 与会人员 --> <!-- 与会人员 -->
<view wx:if="{{tabActive == 'organizeTraining'}}" slot='attendingStaff' class="attendingStaff"> <view wx:if="{{tabActive == 'organizeTraining'}}" slot='attendingStaff' class="attendingStaff">
<view class="picker" bindtap="handleProblemPicker" data-name="attendingStaff" data-pname="organizeTraining"> <view class="picker" bindtap="handleProblemPicker" data-name="attendingStaff" data-pname="organizeTraining">
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!