diff --git a/app/assets/javascripts/admin/index_utils/directives/panel_toggle_row.js.coffee b/app/assets/javascripts/admin/index_utils/directives/panel_ctrl.js.coffee similarity index 88% rename from app/assets/javascripts/admin/index_utils/directives/panel_toggle_row.js.coffee rename to app/assets/javascripts/admin/index_utils/directives/panel_ctrl.js.coffee index ec6cb6d5ed..4259ce63e2 100644 --- a/app/assets/javascripts/admin/index_utils/directives/panel_toggle_row.js.coffee +++ b/app/assets/javascripts/admin/index_utils/directives/panel_ctrl.js.coffee @@ -1,4 +1,4 @@ -angular.module("admin.indexUtils").directive "panelToggleRow", (Panels) -> +angular.module("admin.indexUtils").directive "panelCtrl", (Panels) -> restrict: "C" scope: object: "=" diff --git a/app/assets/javascripts/admin/index_utils/directives/panel_row.js.coffee b/app/assets/javascripts/admin/index_utils/directives/panel_row.js.coffee index 474ec5664d..8b1e8d4b24 100644 --- a/app/assets/javascripts/admin/index_utils/directives/panel_row.js.coffee +++ b/app/assets/javascripts/admin/index_utils/directives/panel_row.js.coffee @@ -1,6 +1,6 @@ angular.module("admin.indexUtils").directive "panelRow", (Panels, Columns) -> restrict: "C" - require: "^^panelToggleRow" + require: "^^panelCtrl" templateUrl: "admin/panel.html" scope: object: "=" diff --git a/app/assets/javascripts/admin/index_utils/directives/panel_toggle.js.coffee b/app/assets/javascripts/admin/index_utils/directives/panel_toggle.js.coffee index 56d80d88b9..cdd15d1d62 100644 --- a/app/assets/javascripts/admin/index_utils/directives/panel_toggle.js.coffee +++ b/app/assets/javascripts/admin/index_utils/directives/panel_toggle.js.coffee @@ -2,7 +2,7 @@ angular.module("admin.indexUtils").directive "panelToggle", -> restrict: "C" transclude: true template: '
' - require: "^^panelToggleRow" + require: "^^panelCtrl" scope: name: "@" link: (scope, element, attrs, ctrl) -> diff --git a/app/assets/stylesheets/admin/index_panels.css.scss b/app/assets/stylesheets/admin/index_panels.css.scss index ca8464ab26..d2861eb661 100644 --- a/app/assets/stylesheets/admin/index_panels.css.scss +++ b/app/assets/stylesheets/admin/index_panels.css.scss @@ -1,4 +1,4 @@ -tbody.panel-toggle-row { +tbody.panel-ctrl { td.panel-toggle{ -webkit-touch-callout: none; -webkit-user-select: none; diff --git a/app/views/admin/enterprises/_enterprise_user_index.html.haml b/app/views/admin/enterprises/_enterprise_user_index.html.haml index 3c976185d5..d89970946d 100644 --- a/app/views/admin/enterprises/_enterprise_user_index.html.haml +++ b/app/views/admin/enterprises/_enterprise_user_index.html.haml @@ -29,7 +29,7 @@ %th.package{ ng: { show: 'columns.package.visible' } }=t('.package') %th.status{ ng: { show: 'columns.status.visible' } }=t('.status') %th.manage{ ng: { show: 'columns.manage.visible' } }=t('.manage') - %tbody.panel-toggle-row{ :id => "e_{{enterprise.id}}", object: "enterprise", ng: { repeat: "enterprise in filteredEnterprises = ( allEnterprises | filter:{ name: quickSearch } )" } } + %tbody.panel-ctrl{ :id => "e_{{enterprise.id}}", object: "enterprise", ng: { repeat: "enterprise in filteredEnterprises = ( allEnterprises | filter:{ name: quickSearch } )" } } %tr.enterprise{ ng: { class: { even: "'even'", odd: "'odd'"} } } %td.name{ ng: { show: 'columns.name.visible' } } %span{ ng: { bind: "::enterprise.name" } } diff --git a/spec/javascripts/unit/admin/index_utils/directives/panel_row_spec.js.coffee b/spec/javascripts/unit/admin/index_utils/directives/panel_row_spec.js.coffee index f4f0ac4ce3..1b075a94be 100644 --- a/spec/javascripts/unit/admin/index_utils/directives/panel_row_spec.js.coffee +++ b/spec/javascripts/unit/admin/index_utils/directives/panel_row_spec.js.coffee @@ -1,8 +1,8 @@ describe "PanelRow directive", -> Panels = null element = null + ctrlScope = null panelScope = null - rowScope = null beforeEach -> module 'admin.indexUtils' @@ -14,24 +14,24 @@ describe "PanelRow directive", -> Panels = _Panels_ $templateCache.put 'admin/panel.html', '{{ template }}' # Declare the directive HTML. - element = angular.element('