@kenyaemr/esm-appointments-app 8.1.1-pre.124 → 8.1.2-pre.152

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (119) hide show
  1. package/.turbo/turbo-build.log +27 -25
  2. package/dist/111.js +2 -0
  3. package/dist/111.js.map +1 -0
  4. package/dist/123.js +2 -0
  5. package/dist/{198.js.LICENSE.txt → 123.js.LICENSE.txt} +0 -6
  6. package/dist/123.js.map +1 -0
  7. package/dist/130.js +1 -1
  8. package/dist/130.js.map +1 -1
  9. package/dist/{385.js → 139.js} +1 -1
  10. package/dist/139.js.map +1 -0
  11. package/dist/228.js +1 -0
  12. package/dist/236.js +1 -0
  13. package/dist/240.js +1 -0
  14. package/dist/261.js +1 -0
  15. package/dist/269.js +1 -1
  16. package/dist/269.js.map +1 -1
  17. package/dist/271.js +1 -1
  18. package/dist/272.js +1 -0
  19. package/dist/319.js +1 -1
  20. package/dist/336.js +1 -0
  21. package/dist/378.js +1 -0
  22. package/dist/443.js +1 -0
  23. package/dist/443.js.map +1 -0
  24. package/dist/460.js +1 -1
  25. package/dist/529.js +1 -1
  26. package/dist/529.js.map +1 -1
  27. package/dist/539.js +1 -0
  28. package/dist/566.js +1 -0
  29. package/dist/574.js +1 -1
  30. package/dist/581.js +1 -1
  31. package/dist/644.js +1 -1
  32. package/dist/652.js +1 -0
  33. package/dist/673.js +1 -0
  34. package/dist/705.js +1 -0
  35. package/dist/711.js +1 -1
  36. package/dist/711.js.map +1 -1
  37. package/dist/727.js +1 -0
  38. package/dist/737.js +1 -0
  39. package/dist/744.js +1 -0
  40. package/dist/757.js +1 -1
  41. package/dist/788.js +1 -1
  42. package/dist/807.js +1 -1
  43. package/dist/833.js +1 -1
  44. package/dist/899.js +1 -0
  45. package/dist/923.js +1 -0
  46. package/dist/923.js.map +1 -0
  47. package/dist/kenyaemr-esm-appointments-app.js +1 -1
  48. package/dist/kenyaemr-esm-appointments-app.js.buildmanifest.json +448 -96
  49. package/dist/kenyaemr-esm-appointments-app.js.map +1 -1
  50. package/dist/main.js +1 -1
  51. package/dist/main.js.map +1 -1
  52. package/dist/routes.json +1 -1
  53. package/package-lock.json +6416 -0
  54. package/package.json +5 -5
  55. package/src/appointments/appointment-tabs.component.tsx +1 -1
  56. package/src/appointments/common-components/appointments-table.component.tsx +0 -1
  57. package/src/appointments/common-components/appointments-table.test.tsx +7 -3
  58. package/src/appointments/common-components/checkin-button.component.tsx +5 -1
  59. package/src/appointments/common-components/end-appointment.modal.tsx +2 -2
  60. package/src/appointments/scheduled/scheduled-appointments.component.tsx +1 -1
  61. package/src/appointments/unscheduled/unscheduled-appointments.component.tsx +6 -6
  62. package/src/appointments/unscheduled/unscheduled-appointments.test.tsx +19 -4
  63. package/src/appointments.component.tsx +7 -7
  64. package/src/appointments.test.tsx +11 -1
  65. package/src/calendar/appointments-calendar-view.component.tsx +2 -2
  66. package/src/calendar/monthly/monthly-workload-view.component.tsx +7 -7
  67. package/src/config-schema.ts +6 -70
  68. package/src/form/appointments-form.component.tsx +84 -73
  69. package/src/form/appointments-form.resource.ts +4 -4
  70. package/src/form/appointments-form.scss +1 -1
  71. package/src/form/appointments-form.test.tsx +142 -110
  72. package/src/patient-appointments/patient-appointments-action-menu.component.tsx +2 -4
  73. package/src/patient-appointments/patient-appointments-base.test.tsx +1 -1
  74. package/src/patient-appointments/patient-appointments-cancel.modal.tsx +6 -1
  75. package/src/patient-appointments/patient-appointments-cancel.scss +29 -0
  76. package/src/patient-appointments/patient-upcoming-appointments-card.component.tsx +64 -8
  77. package/src/routes.json +1 -1
  78. package/src/types/index.ts +1 -1
  79. package/src/workload/monthly-view-workload/monthly-view.component.tsx +8 -6
  80. package/src/workload/monthly-view-workload/monthlyWorkCard.tsx +3 -2
  81. package/src/workload/workload-card.component.tsx +5 -3
  82. package/src/workload/workload.component.tsx +13 -20
  83. package/src/workload/workload.resource.ts +3 -0
  84. package/translations/am.json +4 -2
  85. package/translations/ar.json +24 -22
  86. package/translations/de.json +168 -0
  87. package/translations/en.json +3 -1
  88. package/translations/es.json +58 -56
  89. package/translations/fr.json +4 -2
  90. package/translations/he.json +93 -91
  91. package/translations/hi.json +168 -0
  92. package/translations/hi_IN.json +168 -0
  93. package/translations/id.json +168 -0
  94. package/translations/it.json +168 -0
  95. package/translations/km.json +4 -2
  96. package/translations/ne.json +168 -0
  97. package/translations/pt.json +168 -0
  98. package/translations/pt_BR.json +168 -0
  99. package/translations/qu.json +168 -0
  100. package/translations/si.json +168 -0
  101. package/translations/sw.json +168 -0
  102. package/translations/sw_KE.json +168 -0
  103. package/translations/tr.json +168 -0
  104. package/translations/tr_TR.json +168 -0
  105. package/translations/uk.json +168 -0
  106. package/translations/vi.json +168 -0
  107. package/translations/zh.json +4 -2
  108. package/translations/zh_CN.json +4 -2
  109. package/dist/198.js +0 -2
  110. package/dist/198.js.map +0 -1
  111. package/dist/265.js +0 -1
  112. package/dist/265.js.map +0 -1
  113. package/dist/385.js.map +0 -1
  114. package/dist/440.js +0 -2
  115. package/dist/440.js.map +0 -1
  116. package/dist/501.js +0 -1
  117. package/dist/501.js.map +0 -1
  118. package/src/hooks/useDefaultLocation.ts +0 -14
  119. /package/dist/{440.js.LICENSE.txt → 111.js.LICENSE.txt} +0 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kenyaemr/esm-appointments-app",
