Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas_plus
/
dj-car-life-system
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 8d52234e
authored
Mar 29, 2023
by
张立顺
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
1.3订单上传bug修复
1 parent
61e64b9e
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
23 additions
and
10 deletions
public/index.html
src/App.vue
src/api/orderManage.js
src/api/request.js
src/api/sign.js
src/plugin/axios/index.js
src/views/orderManage/crowdfunding.vue
public/index.html
View file @
8d52234
...
@@ -112,5 +112,8 @@
...
@@ -112,5 +112,8 @@
<script
src=
"<%= htmlWebpackPlugin.options.cdn.js[i] %>"
></script>
<script
src=
"<%= htmlWebpackPlugin.options.cdn.js[i] %>"
></script>
<
% } %>
<
% } %>
</body>
</body>
<script>
</script>
</html>
</html>
\ No newline at end of file
\ No newline at end of file
src/App.vue
View file @
8d52234
...
@@ -9,7 +9,11 @@ export default {
...
@@ -9,7 +9,11 @@ export default {
name
:
'App'
,
name
:
'App'
,
created
()
{
created
()
{
// console.log(abcd.efg)
const
that
=
this
window
.
onstorage
=
function
(
e
)
{
// console.log(`The ${e.key} key has been changed from ${e.oldValue} to ${e.newValue} .`)
that
.
$router
.
push
(
'/login'
)
}
},
},
methods
:
{
methods
:
{
...
@@ -19,6 +23,7 @@ export default {
...
@@ -19,6 +23,7 @@ export default {
<
style
lang=
"scss"
>
<
style
lang=
"scss"
>
@import
"~@/assets/style/public-class.scss"
;
@import
"~@/assets/style/public-class.scss"
;
.el_table
{
.el_table
{
thead
{
thead
{
th
{
th
{
...
...
src/api/orderManage.js
View file @
8d52234
...
@@ -26,8 +26,8 @@ const orderExportApi = (data) => {
...
@@ -26,8 +26,8 @@ const orderExportApi = (data) => {
const
pictureUpload
=
(
data
)
=>
{
const
pictureUpload
=
(
data
)
=>
{
data
.
method
=
"glsx.accounts.biz.common.pictureUpload"
data
.
method
=
"glsx.accounts.biz.common.pictureUpload"
// return request(data, "post"
)
return
request
(
data
,
"post"
,
[
"file"
]
)
return
request
(
data
)
//
return request(data)
}
}
// 导入对账单
// 导入对账单
...
...
src/api/request.js
View file @
8d52234
...
@@ -30,6 +30,7 @@ const request = (
...
@@ -30,6 +30,7 @@ const request = (
"glsx.accounts.biz.common.pictureUpload"
:
"common"
"glsx.accounts.biz.common.pictureUpload"
:
"common"
}
}
const
baseApiName
=
mappingName
[
apiName
]
const
baseApiName
=
mappingName
[
apiName
]
// console.log(baseApiName, "baseApiName")
// params.appKey = baseConfig[baseApiName].appkey
// params.appKey = baseConfig[baseApiName].appkey
if
(
baseApiName
==
"common"
)
{
if
(
baseApiName
==
"common"
)
{
params
.
app_key
=
baseConfig
[
baseApiName
].
appkey
params
.
app_key
=
baseConfig
[
baseApiName
].
appkey
...
@@ -55,19 +56,19 @@ const request = (
...
@@ -55,19 +56,19 @@ const request = (
const
signWay
=
{
const
signWay
=
{
"dj.smartcarlife"
:
"sha1"
,
"dj.smartcarlife"
:
"sha1"
,
dj
:
"sha1"
,
dj
:
"sha1"
,
scrm
:
"
md5
"
,
scrm
:
"
sha1
"
,
glsx
:
"md5"
,
glsx
:
"md5"
,
"glsx.accounts.biz.common.pictureUpload"
:
"md5"
"glsx.accounts.biz.common.pictureUpload"
:
"md5"
}
}
// console.log(signWay[apiName], "baseApiName")
const
secret
=
baseConfig
[
baseApiName
].
secret
const
secret
=
baseConfig
[
baseApiName
].
secret
// const signWay = baseConfig[baseApiName].signWay
var
reqData
=
var
reqData
=
method
===
RequestMethods
.
POST
method
===
RequestMethods
.
POST
?
{
?
{
baseURL
:
"/"
,
baseURL
:
"/"
,
data
:
sign
(
params
,
noSignAttr
,
secret
,
signWay
[
baseA
piName
])
data
:
sign
(
params
,
noSignAttr
,
secret
,
signWay
[
a
piName
])
}
}
:
{
params
:
sign
(
params
,
noSignAttr
,
secret
,
signWay
[
baseA
piName
])
}
:
{
params
:
sign
(
params
,
noSignAttr
,
secret
,
signWay
[
a
piName
])
}
reqData
=
reqData
=
Object
.
assign
(
reqData
,
options
,
{})
reqData
=
reqData
=
Object
.
assign
(
reqData
,
options
,
{})
// console.log(method === RequestMethods.POST)
// console.log(method === RequestMethods.POST)
// console.log(url)
// console.log(url)
...
...
src/api/sign.js
View file @
8d52234
...
@@ -10,6 +10,7 @@ import qs from "qs"
...
@@ -10,6 +10,7 @@ import qs from "qs"
import
{
deepClone
}
from
"@/common/util"
import
{
deepClone
}
from
"@/common/util"
const
sign
=
(
params
,
noSignAttr
=
[],
secret
,
way
=
"sha1"
)
=>
{
const
sign
=
(
params
,
noSignAttr
=
[],
secret
,
way
=
"sha1"
)
=>
{
// console.log(way, "way")
delete
params
.
sign
delete
params
.
sign
var
objStr
=
qs
.
stringify
(
deepClone
(
params
),
{
var
objStr
=
qs
.
stringify
(
deepClone
(
params
),
{
arrayFormat
:
"indices"
,
arrayFormat
:
"indices"
,
...
...
src/plugin/axios/index.js
View file @
8d52234
...
@@ -131,12 +131,14 @@ service.interceptors.response.use(
...
@@ -131,12 +131,14 @@ service.interceptors.response.use(
return
Promise
.
reject
(
new
Error
(
"登录超时,请重新登录"
))
return
Promise
.
reject
(
new
Error
(
"登录超时,请重新登录"
))
// return Promise.reject(new Error(response.message || 'Error'))
// return Promise.reject(new Error(response.message || 'Error'))
}
}
switch
(
+
dataAxios
[
ruleResult
.
code_key
])
{
const
codeValue
=
dataAxios
[
ruleResult
.
code_key
]
||
dataAxios
.
returnCode
switch
(
+
codeValue
)
{
case
ruleResult
.
code_success_value
:
case
ruleResult
.
code_success_value
:
// [ 示例 ] code === 0 代表没有错误
// [ 示例 ] code === 0 代表没有错误
return
dataAxios
[
ruleResult
.
data_key
]
return
dataAxios
[
ruleResult
.
data_key
]
default
:
default
:
// 不是正确的 code
// 不是正确的 code
console
.
log
(
dataAxios
)
errorCreate
(
`
${
dataAxios
[
ruleResult
.
message_key
]}
`
)
errorCreate
(
`
${
dataAxios
[
ruleResult
.
message_key
]}
`
)
break
break
}
}
...
...
src/views/orderManage/crowdfunding.vue
View file @
8d52234
...
@@ -416,9 +416,10 @@ export default {
...
@@ -416,9 +416,10 @@ export default {
if
(
res
)
{
if
(
res
)
{
this
.
fileForm
.
fileUrl
=
res
this
.
fileForm
.
fileUrl
=
res
}
}
const
refName
=
"file"
+
row
.
id
// const refName = "file" + row.id
// const refName = "file"
e
.
target
.
value
=
""
e
.
target
.
value
=
""
this
.
$refs
[
refName
].
value
=
""
//
this.$refs[refName].value = ""
})
})
document
.
getElementById
(
"fileUpload"
).
value
=
""
document
.
getElementById
(
"fileUpload"
).
value
=
""
}
}
...
...
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