Skip to content
This repository was archived by the owner on Nov 29, 2020. It is now read-only.

Commit da5a23d

Browse files
committed
softcenter:fix usb mount
1 parent 6bf0dcf commit da5a23d

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

release/src/router/softcenter/Softcenter.asp

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ function show_partition(){
3737
require(['/require/modules/diskList.js?hash=' + Math.random().toString()], function(diskList){
3838
var code="";
3939
var free=dict['Free'];
40+
var Unsupportfat=dict['Unsupportfat'];
4041
var mounted_partition = 0;
4142
partitions_array = [];
4243
var usbDevicesList = diskList.list();
@@ -48,8 +49,10 @@ var totalSize = simpleNum(usbDevicesList[i].partition[j].size);
4849
sctype=usbDevicesList[i].partition[j].format || "";
4950
if(usbDevicesList[i].partition[j].status == "unmounted")
5051
continue;
51-
if((usbDevicesList[i].partition[j].partName==sc_disk)&&((usbDevicesList[i].partition[j].format.indexOf("ext") != -1)||(usbDevicesList[i].partition[j].format.indexOf("tntfs") != -1)))
52+
if((usbDevicesList[i].partition[j].partName==sc_disk)&&((usbDevicesList[i].partition[j].format.indexOf("ext") != -1)||(usbDevicesList[i].partition[j].format.indexOf("ntfs") != -1)))
5253
code +='<option value="'+ usbDevicesList[i].partition[j].partName+'" selected="selected">'+ usbDevicesList[i].partition[j].partName+'(' + free +':'+accessableSize+' GB ' + sctype + ')</option>';
54+
else if(usbDevicesList[i].partition[j].format.indexOf("fat") != -1)
55+
code +='<option value="0">' + Unsupportfat + '</option>';
5356
else
5457
code +='<option value="'+ usbDevicesList[i].partition[j].partName+'" >'+ usbDevicesList[i].partition[j].partName+'(' + free +':'+accessableSize+' GB ' + sctype + ')</option>';
5558
mounted_partition++;
@@ -71,11 +74,6 @@ if(document.getElementById("usb_disk_id").value==0)
7174
alert(dict['No Disk']);
7275
return;
7376
}
74-
if((sctype == "tfat")||(sctype =="fat")||(sctype =="vfat"))
75-
{
76-
alert(dict['Unsupportfat']);
77-
return;
78-
}
7977
document.form.submit();
8078
}
8179
function reload_Soft_Center(){
@@ -183,3 +181,4 @@ document.form.sc_mount.value = "0";
183181
<div id="footer"></div>
184182
</body>
185183
</html>
184+

0 commit comments

Comments
 (0)