2023-11-20-1
This commit is contained in:
@@ -310,8 +310,8 @@ export default defineComponent({
|
||||
// })
|
||||
// this.store.commit("addGenerateFils", this.fileList);
|
||||
this.token = getCookie("token") || "";
|
||||
this.isTest = getCookie("isTest");
|
||||
|
||||
let isTest:any = getCookie('isTest')
|
||||
this.isTest =JSON.parse(isTest)|| ''
|
||||
this.uploadUrl = getUploadUrl();
|
||||
this.workspace = this.store.state.Workspace.workspace
|
||||
},
|
||||
@@ -460,7 +460,7 @@ export default defineComponent({
|
||||
this.inputTime = setTimeout(()=>{
|
||||
// let num1 = ((input as HTMLInputElement).value.match(/ /g) || []).length
|
||||
// let num2 = (input as HTMLInputElement).value.split(' ').length
|
||||
if(this.searchPictureName.split(/\s+/).length > 75){
|
||||
if(this.searchPictureName?.split(/\s+/).length > 75){
|
||||
this.inputShow = true
|
||||
}else{
|
||||
this.inputShow = false
|
||||
|
||||
@@ -6,7 +6,8 @@
|
||||
<div class="header_user_icon"></div>
|
||||
<!-- <div class="header_icon icon iconfont icon-touxiang3"></div> -->
|
||||
<div class="header_user_content">
|
||||
<div class="username"><span>/</span> {{$t('Header.hello')}}@{{ userInfo?.userName }}</div>
|
||||
<div v-if="isTest" class="username"><span>/</span> {{$t('Header.hello')}}@{{ $t('isTest.userName') }}</div>
|
||||
<div v-else class="username"><span>/</span> {{$t('Header.hello')}}@{{ userInfo?.userName }}</div>
|
||||
<div
|
||||
:class="[
|
||||
'icon',
|
||||
@@ -146,7 +147,7 @@
|
||||
</div>
|
||||
</template>
|
||||
<script >
|
||||
import { defineComponent, createVNode } from "vue";
|
||||
import { defineComponent, createVNode, ref } from "vue";
|
||||
import { isEmail } from "@/tool/util";
|
||||
import { setCookie, getCookie, WriteCookie } from "@/tool/cookie";
|
||||
import VerificationCodeInput from "@/component/LoginPage/verificationCodeInput.vue";
|
||||
@@ -165,10 +166,12 @@ export default defineComponent({
|
||||
const store = useStore();
|
||||
const {t} = useI18n()
|
||||
const {locale} = useI18n()
|
||||
let isTest = ref()
|
||||
return {
|
||||
store,
|
||||
t,
|
||||
locale
|
||||
locale,
|
||||
isTest,
|
||||
}
|
||||
},
|
||||
data() {
|
||||
@@ -201,6 +204,9 @@ export default defineComponent({
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
let isTest = getCookie('isTest')
|
||||
this.isTest =JSON.parse(isTest)|| ''
|
||||
|
||||
this.userInfo = JSON.parse(getCookie("userInfo"));
|
||||
if (!this.userInfo) {
|
||||
this.$router.replace("/login");
|
||||
|
||||
@@ -314,6 +314,7 @@ export default defineComponent({
|
||||
if(item.id == v.id){
|
||||
item.id_ = v.id_?v.id_:GO.id++
|
||||
item.checked = true
|
||||
item.pin = v.pin
|
||||
}
|
||||
})
|
||||
}else{
|
||||
|
||||
@@ -221,7 +221,8 @@ export default defineComponent({
|
||||
},
|
||||
mounted(){
|
||||
this.token = getCookie('token') || ''
|
||||
this.isTest = getCookie('isTest') || ''
|
||||
let isTest:any = getCookie('isTest')
|
||||
this.isTest =JSON.parse(isTest)|| ''
|
||||
this.uploadUrl = getUploadUrl()
|
||||
},
|
||||
methods:{
|
||||
@@ -494,7 +495,7 @@ export default defineComponent({
|
||||
ifMaximumLength(){
|
||||
clearTimeout(this.inputTime)
|
||||
this.inputTime = setTimeout(()=>{
|
||||
if(this.captionGeneration.split(/\s+/).length > 75){
|
||||
if(this.captionGeneration?.split(/\s+/).length > 75){
|
||||
this.inputShow = true
|
||||
}else{
|
||||
this.inputShow = false
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
<div class="robot_text">
|
||||
<span>
|
||||
{{item.str}}
|
||||
<a v-if="item.src" :href="item.src" target="_blank"><i class="fi fi-br-link-alt"></i></a>
|
||||
</span>
|
||||
<div class="robot_img" :class="[item.img ?'img':'']">
|
||||
<div class="robot_img_item" v-for="imgItem,imgIndex in item.img">
|
||||
@@ -69,6 +70,7 @@ export default defineComponent({
|
||||
const userInfo:any = {}
|
||||
let bloodBars:any = ref(0)
|
||||
let {t} = useI18n()
|
||||
let isTest = ref()
|
||||
return {
|
||||
robotTop,
|
||||
robotInput,
|
||||
@@ -81,6 +83,7 @@ export default defineComponent({
|
||||
userInfo,
|
||||
bloodBars,
|
||||
t,
|
||||
isTest,
|
||||
};
|
||||
},
|
||||
data() {
|
||||
@@ -90,6 +93,8 @@ export default defineComponent({
|
||||
mounted() {
|
||||
this.textScroll()
|
||||
let userInfo:any = getCookie("userInfo")
|
||||
let isTest:any = getCookie('isTest')
|
||||
this.isTest =JSON.parse(isTest)|| ''
|
||||
this.userInfo = JSON.parse(userInfo);
|
||||
if (sessionStorage.getItem("record") == null) {
|
||||
this.record = []
|
||||
@@ -196,6 +201,20 @@ export default defineComponent({
|
||||
// }
|
||||
},
|
||||
}
|
||||
if(this.isTest){//试用用户禁止使用
|
||||
// message.warning(
|
||||
// this.t('isTest.available')
|
||||
// );
|
||||
this.record.push({
|
||||
state:1,
|
||||
str:this.t('isTest.src'),
|
||||
src:'https://code-create.com.hk/aida/'
|
||||
})
|
||||
this.createTimer()
|
||||
this.textScroll()
|
||||
this.chatCentent = ""
|
||||
return
|
||||
}
|
||||
Https.axiosPost(Https.httpUrls.chatStreamTest, data).then(
|
||||
// Https.axiosPost(Https.httpUrls.pythonChatStream, data,interaction).then(
|
||||
(rv) => {
|
||||
|
||||
@@ -474,7 +474,7 @@ export default defineComponent({
|
||||
// let num2 = (input as HTMLInputElement).value.split(' ').length
|
||||
console.log(this.captionGeneration);
|
||||
|
||||
if(this.captionGeneration.split(/\s+/).length > 75){
|
||||
if(this.captionGeneration?.split(/\s+/).length > 75){
|
||||
this.inputShow = true
|
||||
}else{
|
||||
this.inputShow = false
|
||||
|
||||
Reference in New Issue
Block a user