Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
E
East_L226
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
East_L226
Commits
3b8ffabe
Commit
3b8ffabe
authored
Jul 10, 2020
by
李维
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dev commit
parent
97964bd9
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
91 additions
and
29 deletions
+91
-29
ng-template-generator_20200709 01-50-06.zip
publish/ng-template-generator_20200709 01-50-06.zip
+0
-0
ng-template-generator_20200710 13-08-24.zip
publish/ng-template-generator_20200710 13-08-24.zip
+0
-0
audio-recorder.component.ts
src/app/common/audio-recorder/audio-recorder.component.ts
+8
-4
upload-image-with-preview.component.ts
...image-with-preview/upload-image-with-preview.component.ts
+9
-6
upload-video.component.ts
src/app/common/upload-video/upload-video.component.ts
+13
-9
play.component.ts
src/app/play/play.component.ts
+61
-5
resources.js
src/app/play/resources.js
+0
-5
No files found.
publish/ng-template-generator_20200709 01-50-06.zip
deleted
100644 → 0
View file @
97964bd9
File deleted
publish/ng-template-generator_20200710 1
1-42-29
.zip
→
publish/ng-template-generator_20200710 1
3-08-24
.zip
View file @
3b8ffabe
No preview for this file type
src/app/common/audio-recorder/audio-recorder.component.ts
View file @
3b8ffabe
...
@@ -21,8 +21,8 @@ export class AudioRecorderComponent implements OnInit, OnChanges, OnDestroy {
...
@@ -21,8 +21,8 @@ export class AudioRecorderComponent implements OnInit, OnChanges, OnDestroy {
Type
=
Type
;
Type
=
Type
;
withRmBtn
=
false
;
withRmBtn
=
false
;
uploadUrl
=
(
<
any
>
window
).
courseware
.
uploadUrl
()
;
uploadUrl
;
uploadData
=
(
<
any
>
window
).
courseware
.
uploadData
()
;
uploadData
;
@
Input
()
@
Input
()
needRemove
=
false
;
needRemove
=
false
;
...
@@ -52,9 +52,13 @@ export class AudioRecorderComponent implements OnInit, OnChanges, OnDestroy {
...
@@ -52,9 +52,13 @@ export class AudioRecorderComponent implements OnInit, OnChanges, OnDestroy {
recorder
:
any
;
recorder
:
any
;
audioBlob
:
any
;
audioBlob
:
any
;
constructor
(
private
nzMessageService
:
NzMessageService
)
{
constructor
(
private
nzMessageService
:
NzMessageService
)
{
this
.
uploadUrl
=
(
<
any
>
window
).
courseware
.
uploadUrl
();
this
.
uploadData
=
(
<
any
>
window
).
courseware
.
uploadData
();
window
[
'
air
'
].
getUploadCallback
=
(
url
,
data
)
=>
{
this
.
uploadUrl
=
url
;
this
.
uploadData
=
data
;
};
}
}
init
()
{
init
()
{
...
...
src/app/common/upload-image-with-preview/upload-image-with-preview.component.ts
View file @
3b8ffabe
...
@@ -29,10 +29,17 @@ export class UploadImageWithPreviewComponent implements OnDestroy, OnChanges {
...
@@ -29,10 +29,17 @@ export class UploadImageWithPreviewComponent implements OnDestroy, OnChanges {
@
Input
()
@
Input
()
disableUpload
=
false
;
disableUpload
=
false
;
uploadUrl
=
(
<
any
>
window
).
courseware
.
uploadUrl
()
;
uploadUrl
;
uploadData
=
(
<
any
>
window
).
courseware
.
uploadData
()
;
uploadData
;
constructor
(
private
nzMessageService
:
NzMessageService
)
{
constructor
(
private
nzMessageService
:
NzMessageService
)
{
this
.
uploadUrl
=
(
<
any
>
window
).
courseware
.
uploadUrl
();
this
.
uploadData
=
(
<
any
>
window
).
courseware
.
uploadData
();
window
[
'
air
'
].
getUploadCallback
=
(
url
,
data
)
=>
{
this
.
uploadUrl
=
url
;
this
.
uploadData
=
data
;
};
}
}
ngOnChanges
()
{
ngOnChanges
()
{
if
(
!
this
.
picItem
)
{
if
(
!
this
.
picItem
)
{
...
@@ -40,10 +47,6 @@ export class UploadImageWithPreviewComponent implements OnDestroy, OnChanges {
...
@@ -40,10 +47,6 @@ export class UploadImageWithPreviewComponent implements OnDestroy, OnChanges {
}
}
}
}
handleChange
(
info
:
{
type
:
string
,
file
:
UploadFile
,
event
:
any
}):
void
{
handleChange
(
info
:
{
type
:
string
,
file
:
UploadFile
,
event
:
any
}):
void
{
switch
(
info
.
type
)
{
switch
(
info
.
type
)
{
case
'
start
'
:
case
'
start
'
:
...
...
src/app/common/upload-video/upload-video.component.ts
View file @
3b8ffabe
...
@@ -27,9 +27,6 @@ export class UploadVideoComponent implements OnChanges, OnDestroy {
...
@@ -27,9 +27,6 @@ export class UploadVideoComponent implements OnChanges, OnDestroy {
@
ViewChild
(
'
videoNode
'
)
@
ViewChild
(
'
videoNode
'
)
videoNode
:
ElementRef
;
videoNode
:
ElementRef
;
// @Input()
// @Input()
// extractCoverFunc = null;
// extractCoverFunc = null;
...
@@ -47,17 +44,24 @@ export class UploadVideoComponent implements OnChanges, OnDestroy {
...
@@ -47,17 +44,24 @@ export class UploadVideoComponent implements OnChanges, OnDestroy {
item
:
any
;
item
:
any
;
// videoItem = null;
// videoItem = null;
uploadUrl
=
(
<
any
>
window
).
courseware
.
uploadUrl
()
;
uploadUrl
;
uploadData
=
(
<
any
>
window
).
courseware
.
uploadData
()
;
uploadData
;
constructor
(
private
nzMessageService
:
NzMessageService
,
constructor
(
private
nzMessageService
:
NzMessageService
,
private
sanitization
:
DomSanitizer
private
sanitization
:
DomSanitizer
// private cwService: _coursewareService,
// private cwService: _coursewareService,
// private resService: ResourceService
// private resService: ResourceService
)
{
)
{
this
.
uploading
=
false
;
this
.
uploading
=
false
;
this
.
videoFile
=
null
;
this
.
videoFile
=
null
;
this
.
uploadUrl
=
(
<
any
>
window
).
courseware
.
uploadUrl
();
this
.
uploadData
=
(
<
any
>
window
).
courseware
.
uploadData
();
window
[
'
air
'
].
getUploadCallback
=
(
url
,
data
)
=>
{
this
.
uploadUrl
=
url
;
this
.
uploadData
=
data
;
};
}
}
ngOnChanges
()
{
ngOnChanges
()
{
// if (!this.videoFile || this.showUploadBtn) {
// if (!this.videoFile || this.showUploadBtn) {
...
...
src/app/play/play.component.ts
View file @
3b8ffabe
...
@@ -633,20 +633,26 @@ export class PlayComponent implements OnInit, OnDestroy {
...
@@ -633,20 +633,26 @@ export class PlayComponent implements OnInit, OnDestroy {
curtainContral
(
status
,
callback
?){
curtainContral
(
status
,
callback
?){
let
all
=
[
"
Curtain-A
"
,
"
Curtain-B
"
,
"
Curtain-C
"
,
"
Curtain-D
"
]
let
all
=
[
"
Curtain-A
"
,
"
Curtain-B
"
,
"
Curtain-C
"
,
"
Curtain-D
"
]
let
_this
=
this
this
.
g_cartoon
.
playAudio
(
"
tongshenghuanhu
"
)
this
.
g_cartoon
.
playAudio
(
"
tongshenghuanhu
"
)
this
.
m_setTimeoutIDs
.
push
(
setTimeout
(()
=>
{
this
.
m_setTimeoutIDs
.
push
(
setTimeout
(()
=>
{
this
.
g_cartoon
.
playAudio
(
"
gusheng_kaitou
"
)
this
.
g_cartoon
.
playAudio
(
"
gusheng_kaitou
"
)
},
2000
))
},
2000
))
if
(
status
){
if
(
status
){
all
.
forEach
(
item
=>
{
all
.
forEach
(
item
=>
{
this
.
g_cartoon
.
getCartoonElement
(
item
).
open
()
_
this
.
g_cartoon
.
getCartoonElement
(
item
).
open
()
})
})
this
.
m_setTimeoutIDs
.
push
(
setTimeout
(()
=>
{
this
.
m_allDrums
.
forEach
(
function
(
item
,
index
){
_this
.
g_cartoon
.
getCartoonElement
(
item
).
show
(
index
)
})
},
4000
))
this
.
m_setTimeoutIDs
.
push
(
setTimeout
(()
=>
{
this
.
m_setTimeoutIDs
.
push
(
setTimeout
(()
=>
{
callback
&&
callback
()
callback
&&
callback
()
},
7000
))
},
7000
))
}
else
{
}
else
{
all
.
forEach
(
item
=>
{
all
.
forEach
(
item
=>
{
this
.
g_cartoon
.
getCartoonElement
(
item
).
close
()
_
this
.
g_cartoon
.
getCartoonElement
(
item
).
close
()
})
})
this
.
m_setTimeoutIDs
.
push
(
setTimeout
(()
=>
{
this
.
m_setTimeoutIDs
.
push
(
setTimeout
(()
=>
{
callback
&&
callback
()
callback
&&
callback
()
...
@@ -731,7 +737,6 @@ export class PlayComponent implements OnInit, OnDestroy {
...
@@ -731,7 +737,6 @@ export class PlayComponent implements OnInit, OnDestroy {
}
}
initDrum
(){
initDrum
(){
console
.
log
(
"
initDrum
"
)
if
(
this
.
g_formData
.
dataArray
.
length
==
0
){
if
(
this
.
g_formData
.
dataArray
.
length
==
0
){
return
return
}
}
...
@@ -872,12 +877,20 @@ export class PlayComponent implements OnInit, OnDestroy {
...
@@ -872,12 +877,20 @@ export class PlayComponent implements OnInit, OnDestroy {
element
.
isOpen
=
false
;
element
.
isOpen
=
false
;
this
.
subscribeMapDownEvent
(
element
.
id
,
()
=>
{
this
.
subscribeMapDownEvent
(
element
.
id
,
()
=>
{
if
(
!
this
.
m_startGame
||
element
.
isOpen
){
if
(
!
this
.
m_startGame
||
element
.
isOpen
){
if
(
element
.
isOpen
){
if
(
data
.
audio_url
){
this
.
g_cartoon
.
playAudio
(
data
.
audio_url
)
}
}
this
.
g_enableMapDown
=
true
;
this
.
g_enableMapDown
=
true
;
return
return
}
}
this
.
g_cartoon
.
playAudio
(
`gusheng_
${
index
+
1
}
`
)
this
.
g_cartoon
.
playAudio
(
`gusheng_
${
index
+
1
}
`
)
this
.
setRenderZIndex
(
element
.
ref
,
zIndexMap
.
drum
+
1
)
this
.
setRenderZIndex
(
element
.
ref
,
zIndexMap
.
drum
+
1
)
tweenChange
(
element
.
ref
,
{
scaleX
:
element
.
initScaleX
*
1.1
,
scaleY
:
element
.
initScaleY
*
1.1
},
0.2
,
()
=>
{
tweenChange
(
element
.
ref
,
{
scaleX
:
element
.
initScaleX
*
1.1
,
scaleY
:
element
.
initScaleY
*
1.1
},
0.2
,
()
=>
{
if
(
data
.
audio_url
){
this
.
g_cartoon
.
playAudio
(
data
.
audio_url
)
}
if
(
element
.
content
){
if
(
element
.
content
){
element
.
content
.
visible
=
true
;
element
.
content
.
visible
=
true
;
tweenChange
(
element
.
content
,
{
scaleX
:
element
.
content
.
initScaleX
,
scaleY
:
element
.
content
.
initScaleY
},
0.2
)
tweenChange
(
element
.
content
,
{
scaleX
:
element
.
content
.
initScaleX
,
scaleY
:
element
.
content
.
initScaleY
},
0.2
)
...
@@ -888,7 +901,21 @@ export class PlayComponent implements OnInit, OnDestroy {
...
@@ -888,7 +901,21 @@ export class PlayComponent implements OnInit, OnDestroy {
element
.
highlight
()
element
.
highlight
()
})
})
})
})
})
})
element
.
show
=
(
index
)
=>
{
this
.
m_setTimeoutIDs
.
push
(
setTimeout
(()
=>
{
this
.
setRenderZIndex
(
element
.
ref
,
zIndexMap
.
drum
+
1
)
tweenChange
(
element
.
ref
,
{
scaleX
:
element
.
initScaleX
*
1.05
,
scaleY
:
element
.
initScaleY
*
1.05
},
0.1
,
()
=>
{
this
.
m_setTimeoutIDs
.
push
(
setTimeout
(()
=>
{
tweenChange
(
element
.
ref
,
{
scaleX
:
element
.
initScaleX
,
scaleY
:
element
.
initScaleY
},
0.1
,
()
=>
{
this
.
setRenderZIndex
(
element
.
ref
,
zIndexMap
.
drum
)
})
},
200
))
})
},
500
*
index
))
}
return
element
return
element
}
}
...
@@ -900,7 +927,6 @@ export class PlayComponent implements OnInit, OnDestroy {
...
@@ -900,7 +927,6 @@ export class PlayComponent implements OnInit, OnDestroy {
drum
=
_this
.
g_cartoon
.
getCartoonElement
(
item
)
drum
=
_this
.
g_cartoon
.
getCartoonElement
(
item
)
drum
.
resetContent
(
_this
.
m_dataArrayNew
[
index
])
drum
.
resetContent
(
_this
.
m_dataArrayNew
[
index
])
})
})
console
.
log
(
this
.
g_cartoon
.
getAllCartoonElement
())
}
}
checkAllOpen
(){
checkAllOpen
(){
...
@@ -968,6 +994,36 @@ export class PlayComponent implements OnInit, OnDestroy {
...
@@ -968,6 +994,36 @@ export class PlayComponent implements OnInit, OnDestroy {
...
...
src/app/play/resources.js
View file @
3b8ffabe
...
@@ -32,10 +32,8 @@ const localImages = {
...
@@ -32,10 +32,8 @@ const localImages = {
'
boy_1
'
:
'
assets/play/boy_1.png
'
,
'
boy_1
'
:
'
assets/play/boy_1.png
'
,
'
btn_start
'
:
'
assets/play/btn_start.png
'
,
'
btn_start
'
:
'
assets/play/btn_start.png
'
,
'
card_bg
'
:
'
assets/play/card_bg.png
'
,
'
card_bg
'
:
'
assets/play/card_bg.png
'
,
'
creatJsonProfile
'
:
'
assets/play/creatJsonProfile.py
'
,
'
dengqiu1
'
:
'
assets/play/dengqiu1.png
'
,
'
dengqiu1
'
:
'
assets/play/dengqiu1.png
'
,
'
drum_highlight
'
:
'
assets/play/drum_highlight.png
'
,
'
drum_highlight
'
:
'
assets/play/drum_highlight.png
'
,
'
filename
'
:
'
assets/play/filename.txt
'
,
'
green
'
:
'
assets/play/green.png
'
,
'
green
'
:
'
assets/play/green.png
'
,
'
hand
'
:
'
assets/play/hand.png
'
,
'
hand
'
:
'
assets/play/hand.png
'
,
'
hand2
'
:
'
assets/play/hand2.png
'
,
'
hand2
'
:
'
assets/play/hand2.png
'
,
...
@@ -52,13 +50,10 @@ const localImages = {
...
@@ -52,13 +50,10 @@ const localImages = {
'
light4
'
:
'
assets/play/light4.png
'
,
'
light4
'
:
'
assets/play/light4.png
'
,
'
qiaoji1
'
:
'
assets/play/qiaoji1.png
'
,
'
qiaoji1
'
:
'
assets/play/qiaoji1.png
'
,
'
red
'
:
'
assets/play/red.png
'
,
'
red
'
:
'
assets/play/red.png
'
,
'
resizeImg
'
:
'
assets/play/resizeImg.py
'
,
'
restart
'
:
'
assets/play/restart.png
'
,
'
restart
'
:
'
assets/play/restart.png
'
,
'
reversalImg
'
:
'
assets/play/reversalImg.py
'
,
'
star
'
:
'
assets/play/star.png
'
,
'
star
'
:
'
assets/play/star.png
'
,
'
yellow
'
:
'
assets/play/yellow.png
'
,
'
yellow
'
:
'
assets/play/yellow.png
'
,
'
light1 (1)
'
:
'
assets/play/frame/light1 (1).png
'
,
'
light1 (1)
'
:
'
assets/play/frame/light1 (1).png
'
,
'
light1 (10)
'
:
'
assets/play/frame/light1 (10).png
'
,
'
light1 (10)
'
:
'
assets/play/frame/light1 (10).png
'
,
'
light1 (11)
'
:
'
assets/play/frame/light1 (11).png
'
,
'
light1 (11)
'
:
'
assets/play/frame/light1 (11).png
'
,
...
...
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