mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/exchange-2.0.git
synced 2026-08-23 22:44:03 +00:00
Merge branch 'new_field_for_bank' into 'master'
New field for bank See merge request CIEFWorldwideSdnBhd/exchange-2.0!21
This commit is contained in:
@@ -100,7 +100,7 @@ class CreateCustomerLogic extends AbstractControllerLogic
|
||||
|
||||
$this->assignSegmentProcessor->execute($company);
|
||||
|
||||
$this->generateEmailVerificationAttemptProcessor->execute($user);
|
||||
// $this->generateEmailVerificationAttemptProcessor->execute($user);
|
||||
|
||||
return $this->response($this->authenticationProcessor->execute($request));
|
||||
|
||||
|
||||
@@ -59,6 +59,7 @@ class CreateBankLogic extends AbstractControllerLogic
|
||||
|
||||
$bank_object = new BankObject($request->input('company_id'), $request->input('account_type'),
|
||||
$request->input('bank_name'), $request->input('holder_name'), $request->input('account_no'),
|
||||
$request->input('bank_branch'), $request->input('swift'), $request->input('snap'),
|
||||
$request->input('country_id'), $request->input('reference'));
|
||||
|
||||
$this->canCreateBank->passes($bank_object);
|
||||
|
||||
@@ -38,13 +38,16 @@ class BankObject implements DataTransferObject
|
||||
* @param int $country_id
|
||||
* @param null|string $reference
|
||||
*/
|
||||
public function __construct(int $company_id, int $type, string $bank_name, string $holder_name, string $account_no, int $country_id, ?string $reference = null)
|
||||
public function __construct(int $company_id, int $type, string $bank_name, string $holder_name, string $account_no, ?string $bank_branch = null, ?string $swift = null, ?string $snap = null, int $country_id, ?string $reference = null)
|
||||
{
|
||||
$this->company_id = $company_id;
|
||||
$this->type = $type;
|
||||
$this->bank_name = $bank_name;
|
||||
$this->holder_name = $holder_name;
|
||||
$this->account_no = $account_no;
|
||||
$this->bank_branch = $bank_branch;
|
||||
$this->swift = $swift;
|
||||
$this->snap = $snap;
|
||||
$this->country_id = $country_id;
|
||||
$this->reference = $reference;
|
||||
}
|
||||
@@ -89,6 +92,30 @@ class BankObject implements DataTransferObject
|
||||
return $this->account_no;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return null|string
|
||||
*/
|
||||
public function getBankBranch(): ?string
|
||||
{
|
||||
return $this->bank_branch;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return null|string
|
||||
*/
|
||||
public function getSwift(): ?string
|
||||
{
|
||||
return $this->swift;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return null|string
|
||||
*/
|
||||
public function getSnap(): ?string
|
||||
{
|
||||
return $this->snap;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return int
|
||||
*/
|
||||
|
||||
@@ -21,6 +21,9 @@ class CreatesBank extends AbstractUpdateRecord
|
||||
$model->bank_name = $object->getBankName();
|
||||
$model->holder_name = $object->getHolderName();
|
||||
$model->account_no = $object->getAccountNo();
|
||||
$model->bank_branch = $object->getBankBranch();
|
||||
$model->swift = $object->getSwift();
|
||||
$model->snap = $object->getSnap();
|
||||
$model->type = $object->getType();
|
||||
$model->country_id = $object->getCountryId();
|
||||
|
||||
|
||||
@@ -20,6 +20,9 @@ class UpdatesBank extends AbstractUpdateRecord
|
||||
$model->bank_name = $object->getBankName();
|
||||
$model->holder_name = $object->getHolderName();
|
||||
$model->account_no = $object->getAccountNo();
|
||||
$model->bank_branch = $object->getBankBranch();
|
||||
$model->swift = $object->getSwift();
|
||||
$model->snap = $object->getSnap();
|
||||
$model->default = $object->getDefault();
|
||||
|
||||
return $this->handler($model);
|
||||
|
||||
@@ -22,6 +22,9 @@ class CreateBanksTable extends Migration
|
||||
$table->string('bank_name');
|
||||
$table->string('holder_name');
|
||||
$table->string('account_no');
|
||||
$table->string('bank_branch')->nullable();
|
||||
$table->string('swift')->nullable();
|
||||
$table->string('snap')->nullable();
|
||||
$table->integer('type')->default(BankAccountType::EXTERNAL);
|
||||
$table->integer('default')->default(false);
|
||||
$table->integer('status')->default(ApprovalStatus::APPROVED);
|
||||
|
||||
Generated
+5362
-5620
File diff suppressed because it is too large
Load Diff
@@ -38,6 +38,35 @@
|
||||
</validation-wrapper-component>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row m-b-10">
|
||||
<div class="col">
|
||||
<validation-wrapper-component :validator="$v.parameters.bank_branch">
|
||||
<label class="muted">Bank Branch</label>
|
||||
<input type="text" class="form-control" v-model="parameters.bank_branch">
|
||||
</validation-wrapper-component>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row m-b-10">
|
||||
<div class="col">
|
||||
<validation-wrapper-component :validator="$v.parameters.swift">
|
||||
<label class="muted">Swift</label>
|
||||
<input type="text" class="form-control" v-model="parameters.swift">
|
||||
</validation-wrapper-component>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row m-b-10">
|
||||
<div class="col">
|
||||
<validation-wrapper-component :validator="$v.parameters.snap">
|
||||
<label class="muted">Snap</label>
|
||||
<input type="text" class="form-control" v-model="parameters.snap">
|
||||
</validation-wrapper-component>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="row m-b-20" v-if="type !== 2">
|
||||
<div class="col">
|
||||
<validation-wrapper-component selecatable :validator="$v.parameters.bank_name">
|
||||
@@ -94,6 +123,9 @@
|
||||
bank_name: '',
|
||||
holder_name: '',
|
||||
account_no: '',
|
||||
bank_branch: '',
|
||||
swift: '',
|
||||
snap: '',
|
||||
country_id: this.country_id,
|
||||
}
|
||||
}
|
||||
@@ -106,6 +138,15 @@
|
||||
account_no: {
|
||||
required
|
||||
},
|
||||
bank_branch: {
|
||||
// required
|
||||
},
|
||||
swift: {
|
||||
// required
|
||||
},
|
||||
snap: {
|
||||
// required
|
||||
},
|
||||
bank_name: {
|
||||
required
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user