← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 20313: tracker-capture: regisering tracker-associate - WIP

 

------------------------------------------------------------
revno: 20313
committer: Abyot Asalefew Gizaw <abyota@xxxxxxxxx>
branch nick: dhis2
timestamp: Wed 2015-09-23 14:05:11 +0200
message:
  tracker-capture: regisering tracker-associate - WIP
modified:
  dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-tracker-capture/components/registration/default-registration-form.html
  dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-tracker-capture/components/registration/registration-controller.js
  dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-tracker-capture/i18n/i18n_app.properties
  dhis-2/dhis-web/dhis-web-apps/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
=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-tracker-capture/components/registration/default-registration-form.html'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-tracker-capture/components/registration/default-registration-form.html	2015-09-21 15:01:55 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-tracker-capture/components/registration/default-registration-form.html	2015-09-23 12:05:11 +0000
@@ -73,7 +73,7 @@
                                ng-blur="teiValueUpdated(selectedTei, attribute.id)"
                                ng-required="attribute.mandatory || attribute.unique"/>
                     </span>
-                     <span ng-switch-when="LONG_TEXT">
+                    <span ng-switch-when="LONG_TEXT">
                         <textarea row="3"
                                name="foo" 
                                class="form-control" 
@@ -83,6 +83,19 @@
                                ng-required="attribute.mandatory || attribute.unique">                                   
                         </textarea>/>                                    
                     </span>
+                    <span ng-switch-when="TRACKER_ASSOCIATE">
+                        <input type="text" 
+                               name="foo" 
+                               class="form-control-trimmed" 
+                               ng-model="selectedTei[attribute.id]" 
+                               ng-disabled="true" 
+                               ng-blur="teiValueUpdated(selectedTei, attribute.id)"
+                               style="width:85%;"
+                               ng-required="attribute.mandatory || attribute.unique"/>
+                        <a href ng-class="{true: 'disable-clicks', false: ''} [editingDisabled]" ng-click="getTrackerAssociate(attribute.id)" title="{{'get'| translate}} {{attribute.name}}">
+                            <i class="fa fa-external-link fa-2x vertical-center"></i>
+                        </a>
+                    </span>
                     <span ng-switch-default>
                         <input type="text" 
                                name="foo" 

=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-tracker-capture/components/registration/registration-controller.js'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-tracker-capture/components/registration/registration-controller.js	2015-09-21 15:01:55 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-tracker-capture/components/registration/registration-controller.js	2015-09-23 12:05:11 +0000
@@ -28,6 +28,8 @@
     $scope.registrationMode = 'REGISTRATION';    
     $scope.hiddenFields = {};
     
+    //$scope.editingDisabled = angular.isUndefined($scope.editingDisabled) ? false : $scope.editingDisabled;
+    
     $scope.attributesById = CurrentSelection.getAttributesById();
     if(!$scope.attributesById){
         $scope.attributesById = [];
@@ -371,4 +373,8 @@
         }
         return status;        
     };
+    
+    $scope.getTrackerAssociate = function(attributeId){
+        console.log('the attribute is:  ', attributeId);
+    };    
 });

=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-tracker-capture/i18n/i18n_app.properties'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-tracker-capture/i18n/i18n_app.properties	2015-09-21 15:01:55 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-tracker-capture/i18n/i18n_app.properties	2015-09-23 12:05:11 +0000
@@ -316,6 +316,7 @@
 latitude=Latitude
 longitude=Longitude
 lat_lng=[Latitude Longitude]
+get=Get
 get_from_map=Get from map
 capture=Capture
 point_and_click_for_coordinate=Point and click for coordinate

=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-tracker-capture/styles/style.css'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-tracker-capture/styles/style.css	2015-09-22 16:33:27 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-tracker-capture/styles/style.css	2015-09-23 12:05:11 +0000
@@ -963,6 +963,7 @@
 
 .disable-clicks {
     pointer-events: none;
+    color: #555;
 }
 
 @media print {