feat: 创建审批页面

This commit is contained in:
范鹏 2025-01-10 15:50:06 +08:00
parent 71f5296f7e
commit 9e206f362a
3 changed files with 45 additions and 5 deletions

View File

@ -65,7 +65,11 @@
},
{
"path": "pages/approval/approval",
"type": "page"
"type": "page",
"style": {
"navigationStyle": "custom",
"disableScroll": true
}
},
{
"path": "pages/attendance/allowed-time",

View File

@ -1,5 +1,41 @@
<route lang="json5">
{
style: {
navigationStyle: 'custom',
disableScroll: true
}
}
</route>
<template>
<view></view>
<view>
<TopNavigation :title="index === 0 ? '发起申请' : '审批'"></TopNavigation>
<CustomTabBar :list="list" :default-index="index" @change="change"></CustomTabBar>
</view>
</template>
<script setup lang="ts"></script>
<script setup lang="ts">
import { TabBarItem } from '@/typings'
const index = ref<number>(0)
const list: Array<TabBarItem> = [
{
title: '新申请',
icon: 'home'
},
{
title: '审批中心',
icon: 'home'
}
]
onLoad(options => {
if (options.index) {
index.value = Number(options.index)
}
})
const change = (data: object) => {
index.value = data.value
}
</script>

View File

@ -212,13 +212,13 @@
{
id: 386,
icon: 'https://file.hikmall.com/prod/image/c5a56acf8efe47d78fc0107552c98bf8.png',
url: '/pages/approval/approval',
url: '/pages/approval/approval?index=0',
name: '发起审批'
},
{
id: 385,
icon: 'https://file.hikmall.com/prod/image/6b946ba258234cdc8d447631b07939c3.png',
url: '/pages/approval/approval',
url: '/pages/approval/approval?index=1',
name: '审批记录'
}
]