Commit a982b8ab by 张立顺

Merge branch 'dev_v4.17.0' into dev_v4.17.1

2 parents d17ca447 3aaa20c9
...@@ -84,10 +84,10 @@ module.exports = { ...@@ -84,10 +84,10 @@ module.exports = {
return api.post('dj.api.smartcarlife.config.list', data) return api.post('dj.api.smartcarlife.config.list', data)
}, },
// /** 获取指定商户指定日期范围的邀约统计 */ /** 获取指定商户指定日期范围的邀约统计 */
// getInviteDateList(data) { getInviteDateList(data) {
// return api.post('dj.api.smartcarlife.inviteStat.merchant.list', data) return api.post('dj.api.smartcarlife.inviteStat.merchant.list', data)
// }, },
/** 获取WebSocket地址 */ /** 获取WebSocket地址 */
getWsUrl() { getWsUrl() {
return api.post('dj.api.smartcarlife.getWsUrl') return api.post('dj.api.smartcarlife.getWsUrl')
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
* 2测试 * 2测试
* 3生产环境 * 3生产环境
*/ */
export let env = 2 export let env = 3
// 配置预发布的小程序aapId // 配置预发布的小程序aapId
// export const preReleaseAppId = 'wx24ebae5768e74138' // export const preReleaseAppId = 'wx24ebae5768e74138'
......
...@@ -207,12 +207,16 @@ ...@@ -207,12 +207,16 @@
.list .item { .list .item {
box-sizing: border-box; box-sizing: border-box;
background: #FFFFFF; background: #FFFFFF;
box-shadow: 0 6rpx 16rpx 0 #cdcdd159; box-shadow: 0 6rpx 16rpx 0 rgba(205, 205, 209, 0.5);
border-radius: 16rpx; border-radius: 16rpx;
/* padding: 20rpx 32rpx; */ /* padding: 20rpx 32rpx; */
margin: 0 6rpx 20rpx; margin: 0 6rpx 20rpx;
} }
.list .item:first-child {
margin-top: 6rpx;
}
.item .item-content { .item .item-content {
position: relative; position: relative;
padding: 0 32rpx; padding: 0 32rpx;
......
...@@ -11,7 +11,9 @@ Page({ ...@@ -11,7 +11,9 @@ Page({
certificateNo: '', certificateNo: '',
carVin: '', carVin: '',
seat: '5', seat: '5',
price: '' price: '',
confirmStatus: false,
saveStatus: false
}, },
// owner: { // owner: {
// owner: 'test2', // owner: 'test2',
...@@ -123,13 +125,18 @@ Page({ ...@@ -123,13 +125,18 @@ Page({
async handleSecondConfirm() { async handleSecondConfirm() {
// owner, orderInfo, // owner, orderInfo,
// 修改权益报价逻辑 // 修改权益报价逻辑
let { modifyEquityQuotation } = this.data let { modifyEquityQuotation, confirmStatus } = this.data
if (confirmStatus) return false
if (modifyEquityQuotation) { if (modifyEquityQuotation) {
return this.updateEquityPrice() return this.updateEquityPrice()
} }
// orderInfo.check = false // orderInfo.check = false
// orderInfo.owner = owner // orderInfo.owner = owner
// this.setData({ orderInfo }) // this.setData({ orderInfo })
wx.showLoading('报价中...')
this.setData({
confirmStatus: true
})
let result = await this.handleSecondConfirmCheck() let result = await this.handleSecondConfirmCheck()
let { code, data: id, message } = result let { code, data: id, message } = result
...@@ -137,14 +144,20 @@ Page({ ...@@ -137,14 +144,20 @@ Page({
if (id) { if (id) {
// 校验生成告知书是否成功 // 校验生成告知书是否成功
let status = await this.getQuotationGenerate(id) let status = await this.getQuotationGenerate(id)
wx.hideLoading()
this.setData({
confirmStatus: false
})
console.log('id', id) console.log('id', id)
status.code == 0 ? this.navigatorNext(id) : wx.$util.showToast(status.message || '报价失败') status.code == 0 ? this.navigatorNext(id) : wx.$util.showToast(status.message || '报价失败')
// let // let
// status && this.navigatorNext(id) // status && this.navigatorNext(id)
} else { } else {
console.log(message) console.log(message)
wx.hideLoading()
this.setData({
confirmStatus: false
})
wx.$util.showToast(message || '报价失败') wx.$util.showToast(message || '报价失败')
} }
...@@ -272,14 +285,22 @@ Page({ ...@@ -272,14 +285,22 @@ Page({
}, },
// 不需要检验 存草稿 // 不需要检验 存草稿
async handleEditSave() { async handleEditSave() {
let { owner, orderInfo, modifyEquityQuotation } = this.data let { owner, orderInfo, modifyEquityQuotation, saveStatus } = this.data
if (modifyEquityQuotation) { if (modifyEquityQuotation) {
return this.updateEquityPrice('saveEdit') return this.updateEquityPrice('saveEdit')
} }
if (saveStatus) return false
wx.showLoading('保存中...')
this.setData({
saveStatus: true
})
orderInfo.check = false orderInfo.check = false
orderInfo.owner = owner orderInfo.owner = owner
this.setData({ orderInfo }) this.setData({ orderInfo })
let id = await this.handleSecondConfirmCheck() let id = await this.handleSecondConfirmCheck()
this.setData({
saveStatus: false
})
console.log('id', id) console.log('id', id)
// this.navigatorNext() // this.navigatorNext()
// wx.$router.go('packageEquity.index') // wx.$router.go('packageEquity.index')
......
...@@ -34,15 +34,7 @@ ...@@ -34,15 +34,7 @@
<view class="search-box"> <view class="search-box">
<view class="search-input"> <view class="search-input">
<image src="/images/search.png" class="search-icon" /> <image src="/images/search.png" class="search-icon" />
<input <input type="text" placeholder="请输入客户名字搜索" class="input" confirm-type="search" value="{{customerName}}" placeholder-class="input-placeholder" bindinput="input" bindconfirm="search" />
type="text"
placeholder="请输入客户名字搜索"
class="input"
confirm-type="search"
value="{{customerName}}"
placeholder-class="input-placeholder"
bindinput="input"
bindconfirm="search" />
<block wx:if="{{customerName}}"> <block wx:if="{{customerName}}">
<image src="/images/clear.png" class="search-clear" bindtap="handleReset" /> <image src="/images/clear.png" class="search-clear" bindtap="handleReset" />
</block> </block>
...@@ -52,25 +44,15 @@ ...@@ -52,25 +44,15 @@
</view> </view>
<view class="total-box"> <view class="total-box">
{{tabIndex == 0 ? '总订单' : tabList[tabIndex]}} · {{total}} {{tabIndex == 0 ? '总订单' : tabList[tabIndex]}} · {{total}}
<text wx:if="{{tabIndex == 0}}" class="total-tips"> <view wx:if="{{tabIndex == 0}}" class="total-tips">
今日成功支付{{statisticsObj.todaySuccessPay || 0}}位,战败{{statisticsObj.todayFailurePay || 0}}位 今日成功支付{{statisticsObj.todaySuccessPay || 0}}位,战败{{statisticsObj.todayFailurePay || 0}}位
</text> </view>
</view> </view>
<view wx:if="{{flag}}" class="order-box"> <view wx:if="{{flag}}" class="order-box">
<scroll-view <scroll-view scroll-y enable-back-to-top refresher-enabled="{{true}}" bindrefresherrefresh="search" bindscrolltolower="onBottomRefresh" class="list" scroll-top="{{scrollTop}}" lower-threshold="400" refresher-threshold="104" refresher-triggered="{{triggered}}">
scroll-y
enable-back-to-top
refresher-enabled="{{true}}"
bindrefresherrefresh="search"
bindscrolltolower="onBottomRefresh"
class="list"
scroll-top="{{scrollTop}}"
lower-threshold="400"
refresher-threshold="104"
refresher-triggered="{{triggered}}">
<block wx:if="{{list.length > 0}}"> <block wx:if="{{list.length > 0}}">
<view wx:for="{{list}}" wx:key="index" class="item"> <view wx:for="{{list}}" wx:key="index" class="item">
<view class="itme-content"> <view class="item-content">
<view class="item-header"> <view class="item-header">
<view class="header-cust"> <view class="header-cust">
{{item.customerName}} {{item.customerName}}
...@@ -90,11 +72,7 @@ ...@@ -90,11 +72,7 @@
</view> </view>
<!-- 内容 --> <!-- 内容 -->
<view class="order-list"> <view class="order-list">
<block <block wx:for="{{orderObj}}" wx:key="sindex" wx:for-index="sindex" wx:for-item="i">
wx:for="{{orderObj}}"
wx:key="sindex"
wx:for-index="sindex"
wx:for-item="i">
<block wx:if="{{i.key == 'remark' || i.key == 'payTime' || i.key == 'createdTime'}}"> <block wx:if="{{i.key == 'remark' || i.key == 'payTime' || i.key == 'createdTime'}}">
<view class="order" wx:if="{{i.key == 'remark' && item.orderStatus == '-1'}}"> <view class="order" wx:if="{{i.key == 'remark' && item.orderStatus == '-1'}}">
<view class="order-label">{{i.label}}</view> <view class="order-label">{{i.label}}</view>
...@@ -141,22 +119,17 @@ ...@@ -141,22 +119,17 @@
<!-- footer --> <!-- footer -->
<view class="item-footer"> <view class="item-footer">
<view> <view>
<view wx:if="{{item.orderStatus == '3' }}" class="orange-txt">订单已支付,未录入权益合同</view> <view wx:if="{{item.orderStatus == '3' }}" class="orange-txt">
<image class="icon-info" src="/packageEquity/images/icon-info.png"></image>
订单已支付,未录入权益合同
</view>
<view wx:else>创建时间:{{item.createdTime}}</view> <view wx:else>创建时间:{{item.createdTime}}</view>
</view> </view>
<view wx:if="{{item.orderStatus != '4'}}"> <view wx:if="{{item.orderStatus != '4'}}">
<view <view wx:if="{{item.orderStatus == '-1' || item.orderStatus == '0'}}" class="order-btn" bindtap="handleClickBtn" data-target="{{item}}">
wx:if="{{item.orderStatus == '-1' || item.orderStatus == '0'}}"
class="order-btn"
bindtap="handleClickBtn"
data-target="{{item}}">
{{btnTxt[item.orderStatus]}} {{btnTxt[item.orderStatus]}}
</view> </view>
<view <view wx:else class="order-btn default-btn" bindtap="handleClickBtn" data-target="{{item}}">
wx:else
class="order-btn default-btn"
bindtap="handleClickBtn"
data-target="{{item}}">
{{btnTxt[item.orderStatus]}} {{btnTxt[item.orderStatus]}}
</view> </view>
</view> </view>
...@@ -172,13 +145,5 @@ ...@@ -172,13 +145,5 @@
</view> </view>
</scroll-view> </scroll-view>
</view> </view>
<image <image data-target="addOrder" bind:tap="handleClickOrderBtn" class="addOrder" src="/packageEquity/images/addOrder.png" mode="scaleToFill|aspectFit|aspectFill|widthFix" binderror="" bindload="" />
data-target="addOrder"
bind:tap="handleClickOrderBtn"
class="addOrder"
src="/packageEquity/images/addOrder.png"
mode="scaleToFill|aspectFit|aspectFill|widthFix"
binderror=""
bindload="" />
</view> </view>
\ No newline at end of file \ No newline at end of file
...@@ -164,7 +164,8 @@ ...@@ -164,7 +164,8 @@
} }
.total-box { .total-box {
padding: 24rpx 30rpx 20rpx; display: flex;
padding: 24rpx 30rpx;
font-weight: 400; font-weight: 400;
font-size: 28rpx; font-size: 28rpx;
color: #222222; color: #222222;
...@@ -184,7 +185,7 @@ ...@@ -184,7 +185,7 @@
.list { .list {
box-sizing: border-box; box-sizing: border-box;
width: 100%; width: 100%;
padding: 20rpx; padding: 0 20rpx 20rpx;
padding-bottom: 0; padding-bottom: 0;
/* height: calc(100% - 20rpx); */ /* height: calc(100% - 20rpx); */
height: calc(100% - 60rpx); height: calc(100% - 60rpx);
...@@ -194,12 +195,16 @@ ...@@ -194,12 +195,16 @@
.list .item { .list .item {
box-sizing: border-box; box-sizing: border-box;
background: #FFFFFF; background: #FFFFFF;
box-shadow: 0 6rpx 16rpx 0 #cdcdd159; box-shadow: 0 6rpx 16rpx 0 rgba(205, 205, 209, 0.5);
border-radius: 16rpx; border-radius: 16rpx;
margin: 0 6rpx 20rpx; margin: 0 6rpx 20rpx;
} }
.item .itme-content { .list .item:first-child {
margin-top: 20rpx;
}
.item .item-content {
padding: 20rpx 32rpx 0; padding: 20rpx 32rpx 0;
} }
...@@ -399,6 +404,13 @@ ...@@ -399,6 +404,13 @@
color: #EB9B2F; color: #EB9B2F;
} }
.icon-info {
width: 28rpx;
height: 28rpx;
margin-right: 8rpx;
vertical-align: middle;
}
.order-btn { .order-btn {
box-sizing: border-box; box-sizing: border-box;
height: 56rpx; height: 56rpx;
......
...@@ -50,7 +50,7 @@ Page({ ...@@ -50,7 +50,7 @@ Page({
if (name == 'confirm') { if (name == 'confirm') {
console.log(wx.$router) console.log(wx.$router)
// this.triggerEvent('confirm') // this.triggerEvent('confirm')
wx.$router.reLaunch('signature', { id }) wx.$router.redirectTo('signature', { id })
} else if (name == 'edit') { } else if (name == 'edit') {
// this.triggerEvent('editSave') // this.triggerEvent('editSave')
this.backEdit() this.backEdit()
......
...@@ -55,6 +55,28 @@ const secretKey_items = { ...@@ -55,6 +55,28 @@ const secretKey_items = {
secret: '4bc07f8868374c49a4661d603377e3106fc9a45bccaaa353' secret: '4bc07f8868374c49a4661d603377e3106fc9a45bccaaa353'
} }
} }
const scrmSecretKey_items = {
ip: {
appKey: '48e5e13229b82c1b4e6e8c96151f0637',
secret: 'c24619ed7fef02a0ae16328146bca5f97cc6493957a2137b'
},
dev: {
appKey: '48e5e13229b82c1b4e6e8c96151f0637',
secret: 'c24619ed7fef02a0ae16328146bca5f97cc6493957a2137b'
},
uat: {
appKey: '48e5e13229b82c1b4e6e8c96151f0637',
secret: 'c24619ed7fef02a0ae16328146bca5f97cc6493957a2137b'
},
prod: {
appKey: '48e5e13229b82c1b4e6e8c96151f0637',
secret: 'c24619ed7fef02a0ae16328146bca5f97cc6493957a2137b'
},
preRelease: {
appKey: 'd7ffc3346fc9a45bccaaa35300d59022',
secret: '4bc07f8868374c49a4661d603377e3106fc9a45bccaaa353'
}
}
const domain_items = { const domain_items = {
ip: { ip: {
// dj: 'http://192.168.1.165:8292', // dj: 'http://192.168.1.165:8292',
...@@ -94,5 +116,6 @@ const target = ['ip', 'dev', 'uat', 'prod', 'preRelease'] ...@@ -94,5 +116,6 @@ const target = ['ip', 'dev', 'uat', 'prod', 'preRelease']
// console.log(domain_items[target[index]]); // console.log(domain_items[target[index]]);
module.exports = { module.exports = {
domain: domain_items[target[index]], domain: domain_items[target[index]],
secretKey: secretKey_items[target[index]] secretKey: secretKey_items[target[index]],
scrmSecretKey: scrmSecretKey_items[target[index]]
} }
import { secretKey, domain, path, sign } from './http.js' import { secretKey, domain, path, sign,scrmSecretKey } from './http.js'
import util from '~/utils/util.js' import util from '~/utils/util.js'
/**接口 */ /**接口 */
class Request { class Request {
...@@ -94,14 +94,23 @@ class Request { ...@@ -94,14 +94,23 @@ class Request {
getData(data, method, noSignAttr) { getData(data, method, noSignAttr) {
let sessionId = util.getSessionId() let sessionId = util.getSessionId()
if (sessionId) data['sessionId'] = sessionId if (sessionId) data['sessionId'] = sessionId
console.log(data,'request');
data['v'] = '1.0.0' data['v'] = '1.0.0'
data['method'] = method data['method'] = method
data['format'] = 'json' data['format'] = 'json'
data['locale'] = 'zh_CN' data['locale'] = 'zh_CN'
data['source'] = 'dj-wechat' data['source'] = 'dj-wechat'
data['appKey'] = secretKey.appKey
let obj = sign(data, secretKey.secret, noSignAttr) // 兼容线上appkey和secret不一样的情况
let djapi = data.method.includes('dj.api')
let scmrapi = data.method.includes('scrm.api')
console.log(scmrapi,'scmrapi');
const appKey = scmrapi?scrmSecretKey.appKey:djapi?secretKey.appKey:''
const secret = scmrapi?scrmSecretKey.secret:djapi?secretKey.secret:''
data['appKey'] = appKey
let obj = sign(data, secret, noSignAttr)
//data['sign'] = obj.sign; //data['sign'] = obj.sign;
return obj return obj
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!