纽威
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

33 lines
948 B

3 years ago
  1. var clients = [];
  2. $(function () {
  3. clients = $.clientsInit();
  4. })
  5. $.clientsInit = function () {
  6. var dataJson = {
  7. dataItems: [],
  8. organize: [],
  9. role: [],
  10. duty: [],
  11. user: [],
  12. authorizeMenu: [],
  13. authorizeButton: []
  14. };
  15. var init = function () {
  16. $.ajax({
  17. url: "/ClientsData/GetClientsDataJson?"+ Math.random(),
  18. type: "get",
  19. dataType: "json",
  20. async: false,
  21. success: function (data) {
  22. dataJson.dataItems = data.dataItems;
  23. dataJson.organize = data.organize;
  24. dataJson.role = data.role;
  25. dataJson.duty = data.duty;
  26. dataJson.user = data.user;
  27. dataJson.authorizeMenu = eval(data.authorizeMenu);
  28. dataJson.authorizeButton = data.authorizeButton;
  29. }
  30. });
  31. }
  32. init();
  33. return dataJson;
  34. }