Commit f80f4ef9 authored by limingzhe's avatar limingzhe

feat: 增加 隐藏跳过按钮

parent 3d9c327e
...@@ -60,6 +60,10 @@ export default class SceneComponent extends MyCocosSceneComponent { ...@@ -60,6 +60,10 @@ export default class SceneComponent extends MyCocosSceneComponent {
this.videoPlayEnd(); this.videoPlayEnd();
}) })
if (this.data.isJump != '1') {
jumpBtn.active = false;
}
const playBtn = cc.find('Canvas/btn_play'); const playBtn = cc.find('Canvas/btn_play');
playBtn.on('click', () => { playBtn.on('click', () => {
......
export const defaultData = {"video_url":"http://staging-teach.cdn.ireadabc.com/31581cee2192077e91982eeb59d5ea5e.mp4"} export const defaultData = {"video_url":"http://staging-teach.cdn.ireadabc.com/31581cee2192077e91982eeb59d5ea5e.mp4","isJump":"0"}
\ No newline at end of file \ No newline at end of file
...@@ -11,6 +11,14 @@ ...@@ -11,6 +11,14 @@
[videoUrl]="item.video_url"></app-upload-video> [videoUrl]="item.video_url"></app-upload-video>
</div> </div>
<div style="padding: 20px">
<nz-radio-group [ngModel]="item.isJump" (ngModelChange)="onRadioChange($event)">
<label>跳过: </label>
<label nz-radio nzValue="1"></label>
<label nz-radio nzValue="0"></label>
</nz-radio-group>
</div>
</div> </div>
......
...@@ -59,11 +59,17 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy { ...@@ -59,11 +59,17 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
} }
init() { init() {
if (!this.item.isJump) {
this.item.isJump = '0';
}
} }
onRadioChange(e) {
console.log('e: ', e);
this.item.isJump = e;
this.save();
}
onVideoUploadSuccess(e) { onVideoUploadSuccess(e) {
console.log('e: ', e); console.log('e: ', e);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment