mirror of
https://github.com/VueTorrent/VueTorrent.git
synced 2025-03-14 12:10:18 +03:00
fix: change settings speed tab speed unit to KiBps (#1082)
This commit is contained in:
parent
21305d8047
commit
587038a7ae
5 changed files with 32 additions and 10 deletions
|
@ -6,10 +6,10 @@
|
|||
|
||||
<v-row class="mx-1">
|
||||
<v-col cols="12" md="6">
|
||||
<v-text-field v-model="settings.up_limit" dense hide-details class="mb-5" :label="$t('modals.settings.speed.upload')" />
|
||||
<v-text-field v-model="upLimitInKB" @change="saveSettings" dense hide-details class="mb-5" :label="$t('modals.settings.speed.upload')" />
|
||||
</v-col>
|
||||
<v-col cols="12" md="6">
|
||||
<v-text-field v-model="settings.dl_limit" dense hide-details class="mb-5" :label="$t('modals.settings.speed.download')" />
|
||||
<v-text-field v-model="dlLimitInKB" @change="saveSettings" dense hide-details class="mb-5" :label="$t('modals.settings.speed.download')" />
|
||||
</v-col>
|
||||
</v-row>
|
||||
|
||||
|
@ -166,6 +166,22 @@ export default defineComponent({
|
|||
}
|
||||
},
|
||||
computed: {
|
||||
upLimitInKB: {
|
||||
get() {
|
||||
return this.settings.up_limit / 1024;
|
||||
},
|
||||
set(value) {
|
||||
this.settings.up_limit = value * 1024;
|
||||
},
|
||||
},
|
||||
dlLimitInKB: {
|
||||
get() {
|
||||
return this.settings.dl_limit / 1024;
|
||||
},
|
||||
set(value) {
|
||||
this.settings.dl_limit = value * 1024;
|
||||
},
|
||||
},
|
||||
fromTime: {
|
||||
get: function () {
|
||||
return `${this.scheduler.from.hours}:${this.scheduler.from.minutes}`
|
||||
|
@ -187,6 +203,9 @@ export default defineComponent({
|
|||
}
|
||||
}
|
||||
},
|
||||
props: {
|
||||
settings: Object,
|
||||
},
|
||||
mounted() {
|
||||
this.scheduler.from.hours = this.settings.schedule_from_hour
|
||||
this.scheduler.from.minutes = this.settings.schedule_from_min
|
||||
|
@ -195,6 +214,9 @@ export default defineComponent({
|
|||
this.scheduler.to.minutes = this.settings.schedule_to_min
|
||||
},
|
||||
methods: {
|
||||
saveSettings() {
|
||||
this.$emit('save-settings', this.settings);
|
||||
},
|
||||
onDialogCloseFrom() {
|
||||
this.scheduler.from.modal = false
|
||||
this.settings.schedule_from_hour = this.scheduler.from.hours
|
||||
|
|
|
@ -412,8 +412,8 @@
|
|||
"alternative": "Alternative Rate Limits",
|
||||
"settings": "Rate Limits Settings"
|
||||
},
|
||||
"upload": "Upload (in B/s)",
|
||||
"download": "Download (in B/s)",
|
||||
"upload": "Upload (in KiB/s)",
|
||||
"download": "Download (in KiB/s)",
|
||||
"tip": "0 means unlimited",
|
||||
"scheduler": {
|
||||
"subheader": "Schedule the use of alternative rate limits",
|
||||
|
|
|
@ -375,8 +375,8 @@
|
|||
"alternative": "Особые ограничения скорости",
|
||||
"settings": "Настройки ограничений скорости"
|
||||
},
|
||||
"upload": "Отдача (в B/s)",
|
||||
"download": "Загрузка (в B/s)",
|
||||
"upload": "Отдача (в KiB/s)",
|
||||
"download": "Загрузка (в KiB/s)",
|
||||
"tip": "0 означает неограниченно",
|
||||
"scheduler": {
|
||||
"subheader": "Запланировать включение особых ограничений скорости",
|
||||
|
|
|
@ -412,8 +412,8 @@
|
|||
"alternative": "备用速率限制",
|
||||
"settings": "速率限制设置"
|
||||
},
|
||||
"upload": "上传 (B/s)",
|
||||
"download": "下载 (B/s)",
|
||||
"upload": "上传 (KiB/s)",
|
||||
"download": "下载 (KiB/s)",
|
||||
"tip": "设置为0为无限",
|
||||
"scheduler": {
|
||||
"subheader": "定时使用备用速率限制",
|
||||
|
|
|
@ -412,8 +412,8 @@
|
|||
"alternative": "替補速率限制",
|
||||
"settings": "速率限制設定"
|
||||
},
|
||||
"upload": "上傳 (B/s)",
|
||||
"download": "下載 (B/s)",
|
||||
"upload": "上傳 (KiB/s)",
|
||||
"download": "下載 (KiB/s)",
|
||||
"tip": "0 代表無限制",
|
||||
"scheduler": {
|
||||
"subheader": "預約使用替補速率限制",
|
||||
|
|
Loading…
Add table
Reference in a new issue