Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function EditInfo(var, tableId) {
- var DropdownLoaded = LoadDropdown(var);
- $.when(DropdownLoaded).done(function () {
- $('#DropdownCore').selectpicker('val', tableId);
- });
- $('#CoreModal').modal('show');
- }
- function LoadDropdown(mfg) {
- var funcDone = false;
- $.getJSON("FilterCore", { mfg: mfg }, function (data) {
- $('#DropdownCore').empty();
- $.each(data, function () {
- $('#DropdownCore').append($('<option></option>').val(this.Value).text(this.Text));
- });
- $('.selectpicker').selectpicker('refresh');
- $("#MFGDropdownCore option[value='0']").remove();
- }).done(function () {
- funcDone = true;
- });
- $.when(funcDone).then(function () {
- return true;
- });
- }
Add Comment
Please, Sign In to add comment