Skip to content

Commit 4fe6bd0

Browse files
author
minjk-bl
committed
Fix sort_values by columnSelector's output code for list
1 parent 9312220 commit 4fe6bd0

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

visualpython/js/com/com_generatorV2.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -739,6 +739,11 @@ define([
739739
let colList = pageThis.autoGen[obj.name].getDataList();
740740
pageThis.state[obj.name] = colList.map(data => { return data.code });
741741
value = colList.map(data => { return data.code }).join(',');
742+
if (colList.length == 0) {
743+
value = '';
744+
} else if (colList.length > 0) {
745+
value = '[' + value + ']';
746+
}
742747
$(pageThis.wrapSelector('#'+obj.name)).val(value);
743748
break;
744749
case 'file-open':
@@ -1293,7 +1298,7 @@ define([
12931298
let value = list.map(data => { return data.code }).join(',');
12941299
if (list.length == 0) {
12951300
value = '';
1296-
} else if (list.length > 1) {
1301+
} else if (list.length > 0) {
12971302
value = '[' + value + ']';
12981303
}
12991304
pageThis.state[compId] = list.map(data => { return data.code });

0 commit comments

Comments
 (0)