Quellcode durchsuchen

增加电站筛选功能

master
dong vor 6 Monaten
Ursprung
Commit
93c6115702

+ 2
- 2
api/index.js Datei anzeigen

@@ -1,7 +1,7 @@
1 1
 // api.jshttp://zlink.bjdexn.cn
2
-// const baseUrl = 'http://192.168.8.187:9999';  // 替换为您的接口基础 URL
2
+const baseUrl = 'http://192.168.8.187:9999';  // 替换为您的接口基础 URL
3 3
 const esosUrl = 'https://esos-iot.bjdexn.cn';  // 线上
4
-const baseUrl = 'https://esos-iot.bjdexn.cn:8443';  // 线上
4
+// const baseUrl = 'https://esos-iot.bjdexn.cn:8443';  // 线上
5 5
 
6 6
 // const baseUrl = 'http://192.168.8.105:8888';  // 替换为您的接口基础 URL
7 7
 //  

+ 35
- 16
app.js Datei anzeigen

@@ -1,20 +1,39 @@
1
-// app.js
2 1
 App({
3 2
   onLaunch() {
4
-    // 展示本地存储能力
5
-    const logs = wx.getStorageSync('logs') || []
6
-    logs.unshift(Date.now())
7
-    wx.setStorageSync('logs', logs)
8
-
9
-    // 登录
10
-    wx.login({
11
-      success: res => {
12
-        // 发送 res.code 到后台换取 openId, sessionKey, unionId
13
-      }
14
-    })
15
- 
3
+    // 检查本地是否有角色信息
4
+    const role = wx.getStorageSync('partnerPosition');
5
+    const hasLogin = wx.getStorageSync('hasLogin');
6
+console.log(role);
7
+    if (hasLogin && role) {
8
+      // 已登录且有角色信息,直接跳转对应主页
9
+      this.redirectByRole(role);
10
+    } else {
11
+      // 未登录,跳转登录页
12
+      wx.redirectTo({ url: '/pages/login/index' });
13
+    }
16 14
   },
17
-  globalData: {
18
-    userInfo: null
15
+
16
+  // 根据角色跳转页面
17
+  redirectByRole(role) {
18
+    console.log(role.partnerPosition);
19
+    switch (role.partnerPosition) {
20
+      case '5':
21
+        wx.reLaunch({ url: '/pages/home/index' });
22
+        break;
23
+      case '1':
24
+        wx.reLaunch({ url: '/pages/index/index' });
25
+        break;
26
+        case '2':
27
+          wx.reLaunch({ url: '/pages/index/index' });
28
+          break;
29
+          case '3':
30
+            wx.reLaunch({ url: '/pages/index/index' });
31
+            break;
32
+            case '4':
33
+              wx.reLaunch({ url: '/pages/index/index' });
34
+              break;
35
+      default:
36
+        wx.redirectTo({ url: '/pages/login/index' });
37
+    }
19 38
   }
20
-})
39
+});

+ 9
- 1
app.json Datei anzeigen

@@ -13,7 +13,9 @@
13 13
     "pages/personalInfo/index",
14 14
     "pages/setuplevel/index",
15 15
     "pages/scheduling/index",
16
-    "pages/privacy/index"
16
+    "pages/privacy/index",
17
+    "pages/home/index"     
18
+    
17 19
   ],
