Advertisement
Guest User

Untitled

a guest
Nov 14th, 2019
97
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.78 KB | None | 0 0
  1. $(document).on('click', '#btnSearchDisclosureDB', function (event) {
  2. var data = {
  3. idType: valOrNull($('#id_type').val()),
  4. id: valOrNull($('#id').val()),
  5. property: valOrNull($('#property').val()),
  6. source: valOrNull($('#source').val()),
  7. target: valOrNull($('#target').val())
  8. };
  9.  
  10. $.ajax({
  11. headers: {
  12. 'Accept': 'application/json',
  13. 'Content-Type': 'application/json'
  14. },
  15. type: 'GET',
  16. url: '/rest/disclosure-db',
  17. dataType: 'json',
  18. data: data
  19. }).done(function () {
  20. table.ajax.reload();
  21. }).fail(function (error) {
  22. console.log(error);
  23. });
  24.  
  25. $("#searchDisclosureDBForm")[0].reset();
  26.  
  27. event.preventDefault();
  28. event.stopPropagation();
  29. return false;
  30. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement