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.

groups.controller.js 1.2KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. angular.module('luticate')
  2. .controller('GroupsController', ['$scope', 'luticateAuthGroups', 'luticateAuthCache',
  3. function($scope, luticateAuthGroups, luticateAuthCache) {
  4. $scope.luTable = {
  5. columns: [
  6. {
  7. name: "Name",
  8. width: 11,
  9. getValue: function (item) {
  10. return item.Name;
  11. }
  12. }
  13. ],
  14. canAdd: 'LU_GROUP_ADD',
  15. canDel: 'LU_GROUP_DEL',
  16. canEdit: function()
  17. {
  18. return true;
  19. },
  20. getLoadPagePromise: function (page, perPage, query, promise) {
  21. return luticateAuthGroups.getAll({page: page, perPage: perPage, query: query}, promise);
  22. },
  23. getDelPromise: function (id, promise) {
  24. return luticateAuthGroups.del({group_id: id}, promise);
  25. },
  26. getEditController: function () {
  27. return "GroupEdit";
  28. },
  29. perPage: luticateAuthCache.getEffectiveSettingValue("LU_GROUPS_PER_PAGE")
  30. };
  31. }]);