18 20
   "requiredPrivateInfos": [
19 21
     "getLocation"
@@ -39,9 +41,15 @@
39 41
   "lazyCodeLoading": "requiredComponents",
40 42
   "__usePrivacyCheck__": true,
41 43
   "tabBar": {
44
+    "custom": true,
42 45
     "selectedColor": "#0F80DC",
43 46
     "list": [
44 47
       {
48
+        "pagePath": "pages/home/index",
49
+        "text": "首页",
50
+        "iconPath": "static/sz3.png",
51
+        "selectedIconPath": "static/sz4.png"
52
+      }, {
45 53
         "pagePath": "pages/index/index",
46 54
         "text": "首页",
47 55
         "iconPath": "static/sz3.png",

+ 4
- 1
app.wxss Datei anzeigen

@@ -15,7 +15,10 @@
15 15
 page {
16 16
   /* font-family:"PingFangSC-Thin"; */
17 17
    font-size:28rpx;          
18
-   
18
+     /* 页面底部内边距 = TabBar基础高度 + 安全区域高度 */
19
+  /* padding-bottom: calc(100rpx + env(safe-area-inset-bottom)); */
20
+  background-color: #f5f5f5;
21
+  box-sizing: border-box;
19 22
 }
20 23
 .card {
21 24
   width: 100%;

+ 71
- 0
custom-tab-bar/index.js Datei anzeigen

@@ -0,0 +1,71 @@
1
+Component({
2
+  data: {
3
+    tabList: [],  // 动态生成的tab列表
4
+    currentPath: ''  // 当前页面路径
5
+  },
6
+
7
+  attached() {
8
+    // 获取当前页面路径
9
+    setTimeout(() => {
10
+    const pages = getCurrentPages();
11
+    console.log(pages);
12
+    this.setData({
13
+      currentPath: '/' + pages[pages.length - 1].route
14
+    });
15
+  }, 10);
16
+    // 根据角色生成对应tab列表
17
+    const role = wx.getStorageSync('partnerPosition');
18
+    const allTabs = [
19
+      { pagePath: '/pages/index/index', 
20
+      text: '首页',
21
+      iconPath: '/static/sz3.png',    // 未选中图标
22
+      selectedIconPath: '/static/sz4.png'  // 选中图标
23
+    },
24
+      { pagePath: '/pages/tool/index',
25
+       text: '工单',
26
+      iconPath: '/static/tool.png',    // 未选中图标
27
+      selectedIconPath: '/static/tool1.png'  // 选中图标 
28
+    },
29
+    {
30
+      pagePath: "/pages/setup/index",
31
+      text: "我的",
32
+      iconPath: "/static/user1.png",
33
+      selectedIconPath: "/static/user2.png"
34
+    }
35
+    ];
36
+    const customer = [
37
+      { pagePath: '/pages/home/index', 
38
+      text: '首页',
39
+      iconPath: '/static/sz3.png',    // 未选中图标
40
+      selectedIconPath: '/static/sz4.png'  // 选中图标
41
+    },
42
+    {
43
+      pagePath: "/pages/setup/index",
44
+      text: "我的",
45
+      iconPath: "/static/user1.png",
46
+      selectedIconPath: "/static/user2.png"
47
+    }
48
+    ];
49
+    console.log(allTabs);
50
+
51
+    // 筛选当前角色可见的tab
52
+    let tabList = [];
53
+    if (role.partnerPosition != 5) {
54
+      tabList = allTabs
55
+     
56
+    } else{
57
+      tabList = customer
58
+    }
59
+
60
+    this.setData({ tabList });
61
+  },
62
+
63
+  methods: {
64
+    // 切换tab页
65
+    switchTab(e) {
66
+      console.log(e);
67
+      const path = e.currentTarget.dataset.path;
68
+      wx.switchTab({ url: path });
69
+    }
70
+  }
71
+});

+ 3
- 0
custom-tab-bar/index.json Datei anzeigen

@@ -0,0 +1,3 @@
1
+{
2
+  "usingComponents": {}
3
+}

+ 20
- 0
custom-tab-bar/index.wxml Datei anzeigen

@@ -0,0 +1,20 @@
1
+<!-- custom-tab-bar/index.wxml -->
2
+<view class="tab-bar">
3
+  <view 
4
+    class="tab-item" 
5
+    wx:for="{{tabList}}" 
6
+    wx:key="pagePath"
7
+    bindtap="switchTab"
8
+    data-path="{{item.pagePath}}"
9
+  >
10
+    <!-- 图标:根据选中状态切换路径 -->
11
+    <image 
12
+      class="icon" 
13
+      src="{{currentPath === item.pagePath ? item.selectedIconPath : item.iconPath}}"
14
+      mode="widthFix"  
15
+    ></image>
16
+    <view class="text {{currentPath === item.pagePath ? 'active' : ''}}">
17
+      {{item.text}}
18
+    </view>
19
+  </view>
20
+</view>

+ 51
- 0
custom-tab-bar/index.wxss Datei anzeigen

@@ -0,0 +1,51 @@
1
+/* custom-tab-bar/index.wxss */
2
+
3
+/* 底部TabBar容器 */
4
+.tab-bar {
5
+  position: fixed;
6
+  bottom: 0;
7
+  left: 0;
8
+  right: 0;
9
+  /* 基础高度 + 安全区域高度(适配苹果底部横条) */
10
+  height: calc(80rpx + env(safe-area-inset-bottom));
11
+  padding-bottom:calc(env(safe-area-inset-bottom) - 30rpx);
12
+  background-color: #ffffff;
13
+  border-top: 1px solid #eeeeee;
14
+  display: flex;
15
+  justify-content: space-around;
16
+  align-items: center;
17
+  z-index: 999;
18
+  box-sizing: border-box; /* 确保padding不会撑开容器高度 */
19
+}
20
+
21
+/* 单个Tab项容器 */
22
+.tab-item {
23
+  flex: 1;
24
+  display: flex;
25
+  flex-direction: column;
26
+  align-items: center;
27
+  justify-content: center;
28
+  padding: 8rpx 0;
29
+}
30
+
31
+/* 图标样式 */
32
+.tab-item .icon {
33
+  width: 50rpx;
34
+  height: 50rpx;
35
+  margin-bottom: 10rpx;
36
+  display: block;
37
+}
38
+
39
+/* 文字样式 */
40
+.tab-item .text {
41
+  font-size: 26rpx;
42
+  color: #8a8a8a;
43
+  line-height: 1;
44
+  font-weight: 500;
45
+
46
+}
47
+
48
+.tab-item .text.active {
49
+  color: #0F80DC; /* 选中颜色 */
50
+  font-weight: 500;
51
+}

+ 103
- 0
pages/home/index.js Datei anzeigen

@@ -0,0 +1,103 @@
1
+// pages/privacy/index.js
2
+Page({
3
+
4
+  /**
5
+   * 页面的初始数据
6
+   */
7
+  data: {
8
+ // 状态栏高度
9
+ statusBarHeight:'',
10
+ // 导航栏高度
11
+ navBarHeight:'',
12
+ // 导航栏和状态栏高度
13
+ navStatusBarHeight: '',
14
+ // 胶囊
15
+ menu:'',
16
+  },
17
+
18
+  /**
19
+   * 生命周期函数--监听页面加载
20
+   */
21
+  onLoad(options) {
22
+
23
+    this.setData({
24
+      statusBarHeight:wx.getStorageSync('statusBarHeight'),
25
+      navBarHeight: wx.getStorageSync('navBarHeight'),
26
+      navStatusBarHeight:wx.getStorageSync('navStatusBarHeight'),
27
+      menu:wx.getStorageSync('menu')
28
+    })
29
+  },
30
+  getShowScreenHeight(){
31
+    //系统信息
32
+    const systemInfo = wx.getWindowInfo()
33
+    //胶囊位置
34
+    const capsuleInfo = wx.getMenuButtonBoundingClientRect()
35
+    //计算导航栏高度
36
+    let navHeight = systemInfo.statusBarHeight + capsuleInfo.height + (capsuleInfo.top - systemInfo.statusBarHeight) * 2
37
+    //计算tabbar高度    
38
+    let tabHeight = systemInfo.safeArea.bottom - systemInfo.safeArea.height
39
+    //计算可现实内容高度(中间区域)
40
+    // let screenHeight = systemInfo.screenHeight-navHeight-tabHeight-30
41
+
42
+
43
+  const menu =  wx.getMenuButtonBoundingClientRect()
44
+  wx.setStorageSync('menu', menu)
45
+    // 手机系统状态栏高度
46
+    wx.setStorageSync('statusBarHeight', tabHeight)
47
+   // 导航栏高度
48
+   wx.setStorageSync('navBarHeight', menu.height+(menu.top-systemInfo.statusBarHeight) *2 )
49
+  
50
+   // 状态栏加导航栏
51
+
52
+   wx.setStorageSync('navStatusBarHeight',navHeight)
53
+ 
54
+  },
55
+  /**
56
+   * 生命周期函数--监听页面初次渲染完成
57
+   */
58
+  onReady() {
59
+
60
+  },
61
+
62
+  /**
63
+   * 生命周期函数--监听页面显示
64
+   */
65
+  onShow() {
66
+
67
+  },
68
+
69
+  /**
70
+   * 生命周期函数--监听页面隐藏
71
+   */
72
+  onHide() {
73
+
74
+  },
75
+
76
+  /**
77
+   * 生命周期函数--监听页面卸载
78
+   */
79
+  onUnload() {
80
+
81
+  },
82
+
83
+  /**
84
+   * 页面相关事件处理函数--监听用户下拉动作
85
+   */
86
+  onPullDownRefresh() {
87
+
88
+  },
89
+
90
+  /**
91
+   * 页面上拉触底事件的处理函数
92
+   */
93
+  onReachBottom() {
94
+
95
+  },
96
+
97
+  /**
98
+   * 用户点击右上角分享
99
+   */
100
+  onShareAppMessage() {
101
+
102
+  }
103
+})

+ 11
- 0
pages/home/index.json Datei anzeigen

@@ -0,0 +1,11 @@
1
+{
2
+  "navigationBarTitleText": "首页",
3
+  "navigationStyle": "custom",
4
+  "enablePullDownRefresh": true,
5
+  "backgroundColor": "#B7D7CB",
6
+
7
+  "usingComponents": {
8
+    "t-icon": "tdesign-miniprogram/icon/icon",
9
+    "t-popup": "tdesign-miniprogram/popup/popup"
10
+  } 
11
+}

+ 139
- 0
pages/home/index.wxml Datei anzeigen

@@ -0,0 +1,139 @@
1
+<!-- echarts -->
2
+<view class="container">
3
+  <view class="navigation-container" style="{{'height: ' + navStatusBarHeight +'px'}}">
4
+  <!--空白来占位状态栏-->
5
+  <view style="{{'height: ' + statusBarHeight +'px'}}"></view>
6
+  <!--自定义导航栏 -->
7
+  <view class="navigation-bar" style="{{'height:' + navBarHeight +'px'}}">
8
+    <!-- 晟运储能 -->
9
+     <image class="weather" src="/static/img/100.png" mode=""/> <text class="weather_1">晴</text> <text class="weather_2">-</text>
10
+     <!-- <image class="weather" src="/static/img/507.png" mode=""/> -->
11
+      <text class="weather_1"> 平均风速(m/s)3.71</text> 
12
+  </view>
13
+</view>
14
+<!--  -->
15
+<view class="home">
16
+<view style="height: 20rpx;"></view>
17
+<view style="{{'height: ' + navStatusBarHeight +'px'}}"></view>
18
+<view class="statistics" data-index="2" bind:tap="rolelocate">
19
+<view class="statistics_top">
20
+<view class="statistics_1">
21
+<view class="statistics_digit">--</view>
22
+<view class="statistics_title">全部工单</view>
23
+</view>
24
+<view class="statistics_1">
25
+<view class="statistics_digit">--</view>
26
+<view class="statistics_title">全部待办</view>
27
+</view>
28
+<view class="statistics_1">
29
+  <view class="statistics_digit">--</view>
30
+<view class="statistics_title">全部办结</view>
31
+</view>
32
+</view>
33
+ 
34
+</view>
35
+<view class="data_box" style="background-image: url(https://esos-iot.bjdexn.cn/wx_images/bj.png);background-size: 100% 100%; background-repeat: no-repeat;margin-top: 40rpx;">
36
+     <view class="titledata">
37
+      <view>基本信息</view>
38
+     </view>
39
+      
40
+     <view class="realtime1">
41
+      <view class="realtime_left1">
42
+        <view><text class="realtime_text">49.55</text><text class="realtime_unit">MW</text></view>  
43
+     <view class="realtime_title">并网容量</view>  
44
+      </view>
45
+      <view class="realtime_right1">
46
+        <view><text class="realtime_text">49.55</text><text class="realtime_unit">台</text></view> 
47
+        <!-- <text class="realtime_unit">h</text> -->
48
+     <view class="realtime_title">风机</view>  
49
+      </view>
50
+     </view>
51
+    </view>
52
+    <view class="data_box" style="margin-top: 30rpx;">
53
+     <view class="titledata">
54
+      <view>发电量</view>
55
+     </view>
56
+      
57
+     <view class="realtime1">
58
+      <view class="realtime_left1">
59
+        <view><text class="realtime_text">49.55</text><text class="realtime_unit">万/kWh</text></view>  
60
+     <view class="realtime_title">当日发电量</view>  
61
+      </view>
62
+      <view class="realtime_right1">
63
+        <view><text class="realtime_text">49.55</text><text class="realtime_unit">万/kWh</text></view> 
64
+        <!-- <text class="realtime_unit">h</text> -->
65
+     <view class="realtime_title">月累计发电量</view>  
66
+      </view>
67
+     </view>
68
+     <view class="realtime1">
69
+      <view class="realtime_left1">
70
+        <view><text class="realtime_text">49.55</text><text class="realtime_unit">万/kWh</text></view>  
71
+     <view class="realtime_title">月计划发电量</view>  
72
+      </view>
73
+      <view class="realtime_right1">
74
+        <view><text class="realtime_text">49.55</text><text class="realtime_unit">%</text></view> 
75
+        <!-- <text class="realtime_unit">h</text> -->
76
+     <view class="realtime_title">月发电量完成率</view>  
77
+      </view>
78
+     </view>
79
+     <!-- <view class="realtime2">
80
+      <view class="realtime_left2">
81
+     <view class="realtime_title">年累计发电量</view>  
82
+      </view>
83
+      <view class="realtime_right2">
84
+        <view><text class="realtime_text">9057.18</text><text class="realtime_unit">万/kWh</text></view> 
85
+      </view>
86
+     </view> -->
87
+    </view>
88
+    <view class="equipment">
89
+    <view>电站总览 <text class="equipmenttext"> (昨日:2025-10-19)</text></view>
90
+    <view class="details">
91
+    <!-- <t-icon name="chevron-right-s" size="24" color="#999999" data-name="chevron-right-s" bind:tap="ondetails"/> -->
92
+    </view>
93
+
94
+    </view>
95
+    <view class="electric">
96
+    <view class="electric1" bind:tap="onIconTap">
97
+    <view class="electric_rong">
98
+    <view class="electric4">故障</view>
99
+    <t-icon name="chevron-right-s" size="40rpx" data-name="chevron-right-s"/>
100
+    </view>
101
+    <view class="pic_pic">
102
+    <!-- <ec-canvas id="mychart_line" canvas-id="mychart_line" ec="{{ ec }}"></ec-canvas> -->
103
+    
104
+    </view>
105
+    </view>
106
+    <view class="electric2">
107
+    <view class="electric21" bind:tap="onIconTap">
108
+      <view class="electric_rong">
109
+    <view class="electric4">电站状态</view>
110
+    <t-icon name="chevron-right-s" size="40rpx" data-name="chevron-right-s"  />
111
+    </view>
112
+    <!-- <view>{{between.list[0].chargetime}} <text class="electric3">h</text></view> -->
113
+    <!-- 功率>0 放电 -->
114
+    <!-- 功率<0 充电/ -->
115
+    <!-- 功率==0 空闲 -->
116
+    <view class="tag_type2">健康</view>
117
+    <!-- <view class="tag_type1" wx:if="{{characteristic.power>0}}">放电</view> -->
118
+    <!-- <view class="tag_type2" wx:if="{{characteristic.power<0}}">充电</view> -->
119
+    <!-- <view class="tag_type3" wx:if="{{characteristic.power==0}}">空闲</view> -->
120
+    <view class="batteryccc">当前电站状态</view>
121
+    </view>
122
+    <!-- <view class="electric22" bind:tap="onhealthy"> -->
123
+    <view class="electric22">
124
+      <!-- <view class="electric_rong">
125
+    <view class="electric4">系统效率</view>
126
+    <view class="battery">{{characteristic.efficiency}} <text class="batteryccc">%</text> </view>
127
+    </view> -->
128
+ <!-- <view class="battery_bottom"></view>  -->
129
+ <view ></view>
130
+ <view><text class="realtime_text">49.55</text><text class="realtime_unit">万/kWh</text></view> 
131
+ <view class="realtime_title">年累计发电量</view>  
132
+
133
+    </view>
134
+    </view>
135
+    </view>
136
+<view style="height: 20rpx;"> </view>
137
+</view>
138
+
139
+</view> 

+ 733
- 0
pages/home/index.wxss Datei anzeigen

@@ -0,0 +1,733 @@
1
+/*  */
2
+.navigation-container {
3
+  position: fixed;
4
+  width: 100%;
5
+  z-index: 99;
6
+  background-color: #89bfea;
7
+}
8
+.navigation-bar {
9
+  position: relative;
10
+  width: 100%;
11
+  display: flex;
12
+  align-items: center;
13
+  /* justify-content: center; */
14
+  font-size: 36rpx;
15
+  padding-left: 40rpx;
16
+  flex-direction: row;
17
+  color: #fff;
18
+}
19
+.title_1{
20
+  font-weight: 500;
21
+  font-size: 28rpx;
22
+  display: flex;
23
+  align-items: center;
24
+}
25
+.title_image{
26
+  width: 24rpx;
27
+  height: 24rpx;
28
+  margin-left: 10rpx;
29
+  transition: transform 3s ease; /* 添加过渡效果 */
30
+}
31
+
32
+.title_2{
33
+  font-size: 28rpx;
34
+  margin-top: 30rpx;
35
+}
36
+.nav-title {
37
+  height: 100%;
38
+  display: flex;
39
+ align-items: center;
40
+  margin-left: 20rpx;
41
+  box-sizing: border-box;
42
+}
43
+ 
44
+.nav-search {
45
+  position: absolute;
46
+  display: flex;
47
+  justify-content: flex-end;
48
+  align-items: center;
49
+}
50
+/* // */
51
+.container {
52
+  width: 100%;
53
+  min-height: 100%;
54
+  display: flex;
55
+  align-items: center;
56
+  /* 007544 */
57
+ background: linear-gradient(to bottom, #0F80DC -40%, #F0F5F5 40%, #F0F5F5 100%);
58
+ /* background: linear-gradient(to bottom, #007544 -40%, #F0F5F5 40%,#F0F5F5 100%); */
59
+}
60
+.home{
61
+  width: 100%;
62
+  padding: 20rpx 20rpx;
63
+  box-sizing: border-box;
64
+}
65
+.statistics{
66
+  width: 100%;
67
+  padding: 0rpx 40rpx;
68
+  box-sizing: border-box;
69
+}
70
+.statistics_top{
71
+  display: flex;
72
+  justify-content: space-between;
73
+}
74
+
75
+.statistics_1{
76
+  display: flex;
77
+  flex-direction: column;
78
+  justify-content: center;
79
+  align-items: center;
80
+}
81
+.statistics_digit{
82
+  font-size: 48rpx;
83
+}
84
+.statistics_title{
85
+  margin-top: 10rpx;
86
+}
87
+.vajra{
88
+  width: 100%;
89
+  padding: 16rpx;
90
+  display: flex;
91
+  align-items: center;
92
+  justify-content: space-between;
93
+  background-color: #fff;
94
+  box-sizing: border-box;
95
+  border-radius: 20rpx;
96
+  margin-top: 60rpx;
97
+  }
98
+  .vajra_role{
99
+    width: 22%;
100
+    padding: 20rpx 0rpx;
101
+    display: flex;
102
+    flex-direction: column;
103
+    justify-content: center;
104
+    align-items: center;
105
+    border-radius: 10rpx;
106
+    /* background-color: #ffffff; */
107
+  }
108
+  .vajra_rights{
109
+    width: 22%;
110
+    padding: 20rpx 0rpx;
111
+    display: flex;
112
+    flex-direction: column;
113
+    justify-content: center;
114
+    align-items: center;
115
+    border-radius: 10rpx;
116
+    /* background-color: #ffffff; */
117
+  }
118
+  .vajra_apply{
119
+    width: 22%;
120
+    padding: 20rpx 0rpx;
121
+    display: flex;
122
+    flex-direction: column;
123
+    justify-content: center;
124
+    align-items: center;
125
+    border-radius: 10rpx;
126
+    /* background-color: #ffffff; */
127
+  }
128
+  .role{
129
+    width: 120rpx;
130
+    height: 120rpx;
131
+    margin-bottom: 20rpx;
132
+    border-radius: 16rpx;
133
+    box-sizing: border-box;
134
+  }
135
+  .role_botton{
136
+    width: 60rpx;
137
+    height: 60rpx;
138
+    box-sizing: border-box;
139
+  }
140
+  .vajra_share{
141
+    width: 22%;
142
+    /* padding: 20rpx 0rpx; */
143
+    display: flex;
144
+    flex-direction: column;
145
+    justify-content: center;
146
+    align-items: center;
147
+    border-radius: 10rpx;
148
+    background-color: #ffffff;
149
+  }
150
+  .role_botton{
151
+    width: 60rpx;
152
+    height: 60rpx;
153
+    box-sizing: border-box;
154
+  }
155
+  button{
156
+    padding: 0rpx;
157
+    margin: 0rpx;
158
+    width: 100%;
159
+    height: 148rpx;
160
+  padding-top: 20rpx;
161
+  display: flex;
162
+  flex-direction: column;
163
+  align-items: center;
164
+    font-size: 28rpx;
165
+    /* line-height: 130rpx; */
166
+    border:0rpx #f5f5f5  solid;
167
+  background-color: rgba(0, 0, 0, 0);
168
+  
169
+  }
170
+  wx-button:after {
171
+    display: flex;
172
+  flex-direction: column;
173
+    width: 100%;
174
+    height: 148rpx;
175
+  padding: 20rpx 0rpx;
176
+    font-size: 28rpx;
177
+    /* line-height: 130rpx; */
178
+    border:0rpx #f5f5f5  solid;
179
+  background-color: rgba(0, 0, 0, 0);
180
+  }  
181
+ .examine{
182
+margin-top: 40rpx;
183
+font-size: 32rpx;
184
+ }
185
+ .examine_box{
186
+   width: 100%;
187
+   background-color: #fff;
188
+   padding: 30rpx 0rpx;
189
+margin-top: 20rpx;
190
+border-radius: 10rpx;
191
+box-sizing: border-box;
192
+ }
193
+ .examine_title{
194
+   width: 100%;
195
+   display: flex;
196
+   align-items: center;
197
+   padding: 0rpx 0rpx 0rpx 20rpx;
198
+   box-sizing: border-box;
199
+ }
200
+ .examine_title0{
201
+  width: 120rpx;
202
+  height: 40rpx;
203
+  font-size: 22rpx; 
204
+  display: flex;
205
+  align-items: center;
206
+  justify-content: center;
207
+  border-radius: 30rpx;
208
+  /* background-color: #0F80DC; */
209
+  background-color: rgba(15, 128, 220, 0.2);
210
+  color: #0F80DC;
211
+  border: 1rpx solid #0F80DC;
212
+box-sizing: border-box;
213
+
214
+ }
215
+ .examine_title01{
216
+  width: 120rpx;
217
+  height: 40rpx;
218
+  font-size: 22rpx; 
219
+  display: flex;
220
+  align-items: center;
221
+  justify-content: center;
222
+  border-radius: 30rpx;
223
+  /* background-color: #0F80DC; */
224
+  color:#ee8d60;
225
+  background-color: rgba(241, 120, 20, 0.2);
226
+
227
+  border: 1rpx solid #f39b72;
228
+ box-sizing: border-box;
229
+ }
230
+ .examine_title02{
231
+  width: 120rpx;
232
+  height: 40rpx;
233
+  font-size: 22rpx; 
234
+  display: flex;
235
+  align-items: center;
236
+  justify-content: center;
237
+  border-radius: 30rpx;
238
+  /* background-color: #0F80DC; */
239
+  color:#0F80DC;
240
+  background-color: rgba(15, 128, 220, 0.2);
241
+  /* color: #007544; */
242
+  border: 1rpx solid #0F80DC;
243
+ box-sizing: border-box;
244
+ }
245
+ .examine_title1{
246
+   flex: 1;
247
+   font-weight: 600;
248
+   font-size: 32rpx;
249
+   display: flex;
250
+   align-items: center;
251
+   padding: 0rpx 10rpx;
252
+   overflow: hidden;
253
+  display: -webkit-box;
254
+  text-overflow: ellipsis;
255
+  box-orient: vertical;
256
+  -webkit-box-orient: vertical;
257
+  -moz-box-orient: vertical;
258
+  -o-box-orient: vertical;
259
+  -ms-box-orient: vertical;
260
+  line-clamp: 1; /* 超出2行显示省略号 */
261
+  -webkit-line-clamp: 1; /* 超出2行显示省略号 */
262
+   box-sizing: border-box;
263
+ }
264
+ .examine_title2{
265
+   width: 100rpx;
266
+   height: 40rpx;
267
+  font-size: 22rpx; 
268
+   display: flex;
269
+   align-items: center;
270
+   justify-content: center;
271
+border-top-left-radius:100rpx;
272
+border-bottom-left-radius:100rpx;
273
+   background-color: rgb(255, 0, 0,0.2);
274
+   color: red;
275
+   border: 1rpx solid red;
276
+   border-right: 0rpx solid red;
277
+box-sizing: border-box;
278
+ }
279
+ .examine_content{
280
+   flex: 1;
281
+   font-size: 24rpx;
282
+   padding: 20rpx 20rpx;
283
+   margin: 20rpx 20rpx;
284
+   color: #cccccc;
285
+   background-color: #f9f9f9;
286
+   border-radius: 8rpx;
287
+   box-sizing: border-box;
288
+ }
289
+ .feedback{
290
+  margin-top: 8rpx;
291
+ }
292
+ .examine_bottom{
293
+   display: flex;
294
+ }
295
+ .examine_bottom{
296
+   display: flex;
297
+   align-items: center;
298
+   justify-content: space-between;
299
+   padding: 0rpx 20rpx;
300
+box-sizing: border-box;
301
+
302
+ }
303
+ .examine_button{
304
+   width: 100%;
305
+   padding: 0rpx 20rpx;
306
+   margin-top: 30rpx;
307
+   display: flex;
308
+   align-items: center;
309
+   justify-content: space-between;
310
+   box-sizing: border-box;
311
+
312
+ }
313
+ .examine_buttonleft{
314
+   width: 160rpx;
315
+   height:60rpx;
316
+  border-radius: 12rpx;
317
+  display: flex;
318
+  align-items: center;
319
+  justify-content: center;
320
+   background-color: #0F80DC;
321
+color: #fff;
322
+box-sizing: border-box;
323
+
324
+ }
325
+ .examine_buttonright{
326
+   width:160rpx;
327
+   height:60rpx;
328
+   display: flex;
329
+   align-items: center;
330
+   justify-content: center;
331
+   margin-left: 10rpx;
332
+   border-radius: 12rpx;
333
+   background-color: #0F80DC;
334
+   color: #fff;
335
+box-sizing: border-box;
336
+
337
+ }
338
+ .examine_name{
339
+   color: #cccccc;
340
+ }
341
+ .available{
342
+   width: 100%;
343
+   display: flex;
344
+   align-items: center;
345
+   justify-content: center;
346
+   margin-top: 60rpx;
347
+ }
348
+ .picker{
349
+   display: flex;
350
+   align-items: center;
351
+ }
352
+ .chevron_down{
353
+   margin-left: 10rpx;
354
+ }
355
+ .weather{
356
+   width: 100rpx;
357
+   height: 100rpx;
358
+ }
359
+ .weather_1{
360
+   font-size: 28rpx;
361
+
362
+ }
363
+ .weather_2{
364
+   margin: 0rpx 10rpx;
365
+ }
366
+ .realtime1{
367
+  width: 100%;
368
+  display: flex;
369
+  padding: 0rpx 20rpx;
370
+  box-sizing: border-box;
371
+}
372
+.realtime2{
373
+  width: 100%;
374
+  display: flex;
375
+  padding: 0rpx 20rpx;
376
+  box-sizing: border-box;
377
+}
378
+
379
+.data_box{
380
+  width: 100%;
381
+  border-radius: 20rpx;
382
+  box-sizing: border-box;
383
+padding-bottom:20rpx;
384
+margin-top: 60rpx;
385
+box-shadow: 0px 2px 10px rgba(0, 0, 0, 0.1);
386
+}
387
+.titledata{
388
+  display: flex;
389
+  align-items: center;
390
+  justify-content: space-between;
391
+  padding: 16rpx 10rpx 20rpx 20rpx;
392
+  box-sizing: border-box;
393
+}
394
+.realtime_left1{
395
+  width: 50%;
396
+  height: 120rpx;
397
+  padding-bottom: 20rpx;
398
+  display: flex;
399
+  flex-direction: column;
400
+  align-items: center;
401
+  justify-content: center;
402
+  font-size: 14px;
403
+  border-right:1rpx solid #E1E0F4;
404
+
405
+}
406
+
407
+.realtime_text{
408
+  font-size: 18px;
409
+  margin-right: 4px;
410
+  color: #00BA82;
411
+}
412
+.realtime_title{
413
+  font-size: 14px;
414
+  margin-top: 10rpx;
415
+  color: #222;
416
+}
417
+.realtime_right1{
418
+  width: 50%;
419
+  height: 120rpx;
420
+  padding-bottom: 20rpx;
421
+
422
+  display: flex;
423
+  flex-direction: column;
424
+  align-items: center;
425
+  justify-content: center;
426
+  font-size: 14px;
427
+}
428
+.realtime_left2{
429
+  width: 50%;
430
+  height: 90rpx;
431
+  
432
+  display: flex;
433
+  flex-direction: column;
434
+  align-items: center;
435
+  justify-content: center;
436
+  font-size: 14px;
437
+  border-top:1rpx solid #E1E0F4;
438
+
439
+}
440
+.realtime_right2{
441
+  width: 50%;
442
+  height: 90rpx;
443
+ 
444
+  display: flex;
445
+  flex-direction: column;
446
+  align-items: center;
447
+  justify-content: center;
448
+  font-size: 14px;
449
+  border-top:1rpx solid #E1E0F4;
450
+
451
+}
452
+.canvasArea1 {
453
+  width: 100%;
454
+  display: flex;
455
+  flex-direction: column;
456
+ margin-top: 10rpx;
457
+ align-items: center;
458
+ }
459
+.canvasArea canvas {
460
+  width: 300rpx;
461
+  height: 300rpx;
462
+}
463
+
464
+
465
+.data_box{
466
+  width: 100%;
467
+  border-radius: 20rpx;
468
+  box-sizing: border-box;
469
+padding-bottom:20rpx;
470
+margin-top: 20rpx;
471
+box-shadow: 0px 2px 10px rgba(0, 0, 0, 0.1);
472
+}
473
+.data_box1{
474
+  width: 100%;
475
+  border-radius: 20rpx;
476
+  box-sizing: border-box;
477
+padding-bottom:20rpx;
478
+}
479
+.titledata{
480
+  display: flex;
481
+  align-items: center;
482
+  justify-content: space-between;
483
+  padding: 16rpx 10rpx 10rpx 20rpx;
484
+  box-sizing: border-box;
485
+}
486
+.realtime{
487
+  width: 100%;
488
+  display: flex;
489
+  padding: 0px 20rpx;
490
+  box-sizing: border-box;
491
+}
492
+.realtime_left{
493
+  width: 50%;
494
+  height: 120rpx;
495
+  display: flex;
496
+  flex-direction: column;
497
+  align-items: center;
498
+  justify-content: center;
499
+  font-size: 14px;
500
+  border-bottom:1rpx solid #E1E0F4;
501
+  border-right:1rpx solid #E1E0F4;
502
+
503
+}
504
+.realtime_right{
505
+  width: 50%;
506
+  height: 120rpx;
507
+  display: flex;
508
+  flex-direction: column;
509
+
510
+  align-items: center;
511
+  justify-content: center;
512
+  font-size: 14px;
513
+  border-bottom:1rpx solid #E1E0F4;
514
+
515
+}
516
+.realtime1{
517
+  width: 100%;
518
+  display: flex;
519
+  padding: 0rpx 20rpx;
520
+  box-sizing: border-box;
521
+}
522
+.realtime2{
523
+  width: 100%;
524
+  display: flex;
525
+  justify-content: space-between;
526
+  padding: 0rpx 20rpx;
527
+  padding-top: 20rpx;
528
+  box-sizing: border-box;
529
+}
530
+.realtime_left1{
531
+  width: 50%;
532
+  height: 120rpx;
533
+  display: flex;
534
+  flex-direction: column;
535
+  align-items: center;
536
+  justify-content: center;
537
+  font-size: 14px;
538
+  border-right:1rpx solid #E1E0F4;
539
+
540
+}
541
+.realtime_left2{
542
+  width: 48%;
543
+  height: 100rpx;
544
+  display: flex;
545
+  align-items: center;
546
+  justify-content: space-around;
547
+  border-radius: 10rpx;
548
+  
549
+  font-size: 14px;
550
+  background-color: #ffffff;
551
+
552
+}
553
+.realtime_right1{
554
+  width: 50%;
555
+  height: 120rpx;
556
+  display: flex;
557
+  flex-direction: column;
558
+
559
+  align-items: center;
560
+  justify-content: center;
561
+  font-size: 14px;
562
+}
563
+.realtime_right2{
564
+  width: 48%;
565
+  height: 100rpx;
566
+  display: flex;
567
+  align-items: center;
568
+  justify-content: center;
569
+  font-size: 14px;
570
+  background-color: #ffffff;
571
+  justify-content: space-around;
572
+  border-radius: 10rpx;
573
+}
574
+.realtime_text{
575
+  font-size: 18px;
576
+  margin-right: 4px;
577
+  color: #00BA82;
578
+}
579
+.realtime_unit{
580
+  font-size: 12px;
581
+  color: #222;
582
+}
583
+.realtime_title{
584
+  font-size: 14px;
585
+  margin-top: 10rpx;
586
+  color: #222;
587
+}
588
+.line{
589
+  width: 100%;
590
+  height: 100%;
591
+}
592
+#mychart_line {
593
+  width: 100%;
594
+  height: 100%;
595
+  margin-top: 20rpx;
596
+}
597
+.equipment{
598
+  width: 100%;
599
+  display: flex;
600
+  justify-content: space-between;
601
+  padding: 0rpx 20rpx;
602
+  box-sizing: border-box;
603
+  margin-top: 40rpx;
604
+  font-size: 28rpx;
605
+}
606
+.equipmenttext{
607
+  font-size: 22rpx;
608
+  color: #999999;
609
+}
610
+ .details{
611
+   font-weight: 400;
612
+   font-size: 26rpx;
613
+  color: #999999;
614
+  display: flex;
615
+  align-items: center;
616
+  box-sizing: border-box;
617
+ }
618
+.electric{
619
+  width: 100%;
620
+  padding: 0rpx 20rpx;
621
+  box-sizing: border-box;
622
+  margin-top: 40rpx;
623
+  display: flex;
624
+  justify-content: space-between;
625
+}
626
+.electric1{
627
+  width: 48%;
628
+  height: 400rpx;
629
+  background-color: #ffffff;
630
+  border-radius: 16rpx;
631
+  padding: 20rpx 20rpx;
632
+  box-sizing: border-box;
633
+box-shadow: 0px 2px 10px rgba(0, 0, 0, 0.1);
634
+
635
+}
636
+.electric_rong{
637
+  display: flex;
638
+  justify-content: space-between;
639
+  align-items: center;
640
+}
641
+.electric_{
642
+  color: #999999;
643
+}
644
+.pic_pic{
645
+  width: 100%;
646
+  height: 320rpx;
647
+}
648
+.cumulative1{
649
+display: flex;
650
+justify-content: space-between;
651
+align-items: center;
652
+}
653
+.cumulative11{
654
+  font-size: 24rpx;
655
+  color: #999999;
656
+}
657
+.cumulative2{
658
+  display: flex;
659
+justify-content: space-between;
660
+align-items: center;
661
+margin-top: 20rpx;
662
+}
663
+.electric2{
664
+  width: 48%;
665
+  height: 400rpx;
666
+  display: flex;
667
+  flex-direction: column;
668
+  justify-content: space-between;
669
+  background-color: #ffffff;
670
+border-radius: 16rpx;
671
+ padding: 0rpx 20rpx;
672
+ box-sizing: border-box;
673
+box-shadow: 0px 2px 10px rgba(0, 0, 0, 0.1);
674
+
675
+}
676
+.electric21{
677
+  width: 100%;
678
+  height: 220rpx;
679
+padding: 20rpx 0rpx;
680
+display: flex;
681
+flex-direction: column;
682
+justify-content: space-between;
683
+box-sizing: border-box
684
+}
685
+.electric22{
686
+  width: 100%;
687
+  height: 160rpx;
688
+  padding: 20rpx 0rpx;
689
+  display: flex;
690
+  flex-direction: column;
691
+  justify-content: space-between;
692
+  box-sizing: border-box;
693
+  border-top:1rpx solid #E1E0F4;
694
+}
695
+.electric3{
696
+  font-size: 22rpx;
697
+}
698
+.electric4{
699
+  font-size: 22rpx;
700
+  color: #999999;
701
+}
702
+.battery{
703
+font-size: 24rpx;
704
+ color: #222222;
705
+
706
+}
707
+.batteryccc{
708
+  font-size: 20rpx;
709
+  color: #999999;
710
+  
711
+  }
712
+  .battery_bottom{
713
+    width: 100%;
714
+    /* border-bottom: 1rpx solid #E1E0F4; */
715
+  }
716
+.tag_type1 {
717
+  font-size: 28rpx;
718
+  color: #F0A26C;
719
+  font-weight: 600;
720
+}
721
+
722
+.tag_type2 {
723
+  font-size: 28rpx;
724
+  color: #15DB9B;
725
+  font-weight: 600;
726
+}
727
+
728
+.tag_type3 {
729
+  font-size: 28rpx;
730
+  color: #b0c4de;
731
+  font-weight: 600;
732
+/* 蓝 */
733
+}

+ 34
- 13
pages/index/index.js Datei anzeigen

@@ -15,6 +15,8 @@ Page({
15 15
  navStatusBarHeight: '',
16 16
  // 胶囊
17 17
  menu:'',
18
+ index:0,
19
+ objectArray: [],
18 20
  workorder:[],
19 21
  reviewdata:[]
20 22
   },
@@ -23,8 +25,8 @@ Page({
23 25
    * 生命周期函数--监听页面加载
24 26
    */
25 27
   onLoad(options) {
26
- this.getuser()
27
- this.getShowScreenHeight()
28
+  this.getpowestation()
29
+ 
28 30
 this.setData({
29 31
   statusBarHeight:wx.getStorageSync('statusBarHeight'),
30 32
   navBarHeight: wx.getStorageSync('navBarHeight'),
@@ -57,24 +59,25 @@ this.setData({
57 59
    wx.setStorageSync('navStatusBarHeight',navHeight)
58 60
  
59 61
   },
60
-  getuser(){
61
-    api.request(`/partner/selectinformation`, 'POST',{})
62
+  // 查询电站
63
+  getpowestation(){
64
+    api.request(`/syspowerstation/selectpowestation`, 'POST',{})
62 65
     .then((res) => {
63
-                 // 设置数据到本地存储
64
-                 wx.setStorage({
65
-                  key: 'partnerPosition',  // 存储的key值
66
-                  data:res.data,
67
-                  success: function(ress) {
68
-                
69
-                    // wx.getStorageSync('token');
70
-                  }
71
-                });
66
+                 if (res.code==200) {
67
+                  this.setData({
68
+                    objectArray:res.data
69
+                   })
70
+                   this.getuser()
71
+ this.getShowScreenHeight()
72
+                 }
72 73
     })
73 74
     .catch((err) => {
74 75
       console.error('请求失败:', err);
75 76
       // 在这里处理请求失败的情况
76 77
     });
77 78
   },
79
+   
80
+
78 81
   getworkoder(){
79 82
     let data = {
80 83
       workorderType:''
@@ -198,6 +201,24 @@ wx.navigateTo({
198 201
       }
199 202
       })
200 203
   },
204
+  bindPickerChange: function(e) {
205
+    console.log('picker发送选择改变,携带值为', e.detail.value)
206
+    this.setData({
207
+      index: e.detail.value
208
+    })
209
+    let data = {
210
+      powerstationId:this.data.objectArray[e.detail.value].powerstationId
211
+    }
212
+    api.request(`/workoder/selectworkoder`, 'POST',data)
213
+    .then((res) => {
214
+      console.log(res);
215
+  
216
+    })
217
+    .catch((err) => {
218
+      console.error('请求失败:', err);
219
+      // 在这里处理请求失败的情况
220
+    });
221
+  },
201 222
   /**
202 223
    * 生命周期函数--监听页面隐藏
203 224
    */

+ 9
- 1
pages/index/index.wxml Datei anzeigen

@@ -5,9 +5,17 @@
5 5
   <view style="{{'height: ' + statusBarHeight +'px'}}"></view>
6 6
   <!--自定义导航栏 -->
7 7
   <view class="navigation-bar" style="{{'height:' + navBarHeight +'px'}}">
8
-    晟运储能
8
+    <!-- 晟运储能 -->
9
+    <picker bindchange="bindPickerChange" value="{{index}}" range="{{objectArray}}" range-key="powerstationName">
10
+    <view class="picker">
11
+     {{objectArray[index].powerstationName}}
12
+     <!-- chevron-down -->
13
+     <t-icon class="chevron_down" name="chevron-down" size="40rpx" data-name="chevron-down"/>
14
+    </view>
15
+  </picker>
9 16
   </view>
10 17
 </view>
18
+<!--  -->
11 19
 <view class="home">
12 20
 <view style="height: 20rpx;"></view>
13 21
 <view style="{{'height: ' + navStatusBarHeight +'px'}}"></view>

+ 8
- 0
pages/index/index.wxss Datei anzeigen

@@ -71,6 +71,7 @@
71 71
   display: flex;
72 72
   justify-content: space-between;
73 73
 }
74
+
74 75
 .statistics_1{
75 76
   display: flex;
76 77
   flex-direction: column;
@@ -343,4 +344,11 @@ box-sizing: border-box;
343 344
    align-items: center;
344 345
    justify-content: center;
345 346
    margin-top: 60rpx;
347
+ }
348
+ .picker{
349
+   display: flex;
350
+   align-items: center;
351
+ }
352
+ .chevron_down{
353
+   margin-left: 10rpx;
346 354
  }

+ 28
- 9
pages/login/index.js Datei anzeigen

@@ -1,6 +1,6 @@
1 1
 // pages/login/index.js 
2 2
 const api = require('../../api/index.js');
3
-
3
+const app = getApp();
4 4
 Page({
5 5
 
6 6
   /**
@@ -172,14 +172,12 @@ wx.setStorage({
172 172
   data:data.data.token,
173 173
   success: function(ress) {
174 174
     console.log(ress);
175
+    wx.setStorageSync('hasLogin', true);
176
+    _this.getuser()
177
+  // wx.reLaunch({
178
+  //   url: '/pages/index/index'
179
+  // });
175 180
 
176
-  wx.reLaunch({
177
-    url: '/pages/index/index'
178
-  });
179
-  wx.showToast({
180
-    title: '登录成功',
181
-    icon: 'success',
182
-  });
183 181
 
184 182
   }
185 183
 });
@@ -217,7 +215,28 @@ wx.setStorage({
217 215
 
218 216
 
219 217
 },
220
- 
218
+getuser(){
219
+  api.request(`/partner/selectinformation`, 'POST',{})
220
+  .then((res) => {
221
+               // 设置数据到本地存储
222
+               wx.setStorage({
223
+                key: 'partnerPosition',  // 存储的key值
224
+                data:res.data,
225
+                success: function(ress) {
226
+                  app.redirectByRole(res.data);
227
+                  wx.showToast({
228
+                    title: '登录成功',
229
+                    icon: 'success',
230
+                  });
231
+                  // wx.getStorageSync('token');
232
+                }
233
+              });
234
+  })
235
+  .catch((err) => {
236
+    console.error('请求失败:', err);
237
+    // 在这里处理请求失败的情况
238
+  });
239
+},
221 240
     // 处理登录按钮点击
222 241
     onLogin() {
223 242
            // 获取本地存储的数据

+ 1
- 1
pages/login/index.wxml Datei anzeigen

@@ -54,7 +54,7 @@
54 54
  <view class="loginbotton">
55 55
   <!-- <button wx:if="{{!Loginswitch}}" class="button_button" open-type="getPhoneNumber" bindgetphonenumber="onGetPhoneNumber">手机号一键登录</button> -->
56 56
  <button wx:if="{{Loginswitch&&checked}}" class="button_button" color="#0F80DC" open-type="getPhoneNumber" bindgetphonenumber="onGetPhoneNumber">手机号一键登录</button>
57
- <button wx:if="{{!checked}}" class="button_button" color="#0F80DC" bind:tap="onstatus">手机号一键登录</button>
57
+ <button wx:if="{{Loginswitch&&!checked}}" class="button_button" color="#0F80DC" bind:tap="onstatus">手机号一键登录</button>
58 58
  <button wx:if="{{!Loginswitch}}" class="button_button" color="#0F80DC" bind:tap="onLogin">登录</button>
59 59
  <!-- <button wx:if="{{!Loginswitch}}" bindphoneoneclicklogin="onHandleLogin" open-type="phoneOneClickLogin">一键登录按钮</button> -->
60 60
  <view class="agreement">

+ 1
- 2
pages/setup/index.js Datei anzeigen

@@ -88,7 +88,7 @@ inputValue: '' // 初始值
88 88
   } catch (e) {
89 89
     console.error("获取小程序版本号失败:", e);
90 90
   }
91
-    // this.getuser()
91
+    this.getuser()
92 92
   },
93 93
 
94 94
   getuser(){
@@ -125,7 +125,6 @@ inputValue: '' // 初始值
125 125
    * 生命周期函数--监听页面显示
126 126
    */
127 127
   onShow() {
128
- this.getuser()
129 128
 
130 129
     this.setData({
131 130
       station:wx.getStorageSync('station')

+ 1
- 1
pages/setup/index.wxml Datei anzeigen

@@ -12,7 +12,7 @@
12 12
 <image bind:tap="onuser" class="user_to" src="{{user.partnerAvite||'https://thirdwx.qlogo.cn/mmopen/vi_32/POgEwh4mIHO4nibH0KlMECNjjGxQUq24ZEaGT4poC6icRiccVGKSyXwibcPq4BWmiaIGuG1icwxaQX6grC9VemZoJ8rg/132'}}" mode=""/>
13 13
 <view class="user_name">
14 14
 <view class="user_name1">{{user.partnerName||'微信用户'}}
15
-<view class="user_role" wx:if="{{user.partnerPosition==4}}">董事长</view>
15
+<view class="user_role" wx:if="{{user.partnerPosition==4}}">黄总</view>
16 16
 <view class="user_role" wx:if="{{user.partnerPosition==3}}">站长</view>
17 17
 <view class="user_role" wx:if="{{user.partnerPosition==2}}">值长</view>
18 18
 <view class="user_role" wx:if="{{user.partnerPosition==1}}">值班员</view>

+ 1
- 1
project.private.config.json Datei anzeigen

@@ -1,6 +1,6 @@
1 1
 {
2 2
   "description": "项目私有配置文件。此文件中的内容将覆盖 project.config.json 中的相同字段。项目的改动优先同步到此文件中。详见文档:https://developers.weixin.qq.com/miniprogram/dev/devtools/projectconfig.html",
3
-  "projectname": "partner_wx",
3
+  "projectname": "autoflow_wx",
4 4
   "setting": {
5 5
     "compileHotReLoad": true,
6 6
     "urlCheck": false,

BIN
static/img/100.png Datei anzeigen


BIN
static/img/101.png Datei anzeigen


BIN
static/img/103.png Datei anzeigen


BIN
static/img/150.png Datei anzeigen


BIN
static/img/301.png Datei anzeigen


BIN
static/img/302.png Datei anzeigen


BIN
static/img/305.png Datei anzeigen


BIN
static/img/312.png Datei anzeigen


BIN
static/img/316.png Datei anzeigen


BIN
static/img/408.png Datei anzeigen


BIN
static/img/410.png Datei anzeigen


BIN
static/img/507.png Datei anzeigen


BIN
static/光伏.png Datei anzeigen


BIN
static/风电场开发.png Datei anzeigen


Laden…
Abbrechen
Speichern