Skip to content

Commit

Permalink
Merge pull request #106 from OpenLMIS-Angola/OAM-45-fixTestsIssues
Browse files Browse the repository at this point in the history
OAM-45: fixed test issues
  • Loading branch information
DominikNoga authored Jun 3, 2024
2 parents 88b70c9 + 5455749 commit 726ad10
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 7 deletions.
1 change: 0 additions & 1 deletion src/admin-facility-view/facility-view.controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -328,7 +328,6 @@
var newWard = angular.copy(vm.newWard);

newWard.code = vm.generateWardCode(vm.facility.code);
console.log(newWard.type.code);

vm.addedWards.push(newWard);

Expand Down
4 changes: 2 additions & 2 deletions src/admin-facility-view/facility-view.controller.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,7 @@ describe('FacilityViewController', function() {
};
this.vm.newWard = {
enabled: true,
active: true
active: false
};
spyOn(this.vm, 'generateWardCode').andReturn('generated-code');
});
Expand Down Expand Up @@ -290,7 +290,7 @@ describe('FacilityViewController', function() {

expect(this.vm.newWard).toEqual({
enabled: true,
active: true,
active: false,
type: undefined,
geograpicZone: undefined
});
Expand Down
2 changes: 1 addition & 1 deletion src/admin-user-form/admin-user-form.routes.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
accessRights: [ADMINISTRATION_RIGHTS.USERS_MANAGE],
resolve: {
facilities: function(facilityService) {
return facilityService.getFacilitiesWithoutWards();
return facilityService.getAllMinimal();
},
user: function(UserService, $stateParams) {
return new UserService().get($stateParams.id);
Expand Down
4 changes: 1 addition & 3 deletions src/admin-user-form/user-form.controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -124,9 +124,7 @@
vm.initialUsername = vm.user.username;
vm.homeFacility = getHomeFacility();
vm.initialHomeFacility = vm.homeFacility;
vm.facilities = facilities.filter(function(facility) {
return facility.type.code !== 'WS';
});
vm.facilities = facilities;
vm.pendingVerificationEmail = pendingVerificationEmail;
}

Expand Down

0 comments on commit 726ad10

Please sign in to comment.