← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 15772: global program selection in tei dashboard

 

------------------------------------------------------------
revno: 15772
committer: Abyot Asalefew Gizaw abyota@xxxxxxxxx
branch nick: dhis2
timestamp: Thu 2014-06-19 17:27:17 +0200
message:
  global program selection in tei dashboard
removed:
  dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/views/dashboard.html
added:
  dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dashboard/
  dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dashboard/dashboard-controller.js
  dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dashboard/dashboard-widgets-controller.js
  dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dashboard/dashboard.html
modified:
  dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dataentry/dataentry-controller.js
  dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dataentry/dataentry.html
  dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/enrollment/enrollment-controller.js
  dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/enrollment/enrollment.html
  dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/notes/notes.html
  dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/profile/profile-controller.js
  dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/profile/profile.html
  dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/registration/registration-controller.js
  dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/index.html
  dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/scripts/app.js
  dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/scripts/controllers.js
  dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/scripts/services.js
  dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/styles/style.css


--
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
=== added directory 'dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dashboard'
=== added file 'dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dashboard/dashboard-controller.js'
--- dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dashboard/dashboard-controller.js	1970-01-01 00:00:00 +0000
+++ dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dashboard/dashboard-controller.js	2014-06-19 15:27:17 +0000
@@ -0,0 +1,99 @@
+//Controller for dashboard
+trackerCapture.controller('DashboardController',
+        function($rootScope,
+                $scope,
+                $location,
+                $modal,
+                $timeout,
+                storage,
+                TEIService,  
+                ProgramFactory,
+                CurrentSelection,
+                TranslationService) {
+
+    //do translation of the dashboard page
+    TranslationService.translate();    
+    
+    //dashboard items   
+    $rootScope.dashboardWidgets = {bigger: [], smaller: []};       
+    $rootScope.enrollmentWidget = {title: 'enrollment', view: "components/enrollment/enrollment.html", show: true};
+    $rootScope.dataentryWidget = {title: 'dataentry', view: "components/dataentry/dataentry.html", show: true};
+    $rootScope.selectedWidget = {title: 'current_selections', view: "components/selected/selected.html", show: false};
+    $rootScope.profileWidget = {title: 'profile', view: "components/profile/profile.html", show: true};
+    $rootScope.relationshipWidget = {title: 'relationship', view: "components/relationship/relationship.html", show: true};
+    $rootScope.notesWidget = {title: 'notes', view: "components/notes/notes.html", show: true};    
+   
+    $rootScope.dashboardWidgets.bigger.push($rootScope.enrollmentWidget);
+    $rootScope.dashboardWidgets.bigger.push($rootScope.dataentryWidget);
+    $rootScope.dashboardWidgets.smaller.push($rootScope.selectedWidget);
+    $rootScope.dashboardWidgets.smaller.push($rootScope.profileWidget);
+    $rootScope.dashboardWidgets.smaller.push($rootScope.relationshipWidget);
+    $rootScope.dashboardWidgets.smaller.push($rootScope.notesWidget);
+    
+    //selections
+    $scope.selectedEntityId = null;
+    $scope.selectedProgramId = null;
+    
+    $scope.selectedEntityId = ($location.search()).selectedEntityId; 
+    $scope.selectedProgramId = ($location.search()).selectedProgramId; 
+    $scope.selectedOrgUnit = storage.get('SELECTED_OU');
+    $scope.selectedProgram = null;
+    $scope.programs = []; 
+    $scope.selectedEntity;
+        
+    if( $scope.selectedEntityId ){
+        
+        //Fetch the selected entity
+        TEIService.get($scope.selectedEntityId).then(function(data){
+            $scope.selectedEntity = data;
+            
+            ProgramFactory.getAll().then(function(programs){  
+            
+                angular.forEach(programs, function(program){
+                    if(program.organisationUnits.hasOwnProperty($scope.selectedOrgUnit.id) &&
+                       program.trackedEntity.id === $scope.selectedEntity.trackedEntity){
+                        $scope.programs.push(program);
+                    }
+                    
+                    if($scope.selectedProgramId && program.id === $scope.selectedProgramId){
+                        $scope.selectedProgram = program;
+                    }
+                });
+                
+                //broadcast selected items for dashboard controllers
+                $scope.broadCastProgram();                                    
+            });
+        });       
+    }   
+    
+    $scope.broadCastProgram = function(){
+        CurrentSelection.set({tei: $scope.selectedEntity, pr: $scope.selectedProgram});
+        $timeout(function() { 
+            $rootScope.$broadcast('selectedEntity', {});
+        }, 100); 
+    };
+     
+    
+    $scope.back = function(){
+        $location.path('/');
+    };
+    
+    $scope.displayEnrollment = false;
+    $scope.showEnrollment = function(){
+        $scope.displayEnrollment = true;
+    };
+    
+    $scope.removeWidget = function(widget){        
+        widget.show = false;
+    };
+    
+    $scope.showHideWidgets = function(){
+        var modalInstance = $modal.open({
+            templateUrl: "views/widgets.html",
+            controller: "DashboardWidgetsController"
+        });
+
+        modalInstance.result.then(function () {
+        });
+    };
+});

=== added file 'dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dashboard/dashboard-widgets-controller.js'
--- dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dashboard/dashboard-widgets-controller.js	1970-01-01 00:00:00 +0000
+++ dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dashboard/dashboard-widgets-controller.js	2014-06-19 15:27:17 +0000
@@ -0,0 +1,12 @@
+//Controller for the dashboard widgets
+trackerCapture.controller('DashboardWidgetsController', 
+    function($scope, 
+            $modalInstance,
+            TranslationService){
+    
+    TranslationService.translate();
+    
+    $scope.close = function () {
+        $modalInstance.close($scope.eventGridColumns);
+    };       
+});
\ No newline at end of file

