Explorar el Código

```
feat: 新增加油功能模块

- 添加加油功能子包配置,包含commonTab和webView两个页面
- 在首页导航栏中启用加油功能入口,设置对应页面路由名称
- 配置加油页面的tabbar显示逻辑,允许未登录访问
- 更新开发环境API地址配置,启用HTTPS接口
- 修复manifest.json文件格式问题
- 生成加油功能相关页面类型定义
```

zouzexu hace 9 horas
padre
commit
cae1ce8bea

+ 2 - 2
src/config/index.ts

@@ -7,13 +7,13 @@ const mapEnvVersion = {
   // develop: 'http://192.168.0.157:8080',
   // develop: 'http://192.168.1.253:8080',
   // develop: 'http://192.168.0.19:8080',
-  develop: 'http://192.168.0.217:8080', // 黄
+  // develop: 'http://192.168.0.217:8080', // 黄
   // develop: 'http://192.168.1.89:8080', // 田
   // develop: 'http://192.168.0.11:8080', // 王
   // develop: 'http://74949mkfh190.vicp.fun', // 付
   // develop: 'http://47.109.84.152:8081',
   // develop: 'https://5ed0f7cc.r9.vip.cpolar.cn',
-  // develop: 'https://smqjh.api.zswlgz.com',
+  develop: 'https://smqjh.api.zswlgz.com',
   /**
    * 体验版
    */

+ 21 - 0
src/pages.json

@@ -568,6 +568,27 @@
           }
         }
       ]
+    },
+    {
+      "root": "subPack-refueling",
+      "pages": [
+        {
+          "path": "commonTab/index",
+          "name": "refueling-tabbar",
+          "islogin": false,
+          "style": {
+            "navigationBarTitleText": "加油"
+          }
+        },
+        {
+          "path": "webView/index",
+          "name": "refueling-webview",
+          "islogin": false,
+          "style": {
+            "navigationBarTitleText": "支付"
+          }
+        }
+      ]
     }
   ]
 }

+ 1 - 1
src/pages/index/index.vue

@@ -60,7 +60,7 @@ const navList = computed(() => {
     { icon: `${StaticUrl}/smqjh-sp.png`, title: '电影演出', name: 'film-index', show: true },
     { icon: `${StaticUrl}/smqjh-vip.png`, title: '视频权益', name: 'video-rights-tabbar', show: true },
     { icon: `${StaticUrl}/smqjh-diancan.png`, title: '大牌点餐', name: '', show: !isOnlineAudit.value },
-    { icon: `${StaticUrl}/smqjh-jiayou.png`, title: '加油', name: '', show: !isOnlineAudit.value },
+    { icon: `${StaticUrl}/smqjh-jiayou.png`, title: '加油', name: 'refueling-tabbar', show: true },
     { icon: `${StaticUrl}/smqjh-jiudian.png`, title: '酒店民宿', name: '', show: !isOnlineAudit.value },
     { icon: `${StaticUrl}/smqjh-daijia.png`, title: '代驾', name: '', show: !isOnlineAudit.value },
     { icon: `${StaticUrl}/smqjh-djk.png`, title: '大健康', name: 'djk-homeTabbar', show: true },

+ 26 - 0
src/subPack-refueling/commonTab/index.vue

@@ -0,0 +1,26 @@
+<script setup lang="ts">
+import router from '@/router'
+
+definePage({
+  name: 'refueling-tabbar',
+  islogin: false,
+  style: {
+    navigationBarTitleText: '加油',
+  },
+})
+
+function refuelingPay() {
+  console.log('触发跳转')
+  router.push({ name: 'refueling-webview' })
+}
+</script>
+
+<template>
+  <view class="">
+    <wd-button @click="refuelingPay">
+      加油充值
+    </wd-button>
+  </view>
+</template>
+
+<style lang="scss" scoped></style>

+ 18 - 0
src/subPack-refueling/webView/index.vue

@@ -0,0 +1,18 @@
+<script setup lang="ts">
+definePage({
+  name: 'refueling-webview',
+  islogin: false,
+  style: {
+    navigationBarTitleText: '支付',
+  },
+})
+const url = ref('https://static.am.xiaojukeji.com/cf-terminal/oil/thanos-fe-oil/pages/open-energy-h5-pay/index.html?orderId=3521815090950710849&tradeId=20260130e21328dee081108086896a3c4e630e9926408709&redirectUrl=')
+</script>
+
+<template>
+  <view class="">
+    <web-view :src="url" />
+  </view>
+</template>
+
+<style lang="scss" scoped></style>

+ 3 - 1
src/uni-pages.d.ts

@@ -53,7 +53,9 @@ interface NavigateToOptions {
        "/subPack-djk/goodsinfo/index" |
        "/subPack-djk/orderDetaile/index" |
        "/subPack-djk/shopinfo/index" |
-       "/subPack-djk/welfare/index";
+       "/subPack-djk/welfare/index" |
+       "/subPack-refueling/commonTab/index" |
+       "/subPack-refueling/webView/index";
 }
 interface RedirectToOptions extends NavigateToOptions {}
 

+ 1 - 0
vite.config.ts

@@ -33,6 +33,7 @@ export default async () => {
           'subPack-charge',
           'subPack-videoRights',
           'subPack-djk',
+          'subPack-refueling',
         ],
         /**
          * 排除的页面,相对于 dir 和 subPackages