Merge pull request #3015 from emanuelschuetze/fix-topic-form

Fixed forms (added missing operator).
This commit is contained in:
Norman Jäckel 2017-02-27 15:18:49 +01:00 committed by GitHub
commit 96cbf17e72
3 changed files with 33 additions and 31 deletions

View File

@ -49,10 +49,11 @@ angular.module('OpenSlidesApp.motions.motionBlock', [])
// MotionBlock views (list view, create dialog, update dialog)
.factory('MotionBlockForm', [
'$http',
'operator',
'gettextCatalog',
'Agenda',
'AgendaTree',
function ($http, gettextCatalog, Agenda, AgendaTree) {
function ($http, operator, gettextCatalog, Agenda, AgendaTree) {
return {
// Get ngDialog configuration.
getDialog: function (motionBlock) {

View File

@ -164,7 +164,7 @@
<translate>State</translate>
<span class="caret"></span>
</span>
<ul class="dropdown-menu dropdown-menu-right" aria-labelledby="dropdownState">
<ul class="dropdown-menu dropdown-menu-left" aria-labelledby="dropdownState">
<li ng-repeat="state in states" ng-class="state.workflowHeader ? 'dropdown-header' : ''">
<a ng-if="state.workflowHeader">
{{ state.headername | translate }}
@ -184,6 +184,34 @@
</li>
</ul>
</span>
<!-- recommendation filter -->
<span uib-dropdown ng-if="config('motions_recommendations_by') != ''">
<span class="pointer" id="dropdownRecommendation" uib-dropdown-toggle
ng-class="{'bold': filter.multiselectFilters.recommendation.length > 0, 'disabled': isSelectMode}"
ng-disabled="isSelectMode">
<translate>Recommendation</translate>
<span class="caret"></span>
</span>
<ul class="dropdown-menu dropdown-menu-left" aria-labelledby="dropdownRecommentation">
<li ng-repeat="recommendation in recommendations" ng-class="recommendation.workflowHeader ? 'dropdown-header' : ''">
<a ng-if="recommendation.workflowHeader">
{{ recommendation.headername | translate }}
</a>
<a href ng-if="!recommendation.workflowHeader"
ng-click="filter.operateMultiselectFilter('recommendation', recommendation.id, isSelectMode)">
<i class="fa fa-check" ng-if="filter.multiselectFilters.recommendation.indexOf(recommendation.id) > -1"></i>
{{ recommendation.recommendation_label | translate }}
</a>
</li>
<li class="divider"></li>
<li>
<a href ng-click="filter.operateMultiselectFilter('recommendation', -1, isSelectMode)">
<i class="fa fa-check" ng-if="filter.multiselectFilters.recommendation.indexOf(-1) > -1"></i>
<translate>No recommendation set</translate>
</a>
</li>
</ul>
</span>
<!-- Category filter -->
<span uib-dropdown ng-if="categories.length > 0">
<span class="pointer" id="dropdownCategory" uib-dropdown-toggle
@ -232,34 +260,6 @@
</li>
</ul>
</span>
<!-- recommendation filter -->
<span uib-dropdown ng-if="config('motions_recommendations_by') != ''">
<span class="pointer" id="dropdownRecommendation" uib-dropdown-toggle
ng-class="{'bold': filter.multiselectFilters.recommendation.length > 0, 'disabled': isSelectMode}"
ng-disabled="isSelectMode">
<translate>Recommendation</translate>
<span class="caret"></span>
</span>
<ul class="dropdown-menu dropdown-menu-right" aria-labelledby="dropdownRecommentation">
<li ng-repeat="recommendation in recommendations" ng-class="recommendation.workflowHeader ? 'dropdown-header' : ''">
<a ng-if="recommendation.workflowHeader">
{{ recommendation.headername | translate }}
</a>
<a href ng-if="!recommendation.workflowHeader"
ng-click="filter.operateMultiselectFilter('recommendation', recommendation.id, isSelectMode)">
<i class="fa fa-check" ng-if="filter.multiselectFilters.recommendation.indexOf(recommendation.id) > -1"></i>
{{ recommendation.recommendation_label | translate }}
</a>
</li>
<li class="divider"></li>
<li>
<a href ng-click="filter.operateMultiselectFilter('recommendation', -1, isSelectMode)">
<i class="fa fa-check" ng-if="filter.multiselectFilters.recommendation.indexOf(-1) > -1"></i>
<translate>No recommendation set</translate>
</a>
</li>
</ul>
</span>
<!-- Tag filter -->
<span uib-dropdown ng-if="tags.length > 0">
<span class="pointer" id="dropdownTag" uib-dropdown-toggle

View File

@ -62,11 +62,12 @@ angular.module('OpenSlidesApp.topics.site', ['OpenSlidesApp.topics', 'OpenSlides
.factory('TopicForm', [
'gettextCatalog',
'operator',
'Editor',
'Mediafile',
'Agenda',
'AgendaTree',
function (gettextCatalog, Editor, Mediafile, Agenda, AgendaTree) {
function (gettextCatalog, operator, Editor, Mediafile, Agenda, AgendaTree) {
return {
// ngDialog for topic form
getDialog: function (topic) {