Zahlungsparser
This commit is contained in:
@@ -5,6 +5,7 @@ namespace App\Domains\Admin\Controllers;
|
||||
use App\Models\AvailablePaymentMethod;
|
||||
use App\Resources\AvailablePaymentMethodResource;
|
||||
use App\Scopes\CommonController;
|
||||
use App\ValueObjects\BankStatementRuleset;
|
||||
use Illuminate\Http\JsonResponse;
|
||||
use Illuminate\Http\Request;
|
||||
|
||||
@@ -16,6 +17,10 @@ class TenantPaymentMethodsGetController extends CommonController
|
||||
'paymentMethods' => AvailablePaymentMethod::all()
|
||||
->map(fn (AvailablePaymentMethod $method) => new AvailablePaymentMethodResource($method)->toArray($request)),
|
||||
'saveEndpoint' => '/api/v1/admin/tenant/payment-methods',
|
||||
// Der app-weite Standard für das Kontoauszug-Format. Das Formular zeigt ihn als
|
||||
// Vorbelegung an, damit erkennbar ist, wovon ein Override abweicht.
|
||||
'statementRulesetDefault' => BankStatementRuleset::default()->toArray(),
|
||||
'statementRulesetCharsets' => BankStatementRuleset::CHARSETS,
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
<script setup>
|
||||
import {computed, ref} from 'vue';
|
||||
import BankRulesetEditor from "../../../../Views/Components/BankRulesetEditor.vue";
|
||||
import FullScreenModal from "../../../../Views/Components/FullScreenModal.vue";
|
||||
import TextEditor from "../../../../Views/Components/TextEditor.vue";
|
||||
import RichSelectBox from "../../../../Views/Components/RichSelectBox.vue";
|
||||
@@ -102,6 +103,10 @@ async function save() {
|
||||
<RichSelectBox v-if="option.type === 'icon'" v-model="form.configuration[option.name]"
|
||||
:options="PAYMENT_METHOD_ICONS" placeholder="Symbol wählen…"/>
|
||||
<TextEditor v-else-if="option.type === 'richtext'" v-model="form.configuration[option.name]"/>
|
||||
<BankRulesetEditor v-else-if="option.type === 'bank-ruleset'"
|
||||
v-model="form.configuration[option.name]"
|
||||
:defaults="data.statementRulesetDefault ?? {}"
|
||||
:charsets="data.statementRulesetCharsets ?? undefined"/>
|
||||
<input v-else type="text" v-model="form.configuration[option.name]" class="form-input"/>
|
||||
<span v-if="option.hint" class="option-hint">{{ option.hint }}</span>
|
||||
</td>
|
||||
|
||||
Reference in New Issue
Block a user