mirror of
https://gitlab.com/t6353/sharee.bike.git
synced 2025-02-22 19:56:29 +01:00
Statistic files and accounting netto
This commit is contained in:
parent
7744e1dccc
commit
bbe973ea70
13 changed files with 127 additions and 67 deletions
|
@ -530,7 +530,16 @@ div#Oline {
|
|||
border-right: solid thin silver;
|
||||
border-bottom: solid thin silver;
|
||||
}
|
||||
|
||||
.tdtxt3 {
|
||||
padding:0.2em 0.5em;
|
||||
vertical-align: top;
|
||||
text-align: left;
|
||||
min-width:45px;
|
||||
font-size:0.81em;
|
||||
background-color:white;
|
||||
border-right: solid thin silver;
|
||||
border-bottom: solid thin silver;
|
||||
}
|
||||
.tdsum {
|
||||
padding:0.1em 0.5em;
|
||||
vertical-align: top;
|
||||
|
@ -720,7 +729,14 @@ div#Content4list {
|
|||
padding: 40px 5px 5px 0px;
|
||||
min-width: 2000px;
|
||||
}
|
||||
|
||||
div#Content4sublist {
|
||||
text-align:left;
|
||||
font-size:15px;
|
||||
border: 0px solid yellow;
|
||||
margin: 0;
|
||||
padding: 40px 5px 5px 0px;
|
||||
min-width: 200px;
|
||||
}
|
||||
div#Content4cal {
|
||||
text-align:left;
|
||||
font-size:14px;
|
|
@ -28,7 +28,13 @@ sub handler {
|
|||
my %varenv = $cf->envonline();
|
||||
my $filesuff = $q->param('file');
|
||||
|
||||
if($filesuff =~ /\.pdf/){
|
||||
rcopy("$varenv{basedir}/pdfinvoice/$filesuff","$varenv{basedir}/cache/$coo/$filesuff");
|
||||
}elsif($filesuff =~ /got_last\.csv/i){
|
||||
rcopy("$varenv{basedir}/ftp/SWK_codes/$filesuff","$varenv{basedir}/cache/$coo/$filesuff");
|
||||
}elsif($filesuff =~ /Statistik_\d{4}-\d{2}\.zip/i){
|
||||
rcopy("$varenv{basedir}/csv/$filesuff","$varenv{basedir}/cache/$coo/$filesuff");
|
||||
}
|
||||
print $q->redirect(-uri=>"$varenv{metahost}/cache/$coo/$filesuff", -type=>"application/octet-stream");
|
||||
#remove_tree("$varenv{basedir}/cache/$coo");
|
||||
#
|
||||
|
|
|
@ -502,28 +502,42 @@ sub operator_accounting2calc {
|
|||
foreach(@tplf_order){
|
||||
my ($key,$val,$size) = split /=/,$_;
|
||||
if($key =~ /int/){
|
||||
$oac->{int01} = $oac->{int01} + $ctpos->{int01} if($key eq "int01" && $ctpos->{int01});#invoice capture
|
||||
$oac->{int99} = $ctpos->{int01} if($key eq "int01" && $ctpos->{int01});#invoice capture brutto
|
||||
$oac->{int01} = $ctpos->{int01} / 119 * 100 if($key eq "int01" && $ctpos->{int01});#invoice capture netto
|
||||
|
||||
if($ctpos->{state} =~ /Lastschrift/){
|
||||
$oac->{int93} = $oac->{int01} / 100 * $ctf->{$key} * -1 if($key eq "int01");#7,5%
|
||||
$oac->{int93} = sprintf('%.3f', $oac->{int93});
|
||||
$oac->{int98} = $oac->{int93} * 0.19 if($oac->{int93});#UmSt auf 7,5%
|
||||
$oac->{int94} = $oac->{int01} / 100 * $ctf->{$key} * -1 if($key eq "int02");#Disagio %
|
||||
$oac->{int99} = $oac->{int94} * 0.19 if($varenv->{dbname} eq "sharee_sx" && $oac->{int94});#UmSt TeilRad Disagio
|
||||
$oac->{int95} = $ctf->{$key} * -1 if($key eq "int04");#Trans
|
||||
$oac->{int96} = $ctf->{$key} * -1 if($key eq "int06");#Zahlungsmeldung
|
||||
$oac->{int98} = sprintf('%.3f', $oac->{int98});
|
||||
$oac->{int94} = $oac->{int01} / 100 * $ctf->{$key} * -1 if($key eq "int02");#po Disagio %
|
||||
$oac->{int94} = sprintf('%.3f', $oac->{int94});
|
||||
$oac->{int95} = $ctf->{$key} * -1 if($key eq "int04");#po Trans
|
||||
$oac->{int95} = sprintf('%.3f', $oac->{int95});
|
||||
$oac->{int96} = $ctf->{$key} * -1 if($key eq "int06");#po Zahlungsmeldung
|
||||
$oac->{int96} = sprintf('%.3f', $oac->{int96});
|
||||
$oac->{int97} = 0;
|
||||
}
|
||||
if($ctpos->{state} =~ /Kreditkarte/){
|
||||
$oac->{int93} = $oac->{int01} / 100 * $ctf->{$key} * -1 if($key eq "int01");#7,5%
|
||||
$oac->{int93} = sprintf('%.3f', $oac->{int93});
|
||||
$oac->{int98} = $oac->{int93} * 0.19 if($oac->{int93});#UmSt auf 7,5%
|
||||
$oac->{int94} = $oac->{int01} / 100 * $ctf->{$key} * -1 if($key eq "int03");#Disagio %
|
||||
$oac->{int99} = $oac->{int94} * 0.19 if($varenv->{dbname} eq "sharee_sx" && $oac->{int94});#UmSt TeilRad Disagio
|
||||
$oac->{int95} = $ctf->{$key} * -1 if($key eq "int05");#Trans
|
||||
$oac->{int96} = $ctf->{$key} * -1 if($key eq "int06");#Zahlungsmeldung
|
||||
$oac->{int97} = $ctf->{$key} * -1 if($key eq "int07");#CC Zuordnung
|
||||
$oac->{int98} = sprintf('%.3f', $oac->{int98});
|
||||
$oac->{int94} = $oac->{int01} / 100 * $ctf->{$key} * -1 if($key eq "int03");#po Disagio %
|
||||
$oac->{int94} = sprintf('%.3f', $oac->{int94});
|
||||
$oac->{int95} = $ctf->{$key} * -1 if($key eq "int05");#po Trans
|
||||
$oac->{int95} = sprintf('%.3f', $oac->{int95});
|
||||
$oac->{int96} = $ctf->{$key} * -1 if($key eq "int06");#po Zahlungsmeldung
|
||||
$oac->{int96} = sprintf('%.3f', $oac->{int96});
|
||||
$oac->{int97} = $ctf->{$key} * -1 if($key eq "int07");#po CC Zuordnung
|
||||
$oac->{int97} = sprintf('%.3f', $oac->{int97});
|
||||
}
|
||||
#operator accounting
|
||||
$oac->{int02} = $oac->{int01} + $oac->{int93} + $oac->{int98} + $oac->{int94} + $oac->{int99} + $oac->{int95} + $oac->{int96} + $oac->{int97};
|
||||
$oac->{int100} = ($oac->{int93} + $oac->{int98} + $oac->{int94} + $oac->{int99}) * -1;
|
||||
$oac->{int02} = $oac->{int01} + $oac->{int94} + $oac->{int95} + $oac->{int96} + $oac->{int97};
|
||||
$oac->{int02} = sprintf('%.3f', $oac->{int02});
|
||||
#operator invoice
|
||||
$oac->{int100} = ($oac->{int93} + $oac->{int98}) * -1;
|
||||
$oac->{int100} = sprintf('%.3f', $oac->{int100});
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -160,7 +160,7 @@ td {
|
|||
my $site_all=1;
|
||||
|
||||
my $header_top = 0;
|
||||
my $footer_px = 1800;
|
||||
my $footer_px = 1790;
|
||||
my $footer_top = $footer_px;#end 1.site
|
||||
|
||||
my $sum_paid = 0;
|
||||
|
@ -424,17 +424,16 @@ td {
|
|||
my @tpl_order = ();
|
||||
|
||||
#int9x are not in db
|
||||
#operator invoice
|
||||
if($ctt->{txt00} eq "Rechnung"){
|
||||
@tpl_order = ("c_id=ID","int01=Summe Einzug","state=Zahlungsart","int93=TeilRad Gebühren","int98=TeilRad Gebühren 19%","int100=Summe");
|
||||
if($varenv->{dbname} eq "sharee_sx"){
|
||||
@tpl_order = ("c_id=ID","int01=Summe Einzug","state=Zahlungsart","int93=TeilRad Gebühren","int98=TeilRad Gebühren 19%","int94=TeilRad Disagio","int99=TeilRad Disagio 19%","int100=Summe");
|
||||
@tpl_order = ("c_id=ID","int01=Summe Einzug","state=Zahlungsart","int93=TeilRad Gebühren","int98=19% UmSt","int100=Summe");
|
||||
}
|
||||
}
|
||||
#default to Abrechnung
|
||||
#operator accounting
|
||||
else{
|
||||
@tpl_order = ("c_id=ID","int01=Summe Einzug","state=Zahlungsart","int93=TeilRad Gebühren","int98=TeilRad Gebühren 19%","int94=payone Disagio","int95=payone Transaktion","int96=payone Zahlungs-meldung","int97=payone Kreditkarte Zuordnung","int02=Summe Gutschrift");
|
||||
if($varenv->{dbname} eq "sharee_sx"){
|
||||
@tpl_order = ("c_id=ID","int01=Summe Einzug","state=Zahlungsart","int93=TeilRad Gebühren","int98=TeilRad Gebühren 19%","int94=TeilRad Disagio","int99=TeilRad Disagio 19%","int02=Summe Gutschrift");
|
||||
@tpl_order = ("c_id=ID","int01=Summe Einzug","state=Zahlungsart","int94=payone Disagio","int02=Summe Gutschrift");
|
||||
}else{
|
||||
@tpl_order = ("c_id=ID","int01=Summe Einzug","state=Zahlungsart","int94=payone Disagio","int95=payone Transaktion","int96=payone Zahlungsmeldung","int97=payone Kreditkarte Zuordnung","int02=Summe Gutschrift");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -934,7 +933,7 @@ td {
|
|||
$line = $footer_top if($debug);
|
||||
|
||||
print "<div style='border:0px solid black;background-color:white;height:150px;width:$width;position:absolute;top:$footer_top;'>$line\n";
|
||||
if($ctt->{txt00} eq "Abrechnung"){
|
||||
if($ctt->{int10} == 2){
|
||||
my $tplop = $dbt->get_tpl($dbh,"196");#Operator-Faktura
|
||||
my @tplop_order = split /,/,$tplop->{tpl_order};
|
||||
foreach(@tplop_order){
|
||||
|
|
|
@ -188,6 +188,7 @@ sub tpl(){
|
|||
$search->{barcode} = $q->escapeHTML("$R::barcode");
|
||||
$search->{ct_txt06} = $q->escapeHTML("$R::ct_txt06");#PLZ
|
||||
$search->{ct_ct_name} = $q->escapeHTML("$R::ct_ct_name");
|
||||
$search->{owner} = $q->escapeHTML("$R::owner");
|
||||
}
|
||||
|
||||
if(!$start_chck && !$end_chck){
|
||||
|
|
|
@ -70,6 +70,8 @@ sub tpl(){
|
|||
my $now_db = strftime("%d.%m.%Y %H:%M:%S",localtime(time));
|
||||
my $dbh = "";
|
||||
my $debug = 0;
|
||||
my $coo = $q->cookie(-name=>'domcookie') || "";
|
||||
my $opdir_dms = "$dbt->{copri_conf}->{basedir}/$dbt->{operator}->{$varenv{dbname}}->{dir_dms}" || "";
|
||||
|
||||
$path =~ s/\/login|\/user|\/manager|\/admin|\/$//;
|
||||
my $user_agent = $q->user_agent();
|
||||
|
@ -526,7 +528,8 @@ sub tpl(){
|
|||
$new_key="new_tver";
|
||||
$delete_key="delete_tver";
|
||||
}
|
||||
if($node_meta->{parent_id} >= "200000" && $node_meta->{template_id} =~ /202|218/){
|
||||
#if($node_meta->{parent_id} >= "200000" && $node_meta->{template_id} =~ /202|218/){
|
||||
if($node_meta->{parent_id} >= 200000){
|
||||
print $q->td({-style=>"width:25px;background-color:$a_color;$hstyle"}, $but->singlesubmit2glyph("$edit","$new_key","$ib{$new_key}","background-color:$a_color;"));
|
||||
print $q->hidden(-name=>'open_set_main_id', -value=>"$node_meta->{main_id}") if($table =~ /contenttrans/);
|
||||
}else{
|
||||
|
@ -1176,6 +1179,17 @@ sub tpl(){
|
|||
|
||||
}
|
||||
}
|
||||
|
||||
if($varenv{dbname} eq "sharee_kn" && $node_meta->{tpl_id} == 228){
|
||||
if( -d "$opdir_dms/ftp/SWK_codes"){
|
||||
my @pdfs = $lb->read_dirfiles("$opdir_dms/ftp/SWK_codes","got_last\.csv","file","");
|
||||
foreach(@pdfs){
|
||||
print $q->Tr(),"\n";
|
||||
print $q->td({-class=>"tdtxt",-colspan=>10},"SWK Bonunsnummern download ",$q->a({-class=>'linknav3',-href=>"$varenv{wwwhost}/FileOut?file=$_&sessionid=$coo", -target=>'_default', -title=>'Download',-type=>'application/octet-stream'}, $q->img({-src=>"$varenv{metahost}/glyphicons/file-any.png", -style=>'width:25px;'}), "\"$_\"")),"\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
print $q->end_table;
|
||||
|
||||
print $q->hidden(-name=>'tpl_id',-override=>'1', -value=>"$tpl_id");
|
||||
|
|
|
@ -27,7 +27,7 @@ sub tpl(){
|
|||
my $node_meta = shift;
|
||||
my $users_dms = shift;
|
||||
my $u_group = shift;
|
||||
my $return = shift;
|
||||
my $return = shift || "";
|
||||
|
||||
my $q = new CGI;
|
||||
my $cf = new Config;
|
||||
|
@ -79,6 +79,7 @@ sub tpl(){
|
|||
|
||||
#Content
|
||||
print $q->start_table({-border=>'0', -width=>'100%',-align=>'center', -cellpadding=>'3', -cellspacing=>'0'});
|
||||
if($return !~ /failure/){
|
||||
print $q->Tr();
|
||||
if($R::config2edit){
|
||||
print "<td class='ct_editline'>";
|
||||
|
@ -94,7 +95,7 @@ sub tpl(){
|
|||
print "</td>\n";
|
||||
}
|
||||
print $q->td({-style=>"background-color:white;padding-right:10px;border-bottom: 1px solid silver;text-align:right;font-size:12px;"}, "$u_name / $ct->{mtime}");
|
||||
|
||||
}
|
||||
my $i=0;
|
||||
foreach (@tpl_order){
|
||||
$i++;
|
||||
|
|
|
@ -34,7 +34,7 @@ sub tpl(){
|
|||
my $node_meta = shift;
|
||||
my $users_dms = shift;
|
||||
my $u_group = shift;
|
||||
my $return = shift;
|
||||
my $return = shift || "";
|
||||
|
||||
my $q = new CGI;
|
||||
my @keywords = $q->param;
|
||||
|
@ -49,27 +49,19 @@ sub tpl(){
|
|||
my $but = new Buttons;
|
||||
my %varenv = $cf->envonline();
|
||||
my $path = $q->path_info();
|
||||
my $coo = $q->cookie(-name=>'domcookie') || "";
|
||||
my $lang = "de";
|
||||
my $dbh = "";
|
||||
|
||||
my $parent_node4rel = $db->get_node4rel($node_meta->{parent_id},"","","null");
|
||||
my %ib = $but->ibuttons();
|
||||
|
||||
my $opdir_dms = "$dbt->{copri_conf}->{basedir}/$dbt->{operator}->{$varenv{dbname}}->{dir_dms}" || "";
|
||||
|
||||
my $message = "";
|
||||
my $s_owner_id = "";
|
||||
#my $s_u_name = "";
|
||||
|
||||
#TODO, build service path by pos.template_id or pos.barcode alis bike_id
|
||||
#my $pref = { table => "content",
|
||||
# table_pos => "contentpos",
|
||||
#};
|
||||
#my $template_group = $dbt->pos_template_group($dbh,$pref);
|
||||
#my $subrelnode = $dbt->get_subrelnode($dbh,$crecord->{main_id},$template_id_pos);
|
||||
|
||||
my $searchref = {};
|
||||
my $channel_map = $dbt->channel_map();
|
||||
|
||||
my $mapref = {};
|
||||
my $ct_users = $dbt->users_map($dbh,$mapref);#get serviceAPP and DMS users from contentadr
|
||||
|
||||
|
@ -239,7 +231,7 @@ EOF
|
|||
}
|
||||
}
|
||||
|
||||
print "<div id='Content4list'>\n";
|
||||
print "<div id='Content4sublist'>\n";
|
||||
my $header_style = "";
|
||||
$header_style = "border:2px solid #9f1f0e;" if($message);
|
||||
print $q->div({-class=>"copri_header",-style=>"background-color:$node_meta->{bg_color};"},"$path",$q->span({-style=>"$header_style"},"$message"));
|
||||
|
@ -255,8 +247,8 @@ EOF
|
|||
my $hstyle = "width:20px;background-color:$node_meta->{bg_color};border-right: solid thin gray;border-bottom: solid thin gray;";
|
||||
print $q->start_table({ -style=>'clear:both;', -border=>'0', -width=>'100%',-align=>'center', -cellpadding=>'0', -cellspacing=>'0'}),"\n";
|
||||
|
||||
#new_edit and search (disabled for DMS-Account)
|
||||
if($node_meta->{tpl_id} != 198 && $node_meta->{tpl_id} != 199){
|
||||
#new_edit and search (disabled for Statistik, Service-Config and DMS-Account view)
|
||||
if($node_meta->{tpl_id} !~ /195|198|199/){
|
||||
my $edit="rel_edit";
|
||||
my $new_key="service_done";
|
||||
|
||||
|
@ -312,7 +304,7 @@ EOF
|
|||
print $q->textfield(-style=>'border:1px solid grey;height:25px;width:80%;',-id=>"json_selectadr",-name=>"json_selectadr", -placeholder=>'Neuer DMS-Account', -value=>""),"\n";
|
||||
|
||||
print "</th>\n";
|
||||
}elsif($node_meta->{tpl_id} != 199){
|
||||
}elsif($node_meta->{tpl_id} !~ /195|199/){
|
||||
#print $q->th({-style=>""}," "),"\n";
|
||||
my $sort_up = "up";
|
||||
my $sort_down = "down";
|
||||
|
@ -341,7 +333,6 @@ EOF
|
|||
}
|
||||
my $sort_title="| $val";
|
||||
|
||||
#$i++;
|
||||
if($node_meta->{tpl_id} !~ /198|199/){
|
||||
$val = "<b>$val</b>" if($key eq $users_dms->{col_sort});
|
||||
print $q->th({-style=>'padding:5px 0'},$q->div({-style=>"$divstyle"},$q->a({-class=>"sortnav",-href=>"?col_sort=$key\&offset=$offset\&limit=$limit",-title=>"$val"},"$val"))),"\n" if($key ne "u_id");
|
||||
|
@ -350,10 +341,29 @@ EOF
|
|||
}
|
||||
}#end Tableheader
|
||||
|
||||
|
||||
#BIG LOOP loop content table
|
||||
$users_dms->{sort_updown} = "down" if(!$users_dms->{sort_updown});
|
||||
my $nr=0;
|
||||
my $tdclass = "tdtxt";
|
||||
my $tdstyle = "text-align:left;";
|
||||
|
||||
#Statistic file view
|
||||
if($node_meta->{tpl_id} == 195){
|
||||
if( -d "$opdir_dms/csv"){
|
||||
my @pdfs = $lb->read_dirfiles("$opdir_dms/csv","\.ZIP","file","");
|
||||
@pdfs = reverse(@pdfs);
|
||||
foreach (@tpl_order){
|
||||
my ($key,$val,$size) = split /=/,$_;
|
||||
if($key eq "pdf01"){
|
||||
foreach(@pdfs){
|
||||
print $q->Tr(),"\n";
|
||||
print $q->td({-class=>"$tdclass"},$q->a({-class=>'linknav3',-href=>"$varenv{wwwhost}/FileOut?file=$_&sessionid=$coo", -target=>'_default', -title=>'Download',-type=>'application/octet-stream'}, $q->img({-src=>"$varenv{metahost}/glyphicons/file-any.png", -style=>'width:25px;'}), "$_")),"\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
#BIG LOOP loop content table
|
||||
else{
|
||||
$users_dms->{sort_updown} = "down" if(!$users_dms->{sort_updown});
|
||||
foreach my $id (sort {
|
||||
if($users_dms->{sort_updown} eq "down"){
|
||||
if ($scol =~ /barcode|int/) {
|
||||
|
@ -384,8 +394,8 @@ EOF
|
|||
my ($key,$val,$size) = split /=/,$_;
|
||||
$size = 15 if($size =~ /area/);
|
||||
$size = 2 if($size =~ /checkbox/);
|
||||
my $tdclass = "tdtxt";
|
||||
my $tdstyle = "text-align:left;";
|
||||
$tdclass = "tdtxt";
|
||||
$tdstyle = "text-align:left;";
|
||||
if($size =~ /\w\+\w/){
|
||||
$size = 5;
|
||||
}elsif($key =~ /barcode|c_id|ct_name|int|state|sort|public/){
|
||||
|
@ -447,6 +457,7 @@ EOF
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
print $q->end_table;
|
||||
|
||||
|
|
|
@ -80,6 +80,7 @@ sub tpl(){
|
|||
$ctf_operator = $dbt->fetch_tablerecord($dbh,$pref_cuop);
|
||||
|
||||
#take original operator accounting c_id to collect related invoices
|
||||
#operator invoice
|
||||
if($ctt->{template_id} != 208){#not equal Abrechnung
|
||||
my $pref = {
|
||||
table => "contenttrans",
|
||||
|
@ -90,18 +91,16 @@ sub tpl(){
|
|||
my $ctt_accounting = $dbt->fetch_record($dbh,$pref);
|
||||
($cttpos,$rows) = $dbt->collect_contenttrans($dbh,$ctt_accounting->{content_id});
|
||||
#int9x are not in db
|
||||
@tpl_order = ("c_id=ID","int01=Summe Einzug","state=Zahlungsart","int93=TeilRad Gebühren","int98=TeilRad Gebühren 19%","int100=Summe");
|
||||
if($varenv{dbname} eq "sharee_sx"){
|
||||
@tpl_order = ("c_id=ID","int01=Summe Einzug","state=Zahlungsart","int93=TeilRad Gebühren","int98=TeilRad Gebühren 19%","int94=TeilRad Disagio","int99=TeilRad Disagio 19%","int100=Summe");
|
||||
@tpl_order = ("c_id=ID","int01=Summe Einzug","state=Zahlungsart","int93=TeilRad Gebühren","int98=19% UmSt","int100=Summe");
|
||||
}
|
||||
}
|
||||
#default to Abrechnung
|
||||
#operator accounting
|
||||
else{
|
||||
($cttpos,$rows) = $dbt->collect_contenttrans($dbh,$ctt->{content_id});
|
||||
#int9x are not in db
|
||||
@tpl_order = ("c_id=ID","int01=Summe Einzug","state=Zahlungsart","int93=TeilRad Gebühren","int98=TeilRad Gebühren 19%","int94=payone Disagio","int95=payone Transaktion","int96=payone Zahlungsmeldung","int97=payone Kreditkarte Zuordnung","int02=Summe Gutschrift");
|
||||
if($varenv{dbname} eq "sharee_sx"){
|
||||
@tpl_order = ("c_id=ID","int01=Summe Einzug","state=Zahlungsart","int93=TeilRad Gebühren","int98=TeilRad Gebühren 19%","int94=TeilRad Disagio","int99=TeilRad Disagio 19%","int02=Summe Gutschrift");
|
||||
@tpl_order = ("c_id=ID","int01=Summe Einzug","state=Zahlungsart","int94=payone Disagio","int02=Summe Gutschrift");
|
||||
}else{
|
||||
@tpl_order = ("c_id=ID","int01=Summe Einzug","state=Zahlungsart","int94=payone Disagio","int95=payone Transaktion","int96=payone Zahlungsmeldung","int97=payone Kreditkarte Zuordnung","int02=Summe Gutschrift");
|
||||
}
|
||||
}
|
||||
my $tplf = $dbt->get_tpl($dbh,201);#Kunden-Faktura, ex Firma
|
||||
|
@ -142,8 +141,8 @@ sub tpl(){
|
|||
my $oac = $pri->operator_accounting2calc(\%varenv,$cttpos->{$id},$ctf_operator);
|
||||
$sum_operatorcredit += $oac->{int02};#Abrechnung Gutschrift
|
||||
$sum_parts19 += $oac->{int100};#Operator Rechnung (TeilRad Gebühren + Disagio incl. 19%)
|
||||
$sum_all += $oac->{int01};
|
||||
$oac->{int01} = sprintf('%.2f', $oac->{int01});
|
||||
$sum_all += $oac->{int99};#capture brutto
|
||||
$oac->{int01} = sprintf('%.2f', $oac->{int01});#capture netto
|
||||
|
||||
if(1==1){
|
||||
$i++;
|
||||
|
@ -258,14 +257,14 @@ sub tpl(){
|
|||
}
|
||||
|
||||
print $q->Tr("\n");$line_count2++;
|
||||
print $q->td({-class=>'tdint',-colspan=>1,-style=>'color:silver;'},"(Einzüge $sum_all)");
|
||||
print $q->td({-class=>'tdint',-colspan=>1,-style=>'color:silver;'},"(Einzüge brutto $sum_all)");
|
||||
print $q->td({-class=>'tdsum',-colspan=>1},"Summe $ctt->{state}");
|
||||
print $q->td({-class=>'tdint',-nowrap=>"1"},"$sum_paid €");
|
||||
}
|
||||
#Summe Betreiber Abrechnung (Gutschrift)
|
||||
else{
|
||||
print $q->Tr("\n");$line_count2++;
|
||||
print $q->td({-class=>'tdint',-colspan=>1,-style=>'color:silver;'},"(Einzüge $sum_all)");
|
||||
print $q->td({-class=>'tdint',-colspan=>1,-style=>'color:silver;'},"(Einzüge brutto $sum_all)");
|
||||
print $q->td({-class=>'tdsum',-colspan=>1},"Summe $ctt->{state}");
|
||||
print $q->td({-class=>'tdint',-nowrap=>"1"},"$sum_operatorcredit €");
|
||||
}
|
||||
|
|
|
@ -52,7 +52,7 @@ sub tpl(){
|
|||
my $today = strftime "%d.%m.%Y",localtime;
|
||||
my $now_dt = strftime "%Y-%m-%d %H:%M:%S", localtime;
|
||||
my $channel_map = $dbt->channel_map();
|
||||
my $coo = $q->cookie(-name=>'domcookie');
|
||||
my $coo = $q->cookie(-name=>'domcookie') || "";
|
||||
my $dbh = "";
|
||||
|
||||
my $mapref = {};
|
||||
|
|
|
@ -92,9 +92,9 @@ sub tplselect(){
|
|||
}elsif($tpl_id == 197){
|
||||
require "Tpl/Contact.pm";
|
||||
&Contact::tpl($node_meta,$users_dms,$mode,$varenv,$users_sharee,$return);
|
||||
}elsif($tpl_id == 1 || $tpl_id == 3){
|
||||
require "Tpl/Listing.pm";
|
||||
&Listing::tpl($node_meta,$users_dms,$mode,$varenv,$users_sharee,$return);
|
||||
#}elsif($tpl_id == 1 || $tpl_id == 3){
|
||||
# require "Tpl/Listing.pm";
|
||||
# &Listing::tpl($node_meta,$users_dms,$mode,$varenv,$users_sharee,$return);
|
||||
}
|
||||
}
|
||||
my $debug = "Mlogic --> (users_sharee->{c_id}: $users_sharee->{c_id} | ct_table: $node_meta->{ct_table} | parent_id: $node_meta->{parent_id} | main_id: $node_meta->{main_id} | tpl_id: $node_meta->{tpl_id} | u_id: $u_id | mode: $mode)";
|
||||
|
|
|
@ -121,7 +121,6 @@ sub tpl(){
|
|||
if( -d "$dir_main"){
|
||||
my @pdfs = $lb->read_dirfiles($dir_main,"\.JPG|\.JPEG|\.PNG","file","not");
|
||||
foreach(@pdfs){
|
||||
#print $q->div({-class=>"$content2"}, $q->a({-href=>"$varenv->{metahost}/data/$datamain_id/$ct4rel->{$id}->{c_id}/$_", -target=>'_blank',-title=>'Download',-type=>'application/octet-stream'}, $q->img({-src=>"$varenv->{metahost}/glyphicons/file-any.png", -style=>'width:50px;'}), "$_")),"\n";
|
||||
print $q->div($q->a({-href=>"$varenv->{wwwhost}/FileOut?file=$datamain_id/$ct4rel->{$id}->{c_id}/$_$session_and", -target=>'_default', -title=>'Download',-type=>'application/octet-stream'}, $q->img({-src=>"$varenv->{metahost}/glyphicons/file-any.png", -style=>'width:50px;'}), "$_")),"\n";
|
||||
|
||||
}
|
||||
|
|
|
@ -355,7 +355,7 @@ print <<EOF
|
|||
EOF
|
||||
;
|
||||
|
||||
if($node_meta->{tpl_id} == 199 && $node_meta->{ct_table} eq "contentuser"){
|
||||
if($node_meta->{tpl_id} =~ /195|199/ && $node_meta->{ct_table} eq "contentuser"){
|
||||
require "Tpl/SubListe.pm";
|
||||
$return = &SubListe::tpl($node_meta,$users_dms,$mode,$return);
|
||||
}elsif($node_meta->{ct_table} eq "contentuser"){
|
||||
|
|
Loading…
Add table
Reference in a new issue