Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
educationStu
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
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
向伟
educationStu
Commits
8e75e5cc
Commit
8e75e5cc
authored
Sep 13, 2021
by
罗超
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
2749788b
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
10 deletions
+11
-10
askForLeave.vue
src/pages/course/askForLeave.vue
+5
-7
timeTable-item.vue
src/pages/course/timeTable-item.vue
+3
-1
index.js
src/utils/index.js
+3
-2
No files found.
src/pages/course/askForLeave.vue
View file @
8e75e5cc
...
...
@@ -143,7 +143,7 @@
<view
style=
"padding-left: 10rpx"
>
<van-uploader
multiple
accept=
"
all
"
accept=
"
media
"
:file-list=
"fileList"
image-fit=
"aspectFill"
preview-size=
"120rpx"
...
...
@@ -173,7 +173,6 @@ import {
import
{
getdate
}
from
"../../utils/date"
;
import
{
uploadFile
}
from
"../../utils/index"
;
import
{
getStundentPlanStatistical
,
setStudentLeave
}
from
"../../api/index"
;
let
{
ClassId
}
=
uni
.
getStorageSync
(
"indexData"
);
export
default
{
setup
()
{
let
Toast
=
inject
(
"$toast"
);
...
...
@@ -208,7 +207,7 @@ export default {
// url: "https://img.yzcdn.cn/vant/leaf.jpg",
// },
],
totalLeaveTimes
:
0
,
totalLeaveTimes
:
0
,
//总课时
leaveMsg
:
{
Id
:
0
,
ClassId
:
0
,
...
...
@@ -296,7 +295,7 @@ export default {
let
msg
=
{
StartTime
:
data
.
data
.
startTime
,
EndTime
:
data
.
data
.
endTime
,
ClassId
:
ClassId
,
ClassId
:
data
.
leaveMsg
.
ClassId
,
};
let
res
=
await
getStundentPlanStatistical
(
msg
);
data
.
isShowAllCheck
=
true
;
...
...
@@ -310,9 +309,7 @@ export default {
},
customUpload
(
event
)
{
const
{
file
}
=
event
.
detail
;
console
.
log
(
"295"
,
file
);
uploadFile
(
"stuLeave"
,
file
,
(
res
)
=>
{
console
.
log
(
"297"
,
res
);
data
.
fileList
.
push
(
res
);
});
},
...
...
@@ -369,10 +366,11 @@ export default {
...
methods
,
};
},
onLoad
()
{
onLoad
(
options
)
{
uni
.
setNavigationBarTitle
({
title
:
"请假"
,
});
this
.
leaveMsg
.
ClassId
=
parseInt
(
options
.
classId
);
},
};
</
script
>
...
...
src/pages/course/timeTable-item.vue
View file @
8e75e5cc
...
...
@@ -36,7 +36,9 @@
<view
class=
"btn-box"
>
<van-button
custom-class=
"leave-btn"
@
click=
"jumpPage('/pages/course/askForLeave')"
@
click=
"
jumpPage(`/pages/course/askForLeave?classId=$
{data.ClassId} `)
"
v-if="item.IsLeave === 1"
>请假
</van-button
>
...
...
src/utils/index.js
View file @
8e75e5cc
...
...
@@ -49,8 +49,9 @@ export function UploadSelfFile(path, file, callback, configObj) {
uploadConfig
=
cacheInfo
.
UploadConfig
;
}
//获取文件扩展名
var
index
=
file
.
name
.
lastIndexOf
(
"."
);
var
suffix
=
file
.
name
.
substr
(
index
);
console
.
log
(
52
,
file
)
var
index
=
file
.
url
.
lastIndexOf
(
"."
);
var
suffix
=
file
.
url
.
substr
(
index
);
var
timestamp1
=
Date
.
parse
(
new
Date
())
+
"_"
+
(
Math
.
ceil
(
Math
.
random
()
*
1000
));
let
str
=
'/Test'
;
var
newPath
=
"/EduSystem"
+
str
+
'/Upload/'
+
path
;
...
...
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