primary_care_admin_binder 0.1.24 → 0.1.25

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 (2) hide show
  1. package/dist/index.cjs.js +26 -16
  2. package/package.json +1 -1
package/dist/index.cjs.js CHANGED
@@ -8050,7 +8050,8 @@ var queries$n = {
8050
8050
  db_name: dbName,
8051
8051
  entity: "CodeableConceptMaster",
8052
8052
  filter: "CodeableConceptMaster.Type=='".concat(type, "'"),
8053
- return_fields: "MERGE(CodeableConceptMaster,{coding:(FOR cod IN CodeableConceptMaster.coding RETURN DOCUMENT(cod))})"
8053
+ return_fields: "MERGE(CodeableConceptMaster,{coding:(FOR cod IN CodeableConceptMaster.coding RETURN DOCUMENT(cod))})",
8054
+ sort: "CodeableConceptMaster.createddate"
8054
8055
  };
8055
8056
  },
8056
8057
  upsert: function upsert(data) {
@@ -19142,13 +19143,15 @@ var generateSaveJSON = function generateSaveJSON(data) {
19142
19143
 
19143
19144
  var getAvailability = function getAvailability(data) {
19144
19145
  var arr = data.map(function (v) {
19146
+ var _v$entity_name$value, _v$entity_name, _v$appointment, _parseInt, _v$entity_type$value, _v$entity_type;
19147
+
19145
19148
  return {
19146
- perforganizationId: v.entity_name.value,
19147
- apptreqd: v.appointment,
19148
- apptDurnInMinutes: parseInt(v.duration),
19149
- perfOrganizationEntity: v.entity_type.value,
19150
- EffFrDate: v.effective_from ? getUtcTime(moment(v.effective_from)) : null,
19151
- EffToDate: v.effective_to ? getUtcTime(moment(v.effective_to)) : null
19149
+ perforganizationId: (_v$entity_name$value = v === null || v === void 0 ? void 0 : (_v$entity_name = v.entity_name) === null || _v$entity_name === void 0 ? void 0 : _v$entity_name.value) !== null && _v$entity_name$value !== void 0 ? _v$entity_name$value : null,
19150
+ apptreqd: (_v$appointment = v === null || v === void 0 ? void 0 : v.appointment) !== null && _v$appointment !== void 0 ? _v$appointment : false,
19151
+ apptDurnInMinutes: (_parseInt = parseInt(v.duration)) !== null && _parseInt !== void 0 ? _parseInt : null,
19152
+ perfOrganizationEntity: (_v$entity_type$value = v === null || v === void 0 ? void 0 : (_v$entity_type = v.entity_type) === null || _v$entity_type === void 0 ? void 0 : _v$entity_type.value) !== null && _v$entity_type$value !== void 0 ? _v$entity_type$value : null,
19153
+ EffFrDate: v !== null && v !== void 0 && v.effective_from ? getUtcTime(moment(v.effective_from, "DD/MM/YYYY")) : null,
19154
+ EffToDate: v !== null && v !== void 0 && v.effective_to ? getUtcTime(moment(v === null || v === void 0 ? void 0 : v.effective_to, "DD/MM/YYYY")) : null
19152
19155
  };
19153
19156
  });
19154
19157
  return arr;
@@ -19520,6 +19523,8 @@ var generateFrequency = function generateFrequency(data, state) {
19520
19523
 
19521
19524
  var generatefaciltity = function generatefaciltity(data, state) {
19522
19525
  var facilityArr = data.map(function (v) {
19526
+ var _v$apptreqd, _v$apptDurnInMinutes;
19527
+
19523
19528
  return {
19524
19529
  entity_type: v.perfOrganizationEntity && v.perfOrganizationEntity._id ? state.order_catalog_masters.data.entityType.find(function (sys) {
19525
19530
  return v.perfOrganizationEntity._id.indexOf(sys.value) > -1;
@@ -19533,10 +19538,10 @@ var generatefaciltity = function generatefaciltity(data, state) {
19533
19538
  label: v.perforganizationId.name,
19534
19539
  value: v.perforganizationId._id
19535
19540
  } : null,
19536
- appointment: v.apptreqd,
19537
- duration: v.apptDurnInMinutes,
19538
- effective_from: new Date(utcTOLocal(v.EffFrDate)).toLocaleDateString(),
19539
- effective_to: new Date(utcTOLocal(v.EffToDate)).toLocaleDateString()
19541
+ appointment: (_v$apptreqd = v === null || v === void 0 ? void 0 : v.apptreqd) !== null && _v$apptreqd !== void 0 ? _v$apptreqd : false,
19542
+ duration: (_v$apptDurnInMinutes = v === null || v === void 0 ? void 0 : v.apptDurnInMinutes) !== null && _v$apptDurnInMinutes !== void 0 ? _v$apptDurnInMinutes : "",
19543
+ effective_from: v !== null && v !== void 0 && v.EffFrDate ? new Date(utcTOLocal(v.EffFrDate)).toLocaleDateString() : "",
19544
+ effective_to: v !== null && v !== void 0 && v.EffToDate ? new Date(utcTOLocal(v.EffToDate)).toLocaleDateString() : ""
19540
19545
  };
19541
19546
  });
19542
19547
  return facilityArr;
@@ -24151,7 +24156,8 @@ var queries$b = {
24151
24156
  db_name: dbName,
24152
24157
  entity: "LevelOfCare",
24153
24158
  filter: "LevelOfCare.activestatus==true",
24154
- return_fields: "{id:LevelOfCare.id,_id:LevelOfCare._id,levelofcareCode:LevelOfCare.levelofcareCode,description:LevelOfCare.description,careType:document(LevelOfCare.careType),active:LevelOfCare.active,key:LevelOfCare._key}"
24159
+ return_fields: "{id:LevelOfCare.id,_id:LevelOfCare._id,levelofcareCode:LevelOfCare.levelofcareCode,description:LevelOfCare.description,careType:document(LevelOfCare.careType),active:LevelOfCare.active,key:LevelOfCare._key}",
24160
+ sort: "LevelOfCare.createddate"
24155
24161
  };
24156
24162
  },
24157
24163
  levelOfCareSinleRead: function levelOfCareSinleRead(key) {
@@ -24208,7 +24214,8 @@ var queries$b = {
24208
24214
  db_name: dbName,
24209
24215
  entity: "HealthcareService",
24210
24216
  filter: "HealthcareService.activestatus==true",
24211
- return_fields: " {id:HealthcareService.id,_id:HealthcareService._id,_key:HealthcareService._key,active:HealthcareService.active,comment:HealthcareService.comment,SpecialtyID:document(HealthcareService.SpecialtyID),healthcareservicecode:HealthcareService.healthcareservicecode,name:HealthcareService.name,notes:HealthcareService.notes,category:document(HealthcareService.category),Type:document(HealthcareService.Type),applicablefacilities:HealthcareService.applicablefacilities ==null?null :(for hs in TO_ARRAY( HealthcareService.applicablefacilities) return {facility:document(hs.facility),locationtype:document(hs.locationtype),locationid:document(hs.locationid)})}"
24217
+ return_fields: " {id:HealthcareService.id,_id:HealthcareService._id,_key:HealthcareService._key,active:HealthcareService.active,comment:HealthcareService.comment,SpecialtyID:document(HealthcareService.SpecialtyID),healthcareservicecode:HealthcareService.healthcareservicecode,name:HealthcareService.name,notes:HealthcareService.notes,category:document(HealthcareService.category),Type:document(HealthcareService.Type),applicablefacilities:HealthcareService.applicablefacilities ==null?null :(for hs in TO_ARRAY( HealthcareService.applicablefacilities) return {facility:document(hs.facility),locationtype:document(hs.locationtype),locationid:document(hs.locationid)})}",
24218
+ sort: "HealthcareService.createddate"
24212
24219
  };
24213
24220
  },
24214
24221
  //HEALTH CARE SERVICE STATUS CHANGE
@@ -29602,7 +29609,8 @@ var query$5 = {
29602
29609
  db_name: "".concat(dbName),
29603
29610
  entity: "CA_OrderSet",
29604
29611
  filter: "CA_OrderSet.activestatus == true",
29605
- return_fields: "keep(CA_OrderSet,'id','_key','_id','longDesc','shortDesc','orderSetCode','status')"
29612
+ return_fields: "keep(CA_OrderSet,'id','_key','_id','longDesc','shortDesc','orderSetCode','status')",
29613
+ sort: "CA_OrderSet.createddate"
29606
29614
  };
29607
29615
  },
29608
29616
  orderSetListById: function orderSetListById(_key) {
@@ -31681,7 +31689,8 @@ var query$3 = {
31681
31689
  offset: page,
31682
31690
  count: perpage
31683
31691
  },
31684
- return_fields: "{TotalCount:COUNT(AllergyMaster),AllergyMaster:merge(AllergyMaster,{extsystemsourceid:document(AllergyMaster.extsystemsourceid)},{conceptidtype:document(AllergyMaster.conceptidtype)},{allergytypeind:document(AllergyMaster.allergytypeind)})}"
31692
+ return_fields: "{TotalCount:COUNT(AllergyMaster),AllergyMaster:merge(AllergyMaster,{extsystemsourceid:document(AllergyMaster.extsystemsourceid)},{conceptidtype:document(AllergyMaster.conceptidtype)},{allergytypeind:document(AllergyMaster.allergytypeind)})}" // sort: "AllergyMaster.createddate"
31693
+
31685
31694
  };
31686
31695
  }
31687
31696
  };
@@ -35576,7 +35585,8 @@ var queries$1 = {
35576
35585
  db_name: dbName,
35577
35586
  entity: "SymptomsMapping",
35578
35587
  filter: "SymptomsMapping.activestatus==true",
35579
- return_fields: "merge(SymptomsMapping,{specialty:(FOR cod IN CodeableConceptMaster filter cod._id in SymptomsMapping.specialty RETURN merge(cod,{coding:document(cod.coding)}))})"
35588
+ return_fields: "merge(SymptomsMapping,{specialty:(FOR cod IN CodeableConceptMaster filter cod._id in SymptomsMapping.specialty RETURN merge(cod,{coding:document(cod.coding)}))})",
35589
+ sort: "SymptomsMapping.createddate"
35580
35590
  };
35581
35591
  },
35582
35592
  symptom_and_specialty_single_read: function symptom_and_specialty_single_read(_key) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "primary_care_admin_binder",
3
- "version": "0.1.24",
3
+ "version": "0.1.25",
4
4
  "description": "",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.esm.js",