=== added file 'dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dashboard/dashboard.html'
--- dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dashboard/dashboard.html	1970-01-01 00:00:00 +0000
+++ dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dashboard/dashboard.html	2014-06-19 15:27:17 +0000
@@ -0,0 +1,47 @@
+<div class="container-1-1">    
+    <div class="col-sm-12 vertical-spacing">
+
+        <button type="button" class="btn btn-default" ng-click="back()">{{'back'| translate}}</button>
+
+        <select ng-model="selectedProgram"
+                class="form-control-program"
+                ng-options="program as program.name for program in programs | orderBy: 'name'" 
+                ng-change="broadCastProgram()">
+            <option value="">{{'please_select_a_program'| translate}}</option>
+        </select>
+
+        <div class="pull-right">
+            <div class="btn-group" dropdown is-open="status.isopen">
+                <button type="button" class="btn btn-default dropdown-toggle">
+                    <i class="fa fa-cog" title="{{'settings'| translate}}"></i>
+                </button>
+                <ul class="dropdown-menu pull-right" role="menu">
+                    <li><a href ng-click="showHideWidgets()">{{'show_hide_widgets'| translate}}</a></li>
+                </ul>
+            </div>
+        </div>
+    </div>
+
+    <div class='separator'></div>
+
+    <div class="col-sm-12">
+        <div class="row">            
+            <div class="col-sm-6 col-md-8">
+                <div sortable class="row connectedSortable empty-dashboard-container">
+                    <div ng-repeat="biggerWidget in dashboardWidgets.bigger">
+                        <div class="col-sm-12" ng-show="biggerWidget.show" ng-include="biggerWidget.view"></div>
+                    </div>                                       
+                </div>                
+            </div>            
+            <div class="col-sm-6 col-md-4">
+                <div sortable class="row connectedSortable empty-dashboard-container">                    
+                    <div class="col-sm-12" ng-repeat="smallerWidget in dashboardWidgets.smaller">                        
+                        <div ng-show="smallerWidget.show" ng-include="smallerWidget.view"></div>
+                    </div>                   
+                </div>
+            </div>
+        </div>
+    </div>    
+</div>
+
+

