对话记录
This commit is contained in:
		@@ -103,9 +103,7 @@ export default {
 | 
			
		||||
    ...mapState(['user', 'token']),
 | 
			
		||||
  },
 | 
			
		||||
  onLoad() {
 | 
			
		||||
    if(this.token) {
 | 
			
		||||
      this.getHistoryList()
 | 
			
		||||
    }
 | 
			
		||||
    this.getHistoryList()
 | 
			
		||||
    recorderManager.onStop((res)=> {
 | 
			
		||||
      this.upLoad(res.tempFilePath)
 | 
			
		||||
		});
 | 
			
		||||
@@ -187,6 +185,9 @@ export default {
 | 
			
		||||
      })
 | 
			
		||||
    },
 | 
			
		||||
    sendMsg() {
 | 
			
		||||
      if(!this.token) {
 | 
			
		||||
        return this.$u.toast("请在'个人中心'登录")
 | 
			
		||||
      }
 | 
			
		||||
      this.$loading()
 | 
			
		||||
      this.$instance.post("/app/appaicopilotinfo/add", {content: this.content, appType: 0, areaId: this.areaId}).then(res => {
 | 
			
		||||
        if(res.code == 0) {
 | 
			
		||||
@@ -204,6 +205,9 @@ export default {
 | 
			
		||||
      })
 | 
			
		||||
    },
 | 
			
		||||
    sendVoice() {
 | 
			
		||||
      if(!this.token) {
 | 
			
		||||
        return this.$u.toast("请在'个人中心'登录")
 | 
			
		||||
      }
 | 
			
		||||
      this.$loading()
 | 
			
		||||
      this.$instance.post("/app/appaicopilotinfo/add", {sdkFileUrl: this.voiceUrl, fileId: this.voiceId, appType: 0}).then(res => {
 | 
			
		||||
        if(res.code == 0) {
 | 
			
		||||
@@ -225,6 +229,9 @@ export default {
 | 
			
		||||
      })
 | 
			
		||||
    },
 | 
			
		||||
    getHistoryList() {
 | 
			
		||||
      if(!this.token) {
 | 
			
		||||
        return this.$u.toast("请在'个人中心'登录")
 | 
			
		||||
      }
 | 
			
		||||
      this.$loading()
 | 
			
		||||
      this.$instance.post(`/app/appaicopilotinfo/list?current=${this.current}&size=10`).then(res => {
 | 
			
		||||
        if(res.code == 0 && res.data.records.length) {
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user