mirror of
https://gitlab.com/t6353/sharee.bike.git
synced 2025-05-09 21:46:34 +02:00
Faktura warning fixes
This commit is contained in:
parent
6747fa4fc2
commit
8547c6efa4
4 changed files with 21 additions and 11 deletions
|
@ -394,7 +394,7 @@ sub handler {
|
||||||
}elsif($R::detail_search && $R::detail_search eq "operator_accounting"){
|
}elsif($R::detail_search && $R::detail_search eq "operator_accounting"){
|
||||||
my $ck4ex = "@R::ck4ex" || "";
|
my $ck4ex = "@R::ck4ex" || "";
|
||||||
$return = $pl->operator_accounting($q,$users_dms,$users_sharee,$R::accounting_type,$ck4ex);
|
$return = $pl->operator_accounting($q,$users_dms,$users_sharee,$R::accounting_type,$ck4ex);
|
||||||
}else{
|
}elsif($R::ct_trans){
|
||||||
$return .= "|";
|
$return .= "|";
|
||||||
$return .= $pre->preinit($users_dms,$lang);#transactions logic
|
$return .= $pre->preinit($users_dms,$lang);#transactions logic
|
||||||
}
|
}
|
||||||
|
|
|
@ -504,6 +504,7 @@ sub set_workflow {
|
||||||
delete $ctt->{txt22};
|
delete $ctt->{txt22};
|
||||||
delete $ctt->{txt23};
|
delete $ctt->{txt23};
|
||||||
delete $ctt->{txt25};
|
delete $ctt->{txt25};
|
||||||
|
delete $ctt->{txt28};
|
||||||
delete $ctt->{txt30};
|
delete $ctt->{txt30};
|
||||||
delete $ctt->{itime};
|
delete $ctt->{itime};
|
||||||
delete $ctt->{mtime};
|
delete $ctt->{mtime};
|
||||||
|
|
|
@ -102,7 +102,10 @@ sub preinit(){
|
||||||
# }
|
# }
|
||||||
#}
|
#}
|
||||||
|
|
||||||
|
if(!looks_like_number($R::c_id4trans) || !looks_like_number($R::tpl_id4trans)){
|
||||||
|
print FILE Dumper($q);
|
||||||
|
return "failure::Fehler<br /> Daten ID's nicht vollständig ($R::c_id4trans || $R::tpl_id4trans)";
|
||||||
|
}
|
||||||
|
|
||||||
#international buttons
|
#international buttons
|
||||||
my ($key,$val,$ib_key);
|
my ($key,$val,$ib_key);
|
||||||
|
@ -113,7 +116,7 @@ sub preinit(){
|
||||||
my ($ct_last,$c_idnew);
|
my ($ct_last,$c_idnew);
|
||||||
|
|
||||||
my $table = "contenttrans";
|
my $table = "contenttrans";
|
||||||
my $ctt = $db->get_content1($table,$users_dms->{c_id4trans});
|
my $ctt = $db->get_content1($table,$R::c_id4trans);
|
||||||
my $buchen_mtime = $lb->time4de($ctt->{mtime});
|
my $buchen_mtime = $lb->time4de($ctt->{mtime});
|
||||||
|
|
||||||
#actual-path an get right mandant for verkauf
|
#actual-path an get right mandant for verkauf
|
||||||
|
@ -125,8 +128,8 @@ sub preinit(){
|
||||||
if(!$parent_trans->{main_id}){
|
if(!$parent_trans->{main_id}){
|
||||||
return "failure::Fehler<br /> keine eindeutige Modulzuweisung vorhanden.";
|
return "failure::Fehler<br /> keine eindeutige Modulzuweisung vorhanden.";
|
||||||
}
|
}
|
||||||
my $rel = $db->get_rel4tpl4nd($parent_trans->{main_id},$lang,$users_dms->{c_id4trans});
|
my $rel = $db->get_rel4tpl4nd($parent_trans->{main_id},$lang,$R::c_id4trans);
|
||||||
$rel = $db->get_rel4tpl4nd("",$lang,$users_dms->{c_id4trans},$rel->{template_id}) if($users_dms->{c_id4trans} > "0");
|
$rel = $db->get_rel4tpl4nd("",$lang,$R::c_id4trans,$rel->{template_id}) if($R::c_id4trans > "0");
|
||||||
|
|
||||||
my $ct_name = $q->escapeHTML("$R::ct_name");
|
my $ct_name = $q->escapeHTML("$R::ct_name");
|
||||||
my $barcode=0;
|
my $barcode=0;
|
||||||
|
@ -222,7 +225,7 @@ sub preinit(){
|
||||||
|
|
||||||
if($ct->{main_id}){
|
if($ct->{main_id}){
|
||||||
$users_dms = $db->select_users($users_dms->{u_id}) if($ib_key =~ /new_/);#nur bei new_ mit save_
|
$users_dms = $db->select_users($users_dms->{u_id}) if($ib_key =~ /new_/);#nur bei new_ mit save_
|
||||||
if(!$users_dms->{c_id4trans} && $ib_key !~ /new_transdate/){
|
if(!$R::c_id4trans && $ib_key !~ /new_transdate/){
|
||||||
return "failure::Zu welchem Vorgang soll die Aktion verknüpft werden? Bitte erst den entsprechenden Vorgang öffnen.";
|
return "failure::Zu welchem Vorgang soll die Aktion verknüpft werden? Bitte erst den entsprechenden Vorgang öffnen.";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -236,7 +239,7 @@ sub preinit(){
|
||||||
#Add Parts from content to contenttranspos#################
|
#Add Parts from content to contenttranspos#################
|
||||||
my $pos_id = 0;
|
my $pos_id = 0;
|
||||||
|
|
||||||
my $ctt = $db->get_content1("contenttrans",$users_dms->{c_id4trans});
|
my $ctt = $db->get_content1("contenttrans",$R::c_id4trans);
|
||||||
my $ctadr = $db->get_content1("contentadr",$ctt->{int10});
|
my $ctadr = $db->get_content1("contentadr",$ctt->{int10});
|
||||||
$pos_id = $dbt->insert_pos($dbh,$ctt->{c_id},$ct,"",$ctadr,"","",$partnr,"0",$users_dms->{u_id},"");
|
$pos_id = $dbt->insert_pos($dbh,$ctt->{c_id},$ct,"",$ctadr,"","",$partnr,"0",$users_dms->{u_id},"");
|
||||||
|
|
||||||
|
@ -547,12 +550,12 @@ sub preinit(){
|
||||||
$R::set_main_id = $R::open_set_main_id;
|
$R::set_main_id = $R::open_set_main_id;
|
||||||
$users_dms = $db->select_users($users_dms->{u_id});
|
$users_dms = $db->select_users($users_dms->{u_id});
|
||||||
}
|
}
|
||||||
my $c_id = $users_dms->{c_id4trans} || "";#Document id
|
my $c_id = $R::c_id4trans || "";#Document id
|
||||||
return "failure::Abbruch, die Aktion konnte keinem Dokument zugeordnet werden. Arbeiten Sie mit mehreren Browser-Tabs? Bitte multiple COPRI Tabs schließen und anschließend das Verkauf-Terminal neu öffnen." if(!$c_id);
|
return "failure::Abbruch, die Aktion konnte keinem Dokument zugeordnet werden. Arbeiten Sie mit mehreren Browser-Tabs? Bitte multiple COPRI Tabs schließen und anschließend das Verkauf-Terminal neu öffnen." if(!$c_id);
|
||||||
|
|
||||||
my $table = "contenttrans";
|
my $table = "contenttrans";
|
||||||
my $ctt = { c_id => 0 };
|
my $ctt = { c_id => 0 };
|
||||||
my $rel = $db->get_rel4tpl("",$lang,$users_dms->{c_id4trans},$users_dms->{tpl_id4trans});
|
my $rel = $db->get_rel4tpl("",$lang,$R::c_id4trans,$R::tpl_id4trans);
|
||||||
$ctt = $db->get_content1("contenttrans",$rel->{content_id});
|
$ctt = $db->get_content1("contenttrans",$rel->{content_id});
|
||||||
return "failure::Bitte erst einen Formular-Typ wählen" if($R::set_main_id <= "300000");
|
return "failure::Bitte erst einen Formular-Typ wählen" if($R::set_main_id <= "300000");
|
||||||
$u_rows += $db->update_relation2("",$lang,$R::set_main_id,"",$rel->{rel_id}) if(!$R::close_time && $rel->{rel_id});
|
$u_rows += $db->update_relation2("",$lang,$R::set_main_id,"",$rel->{rel_id}) if(!$R::close_time && $rel->{rel_id});
|
||||||
|
@ -566,6 +569,7 @@ sub preinit(){
|
||||||
owner => $users_dms->{u_id},
|
owner => $users_dms->{u_id},
|
||||||
};
|
};
|
||||||
|
|
||||||
|
print FILE "c_id4trans:$R::c_id4trans,tpl_id4trans:$R::tpl_id4trans by condition: ($node_faktura->{invoice_nr} > 0) && ($ctt->{ct_name} !~ /\d/ || $R::set_main_id != $rel->{main_id})\n";
|
||||||
if($node_faktura->{invoice_nr} > 0 && $ctt->{c_id} > 0 && ($ctt->{ct_name} !~ /\d/ || $R::set_main_id != $rel->{main_id})){
|
if($node_faktura->{invoice_nr} > 0 && $ctt->{c_id} > 0 && ($ctt->{ct_name} !~ /\d/ || $R::set_main_id != $rel->{main_id})){
|
||||||
|
|
||||||
my $nextNr = $node_faktura->{invoice_nr};
|
my $nextNr = $node_faktura->{invoice_nr};
|
||||||
|
@ -583,7 +587,7 @@ sub preinit(){
|
||||||
$update_ctt->{txt00} = $node->{node_name};
|
$update_ctt->{txt00} = $node->{node_name};
|
||||||
$u_rows += $dbt->update_record($dbh,$update_ctt,$ctt);
|
$u_rows += $dbt->update_record($dbh,$update_ctt,$ctt);
|
||||||
|
|
||||||
print FILE "invoice_nr:$invoice_nr,$users_dms->{c_id4trans},$users_dms->{tpl_id4trans} by condition: ($node_faktura->{invoice_nr} > 0) && ($ctt->{ct_name} !~ /\d/ || $R::set_main_id != $rel->{main_id})\n";
|
print FILE "invoice_nr:$invoice_nr,c_id4trans:$R::c_id4trans,tpl_id4trans:$R::tpl_id4trans by condition: ($node_faktura->{invoice_nr} > 0) && ($ctt->{ct_name} !~ /\d/ || $R::set_main_id != $rel->{main_id})\n";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -667,7 +671,7 @@ sub preinit(){
|
||||||
}
|
}
|
||||||
###end SET Relation or state (V Terminal submit's)
|
###end SET Relation or state (V Terminal submit's)
|
||||||
|
|
||||||
my $c_id4print = $users_dms->{c_id4trans};
|
my $c_id4print = $R::c_id4trans;
|
||||||
$c_id4print= $R::c_id if($R::printer_id =~ /Adresse|Kunde/);
|
$c_id4print= $R::c_id if($R::printer_id =~ /Adresse|Kunde/);
|
||||||
if($c_id4print){
|
if($c_id4print){
|
||||||
my $print_return = "";
|
my $print_return = "";
|
||||||
|
|
|
@ -378,6 +378,11 @@ EOF
|
||||||
if($ctt->{txt00} eq "Storno"){
|
if($ctt->{txt00} eq "Storno"){
|
||||||
print $q->td({-class=>'tdval5',-colspan=>"1"},""),"\n";
|
print $q->td({-class=>'tdval5',-colspan=>"1"},""),"\n";
|
||||||
}else{
|
}else{
|
||||||
|
if($ctt->{ct_name} =~ /^\d+$/){
|
||||||
|
undef @s_valxx[3];
|
||||||
|
undef @s_valxx[4];
|
||||||
|
undef @s_valxx[5];
|
||||||
|
}
|
||||||
print $q->td({-class=>'tdval5',-colspan=>"1"},"Mahnstufe",$but->selector_class("int06","","",$ctt->{int06},@s_valxx)),"\n";
|
print $q->td({-class=>'tdval5',-colspan=>"1"},"Mahnstufe",$but->selector_class("int06","","",$ctt->{int06},@s_valxx)),"\n";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue