Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas_plus
/
dj-car-boutique-work-wechat
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
1
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 276bb2a7
authored
Mar 20, 2023
by
张立顺
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
重复提交bug修复
1 parent
7dd6d7e4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
63 additions
and
10 deletions
packageEquity/pages/carQuotation/createOrderCarQuotation/createOrderCarQuotation.js
packageEquity/pages/carQuotation/schemeConfirmation/schemeConfirmation.js
utils/request/environment.js
utils/request/request.js
packageEquity/pages/carQuotation/createOrderCarQuotation/createOrderCarQuotation.js
View file @
276bb2a
...
...
@@ -11,7 +11,9 @@ Page({
certificateNo
:
''
,
carVin
:
''
,
seat
:
'5'
,
price
:
''
price
:
''
,
confirmStatus
:
false
,
saveStatus
:
false
},
// owner: {
// owner: 'test2',
...
...
@@ -123,13 +125,18 @@ Page({
async
handleSecondConfirm
()
{
// owner, orderInfo,
// 修改权益报价逻辑
let
{
modifyEquityQuotation
}
=
this
.
data
let
{
modifyEquityQuotation
,
confirmStatus
}
=
this
.
data
if
(
confirmStatus
)
return
false
if
(
modifyEquityQuotation
)
{
return
this
.
updateEquityPrice
()
}
// orderInfo.check = false
// orderInfo.owner = owner
// this.setData({ orderInfo })
wx
.
showLoading
(
'报价中...'
)
this
.
setData
({
confirmStatus
:
true
})
let
result
=
await
this
.
handleSecondConfirmCheck
()
let
{
code
,
data
:
id
,
message
}
=
result
...
...
@@ -137,14 +144,20 @@ Page({
if
(
id
)
{
// 校验生成告知书是否成功
let
status
=
await
this
.
getQuotationGenerate
(
id
)
wx
.
hideLoading
()
this
.
setData
({
confirmStatus
:
false
})
console
.
log
(
'id'
,
id
)
status
.
code
==
0
?
this
.
navigatorNext
(
id
)
:
wx
.
$util
.
showToast
(
status
.
message
||
'报价失败'
)
// let
// status && this.navigatorNext(id)
}
else
{
console
.
log
(
message
)
wx
.
hideLoading
()
this
.
setData
({
confirmStatus
:
false
})
wx
.
$util
.
showToast
(
message
||
'报价失败'
)
}
...
...
@@ -272,14 +285,22 @@ Page({
},
// 不需要检验 存草稿
async
handleEditSave
()
{
let
{
owner
,
orderInfo
,
modifyEquityQuotation
}
=
this
.
data
let
{
owner
,
orderInfo
,
modifyEquityQuotation
,
saveStatus
}
=
this
.
data
if
(
modifyEquityQuotation
)
{
return
this
.
updateEquityPrice
(
'saveEdit'
)
}
if
(
saveStatus
)
return
false
wx
.
showLoading
(
'保存中...'
)
this
.
setData
({
saveStatus
:
true
})
orderInfo
.
check
=
false
orderInfo
.
owner
=
owner
this
.
setData
({
orderInfo
})
let
id
=
await
this
.
handleSecondConfirmCheck
()
this
.
setData
({
saveStatus
:
false
})
console
.
log
(
'id'
,
id
)
// this.navigatorNext()
// wx.$router.go('packageEquity.index')
...
...
packageEquity/pages/carQuotation/schemeConfirmation/schemeConfirmation.js
View file @
276bb2a
...
...
@@ -50,7 +50,7 @@ Page({
if
(
name
==
'confirm'
)
{
console
.
log
(
wx
.
$router
)
// this.triggerEvent('confirm')
wx
.
$router
.
re
Launch
(
'signature'
,
{
id
})
wx
.
$router
.
re
directTo
(
'signature'
,
{
id
})
}
else
if
(
name
==
'edit'
)
{
// this.triggerEvent('editSave')
this
.
backEdit
()
...
...
utils/request/environment.js
View file @
276bb2a
...
...
@@ -55,6 +55,28 @@ const secretKey_items = {
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
=
{
ip
:
{
// dj: 'http://192.168.1.165:8292',
...
...
@@ -94,5 +116,6 @@ const target = ['ip', 'dev', 'uat', 'prod', 'preRelease']
// console.log(domain_items[target[index]]);
module
.
exports
=
{
domain
:
domain_items
[
target
[
index
]],
secretKey
:
secretKey_items
[
target
[
index
]]
secretKey
:
secretKey_items
[
target
[
index
]],
scrmSecretKey
:
scrmSecretKey_items
[
target
[
index
]]
}
utils/request/request.js
View file @
276bb2a
import
{
secretKey
,
domain
,
path
,
sign
}
from
'./http.js'
import
{
secretKey
,
domain
,
path
,
sign
,
scrmSecretKey
}
from
'./http.js'
import
util
from
'~/utils/util.js'
/**接口 */
class
Request
{
...
...
@@ -94,14 +94,23 @@ class Request {
getData
(
data
,
method
,
noSignAttr
)
{
let
sessionId
=
util
.
getSessionId
()
if
(
sessionId
)
data
[
'sessionId'
]
=
sessionId
console
.
log
(
data
,
'request'
);
data
[
'v'
]
=
'1.0.0'
data
[
'method'
]
=
method
data
[
'format'
]
=
'json'
data
[
'locale'
]
=
'zh_CN'
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;
return
obj
...
...
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment