From 648f031ebe666611477daf4c7be0ac041c131173 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E7=99=BD=E8=8F=9C?=
<43331987+JiaLiBai@users.noreply.github.com>
Date: Mon, 19 Jan 2026 17:30:03 +0800
Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
pages.json | 2 +-
pages/index.vue | 7 +-
pages/login.vue | 423 +++++++++++++++++----------------
pages/ticket/index.vue | 5 +-
pages/work/DateRangeSelect.vue | 8 +-
pages/work/bmsdcc/index.vue | 22 +-
pages/work/bmszl/index.vue | 20 +-
pages/work/db/index.vue | 21 +-
pages/work/dtdc/index.vue | 6 +-
pages/work/index.vue | 367 +++++++++++++++++-----------
pages/work/pcs/index.vue | 46 ++--
static/scss/global.scss | 34 ++-
12 files changed, 536 insertions(+), 425 deletions(-)
diff --git a/pages.json b/pages.json
index be3f6bc..6748101 100644
--- a/pages.json
+++ b/pages.json
@@ -12,7 +12,7 @@
}, {
"path": "pages/index",
"style": {
- "navigationBarTitleText": "移动端框架",
+ "navigationBarTitleText": "工单列表",
"navigationStyle": "custom",
"onReachBottomDistance": 100
}
diff --git a/pages/index.vue b/pages/index.vue
index 54b3d0f..cb7b268 100644
--- a/pages/index.vue
+++ b/pages/index.vue
@@ -1,5 +1,6 @@
+
@@ -128,11 +129,11 @@
.btn-list {
position: fixed;
- top: 0;
+ top: var(--status-bar-height);
left: 0;
width: 100%;
z-index: 2;
- padding: 30rpx 30rpx;
+ padding: 20rpx 30rpx;
background: #ffffff;
.btns {
@@ -152,7 +153,7 @@
}
.content {
- padding: 170rpx 40rpx 120rpx 40rpx;
+ padding: 80px 30rpx 120rpx 30rpx;
z-index: 1;
}
diff --git a/pages/login.vue b/pages/login.vue
index bddc4fa..e9a1e3b 100644
--- a/pages/login.vue
+++ b/pages/login.vue
@@ -1,210 +1,213 @@
-
-
-
-
-
- EMS移动端登录
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 没有账号?
- 立即注册
-
-
- 登录即代表同意
- 《用户协议》
- 《隐私协议》
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+ 上动EMS登录
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 没有账号?
+ 立即注册
+
+
+ 登录即代表同意
+ 《用户协议》
+ 《隐私协议》
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages/ticket/index.vue b/pages/ticket/index.vue
index feb8948..f339d1f 100644
--- a/pages/ticket/index.vue
+++ b/pages/ticket/index.vue
@@ -143,9 +143,9 @@
})
},
},
- mounted() {
+ onLoad(options) {
uni.showLoading()
- getTicket(this.$route.query.id).then(response => {
+ getTicket(options.id).then(response => {
this.info = JSON.parse(JSON.stringify(response?.data || {}))
const {
images = ''
@@ -164,6 +164,7 @@
}).finally(() => {
uni.hideLoading()
})
+
}
}
diff --git a/pages/work/DateRangeSelect.vue b/pages/work/DateRangeSelect.vue
index 0128295..caa3547 100644
--- a/pages/work/DateRangeSelect.vue
+++ b/pages/work/DateRangeSelect.vue
@@ -92,6 +92,7 @@
padding-left: 0;
padding-right: 0;
text-align: center;
+ font-size: 26rpx;
&:not(:last-child) {
margin-right: 20rpx;
@@ -103,7 +104,12 @@
}
.large {
- width: 180rpx;
+ width: 160rpx;
+ background-color: #547ef4;
+
+ &[disabled][type=primary] {
+ background-color: #89a8ffe6;
+ }
}
}
}
diff --git a/pages/work/bmsdcc/index.vue b/pages/work/bmsdcc/index.vue
index 2fdec8b..d341f36 100644
--- a/pages/work/bmsdcc/index.vue
+++ b/pages/work/bmsdcc/index.vue
@@ -20,29 +20,29 @@
-
-
+
+
工作状态
{{workStatusOptions[item.workStatus] || '-'}}
-
-
+
+
与PCS通信
{{communicationStatusOptions[item.pcsCommunicationStatus] || '-'}}
-
-
+
+
与EMS通信
{{communicationStatusOptions[item.emsCommunicationStatus] || '-'}}
-
-
+
+
@@ -182,9 +182,9 @@
}
},
- mounted() {
+ onLoad(options) {
uni.showLoading()
- this.siteId = this.$route.query.siteId || ''
+ this.siteId = options.siteId || ''
getBMSBatteryCluster({
siteId: this.siteId
}).then(response => {
@@ -192,7 +192,7 @@
if (this.list.length > 0) {
this.$nextTick(() => {
setTimeout(() => {
- this.$refs.collapse.resize()
+ // this.$refs.collapse.resize()
uni.hideLoading()
}, 100)
})
diff --git a/pages/work/bmszl/index.vue b/pages/work/bmszl/index.vue
index e66cfeb..abc5ff3 100644
--- a/pages/work/bmszl/index.vue
+++ b/pages/work/bmszl/index.vue
@@ -19,29 +19,29 @@
-
-
+
+
工作状态
{{workStatusOptions[item.workStatus] || '-'}}
-
-
+
+
与PCS通信
{{communicationStatusOptions[item.pcsCommunicationStatus] || '-'}}
-
-
+
+
与EMS通信
{{communicationStatusOptions[item.emsCommunicationStatus] || '-'}}
-
-
+
+
@@ -187,9 +187,9 @@
}
},
- mounted() {
+ onLoad(options) {
uni.showLoading()
- this.siteId = this.$route.query.siteId || ''
+ this.siteId = options.siteId || ''
getBMSOverView({
siteId: this.siteId
}).then(response => {
diff --git a/pages/work/db/index.vue b/pages/work/db/index.vue
index afa99f9..4424bfd 100644
--- a/pages/work/db/index.vue
+++ b/pages/work/db/index.vue
@@ -147,19 +147,24 @@
}
},
- mounted() {
+ onLoad(options) {
uni.showLoading()
- this.siteId = this.$route.query.siteId || ''
+ this.siteId = options.siteId || ''
getAmmeterDataList({
siteId: this.siteId
}).then(response => {
this.list = response?.data || []
- this.$nextTick(() => {
- setTimeout(() => {
- this.$refs.collapse.resize()
- uni.hideLoading()
- }, 100)
- })
+ if (this.list.length > 0) {
+ this.$nextTick(() => {
+ setTimeout(() => {
+ this.$refs.collapse.resize()
+ uni.hideLoading()
+ }, 1000)
+ })
+ } else {
+ uni.hideLoading()
+ }
+
}).catch(() => {
uni.hideLoading()
})
diff --git a/pages/work/dtdc/index.vue b/pages/work/dtdc/index.vue
index 55ea42b..054661e 100644
--- a/pages/work/dtdc/index.vue
+++ b/pages/work/dtdc/index.vue
@@ -387,9 +387,9 @@
})
},
},
- mounted() {
+ onLoad(options) {
// uni.showLoading()
- this.siteId = this.$route.query.siteId || ''
+ this.siteId = options.siteId || ''
this.getStackList()
this.getTableData(true)
}
@@ -455,6 +455,7 @@
border-bottom: 1px solid #eee;
padding: 20rpx 30rpx;
font-weight: 700;
+ font-size: 28rpx;
position: relative;
color: #333;
@@ -462,6 +463,7 @@
position: absolute;
top: 50%;
right: 20rpx;
+ font-size: 26rpx;
transform: translateY(-50%);
background-color: #4c7af3;
}
diff --git a/pages/work/index.vue b/pages/work/index.vue
index a8aea0c..396e2e1 100644
--- a/pages/work/index.vue
+++ b/pages/work/index.vue
@@ -1,58 +1,67 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- {{item.title}}:
- {{baseInfo[item.attr]}}
+
+
+
+
+
+ {{baseInfo.siteAddress || '-'}}
+
+
+
+ {{baseInfo.runningTime || '-'}}
+
-
-
-
-
-
-
+
+
+
+
+
+
-
- {{item.text}}
+ 装机功率(MW)
+ {{baseInfo.installPower}}
+
+
+
+
+ 装机容量(MW)
+ {{baseInfo.installCapacity}}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+ {{item.text}}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -129,40 +138,27 @@
},
// 图表数据结束
deviceCategoryOptions: [], //当前站点包含的设备类别
- siteType: 1,
siteTypeOptions: [{
text: '储能',
- value: 1,
+ value: 'cn',
+ children: []
},
{
text: '光能',
- value: 2,
+ value: 'gn',
+ disable: true,
+ children: []
},
{
text: '岸电',
- value: 3,
+ value: 'ad',
+ disable: true,
+ children: []
}
],
siteList: [],
siteId: '', //选择的站点ID
baseInfo: {}, //站点基本信息
- singleZdInfo: [{
- title: "电站位置",
- attr: "siteAddress",
- },
- {
- title: "投运时间",
- attr: "runningTime",
- },
- {
- title: "装机功率(MW)",
- attr: "installPower",
- },
- {
- title: "装机容量(MW)",
- attr: "installCapacity",
- },
- ],
gridList: [{
page: 'bmszl',
icon: 'icon-BMS',
@@ -222,12 +218,15 @@
} = e.detail
this.$tab.navigateTo(`/pages/work/${this.gridList[index].page}/index?siteId=${this.siteId}`)
},
- selectedSite(id) {
- if (id === this.siteId) return
- this.siteId = id
- if (this.siteType === 1) {
- this.updateSiteInfo()
- }
+ selectedSite(data) {
+ const [typeObj, siteObj] = data.detail.value
+ const {
+ text,
+ value
+ } = siteObj
+ if (value === this.siteId) return
+ this.siteId = value
+ this.updateSiteInfo()
},
updateSiteInfo() {
if (!this.siteId) return
@@ -236,18 +235,10 @@
this.getGVQXData()
this.getSiteDeviceCategory()
},
- selectedSiteType(id) {
- if (id === this.siteType) return
- this.siteType = id
- this.siteId = ''
- this.baseInfo = {}
- this.weekChartData = {}
- this.activeChartData = {}
- },
getSiteList() {
getAllSites().then(response => {
const data = response?.data || []
- this.siteList = data.map(item => {
+ this.siteTypeOptions.find(i => i.value === 'cn').children = data.map(item => {
return {
text: item.siteName,
value: item.siteId,
@@ -374,13 +365,11 @@
}
},
// 页面切换不会重新调用,如果希望每次切换页面都重新调接口,使用onShow
- mounted() {
+ onLoad() {
this.$nextTick(() => {
+ this.getSiteList()
this.$refs.weekChartDateRangeSelect.init()
this.$refs.activeChartDateRangeSelect.init(true)
- if (this.siteType === 1) {
- this.getSiteList()
- }
})
},
// 页面滚动 设置pageScrollTop chart显示需要
@@ -414,80 +403,172 @@
margin-top: 10rpx;
}
- .sections-list {
- margin-bottom: 10rpx;
+ // 站点选择
+ .site-sections-list {
+ background: linear-gradient(to right, #547ef4, #679ff5);
+ padding: 30rpx 30rpx;
+ padding-bottom: 100rpx;
- ::v-deep &>.uni-section-header {
- font-weight: 700;
+ .info {
+ color: #fff;
font-size: 26rpx;
line-height: 30rpx;
- }
- }
+ vertical-align: middle;
+ margin-top: 20rpx;
- .sections-list:not(:first-child) {
- margin-top: 40rpx;
- }
+ >.list {
+ display: flex;
+ justify-content: flex-start;
+ align-items: center;
- ::v-deep {
- .uni-section__content-title {
- font-size: 26rpx !important;
- }
+ &:not(:last-child) {
+ margin-bottom: 20rpx;
+ }
- .uni-select__input-box {
- width: 100%;
+ >.uni-icons {
+ margin-right: 10rpx;
+ }
- .uni-select__input-text {
- font-size: 24rpx;
}
}
- .uni-select__selector-empty,
- .uni-select__selector-item {
- font-size: 24rpx;
- line-height: 36rpx;
- padding-top: 10rpx;
- padding-bottom: 10rpx;
- text-align: left;
+ .uni-data-tree {
+
+ ::v-deep {
+ .input-value {
+ border: none;
+ padding-left: 0;
+
+ .selected-area {
+ width: 90%;
+ flex: none;
+ white-space: nowrap;
+ overflow: hidden;
+ text-overflow: ellipsis;
+
+ .selected-list {
+ color: #fff;
+ }
+ }
+
+ // 选择中的文字样式
+ .text-color {
+ color: #fff;
+ font-size: 34rpx;
+ font-weight: bolder;
+ }
+
+ // 右侧箭头
+ .arrow-area {
+ transform: rotate(-135deg);
+
+ .input-arrow {
+ border-color: #fff;
+ }
+ }
+
+ }
+ }
+
}
}
- .grid-item-box {
- flex: 1;
- /* #ifndef APP-NVUE */
- display: flex;
- /* #endif */
- flex-direction: column;
- align-items: center;
- justify-content: center;
- padding: 30rpx 0;
+ // 基本信息
+ .base-info {
+ margin-top: -80rpx;
+ border-radius: 80rpx 80rpx 0 0;
+ padding: 30rpx;
+ background-color: #fff;
+
+ // 装机功率
+ .install-data {
+ .grid-item-box {
+ padding-top: 6rpx;
+ padding-bottom: 6rpx;
+
+ .text {
+ margin-top: 20rpx;
+ color: #000;
+ }
+ }
- .icon {
- font-size: 52rpx;
- color: #3a98ff;
}
- .text {
+
+ .sections-list {
+ margin-bottom: 10rpx;
+
+ ::v-deep &>.uni-section-header {
+ font-weight: 700;
+ font-size: 26rpx;
+ line-height: 30rpx;
+ }
+ }
+
+ .sections-list:not(:first-child) {
+ margin-top: 40rpx;
+ }
+
+ ::v-deep {
+ .uni-section__content-title {
+ font-size: 26rpx !important;
+ }
+
+ .uni-select__input-box {
+ width: 100%;
+
+ .uni-select__input-text {
+ font-size: 24rpx;
+ }
+ }
+
+ .uni-select__selector-empty,
+ .uni-select__selector-item {
+ font-size: 24rpx;
+ line-height: 36rpx;
+ padding-top: 10rpx;
+ padding-bottom: 10rpx;
+ text-align: left;
+ }
+
+ // .uni-date__x-input {
+ // height: 50rpx;
+ // line-height: 50rpx;
+ // font-size: 26rpx;
+ // }
+ }
+
+ .work-box {
+
+ .icon {
+ font-size: 52rpx;
+ color: #547ef4;
+ }
+
+ .text {
+ font-size: 26rpx;
+ padding-top: 10rpx;
+ color: #000;
+ }
+ }
+
+
+
+ .base-lists {
font-size: 24rpx;
- padding-top: 10rpx;
- }
- }
+ line-height: 40rpx;
+ padding: 10rpx 20rpx;
+ padding-left: 40rpx;
+ .left {
+ width: 220rpx;
+ display: inline-block;
+ color: #666;
+ }
-
- .base-lists {
- font-size: 24rpx;
- line-height: 40rpx;
- padding: 10rpx 20rpx;
- padding-left: 40rpx;
-
- .left {
- width: 220rpx;
- display: inline-block;
- color: #666;
- }
-
- .right {
- color: #333;
+ .right {
+ color: #333;
+ }
}
}
diff --git a/pages/work/pcs/index.vue b/pages/work/pcs/index.vue
index d867a0d..cdfc99e 100644
--- a/pages/work/pcs/index.vue
+++ b/pages/work/pcs/index.vue
@@ -4,9 +4,9 @@
-
- {{item.title}}
- {{runningHeadInfo[item.attr] | formatNumber}}
+
+ {{item.title}}
+ {{runningHeadInfo[item.attr] | formatNumber}}
@@ -30,33 +30,33 @@
-
-
+
+
工作状态
{{workStatusOptions[item.workStatus] || '-'}}
-
-
+
+
并网状态
{{gridStatusOptions[item.gridStatus] || '-'}}
-
-
+
+
设备状态
{{deviceStatusOptions[item.deviceStatus] || '-'}}
-
-
+
+
控制模式
{{controlModeOptions[item.controlMode] || '-'}}
-
-
+
+
-
-
+
+
直流功率
{{pcsBranchItem.dcPower}}kW
-
-
+
+
直流电压
{{pcsBranchItem.dcVoltage}}V
-
-
+
+
直流电流
{{pcsBranchItem.dcCurrent}}A
-
-
+
+
@@ -262,9 +262,9 @@
]
}
},
- mounted() {
+ onLoad(options) {
uni.showLoading()
- this.siteId = this.$route.query.siteId || ''
+ this.siteId = options.siteId || ''
getRunningHeadInfo({
siteId: this.siteId
}).then(response => {
diff --git a/static/scss/global.scss b/static/scss/global.scss
index c145170..cc2f436 100644
--- a/static/scss/global.scss
+++ b/static/scss/global.scss
@@ -88,7 +88,15 @@
}
}
}
-
+.status-bar{
+ background: #fff;
+ width: 100%;
+ height: var(--status-bar-height);
+ position: fixed;
+ top:0;
+ left: 0;
+ z-index:99;
+}
// 暂无数据通用样式
@@ -97,7 +105,7 @@
text-align: center;
line-height: 100px;
height: 100px;
- font-size: 18px;
+ font-size: 30rpx;
}
// 九宫格
.grid-item-box {
@@ -126,6 +134,12 @@
}
}
+.flex-container{
+ display: flex;
+ .flex-lists{
+ flex:1;
+ }
+}
// 设备详情页面 状态公共样式
.common-collapse-item{
.content{
@@ -145,9 +159,10 @@
display: inline-block;
vertical-align: middle;
color:#fff;
- padding:4rpx 10rpx;
+ padding:0 10rpx;
margin-right: 10rpx;
font-size: 22rpx;
+ line-height: 38rpx;
border-radius: 10rpx;
}
.name{
@@ -158,11 +173,6 @@
}
// 设备状态卡片
.status-card-group{
- &.no-wrapper-padding{
- .uni-group__content{
- padding:0;
- }
- }
.uni-group__content{
padding-top:0;
padding-bottom:0;
@@ -212,9 +222,11 @@
.child-table{
.uni-table-th{
color:#333;
+ font-size: 26rpx;
}
.uni-table-td{
color:#000;
+ font-size: 26rpx;
}
.table--border{
border-color:#ebedf0;
@@ -258,7 +270,7 @@
}
}
.content{
- background: linear-gradient(to bottom, #22bb5873, #45db7a26);
+ background-color:rgba(69,219,122,0.15);
}
// 状态九宫格
.status-card-group{
@@ -290,7 +302,7 @@
}
}
.content{
- background: linear-gradient(to bottom, #f5604e73, #f5604e26);
+ background: rgba(245,96,78,0.15);
}
// 状态九宫格
.status-card-group{
@@ -322,7 +334,7 @@
}
}
.content{
- background: linear-gradient(to bottom, #8c8c8c73, #8c8c8c26);
+ background: rgba(140,140,140,0.15);
}
// 状态九宫格
.status-card-group{