mirror of
https://github.com/openwrt/luci.git
synced 2025-12-26 15:36:22 +04:00
luci-app-filemanager: fixed time parsing
Signed-off-by: junjie zhang <zjjmoming@qq.com>
This commit is contained in:
committed by
Hannu Nyman
parent
56e086756d
commit
e4bfd608bd
@@ -298,7 +298,7 @@ function getFileList(path) {
|
||||
lines.forEach(function(line) {
|
||||
if (line.startsWith('total') || !line.trim()) return;
|
||||
// Parse the output line from 'ls' command
|
||||
var parts = line.match(/^([\-dl])[rwx\-]{2}[rwx\-Ss]{1}[rwx\-]{2}[rwx\-Ss]{1}[rwx\-]{2}[rwx\-Tt]{1}\s+\d+\s+(\S+)\s+(\S+)\s+(\d+)\s+([\d\-]+\s+[\d\:\.]{8,12}\s+[+-]\d{4})\s+(.+)$/);
|
||||
var parts = line.match(/^([\-dl])[rwx\-]{2}[rwx\-Ss]{1}[rwx\-]{2}[rwx\-Ss]{1}[rwx\-]{2}[rwx\-Tt]{1}\s+\d+\s+(\S+)\s+(\S+)\s+(\d+)\s+([\d\-]+\s+\d{2}:\d{2}:\d{2}(?:\.\d+)?\s+[+-]\d{4})\s+(.+)$/);
|
||||
if (!parts || parts.length < 7) {
|
||||
console.warn('Failed to parse line:', line);
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user