Feat(云灵AI):县域AI和平台AI逻辑区分
This commit is contained in:
@@ -13,12 +13,19 @@
|
||||
import {
|
||||
getAiSystemInfoSetting
|
||||
} from '@/api/public'
|
||||
import {
|
||||
getCountyAiDetail
|
||||
} from '@/api/chat/index'
|
||||
export default {
|
||||
name: 'AiEntrance',
|
||||
props: {
|
||||
cityName: {
|
||||
type: String,
|
||||
default: ''
|
||||
},
|
||||
countyId: {
|
||||
type: String,
|
||||
default: ''
|
||||
}
|
||||
},
|
||||
data() {
|
||||
@@ -33,6 +40,19 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
init() {
|
||||
if (this.countyId) {
|
||||
getCountyAiDetail({
|
||||
countyId: this.countyId
|
||||
}).then(res => {
|
||||
const { success, data } = res
|
||||
if (success) {
|
||||
const aiImage = data.aiImage || ''
|
||||
this.settingInfo.mainImage = aiImage
|
||||
this.showImg = !!aiImage
|
||||
}
|
||||
})
|
||||
return
|
||||
}
|
||||
getAiSystemInfoSetting().then(res => {
|
||||
const { success, data } = res
|
||||
if (success) {
|
||||
@@ -43,7 +63,7 @@ export default {
|
||||
},
|
||||
enterAiChat() {
|
||||
uni.navigateTo({
|
||||
url: '/aiChat/views/index?click=1&cityName=' + (this.cityName || this.localCityName)
|
||||
url: '/aiChat/views/index?click=1&cityName=' + (this.cityName || this.localCityName) + '&countyId=' + (this.countyId || '')
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user