=== modified file 'dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dataentry/dataentry-controller.js'
--- dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dataentry/dataentry-controller.js	2014-06-17 07:48:20 +0000
+++ dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dataentry/dataentry-controller.js	2014-06-19 15:27:17 +0000
@@ -13,7 +13,6 @@
      
     //listen for the selected items
     $scope.$on('dashboard', function(event, args) {  
-        
         var today = moment();
         today = Date.parse(today);
         today = $filter('date')(today, 'yyyy-MM-dd');

=== modified file 'dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dataentry/dataentry.html'
--- dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dataentry/dataentry.html	2014-06-17 07:48:20 +0000
+++ dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/dataentry/dataentry.html	2014-06-19 15:27:17 +0000
@@ -9,101 +9,105 @@
         </span>        
     </div>
 
-    <div ng-show="dhis2Events">            
-        <table class="table-borderless">
-            <tbody>
-                <tr>
-                    <td class="inline-block" ng-repeat="dhis2Event in dhis2Events">
-                        <span class="block align-center">{{dhis2Event.orgUnitName}}</span>                                              
-                        <span class="stage-container"                                                     
-                              ng-class="{'current-stage': currentEvent && currentEvent.event == dhis2Event.event, '{{dhis2Event.statusColor}}': true}"                                                      
-                              ng-click="showDataEntry(dhis2Event)">
-                            {{dhis2Event.name}}<br/>
-                            {{dhis2Event.eventDate}}         
-                        </span>
-                        <i class="fa fa-arrow-right" ng-show="$index < dhis2Events.length-1"></i>
-                    </td>                        
-                </tr>
-            </tbody>                
-        </table>
-        <hr>
-        <div ng-show="currentEvent">
-            <table class="table-borderless table-striped">
-                <thead class="align-center">
+    <div class="panel-body dashboard-widget-container">
+        <div ng-show="dhis2Events">            
+            <table class="table-borderless">
+                <tbody>
                     <tr>
-                        <th class="align-center">
-                            {{'data_element' | translate}}
-                        </th>
-                        <th class="align-center">
-                            {{'value' | translate}}
-                        </th>
-                        <th class="align-center">
-                            {{'provided_elsewhere' | translate}}
-                        </th>
+                        <td class="inline-block" ng-repeat="dhis2Event in dhis2Events">
+                            <span class="block align-center">{{dhis2Event.orgUnitName}}</span>                                              
+                            <span class="stage-container"                                                     
+                                  ng-class="{'current-stage': currentEvent && currentEvent.event == dhis2Event.event, '{{dhis2Event.statusColor}}': true}"                                                      
+                                  ng-click="showDataEntry(dhis2Event)">
+                                {{dhis2Event.name}}<br/>
+                                {{dhis2Event.eventDate}}         
+                            </span>
+                            <i class="fa fa-arrow-right" ng-show="$index < dhis2Events.length - 1"></i>
+                        </td>                        
                     </tr>
-                </thead>
-                    
-                <tr ng-repeat="prStDe in currentStage.programStageDataElements">
-                    <td>
-                        {{prStDe.dataElement.name}}
-                    </td>
-                    <td>
-                        <div ng-switch="prStDe.dataElement.type">
-                            <div ng-switch-when="int">
-                                <input type="number"
-                                       class="form-control"
-                                       ng-model="currentEvent[prStDe.dataElement.id]" 
-                                       ng-required={{prStDe.compulsory}}
-                                       ng-blur="saveDatavalue(prStDe)" 
-                                       name="foo"/>
-                            </div>
-                            <div ng-switch-when="string">                                        
-                                <input type="text"
-                                       class="form-control"
-                                       ng-model="currentEvent[prStDe.dataElement.id]" 
-                                       ng-required={{prStDe.compulsory}} 
-                                       typeahead="option for option in prStDe.dataElement.optionSet.options | filter:$viewValue | limitTo:20" 
-                                       typeahead-open-on-focus    
-                                       ng-blur="saveDatavalue(prStDe)" 
-                                       name="foo"/>
-                            </div>
-                            <div ng-switch-when="bool">
-                                <select class="form-control"
-                                        ng-model="currentEvent[prStDe.dataElement.id]" 
-                                        ng-required={{prStDe.compulsory}} 
-                                        ng-change="saveDatavalue(prStDe)" 
-                                        name="foo">
-                                    <option value="">{{'please_select'| translate}}</option>                        
-                                    <option value="0">{{'no'| translate}}</option>
-                                    <option value="1">{{'yes'| translate}}</option>
-                                </select>
-
-                            </div>
-                            <div ng-switch-when="date">
-                                <input type="text" 
-                                       placeholder="yyyy-mm-dd" 
-                                       ng-date 
-                                       class="form-control"
-                                       ng-model="saveDatavalue(prStDe)" 
-                                       ng-required={{prStDe.compulsory}}  
-                                       blur-or-change="saveDatavalue(dhis2Event, eventGridColumn.id)"
-                                       name="foo"/>
-                            </div>
-                        </div>
-                    </td>
-                    <td>                        
-                        <div class="align-center" ng-if="prStDe.allowProvidedElsewhere">
-                            <input type="checkbox" 
-                                   ng-model="currentEvent.providedElsewhere[prStDe.dataElement.id]"
-                                   ng-change="saveDatavalueLocation(prStDe)"/>
-                        </div>
-                    </td>
-                </tr>
-            </table>    
-            
+                </tbody>                
+            </table>
             <hr>
-
+            <div ng-show="currentEvent">
+                <table class="table-borderless table-striped">
+                    <thead class="align-center">
+                        <tr>
+                            <th class="align-center">
+                                {{'data_element'| translate}}
+                            </th>
+                            <th class="align-center">
+                                {{'value'| translate}}
+                            </th>
+                            <th class="align-center">
+                                {{'provided_elsewhere'| translate}}
+                            </th>
+                        </tr>
+                    </thead>
+
+                    <tr ng-repeat="prStDe in currentStage.programStageDataElements">
+                        <td>
+                            {{prStDe.dataElement.name}}
+                        </td>
+                        <td>
+                            <div ng-switch="prStDe.dataElement.type">
+                                <div ng-switch-when="int">
+                                    <input type="number"
+                                           class="form-control"
+                                           ng-model="currentEvent[prStDe.dataElement.id]" 
+                                           ng-required={{prStDe.compulsory}}
+                                           ng-blur="saveDatavalue(prStDe)" 
+                                           name="foo"/>
+                                </div>
+                                <div ng-switch-when="string">                                        
+                                    <input type="text"
+                                           class="form-control"
+                                           ng-model="currentEvent[prStDe.dataElement.id]" 
+                                           ng-required={{prStDe.compulsory}} 
+                                           typeahead="option for option in prStDe.dataElement.optionSet.options | filter:$viewValue | limitTo:20" 
+                                           typeahead-open-on-focus    
+                                           ng-blur="saveDatavalue(prStDe)" 
+                                           name="foo"/>
+                                </div>
+                                <div ng-switch-when="bool">
+                                    <select class="form-control"
+                                            ng-model="currentEvent[prStDe.dataElement.id]" 
+                                            ng-required={{prStDe.compulsory}} 
+                                            ng-change="saveDatavalue(prStDe)" 
+                                            name="foo">
+                                        <option value="">{{'please_select'| translate}}</option>                        
+                                        <option value="0">{{'no'| translate}}</option>
+                                        <option value="1">{{'yes'| translate}}</option>
+                                    </select>
+
+                                </div>
+                                <div ng-switch-when="date">
+                                    <input type="text" 
+                                           placeholder="yyyy-mm-dd" 
+                                           ng-date 
+                                           class="form-control"
+                                           ng-model="saveDatavalue(prStDe)" 
+                                           ng-required={{prStDe.compulsory}}  
+                                           blur-or-change="saveDatavalue(dhis2Event, eventGridColumn.id)"
+                                           name="foo"/>
+                                </div>
+                            </div>
+                        </td>
+                        <td>                        
+                            <div class="align-center" ng-if="prStDe.allowProvidedElsewhere">
+                                <input type="checkbox" 
+                                       ng-model="currentEvent.providedElsewhere[prStDe.dataElement.id]"
+                                       ng-change="saveDatavalueLocation(prStDe)"/>
+                            </div>
+                        </td>
+                    </tr>
+                </table>    
+
+                <hr>
+
+            </div>
         </div>
     </div>
 
+
+
 </div>
\ No newline at end of file

=== modified file 'dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/enrollment/enrollment-controller.js'
--- dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/enrollment/enrollment-controller.js	2014-06-06 13:35:06 +0000
+++ dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/enrollment/enrollment-controller.js	2014-06-19 15:27:17 +0000
@@ -27,33 +27,16 @@
     $scope.$on('selectedEntity', function(event, args) {   
         $scope.newEnrollment = {};
         var selections = CurrentSelection.get();
-        $scope.selectedEntity = selections.tei;        
+        $scope.selectedEntity = selections.tei; 
+        $scope.selectedProgram = selections.pr;
         $scope.selectedOrgUnit = storage.get('SELECTED_OU');
         
-        ProgramFactory.getAll().then(function(programs){  
-            
-            angular.forEach(programs, function(program){
-                if(program.organisationUnits.hasOwnProperty($scope.selectedOrgUnit.id) &&
-                   program.trackedEntity.id === $scope.selectedEntity.trackedEntity){
-                    $scope.programs.push(program);
-                }
-            });
-
-            EnrollmentService.get($scope.selectedEntity.trackedEntityInstance).then(function(data){
+        if($scope.selectedProgram){ 
+            EnrollmentService.getByEntityAndProgram($scope.selectedEntity.trackedEntityInstance, $scope.selectedProgram.id).then(function(data){
                 $scope.enrollments = data.enrollmentList;  
-                if(selections.pr){   
-                    angular.forEach($scope.programs, function(program){
-                        if(selections.pr.id === program.id){
-                            $scope.selectedProgram = program;
-                            $scope.loadEvents();
-                        }
-                    });
-                }
-
-                CurrentSelection.set({tei: $scope.selectedEntity, pr: $scope.selectedProgram, enrollment: $scope.selectedEnrollment});
-                $rootScope.$broadcast('dashboard', {});
-            });                           
-        });        
+                $scope.loadEvents();                
+            });
+        }        
     }); 
     
     $scope.loadEvents = function() {

=== modified file 'dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/enrollment/enrollment.html'
--- dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/enrollment/enrollment.html	2014-06-06 13:35:06 +0000
+++ dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/enrollment/enrollment.html	2014-06-19 15:27:17 +0000
@@ -5,146 +5,135 @@
             <a href ng-click="removeWidget(enrollmentWidget)" title="{{'remove'| translate}}"><span class='black'><i class="fa fa-times-circle"></i></span></a>            
         </span>
     </div>
-    <table class="table-borderless table-striped">
-        <tr>
-            <td>
-                <select ng-model="selectedProgram"
-                        class="form-control"
-                        ng-options="program as program.name for program in programs | orderBy: 'name'" 
-                        ng-change="loadEvents()">
-                    <option value="">{{'please_select_a_program'| translate}}</option>
-                </select>
-            </td>           
-        </tr>
-    </table>
-
-    <div class="horizonal-spacing" ng-if="selectedEnrollment">
-        <hr>
-        <table class="table-borderless">
-            <tr>
-                <td>
-                    {{selectedProgram.dateOfIncidentDescription}}
-                </td>
-                <td>
-                    <input type="text" class="form-control" ng-date ng-model="selectedEnrollment.dateOfIncident" ng-disabled="true"/>
-                </td>
-            </tr>
-
-        </table>
-        <hr>
-        <table class="table-borderless table-striped">
-            <thead>
+    <div class="panel-body dashboard-widget-container">
+        <div ng-if="selectedProgram">
+            <table class="table-borderless">
                 <tr>
-                    <th>
-                        {{'program_stage'| translate}}
-                    </th>
-                    <th>
-                        {{'scheduled_date'| translate}}
-                    </th>
-                </tr>                
-            </thead>           
-            <tr ng-repeat="programStage in programStages">
-                <td>
-                    {{programStage.name}}
-                </td>
-                <td>
-                    <input type="text" class="form-control" ng-date ng-model="programStage.dueDate" ng-disabled="!showSchedulingDiv"/>
-                </td>
-            </tr>
-        </table>
-
-        <div class="vertical-spacing small-horizonal-spacing">
-            <button type="button" 
-                    class="btn btn-default"
-                    ng-disabled="showSchedulingDiv"
-                    ng-click="showScheduling()">
-                {{'reschedule'| translate}}
-            </button>
-            <button type="button" 
-                    class="btn btn-default"
-                    ng-show="showSchedulingDiv"
-                    ng-click="showScheduling()">
-                {{'save'| translate}}
-            </button>
-            <button type="button" 
-                    class="btn btn-default"
-                    ng-show="showSchedulingDiv"
-                    ng-click="showScheduling()">
-                {{'cancel'| translate}}
-            </button>
-        </div>
-    </div>    
-    <div class="vertical-spacing horizonal-spacing" ng-if="selectedProgram && !selectedEnrollment">
-        <hr>
-        <table class="table-borderless">
-            <tr>
-                <td>
-                    {{selectedProgram.dateOfEnrollmentDescription}}
-                </td>
-                <td>
-                    <input type="text" class="form-control" ng-date ng-model="newEnrollment.dateOfEnrollment" />
-                </td>
-            </tr>     
-            <tr ng-if="selectedProgram.displayIncidentDate">
-                <td>
-                    {{selectedProgram.dateOfIncidentDescription}}
-                </td>
-                <td>
-                    <input type="text" class="form-control" ng-date ng-model="newEnrollment.dateOfIncident" />                    
-                </td>
-            </tr>
-        </table>
-        <hr>
-        <table class="table-borderless table-striped">
-            <tr ng-repeat="attribute in attributesForEnrollment">
-                <td>
-                    {{attribute.name}}
-                </td>
-                <td>
-                    <div ng-switch="attribute.valueType">
-                        <div ng-switch-when="date">
-                            <input type="text" class="form-control" ng-date ng-model="attribute.value" />
-                        </div>
-                        <div ng-switch-when="trueOnly">
-                            <input type="checkbox" class="form-control" ng-model="attribute.value" />
-                        </div>
-                        <div ng-switch-when="bool">
-                            <select ng-model="attribute.value" class="form-control">
-                                <option value="">{{'please_select'| translate}}</option>                        
-                                <option value="0">{{'no'| translate}}</option>
-                                <option value="1">{{'yes'| translate}}</option>
-                            </select>
-                        </div>
-                        <div ng-switch-when="optionSet">
-                            <input type="text" 
-                                   class="form-control"
-                                   ng-model="attribute.value"                                                 
-                                   typeahead="option for option in attribute.optionSet.options | filter:$viewValue | limitTo:20" 
-                                   typeahead-open-on-focus 
-                                   />
-                        </div>
-                        <div ng-switch-when="number">
-                            <input type="number" class="form-control" ng-model="attribute.value"/>
-                        </div>
-                        <div ng-switch-default>
-                            <input type="text" class="form-control" ng-model="attribute.value" />                                        
-                        </div>
-                    </div>                                                                                                    
-                </td>
-            </tr>                        
-        </table>
-
-        <div class="vertical-spacing small-horizonal-spacing">            
-            <button type="button" 
-                    class="btn btn-default"
-                    ng-click="enroll()">
-                {{'enroll'| translate}}
-            </button>  
-            <button type="button" 
-                    class="btn btn-default"
-                    ng-click="cancelEnrollment()">
-                {{'cancel'| translate}}
-            </button>
+                    <td>
+                        {{selectedProgram.dateOfIncidentDescription}}
+                    </td>
+                    <td>
+                        <input type="text" class="form-control" ng-date ng-model="selectedEnrollment.dateOfIncident" ng-disabled="true"/>
+                    </td>
+                </tr>
+
+            </table>
+            <hr>
+            <table class="table-borderless table-striped">
+                <thead>
+                    <tr>
+                        <th>
+                            {{'program_stage'| translate}}
+                        </th>
+                        <th>
+                            {{'scheduled_date'| translate}}
+                        </th>
+                    </tr>                
+                </thead>           
+                <tr ng-repeat="programStage in programStages">
+                    <td>
+                        {{programStage.name}}
+                    </td>
+                    <td>
+                        <input type="text" class="form-control" ng-date ng-model="programStage.dueDate" ng-disabled="!showSchedulingDiv"/>
+                    </td>
+                </tr>
+            </table>
+
+            <div class="vertical-spacing small-horizonal-spacing">
+                <button type="button" 
+                        class="btn btn-default"
+                        ng-disabled="showSchedulingDiv"
+                        ng-click="showScheduling()">
+                    {{'reschedule'| translate}}
+                </button>
+                <button type="button" 
+                        class="btn btn-default"
+                        ng-show="showSchedulingDiv"
+                        ng-click="showScheduling()">
+                    {{'save'| translate}}
+                </button>
+                <button type="button" 
+                        class="btn btn-default"
+                        ng-show="showSchedulingDiv"
+                        ng-click="showScheduling()">
+                    {{'cancel'| translate}}
+                </button>
+            </div>
+
+            <div class="vertical-spacing horizonal-spacing" ng-if="selectedProgram && !selectedEnrollment">
+                <hr>
+                <table class="table-borderless">
+                    <tr>
+                        <td>
+                            {{selectedProgram.dateOfEnrollmentDescription}}
+                        </td>
+                        <td>
+                            <input type="text" class="form-control" ng-date ng-model="newEnrollment.dateOfEnrollment" />
+                        </td>
+                    </tr>     
+                    <tr ng-if="selectedProgram.displayIncidentDate">
+                        <td>
+                            {{selectedProgram.dateOfIncidentDescription}}
+                        </td>
+                        <td>
+                            <input type="text" class="form-control" ng-date ng-model="newEnrollment.dateOfIncident" />                    
+                        </td>
+                    </tr>
+                </table>
+                <hr>
+                <table class="table-borderless table-striped">
+                    <tr ng-repeat="attribute in attributesForEnrollment">
+                        <td>
+                            {{attribute.name}}
+                        </td>
+                        <td>
+                            <div ng-switch="attribute.valueType">
+                                <div ng-switch-when="date">
+                                    <input type="text" class="form-control" ng-date ng-model="attribute.value" />
+                                </div>
+                                <div ng-switch-when="trueOnly">
+                                    <input type="checkbox" class="form-control" ng-model="attribute.value" />
+                                </div>
+                                <div ng-switch-when="bool">
+                                    <select ng-model="attribute.value" class="form-control">
+                                        <option value="">{{'please_select'| translate}}</option>                        
+                                        <option value="0">{{'no'| translate}}</option>
+                                        <option value="1">{{'yes'| translate}}</option>
+                                    </select>
+                                </div>
+                                <div ng-switch-when="optionSet">
+                                    <input type="text" 
+                                           class="form-control"
+                                           ng-model="attribute.value"                                                 
+                                           typeahead="option for option in attribute.optionSet.options | filter:$viewValue | limitTo:20" 
+                                           typeahead-open-on-focus 
+                                           />
+                                </div>
+                                <div ng-switch-when="number">
+                                    <input type="number" class="form-control" ng-model="attribute.value"/>
+                                </div>
+                                <div ng-switch-default>
+                                    <input type="text" class="form-control" ng-model="attribute.value" />                                        
+                                </div>
+                            </div>                                                                                                    
+                        </td>
+                    </tr>                        
+                </table>
+
+                <div class="vertical-spacing small-horizonal-spacing">            
+                    <button type="button" 
+                            class="btn btn-default"
+                            ng-click="enroll()">
+                        {{'enroll'| translate}}
+                    </button>  
+                    <button type="button" 
+                            class="btn btn-default"
+                            ng-click="cancelEnrollment()">
+                        {{'cancel'| translate}}
+                    </button>
+                </div>
+            </div>
         </div>
     </div>
 </div>
\ No newline at end of file

=== modified file 'dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/notes/notes.html'
--- dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/notes/notes.html	2014-05-27 12:38:36 +0000
+++ dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/notes/notes.html	2014-06-19 15:27:17 +0000
@@ -5,7 +5,7 @@
             <a href ng-click="removeWidget(notesWidget)" title="{{'remove'| translate}}"><span class='black'><i class="fa fa-times-circle"></i></span></a>            
         </span>        
     </div>
-    <div class="panel-body dashboard-element-container">
+    <div class="panel-body dashboard-widget-container">
         This is notes.
     </div>
 </div>
\ No newline at end of file

=== modified file 'dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/profile/profile-controller.js'
--- dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/profile/profile-controller.js	2014-06-19 10:07:22 +0000
+++ dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/profile/profile-controller.js	2014-06-19 15:27:17 +0000
@@ -19,19 +19,17 @@
     }); 
     
     //listen for the selected entity       
-    $scope.$on('dashboard', function(event, args) { 
+    $scope.$on('selectedEntity', function(event, args) { 
         var selections = CurrentSelection.get();
         $scope.selectedEntity = selections.tei; 
         $scope.selectedProgram = selections.pr; 
-        
         if($scope.selectedEntity){
             TEService.get($scope.selectedEntity.trackedEntity).then(function(te){
                 $scope.trackedEntity = te;
             });
             
             $scope.processTeiAttributes();
-        }
-        
+        }        
     });
     
     //display only those attributes that belong the selected program
@@ -42,7 +40,7 @@
             if(att.type === 'number' && !isNaN(parseInt(att.value))){
                 att.value = parseInt(att.value);
             }
-        });
+        });        
         
         if($scope.selectedProgram){
             //show only those attributes in selected program            
@@ -110,4 +108,4 @@
         $scope.selectedEntity.attributes = $scope.entityAttributes;  
         $scope.editProfile = !$scope.editProfile;
     };
