LuCI - OpenWrt Configuration Interface
Revisão | a2b9bc5aa585d7c171b8c6cf8e7d9adcc090338d (tree) |
---|---|
Hora | 2023-02-06 22:59:20 |
Autor | Tianling Shen <cnsztl@immo...> |
Commiter | Tianling Shen |
luci-app-diskman: sync with upstream source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
@@ -74,7 +74,9 @@ local get_smart_info = function(device) | ||
74 | 74 | elseif attrib == "Serial Number" then |
75 | 75 | smart_info.sn = val |
76 | 76 | elseif attrib == "194" or attrib == "Temperature" then |
77 | - smart_info.temp = val:match("(%d+)") .. "°C" | |
77 | + if val ~= "-" then | |
78 | + smart_info.temp = (val:match("(%d+)") or "?") .. "°C" | |
79 | + end | |
78 | 80 | elseif attrib == "Rotation Rate" then |
79 | 81 | smart_info.rota_rate = val |
80 | 82 | elseif attrib == "SATA Version is" then |
@@ -225,10 +227,10 @@ local get_parted_info = function(device) | ||
225 | 227 | p["type"] = "logical" |
226 | 228 | table.insert(partitions_temp[disk_temp["extended_partition_index"]]["logicals"], i) |
227 | 229 | end |
228 | - elseif (p["number"] < 4) and (p["number"] > 0) then | |
230 | + elseif (p["number"] <= 4) and (p["number"] > 0) then | |
229 | 231 | local s = nixio.fs.readfile("/sys/block/"..device.."/"..p["name"].."/size") |
230 | 232 | if s then |
231 | - local real_size_sec = tonumber(s) * tonumber(disk_temp.phy_sec) | |
233 | + local real_size_sec = tonumber(s) * tonumber(disk_temp.logic_sec) | |
232 | 234 | -- if size not equal, it's an extended |
233 | 235 | if real_size_sec ~= p["size"] then |
234 | 236 | disk_temp["extended_partition_index"] = i |
@@ -0,0 +1,239 @@ | ||
1 | +msgid "" | |
2 | +msgstr "Content-Type: text/plain; charset=UTF-8\n" | |
3 | + | |
4 | +msgid "DiskMan" | |
5 | +msgstr "Menadżer dysków" | |
6 | + | |
7 | +msgid "Manage Disks over LuCI." | |
8 | +msgstr "Zarządzaj dyskami przez LuCI." | |
9 | + | |
10 | +msgid "Rescan Disks" | |
11 | +msgstr "Skanuj dyski" | |
12 | + | |
13 | +msgid "Disks" | |
14 | +msgstr "Dyski" | |
15 | + | |
16 | +msgid "Path" | |
17 | +msgstr "Ścieżka" | |
18 | + | |
19 | +msgid "Serial Number" | |
20 | +msgstr "Numer seryjny" | |
21 | + | |
22 | +msgid "Temp" | |
23 | +msgstr "Temperatura" | |
24 | + | |
25 | +msgid "Partition Table" | |
26 | +msgstr "Tablica partycji" | |
27 | + | |
28 | +msgid "SATA Version" | |
29 | +msgstr "Wersja SATA" | |
30 | + | |
31 | +msgid "Health" | |
32 | +msgstr "Kondycja" | |
33 | + | |
34 | +msgid "File System" | |
35 | +msgstr "System plików" | |
36 | + | |
37 | +msgid "Mount Options" | |
38 | +msgstr "Opcje montowania" | |
39 | + | |
40 | +msgid "Mount" | |
41 | +msgstr "Montuj" | |
42 | + | |
43 | +msgid "Umount" | |
44 | +msgstr "Odmontuj" | |
45 | + | |
46 | +msgid "Eject" | |
47 | +msgstr "Wysuń" | |
48 | + | |
49 | +msgid "New" | |
50 | +msgstr "Nowa" | |
51 | + | |
52 | +msgid "Remove" | |
53 | +msgstr "Wysuń" | |
54 | + | |
55 | +msgid "Format" | |
56 | +msgstr "Formatuj" | |
57 | + | |
58 | +msgid "Start Sector" | |
59 | +msgstr "Sektor początkowy" | |
60 | + | |
61 | +msgid "End Sector" | |
62 | +msgstr "Sektor końcowy" | |
63 | + | |
64 | +msgid "Usage" | |
65 | +msgstr "Wykorzystane" | |
66 | + | |
67 | +msgid "Used" | |
68 | +msgstr "Zajęte" | |
69 | + | |
70 | +msgid "Free Space" | |
71 | +msgstr "Wolna przestrzeń" | |
72 | + | |
73 | +msgid "Model" | |
74 | +msgstr "Model urządzenia" | |
75 | + | |
76 | +msgid "Size" | |
77 | +msgstr "Rozmiar" | |
78 | + | |
79 | +msgid "Status" | |
80 | +msgstr "Status" | |
81 | + | |
82 | +msgid "Mount Point" | |
83 | +msgstr "Punkt montowania" | |
84 | + | |
85 | +msgid "Sector Size" | |
86 | +msgstr "Rozmiar sektora" | |
87 | + | |
88 | +msgid "Rotation Rate" | |
89 | +msgstr "Obroty" | |
90 | + | |
91 | +msgid "RAID Devices" | |
92 | +msgstr "Urządzenia RAID" | |
93 | + | |
94 | +msgid "RAID mode" | |
95 | +msgstr "Tryb RAID" | |
96 | + | |
97 | +msgid "Members" | |
98 | +msgstr "Członkowie" | |
99 | + | |
100 | +msgid "Active" | |
101 | +msgstr "Aktywny" | |
102 | + | |
103 | +msgid "RAID Creation" | |
104 | +msgstr "Kreator RAID" | |
105 | + | |
106 | +msgid "Raid Name" | |
107 | +msgstr "Nazwa RAID" | |
108 | + | |
109 | +msgid "Raid Level" | |
110 | +msgstr "Poziom RAID" | |
111 | + | |
112 | +msgid "Raid Member" | |
113 | +msgstr "Członek RAID" | |
114 | + | |
115 | +msgid "Create Raid" | |
116 | +msgstr "Utwórz RAID" | |
117 | + | |
118 | +msgid "Partition Management" | |
119 | +msgstr "Menadżer partycji" | |
120 | + | |
121 | +msgid "Partition Disk over LuCI." | |
122 | +msgstr "Zarządzaj partycjami przez LuCI." | |
123 | + | |
124 | +msgid "Device Info" | |
125 | +msgstr "Informacja o urządzeniu" | |
126 | + | |
127 | +msgid "Disk Man" | |
128 | +msgstr "Menadżer dysków" | |
129 | + | |
130 | +msgid "Partitions Info" | |
131 | +msgstr "Informacja o partycjach" | |
132 | + | |
133 | +msgid "Default 2048 sector alignment, support +size{b,k,m,g,t} in End Sector" | |
134 | +msgstr "Sektory wyrównywane są do wielokrotności 2048, sektor końcowy można podać jako rozmiar w postaci +size{b,k,m,g,t}" | |
135 | + | |
136 | +msgid "Multiple Devices Btrfs Creation" | |
137 | +msgstr "Kreator urządzeń Btrfs" | |
138 | + | |
139 | +msgid "Label" | |
140 | +msgstr "Etykieta" | |
141 | + | |
142 | +msgid "Btrfs Label" | |
143 | +msgstr "Etykieta Btrfs" | |
144 | + | |
145 | +msgid "Btrfs Raid Level" | |
146 | +msgstr "Poziom Raid Btrfs" | |
147 | + | |
148 | +msgid "Btrfs Member" | |
149 | +msgstr "Członek Btrfs" | |
150 | + | |
151 | +msgid "Create Btrfs" | |
152 | +msgstr "Utwórz Btrfs" | |
153 | + | |
154 | +msgid "New Snapshot" | |
155 | +msgstr "Nowy obraz" | |
156 | + | |
157 | +msgid "SubVolumes" | |
158 | +msgstr "Sub-wolumeny" | |
159 | + | |
160 | +msgid "Top Level" | |
161 | +msgstr "Top Level" | |
162 | + | |
163 | +msgid "Manage Btrfs" | |
164 | +msgstr "Zarządzaj Btrfs" | |
165 | + | |
166 | +msgid "Otime" | |
167 | +msgstr "Otime" | |
168 | + | |
169 | +msgid "Snapshots" | |
170 | +msgstr "Obrazy" | |
171 | + | |
172 | +msgid "Set Default" | |
173 | +msgstr "Ustaw domyślnie" | |
174 | + | |
175 | +msgid "Source Path" | |
176 | +msgstr "Ścieżka źródłowa" | |
177 | + | |
178 | +msgid "Readonly" | |
179 | +msgstr "Tylko do odczytu" | |
180 | + | |
181 | +msgid "Delete" | |
182 | +msgstr "Usuń" | |
183 | + | |
184 | +msgid "Create" | |
185 | +msgstr "Utwórz" | |
186 | + | |
187 | +msgid "Destination Path (optional)" | |
188 | +msgstr "Ścieżka docelowa (opcjonalnie)" | |
189 | + | |
190 | +msgid "Metadata" | |
191 | +msgstr "Metadata" | |
192 | + | |
193 | +msgid "Data" | |
194 | +msgstr "Data" | |
195 | + | |
196 | +msgid "Btrfs Info" | |
197 | +msgstr "Informacja o Btrfs" | |
198 | + | |
199 | +msgid "The source path for create the snapshot" | |
200 | +msgstr "Ścieżka źródłowa do utworzenia obrazu" | |
201 | + | |
202 | +msgid "The path where you want to store the snapshot" | |
203 | +msgstr "Ścieżka w której chcesz przechowywać obraz" | |
204 | + | |
205 | +msgid "Please input Source Path of snapshot, Source Path must start with '/'" | |
206 | +msgstr "Proszę podać ścieżkę źródłową dla obrazu, ścieżka musi zaczynać się od '/'" | |
207 | + | |
208 | +msgid "Please input Subvolume Path, Subvolume must start with '/'" | |
209 | +msgstr "Proszę podać ścieżkę dla sub-wolumenu, sub-wolumen musi zaczynać się od '/'" | |
210 | + | |
211 | +msgid "is in use! please unmount it first!" | |
212 | +msgstr "aktualnie jest w użyciu, proszę najpierw odmontować!" | |
213 | + | |
214 | +msgid "Partition NOT found!" | |
215 | +msgstr "Nie znaleziono partycji!" | |
216 | + | |
217 | +msgid "Filesystem NOT support!" | |
218 | +msgstr "System plików nie jest obsługiwany!" | |
219 | + | |
220 | +msgid "Invalid Start Sector!" | |
221 | +msgstr "Nieprawidłowy sektor początkowy!" | |
222 | + | |
223 | +msgid "Invalid End Sector" | |
224 | +msgstr "Nieprawidłowy sektor końcowy!" | |
225 | + | |
226 | +msgid "Partition not exists!" | |
227 | +msgstr "Partycja nie istnieje!" | |
228 | + | |
229 | +msgid "Creation" | |
230 | +msgstr "Kreator" | |
231 | + | |
232 | +msgid "Please select file system!" | |
233 | +msgstr "Proszę wybrać system plików!" | |
234 | + | |
235 | +msgid "Format partation:" | |
236 | +msgstr "Format partycji:" | |
237 | + | |
238 | +msgid "Warnning !! \nTHIS WILL OVERWRITE EXISTING PARTITIONS!! \nModify the partition table?" | |
239 | +msgstr "Ostrzeżenie !! \nISTNIEJĄCE PARTYCJE ZOSTANĄ NADPISANE!! \nZmodyfikować tablicę partycji?" |
@@ -47,7 +47,7 @@ msgid "Eject" | ||
47 | 47 | msgstr "弹出" |
48 | 48 | |
49 | 49 | msgid "New" |
50 | -msgstr "创建" | |
50 | +msgstr "新建" | |
51 | 51 | |
52 | 52 | msgid "Remove" |
53 | 53 | msgstr "移除" |
@@ -146,7 +146,7 @@ msgid "Btrfs Raid Level" | ||
146 | 146 | msgstr "Btrfs Raid 级别" |
147 | 147 | |
148 | 148 | msgid "Btrfs Member" |
149 | -msgstr "Btrfs 整列成员" | |
149 | +msgstr "Btrfs 阵列成员" | |
150 | 150 | |
151 | 151 | msgid "Create Btrfs" |
152 | 152 | msgstr "创建 Btrfs" |
@@ -0,0 +1,239 @@ | ||
1 | +msgid "" | |
2 | +msgstr "Content-Type: text/plain; charset=UTF-8\n" | |
3 | + | |
4 | +msgid "DiskMan" | |
5 | +msgstr "DiskMan 硬碟管理" | |
6 | + | |
7 | +msgid "Manage Disks over LuCI." | |
8 | +msgstr "通过 LuCI 管理硬碟" | |
9 | + | |
10 | +msgid "Rescan Disks" | |
11 | +msgstr "重新掃描硬碟" | |
12 | + | |
13 | +msgid "Disks" | |
14 | +msgstr "硬碟" | |
15 | + | |
16 | +msgid "Path" | |
17 | +msgstr "路徑" | |
18 | + | |
19 | +msgid "Serial Number" | |
20 | +msgstr "序列號" | |
21 | + | |
22 | +msgid "Temp" | |
23 | +msgstr "溫度" | |
24 | + | |
25 | +msgid "Partition Table" | |
26 | +msgstr "分割區表" | |
27 | + | |
28 | +msgid "SATA Version" | |
29 | +msgstr "SATA 版本" | |
30 | + | |
31 | +msgid "Health" | |
32 | +msgstr "健康" | |
33 | + | |
34 | +msgid "File System" | |
35 | +msgstr "文件系統" | |
36 | + | |
37 | +msgid "Mount Options" | |
38 | +msgstr "掛載選項" | |
39 | + | |
40 | +msgid "Mount" | |
41 | +msgstr "掛載" | |
42 | + | |
43 | +msgid "Umount" | |
44 | +msgstr "卸載" | |
45 | + | |
46 | +msgid "Eject" | |
47 | +msgstr "彈出" | |
48 | + | |
49 | +msgid "New" | |
50 | +msgstr "新建" | |
51 | + | |
52 | +msgid "Remove" | |
53 | +msgstr "移除" | |
54 | + | |
55 | +msgid "Format" | |
56 | +msgstr "格式化" | |
57 | + | |
58 | +msgid "Start Sector" | |
59 | +msgstr "起始磁區" | |
60 | + | |
61 | +msgid "End Sector" | |
62 | +msgstr "結束磁區" | |
63 | + | |
64 | +msgid "Usage" | |
65 | +msgstr "用量" | |
66 | + | |
67 | +msgid "Used" | |
68 | +msgstr "已使用" | |
69 | + | |
70 | +msgid "Free Space" | |
71 | +msgstr "空閒空間" | |
72 | + | |
73 | +msgid "Model" | |
74 | +msgstr "型號" | |
75 | + | |
76 | +msgid "Size" | |
77 | +msgstr "容量" | |
78 | + | |
79 | +msgid "Status" | |
80 | +msgstr "狀態" | |
81 | + | |
82 | +msgid "Mount Point" | |
83 | +msgstr "掛載點" | |
84 | + | |
85 | +msgid "Sector Size" | |
86 | +msgstr "磁區/物理磁區大小" | |
87 | + | |
88 | +msgid "Rotation Rate" | |
89 | +msgstr "轉速" | |
90 | + | |
91 | +msgid "RAID Devices" | |
92 | +msgstr "RAID 裝置" | |
93 | + | |
94 | +msgid "RAID mode" | |
95 | +msgstr "RAID 模式" | |
96 | + | |
97 | +msgid "Members" | |
98 | +msgstr "成員" | |
99 | + | |
100 | +msgid "Active" | |
101 | +msgstr "活躍" | |
102 | + | |
103 | +msgid "RAID Creation" | |
104 | +msgstr "RAID 創建" | |
105 | + | |
106 | +msgid "Raid Name" | |
107 | +msgstr "RAID 名稱" | |
108 | + | |
109 | +msgid "Raid Level" | |
110 | +msgstr "RAID 等級" | |
111 | + | |
112 | +msgid "Raid Member" | |
113 | +msgstr "硬碟陣列成員" | |
114 | + | |
115 | +msgid "Create Raid" | |
116 | +msgstr "創建 RAID" | |
117 | + | |
118 | +msgid "Partition Management" | |
119 | +msgstr "分割區管理" | |
120 | + | |
121 | +msgid "Partition Disk over LuCI." | |
122 | +msgstr "通過 LuCI 分割硬碟。" | |
123 | + | |
124 | +msgid "Device Info" | |
125 | +msgstr "裝置信息" | |
126 | + | |
127 | +msgid "Disk Man" | |
128 | +msgstr "硬碟管理" | |
129 | + | |
130 | +msgid "Partitions Info" | |
131 | +msgstr "分割區信息" | |
132 | + | |
133 | +msgid "Default 2048 sector alignment, support +size{b,k,m,g,t} in End Sector" | |
134 | +msgstr "默認 2048 磁區對齊,【結束磁區】支持 +容量{b,k,m,g,t} 格式,例:+500m +10g +1t" | |
135 | + | |
136 | +msgid "Multiple Devices Btrfs Creation" | |
137 | +msgstr "Btrfs 陣列創建" | |
138 | + | |
139 | +msgid "Label" | |
140 | +msgstr "卷標" | |
141 | + | |
142 | +msgid "Btrfs Label" | |
143 | +msgstr "Btrfs 卷標" | |
144 | + | |
145 | +msgid "Btrfs Raid Level" | |
146 | +msgstr "Btrfs Raid 等級" | |
147 | + | |
148 | +msgid "Btrfs Member" | |
149 | +msgstr "Btrfs 陣列成員" | |
150 | + | |
151 | +msgid "Create Btrfs" | |
152 | +msgstr "創建 Btrfs" | |
153 | + | |
154 | +msgid "New Snapshot" | |
155 | +msgstr "新建快照" | |
156 | + | |
157 | +msgid "SubVolumes" | |
158 | +msgstr "子卷" | |
159 | + | |
160 | +msgid "Top Level" | |
161 | +msgstr "父 ID" | |
162 | + | |
163 | +msgid "Manage Btrfs" | |
164 | +msgstr "Btrfs 管理" | |
165 | + | |
166 | +msgid "Otime" | |
167 | +msgstr "創建時間" | |
168 | + | |
169 | +msgid "Snapshots" | |
170 | +msgstr "快照" | |
171 | + | |
172 | +msgid "Set Default" | |
173 | +msgstr "默認子卷" | |
174 | + | |
175 | +msgid "Source Path" | |
176 | +msgstr "源目錄" | |
177 | + | |
178 | +msgid "Readonly" | |
179 | +msgstr "只讀" | |
180 | + | |
181 | +msgid "Delete" | |
182 | +msgstr "刪除" | |
183 | + | |
184 | +msgid "Create" | |
185 | +msgstr "創建" | |
186 | + | |
187 | +msgid "Destination Path (optional)" | |
188 | +msgstr "目標目錄(可選)" | |
189 | + | |
190 | +msgid "Metadata" | |
191 | +msgstr "元數據" | |
192 | + | |
193 | +msgid "Data" | |
194 | +msgstr "數據" | |
195 | + | |
196 | +msgid "Btrfs Info" | |
197 | +msgstr "Btrfs 信息" | |
198 | + | |
199 | +msgid "The source path for create the snapshot" | |
200 | +msgstr "創建快照的源數據目錄" | |
201 | + | |
202 | +msgid "The path where you want to store the snapshot" | |
203 | +msgstr "存放快照的數據目錄" | |
204 | + | |
205 | +msgid "Please input Source Path of snapshot, Source Path must start with '/'" | |
206 | +msgstr "請輸入快照源路径,源路径必須以'/'開頭" | |
207 | + | |
208 | +msgid "Please input Subvolume Path, Subvolume must start with '/'" | |
209 | +msgstr "請輸入子卷路径,子卷路径必須以'/'開頭" | |
210 | + | |
211 | +msgid "is in use! please unmount it first!" | |
212 | +msgstr "正在被使用!請先卸載!" | |
213 | + | |
214 | +msgid "Partition NOT found!" | |
215 | +msgstr "分割區未找到!" | |
216 | + | |
217 | +msgid "Filesystem NOT support!" | |
218 | +msgstr "文件系統不支持!" | |
219 | + | |
220 | +msgid "Invalid Start Sector!" | |
221 | +msgstr "無效的起始磁區!" | |
222 | + | |
223 | +msgid "Invalid End Sector" | |
224 | +msgstr "無效的結束磁區!" | |
225 | + | |
226 | +msgid "Partition not exists!" | |
227 | +msgstr "分割區不存在!" | |
228 | + | |
229 | +msgid "Creation" | |
230 | +msgstr "創建" | |
231 | + | |
232 | +msgid "Please select file system!" | |
233 | +msgstr "請選擇文件系統!" | |
234 | + | |
235 | +msgid "Format partation:" | |
236 | +msgstr "格式化分割區:" | |
237 | + | |
238 | +msgid "Warnning !! \nTHIS WILL OVERWRITE EXISTING PARTITIONS!! \nModify the partition table?" | |
239 | +msgstr "警告!!\n此操作会覆蓋現有分割區\n確定修改分割區表?" |