5334-editDepartment #1521

Merged
carlossa merged 84 commits from 5334-editDepartment into dev 2023-07-06 07:09:06 +00:00
2 changed files with 1 additions and 26 deletions
Showing only changes of commit beb173f6ce - Show all commits

View File

@ -19,6 +19,7 @@ class Controller extends ModuleCard {
}
}
]
};
this.$http.get(`Departments/${this.$params.id}`, {filter})

View File

@ -1,26 +0,0 @@
import './index.js';
describe('vnWorkerDepartmentDescriptor', () => {
let controller;
let $httpBackend;
beforeEach(ngModule('worker'));
beforeEach(inject(($componentController, _$httpBackend_) => {
$httpBackend = _$httpBackend_;
controller = $componentController('vnWorkerDepartmentDescriptor', {$element: null});
}));
describe('loadData()', () => {
it(`should perform a get query to store the department data into the controller`, () => {
const id = '31';
const response = 'foo';
$httpBackend.expectRoute('GET', `Departments/${id}`).respond(response);
controller.id = id;
$httpBackend.flush();
expect(controller.department).toEqual(response);
});
});
});