This commit is contained in:
TimSpan 2024-09-11 16:54:39 +08:00
parent 0767dc704d
commit 8d588076da
9 changed files with 115 additions and 2 deletions

BIN
.DS_Store vendored

Binary file not shown.

View File

@ -7,3 +7,4 @@ export default {
mini: {}, mini: {},
h5: {} h5: {}
} satisfies UserConfigExport } satisfies UserConfigExport

View File

@ -13,7 +13,16 @@ export default defineAppConfig({
navigationBarBackgroundColor: '#f7f8fa', navigationBarBackgroundColor: '#f7f8fa',
navigationBarTitleText: '', navigationBarTitleText: '',
navigationBarTextStyle: 'black', navigationBarTextStyle: 'black',
backgroundColor: "#008080"
}, },
subpackages: [
{
root: "subPages",
pages: [
'pages/policeManager/index',
]
}
],
tabBar: { tabBar: {
custom: true, custom: true,
list: [ list: [

View File

@ -0,0 +1,4 @@
export default definePageConfig({
navigationBarTitleText: '首页',
})

View File

@ -0,0 +1,39 @@
page {
background-color: #f0f0f0;
}
.content {
width: 702rpx;
margin: 10rpx auto;
background-color: #fff;
border-radius: 10rpx;
height: 500rpx;
display: grid;
/* 定义两列每列占据50%的宽度 */
grid-template-columns: repeat(2, 1fr);
/* 定义两行每行占据1fr分数单位表示剩余空间的一部分 */
grid-template-rows: repeat(2, 1fr);
/* 可选:增加一些间隙 */
gap: 10px;
.grid-item {
//width: 100%;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
.grid-item-image {
height: 150rpx;
width: 150rpx;
background-color: #f0f0f0;
border-radius: 50%;
}
.grid-item-text {
}
}
}

View File

@ -1,12 +1,44 @@
<template> <template>
<view>警察1111</view> <view>
<view class="content">
<div @tap="routerPush(1)" class="grid-item">
<image class="grid-item-image"></image>
<view class="grid-item-text">企事业单位</view>
</div>
<div class="grid-item">
<image class="grid-item-image"></image>
<view class="grid-item-text">监督考核</view>
</div>
<div class="grid-item">
<image class="grid-item-image"></image>
<view class="grid-item-text">警保风采</view>
</div>
<div class="grid-item">
<image class="grid-item-image"></image>
<view class="grid-item-text">三色预警</view>
</div>
</view>
</view>
</template> </template>
<script setup lang="ts"> <script setup lang="ts">
import Taro from "@tarojs/taro";
const routerPush = (path) => {
switch (path) {
case 1:
Taro.navigateTo({
url: '/subPages/pages/policeManager/index',
})
}
}
import './index.scss'
</script> </script>
<style scoped lang="scss"> <style scoped lang="scss">
</style> </style>

View File

@ -0,0 +1,4 @@
export default definePageConfig({
navigationBarTitleText: '企事业单位',
})

View File

@ -0,0 +1,4 @@
page {
background-color: #f0f0f0;
}

View File

@ -0,0 +1,20 @@
<template>
<view>
<view class="content">
</view>
</view>
</template>
<script setup lang="ts">
import Taro, {useLoad} from "@tarojs/taro";
useLoad(() => {
console.log('onLoad')
})
import './index.scss'
</script>