Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
W
WL01
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
template admin
WL01
Commits
85b576e6
Commit
85b576e6
authored
Jul 15, 2021
by
linzhiguo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
+ 每道题限时
+ 最多16道题
parent
c5220242
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
11 deletions
+17
-11
form.component.html
form/src/app/form/form.component.html
+13
-10
form.component.ts
form/src/app/form/form.component.ts
+4
-1
No files found.
form/src/app/form/form.component.html
View file @
85b576e6
<div
class=
"model-content"
>
<div
class=
"model-content"
>
<nz-divider
nzText=
"主题"
nzOrientation=
"
center
"
></nz-divider>
<nz-divider
nzText=
"主题"
nzOrientation=
"
left
"
></nz-divider>
<div
nz-row
style=
"width: 800;"
>
<div
nz-row
style=
"width: 800;"
>
<div
style=
"display: flex; margin-bottom: 10px;"
>
<div
style=
"display: flex; margin-bottom: 10px;"
>
<div
style=
"flex:1;margin-left: 10px;"
>
<div
style=
"flex:1;margin-left: 10px;"
>
标题
标题
</div>
</div>
<div
style=
"flex:5"
>
<div
style=
"flex:5"
>
<input
type=
"text"
nz-input
placeholder=
""
[(
ngModel
)]="
item
.
title
"
(
blur
)="
saveItem
()"
/>
<input
type=
"text"
nz-input
placeholder=
""
[(
ngModel
)]="
item
.
title
"
(
blur
)="
saveItem
()"
style=
"width: 160px;"
/>
</div>
</div>
</div>
</div>
...
@@ -22,16 +22,16 @@
...
@@ -22,16 +22,16 @@
<div
style=
"display: flex; margin-bottom: 10px;"
>
<div
style=
"display: flex; margin-bottom: 10px;"
>
<div
style=
"flex:1; margin-left: 10px;"
>
<div
style=
"flex:1; margin-left: 10px;"
>
时间
每道题限时(整数)
</div>
</div>
<div
style=
"flex:5"
>
<div
style=
"flex:5"
>
<input
type=
"text"
nz-input
placeholder=
""
[(
ngModel
)]="
item
.
time
"
(
blur
)="
saveItem
()"
/>
<input
type=
"text"
nz-input
placeholder=
""
[(
ngModel
)]="
item
.
time
"
(
blur
)="
saveItem
()"
style=
"width: 160px;"
/>
s
</div>
</div>
</div>
</div>
</div>
</div>
<nz-divider
nzOrientation=
"left"
></nz-divider>
<nz-divider
nz
Text=
"题目列表(最多16道题)"
nz
Orientation=
"left"
></nz-divider>
<div
class=
"card-config"
>
<div
class=
"card-config"
>
<div
*
ngFor=
"let data of item.mouses; let i = index"
class=
"card-item"
style=
"padding: 0.5vw;"
>
<div
*
ngFor=
"let data of item.mouses; let i = index"
class=
"card-item"
style=
"padding: 0.5vw;"
>
<div
class=
"card-item-content border"
>
<div
class=
"card-item-content border"
>
...
@@ -78,11 +78,14 @@
...
@@ -78,11 +78,14 @@
</div>
</div>
</div>
</div>
</div>
</div>
<div
class=
"card-item"
style=
"padding: 0.5vw;"
>
<button
nz-button
nzType=
"primary"
class=
"add-btn"
(
click
)="
addRat
()"
>
<div
*
ngIf=
"item.mouses.length < 16"
>
<i
nz-icon
nzType=
"plus-circle"
nzTheme=
"outline"
></i>
<div
class=
"card-item"
style=
"padding: 0.5vw;"
>
新建题目
<button
nz-button
nzType=
"primary"
class=
"add-btn"
(
click
)="
addRat
()"
>
</button>
<i
nz-icon
nzType=
"plus-circle"
nzTheme=
"outline"
></i>
新建题目
</button>
</div>
</div>
</div>
...
...
form/src/app/form/form.component.ts
View file @
85b576e6
...
@@ -28,7 +28,8 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
...
@@ -28,7 +28,8 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
//this.item = new Course();
//this.item = new Course();
this
.
item
=
new
WL01
();
this
.
item
=
new
WL01
();
this
.
item
.
time
=
3
;
this
.
item
.
mouses
=
new
Array
<
Rat
>
();
// 获取存储的数据
// 获取存储的数据
(
<
any
>
window
).
courseware
.
getData
((
data
)
=>
{
(
<
any
>
window
).
courseware
.
getData
((
data
)
=>
{
...
@@ -56,6 +57,8 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
...
@@ -56,6 +57,8 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
init
()
{
init
()
{
if
(
!
this
.
item
){
if
(
!
this
.
item
){
this
.
item
=
new
WL01
();
this
.
item
=
new
WL01
();
this
.
item
.
time
=
3
;
this
.
item
.
mouses
=
new
Array
<
Rat
>
();
}
}
}
}
...
...
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