Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
卡
卡车调度系统
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
caicaicai
卡车调度系统
Commits
d0db5561
Commit
d0db5561
authored
Apr 08, 2022
by
caicaicai
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改
parent
e885549a
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
43 additions
and
34 deletions
+43
-34
common.js
src/assets/js/common.js
+10
-0
index.vue
src/views/carManagement/carType/index.vue
+25
-17
index.vue
src/views/regionalManagement/regionalInformation/index.vue
+8
-17
No files found.
src/assets/js/common.js
View file @
d0db5561
...
...
@@ -6,6 +6,16 @@ var HttpReq = function(){
return
{
//卡车调度系统
truckDispatching
:{
//图片上传
uploadPictures
:
function
(
data
){
return
request
({
url
:
'
/api/Area/updateAvatar
'
,
method
:
'
POST
'
,
data
:
data
,
}).
then
((
res
)
=>
{
return
res
})
},
//系统管理——班次设置
shiftQuery
:
function
(
param
){
return
request
({
...
...
src/views/carManagement/carType/index.vue
View file @
d0db5561
...
...
@@ -262,23 +262,31 @@ export default {
let
file
=
event
.
target
.
files
[
0
];
let
formData1
=
new
FormData
();
formData1
.
append
(
"
avatar
"
,
file
);
Axios
({
url
:
process
.
env
.
VUE_APP_LOCAL_API2
+
'
/api/Area/updateAvatar
'
,
method
:
"
post
"
,
data
:
formData1
,
}).
then
(
response
=>
{
if
(
response
.
status
==
200
)
{
this
.
$message
.
success
(
"
上传成功
"
);
that
.
picFileName
=
response
.
data
.
avatar
;
}
else
{
this
.
$message
.
error
(
"
上传失败
"
);
}
},
)
.
catch
(
error
=>
{
console
.
log
(
error
);
});
HttpReq
.
truckDispatching
.
uploadPictures
(
formData1
).
then
((
res
)
=>
{
this
.
$notify
({
title
:
'
上传成功!
'
,
type
:
'
success
'
,
duration
:
2500
});
that
.
picFileName
=
res
.
avatar
;
})
// Axios({
// url: process.env.VUE_APP_LOCAL_API2 + '/api/users/updateAvatar',
// method: "post",
// data: formData1,
// }).then(
// response => {
// if (response.status == 200) {
// this.$message.success("上传成功");
// that.picFileName = response.data.avatar;
// } else {
// this.$message.error("上传失败");
// }
// },
// )
// .catch(error => {
// console.log(error);
// });
},
}
}
...
...
src/views/regionalManagement/regionalInformation/index.vue
View file @
d0db5561
...
...
@@ -480,23 +480,14 @@ export default {
let
file
=
event
.
target
.
files
[
0
];
let
formData1
=
new
FormData
();
formData1
.
append
(
"
avatar
"
,
file
);
Axios
({
url
:
process
.
env
.
VUE_APP_LOCAL_API2
+
'
/api/Area/updateAvatar
'
,
method
:
"
post
"
,
data
:
formData1
,
}).
then
(
response
=>
{
if
(
response
.
status
==
200
)
{
this
.
$message
.
success
(
"
上传成功
"
);
that
.
picFileName
=
response
.
data
.
avatar
;
}
else
{
this
.
$message
.
error
(
"
上传失败
"
);
}
},
)
.
catch
(
error
=>
{
console
.
log
(
error
);
});
HttpReq
.
truckDispatching
.
uploadPictures
(
formData1
).
then
((
res
)
=>
{
this
.
$notify
({
title
:
'
上传成功!
'
,
type
:
'
success
'
,
duration
:
2500
});
that
.
picFileName
=
res
.
avatar
;
})
},
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
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 comment