@persei/perseed-api 4.34.15 → 4.34.16

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.
package/dist/index.d.ts CHANGED
@@ -85,9 +85,12 @@ declare class BaseModel extends Model {
85
85
  $parseJson(json: any, _opt: any): any;
86
86
  }
87
87
 
88
- declare interface BaseWidget {
88
+ export declare type BaseWidgetPayload = {
89
+ title: string;
90
+ description?: string;
91
+ weight?: number;
89
92
  size?: number | ColProps;
90
- }
93
+ };
91
94
 
92
95
  declare interface CacheOptions {
93
96
  enabled: boolean;
@@ -419,14 +422,6 @@ export declare const CORE: {
419
422
 
420
423
  export declare const CountryPhoneCodes: {};
421
424
 
422
- export declare interface CreateDashboardPayload {
423
- title: string;
424
- active?: boolean;
425
- config?: DashboardConfig;
426
- icon?: string | null;
427
- weight?: number;
428
- }
429
-
430
425
  export declare interface CreateFormPayload extends BaseApiServicePayload {
431
426
  formName: string;
432
427
  patientId: number;
@@ -450,24 +445,33 @@ export declare interface CreateTriggerPayload {
450
445
  configuration?: NotificationConfigurationConf;
451
446
  }
452
447
 
448
+ export declare type CreateWidgetPayload = (BaseWidgetPayload & {
449
+ type: WidgetType.SECTIONCARD;
450
+ params: SectionCardProps;
451
+ }) | (BaseWidgetPayload & {
452
+ type: WidgetType.VALUECARD;
453
+ params: ValueCardProps;
454
+ }) | (BaseWidgetPayload & {
455
+ type: WidgetType.PATIENTLIST;
456
+ params: PatientListProps;
457
+ }) | (BaseWidgetPayload & {
458
+ type: WidgetType.DASHBOARD;
459
+ params: DashboardProps;
460
+ });
461
+
453
462
  declare class CustomQueryBuilder<M extends Model = Model, R = M[]> extends QueryBuilder<M, R> {
454
463
  delete(): this;
455
464
  nativeDelete(): NumberQueryBuilder<this>;
456
465
  }
457
466
 
458
- export declare interface DashboardConfig {
459
- widgets?: Widget[];
460
- }
461
-
462
- export declare enum DashboardWidgetType {
463
- VALUECARD = "ValueCard",
464
- SECTIONCARD = "SectionCard",
465
- PATIENTLIST = "PatientList"
467
+ export declare interface DashboardProps {
468
+ title: string;
469
+ active?: boolean;
470
+ config?: any;
471
+ icon?: string | null;
472
+ weight?: number;
466
473
  }
467
474
 
468
- /**
469
- * Any changes here may need changes in Caaring-js packages/perseed-react-ui-components/src/dashboards/types.ts
470
- */
471
475
  export declare enum DataLoaderType {
472
476
  OUTCOMES = "outcomes"
473
477
  }
@@ -768,12 +772,12 @@ export declare const HREF_TYPE: {
768
772
  EMBEDDED_HTML: string;
769
773
  };
770
774
 
771
- export declare interface I18nTextLocales {
775
+ declare interface I18nTextLocales {
772
776
  default: string;
773
777
  [locale: string]: string;
774
778
  }
775
779
 
776
- export declare type I18nTextTranslation = I18nTextLocales | string;
780
+ declare type I18nTextTranslation = I18nTextLocales | string;
777
781
 
778
782
  declare interface IdRefForm {
779
783
  syncId?: number;
@@ -1704,7 +1708,7 @@ export declare interface SectionCardProps {
1704
1708
  background?: string;
1705
1709
  titleBackground?: string;
1706
1710
  title: I18nTextTranslation;
1707
- widgets: Widget[];
1711
+ widgets: number[];
1708
1712
  }
1709
1713
 
1710
1714
  /**
@@ -1927,8 +1931,6 @@ export declare const TYPE: {
1927
1931
  TASK: string;
1928
1932
  };
1929
1933
 
1930
- export declare type UpdateDashboardPayload = Partial<CreateDashboardPayload>;
1931
-
1932
1934
  export declare interface UpdateFormPayload extends BaseApiServicePayload {
1933
1935
  formName: string;
1934
1936
  body: any;
@@ -1940,6 +1942,8 @@ export declare interface UpdateFormPayload extends BaseApiServicePayload {
1940
1942
 
1941
1943
  export declare type UpdateTriggerPayload = Partial<CreateTriggerPayload>;
1942
1944
 
1945
+ export declare type UpdateWidgetPayload = Partial<CreateWidgetPayload>;
1946
+
1943
1947
  declare class User extends BaseModel {
1944
1948
  username?: string;
1945
1949
  created_user?: number;
@@ -2632,17 +2636,6 @@ export declare interface ValueCardProps {
2632
2636
  dataLoader?: WidgetDataLoader<WidgetOutcomesDataLoader>;
2633
2637
  }
2634
2638
 
2635
- export declare type Widget = BaseWidget & ({
2636
- type: DashboardWidgetType.SECTIONCARD;
2637
- params: SectionCardProps;
2638
- } | {
2639
- type: DashboardWidgetType.VALUECARD;
2640
- params: ValueCardProps;
2641
- } | {
2642
- type: DashboardWidgetType.PATIENTLIST;
2643
- params: PatientListProps;
2644
- });
2645
-
2646
2639
  export declare type WidgetDataLoader<T> = T extends {
2647
2640
  type: infer Type;
2648
2641
  params: infer Params;
@@ -2656,4 +2649,11 @@ export declare interface WidgetOutcomesDataLoader {
2656
2649
  params: OutcomesParams;
2657
2650
  }
2658
2651
 
2652
+ export declare enum WidgetType {
2653
+ VALUECARD = "ValueCard",
2654
+ SECTIONCARD = "SectionCard",
2655
+ PATIENTLIST = "PatientList",
2656
+ DASHBOARD = "Dashboard"
2657
+ }
2658
+
2659
2659
  export { }
@@ -1,4 +1,4 @@
1
- const A = "YYYY-MM-DD", C = "HH:mm:ss", M = "HH:mm", p = "YYYY-MM-DD HH:mm", D = A, g = "YYYY-MM-DD HH:mm:ss", f = {
1
+ const A = "YYYY-MM-DD", C = "HH:mm:ss", M = "HH:mm", p = "YYYY-MM-DD HH:mm", D = A, g = "YYYY-MM-DD HH:mm:ss", h = {
2
2
  PENDING: "IN_PROGRESS",
3
3
  ERROR: "ERROR",
4
4
  SUCCESS: "COMPLETED",
@@ -59,7 +59,7 @@ const A = "YYYY-MM-DD", C = "HH:mm:ss", M = "HH:mm", p = "YYYY-MM-DD HH:mm", D =
59
59
  FILE_NAME: "file"
60
60
  };
61
61
  var l = /* @__PURE__ */ ((a) => (a[a.STATIC = 0] = "STATIC", a[a.STANDARD = 1] = "STANDARD", a[a.FOLLOW_UP = 2] = "FOLLOW_UP", a[a.ADVERSE_EVENT = 3] = "ADVERSE_EVENT", a[a.QUESTIONNAIRE = 5] = "QUESTIONNAIRE", a[a.STUDY = 6] = "STUDY", a))(l || {});
62
- const h = () => {
62
+ const f = () => {
63
63
  let a = {};
64
64
  return Object.keys(r).forEach((e) => {
65
65
  a = {
@@ -67,7 +67,7 @@ const h = () => {
67
67
  [r[e]]: _[`${e}_NAME`]
68
68
  };
69
69
  }), a;
70
- }, P = ["number", _.DECIMAL_NAME, _.INTEGER_NAME], b = ["date"], U = ["object", _.SCAN_CODE_NAME], T = {
70
+ }, b = ["number", _.DECIMAL_NAME, _.INTEGER_NAME], P = ["date"], U = ["object", _.SCAN_CODE_NAME], T = {
71
71
  CREATION_TIME: "creation_time",
72
72
  CREATION_USER: "creation_user",
73
73
  CRF_NAME: "crf_name",
@@ -1122,7 +1122,7 @@ const o = {
1122
1122
  "zu_ZA",
1123
1123
  "fi_FI"
1124
1124
  ], Aa = "forms", la = "history";
1125
- var N = /* @__PURE__ */ ((a) => (a.OUTCOMES = "outcomes", a))(N || {}), d = /* @__PURE__ */ ((a) => (a.VALUECARD = "ValueCard", a.SECTIONCARD = "SectionCard", a.PATIENTLIST = "PatientList", a))(d || {}), S = /* @__PURE__ */ ((a) => (a.QUESTIONNAIRE_CREATE = "questionnaire.create", a.CRF_CREATE = "crf.create", a.CRF_UPDATE = "crf.update", a.CRF_DELETE = "crf.delete", a.EXTERNAL_API_CALL = "external_api_call", a))(S || {}), m = /* @__PURE__ */ ((a) => (a.JSON_LOGIC = "jsonLogic", a.CUSTOM = "custom", a))(m || {}), i = /* @__PURE__ */ ((a) => (a.CREATION = "creation", a.UPDATE = "update", a))(i || {}), R = /* @__PURE__ */ ((a) => (a.TEXT = "text", a.DATE = "date", a.TIME = "time", a.BOOLEAN = "boolean", a.NUMBER = "number", a.SELECT = "select", a.MULTISELECT = "multiselect", a.HIDDEN = "hidden", a))(R || {});
1125
+ var N = /* @__PURE__ */ ((a) => (a.VALUECARD = "ValueCard", a.SECTIONCARD = "SectionCard", a.PATIENTLIST = "PatientList", a.DASHBOARD = "Dashboard", a))(N || {}), d = /* @__PURE__ */ ((a) => (a.OUTCOMES = "outcomes", a))(d || {}), S = /* @__PURE__ */ ((a) => (a.QUESTIONNAIRE_CREATE = "questionnaire.create", a.CRF_CREATE = "crf.create", a.CRF_UPDATE = "crf.update", a.CRF_DELETE = "crf.delete", a.EXTERNAL_API_CALL = "external_api_call", a))(S || {}), m = /* @__PURE__ */ ((a) => (a.JSON_LOGIC = "jsonLogic", a.CUSTOM = "custom", a))(m || {}), i = /* @__PURE__ */ ((a) => (a.CREATION = "creation", a.UPDATE = "update", a))(i || {}), R = /* @__PURE__ */ ((a) => (a.TEXT = "text", a.DATE = "date", a.TIME = "time", a.BOOLEAN = "boolean", a.NUMBER = "number", a.SELECT = "select", a.MULTISELECT = "multiselect", a.HIDDEN = "hidden", a))(R || {});
1126
1126
  class Ta {
1127
1127
  constructor(e) {
1128
1128
  this.notified_about = e;
@@ -1168,16 +1168,15 @@ export {
1168
1168
  aa as CountryPhoneCodes,
1169
1169
  p as DATETIME_SHORT_FORMAT,
1170
1170
  A as DATE_FORMAT,
1171
- b as DATE_TYPE,
1171
+ P as DATE_TYPE,
1172
1172
  J as DEFAULT_CONFIGURATION_PATIENT_LIST,
1173
1173
  X as DYNAMIC_FILE_VALID_FORMATS,
1174
- d as DashboardWidgetType,
1175
- N as DataLoaderType,
1174
+ d as DataLoaderType,
1176
1175
  y as EXCLUDE_FIELDS,
1177
- f as Exporter,
1176
+ h as Exporter,
1178
1177
  r as FIELDS,
1179
1178
  _ as FIELD_NAMES,
1180
- h as FIELD_NAMES_MAP,
1179
+ f as FIELD_NAMES_MAP,
1181
1180
  Y as FIELD_STATUS,
1182
1181
  G as FIELD_SUFFIX,
1183
1182
  Aa as FORMS_VIEW,
@@ -1200,7 +1199,7 @@ export {
1200
1199
  D as MYSQL_DATE_FORMAT,
1201
1200
  $ as NOTIFIED_TYPES,
1202
1201
  z as NO_FILL_STATUS,
1203
- P as NUMBER_TYPE,
1202
+ b as NUMBER_TYPE,
1204
1203
  Ta as NotifiedAboutInfo,
1205
1204
  U as OBJECT_TYPE,
1206
1205
  O as PATIENT_CREATION_ABOUT,
@@ -1223,6 +1222,7 @@ export {
1223
1222
  V as TIME_SCHEMA,
1224
1223
  E as TYPE,
1225
1224
  i as TriggerAction,
1225
+ N as WidgetType,
1226
1226
  c as allCountries,
1227
1227
  w as isNotStatusField
1228
1228
  };
@@ -1 +1 @@
1
- (function(a,n){typeof exports=="object"&&typeof module<"u"?n(exports):typeof define=="function"&&define.amd?define(["exports"],n):(a=typeof globalThis<"u"?globalThis:a||self,n(a["perseed-api"]={}))})(this,function(a){"use strict";const n="YYYY-MM-DD",C="HH:mm:ss",D="HH:mm",g="YYYY-MM-DD HH:mm",f=n,P="YYYY-MM-DD HH:mm:ss",h={PENDING:"IN_PROGRESS",ERROR:"ERROR",SUCCESS:"COMPLETED",AVAILABLE_FORMATS:{xls:0,csv:2,spss:1}},r={DECIMAL:1,INTEGER:2,MULTIPLE_SELECTION:3,SELECTION:4,DYNAMIC_SELECTION:5,DATE:6,HEADER:7,SUBHEADER:8,WARNING:9,SUBFORM:10,MEMO:11,TEXT:12,TEXT_AREA:13,YES_NO:14,TIME:15,LINK_HREF:16,COUNTRY:17,HOSPITAL:18,USERS:19,DYNAMIC_FILE:20,DYNAMIC_LINK_HREF:21,SCAN_CODE:22,PARAGRAPH:23,FILE:24},E={DECIMAL_NAME:"decimal",INTEGER_NAME:"integer",MULTIPLE_SELECTION_NAME:"multiple_selection",SELECTION_NAME:"selection",DYNAMIC_SELECTION_NAME:"dynamic_selection",DATE_NAME:"date",HEADER_NAME:"header",SUBHEADER_NAME:"subheader",WARNING_NAME:"warning",SUBFORM_NAME:"subform",MEMO_NAME:"memo",TEXT_NAME:"text",TEXT_AREA_NAME:"text_area",YES_NO_NAME:"yes_no",TIME_NAME:"time",LINK_HREF_NAME:"link_href",COUNTRY_NAME:"country",HOSPITAL_NAME:"hospital",USERS_NAME:"users",DYNAMIC_FILE_NAME:"dynamic_file",DYNAMIC_LINK_HREF_NAME:"dynamic_link_href",SCAN_CODE_NAME:"scan_code",PARAGRAPH_NAME:"paragraph",FILE_NAME:"file"};var l=(e=>(e[e.STATIC=0]="STATIC",e[e.STANDARD=1]="STANDARD",e[e.FOLLOW_UP=2]="FOLLOW_UP",e[e.ADVERSE_EVENT=3]="ADVERSE_EVENT",e[e.QUESTIONNAIRE=5]="QUESTIONNAIRE",e[e.STUDY=6]="STUDY",e))(l||{});const U=()=>{let e={};return Object.keys(r).forEach(_=>{e={...e,[r[_]]:E[`${_}_NAME`]}}),e},p=["number",E.DECIMAL_NAME,E.INTEGER_NAME],b=["date"],F=["object",E.SCAN_CODE_NAME],I={CREATION_TIME:"creation_time",CREATION_USER:"creation_user",CRF_NAME:"crf_name",CRF_STATUS:"crf_status",HOSPITAL:"hospital",HOSPITAL_STATUS:"hospital_status",ID:"id",LOCK_STATE:"lock_state",LOCK_USER:"lock_user",LOCK_DATE:"lock_date",MODIFICATION_TIME:"mod_time",MODIFICATION_USER:"mod_user",PATIENT_ID:"patient_id",PATIENT_NUMBER:"patient_number",PATIENT_NUMBER_STATUS:"patient_number_status",RECORD_ID:"record_id",SIGNATURE_DATE:"signature_date",SIGNATURE_STATE:"signature_state",SIGNATURE_USER:"signature_user",STATUS:"status",USER_IP:"user_ip",DATE_OF_QUESTIONNAIRE:"date_of_questionnaire",TIME_OF_QUESTIONNAIRE:"time_of_questionnaire",VERSION:"version",REFERENCE:"reference",SUBFORM_ID:"subform_id"},y=Object.values(I),v={added:"A",edited:"E",deleted:"D"},k={PATIENT:"patient",SEPARATOR:"_"},Y={AUDIT:"audit"},B="~",G="_status",H="_status",w={filled:"filled",unk:"UNK",na:"NA",nd:"ND"},u=/^[0-9a-f]{33}_status$/,z=function(e){return!u.test(e)},V=["UNK","NA","ND"],K="^[0-1][0-9]:[0-5][0-9]$|^[0-2][0-3]:[0-5][0-9]$",q={DEPENDENT_SOURCE:"dependent_source",ENCRYPTED:"encrypted",ENCRYPTED_LEVEL:"encrypted_level",EXTERNAL_SHARING:"external_sharing",SHOW_EMBEDDED_PDF:"show_embedded_pdf",HIDDEN:"hidden",IS_CRF_MAIN_FIELD:"is_crf_main_field",MIN_VALUE:"min-value",MIN_VALUE_VALIDATION:"validation_of_less_than",MAX_VALUE:"max-value",MAX_VALUE_VALIDATION:"validation_of_higher_than",NEXT_FORM:"next_form",MULTIPLE:"is_multiple",ORDER:"order",READ_ONLY:"readonly",REQUIRED:"is_required",REQUIRED_TYPE:"type_of_required",SELECTION_VALUE:"value_of_selection",SELECTION_VALUE_SLIDER:"value_of_selection_slider",SOURCE_FIELD:"source_field",TYPE:"type",TYPE_QUESTIONARY:"questionary",QUESTION_DAYS:"question_days",QUESTION_TIME:"question_time",QUESTION_HOURS:"question_hours",QUESTION_MINUTES:"question_minutes",REMINDER_DAYS:"reminder_days",REMINDER_HOURS:"reminder_hours",REMINDER_MINUTES:"reminder_minutes",REMINDER_SUBJECT:"reminder_subject",REMINDER_MESSAGE:"reminder_message",MAX_NUMBER_REMINDER:"max_number_reminder",NUMBER_QUESTION_PAGE:"number_question_page",UNTIL:"until",NUMBER_OF_QUESTIONAIRES:"number_of_questionaires",QUESTION_COMMENTS:"question_comments",TYPE_OF_QUESTIONNAIRE:"type_of_questionnaire",HISTORY_OF_QUESTIONNAIRE:"history_of_questionnaire",HISTORY:"history",CRF_HISTORY:"crf_history",PROCEDURE_CONDITION:"procedure_condition",HREF_VALUE:"href_value",HREF_TYPE:"href_type",SIZE:"size",FILE_TYPE:"file_type",INPUT_TYPE:"input_type",PARAGRAPH_CONTENT:"paragraph_content",FILE_VALUE:"file_value",WINDOW_REFERENCE:"window_reference",START_DATE_DAYS:"start_date_days",HAS_DEFAULT_VALUE:"has_default_value",SPECIFIC_VALUE:"specific_value",DEFAULT_VALUE:"default_value",UNIQUE:"unique",HELP:"help",SELECTOR_TYPE:"selector_type",SLIDER_SELECTOR:"slider_selector",SLIDER_SCALE_ORIENTATION:"slider_scale_orientation",UNTIL_DATE:"until",PAGE_BREAK:"page_break",WINDOW_BEFORE:"window_before",WINDOW_AFTER:"window_after",WINDOW_PERIOD:"window_period"},W={STRICT:"strict",FLEXIBLE:"flexible"},j={ACTIVE:"1"},Q={SLIDER:"slider",DROPDOWN:"dropdown",RADIO_BUTTON:"radio_button",CHECK_BOX:"check_box"},t={STARS:"0",SCALE_RATING:"1",IMAGES:"2"},X={[t.STARS]:"stars",[t.SCALE_RATING]:"scale",[t.IMAGES]:"images"},s={HORIZONTAL:"0",VERTICAL:"1"},Z={[s.HORIZONTAL]:"horizontal",[s.VERTICAL]:"vertical"},J={NEW_WINDOW:"newwindow",EMBEDDED_HTML:"embeddedhtml"},$={1:["image/jpg","image/jpeg","image/bmp","image/gif","image/png"],2:["application/pdf","application/x-pdf","text/csv","application/vnd.ms-excel","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","application/vnd.oasis.opendocument.text","application/msword","application/vnd.openxmlformats-officedocument.wordprocessingml.document"],3:["application/pdf","application/x-pdf"],4:["application/dicom","application/gzip","application/x-gzip","application/tar","application/tar+gzip","application/zip","application/x-rar-compressed","application/x-zip-compressed","application/x-7z-compressed","application/octet-stream"],5:["video/x-msvideo","video/x-mkv","video/x-matroska","video/mpeg","video/mpeg4","video/mpg","video/ogg","video/webm","video/3gpp","video/3gpp2","video/mp4","video/divx","video/avi","video/quicktime","video/x-ms-wmv","video/x-flv"]},x=[{id:"1",name:"patient_number",type:"Zend\\Form\\Element\\Text",label:"Patient Id",required:"1",crf_name:"patient",status:"1"},{type:"4",name:"hospital",label:"Hospital",required:"0",id:"2",crf_name:"patient",status:"1"},{id:"1000000001",name:"procedure",type:"customzation",label:"Procedures",required:"1",crf_name:"",status:"1"}],aa={EMAIL:1,MOBILE:2,PLATFORM:3,SMS:4,HL7:5,ALL:["1","2","3","4","5"]},N=[["Afghanistan (‫افغانستان‬‎)","af","93"],["Albania (Shqipëri)","al","355"],["Algeria (‫الجزائر‬‎)","dz","213"],["American Samoa","as","1",5,["684"]],["Andorra","ad","376"],["Angola","ao","244"],["Anguilla","ai","1",6,["264"]],["Antigua and Barbuda","ag","1",7,["268"]],["Argentina","ar","54"],["Armenia (Հայաստան)","am","374"],["Aruba","aw","297"],["Ascension Island","ac","247"],["Australia","au","61",0],["Austria (Österreich)","at","43"],["Azerbaijan (Azərbaycan)","az","994"],["Bahamas","bs","1",8,["242"]],["Bahrain (‫البحرين‬‎)","bh","973"],["Bangladesh (বাংলাদেশ)","bd","880"],["Barbados","bb","1",9,["246"]],["Belarus (Беларусь)","by","375"],["Belgium (België)","be","32"],["Belize","bz","501"],["Benin (Bénin)","bj","229"],["Bermuda","bm","1",10,["441"]],["Bhutan (འབྲུག)","bt","975"],["Bolivia","bo","591"],["Bosnia and Herzegovina (Босна и Херцеговина)","ba","387"],["Botswana","bw","267"],["Brazil (Brasil)","br","55"],["British Indian Ocean Territory","io","246"],["British Virgin Islands","vg","1",11,["284"]],["Brunei","bn","673"],["Bulgaria (България)","bg","359"],["Burkina Faso","bf","226"],["Burundi (Uburundi)","bi","257"],["Cambodia (កម្ពុជា)","kh","855"],["Cameroon (Cameroun)","cm","237"],["Canada","ca","1",1,["204","226","236","249","250","289","306","343","365","387","403","416","418","431","437","438","450","506","514","519","548","579","581","587","604","613","639","647","672","705","709","742","778","780","782","807","819","825","867","873","902","905"]],["Cape Verde (Kabu Verdi)","cv","238"],["Caribbean Netherlands","bq","599",1,["3","4","7"]],["Cayman Islands","ky","1",12,["345"]],["Central African Republic (République centrafricaine)","cf","236"],["Chad (Tchad)","td","235"],["Chile","cl","56"],["China (中国)","cn","86"],["Christmas Island","cx","61",2,["89164"]],["Cocos (Keeling) Islands","cc","61",1,["89162"]],["Colombia","co","57"],["Comoros (‫جزر القمر‬‎)","km","269"],["Congo (DRC) (Jamhuri ya Kidemokrasia ya Kongo)","cd","243"],["Congo (Republic) (Congo-Brazzaville)","cg","242"],["Cook Islands","ck","682"],["Costa Rica","cr","506"],["Côte d’Ivoire","ci","225"],["Croatia (Hrvatska)","hr","385"],["Cuba","cu","53"],["Curaçao","cw","599",0],["Cyprus (Κύπρος)","cy","357"],["Czech Republic (Česká republika)","cz","420"],["Denmark (Danmark)","dk","45"],["Djibouti","dj","253"],["Dominica","dm","1",13,["767"]],["Dominican Republic (República Dominicana)","do","1",2,["809","829","849"]],["Ecuador","ec","593"],["Egypt (‫مصر‬‎)","eg","20"],["El Salvador","sv","503"],["Equatorial Guinea (Guinea Ecuatorial)","gq","240"],["Eritrea","er","291"],["Estonia (Eesti)","ee","372"],["Eswatini","sz","268"],["Ethiopia","et","251"],["Falkland Islands (Islas Malvinas)","fk","500"],["Faroe Islands (Føroyar)","fo","298"],["Fiji","fj","679"],["Finland (Suomi)","fi","358",0],["France","fr","33"],["French Guiana (Guyane française)","gf","594"],["French Polynesia (Polynésie française)","pf","689"],["Gabon","ga","241"],["Gambia","gm","220"],["Georgia (საქართველო)","ge","995"],["Germany (Deutschland)","de","49"],["Ghana (Gaana)","gh","233"],["Gibraltar","gi","350"],["Greece (Ελλάδα)","gr","30"],["Greenland (Kalaallit Nunaat)","gl","299"],["Grenada","gd","1",14,["473"]],["Guadeloupe","gp","590",0],["Guam","gu","1",15,["671"]],["Guatemala","gt","502"],["Guernsey","gg","44",1,["1481","7781","7839","7911"]],["Guinea (Guinée)","gn","224"],["Guinea-Bissau (Guiné Bissau)","gw","245"],["Guyana","gy","592"],["Haiti","ht","509"],["Honduras","hn","504"],["Hong Kong (香港)","hk","852"],["Hungary (Magyarország)","hu","36"],["Iceland (Ísland)","is","354"],["India (भारत)","in","91"],["Indonesia","id","62"],["Iran (‫ایران‬‎)","ir","98"],["Iraq (‫العراق‬‎)","iq","964"],["Ireland","ie","353"],["Isle of Man","im","44",2,["1624","74576","7524","7924","7624"]],["Israel (‫ישראל‬‎)","il","972"],["Italy (Italia)","it","39",0],["Jamaica","jm","1",4,["876","658"]],["Japan (日本)","jp","81"],["Jersey","je","44",3,["1534","7509","7700","7797","7829","7937"]],["Jordan (‫الأردن‬‎)","jo","962"],["Kazakhstan (Казахстан)","kz","7",1,["33","7"]],["Kenya","ke","254"],["Kiribati","ki","686"],["Kosovo","xk","383"],["Kuwait (‫الكويت‬‎)","kw","965"],["Kyrgyzstan (Кыргызстан)","kg","996"],["Laos (ລາວ)","la","856"],["Latvia (Latvija)","lv","371"],["Lebanon (‫لبنان‬‎)","lb","961"],["Lesotho","ls","266"],["Liberia","lr","231"],["Libya (‫ليبيا‬‎)","ly","218"],["Liechtenstein","li","423"],["Lithuania (Lietuva)","lt","370"],["Luxembourg","lu","352"],["Macau (澳門)","mo","853"],["North Macedonia (Македонија)","mk","389"],["Madagascar (Madagasikara)","mg","261"],["Malawi","mw","265"],["Malaysia","my","60"],["Maldives","mv","960"],["Mali","ml","223"],["Malta","mt","356"],["Marshall Islands","mh","692"],["Martinique","mq","596"],["Mauritania (‫موريتانيا‬‎)","mr","222"],["Mauritius (Moris)","mu","230"],["Mayotte","yt","262",1,["269","639"]],["Mexico (México)","mx","52"],["Micronesia","fm","691"],["Moldova (Republica Moldova)","md","373"],["Monaco","mc","377"],["Mongolia (Монгол)","mn","976"],["Montenegro (Crna Gora)","me","382"],["Montserrat","ms","1",16,["664"]],["Morocco (‫المغرب‬‎)","ma","212",0],["Mozambique (Moçambique)","mz","258"],["Myanmar (Burma) (မြန်မာ)","mm","95"],["Namibia (Namibië)","na","264"],["Nauru","nr","674"],["Nepal (नेपाल)","np","977"],["Netherlands (Nederland)","nl","31"],["New Caledonia (Nouvelle-Calédonie)","nc","687"],["New Zealand","nz","64"],["Nicaragua","ni","505"],["Niger (Nijar)","ne","227"],["Nigeria","ng","234"],["Niue","nu","683"],["Norfolk Island","nf","672"],["North Korea (조선 민주주의 인민 공화국)","kp","850"],["Northern Mariana Islands","mp","1",17,["670"]],["Norway (Norge)","no","47",0],["Oman (‫عُمان‬‎)","om","968"],["Pakistan (‫پاکستان‬‎)","pk","92"],["Palau","pw","680"],["Palestine (‫فلسطين‬‎)","ps","970"],["Panama (Panamá)","pa","507"],["Papua New Guinea","pg","675"],["Paraguay","py","595"],["Peru (Perú)","pe","51"],["Philippines","ph","63"],["Poland (Polska)","pl","48"],["Portugal","pt","351"],["Puerto Rico","pr","1",3,["787","939"]],["Qatar (‫قطر‬‎)","qa","974"],["Réunion (La Réunion)","re","262",0],["Romania (România)","ro","40"],["Russia (Россия)","ru","7",0],["Rwanda","rw","250"],["Saint Barthélemy","bl","590",1],["Saint Helena","sh","290"],["Saint Kitts and Nevis","kn","1",18,["869"]],["Saint Lucia","lc","1",19,["758"]],["Saint Martin (Saint-Martin (partie française))","mf","590",2],["Saint Pierre and Miquelon (Saint-Pierre-et-Miquelon)","pm","508"],["Saint Vincent and the Grenadines","vc","1",20,["784"]],["Samoa","ws","685"],["San Marino","sm","378"],["São Tomé and Príncipe (São Tomé e Príncipe)","st","239"],["Saudi Arabia (‫المملكة العربية السعودية‬‎)","sa","966"],["Senegal (Sénégal)","sn","221"],["Serbia (Србија)","rs","381"],["Seychelles","sc","248"],["Sierra Leone","sl","232"],["Singapore","sg","65"],["Sint Maarten","sx","1",21,["721"]],["Slovakia (Slovensko)","sk","421"],["Slovenia (Slovenija)","si","386"],["Solomon Islands","sb","677"],["Somalia (Soomaaliya)","so","252"],["South Africa","za","27"],["South Korea (대한민국)","kr","82"],["South Sudan (‫جنوب السودان‬‎)","ss","211"],["Spain (España)","es","34"],["Sri Lanka (ශ්‍රී ලංකාව)","lk","94"],["Sudan (‫السودان‬‎)","sd","249"],["Suriname","sr","597"],["Svalbard and Jan Mayen","sj","47",1,["79"]],["Sweden (Sverige)","se","46"],["Switzerland (Schweiz)","ch","41"],["Syria (‫سوريا‬‎)","sy","963"],["Taiwan (台灣)","tw","886"],["Tajikistan","tj","992"],["Tanzania","tz","255"],["Thailand (ไทย)","th","66"],["Timor-Leste","tl","670"],["Togo","tg","228"],["Tokelau","tk","690"],["Tonga","to","676"],["Trinidad and Tobago","tt","1",22,["868"]],["Tunisia (‫تونس‬‎)","tn","216"],["Turkey (Türkiye)","tr","90"],["Turkmenistan","tm","993"],["Turks and Caicos Islands","tc","1",23,["649"]],["Tuvalu","tv","688"],["U.S. Virgin Islands","vi","1",24,["340"]],["Uganda","ug","256"],["Ukraine (Україна)","ua","380"],["United Arab Emirates (‫الإمارات العربية المتحدة‬‎)","ae","971"],["United Kingdom","gb","44",0],["United States","us","1",0],["Uruguay","uy","598"],["Uzbekistan (Oʻzbekiston)","uz","998"],["Vanuatu","vu","678"],["Vatican City (Città del Vaticano)","va","39",1,["06698"]],["Venezuela","ve","58"],["Vietnam (Việt Nam)","vn","84"],["Wallis and Futuna (Wallis-et-Futuna)","wf","681"],["Western Sahara (‫الصحراء الغربية‬‎)","eh","212",1,["5288","5289"]],["Yemen (‫اليمن‬‎)","ye","967"],["Zambia","zm","260"],["Zimbabwe","zw","263"],["Åland Islands","ax","358",1,["18"]]],ea=N.reduce((e,_)=>{const T=_[1];return e[T]=_[2],e},{});var S=(e=>(e.CLOSED="Closed",e.OPEN="Open",e.COMING_SOON="Coming soon",e))(S||{});const o={PERMANENT:"Permanent",TEMPORARY:"Temporary"},A={QOL:"QoL",TASK:"Task"},_a={0:A.QOL,1:A.TASK},ia={0:o.PERMANENT,1:o.TEMPORARY},na={DATE:"date_of_questionnaire",TIME:"time_of_questionnaire"},Ea={TYPE:"type_of_questionnaire"},ta={PERSEED_ADMIN:"PerseedAdmin",ECOSYSTEM_ADMIN:"EcosystemAdmin",USER:"Users",SALE:"Sales"},ra={ADD_PATIENT:"add_patient",ADD_REPEATABLE_CRF:"add_repeat_crf",ADVANCED_FILTER:"advanced_filter",ALL_PATIENT_LIST:"all_patient_list",ALLOW_TO_CONTROL_THESE_PROFILES:"core_control_profile",CONNECTOR_ADD_CP:"connector_add_cp",CONNECTOR_ADD_CRF:"connector_add_crf",CONNECTOR_ADD_FIELD:"connector_add_field",CORE_NOT_ALLOW_ACCESS_SENSITIVE_INFO:"core_not_allow_access_sensitive_info",CORE_NOTIFICATION_LOG:"core_notification_log",CORE_NOTIFICATION_MY_LOG:"core_notification_my_log",DELETE_PATIENT:"delete_patient",FULL_DELETE_PATIENT:"full_delete_patient",DELETE_REPEATABLE_CRF:"delete_crf",EXPORT_ANONYMIZED:"export_anonymized",ENABLE_CP:"enable_cp",EXPORT_MY_HOSPITALS:"export_my_hospitals",EXPORT_NOT_ALLOW_ACCESS_SENSITIVE_INFO:"export_not_allow_access_sensitive_info",EXPORT_USER_TIMESTAMP:"export_user_timestamp",EXPORT_RAW:"export_raw",FILTER_ALL:"filter_all",FILTER_MY_HOSPITALS:"filter_my_hospitals",MANAGE_USERS:"core_manage_user",CORE_PRO_USER_SENSITIVE_INFO:"core_pro_user_sensitive_info",NOTIFICATIONS:"core_notification_seed",ONLY_MY_PATIENTS:"only_my_patients",ONLY_UPDATE_PATIENTS_API:"only_update_patients",PRO_USER:"core_pro_user",USERS_MANAGEMENT_FOR_MY_ORGANIZATIONS:"core_manage_user_hospital",UPLOAD_DOCUMENTS:"add",DELETE_DOCUMENTS:"delete",READ_DOCUMENTS:"read",DISPLAY_PATIENT_LIST:"advanced_patient_list",EXPORT_CONFIGURATION_EXPLICIT_ACCESS:"export_configurations_explicit_access_only",FOLLOWUP_DASHBOARD:"followup_dashboard",TRIGGERS_MANAGEMENT:"triggers_management"},sa=["Etc/GMT+12","Pacific/Midway","Pacific/Honolulu","America/Juneau","America/Dawson","America/Boise","America/Chihuahua","America/Phoenix","America/Chicago","America/Regina","America/Mexico_City","America/Belize","America/Detroit","America/Indiana/Indianapolis","America/Bogota","America/Glace_Bay","America/Caracas","America/Santiago","America/St_Johns","America/Sao_Paulo","America/Argentina/Buenos_Aires","America/Godthab","Etc/GMT+2","Atlantic/Azores","Atlantic/Cape_Verde","GMT","Africa/Casablanca","Atlantic/Canary","Europe/Belgrade","Europe/Sarajevo","Europe/Brussels","Europe/Amsterdam","Africa/Algiers","Europe/Bucharest","Africa/Cairo","Europe/Helsinki","Europe/Athens","Asia/Jerusalem","Africa/Harare","Europe/Moscow","Asia/Kuwait","Africa/Nairobi","Asia/Baghdad","Asia/Tehran","Asia/Dubai","Asia/Baku","Asia/Kabul","Asia/Yekaterinburg","Asia/Karachi","Asia/Kolkata","Asia/Kathmandu","Asia/Dhaka","Asia/Colombo","Asia/Almaty","Asia/Rangoon","Asia/Bangkok","Asia/Krasnoyarsk","Asia/Shanghai","Asia/Kuala_Lumpur","Asia/Taipei","Australia/Perth","Asia/Irkutsk","Asia/Seoul","Asia/Tokyo","Asia/Yakutsk","Australia/Darwin","Australia/Adelaide","Australia/Sydney","Australia/Brisbane","Australia/Hobart","Asia/Vladivostok","Pacific/Guam","Asia/Magadan","Pacific/Fiji","Pacific/Auckland","Pacific/Tongatapu"],oa=["ab","aa","af","ak","sq","am","ar","an","hy","as","av","ae","ay","az","bm","ba","eu","be","bn","bh","bi","bs","br","bg","my","ca","ch","ce","ny","zh","cv","kw","co","cr","hr","cs","da","dv","nl","dz","en","eo","et","ee","fo","fj","fi","fr","ff","gl","gd","gv","ka","de","el","kl","gn","gu","ht","ha","he","hz","hi","ho","hu","is","io","ig","id","ia","ie","iu","ik","ga","it","ja","jv","kl","kn","kr","ks","kk","km","ki","rw","rn","ky","kv","kg","ko","ku","kj","lo","la","lv","li","ln","lt","lu","lg","lb","gv","mk","mg","ms","ml","mt","mi","mr","mh","mo","mn","na","nv","ng","nd","ne","no","nb","nn","ii","oc","oj","cu","or","om","os","pi","ps","fa","pl","pt","pa","qu","rm","ro","ru","se","sm","sg","sa","sr","sh","st","tn","sn","ii","sd","si","ss","sk","sl","so","nr","es","su","sw","ss","sv","tl","ty","tg","ta","tt","te","th","bo","ti","to","ts","tr","tk","tw","ug","uk","ur","uz","ve","vi","vo","wa","cy","wo","fy","xh","ji","yo","za","zu"],Aa=["af_ZA","am_ET","ar_AE","ar_BH","ar_DZ","ar_EG","ar_IQ","ar_JO","ar_KW","ar_LB","ar_LY","ar_MA","arn_CL","ar_OM","ar_QA","ar_SA","ar_SY","ar_TN","ar_YE","as_IN","az_Cyrl_AZ","az_Latn_AZ","ba_RU","be_BY","bg_BG","bn_BD","bn_IN","bo_CN","br_FR","bs_Cyrl_BA","bs_Latn_BA","ca_ES","co_FR","cs_CZ","cy_GB","da_DK","de_AT","de_CH","de_DE","de_LI","de_LU","dsb_DE","dv_MV","el_GR","en_029","en_AU","en_BZ","en_CA","en_GB","en_IE","en_IN","en_JM","en_MY","en_NZ","en_PH","en_SG","en_TT","en_US","en_ZA","en_ZW","es_AR","es_BO","es_CL","es_CO","es_CR","es_DO","es_EC","es_ES","es_GT","es_HN","es_MX","es_NI","es_PA","es_PE","es_PR","es_PY","es_SV","es_US","es_UY","es_VE","et_EE","eu_ES","fa_IR","fi_FI","fil_PH","fo_FO","fr_BE","fr_CA","fr_CH","fr_FR","fr_LU","fr_MC","fy_NL","ga_IE","gd_GB","gl_ES","gsw_FR","gu_IN","ha_Latn_NG","he_IL","hi_IN","hr_BA","hr_HR","hsb_DE","hu_HU","hy_AM","id_ID","ig_NG","ii_CN","is_IS","it_CH","it_IT","iu_Cans_CA","iu_Latn_CA","ja_JP","ka_GE","kk_KZ","kl_GL","km_KH","kn_IN","kok_IN","ko_KR","ky_KG","lb_LU","lo_LA","lt_LT","lv_LV","mi_NZ","mk_MK","ml_IN","mn_MN","mn_Mong_CN","moh_CA","mr_IN","ms_BN","ms_MY","mt_MT","nb_NO","ne_NP","nl_BE","nl_NL","nn_NO","nso_ZA","oc_FR","or_IN","pa_IN","pl_PL","prs_AF","ps_AF","pt_BR","pt_PT","qut_GT","quz_BO","quz_EC","quz_PE","rm_CH","ro_RO","ru_RU","rw_RW","sah_RU","sa_IN","se_FI","se_NO","se_SE","si_LK","sk_SK","sl_SI","sma_NO","sma_SE","smj_NO","smj_SE","smn_FI","sms_FI","sq_AL","sr_Cyrl_BA","sr_Cyrl_CS","sr_Cyrl_ME","sr_Cyrl_RS","sr_Latn_BA","sr_Latn_CS","sr_Latn_ME","sr_Latn_RS","sv_FI","sv_SE","sw_KE","syr_SY","ta_IN","te_IN","tg_Cyrl_TJ","th_TH","tk_TM","tn_ZA","tr_TR","tt_RU","tzm_Latn_DZ","ug_CN","uk_UA","ur_PK","uz_Cyrl_UZ","uz_Latn_UZ","vi_VN","wo_SN","xh_ZA","yo_NG","zh_CN","zh_HK","zh_MO","zh_SG","zh_TW","zu_ZA","fi_FI"],Ta="forms",la="history";var d=(e=>(e.OUTCOMES="outcomes",e))(d||{}),c=(e=>(e.VALUECARD="ValueCard",e.SECTIONCARD="SectionCard",e.PATIENTLIST="PatientList",e))(c||{}),R=(e=>(e.QUESTIONNAIRE_CREATE="questionnaire.create",e.CRF_CREATE="crf.create",e.CRF_UPDATE="crf.update",e.CRF_DELETE="crf.delete",e.EXTERNAL_API_CALL="external_api_call",e))(R||{}),m=(e=>(e.JSON_LOGIC="jsonLogic",e.CUSTOM="custom",e))(m||{}),i=(e=>(e.CREATION="creation",e.UPDATE="update",e))(i||{}),O=(e=>(e.TEXT="text",e.DATE="date",e.TIME="time",e.BOOLEAN="boolean",e.NUMBER="number",e.SELECT="select",e.MULTISELECT="multiselect",e.HIDDEN="hidden",e))(O||{});class Ia{constructor(_){this.notified_about=_}crfName(){return this.notified_about.startsWith("crf_")?this.notified_about.split("_")[1]:this.notified_about.startsWith("Patient")?"patient":null}actionTrigger(){return this.notified_about.toLowerCase().endsWith(i.UPDATE)?i.UPDATE:this.notified_about.toLowerCase().endsWith(i.CREATION)?i.CREATION:null}isCrfTrigger(){return this.notified_about===L||this.notified_about.startsWith("crf_")}isModelTrigger(){return this.notified_about.startsWith("model_")}isDisplayerTrigger(){return this.notified_about.startsWith("model_displayer_")}isFieldTrigger(){return!isNaN(parseInt(this.notified_about))}getModelName(){if(this.isModelTrigger()&&!this.isDisplayerTrigger())return this.notified_about.split("_")[1];if(this.isDisplayerTrigger()){const _=this.notified_about.split("_"),T=_[_.length-1];return Object.values(i).includes(T)&&_.pop(),_.slice(2).join("_")}}getModelTriggerAction(){const _=this.getModelName();return _&&this.isDisplayerTrigger()?this.notified_about.replace(`model_displayer_${_}_`,"").replace(`model_displayer_${_}`,""):_&&this.isModelTrigger()?this.notified_about.replace(`model_${_}_`,"").replace(`model_${_}`,""):null}}const L="Patient Creation";var M=(e=>(e[e.START_OVER=0]="START_OVER",e[e.RESUME=1]="RESUME",e))(M||{});a.AUDIT_FLAGS=v,a.ApiAction=R,a.CORE=I,a.ConditionsFormat=m,a.CountryPhoneCodes=ea,a.DATETIME_SHORT_FORMAT=g,a.DATE_FORMAT=n,a.DATE_TYPE=b,a.DEFAULT_CONFIGURATION_PATIENT_LIST=x,a.DYNAMIC_FILE_VALID_FORMATS=$,a.DashboardWidgetType=c,a.DataLoaderType=d,a.EXCLUDE_FIELDS=y,a.Exporter=h,a.FIELDS=r,a.FIELD_NAMES=E,a.FIELD_NAMES_MAP=U,a.FIELD_STATUS=w,a.FIELD_SUFFIX=G,a.FORMS_VIEW=Ta,a.FORM_NAMES=k,a.FORM_SUFFIX=Y,a.FORM_TYPES=l,a.HISTORY=o,a.HISTORY_TYPE_OPTIONS=ia,a.HISTORY_VIEW=la,a.HREF_TYPE=J,a.IntrospectionSchemaFieldType=O,a.LANG_CODES=oa,a.LOCALE_LANG_CODES=Aa,a.META_NAMES=q,a.META_RESTRICTION=W,a.META_STATUS=j,a.MINIMIAL_TIMEZONE_LIST=sa,a.MULTIPLE_SELECTION_SEPARATOR=B,a.MYSQL_DATETIME_FORMAT=P,a.MYSQL_DATE_FORMAT=f,a.NOTIFIED_TYPES=aa,a.NO_FILL_STATUS=V,a.NUMBER_TYPE=p,a.NotifiedAboutInfo=Ia,a.OBJECT_TYPE=F,a.PATIENT_CREATION_ABOUT=L,a.QUESTIONNAIRE_DATE=na,a.QUESTIONNAIRE_TYPE=Ea,a.QUESTIONNAIRE_TYPE_OPTIONS=_a,a.QuestionnaireInfoUpdateMode=M,a.ROLES=ta,a.SEED_PRIVILEGE=ra,a.SELECTOR_TYPE=Q,a.SHORT_TIME_FORMAT=D,a.SLIDER_SCALE_ORIENTATION_TYPE=Z,a.SLIDER_SCALE_TYPE=s,a.SLIDER_SELECTOR_TYPE=X,a.SLIDER_TYPE=t,a.STATUS=S,a.STATUS_FIELD_REGEXP=u,a.STATUS_SUFFIX=H,a.TIME_FORMAT=C,a.TIME_SCHEMA=K,a.TYPE=A,a.TriggerAction=i,a.allCountries=N,a.isNotStatusField=z,Object.defineProperty(a,Symbol.toStringTag,{value:"Module"})});
1
+ (function(a,n){typeof exports=="object"&&typeof module<"u"?n(exports):typeof define=="function"&&define.amd?define(["exports"],n):(a=typeof globalThis<"u"?globalThis:a||self,n(a["perseed-api"]={}))})(this,function(a){"use strict";const n="YYYY-MM-DD",C="HH:mm:ss",D="HH:mm",g="YYYY-MM-DD HH:mm",f=n,P="YYYY-MM-DD HH:mm:ss",h={PENDING:"IN_PROGRESS",ERROR:"ERROR",SUCCESS:"COMPLETED",AVAILABLE_FORMATS:{xls:0,csv:2,spss:1}},r={DECIMAL:1,INTEGER:2,MULTIPLE_SELECTION:3,SELECTION:4,DYNAMIC_SELECTION:5,DATE:6,HEADER:7,SUBHEADER:8,WARNING:9,SUBFORM:10,MEMO:11,TEXT:12,TEXT_AREA:13,YES_NO:14,TIME:15,LINK_HREF:16,COUNTRY:17,HOSPITAL:18,USERS:19,DYNAMIC_FILE:20,DYNAMIC_LINK_HREF:21,SCAN_CODE:22,PARAGRAPH:23,FILE:24},E={DECIMAL_NAME:"decimal",INTEGER_NAME:"integer",MULTIPLE_SELECTION_NAME:"multiple_selection",SELECTION_NAME:"selection",DYNAMIC_SELECTION_NAME:"dynamic_selection",DATE_NAME:"date",HEADER_NAME:"header",SUBHEADER_NAME:"subheader",WARNING_NAME:"warning",SUBFORM_NAME:"subform",MEMO_NAME:"memo",TEXT_NAME:"text",TEXT_AREA_NAME:"text_area",YES_NO_NAME:"yes_no",TIME_NAME:"time",LINK_HREF_NAME:"link_href",COUNTRY_NAME:"country",HOSPITAL_NAME:"hospital",USERS_NAME:"users",DYNAMIC_FILE_NAME:"dynamic_file",DYNAMIC_LINK_HREF_NAME:"dynamic_link_href",SCAN_CODE_NAME:"scan_code",PARAGRAPH_NAME:"paragraph",FILE_NAME:"file"};var l=(e=>(e[e.STATIC=0]="STATIC",e[e.STANDARD=1]="STANDARD",e[e.FOLLOW_UP=2]="FOLLOW_UP",e[e.ADVERSE_EVENT=3]="ADVERSE_EVENT",e[e.QUESTIONNAIRE=5]="QUESTIONNAIRE",e[e.STUDY=6]="STUDY",e))(l||{});const U=()=>{let e={};return Object.keys(r).forEach(_=>{e={...e,[r[_]]:E[`${_}_NAME`]}}),e},p=["number",E.DECIMAL_NAME,E.INTEGER_NAME],b=["date"],F=["object",E.SCAN_CODE_NAME],I={CREATION_TIME:"creation_time",CREATION_USER:"creation_user",CRF_NAME:"crf_name",CRF_STATUS:"crf_status",HOSPITAL:"hospital",HOSPITAL_STATUS:"hospital_status",ID:"id",LOCK_STATE:"lock_state",LOCK_USER:"lock_user",LOCK_DATE:"lock_date",MODIFICATION_TIME:"mod_time",MODIFICATION_USER:"mod_user",PATIENT_ID:"patient_id",PATIENT_NUMBER:"patient_number",PATIENT_NUMBER_STATUS:"patient_number_status",RECORD_ID:"record_id",SIGNATURE_DATE:"signature_date",SIGNATURE_STATE:"signature_state",SIGNATURE_USER:"signature_user",STATUS:"status",USER_IP:"user_ip",DATE_OF_QUESTIONNAIRE:"date_of_questionnaire",TIME_OF_QUESTIONNAIRE:"time_of_questionnaire",VERSION:"version",REFERENCE:"reference",SUBFORM_ID:"subform_id"},y=Object.values(I),v={added:"A",edited:"E",deleted:"D"},k={PATIENT:"patient",SEPARATOR:"_"},Y={AUDIT:"audit"},B="~",G="_status",H="_status",w={filled:"filled",unk:"UNK",na:"NA",nd:"ND"},u=/^[0-9a-f]{33}_status$/,z=function(e){return!u.test(e)},V=["UNK","NA","ND"],K="^[0-1][0-9]:[0-5][0-9]$|^[0-2][0-3]:[0-5][0-9]$",q={DEPENDENT_SOURCE:"dependent_source",ENCRYPTED:"encrypted",ENCRYPTED_LEVEL:"encrypted_level",EXTERNAL_SHARING:"external_sharing",SHOW_EMBEDDED_PDF:"show_embedded_pdf",HIDDEN:"hidden",IS_CRF_MAIN_FIELD:"is_crf_main_field",MIN_VALUE:"min-value",MIN_VALUE_VALIDATION:"validation_of_less_than",MAX_VALUE:"max-value",MAX_VALUE_VALIDATION:"validation_of_higher_than",NEXT_FORM:"next_form",MULTIPLE:"is_multiple",ORDER:"order",READ_ONLY:"readonly",REQUIRED:"is_required",REQUIRED_TYPE:"type_of_required",SELECTION_VALUE:"value_of_selection",SELECTION_VALUE_SLIDER:"value_of_selection_slider",SOURCE_FIELD:"source_field",TYPE:"type",TYPE_QUESTIONARY:"questionary",QUESTION_DAYS:"question_days",QUESTION_TIME:"question_time",QUESTION_HOURS:"question_hours",QUESTION_MINUTES:"question_minutes",REMINDER_DAYS:"reminder_days",REMINDER_HOURS:"reminder_hours",REMINDER_MINUTES:"reminder_minutes",REMINDER_SUBJECT:"reminder_subject",REMINDER_MESSAGE:"reminder_message",MAX_NUMBER_REMINDER:"max_number_reminder",NUMBER_QUESTION_PAGE:"number_question_page",UNTIL:"until",NUMBER_OF_QUESTIONAIRES:"number_of_questionaires",QUESTION_COMMENTS:"question_comments",TYPE_OF_QUESTIONNAIRE:"type_of_questionnaire",HISTORY_OF_QUESTIONNAIRE:"history_of_questionnaire",HISTORY:"history",CRF_HISTORY:"crf_history",PROCEDURE_CONDITION:"procedure_condition",HREF_VALUE:"href_value",HREF_TYPE:"href_type",SIZE:"size",FILE_TYPE:"file_type",INPUT_TYPE:"input_type",PARAGRAPH_CONTENT:"paragraph_content",FILE_VALUE:"file_value",WINDOW_REFERENCE:"window_reference",START_DATE_DAYS:"start_date_days",HAS_DEFAULT_VALUE:"has_default_value",SPECIFIC_VALUE:"specific_value",DEFAULT_VALUE:"default_value",UNIQUE:"unique",HELP:"help",SELECTOR_TYPE:"selector_type",SLIDER_SELECTOR:"slider_selector",SLIDER_SCALE_ORIENTATION:"slider_scale_orientation",UNTIL_DATE:"until",PAGE_BREAK:"page_break",WINDOW_BEFORE:"window_before",WINDOW_AFTER:"window_after",WINDOW_PERIOD:"window_period"},j={STRICT:"strict",FLEXIBLE:"flexible"},W={ACTIVE:"1"},Q={SLIDER:"slider",DROPDOWN:"dropdown",RADIO_BUTTON:"radio_button",CHECK_BOX:"check_box"},t={STARS:"0",SCALE_RATING:"1",IMAGES:"2"},X={[t.STARS]:"stars",[t.SCALE_RATING]:"scale",[t.IMAGES]:"images"},s={HORIZONTAL:"0",VERTICAL:"1"},Z={[s.HORIZONTAL]:"horizontal",[s.VERTICAL]:"vertical"},J={NEW_WINDOW:"newwindow",EMBEDDED_HTML:"embeddedhtml"},$={1:["image/jpg","image/jpeg","image/bmp","image/gif","image/png"],2:["application/pdf","application/x-pdf","text/csv","application/vnd.ms-excel","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","application/vnd.oasis.opendocument.text","application/msword","application/vnd.openxmlformats-officedocument.wordprocessingml.document"],3:["application/pdf","application/x-pdf"],4:["application/dicom","application/gzip","application/x-gzip","application/tar","application/tar+gzip","application/zip","application/x-rar-compressed","application/x-zip-compressed","application/x-7z-compressed","application/octet-stream"],5:["video/x-msvideo","video/x-mkv","video/x-matroska","video/mpeg","video/mpeg4","video/mpg","video/ogg","video/webm","video/3gpp","video/3gpp2","video/mp4","video/divx","video/avi","video/quicktime","video/x-ms-wmv","video/x-flv"]},x=[{id:"1",name:"patient_number",type:"Zend\\Form\\Element\\Text",label:"Patient Id",required:"1",crf_name:"patient",status:"1"},{type:"4",name:"hospital",label:"Hospital",required:"0",id:"2",crf_name:"patient",status:"1"},{id:"1000000001",name:"procedure",type:"customzation",label:"Procedures",required:"1",crf_name:"",status:"1"}],aa={EMAIL:1,MOBILE:2,PLATFORM:3,SMS:4,HL7:5,ALL:["1","2","3","4","5"]},N=[["Afghanistan (‫افغانستان‬‎)","af","93"],["Albania (Shqipëri)","al","355"],["Algeria (‫الجزائر‬‎)","dz","213"],["American Samoa","as","1",5,["684"]],["Andorra","ad","376"],["Angola","ao","244"],["Anguilla","ai","1",6,["264"]],["Antigua and Barbuda","ag","1",7,["268"]],["Argentina","ar","54"],["Armenia (Հայաստան)","am","374"],["Aruba","aw","297"],["Ascension Island","ac","247"],["Australia","au","61",0],["Austria (Österreich)","at","43"],["Azerbaijan (Azərbaycan)","az","994"],["Bahamas","bs","1",8,["242"]],["Bahrain (‫البحرين‬‎)","bh","973"],["Bangladesh (বাংলাদেশ)","bd","880"],["Barbados","bb","1",9,["246"]],["Belarus (Беларусь)","by","375"],["Belgium (België)","be","32"],["Belize","bz","501"],["Benin (Bénin)","bj","229"],["Bermuda","bm","1",10,["441"]],["Bhutan (འབྲུག)","bt","975"],["Bolivia","bo","591"],["Bosnia and Herzegovina (Босна и Херцеговина)","ba","387"],["Botswana","bw","267"],["Brazil (Brasil)","br","55"],["British Indian Ocean Territory","io","246"],["British Virgin Islands","vg","1",11,["284"]],["Brunei","bn","673"],["Bulgaria (България)","bg","359"],["Burkina Faso","bf","226"],["Burundi (Uburundi)","bi","257"],["Cambodia (កម្ពុជា)","kh","855"],["Cameroon (Cameroun)","cm","237"],["Canada","ca","1",1,["204","226","236","249","250","289","306","343","365","387","403","416","418","431","437","438","450","506","514","519","548","579","581","587","604","613","639","647","672","705","709","742","778","780","782","807","819","825","867","873","902","905"]],["Cape Verde (Kabu Verdi)","cv","238"],["Caribbean Netherlands","bq","599",1,["3","4","7"]],["Cayman Islands","ky","1",12,["345"]],["Central African Republic (République centrafricaine)","cf","236"],["Chad (Tchad)","td","235"],["Chile","cl","56"],["China (中国)","cn","86"],["Christmas Island","cx","61",2,["89164"]],["Cocos (Keeling) Islands","cc","61",1,["89162"]],["Colombia","co","57"],["Comoros (‫جزر القمر‬‎)","km","269"],["Congo (DRC) (Jamhuri ya Kidemokrasia ya Kongo)","cd","243"],["Congo (Republic) (Congo-Brazzaville)","cg","242"],["Cook Islands","ck","682"],["Costa Rica","cr","506"],["Côte d’Ivoire","ci","225"],["Croatia (Hrvatska)","hr","385"],["Cuba","cu","53"],["Curaçao","cw","599",0],["Cyprus (Κύπρος)","cy","357"],["Czech Republic (Česká republika)","cz","420"],["Denmark (Danmark)","dk","45"],["Djibouti","dj","253"],["Dominica","dm","1",13,["767"]],["Dominican Republic (República Dominicana)","do","1",2,["809","829","849"]],["Ecuador","ec","593"],["Egypt (‫مصر‬‎)","eg","20"],["El Salvador","sv","503"],["Equatorial Guinea (Guinea Ecuatorial)","gq","240"],["Eritrea","er","291"],["Estonia (Eesti)","ee","372"],["Eswatini","sz","268"],["Ethiopia","et","251"],["Falkland Islands (Islas Malvinas)","fk","500"],["Faroe Islands (Føroyar)","fo","298"],["Fiji","fj","679"],["Finland (Suomi)","fi","358",0],["France","fr","33"],["French Guiana (Guyane française)","gf","594"],["French Polynesia (Polynésie française)","pf","689"],["Gabon","ga","241"],["Gambia","gm","220"],["Georgia (საქართველო)","ge","995"],["Germany (Deutschland)","de","49"],["Ghana (Gaana)","gh","233"],["Gibraltar","gi","350"],["Greece (Ελλάδα)","gr","30"],["Greenland (Kalaallit Nunaat)","gl","299"],["Grenada","gd","1",14,["473"]],["Guadeloupe","gp","590",0],["Guam","gu","1",15,["671"]],["Guatemala","gt","502"],["Guernsey","gg","44",1,["1481","7781","7839","7911"]],["Guinea (Guinée)","gn","224"],["Guinea-Bissau (Guiné Bissau)","gw","245"],["Guyana","gy","592"],["Haiti","ht","509"],["Honduras","hn","504"],["Hong Kong (香港)","hk","852"],["Hungary (Magyarország)","hu","36"],["Iceland (Ísland)","is","354"],["India (भारत)","in","91"],["Indonesia","id","62"],["Iran (‫ایران‬‎)","ir","98"],["Iraq (‫العراق‬‎)","iq","964"],["Ireland","ie","353"],["Isle of Man","im","44",2,["1624","74576","7524","7924","7624"]],["Israel (‫ישראל‬‎)","il","972"],["Italy (Italia)","it","39",0],["Jamaica","jm","1",4,["876","658"]],["Japan (日本)","jp","81"],["Jersey","je","44",3,["1534","7509","7700","7797","7829","7937"]],["Jordan (‫الأردن‬‎)","jo","962"],["Kazakhstan (Казахстан)","kz","7",1,["33","7"]],["Kenya","ke","254"],["Kiribati","ki","686"],["Kosovo","xk","383"],["Kuwait (‫الكويت‬‎)","kw","965"],["Kyrgyzstan (Кыргызстан)","kg","996"],["Laos (ລາວ)","la","856"],["Latvia (Latvija)","lv","371"],["Lebanon (‫لبنان‬‎)","lb","961"],["Lesotho","ls","266"],["Liberia","lr","231"],["Libya (‫ليبيا‬‎)","ly","218"],["Liechtenstein","li","423"],["Lithuania (Lietuva)","lt","370"],["Luxembourg","lu","352"],["Macau (澳門)","mo","853"],["North Macedonia (Македонија)","mk","389"],["Madagascar (Madagasikara)","mg","261"],["Malawi","mw","265"],["Malaysia","my","60"],["Maldives","mv","960"],["Mali","ml","223"],["Malta","mt","356"],["Marshall Islands","mh","692"],["Martinique","mq","596"],["Mauritania (‫موريتانيا‬‎)","mr","222"],["Mauritius (Moris)","mu","230"],["Mayotte","yt","262",1,["269","639"]],["Mexico (México)","mx","52"],["Micronesia","fm","691"],["Moldova (Republica Moldova)","md","373"],["Monaco","mc","377"],["Mongolia (Монгол)","mn","976"],["Montenegro (Crna Gora)","me","382"],["Montserrat","ms","1",16,["664"]],["Morocco (‫المغرب‬‎)","ma","212",0],["Mozambique (Moçambique)","mz","258"],["Myanmar (Burma) (မြန်မာ)","mm","95"],["Namibia (Namibië)","na","264"],["Nauru","nr","674"],["Nepal (नेपाल)","np","977"],["Netherlands (Nederland)","nl","31"],["New Caledonia (Nouvelle-Calédonie)","nc","687"],["New Zealand","nz","64"],["Nicaragua","ni","505"],["Niger (Nijar)","ne","227"],["Nigeria","ng","234"],["Niue","nu","683"],["Norfolk Island","nf","672"],["North Korea (조선 민주주의 인민 공화국)","kp","850"],["Northern Mariana Islands","mp","1",17,["670"]],["Norway (Norge)","no","47",0],["Oman (‫عُمان‬‎)","om","968"],["Pakistan (‫پاکستان‬‎)","pk","92"],["Palau","pw","680"],["Palestine (‫فلسطين‬‎)","ps","970"],["Panama (Panamá)","pa","507"],["Papua New Guinea","pg","675"],["Paraguay","py","595"],["Peru (Perú)","pe","51"],["Philippines","ph","63"],["Poland (Polska)","pl","48"],["Portugal","pt","351"],["Puerto Rico","pr","1",3,["787","939"]],["Qatar (‫قطر‬‎)","qa","974"],["Réunion (La Réunion)","re","262",0],["Romania (România)","ro","40"],["Russia (Россия)","ru","7",0],["Rwanda","rw","250"],["Saint Barthélemy","bl","590",1],["Saint Helena","sh","290"],["Saint Kitts and Nevis","kn","1",18,["869"]],["Saint Lucia","lc","1",19,["758"]],["Saint Martin (Saint-Martin (partie française))","mf","590",2],["Saint Pierre and Miquelon (Saint-Pierre-et-Miquelon)","pm","508"],["Saint Vincent and the Grenadines","vc","1",20,["784"]],["Samoa","ws","685"],["San Marino","sm","378"],["São Tomé and Príncipe (São Tomé e Príncipe)","st","239"],["Saudi Arabia (‫المملكة العربية السعودية‬‎)","sa","966"],["Senegal (Sénégal)","sn","221"],["Serbia (Србија)","rs","381"],["Seychelles","sc","248"],["Sierra Leone","sl","232"],["Singapore","sg","65"],["Sint Maarten","sx","1",21,["721"]],["Slovakia (Slovensko)","sk","421"],["Slovenia (Slovenija)","si","386"],["Solomon Islands","sb","677"],["Somalia (Soomaaliya)","so","252"],["South Africa","za","27"],["South Korea (대한민국)","kr","82"],["South Sudan (‫جنوب السودان‬‎)","ss","211"],["Spain (España)","es","34"],["Sri Lanka (ශ්‍රී ලංකාව)","lk","94"],["Sudan (‫السودان‬‎)","sd","249"],["Suriname","sr","597"],["Svalbard and Jan Mayen","sj","47",1,["79"]],["Sweden (Sverige)","se","46"],["Switzerland (Schweiz)","ch","41"],["Syria (‫سوريا‬‎)","sy","963"],["Taiwan (台灣)","tw","886"],["Tajikistan","tj","992"],["Tanzania","tz","255"],["Thailand (ไทย)","th","66"],["Timor-Leste","tl","670"],["Togo","tg","228"],["Tokelau","tk","690"],["Tonga","to","676"],["Trinidad and Tobago","tt","1",22,["868"]],["Tunisia (‫تونس‬‎)","tn","216"],["Turkey (Türkiye)","tr","90"],["Turkmenistan","tm","993"],["Turks and Caicos Islands","tc","1",23,["649"]],["Tuvalu","tv","688"],["U.S. Virgin Islands","vi","1",24,["340"]],["Uganda","ug","256"],["Ukraine (Україна)","ua","380"],["United Arab Emirates (‫الإمارات العربية المتحدة‬‎)","ae","971"],["United Kingdom","gb","44",0],["United States","us","1",0],["Uruguay","uy","598"],["Uzbekistan (Oʻzbekiston)","uz","998"],["Vanuatu","vu","678"],["Vatican City (Città del Vaticano)","va","39",1,["06698"]],["Venezuela","ve","58"],["Vietnam (Việt Nam)","vn","84"],["Wallis and Futuna (Wallis-et-Futuna)","wf","681"],["Western Sahara (‫الصحراء الغربية‬‎)","eh","212",1,["5288","5289"]],["Yemen (‫اليمن‬‎)","ye","967"],["Zambia","zm","260"],["Zimbabwe","zw","263"],["Åland Islands","ax","358",1,["18"]]],ea=N.reduce((e,_)=>{const T=_[1];return e[T]=_[2],e},{});var S=(e=>(e.CLOSED="Closed",e.OPEN="Open",e.COMING_SOON="Coming soon",e))(S||{});const o={PERMANENT:"Permanent",TEMPORARY:"Temporary"},A={QOL:"QoL",TASK:"Task"},_a={0:A.QOL,1:A.TASK},ia={0:o.PERMANENT,1:o.TEMPORARY},na={DATE:"date_of_questionnaire",TIME:"time_of_questionnaire"},Ea={TYPE:"type_of_questionnaire"},ta={PERSEED_ADMIN:"PerseedAdmin",ECOSYSTEM_ADMIN:"EcosystemAdmin",USER:"Users",SALE:"Sales"},ra={ADD_PATIENT:"add_patient",ADD_REPEATABLE_CRF:"add_repeat_crf",ADVANCED_FILTER:"advanced_filter",ALL_PATIENT_LIST:"all_patient_list",ALLOW_TO_CONTROL_THESE_PROFILES:"core_control_profile",CONNECTOR_ADD_CP:"connector_add_cp",CONNECTOR_ADD_CRF:"connector_add_crf",CONNECTOR_ADD_FIELD:"connector_add_field",CORE_NOT_ALLOW_ACCESS_SENSITIVE_INFO:"core_not_allow_access_sensitive_info",CORE_NOTIFICATION_LOG:"core_notification_log",CORE_NOTIFICATION_MY_LOG:"core_notification_my_log",DELETE_PATIENT:"delete_patient",FULL_DELETE_PATIENT:"full_delete_patient",DELETE_REPEATABLE_CRF:"delete_crf",EXPORT_ANONYMIZED:"export_anonymized",ENABLE_CP:"enable_cp",EXPORT_MY_HOSPITALS:"export_my_hospitals",EXPORT_NOT_ALLOW_ACCESS_SENSITIVE_INFO:"export_not_allow_access_sensitive_info",EXPORT_USER_TIMESTAMP:"export_user_timestamp",EXPORT_RAW:"export_raw",FILTER_ALL:"filter_all",FILTER_MY_HOSPITALS:"filter_my_hospitals",MANAGE_USERS:"core_manage_user",CORE_PRO_USER_SENSITIVE_INFO:"core_pro_user_sensitive_info",NOTIFICATIONS:"core_notification_seed",ONLY_MY_PATIENTS:"only_my_patients",ONLY_UPDATE_PATIENTS_API:"only_update_patients",PRO_USER:"core_pro_user",USERS_MANAGEMENT_FOR_MY_ORGANIZATIONS:"core_manage_user_hospital",UPLOAD_DOCUMENTS:"add",DELETE_DOCUMENTS:"delete",READ_DOCUMENTS:"read",DISPLAY_PATIENT_LIST:"advanced_patient_list",EXPORT_CONFIGURATION_EXPLICIT_ACCESS:"export_configurations_explicit_access_only",FOLLOWUP_DASHBOARD:"followup_dashboard",TRIGGERS_MANAGEMENT:"triggers_management"},sa=["Etc/GMT+12","Pacific/Midway","Pacific/Honolulu","America/Juneau","America/Dawson","America/Boise","America/Chihuahua","America/Phoenix","America/Chicago","America/Regina","America/Mexico_City","America/Belize","America/Detroit","America/Indiana/Indianapolis","America/Bogota","America/Glace_Bay","America/Caracas","America/Santiago","America/St_Johns","America/Sao_Paulo","America/Argentina/Buenos_Aires","America/Godthab","Etc/GMT+2","Atlantic/Azores","Atlantic/Cape_Verde","GMT","Africa/Casablanca","Atlantic/Canary","Europe/Belgrade","Europe/Sarajevo","Europe/Brussels","Europe/Amsterdam","Africa/Algiers","Europe/Bucharest","Africa/Cairo","Europe/Helsinki","Europe/Athens","Asia/Jerusalem","Africa/Harare","Europe/Moscow","Asia/Kuwait","Africa/Nairobi","Asia/Baghdad","Asia/Tehran","Asia/Dubai","Asia/Baku","Asia/Kabul","Asia/Yekaterinburg","Asia/Karachi","Asia/Kolkata","Asia/Kathmandu","Asia/Dhaka","Asia/Colombo","Asia/Almaty","Asia/Rangoon","Asia/Bangkok","Asia/Krasnoyarsk","Asia/Shanghai","Asia/Kuala_Lumpur","Asia/Taipei","Australia/Perth","Asia/Irkutsk","Asia/Seoul","Asia/Tokyo","Asia/Yakutsk","Australia/Darwin","Australia/Adelaide","Australia/Sydney","Australia/Brisbane","Australia/Hobart","Asia/Vladivostok","Pacific/Guam","Asia/Magadan","Pacific/Fiji","Pacific/Auckland","Pacific/Tongatapu"],oa=["ab","aa","af","ak","sq","am","ar","an","hy","as","av","ae","ay","az","bm","ba","eu","be","bn","bh","bi","bs","br","bg","my","ca","ch","ce","ny","zh","cv","kw","co","cr","hr","cs","da","dv","nl","dz","en","eo","et","ee","fo","fj","fi","fr","ff","gl","gd","gv","ka","de","el","kl","gn","gu","ht","ha","he","hz","hi","ho","hu","is","io","ig","id","ia","ie","iu","ik","ga","it","ja","jv","kl","kn","kr","ks","kk","km","ki","rw","rn","ky","kv","kg","ko","ku","kj","lo","la","lv","li","ln","lt","lu","lg","lb","gv","mk","mg","ms","ml","mt","mi","mr","mh","mo","mn","na","nv","ng","nd","ne","no","nb","nn","ii","oc","oj","cu","or","om","os","pi","ps","fa","pl","pt","pa","qu","rm","ro","ru","se","sm","sg","sa","sr","sh","st","tn","sn","ii","sd","si","ss","sk","sl","so","nr","es","su","sw","ss","sv","tl","ty","tg","ta","tt","te","th","bo","ti","to","ts","tr","tk","tw","ug","uk","ur","uz","ve","vi","vo","wa","cy","wo","fy","xh","ji","yo","za","zu"],Aa=["af_ZA","am_ET","ar_AE","ar_BH","ar_DZ","ar_EG","ar_IQ","ar_JO","ar_KW","ar_LB","ar_LY","ar_MA","arn_CL","ar_OM","ar_QA","ar_SA","ar_SY","ar_TN","ar_YE","as_IN","az_Cyrl_AZ","az_Latn_AZ","ba_RU","be_BY","bg_BG","bn_BD","bn_IN","bo_CN","br_FR","bs_Cyrl_BA","bs_Latn_BA","ca_ES","co_FR","cs_CZ","cy_GB","da_DK","de_AT","de_CH","de_DE","de_LI","de_LU","dsb_DE","dv_MV","el_GR","en_029","en_AU","en_BZ","en_CA","en_GB","en_IE","en_IN","en_JM","en_MY","en_NZ","en_PH","en_SG","en_TT","en_US","en_ZA","en_ZW","es_AR","es_BO","es_CL","es_CO","es_CR","es_DO","es_EC","es_ES","es_GT","es_HN","es_MX","es_NI","es_PA","es_PE","es_PR","es_PY","es_SV","es_US","es_UY","es_VE","et_EE","eu_ES","fa_IR","fi_FI","fil_PH","fo_FO","fr_BE","fr_CA","fr_CH","fr_FR","fr_LU","fr_MC","fy_NL","ga_IE","gd_GB","gl_ES","gsw_FR","gu_IN","ha_Latn_NG","he_IL","hi_IN","hr_BA","hr_HR","hsb_DE","hu_HU","hy_AM","id_ID","ig_NG","ii_CN","is_IS","it_CH","it_IT","iu_Cans_CA","iu_Latn_CA","ja_JP","ka_GE","kk_KZ","kl_GL","km_KH","kn_IN","kok_IN","ko_KR","ky_KG","lb_LU","lo_LA","lt_LT","lv_LV","mi_NZ","mk_MK","ml_IN","mn_MN","mn_Mong_CN","moh_CA","mr_IN","ms_BN","ms_MY","mt_MT","nb_NO","ne_NP","nl_BE","nl_NL","nn_NO","nso_ZA","oc_FR","or_IN","pa_IN","pl_PL","prs_AF","ps_AF","pt_BR","pt_PT","qut_GT","quz_BO","quz_EC","quz_PE","rm_CH","ro_RO","ru_RU","rw_RW","sah_RU","sa_IN","se_FI","se_NO","se_SE","si_LK","sk_SK","sl_SI","sma_NO","sma_SE","smj_NO","smj_SE","smn_FI","sms_FI","sq_AL","sr_Cyrl_BA","sr_Cyrl_CS","sr_Cyrl_ME","sr_Cyrl_RS","sr_Latn_BA","sr_Latn_CS","sr_Latn_ME","sr_Latn_RS","sv_FI","sv_SE","sw_KE","syr_SY","ta_IN","te_IN","tg_Cyrl_TJ","th_TH","tk_TM","tn_ZA","tr_TR","tt_RU","tzm_Latn_DZ","ug_CN","uk_UA","ur_PK","uz_Cyrl_UZ","uz_Latn_UZ","vi_VN","wo_SN","xh_ZA","yo_NG","zh_CN","zh_HK","zh_MO","zh_SG","zh_TW","zu_ZA","fi_FI"],Ta="forms",la="history";var d=(e=>(e.VALUECARD="ValueCard",e.SECTIONCARD="SectionCard",e.PATIENTLIST="PatientList",e.DASHBOARD="Dashboard",e))(d||{}),c=(e=>(e.OUTCOMES="outcomes",e))(c||{}),R=(e=>(e.QUESTIONNAIRE_CREATE="questionnaire.create",e.CRF_CREATE="crf.create",e.CRF_UPDATE="crf.update",e.CRF_DELETE="crf.delete",e.EXTERNAL_API_CALL="external_api_call",e))(R||{}),m=(e=>(e.JSON_LOGIC="jsonLogic",e.CUSTOM="custom",e))(m||{}),i=(e=>(e.CREATION="creation",e.UPDATE="update",e))(i||{}),O=(e=>(e.TEXT="text",e.DATE="date",e.TIME="time",e.BOOLEAN="boolean",e.NUMBER="number",e.SELECT="select",e.MULTISELECT="multiselect",e.HIDDEN="hidden",e))(O||{});class Ia{constructor(_){this.notified_about=_}crfName(){return this.notified_about.startsWith("crf_")?this.notified_about.split("_")[1]:this.notified_about.startsWith("Patient")?"patient":null}actionTrigger(){return this.notified_about.toLowerCase().endsWith(i.UPDATE)?i.UPDATE:this.notified_about.toLowerCase().endsWith(i.CREATION)?i.CREATION:null}isCrfTrigger(){return this.notified_about===L||this.notified_about.startsWith("crf_")}isModelTrigger(){return this.notified_about.startsWith("model_")}isDisplayerTrigger(){return this.notified_about.startsWith("model_displayer_")}isFieldTrigger(){return!isNaN(parseInt(this.notified_about))}getModelName(){if(this.isModelTrigger()&&!this.isDisplayerTrigger())return this.notified_about.split("_")[1];if(this.isDisplayerTrigger()){const _=this.notified_about.split("_"),T=_[_.length-1];return Object.values(i).includes(T)&&_.pop(),_.slice(2).join("_")}}getModelTriggerAction(){const _=this.getModelName();return _&&this.isDisplayerTrigger()?this.notified_about.replace(`model_displayer_${_}_`,"").replace(`model_displayer_${_}`,""):_&&this.isModelTrigger()?this.notified_about.replace(`model_${_}_`,"").replace(`model_${_}`,""):null}}const L="Patient Creation";var M=(e=>(e[e.START_OVER=0]="START_OVER",e[e.RESUME=1]="RESUME",e))(M||{});a.AUDIT_FLAGS=v,a.ApiAction=R,a.CORE=I,a.ConditionsFormat=m,a.CountryPhoneCodes=ea,a.DATETIME_SHORT_FORMAT=g,a.DATE_FORMAT=n,a.DATE_TYPE=b,a.DEFAULT_CONFIGURATION_PATIENT_LIST=x,a.DYNAMIC_FILE_VALID_FORMATS=$,a.DataLoaderType=c,a.EXCLUDE_FIELDS=y,a.Exporter=h,a.FIELDS=r,a.FIELD_NAMES=E,a.FIELD_NAMES_MAP=U,a.FIELD_STATUS=w,a.FIELD_SUFFIX=G,a.FORMS_VIEW=Ta,a.FORM_NAMES=k,a.FORM_SUFFIX=Y,a.FORM_TYPES=l,a.HISTORY=o,a.HISTORY_TYPE_OPTIONS=ia,a.HISTORY_VIEW=la,a.HREF_TYPE=J,a.IntrospectionSchemaFieldType=O,a.LANG_CODES=oa,a.LOCALE_LANG_CODES=Aa,a.META_NAMES=q,a.META_RESTRICTION=j,a.META_STATUS=W,a.MINIMIAL_TIMEZONE_LIST=sa,a.MULTIPLE_SELECTION_SEPARATOR=B,a.MYSQL_DATETIME_FORMAT=P,a.MYSQL_DATE_FORMAT=f,a.NOTIFIED_TYPES=aa,a.NO_FILL_STATUS=V,a.NUMBER_TYPE=p,a.NotifiedAboutInfo=Ia,a.OBJECT_TYPE=F,a.PATIENT_CREATION_ABOUT=L,a.QUESTIONNAIRE_DATE=na,a.QUESTIONNAIRE_TYPE=Ea,a.QUESTIONNAIRE_TYPE_OPTIONS=_a,a.QuestionnaireInfoUpdateMode=M,a.ROLES=ta,a.SEED_PRIVILEGE=ra,a.SELECTOR_TYPE=Q,a.SHORT_TIME_FORMAT=D,a.SLIDER_SCALE_ORIENTATION_TYPE=Z,a.SLIDER_SCALE_TYPE=s,a.SLIDER_SELECTOR_TYPE=X,a.SLIDER_TYPE=t,a.STATUS=S,a.STATUS_FIELD_REGEXP=u,a.STATUS_SUFFIX=H,a.TIME_FORMAT=C,a.TIME_SCHEMA=K,a.TYPE=A,a.TriggerAction=i,a.WidgetType=d,a.allCountries=N,a.isNotStatusField=z,Object.defineProperty(a,Symbol.toStringTag,{value:"Module"})});
@@ -1,42 +1,8 @@
1
1
  {
2
2
  "$schema": "http://json-schema.org/draft-07/schema#",
3
- "$ref": "#/definitions/CreateDashboardPayload",
3
+ "$ref": "#/definitions/CreateWidgetPayload",
4
4
  "definitions": {
5
- "CreateDashboardPayload": {
6
- "type": "object",
7
- "properties": {
8
- "title": {
9
- "type": "string"
10
- },
11
- "active": {
12
- "type": "boolean"
13
- },
14
- "config": {
15
- "$ref": "#/definitions/DashboardConfig"
16
- },
17
- "icon": {
18
- "type": ["string", "null"]
19
- },
20
- "weight": {
21
- "type": "number"
22
- }
23
- },
24
- "required": ["title"],
25
- "additionalProperties": false
26
- },
27
- "DashboardConfig": {
28
- "type": "object",
29
- "properties": {
30
- "widgets": {
31
- "type": "array",
32
- "items": {
33
- "$ref": "#/definitions/Widget"
34
- }
35
- }
36
- },
37
- "additionalProperties": false
38
- },
39
- "Widget": {
5
+ "CreateWidgetPayload": {
40
6
  "anyOf": [
41
7
  {
42
8
  "type": "object",
@@ -49,6 +15,15 @@
49
15
  "params": {
50
16
  "$ref": "#/definitions/SectionCardProps"
51
17
  },
18
+ "title": {
19
+ "type": "string"
20
+ },
21
+ "description": {
22
+ "type": "string"
23
+ },
24
+ "weight": {
25
+ "type": "number"
26
+ },
52
27
  "size": {
53
28
  "anyOf": [
54
29
  {
@@ -60,7 +35,7 @@
60
35
  ]
61
36
  }
62
37
  },
63
- "required": ["params", "type"]
38
+ "required": ["params", "title", "type"]
64
39
  },
65
40
  {
66
41
  "type": "object",
@@ -73,6 +48,15 @@
73
48
  "params": {
74
49
  "$ref": "#/definitions/ValueCardProps"
75
50
  },
51
+ "title": {
52
+ "type": "string"
53
+ },
54
+ "description": {
55
+ "type": "string"
56
+ },
57
+ "weight": {
58
+ "type": "number"
59
+ },
76
60
  "size": {
77
61
  "anyOf": [
78
62
  {
@@ -84,7 +68,7 @@
84
68
  ]
85
69
  }
86
70
  },
87
- "required": ["params", "type"]
71
+ "required": ["params", "title", "type"]
88
72
  },
89
73
  {
90
74
  "type": "object",
@@ -97,6 +81,48 @@
97
81
  "params": {
98
82
  "$ref": "#/definitions/PatientListProps"
99
83
  },
84
+ "title": {
85
+ "type": "string"
86
+ },
87
+ "description": {
88
+ "type": "string"
89
+ },
90
+ "weight": {
91
+ "type": "number"
92
+ },
93
+ "size": {
94
+ "anyOf": [
95
+ {
96
+ "type": "number"
97
+ },
98
+ {
99
+ "$ref": "#/definitions/ColProps"
100
+ }
101
+ ]
102
+ }
103
+ },
104
+ "required": ["params", "title", "type"]
105
+ },
106
+ {
107
+ "type": "object",
108
+ "additionalProperties": false,
109
+ "properties": {
110
+ "type": {
111
+ "type": "string",
112
+ "const": "Dashboard"
113
+ },
114
+ "params": {
115
+ "$ref": "#/definitions/DashboardProps"
116
+ },
117
+ "title": {
118
+ "type": "string"
119
+ },
120
+ "description": {
121
+ "type": "string"
122
+ },
123
+ "weight": {
124
+ "type": "number"
125
+ },
100
126
  "size": {
101
127
  "anyOf": [
102
128
  {
@@ -108,7 +134,7 @@
108
134
  ]
109
135
  }
110
136
  },
111
- "required": ["params", "type"]
137
+ "required": ["params", "title", "type"]
112
138
  }
113
139
  ]
114
140
  },
@@ -130,7 +156,7 @@
130
156
  "widgets": {
131
157
  "type": "array",
132
158
  "items": {
133
- "$ref": "#/definitions/Widget"
159
+ "type": "number"
134
160
  }
135
161
  }
136
162
  },
@@ -533,6 +559,26 @@
533
559
  }
534
560
  },
535
561
  "additionalProperties": false
562
+ },
563
+ "DashboardProps": {
564
+ "type": "object",
565
+ "properties": {
566
+ "title": {
567
+ "type": "string"
568
+ },
569
+ "active": {
570
+ "type": "boolean"
571
+ },
572
+ "config": {},
573
+ "icon": {
574
+ "type": ["string", "null"]
575
+ },
576
+ "weight": {
577
+ "type": "number"
578
+ }
579
+ },
580
+ "required": ["title"],
581
+ "additionalProperties": false
536
582
  }
537
583
  }
538
584
  }
@@ -1,163 +1,68 @@
1
1
  {
2
2
  "$schema": "http://json-schema.org/draft-07/schema#",
3
- "$ref": "#/definitions/UpdateDashboardPayload",
3
+ "$ref": "#/definitions/UpdateWidgetPayload",
4
4
  "definitions": {
5
- "UpdateDashboardPayload": {
5
+ "UpdateWidgetPayload": {
6
6
  "type": "object",
7
7
  "properties": {
8
8
  "title": {
9
9
  "type": "string"
10
10
  },
11
- "active": {
12
- "type": "boolean"
13
- },
14
- "config": {
15
- "$ref": "#/definitions/DashboardConfig"
16
- },
17
- "icon": {
18
- "type": ["string", "null"]
11
+ "description": {
12
+ "type": "string"
19
13
  },
20
14
  "weight": {
21
15
  "type": "number"
22
- }
23
- },
24
- "additionalProperties": false
25
- },
26
- "DashboardConfig": {
27
- "type": "object",
28
- "properties": {
29
- "widgets": {
30
- "type": "array",
31
- "items": {
32
- "$ref": "#/definitions/Widget"
33
- }
34
- }
35
- },
36
- "additionalProperties": false
37
- },
38
- "Widget": {
39
- "anyOf": [
40
- {
41
- "type": "object",
42
- "additionalProperties": false,
43
- "properties": {
44
- "type": {
45
- "type": "string",
46
- "const": "SectionCard"
47
- },
48
- "params": {
49
- "$ref": "#/definitions/SectionCardProps"
16
+ },
17
+ "size": {
18
+ "anyOf": [
19
+ {
20
+ "type": "number"
50
21
  },
51
- "size": {
52
- "anyOf": [
53
- {
54
- "type": "number"
55
- },
56
- {
57
- "$ref": "#/definitions/ColProps"
58
- }
59
- ]
22
+ {
23
+ "$ref": "#/definitions/ColProps"
60
24
  }
61
- },
62
- "required": ["params", "type"]
25
+ ]
63
26
  },
64
- {
65
- "type": "object",
66
- "additionalProperties": false,
67
- "properties": {
68
- "type": {
27
+ "type": {
28
+ "anyOf": [
29
+ {
30
+ "type": "string",
31
+ "const": "SectionCard"
32
+ },
33
+ {
69
34
  "type": "string",
70
35
  "const": "ValueCard"
71
36
  },
72
- "params": {
73
- "$ref": "#/definitions/ValueCardProps"
37
+ {
38
+ "type": "string",
39
+ "const": "PatientList"
74
40
  },
75
- "size": {
76
- "anyOf": [
77
- {
78
- "type": "number"
79
- },
80
- {
81
- "$ref": "#/definitions/ColProps"
82
- }
83
- ]
41
+ {
42
+ "type": "string",
43
+ "const": "Dashboard"
84
44
  }
85
- },
86
- "required": ["params", "type"]
45
+ ]
87
46
  },
88
- {
89
- "type": "object",
90
- "additionalProperties": false,
91
- "properties": {
92
- "type": {
93
- "type": "string",
94
- "const": "PatientList"
47
+ "params": {
48
+ "anyOf": [
49
+ {
50
+ "$ref": "#/definitions/SectionCardProps"
51
+ },
52
+ {
53
+ "$ref": "#/definitions/ValueCardProps"
95
54
  },
96
- "params": {
55
+ {
97
56
  "$ref": "#/definitions/PatientListProps"
98
57
  },
99
- "size": {
100
- "anyOf": [
101
- {
102
- "type": "number"
103
- },
104
- {
105
- "$ref": "#/definitions/ColProps"
106
- }
107
- ]
58
+ {
59
+ "$ref": "#/definitions/DashboardProps"
108
60
  }
109
- },
110
- "required": ["params", "type"]
111
- }
112
- ]
113
- },
114
- "SectionCardProps": {
115
- "type": "object",
116
- "properties": {
117
- "icon": {
118
- "type": "string"
119
- },
120
- "background": {
121
- "type": "string"
122
- },
123
- "titleBackground": {
124
- "type": "string"
125
- },
126
- "title": {
127
- "$ref": "#/definitions/I18nTextTranslation"
128
- },
129
- "widgets": {
130
- "type": "array",
131
- "items": {
132
- "$ref": "#/definitions/Widget"
133
- }
61
+ ]
134
62
  }
135
63
  },
136
- "required": ["icon", "title", "widgets"],
137
64
  "additionalProperties": false
138
65
  },
139
- "I18nTextTranslation": {
140
- "anyOf": [
141
- {
142
- "$ref": "#/definitions/I18nTextLocales"
143
- },
144
- {
145
- "type": "string"
146
- }
147
- ]
148
- },
149
- "I18nTextLocales": {
150
- "type": "object",
151
- "properties": {
152
- "default": {
153
- "type": "string"
154
- }
155
- },
156
- "required": ["default"],
157
- "additionalProperties": {
158
- "type": "string"
159
- }
160
- },
161
66
  "ColProps": {
162
67
  "type": "object",
163
68
  "properties": {
@@ -290,6 +195,53 @@
290
195
  },
291
196
  "additionalProperties": false
292
197
  },
198
+ "SectionCardProps": {
199
+ "type": "object",
200
+ "properties": {
201
+ "icon": {
202
+ "type": "string"
203
+ },
204
+ "background": {
205
+ "type": "string"
206
+ },
207
+ "titleBackground": {
208
+ "type": "string"
209
+ },
210
+ "title": {
211
+ "$ref": "#/definitions/I18nTextTranslation"
212
+ },
213
+ "widgets": {
214
+ "type": "array",
215
+ "items": {
216
+ "type": "number"
217
+ }
218
+ }
219
+ },
220
+ "required": ["icon", "title", "widgets"],
221
+ "additionalProperties": false
222
+ },
223
+ "I18nTextTranslation": {
224
+ "anyOf": [
225
+ {
226
+ "$ref": "#/definitions/I18nTextLocales"
227
+ },
228
+ {
229
+ "type": "string"
230
+ }
231
+ ]
232
+ },
233
+ "I18nTextLocales": {
234
+ "type": "object",
235
+ "properties": {
236
+ "default": {
237
+ "type": "string"
238
+ }
239
+ },
240
+ "required": ["default"],
241
+ "additionalProperties": {
242
+ "type": "string"
243
+ }
244
+ },
293
245
  "ValueCardProps": {
294
246
  "type": "object",
295
247
  "properties": {
@@ -532,6 +484,26 @@
532
484
  }
533
485
  },
534
486
  "additionalProperties": false
487
+ },
488
+ "DashboardProps": {
489
+ "type": "object",
490
+ "properties": {
491
+ "title": {
492
+ "type": "string"
493
+ },
494
+ "active": {
495
+ "type": "boolean"
496
+ },
497
+ "config": {},
498
+ "icon": {
499
+ "type": ["string", "null"]
500
+ },
501
+ "weight": {
502
+ "type": "number"
503
+ }
504
+ },
505
+ "required": ["title"],
506
+ "additionalProperties": false
535
507
  }
536
508
  }
537
509
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@persei/perseed-api",
3
- "version": "4.34.15",
3
+ "version": "4.34.16",
4
4
  "private": false,
5
5
  "main": "./dist/perseed-api.umd.js",
6
6
  "module": "./dist/perseed-api.mjs",