Added IBAN Saving, Automatic Saving, added Mitglieder
This commit is contained in:
@@ -43,6 +43,7 @@ import quantity from "~/components/helpRenderings/quantity.vue"
|
||||
import {useFunctions} from "~/composables/useFunctions.js";
|
||||
import signDate from "~/components/columnRenderings/signDate.vue";
|
||||
import sepaDate from "~/components/columnRenderings/sepaDate.vue";
|
||||
import bankAccounts from "~/components/columnRenderings/bankAccounts.vue";
|
||||
|
||||
// @ts-ignore
|
||||
export const useDataStore = defineStore('data', () => {
|
||||
@@ -410,6 +411,14 @@ export const useDataStore = defineStore('data', () => {
|
||||
inputType: "text",
|
||||
inputColumn: "Kontaktdaten"
|
||||
},
|
||||
{
|
||||
key: "infoData.bankAccountIds",
|
||||
label: "Bankkonten",
|
||||
component: bankAccounts,
|
||||
inputType: "bankaccountassign",
|
||||
inputColumn: "Kontaktdaten",
|
||||
disabledInTable: true
|
||||
},
|
||||
{
|
||||
key: "infoData.ustid",
|
||||
label: "USt-Id",
|
||||
@@ -436,6 +445,202 @@ export const useDataStore = defineStore('data', () => {
|
||||
],
|
||||
showTabs: [{label: 'Informationen'},{label: 'Ansprechpartner'},{label: 'Dateien'},{label: 'Ausgangsbelege'},{label: 'Projekte'},{label: 'Objekte'},{label: 'Termine'},{label: 'Verträge'},{label: 'Wiki'}]
|
||||
},
|
||||
members: {
|
||||
isArchivable: true,
|
||||
label: "Mitglieder",
|
||||
labelSingle: "Mitglied",
|
||||
isStandardEntity: true,
|
||||
redirect: true,
|
||||
numberRangeHolder: "customerNumber",
|
||||
historyItemHolder: "customer",
|
||||
sortColumn: "customerNumber",
|
||||
selectWithInformation: "*, projects(*), plants(*), contracts(*), contacts(*), createddocuments(*, statementallocations(*)), files(*), events(*)",
|
||||
filters: [{
|
||||
name: "Archivierte ausblenden",
|
||||
default: true,
|
||||
"filterFunction": function (row) {
|
||||
return !row.archived
|
||||
}
|
||||
}],
|
||||
inputColumns: [
|
||||
"Allgemeines",
|
||||
"Bank & Kontakt"
|
||||
],
|
||||
templateColumns: [
|
||||
{
|
||||
key: 'customerNumber',
|
||||
label: "Mitgliedsnummer",
|
||||
inputIsNumberRange: true,
|
||||
inputType: "text",
|
||||
inputColumn: "Allgemeines",
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
key: "name",
|
||||
label: "Name",
|
||||
title: true,
|
||||
sortable: true,
|
||||
distinct: true
|
||||
},
|
||||
{
|
||||
key: "salutation",
|
||||
label: "Anrede",
|
||||
inputType: "text",
|
||||
inputChangeFunction: function (row) {
|
||||
row.name = `${row.salutation ? (row.salutation + " ") : ""}${row.title ? (row.title + " ") : ""}${row.firstname ? (row.firstname + " ") : ""}${row.lastname || ""}`.trim();
|
||||
},
|
||||
inputColumn: "Allgemeines",
|
||||
sortable: true,
|
||||
distinct: true
|
||||
},
|
||||
{
|
||||
key: "title",
|
||||
label: "Titel",
|
||||
inputType: "text",
|
||||
inputChangeFunction: function (row) {
|
||||
row.name = `${row.salutation ? (row.salutation + " ") : ""}${row.title ? (row.title + " ") : ""}${row.firstname ? (row.firstname + " ") : ""}${row.lastname || ""}`.trim();
|
||||
},
|
||||
inputColumn: "Allgemeines"
|
||||
},
|
||||
{
|
||||
key: "firstname",
|
||||
label: "Vorname",
|
||||
required: true,
|
||||
inputType: "text",
|
||||
inputChangeFunction: function (row) {
|
||||
row.name = `${row.salutation ? (row.salutation + " ") : ""}${row.title ? (row.title + " ") : ""}${row.firstname ? (row.firstname + " ") : ""}${row.lastname || ""}`.trim();
|
||||
},
|
||||
inputColumn: "Allgemeines",
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
key: "lastname",
|
||||
label: "Nachname",
|
||||
required: true,
|
||||
inputType: "text",
|
||||
inputChangeFunction: function (row) {
|
||||
row.name = `${row.salutation ? (row.salutation + " ") : ""}${row.title ? (row.title + " ") : ""}${row.firstname ? (row.firstname + " ") : ""}${row.lastname || ""}`.trim();
|
||||
},
|
||||
inputColumn: "Allgemeines",
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
key: "active",
|
||||
label: "Aktiv",
|
||||
component: active,
|
||||
inputType: "bool",
|
||||
inputColumn: "Allgemeines",
|
||||
sortable: true,
|
||||
distinct: true
|
||||
},
|
||||
{
|
||||
key: "customPaymentDays",
|
||||
label: "Beitragsintervall in Tagen",
|
||||
inputType: "number",
|
||||
inputColumn: "Allgemeines",
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
key: "infoData.bankAccountIds",
|
||||
label: "Bankkonten",
|
||||
component: bankAccounts,
|
||||
inputType: "bankaccountassign",
|
||||
required: true,
|
||||
inputColumn: "Bank & Kontakt",
|
||||
disabledInTable: true
|
||||
},
|
||||
{
|
||||
key: "infoData.hasSEPA",
|
||||
label: "SEPA-Mandat vorhanden",
|
||||
inputType: "bool",
|
||||
inputColumn: "Bank & Kontakt",
|
||||
disabledInTable: true
|
||||
},
|
||||
{
|
||||
key: "infoData.sepaSignedAt",
|
||||
label: "SEPA unterschrieben am",
|
||||
inputType: "date",
|
||||
required: true,
|
||||
showFunction: function (item) {
|
||||
return Boolean(item.infoData?.hasSEPA)
|
||||
},
|
||||
inputColumn: "Bank & Kontakt",
|
||||
disabledInTable: true
|
||||
},
|
||||
{
|
||||
key: "infoData.street",
|
||||
label: "Straße + Hausnummer",
|
||||
inputType: "text",
|
||||
disabledInTable: true,
|
||||
inputColumn: "Bank & Kontakt"
|
||||
},
|
||||
{
|
||||
key: "infoData.special",
|
||||
label: "Adresszusatz",
|
||||
inputType: "text",
|
||||
disabledInTable: true,
|
||||
inputColumn: "Bank & Kontakt"
|
||||
},
|
||||
{
|
||||
key: "infoData.zip",
|
||||
label: "Postleitzahl",
|
||||
inputType: "text",
|
||||
inputChangeFunction: async function (row) {
|
||||
const zip = String(row.infoData.zip || "").replace(/\D/g, "")
|
||||
row.infoData.zip = zip
|
||||
if ([4, 5].includes(zip.length)) {
|
||||
const zipData = await useFunctions().useZipCheck(zip)
|
||||
row.infoData.zip = zipData?.zip || row.infoData.zip
|
||||
row.infoData.city = zipData?.short || row.infoData.city
|
||||
}
|
||||
},
|
||||
disabledInTable: true,
|
||||
inputColumn: "Bank & Kontakt"
|
||||
},
|
||||
{
|
||||
key: "infoData.city",
|
||||
label: "Stadt",
|
||||
inputType: "text",
|
||||
disabledInTable: true,
|
||||
inputColumn: "Bank & Kontakt"
|
||||
},
|
||||
{
|
||||
key: "infoData.country",
|
||||
label: "Land",
|
||||
inputType: "select",
|
||||
selectDataType: "countrys",
|
||||
selectOptionAttribute: "name",
|
||||
selectValueAttribute: "name",
|
||||
disabledInTable: true,
|
||||
inputColumn: "Bank & Kontakt"
|
||||
},
|
||||
{
|
||||
key: "address",
|
||||
label: "Adresse",
|
||||
component: address,
|
||||
inputColumn: "Bank & Kontakt"
|
||||
},
|
||||
{
|
||||
key: "infoData.tel",
|
||||
label: "Telefon",
|
||||
inputType: "text",
|
||||
inputColumn: "Bank & Kontakt"
|
||||
},
|
||||
{
|
||||
key: "infoData.email",
|
||||
label: "E-Mail",
|
||||
inputType: "text",
|
||||
inputColumn: "Bank & Kontakt"
|
||||
},
|
||||
{
|
||||
key: "notes",
|
||||
label: "Notizen",
|
||||
inputType: "textarea",
|
||||
inputColumn: "Allgemeines"
|
||||
},
|
||||
],
|
||||
showTabs: [{label: 'Informationen'},{label: 'Ansprechpartner'},{label: 'Dateien'},{label: 'Ausgangsbelege'},{label: 'Projekte'},{label: 'Objekte'},{label: 'Termine'},{label: 'Verträge'},{label: 'Wiki'}]
|
||||
},
|
||||
contacts: {
|
||||
isArchivable: true,
|
||||
label: "Kontakte",
|
||||
@@ -1455,6 +1660,13 @@ export const useDataStore = defineStore('data', () => {
|
||||
label: "Web",
|
||||
inputType: "text"
|
||||
},
|
||||
{
|
||||
key: "infoData.bankAccountIds",
|
||||
label: "Bankkonten",
|
||||
component: bankAccounts,
|
||||
inputType: "bankaccountassign",
|
||||
disabledInTable: true
|
||||
},
|
||||
{
|
||||
key: "infoData.ustid",
|
||||
label: "USt-Id",
|
||||
@@ -2700,6 +2912,55 @@ export const useDataStore = defineStore('data', () => {
|
||||
bankaccounts: {
|
||||
label: "Bankkonten",
|
||||
labelSingle: "Bankkonto",
|
||||
},
|
||||
entitybankaccounts: {
|
||||
isArchivable: true,
|
||||
label: "Bankverbindungen",
|
||||
labelSingle: "Bankverbindung",
|
||||
isStandardEntity: false,
|
||||
redirect: false,
|
||||
sortColumn: "created_at",
|
||||
filters: [{
|
||||
name: "Archivierte ausblenden",
|
||||
default: true,
|
||||
"filterFunction": function (row) {
|
||||
return !row.archived
|
||||
}
|
||||
}],
|
||||
templateColumns: [
|
||||
{
|
||||
key: "displayLabel",
|
||||
label: "Bankverbindung",
|
||||
title: true,
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
key: "iban",
|
||||
label: "IBAN",
|
||||
required: true,
|
||||
inputType: "text",
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
key: "bic",
|
||||
label: "BIC",
|
||||
required: true,
|
||||
inputType: "text",
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
key: "bankName",
|
||||
label: "Bankinstitut",
|
||||
required: true,
|
||||
inputType: "text",
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
key: "description",
|
||||
label: "Beschreibung",
|
||||
inputType: "text",
|
||||
},
|
||||
],
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user