-});
+});
\ No newline at end of file

=== modified file 'dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/profile/profile.html'
--- dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/profile/profile.html	2014-06-06 13:35:06 +0000
+++ dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/profile/profile.html	2014-06-19 15:27:17 +0000
@@ -9,58 +9,61 @@
             <a href ng-click="removeWidget(profileWidget)" title="{{'remove'| translate}}"><span class='black'><i class="fa fa-times-circle"></i></span></a>            
         </span>        
     </div>
-    <table class="table-borderless table-striped">
-        <tr ng-repeat="attribute in selectedEntity.attributes" ng-show="attribute.show">
-            <td>
-                {{attribute.displayName}}
-            </td>
-            <td>
-                <div ng-switch="attribute.type">
-                    <div ng-switch-when="date">
-                        <input type="text" class="form-control" ng-date ng-model="attribute.value"  value="attribute.value | date:'yyyy-MM-dd" ng-disabled="!editProfile"/>
-                    </div>
-                    <div ng-switch-when="trueOnly">
-                        <input type="checkbox" class="form-control" ng-model="attribute.value" ng-disabled="!editProfile"/>
-                    </div>
-                    <div ng-switch-when="bool">
-                        <select ng-model="attribute.value" class="form-control" ng-disabled="!editProfile">
-                            <option value="">{{'please_select'| translate}}</option>                        
-                            <option value="0">{{'no'| translate}}</option>
-                            <option value="1">{{'yes'| translate}}</option>
-                        </select>
-                    </div>
-                    <div ng-switch-when="optionSet">
-                        <input type="text"  
-                               class="form-control"
-                               ng-model="attribute.value"                                                 
-                               typeahead="option for option in attributes[attribute.attribute].optionSet.options | filter:$viewValue | limitTo:20" 
-                               typeahead-open-on-focus 
-                               ng-disabled="!editProfile"/>
-                    </div>
-                    <div ng-switch-when="number">
-                        <input type="number" class="form-control" ng-model="attribute.value" ng-disabled="!editProfile"/>
-                    </div>
-                    <div ng-switch-default>
-                        <input type="text"  class="form-control" ng-model="attribute.value" ng-disabled="!editProfile"/>                         
-                    </div>
-                </div>                                                                                                    
-            </td>
-        </tr>           
-    </table>
-
-    <div class="widget-content-container" ng-if="editProfile">
-
-        <button type="button" 
-                class="btn btn-default small-horizonal-spacing"
-                ng-click="save()">
-            {{'save'| translate}}
-        </button>        
-        <button type="button" 
-                class="btn btn-default small-horizonal-spacing" 
-                ng-click="cancel()">
-            {{'cancel'| translate}}
-        </button>        
-
-    </div>
+    <div class="widget-content-container">
+        <table class="table-borderless table-striped">
+            <tr ng-repeat="attribute in selectedEntity.attributes" ng-show="attribute.show">
+                <td>
+                    {{attribute.displayName}}
+                </td>
+                <td>
+                    <div ng-switch="attribute.type">
+                        <div ng-switch-when="date">
+                            <input type="text" class="form-control" ng-date ng-model="attribute.value"  value="attribute.value | date:'yyyy-MM-dd" ng-disabled="!editProfile"/>
+                        </div>
+                        <div ng-switch-when="trueOnly">
+                            <input type="checkbox" class="form-control" ng-model="attribute.value" ng-disabled="!editProfile"/>
+                        </div>
+                        <div ng-switch-when="bool">
+                            <select ng-model="attribute.value" class="form-control" ng-disabled="!editProfile">
+                                <option value="">{{'please_select'| translate}}</option>                        
+                                <option value="0">{{'no'| translate}}</option>
+                                <option value="1">{{'yes'| translate}}</option>
+                            </select>
+                        </div>
+                        <div ng-switch-when="optionSet">
+                            <input type="text"  
+                                   class="form-control"
+                                   ng-model="attribute.value"                                                 
+                                   typeahead="option for option in attributes[attribute.attribute].optionSet.options | filter:$viewValue | limitTo:20" 
+                                   typeahead-open-on-focus 
+                                   ng-disabled="!editProfile"/>
+                        </div>
+                        <div ng-switch-when="number">
+                            <input type="number" class="form-control" ng-model="attribute.value" ng-disabled="!editProfile"/>
+                        </div>
+                        <div ng-switch-default>
+                            <input type="text"  class="form-control" ng-model="attribute.value" ng-disabled="!editProfile"/>                         
+                        </div>
+                    </div>                                                                                                    
+                </td>
+            </tr>           
+        </table>
+
+        <div ng-if="editProfile">
+
+            <button type="button" 
+                    class="btn btn-default small-horizonal-spacing"
+                    ng-click="save()">
+                {{'save'| translate}}
+            </button>        
+            <button type="button" 
+                    class="btn btn-default small-horizonal-spacing" 
+                    ng-click="cancel()">
+                {{'cancel'| translate}}
+            </button>        
+
+        </div>
+    </div> 
+
 
 </div>
