Explorar o código

GPT工具:文字題按鈕權益,每次打開工具清空答案

Louise lin hai 1 ano
pai
achega
e76f4e6077

+ 2 - 2
HiTeachCC/ClientApp/src/components/Chart/OptionView.vue

@@ -77,7 +77,7 @@
         <div :title="$t('board.optionView.翻牌')" class="listicon AnswerShow" v-if="currentIRS() == 'irsImmediately'" @click="listbtn('default')"><svg-icon icon-class="flop" /></div>
         <div :title="$t('board.optionView.長條圖')" v-show="currentIRS() == 'irsImmediately'" @click="listbtn('bar')" :class="['listicon', current === 'bar' ? 'clickicon' : '']"><svg-icon icon-class="barchart" /></div>
         <div :title="$t('board.optionView.餅圖')" v-show="currentIRS() == 'irsImmediately'" @click="listbtn('pie')" :class="['listicon', current === 'pie' ? 'clickicon' : '']"><svg-icon icon-class="Piechart" /></div>
-        <div title="gpt" class="listicon" style="line-height: 28px" v-if="currentIRS() == 'irsText' && this.$store.state.currentState == 'irsTextEnd' && isAuthAccount() != 0 && isAuthOpenAIAccount()&&!isAuthOnlyPureScan()" @click="triggerGPTByOpenBox()"><strong style="font-size: 12px">Gpt</strong></div>
+        <div title="gpt" class="listicon" style="line-height: 28px" v-if="currentIRS() == 'irsText' && this.$store.state.currentState == 'irsTextEnd' && isAuthOpenAIAccount()" @click="triggerGPTByOpenBox()"><strong style="font-size: 12px">Gpt</strong></div>
         <div :title="$t('board.optionView.文字雲')" class="listicon" v-if="currentIRS() == 'irsText' && this.$store.state.currentState == 'irsTextEnd' && isAuthAccount() != 0 && isAuthWordCloud()" @click="triggerWordCloud()"><svg-icon icon-class="word-cloud" /></div>
         <div :title="$t('board.optionView.貼回舞台')" class="listicon" v-if="status == 'cloud' && this.$store.state.currentState == 'irsTextEnd'" @click="requestWordCloudImg()"><svg-icon icon-class="HTPaste" /></div>
         <div :title="$t('board.optionView.統計翻牌自動結束')" v-if="status !== 'cloud' && status !== 'GPT'" class="live-switch"><i-switch :title="$t('board.optionView.統計翻牌自動結束')" v-model="autoOff" /></div>
@@ -1419,7 +1419,7 @@ export default {
         }
       });
       this.$parent.$parent.$parent.$refs.gptBox.currentText = allText
-
+      this.$parent.$parent.$parent.$refs.gptBox.currentGPTAns=''
       this.$parent.$parent.$parent.showGptBox = true
 
     },

+ 2 - 0
HiTeachCC/ClientApp/src/views/Board.vue

@@ -7330,10 +7330,12 @@ export default {
       }
     },
     openGptBox(){
+      
       this.showGptBox =true
       this.$store.state.mqtt.mqttIoTData.isGpt=1
       this.$store.dispatch('mqtt/saveMqttIoTsessionStorage')
       this.$refs.gptBox.currentText = this.currentObjMenuCopyText
+      this.$refs.gptBox.currentGPTAns=''
       this.showObjMenu = false
 
       // const alreadyHaveContaner = document.querySelector('.chat-gpt-container')