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
966e0069
Commit
966e0069
authored
Oct 29, 2021
by
Mac
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
5ce8e94a
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
18 deletions
+24
-18
chooseApplet.vue
src/pages/teacher/components/chooseApplet.vue
+24
-18
No files found.
src/pages/teacher/components/chooseApplet.vue
View file @
966e0069
...
...
@@ -7,7 +7,7 @@
<q-separator
/>
<q-card-section
class=
"q-pt-none"
style=
"margin-top: 15px;"
>
<q-select
filled
stack-label
option-value=
"Id"
option-label=
"Name"
v-model=
"msg.AppletId"
@
input=
"getroute"
ref=
"ID"
:options=
"AppletList"
label=
"
分组
"
:dense=
"false"
emit-value
map-options
/>
@
input=
"getroute"
ref=
"ID"
:options=
"AppletList"
label=
"
选择小程序
"
:dense=
"false"
emit-value
map-options
/>
<q-input
clearable
standout=
"bg-primary text-white"
v-model=
"msg.route"
@
input=
"$forceUpdate()"
label=
"小程序路径"
style=
"margin-top: 20px;"
/>
<div
style=
"display: flex;align-items: center;margin: 10px 0 ;"
>
...
...
@@ -179,6 +179,10 @@
this
.
getImgChoice
=
true
;
},
SelectId
(
obj
)
{
if
(
this
.
msg
.
type
==
2
){
this
.
msg
.
imgUrl
=
obj
[
0
].
ImageUrl
;
this
.
getImgChoice
=
false
;
}
else
{
this
.
getNaturalImgSize
(
obj
[
0
].
ImageUrl
,
k
=>
{
//获取图片比例
let
qualified
=
k
.
qualified
if
(
qualified
==
true
)
{
...
...
@@ -192,6 +196,8 @@
})
}
})
}
},
getNaturalImgSize
(
img_url
,
callback
)
{
...
...
@@ -201,12 +207,12 @@
img
.
onload
=
function
()
{
// 打印
let
qualified
=
false
// if (Number(img.height) / img.width == 0.8) {
// qualified = true
// }
if
(
img
.
width
==
1080
&&
img
.
height
==
864
)
{
if
(
Number
(
img
.
height
)
/
img
.
width
==
0.8
)
{
qualified
=
true
}
// if (img.width == 1080 && img.height==864) {
// qualified = true
// }
callback
({
qualified
:
qualified
})
};
...
...
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