Parcourir la source

📦 修改细节问题

快乐的梦鱼 il y a 1 mois
Parent
commit
4cb03d0682

+ 2 - 1
src/pages/dig/forms/common.vue

@@ -113,9 +113,10 @@ const { querys } = useLoadQuerys({
     currentFormInfo = getVillageInfoForm(querys.collectModuleId, querys.subId);
     const [model, forms] = currentFormInfo;
     formModel.value = new model() as any;
+    const formOptions = forms(formRef as any);
     formDefine.value = {
       ...formDefine.value,
-      ...forms(formRef as any),
+      ...formOptions,
       readonly: querys.isView,
       disabled: querys.isView,
     };

+ 1 - 1
src/pages/dig/forms/forms.ts

@@ -142,7 +142,7 @@ export function getVillageInfoForm(collectModuleId: number, subId: number) {
   const group = villageInfoForm[collectModuleId];
   if (!group)
     throw new Error('未定义的表单类型: ' + collectModuleId);
-  if (subId === -1) 
+  if (subId === -1 || !group[subId]) 
     return mergeFormItems(group);
   return group[subId];
 }

+ 12 - 4
src/pages/home/dig.vue

@@ -117,16 +117,22 @@
       </FlexRow>
     </FlexCol>
 
-    <Dialog 
+    <CommonDialog
+      ref="onlinePreviewDialogRef"
       v-model:show="showOnlinePreviewDialog"
-      :showConfirm="false"
     >
       <FlexCol :padding="[40,20]" :gap="10" center>
         <Image src="https://mn.wenlvti.net/app_static/xiangyuan/images/home/UnOpenIcon.png" width="300" mode="widthFix" />
+        <Height :size="20" />
         <Text textAlign="center">尊敬的用户,您未开通线上村史的使用权限,开通后即可使用!</Text>
-        <Button size="large" type="primary" @click="showOnlinePreviewDialog = false">去开通</Button>
+        <Height :size="20" />
+        <Button size="large" type="primary">
+          <WxButton openType="contact">
+            联系客服开通功能
+          </WxButton>
+        </Button>
       </FlexCol>
-    </Dialog>
+    </CommonDialog>
   </FlexCol>
 </template>
 
@@ -155,6 +161,8 @@ import HomeLargeTitle from '@/common/components/parts/HomeLargeTitle.vue';
 import type { RequestApiError } from '@imengyu/imengyu-utils';
 import FrameButton from '@/common/components/FrameButton.vue';
 import CommonDivider from '@/common/components/CommonDivider.vue';
+import WxButton from '@/components/basic/WxButton.vue';
+import CommonDialog from '@/common/components/CommonDialog.vue';
 
 const showOnlinePreviewDialog = ref(false);
 const authStore = useAuthStore();

+ 7 - 6
src/pages/user/index.vue

@@ -33,10 +33,10 @@
       GridItemPaddingHorizontal: 0,
     }">
       <Grid :borderGrid="false" :mainAxisCount="4">
-        <GridItem title="乡源等级" icon="https://xy.wenlvti.net/app_static/images/mine/IconLevel.png" touchable />
-        <GridItem title="我的成就" icon="https://xy.wenlvti.net/app_static/images/mine/IconArchive.png" touchable />
-        <GridItem title="任务中心" icon="https://xy.wenlvti.net/app_static/images/mine/IconTask.png" touchable />
-        <GridItem title="积分商城" icon="https://xy.wenlvti.net/app_static/images/mine/IconShop.png" touchable />
+        <GridItem title="乡源等级" icon="https://xy.wenlvti.net/app_static/images/mine/IconLevel.png" touchable @click="toast('暂未开放,敬请期待')" />
+        <GridItem title="我的成就" icon="https://xy.wenlvti.net/app_static/images/mine/IconArchive.png" touchable @click="toast('暂未开放,敬请期待')" />
+        <GridItem title="任务中心" icon="https://xy.wenlvti.net/app_static/images/mine/IconTask.png" touchable @click="toast('暂未开放,敬请期待')" />
+        <GridItem title="积分商城" icon="https://xy.wenlvti.net/app_static/images/mine/IconShop.png" touchable @click="toast('暂未开放,敬请期待')" />
       </Grid>
     </ProvideVar>
     <ProvideVar :vars="{
@@ -47,8 +47,8 @@
         <Cell v-if="userInfo" icon="https://xy.wenlvti.net/app_static/images/mine/IconMyArticle.png" title="我的投稿" showArrow touchable @click="navTo('/pages/dig/forms/submits', { 
           villageVolunteerId: volunteerInfoLoader.content.value?.id || 0 
         })" />
-        <Cell icon="https://xy.wenlvti.net/app_static/images/mine/IconMyRecord.png" title="福泽记录" showArrow touchable @click="requireLogin(() => navTo('/pages/home/bless/my-orders'), '登录后查看我的福泽记录哦')" />
-        <Cell icon="https://xy.wenlvti.net/app_static/images/mine/IconMyReward.png" title="兑换记录" showArrow touchable />
+        <Cell icon="https://xy.wenlvti.net/app_static/images/mine/IconMyRecord.png" title="福泽记录" showArrow touchable @click="requireLogin(() => navTo('/pages/home/village/bless/my-orders'), '登录后查看我的福泽记录哦')" />
+        <Cell icon="https://xy.wenlvti.net/app_static/images/mine/IconMyReward.png" title="兑换记录" showArrow touchable @click="toast('暂未开放,敬请期待')" />
         <Cell icon="https://xy.wenlvti.net/app_static/images/mine/IconAbout.png" title="关于我们" showArrow touchable @click="navTo('/pages/home/about/about')" />
         <button open-type="contact" class="remove-button-style">
           <Cell icon="https://xy.wenlvti.net/app_static/images/mine/IconContract.png" title="联系客服" showArrow touchable />
@@ -67,6 +67,7 @@ import { confirm } from '@/components/dialog/CommonRoot';
 import { useAuthStore } from '@/store/auth';
 import { useRequireLogin } from '@/common/composeabe/RequireLogin';
 import { useSimpleDataLoader } from '@/components/composeabe/loader/SimpleDataLoader';
+import { toast } from '@/components/utils/DialogAction';
 import CellGroup from '@/components/basic/CellGroup.vue';
 import Cell from '@/components/basic/Cell.vue';
 import Image from '@/components/basic/Image.vue';