Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
confucius
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
罗超
confucius
Commits
d3c4cfd5
Commit
d3c4cfd5
authored
Aug 02, 2021
by
zhengke
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改
parent
85ef55a4
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
243 additions
and
3 deletions
+243
-3
studentList.vue
src/pages/sale/studentList.vue
+243
-3
No files found.
src/pages/sale/studentList.vue
View file @
d3c4cfd5
<
style
>
._addUpload_stu
{
display
:
block
;
margin-top
:
15px
;
}
._addUpload_stu
img
{
width
:
100%
;
}
._addUpload_stu
>
div
{
display
:
inline-block
;
width
:
138px
;
height
:
92px
;
border
:
1px
dashed
rgba
(
210
,
210
,
210
,
1
);
border-radius
:
2px
;
cursor
:
pointer
;
margin-bottom
:
10px
;
padding
:
5px
;
margin-right
:
10px
;
position
:
relative
;
}
._addUpload_stu
>
div
:hover
{
background-color
:
#f5f5f5
;
}
.stuCard
.el-upload-dragger
{
font-size
:
28px
;
color
:
#8c939d
;
width
:
126px
;
height
:
80px
;
line-height
:
41px
;
text-align
:
center
;
}
._addUpload_stu
.icon-guanbi1
{
font-size
:
12px
;
color
:
white
;
display
:
inline-block
;
margin-left
:
15px
;
position
:
absolute
;
right
:
-6px
;
top
:
-9px
;
background-color
:
#f56c6c
;
border-radius
:
50%
;
height
:
20px
;
width
:
20px
;
text-align
:
center
;
line-height
:
20px
;
}
</
style
>
<
template
>
<
template
>
<div
class=
"page-body"
>
<div
class=
"page-body"
>
<div
class=
"page-content"
>
<div
class=
"page-content"
>
...
@@ -49,7 +98,7 @@
...
@@ -49,7 +98,7 @@
</q-table>
</q-table>
</div>
</div>
<q-dialog
v-model=
"persistent"
content-class=
"bg-grey-1"
persistent
transition-show=
"scale"
transition-hide=
"scale"
>
<q-dialog
v-model=
"persistent"
content-class=
"bg-grey-1"
persistent
transition-show=
"scale"
transition-hide=
"scale"
>
<q-card
style=
"width: 800px;max-width:900px;"
>
<q-card
style=
"width: 800px;max-width:900px;"
class=
"stuCard"
>
<q-card-section>
<q-card-section>
<div
class=
"text-h6"
>
{{addMsg.Id==0?'新增学员':'修改学员'}}
</div>
<div
class=
"text-h6"
>
{{addMsg.Id==0?'新增学员':'修改学员'}}
</div>
</q-card-section>
</q-card-section>
...
@@ -152,6 +201,41 @@
...
@@ -152,6 +201,41 @@
<q-input
filled
stack-label
:dense=
"false"
v-model=
"addMsg.StudyRemark"
type=
"textarea"
class=
"col-12"
<q-input
filled
stack-label
:dense=
"false"
v-model=
"addMsg.StudyRemark"
type=
"textarea"
class=
"col-12"
label=
"备注"
maxlength=
"300"
/>
label=
"备注"
maxlength=
"300"
/>
</div>
</div>
<div
class=
"row wrap"
style=
"margin:0 20px;"
>
<q-input
clearable
filled
class=
"col-6 q-pb-lg q-pr-lg"
v-model=
"addMsg.GuestContractNo"
label=
"合同编号"
/>
<q-select
class=
"col-6 q-pb-lg"
ref=
"ContractType"
@
input=
"resetContractArr"
standout=
"bg-primary text-white"
option-value=
"Id"
option-label=
"Name"
v-model=
"addMsg.ContractType"
:options=
"ContractTypeList"
emit-value
map-options
label=
"上传类型"
use-input
new-value-mode=
"add-unique"
/>
</div>
<div
class=
"row wrap"
style=
"margin:0 20px;"
>
<div
class=
"col-12 text-grey-6"
>
上传附件:
<span
class=
"fj-tip"
style=
"font-size: 10px; color: #f00"
></span>
</div>
</div>
<div>
<div
class=
"_addUpload_stu"
style=
"margin:15px 0 0 20px;min-height:100px;"
>
<
template
v-for=
"(file, fIndex) in saveMsg"
>
<div
v-if=
"file.Type == 2"
>
<div
style=
"width: 100%; height: 100%; overflow: hidden"
>
<img
:src=
"file.Url ? file.Url : file.Content"
@
click=
"showUpLoadFile(file)"
/>
</div>
<span
class=
"iconfont icon-guanbi1"
@
click=
"deleteUploadFile(fIndex)"
></span>
</div>
<div
v-if=
"file.Type == 1"
style=
"float:left;"
>
<div
class=
"iconfont icon-pdf"
style=
"font-size:38px;color:green;text-align:center;line-height:75px;"
@
click=
"showUpLoadFile(file)"
></div>
<span
class=
"iconfont icon-guanbi1"
@
click=
"deleteUploadFile(fIndex)"
></span>
</div>
</
template
>
<div
class=
"_pic_upload"
>
<el-upload
drag
:http-request=
"uploadFileBtn"
:multiple=
"true"
:show-file-list=
"false"
action=
""
>
<i
class=
"el-icon-plus avatar-uploader-icon"
></i>
<div
class=
"el-upload__text"
>
{{ $t("active.ld_djscwj") }}
</div>
</el-upload>
</div>
</div>
</div>
<q-separator
/>
<q-separator
/>
<q-card-actions
align=
"right"
class=
"bg-white"
>
<q-card-actions
align=
"right"
class=
"bg-white"
>
<q-btn
label=
"取消"
flat
color=
"grey-10"
style=
"font-weight:400 !important"
@
click=
"closeSaveForm"
/>
<q-btn
label=
"取消"
flat
color=
"grey-10"
style=
"font-weight:400 !important"
@
click=
"closeSaveForm"
/>
...
@@ -160,6 +244,23 @@
...
@@ -160,6 +244,23 @@
</q-card-actions>
</q-card-actions>
</q-card>
</q-card>
</q-dialog>
</q-dialog>
<div
v-if=
"picIsShow"
class=
"_show_img_box"
@
click=
"(picIsShow = false), (picObj = [])"
>
<div
style=
"
position: absolute;
width: 800px;
height: 600px;
left: 50%;
top: 50%;
margin-left: -400px;
margin-top: -300px;
"
>
<el-carousel
:initial-index=
"initialIndex"
height=
"600px"
:interval=
"5000"
trigger=
"click"
>
<el-carousel-item
style=
"height: 600px; overflow: auto"
v-for=
"(item, index) in picObj"
:key=
"index"
>
<img
:src=
"item"
style=
""
/>
</el-carousel-item>
</el-carousel>
</div>
</div>
</div>
</div>
</template>
</template>
...
@@ -323,7 +424,10 @@
...
@@ -323,7 +424,10 @@
StudyRemark
:
""
,
//留学就业备注
StudyRemark
:
""
,
//留学就业备注
BirthDate
:
""
,
//出生日期
BirthDate
:
""
,
//出生日期
TotalHours
:
0
,
//总课时
TotalHours
:
0
,
//总课时
StuIcon
:
''
//头像
StuIcon
:
''
,
//头像
GuestContractNo
:
''
,
//合同编号
ContractType
:
1
,
//上传类型 1-PDF 2图片
ContractUrl
:
[]
//合同链接
},
},
GBList
:
[],
//日语基础列表
GBList
:
[],
//日语基础列表
GEList
:
[],
//学历列表
GEList
:
[],
//学历列表
...
@@ -335,6 +439,17 @@
...
@@ -335,6 +439,17 @@
visibleColumns
:
[
visibleColumns
:
[
],
//可见列
],
//可见列
saveMsg
:
[],
picObj
:
[],
picIsShow
:
false
,
initialIndex
:
0
,
ContractTypeList
:[{
Name
:
'PDF'
,
Id
:
1
},{
Name
:
'图片'
,
Id
:
2
}]
}
}
},
},
created
()
{
created
()
{
...
@@ -375,6 +490,117 @@
...
@@ -375,6 +490,117 @@
this
.
getGuestPage
();
this
.
getGuestPage
();
},
},
methods
:
{
methods
:
{
resetContractArr
(){
this
.
saveMsg
=
[];
this
.
addMsg
.
ContractUrl
=
[];
},
showUpLoadFile
(
i
)
{
// 预览上传文件
if
(
i
.
Type
==
3
)
{
this
.
picObj
.
push
(
i
.
Url
);
// this.imgList.push(i.Url)
this
.
picIsShow
=
true
;
}
else
{
if
(
i
.
Content
.
substring
(
i
.
Content
.
lastIndexOf
(
"."
)
+
1
,
i
.
Content
.
length
).
toUpperCase
()
==
"PDF"
||
i
.
Content
.
substring
(
i
.
Content
.
lastIndexOf
(
"."
)
+
1
,
i
.
Content
.
length
).
toUpperCase
()
==
"TXT"
)
{
this
.
previewPDF
(
i
.
Url
);
}
else
{
window
.
open
(
"https://view.officeapps.live.com/op/view.aspx?src="
+
i
.
Url
);
}
}
},
deleteUploadFile
(
i
)
{
// 删除上传文件
this
.
saveMsg
.
splice
(
i
,
1
);
this
.
addMsg
.
ContractUrl
.
splice
(
i
,
1
);
},
uploadFileBtn
(
file
)
{
// 1 文档 2 数据 3 图片,4压缩包,5视频
let
typeArr
=
[{
stringArr
:
"GIF|JPG|JPEG|PNG|BMP|WEBP"
,
type
:
2
,
},
{
stringArr
:
"PDF|pdf"
,
type
:
1
,
},
];
let
ft
=
file
.
file
.
name
.
substring
(
file
.
file
.
name
.
lastIndexOf
(
"."
)
+
1
,
file
.
file
.
name
.
length
)
.
toUpperCase
();
let
fileTypeNumber
=
2
;
typeArr
.
forEach
((
x
)
=>
{
if
(
x
.
stringArr
.
indexOf
(
ft
)
!=
"-1"
)
{
fileTypeNumber
=
x
.
type
;
}
});
if
(
this
.
addMsg
.
ContractType
==
1
){
if
(
fileTypeNumber
!=
1
){
this
.
$q
.
notify
({
type
:
'negative'
,
position
:
"top"
,
message
:
`请上传pdf文件`
})
return
}
}
if
(
this
.
addMsg
.
ContractType
==
2
){
if
(
fileTypeNumber
!=
2
){
this
.
$q
.
notify
({
type
:
'negative'
,
position
:
"top"
,
message
:
`请上传图片`
})
return
}
}
this
.
$message
.
info
(
this
.
$t
(
"tips.shangchuanzhong"
));
UploadSelfFile
(
"Temporary"
,
file
.
file
,
(
x
)
=>
{
if
(
x
.
Code
==
1
)
{
if
(
this
.
addMsg
.
ContractType
==
1
){
if
(
this
.
addMsg
.
ContractUrl
.
length
<
1
){
this
.
saveMsg
.
push
({
Content
:
x
.
FileUrl
,
ID
:
0
,
Type
:
fileTypeNumber
,
Url
:
x
.
FileUrl
,
});
this
.
addMsg
.
ContractUrl
.
push
(
x
.
FileUrl
);
}
else
{
this
.
$q
.
notify
({
type
:
'negative'
,
position
:
"top"
,
message
:
`只能上传一个PDF文件`
})
}
}
else
{
this
.
saveMsg
.
push
({
Content
:
x
.
FileUrl
,
ID
:
0
,
Type
:
fileTypeNumber
,
Url
:
x
.
FileUrl
,
});
this
.
addMsg
.
ContractUrl
.
push
(
x
.
FileUrl
);
}
this
.
$message
.
success
(
this
.
$t
(
"tips.scchenggong"
));
}
},
1
);
},
getOrderInfo
()
{
getOrderInfo
()
{
var
qMsg
=
{
var
qMsg
=
{
ClassId
:
this
.
msg
.
ClassId
,
ClassId
:
this
.
msg
.
ClassId
,
...
@@ -516,7 +742,7 @@
...
@@ -516,7 +742,7 @@
VolunteerMajor
:
""
,
//志愿专业
VolunteerMajor
:
""
,
//志愿专业
Price
:
0
,
//价格
Price
:
0
,
//价格
StudyRemark
:
""
,
//留学就业备注
StudyRemark
:
""
,
//留学就业备注
TotalHours
:
this
.
CourseClassHourse
,
TotalHours
:
this
.
CourseClassHourse
,
}
}
},
},
//新增学员弹窗
//新增学员弹窗
...
@@ -552,6 +778,20 @@
...
@@ -552,6 +778,20 @@
}
}
this
.
addMsg
.
TotalHours
=
item
.
TotalHours
;
this
.
addMsg
.
TotalHours
=
item
.
TotalHours
;
this
.
addMsg
.
StuIcon
=
item
.
StuIcon
;
this
.
addMsg
.
StuIcon
=
item
.
StuIcon
;
this
.
addMsg
.
ContractType
=
item
.
ContractType
;
this
.
addMsg
.
GuestContractNo
=
item
.
GuestContractNo
;
this
.
addMsg
.
ContractUrl
=
item
.
ContractUrlList
;
this
.
saveMsg
=
[];
if
(
this
.
addMsg
.
ContractUrl
&&
this
.
addMsg
.
ContractUrl
.
length
>
0
){
this
.
addMsg
.
ContractUrl
.
forEach
(
x
=>
{
this
.
saveMsg
.
push
({
Content
:
x
,
ID
:
0
,
Type
:
this
.
addMsg
.
ContractType
,
Url
:
x
});
})
}
this
.
persistent
=
true
;
this
.
persistent
=
true
;
},
},
//删除学员
//删除学员
...
...
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