Browse Source

add new features

vbea 2 years ago
parent
commit
b86d98b69e

+ 1 - 1
Strides-Admin/src/components/DialogAssignment.vue

@@ -353,7 +353,7 @@ export default {
     align-items: center;
     align-items: center;
     justify-content: flex-end;
     justify-content: flex-end;
   }
   }
-  .table-view {
+  .assign-dialog .table-view {
     flex: 1;
     flex: 1;
     overflow-y: auto;
     overflow-y: auto;
     padding-top: 10px;
     padding-top: 10px;

+ 15 - 0
Strides-Admin/src/http/api/apiBalancing.js

@@ -0,0 +1,15 @@
+import {get, post, put, del} from '../http'
+
+const apiBalancing = {
+  getBalancingPages(params) {
+    return post('site-load-balancing/config-pages', params)
+  },
+  viewBalancing(params) {
+    return get('site-load-balancing/config', params)
+  },
+  updateBalancing(params) {
+    return post('site-load-balancing/config', params)
+  }
+}
+
+export default apiBalancing;

+ 24 - 0
Strides-Admin/src/http/api/apiReport.js

@@ -0,0 +1,24 @@
+import { get, post, download } from '../http'
+
+const apiReport = {
+  getReportTypeList() {
+    return get('report-mgmt/report-types')
+  },
+  getMonthList() {
+    return get('report-mgmt/months')
+  },
+  getGroupList(params) {
+    return get('report-mgmt/groups', params)
+  },
+  generateReport(params) {
+    return post('report-mgmt/generate', params)
+  },
+  getReportsPages(params) {
+    return post('report-mgmt/report-pages', params)
+  },
+  exportReports(params) {
+    return download('report-mgmt/download', params)
+  }
+}
+
+export default apiReport

+ 6 - 0
Strides-Admin/src/http/api/site.js

@@ -56,6 +56,12 @@ const site = {
   },
   },
   deleteChargingProfile(id) {
   deleteChargingProfile(id) {
     return get(MODULE_NAME+ '/delSiteChargingProfile', {siteChargingProfileId: id})
     return get(MODULE_NAME+ '/delSiteChargingProfile', {siteChargingProfileId: id})
+  },
+  getPlugTypes() {
+    return get('/chargeType/plug-types')
+  },
+  getHistoryRates(params) {
+    return get(MODULE_NAME + '/site-rates', params)
   }
   }
 }
 }
 
 

+ 1 - 1
Strides-Admin/src/http/http.js

@@ -6,7 +6,7 @@ import { getToken } from '@/utils/auth'
 export const baseURL = process.env.VUE_APP_BASE_API
 export const baseURL = process.env.VUE_APP_BASE_API
 //console.log('---CONFIG---', process.env)
 //console.log('---CONFIG---', process.env)
 // 设置接口响应时间
 // 设置接口响应时间
-axios.defaults.timeout = 50000
+axios.defaults.timeout = 60000
 axios.defaults.baseURL = baseURL + process.env.VUE_APP_API_PREFIX
 axios.defaults.baseURL = baseURL + process.env.VUE_APP_API_PREFIX
 // request interceptor
 // request interceptor
 axios.interceptors.request.use(
 axios.interceptors.request.use(

+ 4 - 2
Strides-Admin/src/layout/components/Navbar.vue

@@ -59,12 +59,14 @@
       </div> -->
       </div> -->
       <div
       <div
         class="right-menu-image"
         class="right-menu-image"
-        @click="onClickMessageButton">
+        @click="onClickMessageButton"
+        title="Notification">
         <i class="el-icon-message-solid"></i>
         <i class="el-icon-message-solid"></i>
       </div>
       </div>
       <div
       <div
         class="right-menu-image"
         class="right-menu-image"
-        @click="logout">
+        @click="logout"
+        title="Log out">
         <i class="el-icon-switch-button bold"></i>
         <i class="el-icon-switch-button bold"></i>
       </div>
       </div>
     </div>
     </div>

+ 19 - 6
Strides-Admin/src/router/EnergyRouter.js

@@ -35,15 +35,14 @@ export default {
     },
     },
     {
     {
       path: '/smart-energy-management/site-load-balancing',
       path: '/smart-energy-management/site-load-balancing',
-      component: () => import('@/views/charging/ConfigureStations'),
-      name: 'site-load-balancing',
+      component: () => import('@/views/charging/LoadBalance'),
+      name: 'view-charging-profile',
       meta: {
       meta: {
         title: 'Site Load Balancing',
         title: 'Site Load Balancing',
+        breadcrumb: true,
         icon: 'sidebar-submenu-item',
         icon: 'sidebar-submenu-item',
-        activeIcon: 'sidebar-submenu-item-active',
-        breadcrumb: true
-      },
-      hidden: true
+        activeIcon: 'sidebar-submenu-item-active'
+      }
     },
     },
     {
     {
       path: '/smart-energy-management/charging-profiles/add',
       path: '/smart-energy-management/charging-profiles/add',
@@ -78,6 +77,20 @@ export default {
         }
         }
       },
       },
       hidden: true
       hidden: true
+    },
+    {
+      path: '/smart-energy-management/site-load-balancing/:id',
+      component: () => import('@/views/charging/LoadBalanceView'),
+      name: 'view-charging-profile',
+      meta: {
+        title: 'Detail',
+        activeMenu: '/smart-energy-management/site-load-balancing',
+        parent: {
+          title: 'Site Load Balancing',
+          path: "/smart-energy-management/site-load-balancing"
+        }
+      },
+      hidden: true
     }
     }
   ]
   ]
 }
 }

+ 19 - 3
Strides-Admin/src/router/ReportsRouter.js

@@ -1,12 +1,12 @@
 import Layout from '@/layout'
 import Layout from '@/layout'
 
 
-export default {
+export default [{
   path: '/reports',
   path: '/reports',
   component: Layout,
   component: Layout,
   children: [
   children: [
     {
     {
       path: '/reports',
       path: '/reports',
-      component: () => import('@/views/Reports'),
+      component: () => import('@/views/report/Reports'),
       name: 'reports',
       name: 'reports',
       meta: {
       meta: {
         title: 'Reports',
         title: 'Reports',
@@ -15,4 +15,20 @@ export default {
       }
       }
     }
     }
   ],
   ],
-}
+},
+{
+  path: '/csms-reports',
+  component: Layout,
+  children: [
+    {
+      path: '/csms-reports',
+      component: () => import('@/views/report/ReportV2'),
+      name: 'reports',
+      meta: {
+        title: 'Reports',
+        icon: 'reports',
+        activeIcon: 'reports-active',
+      }
+    }
+  ]
+}]

+ 1 - 1
Strides-Admin/src/router/index.js

@@ -107,7 +107,7 @@ const constantRoutes = [
   UserRouter,
   UserRouter,
   SupportRouter,
   SupportRouter,
   OCPPRouter,
   OCPPRouter,
-  ReportsRouter,
+  ...ReportsRouter,
   NotificationRouter,
   NotificationRouter,
   PartnershipRouter,
   PartnershipRouter,
   AccessRouter,
   AccessRouter,

+ 1 - 0
Strides-Admin/src/store/modules/user.js

@@ -86,6 +86,7 @@ const actions = {
     return new Promise((resolve, reject) => {
     return new Promise((resolve, reject) => {
       commit('SET_TOKEN', '')
       commit('SET_TOKEN', '')
       commit('SET_ROLES', [])
       commit('SET_ROLES', [])
+      commit('SET_RESOURCES', [])
       removeToken()
       removeToken()
       removeAuthRoutes()
       removeAuthRoutes()
       resetRouter()
       resetRouter()