开始做工作台,调整用电查询分页

This commit is contained in:
2024-11-08 18:24:05 +08:00
parent 08ef87ce33
commit b9d1ee34a7
32 changed files with 384 additions and 16 deletions

View File

@@ -386,4 +386,5 @@ Page({
}
})
},
})

View File

@@ -39,6 +39,11 @@ Page({
})
},
jumpToQrCode() {
const { user = {} } = this.data;
if (!user?.id) {
alertInfo("请先登录")
return;
}
wx.navigateTo({
url: '/pages/qrCode/index',
})
@@ -73,6 +78,11 @@ Page({
url: '/pages/invoiceList/index?tab=2',
})
},
jumpToWorkBench() {
wx.navigateTo({
url: '/pages/workBench/index',
})
},
async getUnReadNumber() {
const dot = await getDot();
this.setData({
@@ -117,4 +127,8 @@ Page({
});
},
// onTabItemTap(item) {
// console.log('------------', item)
// }
})

View File

@@ -14,6 +14,7 @@
<van-cell title="发票抬头" value="" is-link bind:tap="jumpToUpdateInvoice" />
<van-cell title="绑定企业" value="" is-link bind:tap="bindTenement" />
<van-cell title="常见问题" value="" is-link bind:tap="jumpToQuestions" />
<van-cell title="工作台" wx:if="{{user.workStatus}}" value="" is-link bind:tap="jumpToWorkBench" />
<van-cell title="退出登录" value="" is-link bind:tap="logout" />
<van-dialog id="van-dialog" />

View File

@@ -0,0 +1,24 @@
// pages/workBench/components/approve/index.js
Component({
/**
* 组件的属性列表
*/
properties: {
},
/**
* 组件的初始数据
*/
data: {
},
/**
* 组件的方法列表
*/
methods: {
}
})

View File

@@ -0,0 +1,4 @@
{
"component": true,
"usingComponents": {}
}

View File

@@ -0,0 +1,2 @@
<!--pages/workBench/components/approve/index.wxml-->
<text>pages/workBench/components/approve/index.wxml</text>

View File

@@ -0,0 +1 @@
/* pages/workBench/components/approve/index.wxss */

View File

@@ -0,0 +1,24 @@
// pages/workBench/components/recharge/index.js
Component({
/**
* 组件的属性列表
*/
properties: {
},
/**
* 组件的初始数据
*/
data: {
},
/**
* 组件的方法列表
*/
methods: {
}
})

View File

@@ -0,0 +1,6 @@
{
"component": true,
"usingComponents": {
"van-popup": "@vant/weapp/popup/index"
}
}

View File

@@ -0,0 +1,3 @@
<!--pages/workBench/components/recharge/index.wxml-->
充值
<searchSelect />

View File

@@ -0,0 +1 @@
/* pages/workBench/components/recharge/index.wxss */

View File

@@ -0,0 +1,24 @@
// pages/workBench/components/record/index.js
Component({
/**
* 组件的属性列表
*/
properties: {
},
/**
* 组件的初始数据
*/
data: {
},
/**
* 组件的方法列表
*/
methods: {
}
})

View File

@@ -0,0 +1,4 @@
{
"component": true,
"usingComponents": {}
}

View File

@@ -0,0 +1,2 @@
<!--pages/workBench/components/record/index.wxml-->
<text>pages/workBench/components/record/index.wxml</text>

View File

@@ -0,0 +1 @@
/* pages/workBench/components/record/index.wxss */

68
pages/workBench/index.js Normal file
View File

@@ -0,0 +1,68 @@
// pages/workBench/index.js
Page({
/**
* 页面的初始数据
*/
data: {
active: 0
},
/**
* 生命周期函数--监听页面加载
*/
onLoad(options) {
},
onTabChange(e) {
this.setData({ active: e.detail.index })
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady() {
},
/**
* 生命周期函数--监听页面显示
*/
onShow() {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide() {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload() {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh() {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom() {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage() {
}
})

View File

@@ -0,0 +1,11 @@
{
"usingComponents": {
"van-tab": "@vant/weapp/tab/index",
"van-tabs": "@vant/weapp/tabs/index",
"navigator": "/components/navigator/index",
"approve": "./components/approve/index",
"recharge": "./components/recharge/index",
"record": "./components/record/index"
},
"navigationStyle": "custom"
}

View File

@@ -0,0 +1,13 @@
<!--pages/workBench/index.wxml-->
<navigator title="工作台" canBack="true" />
<van-tabs active="{{ active }}" bind:change="onTabChange">
<van-tab title="充值">
<recharge />
</van-tab>
<van-tab title="查询">
<record />
</van-tab>
<van-tab title="审核">
<approve />
</van-tab>
</van-tabs>

View File

@@ -0,0 +1 @@
/* pages/workBench/index.wxss */