branch develop updated (234d0d1 -> 45aa015)
This is an automated email from the git hooks/post-receive script. New change to branch develop in repository coselmar. See http://git.codelutin.com/coselmar.git from 234d0d1 [jgitflow-maven-plugin]Updating develop poms back to pre merge state new 45aa015 Add presentation text in home page even if connected internal-test #6741 Add a "DELETED" status for questions that are removed, to be able to filter on it if needed Filter on status "in progress" in home last projects list The 1 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "adds" were already present in the repository and have only been added to this reference. Detailed log of new commits: commit 45aa015f2290fe568cc292017e0d35f05f56c9d5 Author: Yannick Martel <martel@©odelutin.com> Date: Mon Mar 2 14:58:36 2015 +0100 Add presentation text in home page even if connected internal-test #6741 Add a "DELETED" status for questions that are removed, to be able to filter on it if needed Filter on status "in progress" in home last projects list Summary of changes: .../src/main/xmi/coselmar-model.zargo | Bin 10390 -> 10470 bytes .../coselmar/services/v1/QuestionsWebService.java | 1 + .../src/main/webapp/js/coselmar-controllers.js | 2 +- .../main/webapp/js/coselmar-questions-services.js | 14 ++++-- coselmar-ui/src/main/webapp/views/home.html | 53 ++++++++++----------- 5 files changed, 38 insertions(+), 32 deletions(-) -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@codelutin.com>.
This is an automated email from the git hooks/post-receive script. New commit to branch develop in repository coselmar. See http://git.codelutin.com/coselmar.git commit 45aa015f2290fe568cc292017e0d35f05f56c9d5 Author: Yannick Martel <martel@©odelutin.com> Date: Mon Mar 2 14:58:36 2015 +0100 Add presentation text in home page even if connected internal-test #6741 Add a "DELETED" status for questions that are removed, to be able to filter on it if needed Filter on status "in progress" in home last projects list --- .../src/main/xmi/coselmar-model.zargo | Bin 10390 -> 10470 bytes .../coselmar/services/v1/QuestionsWebService.java | 1 + .../src/main/webapp/js/coselmar-controllers.js | 2 +- .../main/webapp/js/coselmar-questions-services.js | 14 ++++-- coselmar-ui/src/main/webapp/views/home.html | 53 ++++++++++----------- 5 files changed, 38 insertions(+), 32 deletions(-) diff --git a/coselmar-persistence/src/main/xmi/coselmar-model.zargo b/coselmar-persistence/src/main/xmi/coselmar-model.zargo index ee44fcc..5b57c85 100644 Binary files a/coselmar-persistence/src/main/xmi/coselmar-model.zargo and b/coselmar-persistence/src/main/xmi/coselmar-model.zargo differ diff --git a/coselmar-rest/src/main/java/fr/ifremer/coselmar/services/v1/QuestionsWebService.java b/coselmar-rest/src/main/java/fr/ifremer/coselmar/services/v1/QuestionsWebService.java index 7d7c27d..fc5c64e 100644 --- a/coselmar-rest/src/main/java/fr/ifremer/coselmar/services/v1/QuestionsWebService.java +++ b/coselmar-rest/src/main/java/fr/ifremer/coselmar/services/v1/QuestionsWebService.java @@ -312,6 +312,7 @@ public class QuestionsWebService extends CoselmarWebServiceSupport { // Question become unavailable question.setUnavailable(true); + question.setStatus(Status.DELETED); commit(); diff --git a/coselmar-ui/src/main/webapp/js/coselmar-controllers.js b/coselmar-ui/src/main/webapp/js/coselmar-controllers.js index e5a4a31..f8eb6e7 100644 --- a/coselmar-ui/src/main/webapp/js/coselmar-controllers.js +++ b/coselmar-ui/src/main/webapp/js/coselmar-controllers.js @@ -119,7 +119,7 @@ coselmarControllers.controller("homeConnectedCtrl", ['$scope', 'questionsService if ($scope.context && $scope.context.currentUser) { - var searchOptions = {'limit' : 5, 'page' : 0}; + var searchOptions = {'status' : 'IN_PROGRESS', 'limit' : 5, 'page' : 0}; questionsService.getQuestions(searchOptions, function(questions) { $scope.questions = questions; diff --git a/coselmar-ui/src/main/webapp/js/coselmar-questions-services.js b/coselmar-ui/src/main/webapp/js/coselmar-questions-services.js index 3c0cac6..d62496f 100644 --- a/coselmar-ui/src/main/webapp/js/coselmar-questions-services.js +++ b/coselmar-ui/src/main/webapp/js/coselmar-questions-services.js @@ -60,14 +60,22 @@ function Question(resource, config){ this.getQuestions = function(searchOptions, successFunction, failFunction) { - if (searchOptions.privacy != "private" && searchOptions.privacy != "public" ) { + console.log(searchOptions); + + if (searchOptions.privacy + && searchOptions.privacy.toUpperCase() != "private" + && searchOptions.privacy.toUpperCase() != "public" ) { + searchOptions.privacy = undefined; } - if (searchOptions.status != "open" && searchOptions.status != "close" - && searchOptions.status != "in_progress" && searchOptions.status != "adjourned") { + if (searchOptions.status && searchOptions.status.toUpperCase() != "IN_PROGRESS" + && searchOptions.status.toUpperCase() != "CLOSED" + && searchOptions.status.toUpperCase() != "ADJOURNED") { + searchOptions.status = undefined; } + console.log("status is " + searchOptions.status); var questionResource = resource(baseURL, {'searchOption' : searchOptions}); questionResource.query().$promise.then(successFunction, failFunction); diff --git a/coselmar-ui/src/main/webapp/views/home.html b/coselmar-ui/src/main/webapp/views/home.html index 9b4c166..df3ca2f 100644 --- a/coselmar-ui/src/main/webapp/views/home.html +++ b/coselmar-ui/src/main/webapp/views/home.html @@ -21,42 +21,39 @@ <http://www.gnu.org/licenses/gpl-3.0.html>. #L% --> -<div ng-if="!context.currentUser"> +<div> <div translate="home.presentation.title"></div> <div style="margin-top : 50px" translate="home.presentation.body"></div> -</div> -<div ng-if="context.currentUser"> <!-- In case of user connected, show five last projects --> - <div translate="home.presentation.title"></div> - <div> - <h3>{{ "home.connected.lastProjects" | translate }}</h3> + <div ng-if="context.currentUser"> + <h3>{{ "home.connected.lastProjects" | translate }}</h3> - <table class="table table-bordered"> - <thead> - <tr> - <th>{{ 'question.metadata.title' | translate }}</th> - <th>{{ 'question.metadata.submissionDate' | translate }}</th> - <th>{{ 'question.metadata.themes' | translate }}</th> - <th>{{ 'question.metadata.deadline' | translate }}</th> - <th ng-if="context.currentUser.role != 'MEMBER' && context.currentUser.role != 'CLIENT'">{{ 'question.metadata.clients' | translate }}</th> - <th ng-if="context.currentUser.role != 'MEMBER' && context.currentUser.role != 'CLIENT'">{{ 'question.metadata.participants' | translate }}</th> - <th ng-if="context.currentUser.role != 'MEMBER' && context.currentUser.role != 'CLIENT'">{{ 'question.metadata.relatedDocuments' | translate }}</th> - </tr> - </thead> - <tbody> - <tr ng-repeat="question in questions" > - <td ng-if="context.currentUser.role != 'MEMBER'"> - <span class="status-{{question.status|lowercase}}" title="{{question.status | translate}}"></span> - <a href="#/questions/{{question.id}}" class="paddingLeft10" tooltip-placement="bottom" tooltip-html-unsafe="{{question.summary}}">{{question.title}}</a> - </td> - <td ng-if="context.currentUser.role == 'MEMBER'">{{question.title}}</td> + <table class="table table-bordered"> + <thead> + <tr> + <th>{{ 'question.metadata.title' | translate }}</th> + <th>{{ 'question.metadata.submissionDate' | translate }}</th> + <th>{{ 'question.metadata.themes' | translate }}</th> + <th>{{ 'question.metadata.deadline' | translate }}</th> + <th ng-if="context.currentUser.role != 'MEMBER' && context.currentUser.role != 'CLIENT'">{{ 'question.metadata.clients' | translate }}</th> + <th ng-if="context.currentUser.role != 'MEMBER' && context.currentUser.role != 'CLIENT'">{{ 'question.metadata.participants' | translate }}</th> + <th ng-if="context.currentUser.role != 'MEMBER' && context.currentUser.role != 'CLIENT'">{{ 'question.metadata.relatedDocuments' | translate }}</th> + </tr> + </thead> + <tbody> + <tr ng-repeat="question in questions" > + <td ng-if="context.currentUser.role != 'MEMBER'"> + <span class="status-{{question.status|lowercase}}" title="{{question.status | translate}}"></span> + <a href="#/questions/{{question.id}}" class="paddingLeft10" tooltip-placement="bottom" tooltip-html-unsafe="{{question.summary}}">{{question.title}}</a> + </td> + <td ng-if="context.currentUser.role == 'MEMBER'">{{question.title}}</td> - <td>{{question.submissionDate | date:'mediumDate'}}</td> + <td>{{question.submissionDate | date:'mediumDate'}}</td> - <td><span ng-repeat="theme in question.themes">{{theme}}, </span></td> + <td><span ng-repeat="theme in question.themes">{{theme}}, </span></td> - <td>{{question.deadline | date:'mediumDate'}}</td> + <td>{{question.deadline | date:'mediumDate'}}</td> <!-- clients : we use ng-if for better tooltip management --> <td ng-if="question.clients && context.currentUser.role != 'MEMBER' && context.currentUser.role != 'CLIENT'"> -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@codelutin.com>.
participants (1)
-
codelutin.com scm