uuid.html 851 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8" />
  5. <title>main_entiity</title>
  6. <script>
  7. $(document).ready(function() {
  8. $('#get_uuid').click(function() {
  9. $('#data', '#result').val('');
  10. $.ajax({
  11. type : 'get',
  12. dataType : 'json',
  13. url : '../jaxrs/uuid/random',
  14. xhrFields : {
  15. 'withCredentials' : true
  16. },
  17. crossDomain : true
  18. }).done(function(json) {
  19. $('#result').html(JSON.stringify( json, null, 4));
  20. });
  21. });
  22. });
  23. </script>
  24. </head>
  25. <body>
  26. <div style="float: left; width: 720px;">
  27. <div style="width: 100%;">
  28. <table border="1" width="100%">
  29. <tr>
  30. <td colspan="2">
  31. <button id="get_uuid">GET UUID</button>
  32. </td>
  33. </tr>
  34. <tr>
  35. <td colspan="2">
  36. <textarea id="result" style="width:97%;height:600px"/>
  37. </td>
  38. </tr>
  39. </table>
  40. </div>
  41. </div>
  42. </body>
  43. </html>