Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $("#draftImg").click(function () {
- $.ajax({
- url:"/rest/report/listReportName?userId=999",
- dataType: 'json',
- type: 'GET',
- success: function(data) {
- $('#olSavedReports').empty();//div to show the list
- var items = [];
- $.each( data, function( index, value ) {
- items.push('<li><a href="/rest/report/getReport?userId=999&reportId=' + value.reportId + '">' + value.reportName + '</a></li>');
- });
- $('#olSavedReports').append( items.join('') );
- },
- error: function() {
- console.log('An error has occured in ajax call!!');
- }
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement