I have companies in the dropdown list that are active and deleted(deleted companies will show "(deleted)"), I want to have a checkbox to show/hide the deleted ones (client side).
$('#drAdvisor').change(function () { //select broker to get client
var lic_id = $(this).val();
getClientByBroker(lic_id)
function getClientByBroker(lic_id) {
try {
$.ajax({
url: '../Admin/GetClientByBroker',
type: "POST",
contentType: 'application/json;',
dataType: "json",
data: JSON.stringify({ "Lic_ID": lic_id }),
success: function (data) {
$.each(data, function (key, value) {
$('#drCompany').append($("<option>
</option>").val(value.CLIENTID).html(value.CLIENTNAME));
});
},
});
} catch (e) {console.log(e); }
}