浏览代码

Merge branch 'dev' into dev-vj

Vijayakrishnan 3 年之前
父节点
当前提交
156e63336b

+ 0 - 2
.env-example

@@ -53,5 +53,3 @@ AUTH_URL="http://localhost:3002"
 BACKEND_WS_URL=http://localhost:8080/ws
 AGORA_APPID=9d04292b03524927a8fe9d937a448d85
 AGORA_MODE=screen
-
-ENABLE_SOCKETS=false

+ 0 - 63
.env.example

@@ -1,63 +0,0 @@
-APP_NAME=Stag
-APP_ENV=local
-APP_KEY=base64:1yKRgeLWTeEXTfh51vXtJaf6GJaRUn4NHzdlOdyDpRY=
-APP_DEBUG=true
-APP_URL=http://localhost
-
-LOG_CHANNEL=stack
-
-DB_CONNECTION=pgsql
-DB_HOST=127.0.0.1
-DB_PORT=5432
-DB_DATABASE=stag2
-DB_USERNAME=postgres
-DB_PASSWORD=pass
-
-DB_HOST_FDB=127.0.0.1
-DB_PORT_FDB=5432
-DB_DATABASE_FDB=fdb
-DB_USERNAME_FDB=postgres
-DB_PASSWORD_FDB=password
-
-BROADCAST_DRIVER=log
-CACHE_DRIVER=file
-QUEUE_CONNECTION=sync
-SESSION_DRIVER=file
-SESSION_LIFETIME=120
-
-REDIS_HOST=127.0.0.1
-REDIS_PASSWORD=null
-REDIS_PORT=6379
-
-MAIL_MAILER=smtp
-MAIL_HOST=smtp.mailtrap.io
-MAIL_PORT=2525
-MAIL_USERNAME=null
-MAIL_PASSWORD=null
-MAIL_ENCRYPTION=null
-MAIL_FROM_ADDRESS=null
-MAIL_FROM_NAME="${APP_NAME}"
-
-AWS_ACCESS_KEY_ID=
-AWS_SECRET_ACCESS_KEY=
-AWS_DEFAULT_REGION=us-east-1
-AWS_BUCKET=
-
-PUSHER_APP_ID=
-PUSHER_APP_KEY=
-PUSHER_APP_SECRET=
-PUSHER_APP_CLUSTER=mt1
-
-MIX_PUSHER_APP_KEY="${PUSHER_APP_KEY}"
-MIX_PUSHER_APP_CLUSTER="${PUSHER_APP_CLUSTER}"
-
-BACKEND_URL="http://localhost:8080/api"
-ADMIN_PORTAL_URL="http://localhost:3000"
-
-AUTH_URL="http://localhost:3002"
-
-BACKEND_WS_URL=http://localhost:8080/ws
-AGORA_APPID=9d04292b03524927a8fe9d937a448d85
-AGORA_MODE=screen
-
-ENABLE_SOCKETS=false

+ 7 - 6
app/Http/Controllers/HomeController.php

@@ -462,11 +462,11 @@ WHERE
         note.ally_pro_id = :pro_id AND
         note.is_cancelled = FALSE AND
         (
-            SELECT count(bill.id) 
-            FROM bill 
-            WHERE 
-                  bill.is_cancelled = FALSE AND 
-                  bill.generic_pro_id = :pro_id AND 
+            SELECT count(bill.id)
+            FROM bill
+            WHERE
+                  bill.is_cancelled = FALSE AND
+                  bill.generic_pro_id = :pro_id AND
                   bill.note_id = note.id
         ) = 0
         "), ["pro_id" => $performerProID]);
@@ -640,6 +640,7 @@ FROM measurement
 WHERE measurement.label NOT IN ('SBP', 'DBP')
   AND (measurement.is_cellular_zero = FALSE or measurement.is_cellular_zero IS NULL)
   AND measurement.is_removed IS FALSE
+  AND measurement.has_been_stamped_by_mcp IS FALSE
   AND measurement.ts IS NOT NULL
   AND measurement.client_bdt_measurement_id IS NOT NULL
   AND (measurement.status IS NULL OR (measurement.status <> 'ACK' AND measurement.status <> 'INVALID_ACK'))
@@ -999,7 +1000,7 @@ WHERE measurement.label NOT IN ('SBP', 'DBP')
     }
 
     public function logInAs(Request $request)
-    {   
+    {
         if($this->pro->pro_type != 'ADMIN'){
             return redirect()->to(route('dashboard'));
         }

+ 1 - 1
app/Http/Controllers/PracticeManagementController.php

@@ -1648,7 +1648,7 @@ ORDER BY claim.created_at DESC
             // TODO
         }
 
-        $notes = $notes->orderBy('effective_dateest')->paginate();
+        $notes = $notes->orderBy('effective_dateest')->paginate(10);
 
         return  view('app.practice-management.notes-processing-center', compact('notes'));
     }

