Skip to content

Commit e33cd87

Browse files
authored
feat(#9598): add training materials page (#9592)
1 parent 51da792 commit e33cd87

55 files changed

Lines changed: 2514 additions & 837 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎api/resources/translations/messages-en.properties‎

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -437,7 +437,7 @@ configuration.sms = SMS
437437
configuration.sms.forms = SMS forms
438438
configuration.sms.forms.title = You need to choose both an XML file and a Meta file before clicking the upload button. You may only upload one app form file at a time and any existing forms will be overwritten.
439439
configuration.sms.settings = Basic settings
440-
configuration.sms.test.description = Use this page to send a test message to the production application without going through the SMS Gateway. Be sure to use a phone number registered to a CHW’s profile to mimic a report coming from him or her about a particular patient.
440+
configuration.sms.test.description = Use this page to send a test message to the production application without going through the SMS Gateway. Be sure to use a phone number registered to a CHW?s profile to mimic a report coming from him or her about a particular patient.
441441
configuration.sms.test.from.number = From phone number
442442
configuration.sms.test.message.description = Limit of 144 characters
443443
configuration.sms.test.number.validation.description = Please enter a valid phone number without dashes or punctuation.
@@ -454,7 +454,7 @@ confirm.destructive.navigation.submit = Exit
454454
confirm.destructive.navigation.title = Exit form?
455455
confirm.logout = You will need an internet connection to log back in.
456456
password.updated = Your password has been successfully updated.
457-
confirm.verification = This report will be verified as “correct”. This cannot be changed later.
457+
confirm.verification = This report will be verified as ?correct?. This cannot be changed later.
458458
confirm.verification.submit = Verify as correct
459459
confirm.verification.title = Verify report
460460
contact.age = Age
@@ -654,8 +654,8 @@ enketo.geopicker.altitude = altitude (m)
654654
enketo.geopicker.closepolygon = close polygon
655655
enketo.geopicker.kmlcoords = KML coordinates
656656
enketo.geopicker.kmlpaste = paste KML coordinates here
657-
enketo.geopicker.latitude = latitude (x.y °)
658-
enketo.geopicker.longitude = longitude (x.y °)
657+
enketo.geopicker.latitude = latitude (x.y °)
658+
enketo.geopicker.longitude = longitude (x.y °)
659659
enketo.geopicker.points = points
660660
enketo.geopicker.searchPlaceholder = search for place or address
661661
enketo.geopicker.removePoint = This will completely remove the current geopoint from the list of geopoints and cannot be undone. Are you sure you want to do this?
@@ -686,7 +686,7 @@ export.dhis.place.all = All Places
686686
export.dhis.place.description = Filter exported data to include data associated with contacts under this place in the hierarchy.
687687
export.dhis.place.label = Filter by place
688688
export.dhis.unconfigured = DHIS2 integration is not configured.
689-
export.feedback.description = Download a log of detected errors and user feedback submitted via the “Report bug” feature in CSV format. The table below shows the most recently submitted reports.
689+
export.feedback.description = Download a log of detected errors and user feedback submitted via the ?Report bug? feature in CSV format. The table below shows the most recently submitted reports.
690690
export.messages.description = Download all messages that have ever been sent or received in CSV format.
691691
export.people.description = Download all contacts registered in the system in JSON format.
692692
export.reports.description = Download a summary of all the reports that have ever been submitted in CSV format.
@@ -1215,7 +1215,7 @@ sync.last_success = Last sync
12151215
sync.now = Sync now
12161216
sync.retry = Retry
12171217
sync.feedback.failure.unknown = Sync failed. Unable to connect.
1218-
sync.status.in_progress = Currently syncing…
1218+
sync.status.in_progress = Currently syncing?
12191219
sync.status.not_required = All reports synced
12201220
sync.status.required = Reports to sync
12211221
sync.status.unknown = Unable to connect
@@ -1264,7 +1264,10 @@ training_cards.confirm.title = Leave training?
12641264
training_cards.error.loading = Error loading training. Please contact your supervisor.
12651265
training_cards.error.save = Error saving training.
12661266
training_cards.form.saved = Training completed.
1267-
training_cards.modal.title = Important changes
1267+
training_materials.page.no_more_trainings = No more trainings
1268+
training_materials.page.no_selected = No training material selected
1269+
training_materials.page.no_trainings = No trainings found
1270+
training_materials.page.title = Training materials
12681271
translation.add = Add new translation key
12691272
translation.key = Translation key
12701273
unique.id = Unique ID

‎api/resources/translations/messages-es.properties‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1264,7 +1264,10 @@ training_cards.confirm.title = \¿Salir del entrenamiento\?
12641264
training_cards.error.loading = Hubo un error al cargar el entrenamiento. Por favor contacte a su supervisor.
12651265
training_cards.error.save = Hubo un error al guardar el entrenamiento.
12661266
training_cards.form.saved = Entrenamiento completado.
1267-
training_cards.modal.title = Cambios importantes
1267+
training_materials.page.no_more_trainings = No hay más entrenamientos
1268+
training_materials.page.no_selected = Ningún material de entrenamiento seleccionado
1269+
training_materials.page.no_trainings = No se encontraron entrenamientos
1270+
training_materials.page.title = Materiales de entrenamiento
12681271
translation.add = Agregar Traducción
12691272
translation.key = Clave de traducción
12701273
unique.id = Identificación única

‎api/resources/translations/messages-fr.properties‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1264,7 +1264,10 @@ training_cards.confirm.title = Quitter l'entraînement?
12641264
training_cards.error.loading = Erreur lors du chargement de la formation. Veuillez contacter votre superviseur.
12651265
training_cards.error.save = Erreur lors de l'enregistrement de la formation.
12661266
training_cards.form.saved = Formation terminée.
1267-
training_cards.modal.title = Changements importants
1267+
training_materials.page.no_more_trainings = Aucune formation restante
1268+
training_materials.page.no_selected = Aucun matériel de formation sélectionné
1269+
training_materials.page.no_trainings = Aucune formation trouvée
1270+
training_materials.page.title = Matériel de formation
12681271
translation.add = Ajouter une traduction
12691272
translation.key = Clé de traduction
12701273
unique.id = ID unique

‎api/resources/translations/messages-hi.properties‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1168,6 +1168,10 @@ training_cards.confirm.exit = यह प्रशिक्षण समाप्
11681168
training_cards.confirm.button.no = रद्द करें
11691169
training_cards.confirm.button.yes = बाहर निकलें
11701170
training_cards.confirm.title = प्रशिक्षण छोड़ें?
1171+
training_materials.page.no_more_trainings = अब और कोई प्रशिक्षण नहीं है
1172+
training_materials.page.no_selected = कोई प्रशिक्षण दस्तावेज़ नहीं चुना गया
1173+
training_materials.page.no_trainings = कोई प्रशिक्षण नहीं मिला
1174+
training_materials.page.title = प्रशिक्षण दस्तावेज़
11711175
translation.add = अनुवाद दर्ज करें
11721176
translation.key = अनुवाद का गाइड
11731177
unique.id =

‎api/resources/translations/messages-id.properties‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1175,6 +1175,10 @@ training_cards.confirm.exit = Pelatihan ini belum selesai. Jika Anda keluar seka
11751175
training_cards.confirm.button.no = Batalkan
11761176
training_cards.confirm.button.yes = Keluar
11771177
training_cards.confirm.title = Keluar dari pelatihan?
1178+
training_materials.page.no_more_trainings = Tidak ada lagi pelatihan
1179+
training_materials.page.no_selected = Tidak ada materi pelatihan yang dipilih
1180+
training_materials.page.no_trainings = Tidak ditemukan pelatihan
1181+
training_materials.page.title = Materi pelatihan
11781182
translation.add = Tambah terjemahan
11791183
translation.key = Kunci terjemahan
11801184
unique.id =

‎api/resources/translations/messages-ne.properties‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1264,7 +1264,10 @@ training_cards.confirm.title = तालिम छोड्ने हो?
12641264
training_cards.error.loading = तालिम लोड गर्दा त्रुटि भयो। तपाइँको सुपरभाइजरलाई सम्पर्क गर्नुहोस्।
12651265
training_cards.error.save = तालिम सेभ गर्न त्रुटि।
12661266
training_cards.form.saved = तालिम सम्पन्न भयो।
1267-
training_cards.modal.title = महत्वपुर्ण परिवर्तनहरु
1267+
training_materials.page.no_more_trainings = थप तालिम छैन
1268+
training_materials.page.no_selected = कुनै तालिम सामग्री छनोट गरिएको छैन।
1269+
training_materials.page.no_trainings = तालिम फेला परेन
1270+
training_materials.page.title = तालिम शीर्षक
12681271
translation.add = नयाँ अनुवाद कुञ्जी थप्नुहोस्
12691272
translation.key = अनुवाद कुञ्जी
12701273
unique.id = आईडी

‎api/resources/translations/messages-sw.properties‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1264,7 +1264,10 @@ training_cards.confirm.title = Ungependa kuondoka kwenye mafunzo?
12641264
training_cards.error.loading = Hitilafu katika kupakia mafunzo. Tafadhali wasiliana na msimamizi wako.
12651265
training_cards.error.save = Hitilafu katika kuhifadhi mafunzo.
12661266
training_cards.form.saved = Mafunzo yamekamilika.
1267-
training_cards.modal.title = Mabadiliko muhimu
1267+
training_materials.page.no_more_trainings = Hakuna mafunzo mengine
1268+
training_materials.page.no_selected = Hakuna nyenzo za mafunzo zilizochaguliwa
1269+
training_materials.page.no_trainings = Hakuna mafunzo yaliyopatikana
1270+
training_materials.page.title = Vifaa vya mafunzo
12681271
translation.add = Ongeza tafsiri
12691272
translation.key = Ufunguo wa tafsiri
12701273
unique.id = Kitambulisho cha kipekee

‎tests/e2e/default/enketo/training-cards.wdio-spec.js‎

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ const commonPage = require('@page-objects/default/common/common.wdio.page');
44
const trainingCardsPage = require('@page-objects/default/enketo/training-cards.wdio.page');
55
const placeFactory = require('@factories/cht/contacts/place');
66
const userFactory = require('@factories/cht/users/users');
7-
const personFactory = require('@factories/cht/contacts/person');
87
const reportsPage = require('@page-objects/default/reports/reports.wdio.page');
98
const privacyPolicyFactory = require('@factories/cht/settings/privacy-policy');
109
const privacyPage = require('@page-objects/default/privacy-policy/privacy-policy.wdio.page');
@@ -26,7 +25,6 @@ describe('Training Cards', () => {
2625
before(async () => {
2726
const parent = placeFactory.place().build({ _id: 'dist1', type: 'district_hospital' });
2827
const user = userFactory.build({ roles: [ 'nurse', 'chw' ] });
29-
const patient = personFactory.build({ parent: { _id: user.place._id, parent: { _id: parent._id } } });
3028
const formDoc = commonPage.createFormDoc(`${__dirname}/forms/training-cards-text-only`);
3129
formDoc._id = `form:${formDocId}`;
3230
formDoc.internalId = formDocId;
@@ -36,8 +34,7 @@ describe('Training Cards', () => {
3634
duration: 5,
3735
};
3836

39-
await utils.saveDocs([ parent, patient ]);
40-
await utils.saveDoc(formDoc);
37+
await utils.saveDocs([ parent, formDoc ]);
4138
await utils.createUsers([ user ]);
4239
await loginPage.login(user);
4340
await commonPage.waitForPageLoaded();

‎tests/e2e/default/service-worker/service-worker.wdio-spec.js‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,7 @@ describe('Service worker cache', () => {
120120
'/img/icon-pregnant-selected.svg',
121121
'/img/icon-pregnant.svg',
122122
'/img/icon-filter.svg',
123+
'/img/icon-check.svg',
123124
'/img/icon.png',
124125
'/img/icon-back.svg',
125126
'/img/layers.png',

‎tests/e2e/default/suites.js‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ const SUITES = {
66
'./more-options-menu/**/*.wdio-spec.js',
77
'./users/**/*.wdio-spec.js',
88
'./about/**/*.wdio-spec.js',
9+
'./training-materials/**/*.wdio-spec.js',
910
'./navigation/**/*.wdio-spec.js',
1011
'./old-navigation/**/*.wdio-spec.js',
1112
'./privacy-policy/**/*.wdio-spec.js',

0 commit comments

Comments
 (0)