WIP javascript client
This commit is contained in:
@@ -390,21 +390,6 @@ setClientListingContent("content");
|
|||||||
|
|
||||||
//HOME list clients functionality
|
//HOME list clients functionality
|
||||||
$("#tabs").tabs({
|
$("#tabs").tabs({
|
||||||
/* "ajaxOptions": {
|
|
||||||
type: 'GET',
|
|
||||||
dataType: 'json',
|
|
||||||
contentType: 'application/json; charset=utf-8',
|
|
||||||
cache: false,
|
|
||||||
beforeSend: function(xhr) {
|
|
||||||
console.log("before send");
|
|
||||||
xhr.setRequestHeader("Authorization", "Basic " + base64);
|
|
||||||
},
|
|
||||||
success: function(data, status, xhr) {
|
|
||||||
},
|
|
||||||
error: function(xhr, status, index, anchor) {
|
|
||||||
$(anchor.hash).html("error occured while ajax loading.");
|
|
||||||
}
|
|
||||||
},*/
|
|
||||||
select: function(event, ui) {
|
select: function(event, ui) {
|
||||||
console.log("selected..");
|
console.log("selected..");
|
||||||
},
|
},
|
||||||
@@ -413,8 +398,6 @@ setClientListingContent("content");
|
|||||||
},
|
},
|
||||||
show: function(event, ui) {
|
show: function(event, ui) {
|
||||||
console.log("show..");
|
console.log("show..");
|
||||||
|
|
||||||
|
|
||||||
var successFunction = function(data) {
|
var successFunction = function(data) {
|
||||||
var clientObject = new Object();
|
var clientObject = new Object();
|
||||||
clientObject.clients = data;
|
clientObject.clients = data;
|
||||||
@@ -429,29 +412,6 @@ setClientListingContent("content");
|
|||||||
};
|
};
|
||||||
|
|
||||||
executeAjaxRequest(baseApiUrl + 'clients', 'GET', "", base64, successFunction, errorFunction);
|
executeAjaxRequest(baseApiUrl + 'clients', 'GET', "", base64, successFunction, errorFunction);
|
||||||
/*
|
|
||||||
var jqxhr = $.ajax({
|
|
||||||
url: baseApiUrl + 'clients',
|
|
||||||
type: 'GET',
|
|
||||||
contentType: 'application/json',
|
|
||||||
dataType: 'json',
|
|
||||||
cache: false,
|
|
||||||
beforeSend: function(xhr) {
|
|
||||||
xhr.setRequestHeader("Authorization", "Basic " + base64);
|
|
||||||
},
|
|
||||||
success: function(data) {
|
|
||||||
var clientObject = new Object();
|
|
||||||
clientObject.clients = data;
|
|
||||||
console.log(clientObject);
|
|
||||||
|
|
||||||
var tableHtml = $("#clientSearchTabTemplate").render(clientObject);
|
|
||||||
$("#searchtab").html(tableHtml);
|
|
||||||
},
|
|
||||||
error: function(jqXHR, textStatus, errorThrown) {
|
|
||||||
handleXhrError(jqXHR, textStatus, errorThrown, "#formErrorsTemplate", "#formerrors");
|
|
||||||
}
|
|
||||||
});
|
|
||||||
*/
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user