+ 1 - 1
resources/views/app/patient/canvas-sections/fhx/summary.php

@@ -47,7 +47,7 @@ $labels = [
     'cancer_uterine_ca' => 'Uterine cancer',
 ];
 
-if(!$contentData['unknown'] && !!$contentData['count']) {
+if((isset($contentData['unknown']) && !$contentData['unknown']) && !!$contentData['count']) {
     for ($i = 0; $i < $contentData['count']; $i++) {
 ?>
         <div class="<?= $i > 0 ? 'mt-2' : '' ?>">

+ 1 - 0
resources/views/app/patient/note/dashboard.blade.php

@@ -355,6 +355,7 @@
                                         </div>
                                     </form>
                                 </span>
+                                @endif
                                 @endif--}}
                             </div>
                         @endif

+ 198 - 0
spec/9-8-clientrmspec.txt

@@ -0,0 +1,198 @@
+@Embeddable
+	@Data
+	public class RmSetupValue {
+		Boolean hasRmSetupBeenPerformed = Boolean.FALSE;
+		@ManyToOne(fetch = FetchType.LAZY)
+		CareMonth rmSetupCareMonth;
+	}
+
+	@Embedded
+	@Setter
+	RmSetupValue rmSetupValueValue;
+
+	@Embeddable
+	@Data
+	public class RmEligibilityValue {
+		@Enumerated(EnumType.STRING)
+		YesNoOrUnknown isEligibleForRm = YesNoOrUnknown.UNKNOWN;
+		String whyEligibleForRmCategory;
+		String whyEligibleForRmMemo;
+		String whyNotEligibleForRmCategory;
+		String whyNotEligibleForRmMemo;
+	}
+
+	@Embedded
+	@Setter
+	RmEligibilityValue rmEligibilityValue;
+
+	@Embeddable
+	@Data
+	public class RmCurrentlyEnrolledValue {
+		@Enumerated(EnumType.STRING)
+		YesNoOrUnknown isCurrentlyEnrolledInRm = YesNoOrUnknown.UNKNOWN;
+		String whyNotEnrolledInRmCategory;
+		String whyNotEnrolledInRmMemo;
+	}
+
+	@Embedded
+	@Setter
+	RmCurrentlyEnrolledValue rmCurrentlyEnrolledValue;
+
+	////
+
+	Boolean sendSmsOnBdtMeasurement = false;
+
+	public void setSendSmsOnBdtMeasurementToTrue(AppSession performer) {
+		this.sendSmsOnBdtMeasurement = true;
+	}
+
+	public void setSendSmsOnBdtMeasurementToFalse(AppSession performer) {
+		this.sendSmsOnBdtMeasurement = false;
+	}
+
+	/*
+	 * ... BMI
+	 */
+
+	@Embedded
+	@Setter
+	BmiManagementSettingsValue bmiManagementValue;
+
+	@Embeddable
+	public class MostRecentWeightValue {
+		Double mostRecentWeight;
+		ZonedDateTime mostRecentWeightAt;
+		@OneToOne
+		Measurement mostRecentWeightMeasurement;
+	}
+
+	@Embedded
+	@Setter
+	MostRecentWeightValue mostRecentWeightValue;
+
+	@Embeddable
+	@Data
+	public class DedicatedCellularScaleValue {
+		// @JK maintained in service
+		@OneToOne
+		SupplyOrder dedicatedCellularScaleSupplyOrder;
+		@OneToOne(cascade = CascadeType.ALL, orphanRemoval = false)
+		ClientBDTDevice dedicatedCellularScaleClientBdtDevice;
+		@Enumerated(EnumType.STRING)
+		YesNoOrUnknown hasDedicatedCellularScaleBeenDelivered;
+		ZonedDateTime dedicatedCellularScaleDeliveryReportedAt;
+		String dedicatedCellularScaleDeliveryMemo;
+		@Enumerated(EnumType.STRING)
+		YesNoOrUnknown hasClientConfirmedReceiptOfDedicatedCellularScale;
+		String clientConfirmedReceiptOfDedicatedCellularScaleMemo;
+		@OneToOne
+		Measurement firstDedicatedCellularScaleMeasurement;
+		@OneToOne
+		Measurement mostRecentDedicatedCellularScaleMeasurement;
+	}
+
+	@Embedded
+	DedicatedCellularScaleValue dedicatedCellularScaleValue;
+
+	@OneToOne(cascade = CascadeType.ALL, orphanRemoval = false)
+	Status clientIntentForCellularScaleStatus;
+
+	@OneToOne(cascade = CascadeType.ALL, orphanRemoval = false)
+	Status mcpExpectationForCellularScaleStatus;
+
+	@OneToOne(cascade = CascadeType.ALL, orphanRemoval = false)
+	Status defaultNaExpectationForCellularScaleStatus;
+
+	/*
+	 * ... BP
+	 */
+
+	@Embedded
+	@Setter
+	BpManagementSettingsValue bpManagementValue;
+
+	@Embeddable
+	@Data
+	public class MostRecentBpValue {
+
+		Double mostRecentSbp;
+		Double mostRecentDbp;
+		Double mostRecentPulse;
+		ZonedDateTime mostRecentBpAt;
+		@OneToOne
+		Measurement mostRecentBpMeasurement;
+
+	}
+
+	@Embedded
+	@Setter
+	MostRecentBpValue mostRecentBPValue;
+
+	@Embeddable
+	@Data
+	public class DedicatedCellularBpValue {
+		// @JK maintained in service
+		@OneToOne
+		SupplyOrder dedicatedCellularBpSupplyOrder;
+		@OneToOne
+		ClientBDTDevice dedicatedCellularBpClientBdtDevice;
+		@Enumerated(EnumType.STRING)
+		YesNoOrUnknown hasDedicatedCellularBpBeenDelivered;
+		ZonedDateTime dedicatedCellularBpDeliveryReportedAt;
+		String dedicatedCellularBpDeliveryMemo;
+		@Enumerated(EnumType.STRING)
+		YesNoOrUnknown hasClientConfirmedReceiptOfDedicatedCellularBp;
+		String clientConfirmedReceiptOfDedicatedCellularBpMemo;
+		@OneToOne
+		Measurement firstDedicatedCellularBpMeasurement;
+		@OneToOne
+		Measurement mostRecentDedicatedCellularBpMeasurement;
+	}
+
+	@Embedded
+	DedicatedCellularBpValue dedicatedCellularBpValue;
+
+	@OneToOne(cascade = CascadeType.ALL, orphanRemoval = false)
+	Status clientIntentForCellularBpStatus;
+
+	@OneToOne(cascade = CascadeType.ALL, orphanRemoval = false)
+	Status mcpExpectationForCellularBpStatus;
+
+	@OneToOne(cascade = CascadeType.ALL, orphanRemoval = false)
+	Status defaultNaExpectationForCellularBpStatus;
+
+	@Embeddable
+	@Data
+	public class EquipmentAwaitingSetupValue {
+		@Enumerated(EnumType.STRING)
+		YesNoOrUnknown isEquipmentAwaitingSetup = YesNoOrUnknown.UNKNOWN;
+		String whatEquipmentIsAwaitingSetup;
+	}
+
+	@Embedded
+	@Setter
+	EquipmentAwaitingSetupValue equipmentAwaitingSetupValue;
+
+	@Embeddable
+	@Data
+	public class EquipmentSetupCompletionValue {
+		@Enumerated(EnumType.STRING)
+		YesNoOrUnknown isEquipmentSetupCompleted = YesNoOrUnknown.UNKNOWN;
+		String whatEquipmentSetupIsCompleted;
+	}
+
+	@Embedded
+	@Setter
+	EquipmentSetupCompletionValue equipmentSetupCompletionValue;
+
+	@Embeddable
+	@Data
+	public class EquipmentServiceNeedValue {
+		@Enumerated(EnumType.STRING)
+		YesNoOrUnknown isEquipmentServiceNeeded = YesNoOrUnknown.UNKNOWN;
+		String whatEquipmentServiceIsNeeded;
+	}
+
+	@Embedded
+	@Setter
+	EquipmentServiceNeedValue equipmentServiceNeedValue;

+ 51 - 0
spec/note-structure-outline.txt

@@ -0,0 +1,51 @@
+
+
+
+==========================================
+
+
+	cc:
+	vitals:
+	allergies: 
+	medications: 
+	history_medical: 
+	history_surgical: 
+	history_family: 
+	history_social: 
+	history_screenings: 
+	subjective:
+	ros:
+	active_interventions_review:
+	
+		Lifestyle Assessments:
+
+			General
+			Nutrition
+			Physical Activity
+			Sleep
+			Social Relationships
+			Stress
+			Substance Use
+
+	Objective:
+
+		Physical exam findings:
+		Laboratory data:
+		Imaging results:
+		Measurements:
+		Other diagnostic data:
+		Recognition and review of the documentation of other clinicians:
+
+	Assessments / Current Problems / Focus Areas:
+
+		List:
+
+	PLAN:
+		
+		Free Text:
+		Condition-Specific (Long-Term / Overall):
+		Medication Changes:
+		Interventions:
+		Follow-Up:
+
+-------------------------------------------