|
@@ -2,15 +2,15 @@
|
|
|
<view class="content">
|
|
|
<view class="uni-margin-wrap">
|
|
|
<swiper class="swiper" circular :indicator-dots="true" indicator-color="#DE868F" indicator-active-color="#fff"
|
|
|
- :autoplay="true" :interval="1000" :duration="500">
|
|
|
+ :autoplay="true" :interval="5000" :duration="1000">
|
|
|
<swiper-item>
|
|
|
- <view class="swiper-item">功能介绍1</view>
|
|
|
+ <view class="swiper-item"><text>创建步骤1<br>填写视频名称</text></view>
|
|
|
</swiper-item>
|
|
|
<swiper-item>
|
|
|
- <view class="swiper-item">功能介绍2</view>
|
|
|
+ <view class="swiper-item">创建步骤2<br>选择个人形象照片,最好是正面照</view>
|
|
|
</swiper-item>
|
|
|
<swiper-item>
|
|
|
- <view class="swiper-item">功能介绍3</view>
|
|
|
+ <view class="swiper-item">创建步骤3<br>选择生成视频内容的方式:<br>若选择文字输入,则输入口播的文字内容及使用音色;<br>若选择语音录入则点击开始录音,录音结束后再点击停止录音,可在下方播放容器试听录音内容;<br>若选择音频选择,则选择本机的音频文件</view>
|
|
|
</swiper-item>
|
|
|
</swiper>
|
|
|
</view>
|
|
@@ -143,11 +143,20 @@
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
|
+ // 选择音频文件
|
|
|
chooseFile() {
|
|
|
+ if(!this.imagePath) {
|
|
|
+ uni.showToast({
|
|
|
+ title: '请先选择形象照片',
|
|
|
+ icon: 'none'
|
|
|
+ });
|
|
|
+ return
|
|
|
+ }
|
|
|
uni.navigateTo({
|
|
|
url: "/pages/root-filelist/root-filelist",
|
|
|
});
|
|
|
},
|
|
|
+ // 选择图片文件
|
|
|
async chooseImage() {
|
|
|
const that = this;
|
|
|
uni.chooseImage({
|
|
@@ -166,15 +175,7 @@
|
|
|
}
|
|
|
});
|
|
|
},
|
|
|
- radioChange(evt) {
|
|
|
- for (let i = 0; i < this.videoContent.length; i++) {
|
|
|
- if (this.videoContent[i].value === evt.detail.value) {
|
|
|
- this.current = i;
|
|
|
- break;
|
|
|
- }
|
|
|
- }
|
|
|
- },
|
|
|
-
|
|
|
+ // 开始/停止录音
|
|
|
toggleRecording() {
|
|
|
if (this.isRecording) {
|
|
|
this.recorderManager.stop();
|
|
@@ -195,6 +196,7 @@
|
|
|
this.isRecording = true;
|
|
|
}
|
|
|
},
|
|
|
+ // 上传形象照片
|
|
|
uploadImagePath() {
|
|
|
let data = {
|
|
|
file: this.imagePath
|
|
@@ -203,6 +205,7 @@
|
|
|
this.personPath = response.data.url
|
|
|
})
|
|
|
},
|
|
|
+ // 上传音频文件
|
|
|
uploadAudioPath(url) {
|
|
|
let data = {
|
|
|
file: url
|
|
@@ -211,6 +214,7 @@
|
|
|
this.personAudio = response.data.url
|
|
|
})
|
|
|
},
|
|
|
+ // 点击生成视频,跳转生成页面
|
|
|
jumpToList() {
|
|
|
let missingFields = [];
|
|
|
if (!this.videoName.trim()) {
|
|
@@ -277,16 +281,16 @@
|
|
|
}
|
|
|
|
|
|
.swiper {
|
|
|
- height: 300rpx;
|
|
|
+ height: 350rpx;
|
|
|
}
|
|
|
|
|
|
.swiper-item {
|
|
|
display: block;
|
|
|
- height: 300rpx;
|
|
|
- line-height: 300rpx;
|
|
|
+ height: 350rpx;
|
|
|
text-align: center;
|
|
|
background-color: #BD3124;
|
|
|
color: #fff;
|
|
|
+ padding-top:30px;
|
|
|
}
|
|
|
|
|
|
.form-area {
|