|
@@ -364,6 +364,7 @@ var blockLibObj = {
|
|
|
return new TreeCell();
|
|
|
},
|
|
|
newNode: async function (nodeType, nodeName, categoryID, source){ // 1 分类(只用前两个参数) 2 块文件
|
|
|
+ if (nodeName == '') return;
|
|
|
let tree = blockLibObj.mainTree;
|
|
|
let ID = uuid.v1();
|
|
|
let pID = (nodeType == 2) ? categoryID : -1;
|
|
@@ -640,7 +641,7 @@ $(document).ready(function(){ // 这里不需要处理异步:因为不需
|
|
|
|
|
|
$('#btn_block_newFolder_add').on('click', function (){
|
|
|
let name = $('#input_block_newFolder').val();
|
|
|
- if (name != '') blockLibObj.newNode(1, name);
|
|
|
+ blockLibObj.newNode(1, name);
|
|
|
});
|
|
|
|
|
|
$('#btn_block_reName').on('click', function (){
|