# sanity check, can't have AR with AR_...
if ($form->{AR} || $form->{AP} || $form->{IC}) {
map { delete $form->{$_} }
- qw(AR_amount AR_tax AR_paid AP_amount AP_tax AP_paid IC_sale IC_cogs IC_taxpart IC_income IC_expense IC_taxservice CT_tax);
+ qw(AR_amount AR_tax AR_paid AP_amount AP_tax AP_paid IC_sale IC_cogs IC_taxpart IC_income IC_expense IC_taxservice);
+ }
+
+ if ($form->{AR_include_in_dropdown}) {
+ $form->{$form->{AR_include_in_dropdown}} = $form->{AR_include_in_dropdown};
+ }
+ if ($form->{AP_include_in_dropdown}) {
+ $form->{$form->{AP_include_in_dropdown}} = $form->{AP_include_in_dropdown};
}
$form->{link} = "";
$form->{IC}, $form->{IC_sale},
$form->{IC_cogs}, $form->{IC_taxpart},
$form->{IC_income}, $form->{IC_expense},
- $form->{IC_taxservice}, $form->{CT_tax}
+ $form->{IC_taxservice}
) {
$form->{link} .= "${item}:" if ($item);
}
$main::lxdebug->leave_sub();
}
-sub get_taxaccounts {
- $main::lxdebug->enter_sub();
-
- my ($self, $myconfig, $form) = @_;
-
- # connect to database
- my $dbh = $form->dbconnect($myconfig);
-
- # get tax accounts
- my $query =
- qq|SELECT c.accno, c.description, t.rate
- FROM chart c, tax t
- WHERE (c.link LIKE '%CT_tax%') AND (c.id = t.chart_id)
- ORDER BY c.accno|;
- $form->{taxaccounts} = selectall_hashref_query($form, $dbh, $query);
-
- $dbh->disconnect;
-
- $main::lxdebug->leave_sub();
-}
-
sub tax_report {
$main::lxdebug->enter_sub();
}
+ # account where AR_tax or AP_tax is set are not orphaned if they are used as
+ # tax-o-matic account
+ if ( $form->{id} && !$form->{orphaned} && ($form->{link} =~ m/(AP_tax|AR_tax)/) ) {
+ if (SL::DB::Manager::Tax->find_by(chart_id => $form->{id})) {
+ $form->{orphaned} = 0;
+ }
+ }
+
my $ChartTypeIsAccount = ($form->{charttype} eq "A") ? "1":"";
my $AccountIsPosted = ($form->{orphaned} ) ? "":"1";
: ( $link eq 'IC_income' ) ? $locale->text('Account Link IC_income')
: ( $link eq 'IC_expense' ) ? $locale->text('Account Link IC_expense')
: ( $link eq 'IC_taxservice' ) ? $locale->text('Account Link IC_taxservice')
-# : ( $link eq 'CT_tax' ) ? $locale->text('Account Link CT_tax')
: $locale->text('Unknown Link') . ': ' . $link;
$ca->{link} .= ($link ne '') ? "[$link] ":'';
}
}
}
}
- # Falls Suche über Rechnungsnummer und kein Kundenname vorhanden
- if ($form->{invnumber} && !($form->{$form->{vc}})){
- $form->{open} ='Y'; # nur die offenen rechnungen
- if ($form->{ARAP} eq 'AR'){
- AR->ar_transactions(\%myconfig, \%$form);
-
- # if you search for invoice '11' ar_transactions will also match invoices
- # 112, 211, ... due to the LIKE
-
- # so there is now an extra loop that tries to match the invoice number
- # exactly among all returned results, and then passes the customer_id instead of the name
- # because the name may not be unique
-
- my $found_exact_invnumber_match = 0;
- foreach my $i ( @{ $form->{AR} } ) {
- next unless $i->{invnumber} eq $form->{invnumber};
- # found exactly matching invnumber
- $form->{$form->{vc}} = $i->{name};
- $form->{customer_id} = $i->{customer_id};
- $found_exact_invnumber_match = 1;
- };
-
- unless ( $found_exact_invnumber_match ) {
- # use first returned entry, may not be the correct one if invnumber doesn't match uniquely
- $form->{$form->{vc}} = $form->{AR}[0]{name};
- $form->{customer_id} = $form->{AR}[0]{customer_id};
- };
- } else {
- # s.o. nur für zahlungsausgang
- AP->ap_transactions(\%myconfig, \%$form);
- $form->{$form->{vc}} = $form->{AP}[0]{name};
+
+ # search by invoicenumber,
+ if ($form->{invnumber}) {
+ $form->{open} ='Y'; # nur die offenen rechnungen
+ if ($form->{ARAP} eq 'AR'){
+
+ # ar_transactions automatically searches by $form->{customer_id} or else
+ # $form->{customer} if available, and these variables will always be set
+ # when we have a dropdown field rather than an input field, so we have to
+ # empty these values first
+ $form->{customer_id} = '';
+ $form->{customer} = '';
+ AR->ar_transactions(\%myconfig, \%$form);
+
+ # if you search for invoice '11' ar_transactions will also match invoices
+ # 112, 211, ... due to the LIKE
+
+ # so there is now an extra loop that tries to match the invoice number
+ # exactly among all returned results, and then passes the customer_id instead of the name
+ # because the name may not be unique
+
+ my $found_exact_invnumber_match = 0;
+ foreach my $i ( @{ $form->{AR} } ) {
+ next unless $i->{invnumber} eq $form->{invnumber};
+ # found exactly matching invnumber
+ $form->{$form->{vc}} = $i->{name};
+ $form->{customer_id} = $i->{customer_id};
+ #$form->{"old${form->{vc}"} = $i->{customer_id};
+ $found_exact_invnumber_match = 1;
+ };
+
+ unless ( $found_exact_invnumber_match ) {
+ # use first returned entry, may not be the correct one if invnumber doesn't
+ # match uniquely
+ $form->{$form->{vc}} = $form->{AR}[0]{name};
+ $form->{customer_id} = $form->{AR}[0]{customer_id};
+ };
+ } else {
+ # s.o. nur für zahlungsausgang
+ AP->ap_transactions(\%myconfig, \%$form);
+ $form->{$form->{vc}} = $form->{AP}[0]{name};
}
}
- # get customer and invoices
- $updated = &check_name($form->{vc}) unless $form->{customer_id};
- if ( $form->{customer_id} ) {
- # we already know the exact customer_id, fill $form with customer data
+ # determine customer/vendor
+ if ( $form->{customer_id} and $form->{invnumber} ) {
+ # we already know the exact customer_id, so fill $form with customer data
IS->get_customer(\%myconfig, \%$form);
$updated = 1;
+ } else {
+ # check_name is called with "customer" or "vendor" and otherwise uses contents of $form
+ # check_name also runs get_customer/get_vendor
+ $updated = &check_name($form->{vc});
};
if ($new_name_selected || $updated) {
- # get open invoices from ar/ap using $form->{vc} and a.${vc}_id
+ # get open invoices from ar/ap using $form->{vc} and a.${vc}_id, i.e. customer_id
CP->get_openinvoices(\%myconfig, \%$form);
($newvc) = split /--/, $form->{ $form->{vc} };
$form->{"old$form->{vc}"} = qq|$newvc--$form->{"$form->{vc}_id"}|;
my $is_bwa = $::form->{report} eq "bwa";
my $is_balance_sheet = $::form->{report} eq "balance_sheet";
my $is_trial_balance = $::form->{report} eq "trial_balance";
- my $is_taxreport = $::form->{report} =~ /^tax_/;
- my $is_nontaxable = $::form->{report} =~ /^nontaxable_/;
my $is_aging = $::form->{report} =~ /^a[rp]_aging$/;
my $is_payments = $::form->{report} =~ /(receipts|payments)$/;
-# if (is_taxreport) {
-# $::form->{db} = ($::form->{report} =~ /_collected/) ? "ar" : "ap";
-# RP->get_taxaccounts(\%::myconfig, $::form);
-# }
-#
-# if ($is_nontaxable) {
-# $::form->{db} = ($::form->{report} =~ /_sales/) ? "ar" : "ap";
-# }
-
my ($label, $nextsub, $vc);
if ($is_aging) {
my $is_sales = $::form->{report} eq 'ar_aging';
ein "Bullet" ersetzt. Dafür kann mit <bullet> ein Aufzählungspunkt erzeugt
werden.
+ - Bebuchte Konten und als Steuerautomatik-Konten dienende Konten lassen sich
+ löschen und nur bedingt umkonfigurieren (Häkchen bei Forderungen o.
+ Verbindlichkeiten).
+
+ - Häkchen bei der Konto-Konfiguration f. Forderungen u. Verbindlichkeiten
+ als Radio-Buttons.
+
Liste gefixter Bugs aus dem Bugtracker:
'Account Link AR_amount' => 'Forderungen Erlöskonto',
'Account Link AR_paid' => 'Forderungen Zahlungseingang',
'Account Link AR_tax' => 'Forderungen Steuer',
- 'Account Link CT_tax' => 'Kunde/Lieferant Steuer',
'Account Link IC' => 'Inventar',
'Account Link IC_cogs' => 'Warenliste Aufwandskonto',
'Account Link IC_expense' => 'Dienstleistungen Aufwandskonto',
'An invalid character was used (invalid characters: #1).' => 'Ein ungültiges Zeichen wurde benutzt (ungültige Zeichen: #1).',
'An invalid character was used (valid characters: #1).' => 'Ein ungültiges Zeichen wurde benutzt (gültige Zeichen: #1).',
'An upper-case character is required.' => 'Ein Großbuchstabe ist vorgeschrieben.',
+ 'And if the account does not act as tax-o-matic account.' => 'Und wenn das Konto kein Steuerautomatik-Konto ist.',
'Annotations' => 'Anmerkungen',
'Another user with the login #1 does already exist.' => 'Es existiert bereits ein anderer Benutzer mit diesem Login.',
'Ap aging on %s' => 'Offene Verbindlichkeiten zum %s',
'deliverydate' => 'Lieferdatum',
'direct debit' => 'Lastschrift',
'disposed' => 'Entsorgung',
+ 'do not include' => 'Nicht aufnehmen',
'done' => 'erledigt',
'down' => 'runter',
'dunning_list' => 'mahnungsliste',
'Account Link AR_amount' => 'Forderungen Erlöskonto',
'Account Link AR_paid' => 'Forderungen Zahlungseingang',
'Account Link AR_tax' => 'Forderungen Steuer',
- 'Account Link CT_tax' => 'Kunde/Lieferant Steuer',
'Account Link IC' => 'Inventar',
'Account Link IC_cogs' => 'Warenliste Aufwandskonto',
'Account Link IC_expense' => 'Dienstleistungen Aufwandskonto',
'An invalid character was used (invalid characters: #1).' => '',
'An invalid character was used (valid characters: #1).' => '',
'An upper-case character is required.' => '',
+ 'And if the account does not act as tax-o-matic account.' => 'Und wenn das Konto kein Steuerautomatik-Konto ist.',
'Annotations' => 'Hilfe',
'Another user with the login #1 does already exist.' => 'Es existiert bereits ein anderer Benutzer mit diesem Login.',
'Ap aging on %s' => 'Offene Verbindlichkeiten zum %s',
'deliverydate' => 'Lieferdatum',
'direct debit' => 'Lastschrift',
'disposed' => 'Entsorgung',
+ 'do not include' => 'Nicht aufnehmen',
'done' => 'erledigt',
'down' => 'runter',
'dunning_list' => 'mahnungsliste',
'Account Link AR_amount' => '',
'Account Link AR_paid' => '',
'Account Link AR_tax' => '',
- 'Account Link CT_tax' => '',
'Account Link IC' => '',
'Account Link IC_cogs' => '',
'Account Link IC_expense' => '',
'An invalid character was used (invalid characters: #1).' => '',
'An invalid character was used (valid characters: #1).' => '',
'An upper-case character is required.' => '',
+ 'And if the account does not act as tax-o-matic account.' => '',
'Annotations' => '',
'Another user with the login #1 does already exist.' => '',
'Ap aging on %s' => '',
'deliverydate' => '',
'direct debit' => '',
'disposed' => '',
+ 'do not include' => '',
'done' => '',
'down' => '',
'dunning_list' => '',
'Account Link AR_amount' => '',
'Account Link AR_paid' => '',
'Account Link AR_tax' => '',
- 'Account Link CT_tax' => '',
'Account Link IC' => '',
'Account Link IC_cogs' => '',
'Account Link IC_expense' => '',
insert into chart (accno,description,charttype,gifi_accno,category,link) values ('3500','VERBINDLICHKEITEN FINANZAMT','H','35','L','');
insert into chart (accno,description,charttype,gifi_accno,category,link) values ('3510','Finanzamt Verrechnung Körperschaftssteuer','A','350-359','L','');
insert into chart (accno,description,charttype,gifi_accno,category,link) values ('3520','Finanzamt Verrechnung Umsatzsteuer','A','350-359','L','');
-insert into chart (accno,description,charttype,gifi_accno,category,link) values ('3530','Mehrwertsteuer 0%','A','350-359','L','AR_tax:AP_tax:IC_taxpart:IC_taxservice:CT_tax');
-insert into chart (accno,description,charttype,gifi_accno,category,link) values ('3531','Mehrwertsteuer 10%','A','350-359','L','AR_tax:AP_tax:IC_taxpart:IC_taxservice:CT_tax');
-insert into chart (accno,description,charttype,gifi_accno,category,link) values ('3532','Mehrwertsteuer 20%','A','350-359','L','AR_tax:AP_tax:IC_taxpart:IC_taxservice:CT_tax');
-insert into chart (accno,description,charttype,gifi_accno,category,link) values ('3540','Vorsteuer 0%','A','350-359','L','AR_tax:AP_tax:IC_taxpart:IC_taxservice:CT_tax');
-insert into chart (accno,description,charttype,gifi_accno,category,link) values ('3541','Vorsteuer 10%','A','350-359','L','AR_tax:AP_tax:IC_taxpart:IC_taxservice:CT_tax');
-insert into chart (accno,description,charttype,gifi_accno,category,link) values ('3542','Vorsteuer 20%','A','350-359','L','AR_tax:AP_tax:IC_taxpart:IC_taxservice:CT_tax');
+insert into chart (accno,description,charttype,gifi_accno,category,link) values ('3530','Mehrwertsteuer 0%','A','350-359','L','AR_tax:AP_tax:IC_taxpart:IC_taxservice');
+insert into chart (accno,description,charttype,gifi_accno,category,link) values ('3531','Mehrwertsteuer 10%','A','350-359','L','AR_tax:AP_tax:IC_taxpart:IC_taxservice');
+insert into chart (accno,description,charttype,gifi_accno,category,link) values ('3532','Mehrwertsteuer 20%','A','350-359','L','AR_tax:AP_tax:IC_taxpart:IC_taxservice');
+insert into chart (accno,description,charttype,gifi_accno,category,link) values ('3540','Vorsteuer 0%','A','350-359','L','AR_tax:AP_tax:IC_taxpart:IC_taxservice');
+insert into chart (accno,description,charttype,gifi_accno,category,link) values ('3541','Vorsteuer 10%','A','350-359','L','AR_tax:AP_tax:IC_taxpart:IC_taxservice');
+insert into chart (accno,description,charttype,gifi_accno,category,link) values ('3542','Vorsteuer 20%','A','350-359','L','AR_tax:AP_tax:IC_taxpart:IC_taxservice');
insert into chart (accno,description,charttype,gifi_accno,category,link) values ('4000','UMSATZ','H','4','I','');
insert into chart (accno,description,charttype,gifi_accno,category,link) values ('4020','Verkauf - Hardware','A','40-44','I','AR_amount:IC_sale');
insert into chart (accno,description,charttype,gifi_accno,category,link) values ('4030','Verkauf - Software ','A','40-44','I','AR_amount:IC_sale');
INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('445500', 'TAXES SUR CA A DECAISSER', 'A', '', '', '');
INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('706000', 'PRESTATIONS DE SERVICES', 'A', '', 'I', 'IC_income');
INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('707000', 'VENTES DE MARCHANDISES', 'A', '', 'I', 'IC_sale');
-INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('445713', 'TVA COLLECTEE 19.6%', 'A', '', 'I', 'AR_tax:IC_taxpart:IC_taxservice:CT_tax');
+INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('445713', 'TVA COLLECTEE 19.6%', 'A', '', 'I', 'AR_tax:IC_taxpart:IC_taxservice');
INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('512020', 'BANQUE DEBIT', 'A', '', 'E', 'AP');
-INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('445711', 'TVA COLLECTEE 5.5%', 'A', '', 'I', 'AR_tax:IC_taxpart:IC_taxservice:CT_tax');
-INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('445661', 'TVA DEDUCTIBLE 5.5%', 'A', '', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax');
+INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('445711', 'TVA COLLECTEE 5.5%', 'A', '', 'I', 'AR_tax:IC_taxpart:IC_taxservice');
+INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('445661', 'TVA DEDUCTIBLE 5.5%', 'A', '', 'E', 'AP_tax:IC_taxpart:IC_taxservice');
INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('512010', 'BANQUE CREDIT', 'A', '', 'I', 'AR:AR_amount');
INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('681730', 'STOCKS ET EN-COURS', 'A', '', 'A', 'IC');
INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('580010', 'VIREMENT INTERNE', 'A', '', 'E', '');
INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('609400', 'D\'ETUDES & PRESTATIONS DE SERVICES', 'A', '', '', '');
INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('625100', 'VOYAGES ET DEPLACEMENTS', 'A', '', 'E', 'AP_amount');
INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('618300', 'DOCUMENTATION TECHNIQUE', 'A', '', 'E', 'AP_amount');
-INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('445663', 'TVA DEDUCTIBLE 19.6%', 'A', '', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax');
+INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('445663', 'TVA DEDUCTIBLE 19.6%', 'A', '', 'E', 'AP_tax:IC_taxpart:IC_taxservice');
INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('601000', 'ACHATS STOCKES MAT. PREM. (FOURN.)', 'A', '', 'E', 'AP_amount:IC_cogs');
INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('626000', 'FRAIS POSTAUX ET TELECOMMUNIC.', 'A', '', 'E', 'AP_amount');
INSERT INTO "chart" ("accno", "description", "charttype", "gifi_accno", "category", "link") VALUES ('512000', 'BANQUE', 'A', '', 'A', 'AR_paid:AP_paid');
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('0650', 'Vblk.geg.Kreditinst.- Restlaufzeit grösser als 5 Jahre', 'A', 'A', '', '0650', 0, NULL, NULL, NULL, NULL, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('4510', 'Kfz-Steuer', 'A', 'E', 'AP_amount', '4510', 0, NULL, 19, NULL, 15, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('4520', 'Kfz-Versicherungen', 'A', 'E', 'AP_amount', '4520', 0, NULL, 14, NULL, 16, FALSE);
-INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1771', 'Umsatzsteuer 7%', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice:CT_tax', '1771', 0, NULL, NULL, NULL, 5, FALSE);
-INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1775', 'Umsatzsteuer 16%', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice:CT_tax', '1775', 0, NULL, NULL, NULL, 6, FALSE);
+INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1771', 'Umsatzsteuer 7%', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice', '1771', 0, NULL, NULL, NULL, 5, FALSE);
+INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1775', 'Umsatzsteuer 16%', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice', '1775', 0, NULL, NULL, NULL, 6, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1767', 'Im anderen EG-Staat steuerpfl. Lieferung', 'A', ' ', '', '1767', 10, NULL, 0, NULL, NULL, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('0853', 'Satzungsm.Rücklagen 0% Vorbelast.(st.Einlagekto.)', 'A', 'Q', '', '0853', 0, NULL, NULL, NULL, NULL, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1607', 'Vblk.a.LuL ohne Vorsteuer (EÜR)', 'A', 'L', 'AP', '1607', 0, NULL, NULL, NULL, NULL, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('8922', 'Verwend.f.Gegenst.f.Zwecke außerh.d.Untern.16%USt(Telefonnutzung)', 'A', 'I', '', '8922', 0, 0, 5, NULL, 3, TRUE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1000', 'Kasse', 'A', 'A', 'AR_paid:AP_paid', '1000', 0, NULL, NULL, NULL, NULL, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1572', 'Steuerpflicht. EG-Erwerb 7%', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice', '1572', 0, 61, NULL, NULL, 27, FALSE);
-INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1571', 'Abziehbare Vorsteuer 7%', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax', '1570', 0, 66, NULL, NULL, 27, FALSE);
+INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1571', 'Abziehbare Vorsteuer 7%', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice', '1570', 0, 66, NULL, NULL, 27, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1573', 'Steuerpflicht. EG-Erwerb 16%', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice', '1573', 0, 61, NULL, NULL, 27, FALSE);
-INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1575', 'Abziehbare Vorsteuer 16%', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax', '1570', 0, 66, NULL, NULL, 27, FALSE);
+INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1575', 'Abziehbare Vorsteuer 16%', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice', '1570', 0, 66, NULL, NULL, 27, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1772', 'Steuerpflicht. EG-Lieferungen 7%', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice', '1772', 0, NULL, NULL, NULL, 6, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1773', 'Steuerpflicht. EG-Lieferungen 16%', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice', '1773', 0, NULL, NULL, NULL, 28, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('2501', 'Ausserordentliche Erträge finanzwirksam', 'A', 'I', '', '2501', 0, NULL, NULL, NULL, 5, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('3090', 'Energiestoffe (Fert.).', 'A', 'E', 'IC', '3090', 9, 0, 4, NULL, 8, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('4595', 'Fremdfahrzeuge', 'A', 'E', 'AP_amount', '4570', 0, NULL, 14, NULL, 17, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1450', 'Ford.a.LuL n.Durchschnittss.gem.§24UStG(EÜR)', 'A', 'A', 'AR', '1448', 0, NULL, NULL, NULL, NULL, FALSE);
-INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1577', 'Abzieb.Vorst.n.allg.Durchschnittss.UStVA Kz.63', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax', '1577', 0, NULL, NULL, NULL, 27, FALSE);
-INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1578', 'Abzieb.Vorst.n.§13b', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax', '1578', 0, NULL, NULL, NULL, 27, FALSE);
+INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1577', 'Abzieb.Vorst.n.allg.Durchschnittss.UStVA Kz.63', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice', '1577', 0, NULL, NULL, NULL, 27, FALSE);
+INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1578', 'Abzieb.Vorst.n.§13b', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice', '1578', 0, NULL, NULL, NULL, 27, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1580', 'Gegenkonto Vorsteuer §4/3 EStG', 'A', 'A', '', '1580', 0, NULL, NULL, NULL, NULL, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1581', 'Auflösung Vorst.a.Vorjahr §4/3 EStG', 'A', 'A', '', '1581', 0, NULL, NULL, NULL, NULL, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1582', 'Vorst.aus Investitionen §4/3 EStG', 'A', 'E', '', '1582', 0, NULL, NULL, NULL, 27, FALSE);
insert into taxkeys (chart_id, tax_id, taxkey_id, pos_ustva, startdate) select chart.id, tax.id, taxkey_id, pos_ustva, '1970-01-01' from chart LEFT JOIN tax on (tax.taxkey=chart.taxkey_id) WHERE taxkey_id is not null;
insert into taxkeys (chart_id, tax_id, taxkey_id,startdate) SELECT 0, id, taxkey, '1970-01-01' FROM tax;
INSERT INTO chart (accno, description, charttype, category, link, taxkey_id, pos_ustva, pos_eur)
- VALUES ('1776','Umsatzsteuer 19 %', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice:CT_tax', 0, 511,6);
+ VALUES ('1776','Umsatzsteuer 19 %', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice', 0, 511,6);
INSERT INTO chart (accno, description, charttype, category, link, taxkey_id, pos_ustva, pos_eur)
- VALUES ('1576','Abziehbare Vorsteuer 19 %', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax', 0, 66,27);
+ VALUES ('1576','Abziehbare Vorsteuer 19 %', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice', 0, 66,27);
INSERT INTO tax (chart_id, rate, taxnumber, taxkey, taxdescription) VALUES ((SELECT id from CHART WHERE accno='1776'), 0.19, '1776', 3, 'Umsatzsteuer 19%');
INSERT INTO tax (chart_id, rate, taxnumber, taxkey, taxdescription) VALUES ((SELECT id from CHART WHERE accno='1576'), 0.19, '1576', 9, 'Vorsteuer 19%');
insert into taxkeys (chart_id, tax_id, taxkey_id, pos_ustva, startdate) select chart.id, (SELECT id from tax where taxdescription='Umsatzsteuer 19%'), 3, pos_ustva, '2007-01-01' from chart WHERE taxkey_id=3;
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1249', 'Pauschwertber. zu Forder. Restlzeit >1 Jahr', 'A', 'E', '', '1249', 0, NULL, 31, NULL, NULL, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1370', 'Durchlaufende Posten', 'A', 'A', '', '1370', 0, NULL, NULL, NULL, NULL, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1374', 'Fremdgeld', 'A', 'A', '', '1374', 0, NULL, NULL, NULL, NULL, FALSE);
-INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1401', 'Abziehbare Vorsteuer 7%', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax', '1401', 0, 66, NULL, NULL, 27, FALSE);
+INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1401', 'Abziehbare Vorsteuer 7%', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice', '1401', 0, 66, NULL, NULL, 27, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1402', 'Abziehbare Vorsteuer aus innergemeinschftl. Erwerb', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice', '1402', 0, 61, NULL, NULL, 27, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1403', 'Abziehbare Vorsteuer aus innergemeinschftl. Erwerb 16%', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice', '1403', 0, 61, NULL, NULL, 27, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1404', 'Abziehbare Vorsteuer aus innergemeinschftl. Erwerb 19%', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice', '1403', 0, 61, NULL, NULL, 27, FALSE);
-INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1405', 'Abziehbare Vorsteuer 16%', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax', '1405', 0, 66, NULL, NULL, 27, FALSE);
-INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1406', 'Abziehbare Vorsteuer 19 %', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax', 0, 0, 66, NULL, NULL, 27, FALSE);
-INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1407', 'Abziehbare Vorsteuer nach § 13b UStG 19%', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax', '1407', 0, NULL, NULL, NULL, 27, FALSE);
-INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1408', 'Abziehbare Vorsteuer nach § 13b UStG', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax', '1408', 0, NULL, NULL, NULL, 27, FALSE);
-INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1409', 'Abziehbare Vorsteuer nach § 13b UStG 16%', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax', '1408', 0, NULL, NULL, NULL, 27, FALSE);
+INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1405', 'Abziehbare Vorsteuer 16%', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice', '1405', 0, 66, NULL, NULL, 27, FALSE);
+INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1406', 'Abziehbare Vorsteuer 19 %', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice', 0, 0, 66, NULL, NULL, 27, FALSE);
+INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1407', 'Abziehbare Vorsteuer nach § 13b UStG 19%', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice', '1407', 0, NULL, NULL, NULL, 27, FALSE);
+INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1408', 'Abziehbare Vorsteuer nach § 13b UStG', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice', '1408', 0, NULL, NULL, NULL, 27, FALSE);
+INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1409', 'Abziehbare Vorsteuer nach § 13b UStG 16%', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice', '1408', 0, NULL, NULL, NULL, 27, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1432', 'abziehb. VorSt EU-Erwerb Neufzg.b.Lief. o. USt-IdNr.', 'A', 'E', 'AR_tax', '1483', 0, NULL, NULL, NULL, 27, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1433', 'Bezahlte Einfuhrumsatzsteuer', 'A', 'E', '', '1433', 0, 62, NULL, NULL, NULL, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('1460', 'Geldtransit', 'A', 'A', '', '1460', 0, NULL, NULL, NULL, NULL, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('3306', 'Verbindlk. aus LuL zum erm. USTsatz (EÜR)', 'A', 'L', 'AP', '3306', 0, NULL, NULL, NULL, NULL, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('3307', 'Verbindlk. aus LuL ohne Vorsteuer (EÜR)', 'A', 'L', 'AP', '3307', 0, NULL, NULL, NULL, NULL, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('3309', 'Gegenkonto 3305-3307 bei Auteilung d. Forder. nach Steuersätzen (EÜR)', 'A', 'L', '', '3309', 0, NULL, NULL, NULL, NULL, FALSE);
-INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('3801', 'Umsatzsteuer 7%', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice:CT_tax', '3801', 0, NULL, NULL, NULL, 5, FALSE);
+INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('3801', 'Umsatzsteuer 7%', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice', '3801', 0, NULL, NULL, NULL, 5, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('3802', 'Umsatzsteuer aus innergemeinschftl. Erwerb', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice', '3802', 0, NULL, NULL, NULL, 6, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('3803', 'Umsatzsteuer aus innergemeinschftl. Erwerb 16%', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice', '3803', 0, NULL, NULL, NULL, 28, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('3804', 'Umsatzsteuer aus innergemeinschftl. Erwerb 19%', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice', '3803', 0, NULL, NULL, NULL, 28, FALSE);
-INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('3805', 'Umsatzsteuer 16%', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice:CT_tax', '3805', 0, NULL, NULL, NULL, 6, FALSE);
-INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('3806', 'Umsatzsteuer 19%', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice:CT_tax', '3805', 0, 511, NULL, NULL, 6, FALSE);
+INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('3805', 'Umsatzsteuer 16%', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice', '3805', 0, NULL, NULL, NULL, 6, FALSE);
+INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('3806', 'Umsatzsteuer 19%', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice', '3805', 0, 511, NULL, NULL, 6, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('3817', 'Umsatzsteuer aus in anderen EG-Land stpfl. Lieferungen', 'A', ' ', '', '3817', 10, NULL, 0, NULL, NULL, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('3820', 'Umsatzsteuer-Vorauszahlungen', 'A', 'E', '', '3820', 0, NULL, NULL, NULL, 28, FALSE);
INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('3830', 'Umsatzsteuer-Vorauszahlungen 1/11', 'A', 'E', '', '3830', 0, NULL, NULL, NULL, 28, FALSE);
if (!$count) {
$query =
qq|INSERT INTO chart (accno, description, charttype, category, link, taxkey_id, pos_ustva, pos_eur)
- VALUES ('1776','Umsatzsteuer 19 %', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice:CT_tax', 0, 511,6)|;
+ VALUES ('1776','Umsatzsteuer 19 %', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice', 0, 511,6)|;
$dbh->do($query) || mydberror($query);
}
$query = "SELECT COUNT(*) FROM chart " .
if (!$count) {
$query =
qq|INSERT INTO chart (accno, description, charttype, category, link, taxkey_id, pos_ustva, pos_eur)
- VALUES ('1576','Abziehbare Vorsteuer 19 %', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax', 0, 66,27)|;
+ VALUES ('1576','Abziehbare Vorsteuer 19 %', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice', 0, 66,27)|;
$dbh->do($query) || mydberror($query);
}
if (!$count) {
$query =
qq|INSERT INTO chart (accno, description, charttype, category, link, taxkey_id, pos_ustva, pos_eur)
- VALUES ('3806','Umsatzsteuer 19 %', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice:CT_tax', 0, 511,6)|;
+ VALUES ('3806','Umsatzsteuer 19 %', 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice', 0, 511,6)|;
$dbh->do($query) || mydberror($query);
}
$query = "SELECT COUNT(*) FROM chart " .
if (!$count) {
$query =
qq|INSERT INTO chart (accno, description, charttype, category, link, taxkey_id, pos_ustva, pos_eur)
- VALUES ('1406','Abziehbare Vorsteuer 19 %', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax', 0, 66,27)|;
+ VALUES ('1406','Abziehbare Vorsteuer 19 %', 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice', 0, 66,27)|;
$dbh->do($query) || mydberror($query);
}
)
SELECT
'1570','Anrechenbare Vorsteuer',
- 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax',
+ 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice',
0
WHERE EXISTS ( -- update only for SKR03
SELECT coa FROM defaults
)
SELECT
'1574','Abziehbare Vorsteuer aus innergem. Erwerb 19 %',
- 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax',
+ 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice',
0
WHERE EXISTS ( -- update only for SKR03
SELECT coa FROM defaults
)
SELECT
'1774','Umsatzsteuer aus innergem. Erwerb 19 %',
- 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice:CT_tax',
+ 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice',
0
WHERE EXISTS ( -- update only for SKR03
SELECT coa FROM defaults
INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('21205','Leasing','A','21200','L','AP');
INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('21210','Kurzfristige Finanzverbindlichkeiten','H','21000','L','');
INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('21220','Andere kurzfristige Verbindlichkeiten','H','21000','L','');
-INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('21222','MWST (3,6)','A','21220','L','AR_tax:AP_tax:IC_taxpart:IC_taxservice:CT_tax');
+INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('21222','MWST (3,6)','A','21220','L','AR_tax:AP_tax:IC_taxpart:IC_taxservice');
INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('21229','Gewinnausschüttung','A','21220','L','');
INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('21230','Passive Rechnungsabgrenzung, kurzfristige Rückstellungen','H','21000','L','');
INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('21235','Rückstellungen','A','21230','L','');
INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('36002','Reise (Fahrt)','A','36000','I','IC_income');
INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('11117','MWST Vorsteuer auf Aufwand','A','11110','A','');
INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('21228','Geschuldete Steuern','A','21220','L','AP');
-INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('21223','MWST (7,6)','A','21220','L','AR_tax:AP_tax:IC_taxpart:IC_expense:IC_taxservice:CT_tax');
+INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('21223','MWST (7,6)','A','21220','L','AR_tax:AP_tax:IC_taxpart:IC_expense:IC_taxservice');
INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('57001','AHV, IV, EO, ALV','A','57000','E','AP_amount:IC_income:IC_expense');
-INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('21221','MWST (2,4)','A','21220','L','AR_tax:AP_tax:IC_taxpart:IC_taxservice:CT_tax');
-INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('21224','MWST (7.6) 1/2','A','21220','L','AR_tax:AP_tax:IC_taxpart:IC_expense:IC_taxservice:CT_tax');
+INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('21221','MWST (2,4)','A','21220','L','AR_tax:AP_tax:IC_taxpart:IC_taxservice');
+INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('21224','MWST (7.6) 1/2','A','21220','L','AR_tax:AP_tax:IC_taxpart:IC_expense:IC_taxservice');
INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('66001','Werbeaufwand','A','66000','E','AP_amount:IC_expense');
INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('21217','Privat','A','21210','L','AP');
INSERT INTO chart (accno,description,charttype,gifi_accno,category,link) VALUES ('11101','Kasse','A','11100','A','AR_paid:AP_paid');
[%- USE T8 %]
+[%- USE L %]
[% USE HTML %]<script type="text/javascript" src="js/FormManager.js" >
/****************************************************
* Form Dependency Manager- By Twey- http://www.twey.co.uk
</fieldset>
[% IF AccountIsPosted %]
-[%- SET DIS = ' disabled="disabled"' %]
+ [% IF AR_amount %] [% L.hidden_tag('AR_amount', 'AR_amount') %] [% END %]
+ [% IF AR_paid %] [% L.hidden_tag('AR_paid', 'AR_paid') %] [% END %]
+ [% IF AR_tax %] [% L.hidden_tag('AR_tax', 'AR_tax') %] [% END %]
+ [% IF AP_amount %] [% L.hidden_tag('AP_amount', 'AP_amount') %] [% END %]
+ [% IF AP_paid %] [% L.hidden_tag('AP_paid', 'AP_paid') %] [% END %]
+ [% IF AP_tax %] [% L.hidden_tag('AP_tax', 'AP_tax') %] [% END %]
+ [%- SET DIS = ' disabled="disabled"' %]
[% END %]
<fieldset class="DEPENDS ON charttype BEING A">
<legend>[% 'Include in drop-down menus' | $T8 %]</legend>
<p style='font-weight:normal'>[% 'These will only be effective if the account is NOT a summary account AND there exists at least one taxkey. Setting the account as a summary account will erase these settings.' | $T8 %]</p>
- <p style='font-weight:normal'>[% 'Changes to Receivables and Payables are only possible if no transactions to this account are posted yet.' | $T8 %]</p>
+ <p style='font-weight:normal'>[% 'Changes to Receivables and Payables are only possible if no transactions to this account are posted yet.' | $T8 %]
+ [% 'And if the account does not act as tax-o-matic account.' | $T8 %]</p>
<table width="100%">
<tr>
<th align="left">[% 'Receivables' | $T8 %]</th>
</tr>
<tr>
<td>
- <input name="AR_amount" type="checkbox" class="checkbox" value="AR_amount"
- [% HTML.escape(AR_amount)%][% DIS %]>
- [% 'Revenue' | $T8 %] <br>
- <input name="AR_paid" type="checkbox" class="checkbox" value="AR_paid"
- [% HTML.escape(AR_paid) %][% DIS %]>
- [% 'Receipt' | $T8 %] <br>
- <input name="AR_tax" type="checkbox" class="checkbox" value="AR_tax"
- [% HTML.escape(AR_tax) %][% DIS %]>
- [% 'Tax' | $T8 %]
+ [% L.radio_button_tag('AR_include_in_dropdown',
+ value => 'AR_amount',
+ disabled => AccountIsPosted,
+ checked => AR_amount) %]
+ [% 'Revenue' | $T8 %] <br>
+ [% L.radio_button_tag('AR_include_in_dropdown',
+ value => 'AR_paid',
+ disabled => AccountIsPosted,
+ checked => AR_paid) %]
+ [% 'Receipt' | $T8 %] <br>
+ [% L.radio_button_tag('AR_include_in_dropdown',
+ value => 'AR_tax',
+ disabled => AccountIsPosted,
+ checked => AR_tax) %]
+ [% 'Tax' | $T8 %] <br>
+ [% L.radio_button_tag('AR_include_in_dropdown',
+ value => '',
+ disabled => AccountIsPosted) %]
+ [% 'do not include' | $T8 %]
</td>
<td>
- <input name="AP_amount" type="checkbox" class="checkbox" value="AP_amount"
- [% HTML.escape(AP_amount) %][% DIS %]>
- [% 'Expense/Asset' | $T8 %] <br>
- <input name="AP_paid" type="checkbox" class="checkbox" value="AP_paid"
- [% HTML.escape(AP_paid) %][% DIS %]>
- [% 'Payment' | $T8 %] <br>
- <input name="AP_tax" type="checkbox" class="checkbox" value="AP_tax"
- [% HTML.escape(AP_tax) %][% DIS %]>
- [% 'Tax' | $T8 %]
+ [% L.radio_button_tag('AP_include_in_dropdown',
+ value => 'AP_amount',
+ disabled => AccountIsPosted,
+ checked => AP_amount) %]
+ [% 'Expense/Asset' | $T8 %] <br>
+ [% L.radio_button_tag('AP_include_in_dropdown',
+ value => 'AP_paid',
+ disabled => AccountIsPosted,
+ checked => AP_paid) %]
+ [% 'Payment' | $T8 %] <br>
+ [% L.radio_button_tag('AP_include_in_dropdown',
+ value => 'AP_tax',
+ disabled => AccountIsPosted,
+ checked => AP_tax) %]
+ [% 'Tax' | $T8 %] <br>
+ [% L.radio_button_tag('AP_include_in_dropdown',
+ value => '',
+ disabled => AccountIsPosted) %]
+ [% 'do not include' | $T8 %]
</td>
<td>
<input name="IC_sale" type="checkbox" class="checkbox" value="IC_sale"
<input name="IC_taxpart" type="checkbox" class="checkbox" value="IC_taxpart"
[% HTML.escape(IC_taxpart) %]>
[% 'Tax' | $T8 %]
+ <br><br>
</td>
<td>
<input name=IC_income type=checkbox class=checkbox value="IC_income"
<input name=IC_taxservice type=checkbox class=checkbox value="IC_taxservice"
[% HTML.escape(IC_taxservice) %]>
[% 'Tax' | $T8 %]
+ <br><br>
</td>
</tr>
</table>