Skip to content

Commit b97071a

Browse files
authored
fix: Fifth round of bug fixes for private update & update transfer & HTTP speed limit online configuration features (#282)
Fixed the following issues: [V25 2500U1][Update Management System][Enterprise Update Management System][Sixth Round Testing] When the server supports P2P and the terminal successfully connects, the transfer optimization switch in Control Center should be grayed out and non-closable [V25 2500U1][Update Management System][Control Center Update Client][Sixth Round Testing][Public Network] After checking the upload speed limit and download speed limit checkboxes of transfer optimization sub-items, unchecking them again causes the speed limit value to change to 104857 [V25 2500U1][Update Management System][Control Center Update Client][Fourth Round Testing] After modifying the status or value of transfer optimization upload/download speed limits, reopening Control Center causes the transfer optimization upload/download speed limit positions to change [V25 2500U1][Update Management System][Control Center Update Client][Sixth Round Testing][Public Network] The English translation of transfer optimization does not match requirements [V25 2500U1][Update Management System][Control Center Update Client][Sixth Round Testing][System Update][Public Network] When enabling or disabling transfer optimization settings fails, a retry dialog appears with prompt information and buttons inconsistent with requirements [V25 2500U1][Update Management System][Control Center Update Client][Sixth Round Testing][Public Network] When enabling or disabling transfer optimization sub-item settings fails, the dialog display does not match requirements [V25 2500U1][Update Management System][Control Center Update Client][Sixth Round Testing][Public Network] When enabling transfer optimization settings fails, the dialog needs to support closing with Esc key [V25 2500U1][Update Management System][Control Center Update Client][Sixth Round Testing][Public Network] When enabling or disabling transfer optimization sub-item settings fails, the dialog needs to support closing with Esc key [V25 2500U1][Update Management System][Control Center Update Client][Sixth Round Testing][System Update][Public Network] The display names of transfer optimization sub-items need to match requirements [V25 2500U1][Update Management System][Control Center Update Client][First Round Testing][System Update][Public Network] After the client successfully connects, the public network update plugin in the taskbar plugin area is not blocked [V25 2500U1][Update Management System][Enterprise Update Management System][Sixth Round Testing] After the server authorization file switches from not supporting P2P to supporting P2P, the order of the transfer optimization menu in the client Control Center changes, and it is restored after restart Log: As above Bug: https://pms.uniontech.com/bug-view-357875.html https://pms.uniontech.com/bug-view-358203.html https://pms.uniontech.com/bug-view-357291.html https://pms.uniontech.com/bug-view-358231.html https://pms.uniontech.com/bug-view-358257.html https://pms.uniontech.com/bug-view-358321.html https://pms.uniontech.com/bug-view-358303.html https://pms.uniontech.com/bug-view-358357.html https://pms.uniontech.com/bug-view-358365.html https://pms.uniontech.com/bug-view-354239.html https://pms.uniontech.com/bug-view-358585.html Influence: Affects private update & update transfer & HTTP speed limit online configuration features fix: 私有化更新&更新传递&http限速在线配置功能第五轮bug修复 修复以下问题: 【V25 2500U1】【更新管理系统】【企业级更新管理系统】【第六轮测试】服务端支持P2P,终端接入成功后,控制中心-传递优化开关应该置灰并不可关闭 【V25 2500U1】【更新管理系统】【控制中心更新客户端】【第六轮测试】【公网】勾选传递优化子配置项的上传限速和下载限速复选框,再次去勾选复选框,限速值变成了104857 【V25 2500U1】【更新管理系统】【控制中心更新客户端】【第四轮测试】修改传递优化上传下载限速的状态或者值,重新打开控制中心,传递优化上传下载限速位置发生变化 【V25 2500U1】【更新管理系统】【控制中心更新客户端】【第六轮测试】【公网】传递优化英文翻译与需求不一致 【V25 2500U1】【更新管理系统】【控制中心更新客户端】【第六轮测试】【系统更新】【公网】传递优化设置项开启或关闭失败,出现重试弹窗,提示信息和按钮与需求不一致 【V25 2500U1】【更新管理系统】【控制中心更新客户端】【第六轮测试】【公网】传递优化设置项子配置项开启或关闭失败,弹窗展示与需求不一致 【V25 2500U1】【更新管理系统】【控制中心更新客户端】【第六轮测试】【公网】传递优化设置项开启失败,弹窗需要支持Esc键关闭弹窗 【V25 2500U1】【更新管理系统】【控制中心更新客户端】【第六轮测试】【公网】传递优化设置项子配置项开启或关闭失败,弹窗需要支持esc关闭操作 【V25 2500U1】【更新管理系统】【控制中心更新客户端】【第六轮测试】【系统更新】【公网】传递优化子配置项展示名称需要与需求一致 【V25 2500U1】【更新管理系统】【企业级更新管理系统】【第一轮测试】客户端接入成功之后,任务栏插件区域公网更新插件未屏蔽 【V25 2500U1】【更新管理系统】【企业级更新管理系统】【第六轮测试】服务端授权文件从不支持P2P切换为支持P2P之后,客户端控制中心传递优化菜单顺序发生变化,重启后恢复 Log:如上所述 Bug:https://pms.uniontech.com/bug-view-357875.html https://pms.uniontech.com/bug-view-358203.html https://pms.uniontech.com/bug-view-357291.html https://pms.uniontech.com/bug-view-358231.html https://pms.uniontech.com/bug-view-358257.html https://pms.uniontech.com/bug-view-358321.html https://pms.uniontech.com/bug-view-358303.html https://pms.uniontech.com/bug-view-358357.html https://pms.uniontech.com/bug-view-358365.html https://pms.uniontech.com/bug-view-354239.html https://pms.uniontech.com/bug-view-358585.html Influence:影响私有化更新&更新传递&http限速在线配置功能
1 parent 537e84f commit b97071a

9 files changed

Lines changed: 130 additions & 61 deletions

File tree

src/dcc-update-plugin/operation/updatedatastructs.h

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -316,7 +316,11 @@ inline QString transferDeliveryConfigToLastoreDeliveryConfig(const QString& deli
316316
LastoreUpgradeSpeedLimitConfig lastoreDeliveryConfig;
317317
lastoreDeliveryConfig.isOnlineSpeedLimit = UpgradeSpeedLimitConfig::fromJson(deliveryConfig.toUtf8()).ifInOnlineLimit();
318318
lastoreDeliveryConfig.speedLimitEnabled = UpgradeSpeedLimitConfig::fromJson(deliveryConfig.toUtf8()).shouldLimitRate();
319-
lastoreDeliveryConfig.limitSpeed = QString::number(UpgradeSpeedLimitConfig::fromJson(deliveryConfig.toUtf8()).currentRate);
319+
if (lastoreDeliveryConfig.isOnlineSpeedLimit) {
320+
lastoreDeliveryConfig.limitSpeed = QString::number(UpgradeSpeedLimitConfig::fromJson(deliveryConfig.toUtf8()).currentRate);
321+
} else {
322+
lastoreDeliveryConfig.limitSpeed = QString::number(UpgradeSpeedLimitConfig::fromJson(deliveryConfig.toUtf8()).limitRate);
323+
}
320324
return lastoreDeliveryConfig.toJson();
321325
}
322326

src/dcc-update-plugin/qml/UpdateSetting.qml

Lines changed: 21 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ import org.deepin.dcc.update 1.0
1414
DccObject {
1515
id: root
1616
property bool syncingUpgradeDeliverySwitch: false
17-
property bool pendingUpgradeDeliveryEnabled: dccData.model().upgradeDeliveryEnable
1817

1918
FontMetrics {
2019
id: fm
@@ -34,7 +33,7 @@ DccObject {
3433
Layout.fillWidth: true
3534
horizontalAlignment: Text.AlignHCenter
3635
wrapMode: Text.WordWrap
37-
text: qsTr("Failed to change Upgrade Delivery setting")
36+
text: qsTr("Failed to change Delivery Optimization setting")
3837
}
3938

4039
Item {
@@ -48,12 +47,15 @@ DccObject {
4847
spacing: 10
4948

5049
ButtonWithToolTip {
51-
text: qsTr("OK")
50+
text: qsTr("Cancel")
5251
Layout.fillWidth: true
5352
focus: upgradeDeliverySetConfigFailedDialog.visible
5453
onClicked: {
5554
upgradeDeliverySetConfigFailedDialog.close()
5655
}
56+
Keys.onEscapePressed: {
57+
upgradeDeliverySetConfigFailedDialog.close()
58+
}
5759
}
5860

5961
component ButtonWithToolTip: D.Button {
@@ -103,8 +105,7 @@ DccObject {
103105
Layout.fillWidth: true
104106
horizontalAlignment: Text.AlignHCenter
105107
wrapMode: Text.WordWrap
106-
text: root.pendingUpgradeDeliveryEnabled ? qsTr("Update Delivery Optimization service exception. Failed to enable.")
107-
: qsTr("Update Delivery Optimization service exception. Failed to disable.")
108+
text: qsTr("Update Delivery Optimization service exception")
108109
}
109110

110111
Item {
@@ -123,12 +124,15 @@ DccObject {
123124
focus: upgradeDeliverySetEnableFailedDialog.visible
124125
onClicked: {
125126
upgradeDeliverySetEnableFailedDialog.close()
126-
dccData.work().setUpgradeDeliveryEnabled(root.pendingUpgradeDeliveryEnabled, true)
127+
dccData.work().setUpgradeDeliveryEnabled(!dccData.model().upgradeDeliveryEnable, true)
128+
}
129+
Keys.onEscapePressed: {
130+
upgradeDeliverySetEnableFailedDialog.close()
127131
}
128132
}
129133

130134
EnableFailedDialogButton {
131-
text: qsTr("OK")
135+
text: qsTr("Cancel")
132136
Layout.fillWidth: true
133137
onClicked: {
134138
upgradeDeliverySetEnableFailedDialog.close()
@@ -173,6 +177,7 @@ DccObject {
173177
parentName: "updateSettingsPage"
174178
displayName: qsTr("Update Type")
175179
weight: 10
180+
visible: !dccData.model().isPrivateUpdate
176181
}
177182

178183
DccObject {
@@ -181,6 +186,7 @@ DccObject {
181186
parentName: "updateSettingsPage"
182187
weight: 20
183188
pageType: DccObject.Item
189+
visible: !dccData.model().isPrivateUpdate
184190
page: DccGroupView {
185191
height: implicitHeight + 10
186192
spacing: 0
@@ -245,15 +251,15 @@ DccObject {
245251

246252
DccObject {
247253
id: advancedSetting
248-
property bool showDetails: false
254+
property bool showDetails: dccData.model().isPrivateUpdate
249255
name: "advancedSettingTitle"
250256
parentName: "updateSettingsPage"
251257
displayName: qsTr("Advanced Settings")
252258
weight: 30
253259
pageType: DccObject.Item
254260
page: RowLayout {
255261
Component.onDestruction: {
256-
advancedSetting.showDetails = false
262+
advancedSetting.showDetails = false || dccData.model().isPrivateUpdate
257263
}
258264
DccLabel {
259265
property D.Palette textColor: D.Palette {
@@ -335,10 +341,10 @@ DccObject {
335341
DccObject {
336342
name: "upgradeDeliverySwitch"
337343
parentName: "upgradeDeliveryGrp"
338-
displayName: qsTr("Upgrade Delivery")
344+
displayName: qsTr("Delivery Optimization")
339345
description: qsTr("When enabled, your device may share previously downloaded system updates with other devices on your local network.When you turn it off, cached files from update delivery will be cleared during the next restart.")
340346
weight: 10
341-
enabled: !dccData.model().updateProhibited
347+
enabled: !dccData.model().isPrivateUpdate
342348
pageType: DccObject.Editor
343349
page: D.Switch {
344350
id: upgradeDeliverySwitch
@@ -347,7 +353,6 @@ DccObject {
347353
if (root.syncingUpgradeDeliverySwitch) {
348354
return
349355
}
350-
root.pendingUpgradeDeliveryEnabled = checked
351356
dccData.work().setUpgradeDeliveryEnabled(checked)
352357
}
353358
Connections {
@@ -365,7 +370,7 @@ DccObject {
365370
id: upgradeDeliveryUploadLimitSetting
366371
name: "upgradeDeliveryUploadLimitSetting"
367372
parentName: "upgradeDeliveryGrp"
368-
displayName: qsTr("Upgrade Delivery Upload Limit Setting")
373+
displayName: qsTr("Delivery Optimization-Upload throttling")
369374
visible: dccData.model().upgradeDeliveryEnable
370375
weight: 20
371376
enabled: !dccData.model().upgradeUploadSpeedIsOnline
@@ -465,9 +470,9 @@ DccObject {
465470
id: upgradeDeliveryDownloadLimitSetting
466471
name: "upgradeDeliveryDownloadLimitSetting"
467472
parentName: "upgradeDeliveryGrp"
468-
displayName: qsTr("Upgrade Delivery Download Limit Setting")
473+
displayName: qsTr("Delivery Optimization-Limit Speed")
469474
visible: dccData.model().upgradeDeliveryEnable
470-
weight: 20
475+
weight: 30
471476
enabled: !dccData.model().upgradeDownloadSpeedIsOnline
472477
pageType: DccObject.Item
473478
Connections {
@@ -566,7 +571,7 @@ DccObject {
566571
id: downloadLimitGrp
567572
name: "downloadLimitGrp"
568573
parentName: "advancedSettingGroup"
569-
weight: 40
574+
weight: 50
570575
enabled: !dccData.model().downloadIsOnlineSpeedLimit
571576
pageType: DccObject.Item
572577
page: DccGroupView {

src/dcc-update-plugin/translations/update_en.ts

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -422,6 +422,22 @@
422422
<source>Delivers updates for additional repository sources</source>
423423
<translation type="unfinished"></translation>
424424
</message>
425+
<message>
426+
<source>Delivery Optimization</source>
427+
<translation type="unfinished"></translation>
428+
</message>
429+
<message>
430+
<source>When enabled, your device may share previously downloaded system updates with other devices on your local network.When you turn it off, cached files from update delivery will be cleared during the next restart.</source>
431+
<translation type="unfinished"></translation>
432+
</message>
433+
<message>
434+
<source>Delivery Optimization-Limit Speed</source>
435+
<translation type="unfinished"></translation>
436+
</message>
437+
<message>
438+
<source>Delivery Optimization-Upload throttling</source>
439+
<translation type="unfinished"></translation>
440+
</message>
425441
<message>
426442
<source>Limit Speed</source>
427443
<translation type="unfinished"></translation>
@@ -494,6 +510,22 @@
494510
<source>Only numbers between 10-999999 are allowed</source>
495511
<translation type="unfinished"></translation>
496512
</message>
513+
<message>
514+
<source>Failed to change Delivery Optimization setting</source>
515+
<translation type="unfinished"></translation>
516+
</message>
517+
<message>
518+
<source>Update Delivery Optimization service exception</source>
519+
<translation type="unfinished"></translation>
520+
</message>
521+
<message>
522+
<source>Retry</source>
523+
<translation type="unfinished"></translation>
524+
</message>
525+
<message>
526+
<source>Cancel</source>
527+
<translation type="unfinished"></translation>
528+
</message>
497529
<message>
498530
<source>Join the internal testing channel to get deepin latest updates.</source>
499531
<translation type="unfinished"></translation>

src/dcc-update-plugin/translations/update_en_US.ts

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -422,6 +422,22 @@
422422
<source>Delivers updates for additional repository sources</source>
423423
<translation type="unfinished"></translation>
424424
</message>
425+
<message>
426+
<source>Delivery Optimization</source>
427+
<translation type="unfinished"></translation>
428+
</message>
429+
<message>
430+
<source>When enabled, your device may share previously downloaded system updates with other devices on your local network.When you turn it off, cached files from update delivery will be cleared during the next restart.</source>
431+
<translation type="unfinished"></translation>
432+
</message>
433+
<message>
434+
<source>Delivery Optimization-Limit Speed</source>
435+
<translation type="unfinished"></translation>
436+
</message>
437+
<message>
438+
<source>Delivery Optimization-Upload throttling</source>
439+
<translation type="unfinished"></translation>
440+
</message>
425441
<message>
426442
<source>Limit Speed</source>
427443
<translation type="unfinished"></translation>
@@ -490,6 +506,26 @@
490506
<source>Only numbers between 1-99999 are allowed</source>
491507
<translation type="unfinished"></translation>
492508
</message>
509+
<message>
510+
<source>Only numbers between 10-999999 are allowed</source>
511+
<translation type="unfinished"></translation>
512+
</message>
513+
<message>
514+
<source>Failed to change Delivery Optimization setting</source>
515+
<translation type="unfinished"></translation>
516+
</message>
517+
<message>
518+
<source>Update Delivery Optimization service exception</source>
519+
<translation type="unfinished"></translation>
520+
</message>
521+
<message>
522+
<source>Retry</source>
523+
<translation type="unfinished"></translation>
524+
</message>
525+
<message>
526+
<source>Cancel</source>
527+
<translation type="unfinished"></translation>
528+
</message>
493529
<message>
494530
<source>Join the internal testing channel to get deepin latest updates.</source>
495531
<translation type="unfinished"></translation>

src/dcc-update-plugin/translations/update_zh_CN.ts

Lines changed: 10 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -443,20 +443,20 @@
443443
<translation>提供额外添加的仓库源更新内容</translation>
444444
</message>
445445
<message>
446-
<source>Upgrade Delivery</source>
446+
<source>Delivery Optimization</source>
447447
<translation>传递优化</translation>
448448
</message>
449449
<message>
450450
<source>When enabled, your device may share previously downloaded system updates with other devices on your local network.When you turn it off, cached files from update delivery will be cleared during the next restart.</source>
451451
<translation>开启此功能,你的设备可能会将以前下载的部分系统更新发送到本地网络的设备上。关闭此功能后,将在重启时清除传递优化时缓存的文件</translation>
452452
</message>
453453
<message>
454-
<source>Upgrade Delivery Download Limit Setting</source>
455-
<translation>下载限速</translation>
454+
<source>Delivery Optimization-Limit Speed</source>
455+
<translation>传递优化-下载限速</translation>
456456
</message>
457457
<message>
458-
<source>Upgrade Delivery Upload Limit Setting</source>
459-
<translation>上传限速</translation>
458+
<source>Delivery Optimization-Upload throttling</source>
459+
<translation>传递优化-上传限速</translation>
460460
</message>
461461
<message>
462462
<source>Limit Speed</source>
@@ -531,24 +531,20 @@
531531
<translation>只允许输入10-999999</translation>
532532
</message>
533533
<message>
534-
<source>Failed to change Upgrade Delivery setting</source>
534+
<source>Failed to change Delivery Optimization setting</source>
535535
<translation>更新传递优化服务异常</translation>
536536
</message>
537537
<message>
538-
<source>Update Delivery Optimization service exception. Failed to enable.</source>
539-
<translation>更新传递优化服务异常,开启失败</translation>
540-
</message>
541-
<message>
542-
<source>Update Delivery Optimization service exception. Failed to disable.</source>
543-
<translation>更新传递优化服务异常,关闭失败</translation>
538+
<source>Update Delivery Optimization service exception</source>
539+
<translation>更新传递优化服务异常</translation>
544540
</message>
545541
<message>
546542
<source>Retry</source>
547543
<translation>再试一次</translation>
548544
</message>
549545
<message>
550-
<source>OK</source>
551-
<translation>确定</translation>
546+
<source>Cancel</source>
547+
<translation>取消</translation>
552548
</message>
553549
<message>
554550
<source>Join the internal testing channel to get deepin latest updates.</source>

src/dcc-update-plugin/translations/update_zh_HK.ts

Lines changed: 10 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -443,20 +443,20 @@
443443
<translation>提供額外添加的倉庫源更新內容</translation>
444444
</message>
445445
<message>
446-
<source>Upgrade Delivery</source>
446+
<source>Delivery Optimization</source>
447447
<translation>傳遞優化</translation>
448448
</message>
449449
<message>
450450
<source>When enabled, your device may share previously downloaded system updates with other devices on your local network.When you turn it off, cached files from update delivery will be cleared during the next restart.</source>
451451
<translation>開啟此功能,你的裝置可能會將以前下載的部分系統更新傳送到本地網絡的裝置上。關閉此功能後,將在重新啟動時清除更新傳遞時快取的檔案</translation>
452452
</message>
453453
<message>
454-
<source>Upgrade Delivery Download Limit Setting</source>
455-
<translation>下載限速</translation>
454+
<source>Delivery Optimization-Limit Speed</source>
455+
<translation>傳遞優化-下載限速</translation>
456456
</message>
457457
<message>
458-
<source>Upgrade Delivery Upload Limit Setting</source>
459-
<translation>上傳限速</translation>
458+
<source>Delivery Optimization-Upload throttling</source>
459+
<translation>傳遞優化-上傳限速</translation>
460460
</message>
461461
<message>
462462
<source>Limit Speed</source>
@@ -527,24 +527,20 @@
527527
<translation>只允許輸入1-99999</translation>
528528
</message>
529529
<message>
530-
<source>Failed to change Upgrade Delivery setting</source>
530+
<source>Failed to change Delivery Optimization setting</source>
531531
<translation>更新傳遞優化服務異常</translation>
532532
</message>
533533
<message>
534-
<source>Update Delivery Optimization service exception. Failed to enable.</source>
535-
<translation>更新傳遞優化服務異常,開啓失敗</translation>
536-
</message>
537-
<message>
538-
<source>Update Delivery Optimization service exception. Failed to disable.</source>
539-
<translation>更新傳遞優化服務異常,關閉失敗</translation>
534+
<source>Update Delivery Optimization service exception</source>
535+
<translation>更新傳遞優化服務異常</translation>
540536
</message>
541537
<message>
542538
<source>Retry</source>
543539
<translation>再試一次</translation>
544540
</message>
545541
<message>
546-
<source>OK</source>
547-
<translation>確定</translation>
542+
<source>Cancel</source>
543+
<translation>取消</translation>
548544
</message>
549545
<message>
550546
<source>Join the internal testing channel to get deepin latest updates.</source>

0 commit comments

Comments
 (0)