@flexem/fc-gui 3.0.0-alpha.72 → 3.0.0-alpha.74
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md
CHANGED
|
@@ -314,4 +314,14 @@
|
|
|
314
314
|
## 3.0.0-alpha.72(2023-03-13)
|
|
315
315
|
### Web端
|
|
316
316
|
#### Bug Fix
|
|
317
|
-
1. 修改设备告警的订阅事件
|
|
317
|
+
1. 修改设备告警的订阅事件
|
|
318
|
+
|
|
319
|
+
## 3.0.0-alpha.73(2023-03-13)
|
|
320
|
+
### Web端
|
|
321
|
+
#### Bug Fix
|
|
322
|
+
1. 解决当前告警当第二页的报警恢复后,无告警时,翻页未自动翻到第一页的问题
|
|
323
|
+
|
|
324
|
+
## 3.0.0-alpha.74(2023-03-17)
|
|
325
|
+
### Web端
|
|
326
|
+
#### Bug Fix
|
|
327
|
+
1. FLEXCLOUD-2535 【app】分页器与表格分离
|
|
@@ -40133,6 +40133,11 @@ class alarm_element_AlarmElement extends conditional_display_element_Conditional
|
|
|
40133
40133
|
if (!result.error) {
|
|
40134
40134
|
this.totalCount = result.totalCount;
|
|
40135
40135
|
this.currentAlarmList = result.items;
|
|
40136
|
+
if (!result.items.length && result.totalCount) {
|
|
40137
|
+
this.page = 0;
|
|
40138
|
+
this.init();
|
|
40139
|
+
return;
|
|
40140
|
+
}
|
|
40136
40141
|
this.alarmList = this.currentAlarmList.map(item => [
|
|
40137
40142
|
item.name,
|
|
40138
40143
|
item.message,
|
|
@@ -40171,41 +40176,41 @@ class alarm_element_AlarmElement extends conditional_display_element_Conditional
|
|
|
40171
40176
|
text-align: ${this.model.generalSetting.headerFont.textAlign};
|
|
40172
40177
|
${this.model.generalSetting.headerFont.isUnderline ? 'text-decoration: underline' : ''};
|
|
40173
40178
|
vertical-align: middle;`;
|
|
40174
|
-
for (let
|
|
40179
|
+
for (let row = 0; row < 4; row++) {
|
|
40175
40180
|
const th = document.createElement('th');
|
|
40176
|
-
th.innerHTML = this.model.columLabels[
|
|
40177
|
-
th.style.cssText = `width: ${this.model.widths[
|
|
40181
|
+
th.innerHTML = this.model.columLabels[row];
|
|
40182
|
+
th.style.cssText = `width: ${this.model.widths[row] / this.model.size.width * 100}%;
|
|
40178
40183
|
border-style: solid;
|
|
40179
40184
|
border-color: ${this.model.generalSetting.splitLine};
|
|
40180
|
-
border-left-width: ${!
|
|
40185
|
+
border-left-width: ${!row || this.model.generalSetting.isHiddenColumnSplitLine ? 0 : 1}px;`;
|
|
40181
40186
|
tr.appendChild(th);
|
|
40182
40187
|
}
|
|
40183
40188
|
table.appendChild(tr);
|
|
40184
40189
|
const levelColors = ['#3695FF', '#FFE900', '#FFA800', '#E84F4F'];
|
|
40185
|
-
for (let
|
|
40190
|
+
for (let row = 0; row < this.pageSize; row++) {
|
|
40186
40191
|
tr = document.createElement('tr');
|
|
40187
|
-
tr.style.cssText = `height: ${this.model.heights[
|
|
40192
|
+
tr.style.cssText = `height: ${this.model.heights[row + 1]}px;
|
|
40188
40193
|
background: ${this.model.generalSetting.tableFillColor};
|
|
40189
40194
|
font: ${this.model.generalSetting.fontStyle};
|
|
40190
40195
|
color: ${this.model.generalSetting.fontColor};
|
|
40191
40196
|
text-align: ${this.model.generalSetting.textAlign};
|
|
40192
40197
|
vertical-align: middle;`;
|
|
40193
|
-
for (let
|
|
40198
|
+
for (let col = 0; col < 4; col++) {
|
|
40194
40199
|
const td = document.createElement('td');
|
|
40195
40200
|
td.style.cssText = `border-style: solid;
|
|
40196
40201
|
border-color: ${this.model.generalSetting.splitLine};
|
|
40197
40202
|
border-top-width: ${this.model.generalSetting.isHiddenColumnSplitLine ? 0 : 1}px;
|
|
40198
|
-
border-left-width: ${!
|
|
40199
|
-
if (this.alarmList[
|
|
40200
|
-
if (
|
|
40201
|
-
td.innerHTML = this.alarmList[
|
|
40203
|
+
border-left-width: ${!col || this.model.generalSetting.isHiddenColumnSplitLine ? 0 : 1}px;`;
|
|
40204
|
+
if (this.alarmList[row]) {
|
|
40205
|
+
if (col !== 2) {
|
|
40206
|
+
td.innerHTML = this.alarmList[row][col];
|
|
40202
40207
|
td.style.cssText += `${this.model.generalSetting.isUnderline ? 'text-decoration: underline' : ''};`;
|
|
40203
40208
|
}
|
|
40204
40209
|
else {
|
|
40205
40210
|
const alarmLevel = document.createElement('div');
|
|
40206
40211
|
let alarmHeight = parseInt(this.model.generalSetting.fontSize) + 15;
|
|
40207
|
-
if (alarmHeight > this.model.heights[
|
|
40208
|
-
alarmHeight = this.model.heights[
|
|
40212
|
+
if (alarmHeight > this.model.heights[row + 1])
|
|
40213
|
+
alarmHeight = this.model.heights[row + 1];
|
|
40209
40214
|
let margin = '0 15px';
|
|
40210
40215
|
if (this.model.generalSetting.textAlign === 'left') {
|
|
40211
40216
|
margin = '0 30px 0 0';
|
|
@@ -40215,19 +40220,32 @@ class alarm_element_AlarmElement extends conditional_display_element_Conditional
|
|
|
40215
40220
|
}
|
|
40216
40221
|
alarmLevel.style.cssText = `margin: ${margin};
|
|
40217
40222
|
border-radius: 5px;
|
|
40218
|
-
background: ${levelColors[this.alarmList[
|
|
40223
|
+
background: ${levelColors[this.alarmList[row][col]]};
|
|
40219
40224
|
color: #ffffff;
|
|
40220
|
-
width: ${this.model.widths[
|
|
40225
|
+
width: ${this.model.widths[col] - 30}px;
|
|
40221
40226
|
height: ${alarmHeight}px;
|
|
40222
|
-
max-height: ${this.model.heights[
|
|
40227
|
+
max-height: ${this.model.heights[row + 1]}px;
|
|
40223
40228
|
display: flex;
|
|
40224
40229
|
justify-content: center;
|
|
40225
40230
|
align-items: center;
|
|
40226
40231
|
${this.model.generalSetting.isUnderline ? 'text-decoration: underline' : ''};`;
|
|
40227
|
-
alarmLevel.innerHTML = this.model.levelText[this.alarmList[
|
|
40232
|
+
alarmLevel.innerHTML = this.model.levelText[this.alarmList[row][col]];
|
|
40228
40233
|
td.appendChild(alarmLevel);
|
|
40229
40234
|
}
|
|
40230
40235
|
}
|
|
40236
|
+
else if (col === 2) {
|
|
40237
|
+
const alarmLevel = document.createElement('div');
|
|
40238
|
+
let margin = '0 15px';
|
|
40239
|
+
if (this.model.generalSetting.textAlign === 'left') {
|
|
40240
|
+
margin = '0 30px 0 0';
|
|
40241
|
+
}
|
|
40242
|
+
else if (this.model.generalSetting.textAlign === 'right') {
|
|
40243
|
+
margin = '0 0 0 30px';
|
|
40244
|
+
}
|
|
40245
|
+
alarmLevel.style.cssText = `margin: ${margin};
|
|
40246
|
+
width: ${this.model.widths[col] - 30}px;`;
|
|
40247
|
+
td.appendChild(alarmLevel);
|
|
40248
|
+
}
|
|
40231
40249
|
tr.appendChild(td);
|
|
40232
40250
|
}
|
|
40233
40251
|
table.appendChild(tr);
|