\ No newline at end of file

=== modified file 'dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/registration/registration-controller.js'
--- dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/registration/registration-controller.js	2014-06-19 12:56:21 +0000
+++ dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/components/registration/registration-controller.js	2014-06-19 15:27:17 +0000
@@ -25,7 +25,7 @@
         $scope.trackedEntities.selected = $scope.trackedEntities.available[0];
     });
     
-    //watch for selection of org unit from tree
+    //watch for selection of program
     $scope.$watch('selectedProgram', function() {        
         if( angular.isObject($scope.selectedProgram)){
             $scope.trackedEntityList = [];

=== modified file 'dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/index.html'
--- dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/index.html	2014-06-17 07:48:20 +0000
+++ dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/index.html	2014-06-19 15:27:17 +0000
@@ -63,6 +63,8 @@
         <script type="text/javascript" src="scripts/filters.js"></script>
         <script type="text/javascript" src="scripts/directives.js"></script>
         <script type="text/javascript" src="scripts/controllers.js"></script>
+        <script type="text/javascript" src="components/dashboard/dashboard-controller.js"></script>
+        <script type="text/javascript" src="components/dashboard/dashboard-widgets-controller.js"></script>
         <script type="text/javascript" src="components/registration/registration-controller.js"></script>
         <script type="text/javascript" src="components/enrollment/enrollment-controller.js"></script>
         <script type="text/javascript" src="components/dataentry/dataentry-controller.js"></script>

=== modified file 'dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/scripts/app.js'
--- dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/scripts/app.js	2014-06-17 07:48:20 +0000
+++ dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/scripts/app.js	2014-06-19 15:27:17 +0000
@@ -17,8 +17,6 @@
               
 .value('DHIS2URL', '..')
 
-
-
 .config(function($httpProvider, $routeProvider, $translateProvider) {    
             
     $httpProvider.defaults.useXDomain = true;
@@ -28,7 +26,7 @@
         templateUrl:'views/home.html',
         controller: 'SelectionController'
     }).when('/dashboard',{
-        templateUrl:'views/dashboard.html',
+        templateUrl:'components/dashboard/dashboard.html',
         controller: 'DashboardController'
     }).otherwise({
         redirectTo : '/'

=== modified file 'dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/scripts/controllers.js'
--- dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/scripts/controllers.js	2014-06-19 12:56:21 +0000
+++ dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/scripts/controllers.js	2014-06-19 15:27:17 +0000
@@ -298,112 +298,6 @@
     };    
 })
 
-//Controller for registration section
-
-
-//Controller for dashboard
-.controller('DashboardController',
-        function($rootScope,
-                $scope,
-                $location,
-                $modal,
-                $timeout,
-                storage,
-                TEIService,  
-                ProgramFactory,
-                CurrentSelection,
-                TranslationService) {
-
-    //do translation of the dashboard page
-    TranslationService.translate();    
-    
-    //dashboard items   
-    $rootScope.dashboardWidgets = {bigger: [], smaller: []};       
-    $rootScope.enrollmentWidget = {title: 'enrollment', view: "components/enrollment/enrollment.html", show: true};
-    $rootScope.dataentryWidget = {title: 'dataentry', view: "components/dataentry/dataentry.html", show: true};
-    $rootScope.selectedWidget = {title: 'current_selections', view: "components/selected/selected.html", show: false};
-    $rootScope.profileWidget = {title: 'profile', view: "components/profile/profile.html", show: true};
-    $rootScope.relationshipWidget = {title: 'relationship', view: "components/relationship/relationship.html", show: true};
-    $rootScope.notesWidget = {title: 'notes', view: "components/notes/notes.html", show: true};    
-   
-    $rootScope.dashboardWidgets.bigger.push($rootScope.enrollmentWidget);
-    $rootScope.dashboardWidgets.bigger.push($rootScope.dataentryWidget);
-    $rootScope.dashboardWidgets.smaller.push($rootScope.selectedWidget);
-    $rootScope.dashboardWidgets.smaller.push($rootScope.profileWidget);
-    $rootScope.dashboardWidgets.smaller.push($rootScope.relationshipWidget);
-    $rootScope.dashboardWidgets.smaller.push($rootScope.notesWidget);
-    
-    //selections
-    $scope.selectedEntityId = null;
-    $scope.selectedProgramId = null;
-    
-    $scope.selectedEntityId = ($location.search()).selectedEntityId; 
-    $scope.selectedProgramId = ($location.search()).selectedProgramId; 
-    $scope.selectedOrgUnit = storage.get('SELECTED_OU');
-        
-    if( $scope.selectedEntityId ){
-      
-        //Fetch the selected entity
-        TEIService.get($scope.selectedEntityId).then(function(data){     
-            
-            if($scope.selectedProgramId){
-                ProgramFactory.get($scope.selectedProgramId).then(function(program){
-                    $scope.selectedProgram = program;   
-                    
-                    //broadcast selected items for dashboard controllers
-                    CurrentSelection.set({tei: data, pr: $scope.selectedProgram});
-                    $timeout(function() { 
-                        $rootScope.$broadcast('selectedEntity', {});
-                    }, 100);
-                });
-            }
-            else{                
-                //broadcast selected items for dashboard controllers
-                CurrentSelection.set({tei: data, pr: ''});
-                $timeout(function() { 
-                    $rootScope.$broadcast('selectedEntity', {});
-                }, 100);
-            }
-        });       
-    }   
-    
-    $scope.back = function(){
-        $location.path('/');
-    };
-    
-    $scope.displayEnrollment = false;
-    $scope.showEnrollment = function(){
-        $scope.displayEnrollment = true;
-    };
-    
-    $scope.removeWidget = function(widget){        
-        widget.show = false;
-    };
-    
-    $scope.showHideWidgets = function(){
-        var modalInstance = $modal.open({
-            templateUrl: "views/widgets.html",
-            controller: "DashboardWidgetsController"
-        });
-
-        modalInstance.result.then(function () {
-        });
-    };
-})
-
-//Controller for the dashboard widgets
-.controller('DashboardWidgetsController', 
-    function($scope, 
-            $modalInstance,
-            TranslationService){
-    
-    TranslationService.translate();
-    
-    $scope.close = function () {
-        $modalInstance.close($scope.eventGridColumns);
-    };       
-})
-
 //Controller for the header section
 .controller('HeaderController',
         function($scope,                

=== modified file 'dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/scripts/services.js'
--- dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/scripts/services.js	2014-06-19 12:56:21 +0000
+++ dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/scripts/services.js	2014-06-19 15:27:17 +0000
@@ -178,12 +178,30 @@
             });
             return promise;
         },
+        getByEntity: function( entity ){
+            var promise = $http.get(  '../api/enrollments?trackedEntityInstance=' + entity ).then(function(response){
+                return response.data;
+            });
+            return promise;
+        },
+        getByEntityAndProgram: function( entity, program ){
+            var promise = $http.get(  '../api/enrollments?trackedEntityInstance=' + entity + '&program=' + program ).then(function(response){
+                return response.data;
+            });
+            return promise;
+        },
         enroll: function( enrollment ){
             var promise = $http.post(  '../api/enrollments', enrollment ).then(function(response){
                 return response.data;
             });
             return promise;
-        }        
+        },
+        update: function( enrollment){
+            var promise = $http.put( '../api/enrollments/' + enrollment.enrollment , enrollment).then(function(response){
+                return response.data;
+            });
+            return promise;
+        }
     };   
 })
 

