刘琳琳 2 days ago
parent
commit
50b1c49c73

+ 7 - 1
.mini-ide/compileMode.json

@@ -5,6 +5,12 @@
       "page": "pages/index/index",
       "launchMode": "common",
       "pageQuery": ""
+    },
+    {
+      "title": "pages/digitalHumans/digitalHumans",
+      "page": "pages/digitalHumans/digitalHumans",
+      "launchMode": "common",
+      "pageQuery": ""
     }
   ]
-}
+}

+ 2 - 1
app.json

@@ -3,6 +3,7 @@
   "pages": [
     "pages/searchIndex/index",
     "pages/index/index",
+    "pages/digitalHumans/digitalHumans",
     "pages/setInit/setInit",
     "pages/setOneVN/setOneVN",
     "pages/setAuth/setAuth",
@@ -52,4 +53,4 @@
     "van-rate": "vant-aliapp/dist/dist/rate/index",
     "add-car-number": "./components/addCarNumber"
   }
-}
+}

+ 0 - 0
pages/digitalHumans/digitalHumans.acss


+ 5 - 0
pages/digitalHumans/digitalHumans.axml

@@ -0,0 +1,5 @@
+<view>
+      <web-view src="https://www.reawing.com/guide/introduction.html#%E6%9C%AC%E5%9C%B0%E8%BF%90%E8%A1%8C%E6%96%87%E6%A1%A3" />
+
+  <!-- <web-view src="C:/Users/22711/Pictures/Screenshots/屏幕截图 2024-07-08 102839.png" /> -->
+</view>

+ 20 - 0
pages/digitalHumans/digitalHumans.js

@@ -0,0 +1,20 @@
+const app = getApp()
+
+Page({
+  data: {
+
+  },
+  onLoad(query) {
+  },
+  onReady() {
+    // 页面加载完成
+  },
+  onShow() {
+  },
+  onHide() {
+    // 页面隐藏
+  },
+  onUnload() {
+    // 页面被关闭
+  },
+});

+ 4 - 0
pages/digitalHumans/digitalHumans.json

@@ -0,0 +1,4 @@
+{
+  "component": false,
+  "styleIsolation": "apply-shared"
+}

+ 12 - 0
pages/searchIndex/index.axml

@@ -24,6 +24,18 @@
       data-item="{{menuItem}}"
       data-id="{{menuItem.id}}"
     >
+    <!--<block a:if="{{ menuItem.id ==  -1}}">
+      <container title="webview">
+      </container>
+      <view class="content">
+        <ant-button
+          type="primary"
+          onTap="goToWebView"
+        >
+          location
+        </ant-button>
+        </view>
+    </block>-->
       <block a:if="{{ menuItem.id ==  0}}">
         <container title="系统信息">
           <view slot="headerRight" onTap="changeMsg" style="font-size: 16px;">

+ 100 - 0
pages/searchIndex/index.js

@@ -69,6 +69,11 @@ Page({
 
     activeTab: 0,
     menuList: [
+      /*{
+        name: 'web-view',
+        id: -1,
+        ampe_params: []
+      },*/
       {
         name: '系统信息',
         id: 0,
@@ -822,6 +827,74 @@ Page({
           },
         ]
       },
+      {
+        name: '扬声器',
+        id: 20,
+        ampe_params: [
+          {
+            name: '获取扬声器音量',
+            aromeCode: "",
+            number: "R1",
+            initParams: {
+              "action": "loudspeaker",
+              "event": "get",
+              "taskId": "R1",
+              "params": {
+
+              }
+            }
+          }, {
+            name: '设置扬声器音量',
+            aromeCode: "",
+            number: "R1",
+            initParams: {
+              "action": "loudspeaker",
+              "event": "set",
+              "taskId": "R1",
+              "params": {
+                "volume": "0.95"
+              }
+            }
+          }, {
+            name: '获取缓存文件列表',
+            aromeCode: "",
+            number: "z1",
+            initParams: {
+              "action": "storage",
+              "event": "get",
+              "taskId": "z1",
+              "params": {}
+            }
+          }, {
+            name: '缓存文件',
+            aromeCode: "",
+            number: "z2",
+            initParams: {
+              "action": "storage",
+              "event": "set",
+              "taskId": "z2",
+              "params": {
+                fileName: "夏伟浩.mp4",
+                fileUrl: "https://wallpaper-static.cheetahfun.com/wallpaper/sites/dynamics/vm5.mp4"
+              }
+            }
+          }, {
+            name: '移除缓存文件',
+            aromeCode: "",
+            number: "z3",
+            initParams: {
+              "action": "storage",
+              "event": "remove",
+              "taskId": "z3",
+              "params": {
+                fileName: "夏伟浩",
+                fileType: ".mp4",
+                path: "/storage/emulated/0/Download/夏伟浩.mp4"
+              }
+            }
+          },
+        ]
+      },
       // {
       //   name: '附件上传',
       //   id: 19,
@@ -1132,6 +1205,33 @@ Page({
           });
         }*/
   },
+  goToWebView() {
+    // my.getLocation({
+    //   type: 1, // 获取经纬度和省市区县数据
+    //   success: (res) => {
+    //     console.log(res);
+    //     my.showModal({
+    //       title: '提示',
+    //       content: res && JSON.stringify(res),
+    //       success: function(res) {
+    //         console.log(res);
+    //       },
+    //       fail: function(err) {
+    //         console.log(err);
+    //       }
+    //     });
+    //   },
+    //   fail: (error) => {
+    //     console.error('定位失败: ', JSON.stringify(error));
+    //   },
+    //   complete: (res) => {
+    //     console.log(res);
+    //   },
+    // });
+    my.navigateTo({
+      url: '/pages/digitalHumans/digitalHumans'
+    })
+  },
   onReady() {
     // 页面加载完成
   },