3
- "version": "8.1.1-pre.124",
3
+ "version": "8.1.2-pre.152",
4
4
  "description": "Appointments front-end module for the OpenMRS SPA",
5
5
  "browser": "dist/kenyaemr-esm-appointments-app.js",
6
6
  "main": "src/index.ts",
@@ -37,14 +37,14 @@
37
37
  "url": "https://github.com/openmrs/openmrs-esm-patient-management/issues"
38
38
  },
39
39
  "dependencies": {
40
- "@carbon/react": "~1.37.0",
40
+ "@carbon/react": "^1.71.0",
41
41
  "formik": "^2.2.9",
42
42
  "lodash-es": "^4.17.15",
43
43
  "yup": "^0.32.11"
44
44
  },
45
45
  "peerDependencies": {
46
- "@openmrs/esm-framework": "5.x",
47
- "@openmrs/esm-patient-common-lib": "8.x",
46
+ "@openmrs/esm-framework": "6.x",
47
+ "@openmrs/esm-patient-common-lib": "9.x",
48
48
  "react": "18.x",
49
49
  "react-i18next": "11.x",
50
50
  "react-router-dom": "6.x",
@@ -53,5 +53,5 @@
53
53
  "devDependencies": {
54
54
  "webpack": "^5.74.0"
55
55
  },
56
- "stableVersion": "8.1.0"
56
+ "stableVersion": "8.0.2"
57
57
  }