=== modified file 'dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/styles/style.css'
--- dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/styles/style.css	2014-06-19 10:07:22 +0000
+++ dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/styles/style.css	2014-06-19 15:27:17 +0000
@@ -37,6 +37,13 @@
     color: #585D61;
 }
 
+.dashboard-top-bar {
+    padding-right: 15px;
+    padding-left: 15px;
+    margin-right: auto;
+    margin-left: auto;
+}
+
 /*----------------------------------------------------------------------------*/
 /* Form
 /*----------------------------------------------------------------------------*/
@@ -543,9 +550,9 @@
     margin-bottom: 10px;
 }
 
-.dashboard-element-container {
-    max-height: 250px !important;
-    height: 250px !important;
+.dashboard-widget-container {
+    max-height: 400px !important;
+    height: auto;
     overflow-x:auto;
     overflow-y:auto;
 }
@@ -559,6 +566,10 @@
     margin-right: 10px;    
 }
 
+.row-with-margin {
+    padding-left: 30px;
+    padding-right: 30px;
+}
 .vertical-spacing{
     margin-top: 10px;   
     margin-bottom: 10px;
@@ -838,6 +849,26 @@
     transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s
 }
 
+.form-control-program {    
+    width: 40%;
+    height: 34px;
+    padding: 6px 6px;
+    font-size: 14px;
+    line-height: 1.0;
+    color: #555;
+    margin-bottom: 5px;
+    margin-top: 5px;
+    vertical-align: middle;
+    background-color: #fff;
+    background-image: none;
+    border: 1px solid #ccc;
+    border-radius: 4px;
+    -webkit-box-shadow: inset 0 1px 1px rgba(0,0,0,0.075);
+    box-shadow: inset 0 1px 1px rgba(0,0,0,0.075);
+    -webkit-transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s;
+    transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s
+}
+
 .form-control-select2 {
     display: block;
     width: 100%;

=== removed file 'dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/views/dashboard.html'
--- dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/views/dashboard.html	2014-06-19 09:47:23 +0000
+++ dhis-2/dhis-web/dhis-web-tracker-capture/src/main/webapp/dhis-web-tracker-capture/views/dashboard.html	1970-01-01 00:00:00 +0000
@@ -1,41 +0,0 @@
-<div class="container-1-1">    
-    <div class="col-sm-12 vertical-spacing">        
-        <button type="button" class="btn btn-default" ng-click="back()">{{'back'| translate}}</button>
-        <div class="pull-right">
-            <div class="btn-group" dropdown is-open="status.isopen">
-                <button type="button" class="btn btn-default dropdown-toggle">
-                    <i class="fa fa-cog" title="{{'settings' | translate}}"></i>
-                </button>
-                <ul class="dropdown-menu pull-right" role="menu">
-                    <li><a href ng-click="showHideWidgets()">{{'show_hide_widgets'| translate}}</a></li>
-                </ul>
-            </div>
-        </div>
-        <!--<span class="right">
-            <button type="button" class="btn btn-default" ng-click="showHideWidgets()">{{'show_hide_widgets'| translate}}</button>
-        </span> -->       
-    </div>
-
-    <div class='separator'></div>
-
-    <div class="col-sm-12">
-        <div class="row">            
-            <div class="col-sm-6 col-md-8">
-                <div sortable class="row connectedSortable empty-dashboard-container">
-                    <div ng-repeat="biggerWidget in dashboardWidgets.bigger">
-                        <div class="col-sm-12" ng-show="biggerWidget.show" ng-include="biggerWidget.view"></div>
-                    </div>                                       
-                </div>                
-            </div>            
-            <div class="col-sm-6 col-md-4">
-                <div sortable class="row connectedSortable empty-dashboard-container">                    
-                    <div class="col-sm-12" ng-repeat="smallerWidget in dashboardWidgets.smaller">                        
-                        <div ng-show="smallerWidget.show" ng-include="smallerWidget.view"></div>
-                    </div>                   
-                </div>
-            </div>
-        </div>
-    </div>    
-</div>
-
-