diff --git a/src/Billing/X125010837P.php b/src/Billing/X125010837P.php index 951650326c3..e36ec5983f1 100644 --- a/src/Billing/X125010837P.php +++ b/src/Billing/X125010837P.php @@ -663,7 +663,7 @@ public static function genX12837P( $proccount = $claim->procCount(); $clm_total_charges = 0; for ($prockey = 0; $prockey < $proccount; ++$prockey) { - $clm_total_charges += $claim->cptCharges($prockey); + $clm_total_charges += floatval($claim->cptCharges($prockey)); } if (!$clm_total_charges) { $log .= "*** This claim has no charges!\n"; diff --git a/src/Validators/CoverageValidator.php b/src/Validators/CoverageValidator.php index d4aabde5d36..bbc72fed9f2 100644 --- a/src/Validators/CoverageValidator.php +++ b/src/Validators/CoverageValidator.php @@ -69,7 +69,7 @@ function (Validator $context) { $context->optional('group_number')->lengthBetween(2, 255); $context->required('subscriber_lname')->lengthBetween(2, 255); $context->optional('subscriber_mname')->lengthBetween(1, 255); - $context->required('subscriber_fname')->lengthBetween(2, 255); + $context->required('subscriber_fname')->lengthBetween(1, 255); $context->required('subscriber_relationship')->listOption('sub_relation') ->callback(function ($value, $values) { if ( diff --git a/src/Validators/PatientValidator.php b/src/Validators/PatientValidator.php index 9dbd0486751..6e383205867 100644 --- a/src/Validators/PatientValidator.php +++ b/src/Validators/PatientValidator.php @@ -53,7 +53,7 @@ protected function configureValidator() $this->validator->context( self::DATABASE_INSERT_CONTEXT, function (Validator $context) { - $context->required("fname", "First Name")->lengthBetween(2, 255); + $context->required("fname", "First Name")->lengthBetween(1, 255); $context->required("lname", 'Last Name')->lengthBetween(2, 255); $context->required("sex", 'Gender')->lengthBetween(4, 30); $context->required("DOB", 'Date of Birth')->datetime('Y-m-d'); diff --git a/tests/Tests/Services/PatientServiceTest.php b/tests/Tests/Services/PatientServiceTest.php index 0b2025ebcb5..0c27195d939 100644 --- a/tests/Tests/Services/PatientServiceTest.php +++ b/tests/Tests/Services/PatientServiceTest.php @@ -51,7 +51,7 @@ public function testGetFreshPid() */ public function testInsertFailure() { - $this->patientFixture["fname"] = "A"; + $this->patientFixture["fname"] = ""; $this->patientFixture["DOB"] = "12/27/2017"; unset($this->patientFixture["sex"]); @@ -93,7 +93,7 @@ public function testUpdateFailure() { $this->patientService->insert($this->patientFixture); - $this->patientFixture["fname"] = "A"; + $this->patientFixture["fname"] = ""; $actualResult = $this->patientService->update("not-a-uuid", $this->patientFixture); diff --git a/tests/Tests/Validators/PatientValidatorTest.php b/tests/Tests/Validators/PatientValidatorTest.php index 10fb703c38d..4e9ca5d47b8 100644 --- a/tests/Tests/Validators/PatientValidatorTest.php +++ b/tests/Tests/Validators/PatientValidatorTest.php @@ -69,7 +69,7 @@ public function testValidationInsertSuccess() public function testValidationUpdateFailure() { $this->patientFixture["uuid"] = $this->fixtureManager->getUnregisteredUuid(); - $this->patientFixture["fname"] = "A"; + $this->patientFixture["fname"] = ""; $this->patientFixture["sex"] = "M"; $actualResult = $this->patientValidator->validate($this->patientFixture, PatientValidator::DATABASE_UPDATE_CONTEXT);