@@ -13,8 +13,8 @@ interface AppointmentTabsProps {
13
13
 
14
14
  const AppointmentTabs: React.FC<AppointmentTabsProps> = ({ appointmentServiceType }) => {
15
15
  const { t } = useTranslation();
16
- const [activeTabIndex, setActiveTabIndex] = useState<number>(0);
17
16
  const { showUnscheduledAppointmentsTab } = useConfig<ConfigObject>();
17
+ const [activeTabIndex, setActiveTabIndex] = useState(0);
18
18
 
19
19
  const handleTabChange = ({ selectedIndex }: { selectedIndex: number }) => {
20
20
  setActiveTabIndex(selectedIndex);
@@ -44,7 +44,6 @@ import { type ConfigObject } from '../../config-schema';
44
44
  import { getPageSizes, useAppointmentSearchResults } from '../utils';
45
45
  import AppointmentActions from './appointments-actions.component';
46
46
  import AppointmentDetails from '../details/appointment-details.component';
47
- import PatientSearch from '../../patient-search/patient-search.component';
48
47
  import styles from './appointments-table.scss';
49
48
 
50
49
  dayjs.extend(utc);
@@ -62,11 +62,15 @@ const mockAppointments = [
62
62
  },
63
63
  ] as unknown as Array<Appointment>;
64
64
 
65
- const mockExportAppointmentsToSpreadsheet = jest.mocked(exportAppointmentsToSpreadsheet);
66
65
  const mockUseConfig = jest.mocked(useConfig<ConfigObject>);
66
+ const mockExportAppointmentsToSpreadsheet = jest.mocked(exportAppointmentsToSpreadsheet);
67
67
 
68
- jest.mock('../../helpers/excel');
69
- jest.mock('../../hooks/useOverlay');
68
+ jest.mock('../../helpers/excel', () => {
69
+ return {
70
+ ...jest.requireActual('../../helpers/excel'),
71
+ exportAppointmentsToSpreadsheet: jest.fn(),
72
+ };
73
+ });
70
74
 
71
75
  describe('AppointmentsTable', () => {
72
76
  beforeEach(() => {
@@ -31,7 +31,11 @@ const CheckInButton: React.FC<CheckInButtonProps> = ({ appointment, patientUuid
31
31
  to: checkInButton.customUrl,
32
32
  templateParams: { patientUuid: appointment.patient.uuid, appointmentUuid: appointment.uuid },
33
33
  })
34
- : launchWorkspace('start-visit-workspace-form', { patientUuid: patientUuid, showPatientHeader: true })
34
+ : launchWorkspace('start-visit-workspace-form', {
35
+ patientUuid: patientUuid,
36
+ showPatientHeader: true,
37
+ openedFrom: 'appointments-check-in',
38
+ })
35
39
  }>
36
40
  {t('checkIn', 'Check in')}
37
41
  </Button>
@@ -1,7 +1,7 @@
1
1
  import React, { useCallback } from 'react';
2
2
  import { useTranslation } from 'react-i18next';
3
- import { showSnackbar, updateVisit, useVisit } from '@openmrs/esm-framework';
4
3
  import { Button, ModalBody, ModalFooter, ModalHeader } from '@carbon/react';
4
+ import { showSnackbar, updateVisit, useVisit } from '@openmrs/esm-framework';
5
5
  import { changeAppointmentStatus } from '../../patient-appointments/patient-appointments.resource';
6
6
  import { useMutateAppointments } from '../../form/appointments-form.resource';
7
7
 
@@ -68,7 +68,7 @@ const EndAppointmentModal: React.FC<EndAppointmentModalProps> = ({ patientUuid,
68
68
  .finally(() => {
69
69
  closeModal();
70
70
  });
71
- }, [activeVisit, mutate, mutateAppointments, closeModal, patientUuid, appointmentUuid]);
71
+ }, [activeVisit, appointmentUuid, closeModal, mutate, mutateAppointments, t]);
72
72
 
73
73
  return (
74
74
  <div>
@@ -35,7 +35,7 @@ const ScheduledAppointments: React.FC<ScheduledAppointmentsProps> = ({ appointme
35
35
  // t('checkedIn', 'Checked in');
36
36
  // t('expected', 'Expected');
37
37
 
38
- const [currentTab, setCurrentTab] = useState<string>(null);
38
+ const [currentTab, setCurrentTab] = useState(null);
39
39
  const [dateType, setDateType] = useState<DateType>('today');
40
40
  const scheduledAppointmentPanels = useConnectedExtensions(scheduledAppointmentsPanelsSlot);
41
41
  const { allowedExtensions, showExtension, hideExtension } = useAllowedExtensions();
@@ -1,20 +1,20 @@
1
1
  import React, { useState } from 'react';
2
2
  import { useTranslation } from 'react-i18next';
3
3
  import {
4
+ Button,
4
5
  DataTable,
5
- TableContainer,
6
+ DataTableSkeleton,
7
+ Pagination,
6
8
  Table,
9
+ TableBody,
10
+ TableCell,
11
+ TableContainer,
7
12
  TableHead,
8
13
  TableHeader,
9
14
  TableRow,
10
- TableBody,
11
- TableCell,
12
15
  TableToolbar,
13
16
  TableToolbarContent,
14
17
  TableToolbarSearch,
15
- Pagination,
16
- DataTableSkeleton,
17
- Button,
18
18
  } from '@carbon/react';
19
19
  import { Download } from '@carbon/react/icons';
20
20
  import { ConfigurableLink, useConfig, usePagination } from '@openmrs/esm-framework';
@@ -3,18 +3,28 @@ import userEvent from '@testing-library/user-event';
3
3
  import { render, screen } from '@testing-library/react';
4
4
  import { getDefaultsFromConfigSchema, useConfig } from '@openmrs/esm-framework';
5
5
  import { type ConfigObject, configSchema } from '../../config-schema';
6
+ import { exportUnscheduledAppointmentsToSpreadsheet } from '../../helpers/excel';
6
7
  import { getByTextWithMarkup } from 'tools';
7
8
  import { useUnscheduledAppointments } from '../../hooks/useUnscheduledAppointments';
8
- import { exportUnscheduledAppointmentsToSpreadsheet } from '../../helpers/excel';
9
9
  import UnscheduledAppointments from './unscheduled-appointments.component';
10
10
 
11
11
  const mockExportUnscheduledAppointmentsToSpreadsheet = jest.mocked(exportUnscheduledAppointmentsToSpreadsheet);
12
12
  const mockUseUnscheduledAppointments = jest.mocked(useUnscheduledAppointments);
13
13
  const mockUseConfig = jest.mocked(useConfig<ConfigObject>);
14
14
 
15
- jest.mock('../../helpers/excel');
16
- jest.mock('../../hooks/useOverlay');
17
- jest.mock('../../hooks/useUnscheduledAppointments');
15
+ jest.mock('../../helpers/excel', () => {
16
+ return {
17
+ ...jest.requireActual('../../helpers/excel'),
18
+ exportUnscheduledAppointmentsToSpreadsheet: jest.fn(),
19
+ };
20
+ });
21
+
22
+ jest.mock('../../hooks/useUnscheduledAppointments', () => {
23
+ return {
24
+ ...jest.requireActual('../../hooks/useUnscheduledAppointments'),
25
+ useUnscheduledAppointments: jest.fn(),
26
+ };
27
+ });
18
28
 
19
29
  const mockUnscheduledAppointments = [
20
30
  {
@@ -45,6 +55,11 @@ describe('UnscheduledAppointments', () => {
45
55
  ...getDefaultsFromConfigSchema(configSchema),
46
56
  customPatientChartUrl: 'someUrl',
47
57
  });
58
+ mockUseUnscheduledAppointments.mockReturnValue({
59
+ isLoading: false,
60
+ data: mockUnscheduledAppointments,
61
+ error: null,
62
+ });
48
63
  });
49
64
 
50
65
  it('renders the component correctly', async () => {
@@ -1,19 +1,19 @@
1
1
  import React, { useEffect, useState } from 'react';
2
- import { useTranslation } from 'react-i18next';
3
2
  import dayjs from 'dayjs';
3
+ import { useTranslation } from 'react-i18next';
4
+ import { useParams } from 'react-router-dom';
5
+ import { omrsDateFormat } from './constants';
4
6
  import AppointmentTabs from './appointments/appointment-tabs.component';
5
7
  import AppointmentsHeader from './header/appointments-header.component';
6
8
  import AppointmentMetrics from './metrics/appointments-metrics.component';
7
- import { useParams } from 'react-router-dom';
8
9
  import SelectedDateContext from './hooks/selectedDateContext';
9
- import { omrsDateFormat } from './constants';
10
10
 
11
11
  const Appointments: React.FC = () => {
12
12
  const { t } = useTranslation();
13
- const [appointmentServiceType, setAppointmentServiceType] = useState<string>('');
14
- const [selectedDate, setSelectedDate] = useState<string>(dayjs().startOf('day').format(omrsDateFormat));
13
+ const [appointmentServiceType, setAppointmentServiceType] = useState('');
14
+ const [selectedDate, setSelectedDate] = useState(dayjs().startOf('day').format(omrsDateFormat));
15
15
 
16
- let params = useParams();
16
+ const params = useParams();
17
17
 
18
18
  useEffect(() => {
19
19
  if (params.date) {
@@ -30,9 +30,9 @@ const Appointments: React.FC = () => {
30
30
  return (
31
31
  <SelectedDateContext.Provider value={{ selectedDate, setSelectedDate }}>
32
32
  <AppointmentsHeader
33
- title={t('appointments', 'Appointments')}
34
33
  appointmentServiceType={appointmentServiceType}
35
34
  onChange={setAppointmentServiceType}
35
+ title={t('appointments', 'Appointments')}
36
36
  />
37
37
  <AppointmentMetrics appointmentServiceType={appointmentServiceType} />
38
38
  <AppointmentTabs appointmentServiceType={appointmentServiceType} />
@@ -2,14 +2,24 @@ import React from 'react';
2
2
  import { render, screen } from '@testing-library/react';
3
3
  import Appointments from './appointments.component';
4
4
 
5
+ // TODO: Tweak the ExtensionSlot stub in the framework to not return a function. Functions are not valid React children.
5
6
  describe('Appointments', () => {
6
7
  it('renders the appointments dashboard', async () => {
7
8
  render(<Appointments />);
8
9
 
9
10
  await screen.findByText(/^appointments$/i);
11
+
10
12
  expect(screen.getByRole('button', { name: /appointments calendar/i })).toBeInTheDocument();
11
13
  expect(screen.getByPlaceholderText(/dd-mmm-yyyy/i)).toBeInTheDocument();
12
- expect(screen.getByRole('combobox', { name: /view/i })).toBeInTheDocument();
14
+ expect(
15
+ screen.getByRole('combobox', {
16
+ name: /select service type/i,
17
+ }),
18
+ ).toBeInTheDocument();
19
+ expect(screen.getByRole('listbox', { name: /view/i })).toBeInTheDocument();
13
20
  expect(screen.getByText(/appointment metrics/i)).toBeInTheDocument();
21
+ expect(screen.getByText(/scheduled appointments/i)).toBeInTheDocument();
22
+ expect(screen.getByText(/highest volume service/i)).toBeInTheDocument();
23
+ expect(screen.getByText(/providers booked/i)).toBeInTheDocument();
14
24
  });
15
25
  });
@@ -2,16 +2,16 @@ import React, { useEffect, useState } from 'react';
2
2
  import dayjs from 'dayjs';
3
3
  import { useParams } from 'react-router-dom';
4
4
  import { useTranslation } from 'react-i18next';
5
+ import { omrsDateFormat } from '../constants';
5
6
  import { useAppointmentsCalendar } from '../hooks/useAppointmentsCalendar';
6
7
  import AppointmentsHeader from '../header/appointments-header.component';
7
8
  import CalendarHeader from './header/calendar-header.component';
8
9
  import MonthlyCalendarView from './monthly/monthly-calendar-view.component';
9
10
  import SelectedDateContext from '../hooks/selectedDateContext';
10
- import { omrsDateFormat } from '../constants';
11
11
 
12
12
  const AppointmentsCalendarView: React.FC = () => {
13
13
  const { t } = useTranslation();
14
- const [selectedDate, setSelectedDate] = useState<string>(dayjs().startOf('day').format(omrsDateFormat));
14
+ const [selectedDate, setSelectedDate] = useState(dayjs().startOf('day').format(omrsDateFormat));
15
15
  const { calendarEvents } = useAppointmentsCalendar(dayjs(selectedDate).toISOString(), 'monthly');
16
16
 
17
17
  let params = useParams();
@@ -25,7 +25,7 @@ const MonthlyWorkloadView: React.FC<MonthlyWorkloadViewProps> = ({ dateTime, eve
25
25
  events?.find(
26
26
  (event) => dayjs(event.appointmentDate)?.format('YYYY-MM-DD') === dayjs(dateTime)?.format('YYYY-MM-DD'),
27
27
  ),
28
- [events],
28
+ [dateTime, events],
29
29
  );
30
30
 
31
31
  const visibleServices = useMemo(() => {
@@ -34,7 +34,7 @@ const MonthlyWorkloadView: React.FC<MonthlyWorkloadViewProps> = ({ dateTime, eve
34
34
  return currentData.services.slice(0, layout === 'small-desktop' ? 2 : 4);
35
35
  }
36
36
  return [];
37
- }, [currentData, showAllServices, layout, currentData]);
37
+ }, [currentData, showAllServices, layout]);
38
38
 
39
39
  const hasHiddenServices = useMemo(() => {
40
40
  if (currentData?.services) {
@@ -42,7 +42,7 @@ const MonthlyWorkloadView: React.FC<MonthlyWorkloadViewProps> = ({ dateTime, eve
42
42
  return layout === 'small-desktop' ? currentData.services.length > 2 : currentData.services.length > 4;
43
43
  }
44
44
  return false;
45
- }, [layout, currentData, currentData]);
45
+ }, [currentData?.services, layout, showAllServices]);
46
46
 
47
47
  const navigateToAppointmentsByDate = (serviceUuid: string) => {
48
48
  navigate({ to: `${spaHomePage}/appointments/${dayjs(dateTime).format('YYYY-MM-DD')}/${serviceUuid}` });
@@ -61,8 +61,8 @@ const MonthlyWorkloadView: React.FC<MonthlyWorkloadViewProps> = ({ dateTime, eve
61
61
  },
62
62
  )}>
63
63
  {isSameMonth(dateTime, dayjs(selectedDate)) && (
64
- <p>
65
- <div className={classNames(styles.totals)}>
64
+ <div>
65
+ <span className={classNames(styles.totals)}>
66
66
  {currentData?.services ? (
67
67
  <div role="button" tabIndex={0}>
68
68
  <User size={16} />
@@ -72,7 +72,7 @@ const MonthlyWorkloadView: React.FC<MonthlyWorkloadViewProps> = ({ dateTime, eve
72
72
  <div />
73
73
  )}
74
74
  <b className={styles.calendarDate}>{dateTime.format('D')}</b>
75
- </div>
75
+ </span>
76
76
  {currentData?.services && (
77
77
  <div className={styles.currentData}>
78
78
  {visibleServices.map(({ serviceName, serviceUuid, count }, i) => (
@@ -100,7 +100,7 @@ const MonthlyWorkloadView: React.FC<MonthlyWorkloadViewProps> = ({ dateTime, eve
100
100
  )}
101
101
  </div>
102
102
  )}
103
- </p>
103
+ </div>
104
104
  )}
105
105
  </div>
106
106
  );
@@ -1,22 +1,11 @@
1
- import { Type, restBaseUrl, validators } from '@openmrs/esm-framework';
2
- import { spaHomePage } from './constants';
1
+ import { Type, validators } from '@openmrs/esm-framework';
3
2
 
4
3
  export const configSchema = {
5
- includePhoneNumberInExcelSpreadsheet: {
6
- _type: Type.Boolean,
7
- _description: 'Whether to include phone numbers in the exported Excel spreadsheet',
8
- _default: false,
9
- },
10
4
  allowAllDayAppointments: {
11
5
  _type: Type.Boolean,
12
6
  _description: 'Whether to allow scheduling of all-day appointments (vs appointments with start time and end time)',
13
7
  _default: false,
14
8
  },
15
- appointmentsBaseUrl: {
16
- _type: Type.String,
17
- _description: 'Configurable alternative URL for the Appointments UI. Eg, the Bahmni Appointments UI URL',
18
- _default: `${spaHomePage}`,
19
- },
20
9
  appointmentStatuses: {
21
10
  _type: Type.Array,
22
11
  _description: 'Configurable appointment status (status of appointments)',
@@ -27,11 +16,6 @@ export const configSchema = {
27
16
  _description: 'Configurable appointment types (types of appointments)',
28
17
  _default: ['Scheduled'],
29
18
  },
30
- bahmniAppointmentsUiBaseUrl: {
31
- _type: Type.String,
32
- _description: 'Configurable base URL that points to the Bahmni Appointments UI',
33
- _default: '/appointments',
34
- },
35
19
  checkInButton: {
36
20
  enabled: {
37
21
  _type: Type.Boolean,
@@ -61,13 +45,6 @@ export const configSchema = {
61
45
  _default: '',
62
46
  },
63
47
  },
64
- concepts: {
65
- visitQueueNumberAttributeUuid: {
66
- _type: Type.String,
67
- _description: 'The UUID of the visit attribute that contains the visit queue number.',
68
- _default: 'c61ce16f-272a-41e7-9924-4c555d0932c5',
69
- },
70
- },
71
48
  customPatientChartUrl: {
72
49
  _type: Type.String,
73
50
  _description: `Template URL that will be used when clicking on the patient name in the queues table.
@@ -76,57 +53,26 @@ export const configSchema = {
76
53
  _default: '${openmrsSpaBase}/patient/${patientUuid}/chart',
77
54
  _validators: [validators.isUrlWithTemplateParameters(['patientUuid'])],
78
55
  },
79
- daysOfTheWeek: {
80
- _type: Type.Array,
81
- _description: 'Configurable days of the week',
82
- _default: ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'],
83
- },
84
- defaultFacilityUrl: {
85
- _type: Type.String,
86
- _default: `${restBaseUrl}/kenyaemr/default-facility`,
87
- _description: 'Custom URL to load default facility if it is not in the session',
88
- },
89
- fullViewPrivilege: {
90
- _type: Type.String,
91
- _description: 'Name of the privilege to display the full view of the Appointments dashboard widget.',
92
- _default: "Today's Appointments Widget: Display Full View",
93
- },
94
- hiddenFormFields: {
95
- _type: Type.Array,
96
- _description: 'Array of form controls to be hidden on form load',
97
- _default: [],
56
+ includePhoneNumberInExcelSpreadsheet: {
57
+ _type: Type.Boolean,
58
+ _description: 'Whether to include phone numbers in the exported Excel spreadsheet',
59
+ _default: false,
98
60
  },
99
61
  patientIdentifierType: {
100
62
  _type: Type.String,
101
63
  _description: 'The name of the patient identifier type to be used for the patient identifier field',
102
64
  _default: '',
103
65
  },
104
- showServiceQueueFields: {
105
- _type: Type.Boolean,
106
- _description: 'Whether start visit form should display service queue fields`',
107
- _default: false,
108
- },
109
66
  showUnscheduledAppointmentsTab: {
110
67
  _type: Type.Boolean,
111
68
  _description:
112
69
  'Whether to show the Unscheduled Appointments tab. Note that configuring this to true requires a custom unscheduledAppointment endpoint not currently available',
113
70
  _default: false,
114
71
  },
115
- useBahmniAppointmentsUI: {
116
- _type: Type.Boolean,
117
- _description: 'Open links in Bahmni Appointments UI instead of O3 UI',
118
- _default: false,
119
- },
120
- useFullViewPrivilege: {
121
- _type: Type.Boolean,
122
- _description: "If set to 'false', will always display the full view, disregarding any privilege",
123
- _default: false,
124
- },
125
72
  };
126
73
 
127
74
  export interface ConfigObject {
128
75
  allowAllDayAppointments: boolean;
129
- appointmentComments: Array<string>;
130
76
  appointmentStatuses: Array<string>;
131
77
  appointmentTypes: Array<string>;
132
78
  checkInButton: {
@@ -138,18 +84,8 @@ export interface ConfigObject {
138
84
  enabled: boolean;
139
85
  customUrl: string;
140
86
  };
141
- concepts: {
142
- visitQueueNumberAttributeUuid: string;
143
- };
144
87
  customPatientChartUrl: string;
145
- daysOfTheWeek: Array<string>;
146
- defaultFacilityUrl: string;
147
- fullViewPrivilege: string;
148
- hiddenFormFields: Array<string>;
88
+ includePhoneNumberInExcelSpreadsheet: boolean;
149
89
  patientIdentifierType: string;
150
- showServiceQueueFields: boolean;
151
90
  showUnscheduledAppointmentsTab: boolean;
152
- useBahmniAppointmentsUI: boolean;
153
- useFullViewPrivilege: boolean;
154
- includePhoneNumberInExcelSpreadsheet: boolean;
155
91
  }