Work in progress
This commit is contained in:
parent
facb48f839
commit
6b815840c7
@ -64,17 +64,19 @@
|
|||||||
return new Handlebars.SafeString(value == this.value ? 'checked' : '');
|
return new Handlebars.SafeString(value == this.value ? 'checked' : '');
|
||||||
});
|
});
|
||||||
|
|
||||||
categories = {
|
$.getJSON('/query', _ctx.query, function(results) {
|
||||||
0: {description: 'Description1', value: -1},
|
var profile = {};
|
||||||
1: {description: 'Description2', value: 0},
|
for (var i = 0, length = results.length; i < length; ++i) {
|
||||||
2: {description: 'Description3', value: 1},
|
var result = results[i];
|
||||||
};
|
profile[result.id] = {description: result.description, value: 0};
|
||||||
|
}
|
||||||
|
|
||||||
$('#addCategory').click(function() {
|
$('#addCategory').click(function() {
|
||||||
addCategory($('#newCategory').val());
|
addCategory($('#newCategory').val());
|
||||||
});
|
});
|
||||||
|
|
||||||
displayCategories();
|
displayCategories();
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
$(document).on({
|
$(document).on({
|
||||||
@ -82,4 +84,4 @@
|
|||||||
ajaxStop: function() { $('#spinner').hide(); },
|
ajaxStop: function() { $('#spinner').hide(); },
|
||||||
ready: onReady()
|
ready: onReady()
|
||||||
});
|
});
|
||||||
})(window.categories = window.categories || {});
|
})();
|
||||||
|
Loading…
Reference in New Issue
Block a user