mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-12 22:22:32 +01:00
Remodelling bank transaction rules
This commit is contained in:
parent
fe7f30785a
commit
b2c314d7c3
@ -38,7 +38,6 @@ class StoreBankTransactionRuleRequest extends Request
|
||||
'auto_convert' => 'bail|sometimes|bool',
|
||||
'matches_on_all' => 'bail|sometimes|bool',
|
||||
'applies_to' => 'bail|sometimes|bool',
|
||||
'record_as' => 'bail|sometimes|bool',
|
||||
];
|
||||
|
||||
if (isset($this->currency_id))
|
||||
|
@ -37,7 +37,6 @@ class UpdateBankTransactionRuleRequest extends Request
|
||||
'auto_convert' => 'bail|sometimes|bool',
|
||||
'matches_on_all' => 'bail|sometimes|bool',
|
||||
'applies_to' => 'bail|sometimes|bool',
|
||||
'record_as' => 'bail|sometimes|bool',
|
||||
];
|
||||
|
||||
if (isset($this->currency_id))
|
||||
|
@ -27,7 +27,6 @@ class BankTransactionRule extends BaseModel
|
||||
'auto_convert',
|
||||
'matches_on_all',
|
||||
'applies_to',
|
||||
'record_as',
|
||||
'client_id',
|
||||
'vendor_id',
|
||||
'category_id',
|
||||
|
@ -56,7 +56,6 @@ class BankTransactionRuleTransformer extends EntityTransformer
|
||||
'auto_convert' => (bool) $bank_transaction_rule->auto_convert,
|
||||
'matches_on_all' => (bool) $bank_transaction_rule->matches_on_all,
|
||||
'applies_to' => (string) $bank_transaction_rule->applies_to,
|
||||
'record_as' => (string) $bank_transaction_rule->record_as,
|
||||
'client_id' => $this->encodePrimaryKey($bank_transaction_rule->client_id) ?: '',
|
||||
'vendor_id' => $this->encodePrimaryKey($bank_transaction_rule->vendor_id) ?: '',
|
||||
'category_id' => $this->encodePrimaryKey($bank_transaction_rule->category_id) ?: '',
|
||||
|
@ -24,7 +24,6 @@ return new class extends Migration
|
||||
$table->boolean('auto_convert')->default(false); //auto convert to match
|
||||
$table->boolean('matches_on_all')->default(false); //match on all rules or just one
|
||||
$table->string('applies_to')->default('CREDIT'); //CREDIT/DEBIT
|
||||
$table->string('record_as')->default('CREDIT'); //CREDIT/DEBIT
|
||||
|
||||
$table->unsignedInteger('client_id')->nullable();
|
||||
$table->unsignedInteger('vendor_id')->nullable();
|
||||
|
Loading…
Reference in New Issue
Block a user