* adjust for tree browsetask page.

This commit is contained in:
wangyidong
2018-04-28 11:28:53 +08:00
parent f963b360a2
commit fb3e2b370f
17 changed files with 111 additions and 249 deletions
+1 -20
View File
@@ -1,29 +1,12 @@
function updateItemOrder()
{
var order = 10;
$('#sonModule').children('.row-table').each(function()
{
if($(this).find("input[name*='order']").length > 0)
{
console.log(order);
$(this).find("input[name*='order']").val(order);
order += 10;
}
});
$('#maxOrder').val(order - 10);
}
function addItem(obj)
{
var $inputRow = $(obj).closest('.row-module');
var $newRow = $('#insertItemBox').children('.row-module').clone().insertAfter($inputRow).addClass('highlight');
$newRow.find('input').val('');
$newRow.find("input[type!='hidden']").val('');
setTimeout(function()
{
$newRow.removeClass('highlight');
}, 1600);
updateItemOrder();
}
function insertItem(obj)
@@ -31,8 +14,6 @@ function insertItem(obj)
var $inputgroup = $(obj).closest('.row-table');
var insertHtml = $('#insertItemBox').children('.row-table').clone();
$inputgroup.after(insertHtml).next('.row-table').find('input').val('');
updateItemOrder();
}
function deleteItem(obj)