优化
This commit is contained in:
@@ -157,6 +157,7 @@
|
||||
},
|
||||
|
||||
onLongtap () {
|
||||
this.time = 60
|
||||
if (!this.equipmentList.length) {
|
||||
return this.$u.toast('请选择播发设备')
|
||||
}
|
||||
@@ -174,7 +175,6 @@
|
||||
},
|
||||
|
||||
record () {
|
||||
this.time = 60
|
||||
this.recorder = Recorder({
|
||||
type: 'mp3',
|
||||
sampleRate: 16000,
|
||||
@@ -191,11 +191,13 @@
|
||||
},
|
||||
|
||||
timing () {
|
||||
this.time = this.time - 1
|
||||
|
||||
if (this.time === 0) {
|
||||
this.stop()
|
||||
|
||||
return false
|
||||
}
|
||||
this.time = this.time - 1
|
||||
|
||||
this.timingTimeout = setTimeout(() => {
|
||||
this.timing()
|
||||
}, 1000)
|
||||
@@ -275,7 +277,6 @@
|
||||
this.isShow = false
|
||||
})
|
||||
|
||||
this.time = 60
|
||||
console.log(blob, (window.URL || webkitURL).createObjectURL(blob), '时长:' + duration + 'ms')
|
||||
}, msg => {
|
||||
console.log('录音失败:' + msg)
|
||||
|
||||
Reference in New Issue
Block a user