add reason in corporate, plan, service

This commit is contained in:
2023-06-05 09:01:43 +07:00
parent 4fb2bab64e
commit 4cc2ae24b8
34 changed files with 2037 additions and 87 deletions

View File

@@ -70,10 +70,10 @@ class CorporateService
'attribute' => 'Plan'
]), 0, null, $row);
} else if(!in_array($row['corporate_plan_id'], $current_corporate_plans)){
throw new ImportRowException(__('plan.NOT_MATCH', [
'attribute' => 'Plans',
'code' => $row['corporate_plan_id']
]), 0, null, $row);
// throw new ImportRowException(__('plan.NOT_MATCH', [
// 'attribute' => 'Plans',
// 'code' => $row['corporate_plan_id']
// ]), 0, null, $row);
}
if (empty($row['code'])) {
@@ -175,10 +175,10 @@ class CorporateService
if (empty($row['plan_code'])) {
throw new ImportRowException(__('benefit.PLAN_CODE_REQUIRED'), 0, null, $row);
} else if (!in_array($row['plan_code'], $current_corporate_plans)){
throw new ImportRowException(__('plan.NOT_MATCH', [
'attribute' => 'Plan',
'code' => $row['plan_code']
]), 0, null, $row);
// throw new ImportRowException(__('plan.NOT_MATCH', [
// 'attribute' => 'Plan',
// 'code' => $row['plan_code']
// ]), 0, null, $row);
}
if (empty($row['code'])) {

View File

@@ -736,7 +736,7 @@ class MemberEnrollmentService
$person = Person::create([
'name' => $row['name'],
'birth_date' => $this->dateParser($row['date_of_birth']),
'birth_date' => $row['date_of_birth'],
'gender' => Helper::genderPerson($row['sex']),
'language' => $row['language'] ?? null,
'race' => $row['race'] ?? null,