提交 8764f496 作者: 方治民

合并分支 'main' 到 'dev'

Main

查看合并请求 digital-agri/agri-app!2
{ {
"name": "数字农服", "name": "数字农服",
"version": "1.0.25", "version": "1.0.27",
"description": "数字农服", "description": "数字农服",
"keywords": [ "keywords": [
"app", "app",
......
...@@ -83,7 +83,9 @@ ...@@ -83,7 +83,9 @@
} }
if (button.type === 'button') { if (button.type === 'button') {
button.handle?.({ type: 'click', name: button.name }) button.handle?.({ type: 'click', name: button.name, button })
} else if (button.type === 'toggle') {
button.handle?.({ type: 'toggle', name: button.name, button })
} else if (button.type === 'select') { } else if (button.type === 'select') {
// 打开 Select 组件 // 打开 Select 组件
model.selectPopup.title = button.name model.selectPopup.title = button.name
......
...@@ -2,16 +2,19 @@ import type { BasicWidgetInstance, BasicWidgetProps } from '../../utils' ...@@ -2,16 +2,19 @@ import type { BasicWidgetInstance, BasicWidgetProps } from '../../utils'
export interface ToolBoxButtonHandleEvent { export interface ToolBoxButtonHandleEvent {
// 事件类型 // 事件类型
type: 'click' | 'change' type: 'click' | 'change' | 'toggle'
// 事件名称 // 事件名称
name: string name: string
// 事件值 // 事件值
value?: string | string[] | { text: string; value: string } | { text: string; value: string }[] value?: string | string[] | { text: string; value: string } | { text: string; value: string }[]
// 按钮本身
button?: ToolBoxButton
} }
export interface ToolBoxButton { export interface ToolBoxButton {
// 按钮类型 // 按钮类型
type: 'select' | 'button' | 'filter' type: 'select' | 'button' | 'filter' | 'toggle'
// 按钮名称 // 按钮名称
name: string name: string
// 按钮图标 // 按钮图标
......
...@@ -2,8 +2,8 @@ ...@@ -2,8 +2,8 @@
"name": "数字农服", "name": "数字农服",
"appid": "__UNI__FD09823", "appid": "__UNI__FD09823",
"description": "数字农服 APP", "description": "数字农服 APP",
"versionName": "1.0.25", "versionName": "1.0.27",
"versionCode": 10025, "versionCode": 10027,
"transformPx": false, "transformPx": false,
"locale": "zh-Hans", "locale": "zh-Hans",
"vueVersion": "3", "vueVersion": "3",
......
...@@ -592,7 +592,7 @@ ...@@ -592,7 +592,7 @@
{ {
"path": "pages/nongchang/detail/index", "path": "pages/nongchang/detail/index",
"style": { "style": {
"navigationBarTitleText": "", "navigationBarTitleText": "农场",
"enablePullDownRefresh": false, "enablePullDownRefresh": false,
"navigationBarBackgroundColor": "#5DB66F", "navigationBarBackgroundColor": "#5DB66F",
"navigationBarTextStyle": "white", "navigationBarTextStyle": "white",
......
...@@ -11,7 +11,9 @@ ...@@ -11,7 +11,9 @@
import * as AreaDict from '@/utils/dict/area' import * as AreaDict from '@/utils/dict/area'
import { getList } from '@/api/model/news' import { getList } from '@/api/model/news'
import { getList as getVideoList } from '@/api/model/knowledgeVideo' import { getList as getVideoList } from '@/api/model/knowledgeVideo'
import { useUserStore } from '@/store/modules/user'
const userStore = useUserStore()
const dictStore = useDictStore() const dictStore = useDictStore()
const model = reactive({ const model = reactive({
// 湖南省人民政府 // 湖南省人民政府
...@@ -487,6 +489,14 @@ ...@@ -487,6 +489,14 @@
}) })
} }
function openAITools() {
uni.navigateTo({
animationType: 'slide-in-bottom',
// 最新版 SDK Webview 嵌入版本,支持绑定用户 ID,支持自定义样式等
url: `/pages/common/chat/webview?token=&userId=${userStore.getUserInfo?.id}`,
})
}
onHide(() => { onHide(() => {
// 停止所有其他视频的播放(只暂停,不重置位置) // 停止所有其他视频的播放(只暂停,不重置位置)
pageData.agricultureClass.videoList.forEach((_, index) => { pageData.agricultureClass.videoList.forEach((_, index) => {
...@@ -511,6 +521,12 @@ ...@@ -511,6 +521,12 @@
</view> </view>
<text class="text" style="font-family: alimamashuheiti">湖南省</text> <text class="text" style="font-family: alimamashuheiti">湖南省</text>
</view> </view>
<!-- ai助手 -->
<FuiMovableView top="650" right="10" zIndex="99999">
<view class="h-80rpx flex items-center" @click="openAITools">
<image class="w-117rpx h-118rpx" src="/static/images/codefun/ai.png" alt="" />
</view>
</FuiMovableView>
<view class="codefun-flex-col codefun-relative group_3"> <view class="codefun-flex-col codefun-relative group_3">
<view class="codefun-flex-col"> <view class="codefun-flex-col">
<view class="codefun-flex-col codefun-self-stretch group_4"> <view class="codefun-flex-col codefun-self-stretch group_4">
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论