dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #39579
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 20037: event-capture: some look change; attribute category combo for program - WIP
------------------------------------------------------------
revno: 20037
committer: Abyot Asalefew Gizaw <abyota@xxxxxxxxx>
branch nick: dhis2
timestamp: Tue 2015-09-08 11:15:23 +0200
message:
event-capture: some look change; attribute category combo for program - WIP
removed:
dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/selections.html
modified:
dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/event-capture.appcache
dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/index.html
dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/scripts/controllers.js
dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/scripts/event-capture.js
dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/scripts/services.js
dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/styles/style.css
dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/buttons-section.html
dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/column-modal.html
dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/comments-section.html
dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/defaultForm.html
dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/dialog.html
dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/eventList.html
dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/home.html
dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/modal.html
--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk
Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/event-capture.appcache'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/event-capture.appcache 2015-06-15 11:04:20 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/event-capture.appcache 2015-09-08 09:15:23 +0000
@@ -30,6 +30,7 @@
../dhis-web-commons/javascripts/jQuery/calendars/css/ui.calendars.picker.css
../dhis-web-commons/bootstrap/js/bootstrap.min.js
+../dhis-web-commons/bootstrap/css/bootstrap.min.css
../dhis-web-commons/javascripts/angular/angular.js
../dhis-web-commons/javascripts/angular/angular-resource.js
=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/index.html'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/index.html 2015-09-03 14:22:27 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/index.html 2015-09-08 09:15:23 +0000
@@ -35,7 +35,8 @@
<link type="text/css" rel="stylesheet" href="../dhis-web-commons/javascripts/jQuery/calendars/css/ui.calendars.picker.css">
<link type="text/css" rel="stylesheet" href="../dhis-web-commons/javascripts/jQuery/calendars/css/ui-redmond.calendars.picker.css">
- <script type="text/javascript" src="../dhis-web-commons/bootstrap/js/bootstrap.min.js"></script>
+ <script type="text/javascript" src="../dhis-web-commons/bootstrap/js/bootstrap.min.js"></script>
+ <link type="text/css" rel="stylesheet" href="../dhis-web-commons/bootstrap/css/bootstrap.min.css">
<script type="text/javascript" src="../dhis-web-commons/javascripts/angular/angular.js"></script>
<script type="text/javascript" src="../dhis-web-commons/javascripts/angular/angular-resource.js"></script>
=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/scripts/controllers.js'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/scripts/controllers.js 2015-09-07 02:54:26 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/scripts/controllers.js 2015-09-08 09:15:23 +0000
@@ -212,11 +212,25 @@
if($scope.selectedProgramStage.captureCoordinates){
$scope.newDhis2Event.coordinate = {};
}
+
$scope.newDhis2Event.eventDate = '';
- TrackerRulesFactory.getRules($scope.selectedProgram.id).then(function(rules){
- $scope.allProgramRules = rules;
- $scope.loadEvents();
+ var categoryIds = [];
+ if($scope.selectedProgram.categoryCombo &&
+ !$scope.selectedProgram.categoryCombo.isDefault &&
+ $scope.selectedProgram.categoryCombo.categories){
+
+ angular.forEach($scope.selectedProgram.categoryCombo.categories, function(cat){
+ categoryIds.push(cat.id);
+ });
+ }
+
+ MetaDataFactory.getByIds('categories', categoryIds).then(function(categories){
+ $scope.selectedCategories = categories;
+ TrackerRulesFactory.getRules($scope.selectedProgram.id).then(function(rules){
+ $scope.allProgramRules = rules;
+ $scope.loadEvents();
+ });
});
});
}
@@ -326,7 +340,7 @@
return;
}
$scope.sortHeader = gridHeader;
- if($scope.sortHeader.type === 'date'){
+ if($scope.sortHeader.type === 'DATE'){
$scope.reverse = true;
}
else{
@@ -335,7 +349,7 @@
};
$scope.d2Sort = function(dhis2Event){
- if($scope.sortHeader && $scope.sortHeader.type === 'date'){
+ if($scope.sortHeader && $scope.sortHeader.type === 'DATE'){
var d = dhis2Event[$scope.sortHeader.id];
return DateUtils.getDate(d);
}
=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/scripts/event-capture.js'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/scripts/event-capture.js 2015-09-07 12:48:35 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/scripts/event-capture.js 2015-09-08 09:15:23 +0000
@@ -244,7 +244,7 @@
$.ajax({
url: '../api/programs.json',
type: 'GET',
- data:'filter=programType:eq:WITHOUT_REGISTRATION&paging=false&fields=id,name,version,categoryCombo[id,categories[id,categoryOptions[id]]],programStages[id,version,programStageSections[id],programStageDataElements[dataElement[id,optionSet[id,version]]]]'
+ data:'filter=programType:eq:WITHOUT_REGISTRATION&paging=false&fields=id,name,version,categoryCombo[id,isDefault,categories[id,categoryOptions[id]]],programStages[id,version,programStageSections[id],programStageDataElements[dataElement[id,optionSet[id,version]]]]'
}).done( function(response) {
def.resolve( response.programs ? response.programs: [] );
}).fail(function(){
@@ -309,7 +309,7 @@
return $.ajax( {
url: '../api/programs/' + id + '.json',
type: 'GET',
- data: 'fields=id,name,programType,version,dataEntryMethod,dateOfEnrollmentDescription,dateOfIncidentDescription,displayIncidentDate,ignoreOverdueEvents,categoryCombo[id,categories[id]],organisationUnits[id,name],programStages[id,name,version],userRoles[id,name]'
+ data: 'fields=id,name,programType,version,dataEntryMethod,dateOfEnrollmentDescription,dateOfIncidentDescription,displayIncidentDate,ignoreOverdueEvents,categoryCombo[id,isDefault,categories[id]],organisationUnits[id,name],programStages[id,name,version],userRoles[id,name]'
}).done( function( program ){
var ou = {};
_.each(_.values( program.organisationUnits), function(o){
@@ -384,8 +384,8 @@
}
var catigories = [];
- _.each( _.values( programs ), function ( program ) {
- if( program && program.categoryCombo && program.categoryCombo.categories ) {
+ _.each( _.values( programs ), function ( program ) {
+ if( program && program.categoryCombo && !program.categoryCombo.isDefault && program.categoryCombo.categories ) {
_.each(_.values(program.categoryCombo.categories), function(cat){
catigories.push( cat );
});
=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/scripts/services.js'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/scripts/services.js 2015-09-07 12:48:35 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/scripts/services.js 2015-09-08 09:15:23 +0000
@@ -200,7 +200,7 @@
var objs = [];
ECStorageService.currentStore.open().done(function(){
- ECStorageService.currentStore.getAll(store, program).done(function(data){
+ ECStorageService.currentStore.getAll(store).done(function(data){
angular.forEach(data, function(o){
if(o.program.id === program){
objs.push(o);
@@ -213,6 +213,24 @@
});
return def.promise;
},
+ getByIds: function(store, ids){
+ var def = $q.defer();
+ var objs = [];
+
+ ECStorageService.currentStore.open().done(function(){
+ ECStorageService.currentStore.getAll(store).done(function(data){
+ angular.forEach(data, function(o){
+ if(ids.indexOf(o.id) !== -1){
+ objs.push(o);
+ }
+ });
+ $rootScope.$apply(function(){
+ def.resolve(objs);
+ });
+ });
+ });
+ return def.promise;
+ },
getAll: function(store){
var def = $q.defer();
ECStorageService.currentStore.open().done(function(){
=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/styles/style.css'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/styles/style.css 2015-06-15 11:04:20 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/styles/style.css 2015-09-08 09:15:23 +0000
@@ -10,23 +10,6 @@
}
/*----------------------------------------------------------------------------*/
-/* Form
-/*----------------------------------------------------------------------------*/
-
-.fixed-width-text {
- width: 260px;
-}
-
-input.option
-{
- width: 240px;
-}
-
-.fixed-width-select{
- width: 262px;
-}
-
-/*----------------------------------------------------------------------------*/
/* Table
/*----------------------------------------------------------------------------*/
@@ -273,600 +256,6 @@
padding-left: 5px
}
-/*----------------------------------------------------------------------------*/
-/* Bootstrap modal and panel style
-/*----------------------------------------------------------------------------*/
-
-.modal-open {
- overflow: hidden
-}
-.modal {
- position: fixed;
- top: 0;
- right: 0;
- bottom: 0;
- left: 0;
- z-index: 1040;
- display: none;
- overflow: auto;
- overflow-y: scroll
-}
-.modal.fade .modal-dialog {
- -webkit-transform: translate(0,-25%);
- -ms-transform: translate(0,-25%);
- transform: translate(0,-25%);
- -webkit-transition: -webkit-transform .3s ease-out;
- -moz-transition: -moz-transform .3s ease-out;
- -o-transition: -o-transform .3s ease-out;
- transition: transform .3s ease-out
-}
-.modal.in .modal-dialog {
- -webkit-transform: translate(0,0);
- -ms-transform: translate(0,0);
- transform: translate(0,0)
-}
-.modal-dialog {
- position: relative;
- z-index: 1050;
- width: auto;
- padding: 5px;
- margin-right: auto;
- margin-left: auto
-}
-.modal-content {
- position: relative;
- background-color: #fff;
- border: 1px solid #999;
- border: 1px solid rgba(0,0,0,0.2);
- border-radius: 6px;
- outline: 0;
- -webkit-box-shadow: 0 3px 9px rgba(0,0,0,0.5);
- box-shadow: 0 3px 9px rgba(0,0,0,0.5);
- background-clip: padding-box
-}
-.modal-backdrop {
- position: fixed;
- top: 0;
- right: 0;
- bottom: 0;
- left: 0;
- z-index: 1030;
- background-color: #000
-}
-.modal-backdrop.fade {
- opacity: 0;
- filter: alpha(opacity=0)
-}
-.modal-backdrop.in {
- opacity: .5;
- filter: alpha(opacity=50)
-}
-.modal-header {
- min-height: 16.428571429px;
- padding: 0 5px;
- border-bottom: 1px solid #e5e5e5
-}
-.modal-header .close {
- margin-top: -2px
-}
-.modal-title {
- margin: 0;
- line-height: 1.428571429
-}
-.modal-body {
- position: relative;
- margin: 5px;
-}
-.modal-footer {
- padding: 10px;
- text-align: right;
- border-top: 1px solid #e5e5e5
-}
-.modal-footer:before, .modal-footer:after {
- display: table;
- content: " "
-}
-.modal-footer:after {
- clear: both
-}
-.modal-footer:before, .modal-footer:after {
- display: table;
- content: " "
-}
-.modal-footer:after {
- clear: both
-}
-.modal-footer .btn+ .btn {
- margin-bottom: 0;
- margin-left: 5px
-}
-.modal-footer .btn-group .btn+ .btn {
- margin-left: -1px
-}
-.modal-footer .btn-block+ .btn-block {
- margin-left: 0
-}
-@media screen and (min-width: 768px) {
- .modal-dialog {
- width: 600px;
- padding-top: 30px;
- padding-bottom: 30px
- }
- .modal-content {
- -webkit-box-shadow: 0 5px 15px rgba(0,0,0,0.5);
- box-shadow: 0 5px 15px rgba(0,0,0,0.5)
- }
-}
-
-
-.popover {
- position: absolute;
- top: 0;
- left: 0;
- z-index: 1010;
- display: none;
- max-width: 276px;
- padding: 1px;
- text-align: left;
- white-space: normal;
- background-color: #fff;
- border: 1px solid #ccc;
- border: 1px solid rgba(0,0,0,0.2);
- border-radius: 6px;
- -webkit-box-shadow: 0 5px 10px rgba(0,0,0,0.2);
- box-shadow: 0 5px 10px rgba(0,0,0,0.2);
- background-clip: padding-box
-}
-.popover.top {
- margin-top: -10px
-}
-.popover.right {
- margin-left: 10px
-}
-.popover.bottom {
- margin-top: 10px
-}
-.popover.left {
- margin-left: -10px
-}
-.popover-title {
- padding: 5px;;
- margin: 0;
- font-size: 14px;
- font-weight: normal;
- line-height: 18px;
- background-color: #f7f7f7;
- border-bottom: 1px solid #ebebeb;
- border-radius: 5px 5px 0 0
-}
-.popover-content {
- padding: 5px;
-}
-.popover .arrow, .popover .arrow:after {
- position: absolute;
- display: block;
- width: 0;
- height: 0;
- border-color: transparent;
- border-style: solid
-}
-.popover .arrow {
- border-width: 11px
-}
-.popover .arrow:after {
- border-width: 10px;
- content: ""
-}
-.popover.top .arrow {
- bottom: -11px;
- left: 50%;
- margin-left: -11px;
- border-top-color: #999;
- border-top-color: rgba(0,0,0,0.25);
- border-bottom-width: 0
-}
-.popover.top .arrow:after {
- bottom: 1px;
- margin-left: -10px;
- border-top-color: #fff;
- border-bottom-width: 0;
- content: " "
-}
-.popover.right .arrow {
- top: 50%;
- left: -11px;
- margin-top: -11px;
- border-right-color: #999;
- border-right-color: rgba(0,0,0,0.25);
- border-left-width: 0
-}
-.popover.right .arrow:after {
- bottom: -10px;
- left: 1px;
- border-right-color: #fff;
- border-left-width: 0;
- content: " "
-}
-.popover.bottom .arrow {
- top: -11px;
- left: 50%;
- margin-left: -11px;
- border-bottom-color: #999;
- border-bottom-color: rgba(0,0,0,0.25);
- border-top-width: 0
-}
-.popover.bottom .arrow:after {
- top: 1px;
- margin-left: -10px;
- border-bottom-color: #fff;
- border-top-width: 0;
- content: " "
-}
-.popover.left .arrow {
- top: 50%;
- right: -11px;
- margin-top: -11px;
- border-left-color: #999;
- border-left-color: rgba(0,0,0,0.25);
- border-right-width: 0
-}
-.popover.left .arrow:after {
- right: 1px;
- bottom: -10px;
- border-left-color: #fff;
- border-right-width: 0;
- content: " "
-}
-
-
-.container {
- padding-right: 15px;
- padding-left: 15px;
- margin-right: auto;
- margin-left: auto
-}
-.container:before, .container:after {
- display: table;
- content: " "
-}
-.container:after {
- clear: both
-}
-.container:before, .container:after {
- display: table;
- content: " "
-}
-.container:after {
- clear: both
-}
-@media (min-width: 768px) {
- .container {
- width: 750px
- } z-index: 1051;
-}
-@media (min-width: 992px) {
- .container {
- width: 970px
- }
-}
-@media (min-width: 1200px) {
- .container {
- width: 1170px
- }
-}
-.container > .navbar-header, .container > .navbar-collapse {
- margin-right: -15px;
- margin-left: -15px
-}
-@media (min-width: 768px) {
- .container > .navbar-header, .container > .navbar-collapse {
- margin-right: 0;
- margin-left: 0
- }
-}
-
-@media (min-width: 768px) {
- .navbar > .container .navbar-brand {
- margin-left: -15px
- }
-}
-
-.container .jumbotron {
- border-radius: 6px
-}
-@media screen and (min-width: 768px) {
- .jumbotron {
- padding-top: 48px;
- padding-bottom: 48px
- }
- .container .jumbotron {
- padding-right: 60px;
- padding-left: 60px
- }
- .jumbotron h1 {
- font-size: 63px
- }
-}
-
-.panel {
- margin-bottom: 20px;
- background-color: #fff;
- border: 1px solid transparent;
- border-radius: 4px;
- -webkit-box-shadow: 0 1px 1px rgba(0,0,0,0.05);
- box-shadow: 0 1px 1px rgba(0,0,0,0.05)
-}
-.panel-body {
- padding: 0;
-}
-.panel-body:before, .panel-body:after {
- display: table;
- content: " "
-}
-.panel-body:after {
- clear: both
-}
-.panel-body:before, .panel-body:after {
- display: table;
- content: " "
-}
-.panel-body:after {
- clear: both
-}
-.panel > .list-group {
- margin-bottom: 0
-}
-.panel > .list-group .list-group-item {
- border-width: 1px 0
-}
-.panel > .list-group .list-group-item:first-child {
- border-top-right-radius: 0;
- border-top-left-radius: 0
-}
-.panel > .list-group .list-group-item:last-child {
- border-bottom: 0
-}
-.panel-heading+ .list-group .list-group-item:first-child {
- border-top-width: 0
-}
-.panel > .table, .panel > .table-responsive {
- margin-bottom: 0
-}
-.panel > .panel-body+ .table, .panel > .panel-body+ .table-responsive {
- border-top: 1px solid #ddd
-}
-.panel > .table-bordered, .panel > .table-responsive > .table-bordered {
- border: 0
-}
-.panel > .table-bordered > thead > tr > th:first-child, .panel > .table-responsive > .table-bordered > thead > tr > th:first-child, .panel > .table-bordered > tbody > tr > th:first-child, .panel > .table-responsive > .table-bordered > tbody > tr > th:first-child, .panel > .table-bordered > tfoot > tr > th:first-child, .panel > .table-responsive > .table-bordered > tfoot > tr > th:first-child, .panel > .table-bordered > thead > tr > td:first-child, .panel > .table-responsive > .table-bordered > thead > tr > td:first-child, .panel > .table-bordered > tbody > tr > td:first-child, .panel > .table-responsive > .table-bordered > tbody > tr > td:first-child, .panel > .table-bordered > tfoot > tr > td:first-child, .panel > .table-responsive > .table-bordered > tfoot > tr > td:first-child {
- border-left: 0
-}
-.panel > .table-bordered > thead > tr > th:last-child, .panel > .table-responsive > .table-bordered > thead > tr > th:last-child, .panel > .table-bordered > tbody > tr > th:last-child, .panel > .table-responsive > .table-bordered > tbody > tr > th:last-child, .panel > .table-bordered > tfoot > tr > th:last-child, .panel > .table-responsive > .table-bordered > tfoot > tr > th:last-child, .panel > .table-bordered > thead > tr > td:last-child, .panel > .table-responsive > .table-bordered > thead > tr > td:last-child, .panel > .table-bordered > tbody > tr > td:last-child, .panel > .table-responsive > .table-bordered > tbody > tr > td:last-child, .panel > .table-bordered > tfoot > tr > td:last-child, .panel > .table-responsive > .table-bordered > tfoot > tr > td:last-child {
- border-right: 0
-}
-.panel > .table-bordered > thead > tr:last-child > th, .panel > .table-responsive > .table-bordered > thead > tr:last-child > th, .panel > .table-bordered > tbody > tr:last-child > th, .panel > .table-responsive > .table-bordered > tbody > tr:last-child > th, .panel > .table-bordered > tfoot > tr:last-child > th, .panel > .table-responsive > .table-bordered > tfoot > tr:last-child > th, .panel > .table-bordered > thead > tr:last-child > td, .panel > .table-responsive > .table-bordered > thead > tr:last-child > td, .panel > .table-bordered > tbody > tr:last-child > td, .panel > .table-responsive > .table-bordered > tbody > tr:last-child > td, .panel > .table-bordered > tfoot > tr:last-child > td, .panel > .table-responsive > .table-bordered > tfoot > tr:last-child > td {
- border-bottom: 0
-}
-.panel-heading {
- padding: 5px;
- border-bottom: 1px solid transparent;
- border-top-right-radius: 3px;
- border-top-left-radius: 3px
-}
-.panel-heading > .dropdown .dropdown-toggle {
- color: inherit
-}
-.panel-title {
- margin-top: 0;
- margin-bottom: 0;
- font-size: 16px
-}
-.panel-title > a {
- color: inherit
-}
-.panel-footer {
- padding: 10px 15px;
- background-color: #f5f5f5;
- border-top: 1px solid #ddd;
- border-bottom-right-radius: 3px;
- border-bottom-left-radius: 3px
-}
-.panel-group .panel {
- margin-bottom: 0;
- //overflow: hidden;
- border-radius: 4px
-}
-.panel-group .panel+ .panel {
- margin-top: 5px
-}
-.panel-group .panel-heading {
- border-bottom: 0
-}
-.panel-group .panel-heading+ .panel-collapse .panel-body {
- border-top: 1px solid #ddd
-}
-.panel-group .panel-footer {
- border-top: 0
-}
-.panel-group .panel-footer+ .panel-collapse .panel-body {
- border-bottom: 1px solid #ddd
-}
-.panel-default {
- border-color: #ddd
-}
-.panel-default > .panel-heading {
- color: #333;
- background-color: #f5f5f5;
- border-color: #ddd
-}
-.panel-default > .panel-heading+ .panel-collapse .panel-body {
- border-top-color: #ddd
-}
-.panel-default > .panel-heading > .dropdown .caret {
- border-color: #333 transparent
-}
-.panel-default > .panel-footer+ .panel-collapse .panel-body {
- border-bottom-color: #ddd
-}
-.panel-primary {
- border-color: #428bca
-}
-.panel-primary > .panel-heading {
- color: #fff;
- background-color: #428bca;
- border-color: #428bca
-}
-.panel-primary > .panel-heading+ .panel-collapse .panel-body {
- border-top-color: #428bca
-}
-.panel-primary > .panel-heading > .dropdown .caret {
- border-color: #fff transparent
-}
-.panel-primary > .panel-footer+ .panel-collapse .panel-body {
- border-bottom-color: #428bca
-}
-.panel-success {
- border-color: #d6e9c6
-}
-.panel-success > .panel-heading {
- color: #468847;
- background-color: #dff0d8;
- border-color: #d6e9c6
-}
-.panel-success > .panel-heading+ .panel-collapse .panel-body {
- border-top-color: #d6e9c6
-}
-.panel-success > .panel-heading > .dropdown .caret {
- border-color: #468847 transparent
-}
-.panel-success > .panel-footer+ .panel-collapse .panel-body {
- border-bottom-color: #d6e9c6
-}
-.panel-warning {
- border-color: #faebcc
-}
-.panel-warning > .panel-heading {
- color: #c09853;
- background-color: #fcf8e3;
- border-color: #faebcc
-}
-.panel-warning > .panel-heading+ .panel-collapse .panel-body {
- border-top-color: #faebcc
-}
-.panel-warning > .panel-heading > .dropdown .caret {
- border-color: #c09853 transparent
-}
-.panel-warning > .panel-footer+ .panel-collapse .panel-body {
- border-bottom-color: #faebcc
-}
-.panel-danger {
- border-color: #ebccd1
-}
-.panel-danger > .panel-heading {
- color: #b94a48;
- background-color: #f2dede;
- border-color: #ebccd1
-}
-.panel-danger > .panel-heading+ .panel-collapse .panel-body {
- border-top-color: #ebccd1
-}
-.panel-danger > .panel-heading > .dropdown .caret {
- border-color: #b94a48 transparent
-}
-.panel-danger > .panel-footer+ .panel-collapse .panel-body {
- border-bottom-color: #ebccd1
-}
-.panel-info {
- border-color: #bce8f1
-}
-.panel-info > .panel-heading {
- color: #3a87ad;
- background-color: #d9edf7;
- border-color: #bce8f1
-}
-.panel-info > .panel-heading+ .panel-collapse .panel-body {
- border-top-color: #bce8f1
-}
-.panel-info > .panel-heading > .dropdown .caret {
- border-color: #3a87ad transparent
-}
-.panel-info > .panel-footer+ .panel-collapse .panel-body {
- border-bottom-color: #bce8f1
-}
-
-.dropdown {
- position: relative
-}
-.dropdown-toggle:focus {
- outline: 0
-}
-.dropdown-menu {
- position: absolute;
- top: 100%;
- left: 0;
- z-index: 1000;
- display: none;
- float: left;
- min-width: 160px;
- padding: 0;
- margin: 0;
- font-size: 9pt;
- list-style: none;
- background-color: #fff;
- border: 1px solid #ccc;
- border: 1px solid rgba(0,0,0,0.15);
- border-radius: 4px;
- -webkit-box-shadow: 0 6px 12px rgba(0,0,0,0.175);
- box-shadow: 0 6px 12px rgba(0,0,0,0.175);
- background-clip: padding-box
-}
-.dropdown-menu.pull-right {
- right: 0;
- left: auto
-}
-.dropdown-menu .divider {
- height: 1px;
- margin: 9px 0;
- overflow: hidden;
- background-color: #e5e5e5
-}
-.dropdown-menu > li > a {
- display: block;
- padding: 5px;
- clear: both;
- font-weight: normal;
- line-height: 1.428571429;
- color: #333;
- white-space: nowrap
-}
-.dropdown-menu > li > a:hover, .dropdown-menu > li > a:focus {
- color: #262626;
- text-decoration: none;
- background-color: #f5f5f5
-}
-.dropdown-menu > .active > a, .dropdown-menu > .active > a:hover, .dropdown-menu > .active > a:focus {
- color: #fff;
- text-decoration: none;
- background-color: #428bca;
- outline: 0
-}
-.dropdown-menu > .disabled > a, .dropdown-menu > .disabled > a:hover, .dropdown-menu > .disabled > a:focus {
- color: #999
-}
-.dropdown-menu > .disabled > a:hover, .dropdown-menu > .disabled > a:focus {
- text-decoration: none;
- cursor: not-allowed;
- background-color: transparent;
- background-image: none;
- filter: progid:DXImageTransform.Microsoft.gradient(enabled=false)
-}
-.open > .dropdown-menu {
- display: block
-}
-.dropdown-menu li:hover {
- cursor: pointer;
-}
-
input[type=number], input[type=text], input[type=password], input[type=email], textarea
{
border: 1px solid #aaa;
@@ -887,25 +276,6 @@
margin-right: 20px;
}
-input.typeahead::-webkit-input-placeholder {
- font-family: fontAwesome;
- content: "\f0d7";
- text-align: right;
- font-weight: bold;
-}
-input.typeahead::-moz-placeholder {
- font-family: fontAwesome;
- content: "\f0d7";
- text-align: right;
- font-weight: bold;
-}
-input.typeahead::-ms-input-placeholder {
- font-family: fontAwesome;
- content: "\f0d7";
- text-align: right;
- font-weight: bold;
-}
-
.disable-clicks {
pointer-events: none;
}
@@ -949,10 +319,6 @@
margin-top: 20px;
}
-.form-control {
- width: 100%;
-}
-
div#orgUnitTree {
height: 50%;
border: 1px solid #e3e3e3;
@@ -968,3 +334,22 @@
border-bottom: 1px solid #e3e3e3;
//text-align: center;
}
+
+.selectionGroup{
+ margin: 0 auto;
+ display: flex;
+}
+
+.selectionArea {
+ border: 1px solid #a4d2a3;
+ background-color: #d0eBd0;
+ padding-top: 10px;
+ padding-bottom: 10px;
+ //margin-bottom: 15px;
+ border-radius: 3px;
+}
+
+.div-bottom {
+ position: absolute;
+ bottom: 0;
+}
\ No newline at end of file
=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/buttons-section.html'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/buttons-section.html 2015-06-22 08:45:36 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/buttons-section.html 2015-09-08 09:15:23 +0000
@@ -1,12 +1,12 @@
-<div style="clear: both;">
+<div style="clear: both;" class="small-vertical-spacing">
<span ng-if="editingEventInFull">
- <button type="button" ng-click="updateEvent()" class="button hideInPrint">{{'update'| translate}}</button>
- <button type="button" ng-click="cancel()" class="button hideInPrint">{{'cancel'| translate}}</button>
+ <button type="button" ng-click="updateEvent()" class="btn btn-primary hideInPrint">{{'update'| translate}}</button>
+ <button type="button" ng-click="cancel()" class="btn btn-default hideInPrint">{{'cancel'| translate}}</button>
</span>
<span ng-if="eventRegistration">
- <button type="button" ng-disabled="disableSaveAndAddNew" ng-click="addEvent(true)" class="button hideInPrint">{{'save_and_add_new'| translate}}</button>
- <button type="button" ng-click="addEvent()" class="button hideInPrint">{{'save_and_back'| translate}}</button>
- <button type="button" ng-click="cancel()" class="button hideInPrint">{{'cancel'| translate}}</button>
+ <button type="button" ng-disabled="disableSaveAndAddNew" ng-click="addEvent(true)" class="btn btn-primary hideInPrint">{{'save_and_add_new'| translate}}</button>
+ <button type="button" ng-click="addEvent()" class="btn btn-success hideInPrint">{{'save_and_back'| translate}}</button>
+ <button type="button" ng-click="cancel()" class="btn btn-default hideInPrint">{{'cancel'| translate}}</button>
</span>
<br><span ng-if="isFormInvalid()" class="horizontal-spacing red">{{'form_invalid' | translate}}</span>
</div>
\ No newline at end of file
=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/column-modal.html'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/column-modal.html 2015-08-09 22:28:42 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/column-modal.html 2015-09-08 09:15:23 +0000
@@ -17,5 +17,5 @@
</div>
<div class="modal-footer page">
- <button data-ng-click="close()">{{'close'| translate}}</button>
+ <button class="btn btn-primary" type="button" data-ng-click="close()">{{'close'| translate}}</button>
</div>
\ No newline at end of file
=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/comments-section.html'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/comments-section.html 2015-06-22 08:45:36 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/comments-section.html 2015-09-08 09:15:23 +0000
@@ -2,7 +2,7 @@
<div class="vertical-spacing section-label">
{{'comments'| translate}}
</div>
- <textarea class="small-vertical-spacing" rows="3" ng-model="note.value" placeholder="{{'add_your_comment_here'| translate}}" style="width:100%;"></textarea>
+ <textarea class="form-control" rows="3" ng-model="note.value" placeholder="{{'add_your_comment_here'| translate}}" style="width:100%;"></textarea>
<div ng-if="currentEvent.notes">
<table class="listTable dhis2-list-table-striped">
<thead>
=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/defaultForm.html'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/defaultForm.html 2015-09-03 13:13:08 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/defaultForm.html 2015-09-08 09:15:23 +0000
@@ -83,8 +83,8 @@
name="foo"
input-field-id={{eventGridColumn.id}}
on-select={{saveDatavalue()}}
- class='form-control'>
- <ui-select-match allow-clear="true" class="form-control" placeholder="{{'select_or_search' | translate}}">{{$select.selected.name || $select.selected}}</ui-select-match>
+ style="width:100%;">
+ <ui-select-match allow-clear="true" style="width:100%; height:34px; line-height:1.0; padding: 2px 6px; margin-top:5px" placeholder="{{'select_or_search' | translate}}">{{$select.selected.name || $select.selected}}</ui-select-match>
<ui-select-choices repeat="option.name as option in optionSets[prStDes[eventGridColumn.id].dataElement.optionSet.id].options | filter: $select.search | limitTo:30">
<span ng-bind-html="option.name | highlight: $select.search"></span>
</ui-select-choices>
@@ -346,8 +346,8 @@
name="foo"
input-field-id={{de.dataElement.id}}
on-select={{saveDatavalue()}}
- class='form-control'>
- <ui-select-match allow-clear="true" class="form-control" placeholder="{{'select_or_search' | translate}}">{{$select.selected.name || $select.selected}}</ui-select-match>
+ style="width:100%;">
+ <ui-select-match allow-clear="true"style="width:100%; height:34px; line-height:1.0; padding: 2px 6px; margin-top:5px" placeholder="{{'select_or_search' | translate}}">{{$select.selected.name || $select.selected}}</ui-select-match>
<ui-select-choices repeat="option.name as option in optionSets[prStDes[de.dataElement.id].dataElement.optionSet.id].options | filter: $select.search | limitTo:30">
<span ng-bind-html="option.name | highlight: $select.search"></span>
</ui-select-choices>
=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/dialog.html'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/dialog.html 2014-03-05 11:07:39 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/dialog.html 2015-09-08 09:15:23 +0000
@@ -6,5 +6,5 @@
</div>
<div class="modal-footer">
- <button class="big-button grey" data-ng-click="dialogOptions.ok();">{{dialogOptions.closeButtonText| translate}}</button>
+ <button class="btn btn-primary" type="button" data-ng-click="dialogOptions.ok();">{{dialogOptions.closeButtonText| translate}}</button>
</div>
\ No newline at end of file
=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/eventList.html'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/eventList.html 2015-09-03 15:33:49 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/eventList.html 2015-09-08 09:15:23 +0000
@@ -1,4 +1,4 @@
-<div ng-if="selectedProgramStage && !eventRegistration && !editingEventInFull">
+<div ng-if="selectedProgramStage && !eventRegistration && !editingEventInFull" class="small-vertical-spacing">
<i ng-if="!eventFetched" class="fa fa-spinner fa-spin fa-2x"></i>
<div ng-if="eventFetched" ng-switch="dhis2Events.length">
<div ng-switch-when="undefined">
@@ -11,16 +11,25 @@
{{'empty_event_list'| translate}}
</h4>
</div>
- <div ng-switch-default>
- <h4>
- {{'registered_events'| translate}}<span class="small-horizonal-spacing" ng-if="pager.total">({{'total' | translate}}: {{pager.total}})</span>
- <button class="button button-std pull-right hideInPrint"
- ng-show="dhis2Events.length"
- ng-disabled="eventRegistration || editingEventInFull || editingEventInGrid"
- ng-click="showHideColumns()">
- {{'show_hide_columns'| translate}}
- </button>
- </h4>
+ <div ng-switch-default>
+ <div class="row small-vertical-spacing small-vertical-spacing">
+ <div class="col-sm-12">
+ <span>
+ {{'registered_events'| translate}}<span class="small-horizonal-spacing" ng-if="pager.total">({{'total' | translate}}: {{pager.total}})</span>
+ </span>
+
+ <div class="pull-right hideInPrint">
+ <button class="btn btn-info pull-right hideInPrint"
+ ng-show="dhis2Events.length"
+ type="button"
+ ng-disabled="eventRegistration || editingEventInFull || editingEventInGrid"
+ ng-click="showHideColumns()">
+ {{'show_hide_columns'| translate}}
+ </button>
+ </div>
+ </div>
+ </div>
+
<!-- context menu for event grid -->
<div id="contextMenu" class="contextMenu" style="width: 180px;">
@@ -33,7 +42,8 @@
<!-- context menu ends -->
<!-- grid begins -->
- <form name="outerForm" novalidate>
+ <div class="small-vertical-spacing">
+ <form name="outerForm" novalidate>
<table class="listTable dhis2-table-striped-border dhis2-table-hover">
<thead>
@@ -357,6 +367,8 @@
<serverside-paginator></serverside-paginator>
</form>
+ </div>
+
<!-- grid ends -->
</div>
</div>
=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/home.html'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/home.html 2015-08-25 14:54:19 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/home.html 2015-09-08 09:15:23 +0000
@@ -26,16 +26,87 @@
</h3>
<!-- selection begins-->
- <table>
+ <div class="col-sm-12 selectionGroup">
+ <div class="row col-sm-6 selectionArea">
+ <div class="row col-sm-12">
+ <div class="col-sm-4">
+ {{registeringUnitLabel}}
+ </div>
+ <div class="col-sm-8">
+ <input type="text" class="form-control" selected-org-unit ng-model="selectedOrgUnit.name" value="{{selectedOrgUnit.name|| pleaseSelectLabel}}" disabled=""></td>
+ </div>
+ </div>
+ <div class="row col-sm-12 small-vertical-spacing">
+ <div class="col-sm-4">
+ {{programLabel}}
+ </div>
+ <div class="col-sm-8">
+ <select id="programId"
+ class="form-control"
+ name="programId"
+ ng-model="selectedProgram"
+ ng-options="program as program.name for program in programs | orderBy: 'name'"
+ ng-change="getProgramDetails()"
+ ng-disabled="eventRegistration || editingEventInFull || editingEventInGrid">
+ <option value="">{{pleaseSelectLabel}}</option>
+ </select>
+ </div>
+ </div>
+ <div class="row col-sm-12 small-vertical-spacing" ng-repeat="category in selectedCategories">
+ <div class="col-sm-4">
+ {{category.name}}
+ </div>
+ <div class="col-sm-8">
+ <select class="form-control"
+ name="option"
+ ng-model="selectedOptions.id">
+ <option value="">{{pleaseSelectLabel}}</option>
+ <option ng-repeat="option in category.categoryOptions" value={{section.id}}>{{option.name}}</option>
+ </select>
+ </div>
+ </div>
+ <div class="row col-sm-12 small-vertical-spacing" ng-if="selectedProgramStage && selectedProgramStage.programStageSections.length && eventRegistration || editingEventInFull">
+ <div class="col-sm-4">
+ {{'section'| translate}}
+ </div>
+ <div class="col-sm-8">
+ <select class="form-control"
+ name="section"
+ ng-model="selectedSection.id">
+ <option value="ALL">{{'show_all'| translate}}</option>
+ <option ng-repeat="section in selectedProgramStage.programStageSections" value={{section.id}}>{{section.name}}</option>
+ </select>
+ </div>
+ </div>
+ </div>
+ <div class="col-sm-6 div-bottom">
+ <button class="btn btn-success hideInPrint small-horizonal-spacing"
+ type="button"
+ ng-show="selectedProgramStage"
+ ng-click="showEventRegistration()"
+ ng-disabled="eventRegistration || editingEventInFull || editingEventInGrid">
+ {{'register_event'| translate}}
+ </button>
+ <button class="btn btn-primary hideInPrint small-horizonal-spacing"
+ type="button"
+ ng-if="dhis2Events.length > 0 || eventRegistration || editingEventInFull"
+ onclick="javascript:window.print()">
+ <span ng-if="!eventRegistration && !editingEventInFull">{{'print_list'| translate}}</span>
+ <span ng-if="eventRegistration">{{'print_form'| translate}}</span>
+ <span ng-if="editingEventInFull">{{'print_details'| translate}}</span>
+ </button>
+ </div>
+ </div>
+ <!--<table>
<tr>
<td><label>{{registeringUnitLabel}}</label></td>
- <td><input type="text" class="fixed-width-text" selected-org-unit ng-model="selectedOrgUnit.name" value="{{selectedOrgUnit.name|| pleaseSelectLabel}}" disabled="" style="height:14px"></td>
+ <td><input type="text" class="form-control" selected-org-unit ng-model="selectedOrgUnit.name" value="{{selectedOrgUnit.name|| pleaseSelectLabel}}" disabled=""></td>
</tr>
<tr>
<td><label>{{programLabel}}</label></td>
<td>
<select id="programId"
- class="fixed-width-select"
+ class="form-control"
name="programId"
ng-model="selectedProgram"
ng-options="program as program.name for program in programs | orderBy: 'name'"
@@ -45,26 +116,28 @@
</select>
</td>
<td style='padding-left: 10px;'>
- <button class="button button-std hideInPrint"
+ <button class="btn btn-success hideInPrint"
+ type="button"
ng-show="selectedProgramStage"
ng-click="showEventRegistration()"
ng-disabled="eventRegistration || editingEventInFull || editingEventInGrid">
{{'register_event'| translate}}
- </button>
+ </button>
</td>
<td ng-if="dhis2Events.length > 0 || eventRegistration || editingEventInFull" style='padding-left: 10px;'>
- <button class="button button-std hideInPrint"
+ <button class="btn btn-info hideInPrint"
+ type="button"
onclick="javascript:window.print()">
<span ng-if="!eventRegistration && !editingEventInFull">{{'print_list'| translate}}</span>
<span ng-if="eventRegistration">{{'print_form'| translate}}</span>
<span ng-if="editingEventInFull">{{'print_details'| translate}}</span>
- </button>
+ </button>
</td>
</tr>
<tr ng-if="selectedProgramStage && selectedProgramStage.programStageSections.length && eventRegistration || editingEventInFull">
<td><label>{{'section'| translate}}</label></td>
<td>
- <select class="fixed-width-select"
+ <select class="form-control"
name="section"
ng-model="selectedSection.id">
<option value="ALL">{{'show_all'| translate}}</option>
@@ -72,7 +145,7 @@
</select>
</td>
</tr>
- </table>
+ </table>-->
<!-- selection ends -->
<div id="hideTypeAheadPopUp" ng-hide="true"></div>
=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/modal.html'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/modal.html 2014-03-05 11:07:39 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/modal.html 2015-09-08 09:15:23 +0000
@@ -5,6 +5,6 @@
<p>{{modalOptions.bodyText | translate}}</p>
</div>
<div class="modal-footer">
- <button data-ng-click="modalOptions.close()">{{modalOptions.closeButtonText | translate}}</button>
- <button data-ng-click="modalOptions.ok();">{{modalOptions.actionButtonText | translate}}</button>
+ <button class="btn btn-default" type="button" data-ng-click="modalOptions.close()">{{modalOptions.closeButtonText | translate}}</button>
+ <button class="btn btn-primary" type="button" data-ng-click="modalOptions.ok();">{{modalOptions.actionButtonText | translate}}</button>
</div>
\ No newline at end of file
=== removed file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/selections.html'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/selections.html 2015-08-25 14:54:19 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-capture/views/selections.html 1970-01-01 00:00:00 +0000
@@ -1,34 +0,0 @@
-<table>
- <tr>
- <td><label>{{'registering_unit'| translate}}</label></td>
- <td><input type="text" class="fixed-width-text" selected-org-unit ng-model="selectedOrgUnit.name" value="{{selectedOrgUnit.name|| pleaseSelectLabel}}" disabled="" style="height:14px"></td>
- </tr>
- <tr>
- <td><label>{{'program'| translate}}</label></td>
- <td>
- <select id="programId"
- class="fixed-width-select"
- name="programId"
- ng-model="selectedProgram"
- ng-options="program as program.name for program in programs | orderBy: 'name'"
- ng-change="loadEvents()"
- ng-disabled="eventRegistration || editingEventInFull || editingEventInGrid">
- <option value="">{{pleaseSelectLabel}}</option>
- </select>
- </td>
- <td style='padding-left: 10px;'>
- <button class="button button-std"
- ng-show="selectedProgramStage"
- ng-click="showEventRegistration()"
- ng-disabled="eventRegistration || editingEventInFull || editingEventInGrid">
- {{'register_event'| translate}}
- </button>
- </td>
- <td ng-if="(editingEventInFull || eventRegistration) && customForm" style='padding-left: 10px;'>
- <button class="button button-std"
- ng-click="switchDataEntryForm()">
- {{displayCustomForm ? 'use_default_form' : 'use_custom_form'| translate}}
- </button>
- </td>
- </tr>
-</table>
\ No newline at end of file