mirror of
https://gitlab.com/t6353/sharee.bike.git
synced 2025-05-13 23:26:29 +02:00
Operator sharee_mak init
This commit is contained in:
parent
75c38a8721
commit
b586568e68
8 changed files with 33 additions and 55 deletions
|
@ -1735,7 +1735,7 @@ sub bikes_available(){
|
|||
|
||||
if(ref($tariff_content) eq "HASH"){
|
||||
foreach my $tid (sort { $tariff_content->{$a}->{barcode} <=> $tariff_content->{$b}->{barcode} } keys (%$tariff_content)){
|
||||
$bw->log("bikes_available tariff_content tariff_description $tariff_content->{$tid}->{int12} && $auth->{txt30} =~ /$tariff_content->{$tid}->{barcode}/ BIKE:",$return->{$id}->{bike},"");
|
||||
#$bw->log("bikes_available tariff_content tariff_description $tariff_content->{$tid}->{int12} && $auth->{txt30} =~ /$tariff_content->{$tid}->{barcode}/ BIKE:",$return->{$id}->{bike},"");
|
||||
|
||||
foreach(@adr_tariff){
|
||||
if($record->{$id}->{main_id} == $tariff_content->{$tid}->{int12} && $_ == $tariff_content->{$tid}->{barcode}){
|
||||
|
|
|
@ -388,7 +388,8 @@ sub collect_noderel {
|
|||
my $dbh = shift || $dbh_intern;
|
||||
my $main_id = shift;
|
||||
my $template_id = shift || "";
|
||||
my $where = "WHERE n.main_id=rel.main_id and rel.content_id=0 and n.parent_id=$main_id";
|
||||
#my $where = "WHERE n.main_id=rel.main_id and rel.content_id=0 and n.parent_id=$main_id";
|
||||
my $where = "WHERE n.main_id=rel.main_id and rel.content_id=0 and n.parent_id=$main_id and node_public='t'";
|
||||
$where .= " and rel.template_id=$template_id" if($template_id);
|
||||
my $sth = $dbh->prepare("SELECT * FROM nodes n, relation rel $where");
|
||||
my $rc = $sth->execute();
|
||||
|
@ -1142,7 +1143,7 @@ sub insert_nodeoid(){
|
|||
my $node_path = $insert->{node_name};
|
||||
($node_name,$node_path) = split(/\|/,$node_name) if($node_name =~ /\|/);
|
||||
|
||||
my $sth2 = $dbh->prepare("INSERT INTO nodes (main_id,parent_id,lang,node_name,node_path,n_sort,owner) VALUES('$insert->{main_id}','$insert->{parent_id}','$insert->{lang}','$node_name','$node_path','$insert->{n_sort}','$insert->{owner}')");
|
||||
my $sth2 = $dbh->prepare("INSERT INTO nodes (main_id,parent_id,lang,node_name,node_path,n_sort,owner,node_public) VALUES('$insert->{main_id}','$insert->{parent_id}','$insert->{lang}','$node_name','$node_path','$insert->{n_sort}','$insert->{owner}','t')");
|
||||
my $rc = $sth2->execute();
|
||||
$sth2 = $dbh->prepare("INSERT INTO relation (main_id,template_id,content_id,lang,change) VALUES('$insert->{main_id}','$insert->{template_id}','$insert->{content_id}','$insert->{lang}','now()') RETURNING rel_id");
|
||||
$rc = $sth2->execute();
|
||||
|
|
|
@ -735,10 +735,10 @@ sub handler {
|
|||
|
||||
my $base_uri = "true";
|
||||
my $title = "";
|
||||
$title .= "devel " if($dbt->{copri_conf}->{stage} eq "test");
|
||||
$title .= $dbt->{primary}->{$varenv{dbname}}->{title} if($dbt->{primary}->{$varenv{dbname}}->{title});
|
||||
$title .= $dbt->{operator}->{$varenv{dbname}}->{title} if($dbt->{operator}->{$varenv{dbname}}->{title});
|
||||
$title .= $dbt->{website}->{$varenv{syshost}}->{title} if($dbt->{website}->{$varenv{syshost}}->{title});
|
||||
$title = $dbt->{primary}->{$varenv{dbname}}->{title} if($dbt->{primary}->{$varenv{dbname}}->{title});
|
||||
$title = $dbt->{operator}->{$varenv{dbname}}->{title} if($dbt->{operator}->{$varenv{dbname}}->{title});
|
||||
$title = $dbt->{website}->{$varenv{syshost}}->{title} if($dbt->{website}->{$varenv{syshost}}->{title});
|
||||
$title .= " devel" if($dbt->{copri_conf}->{stage} eq "test");
|
||||
my $html5 = $q->start_html(-title=>"$title",
|
||||
-lang=>'de',
|
||||
-onload=>"$onload",
|
||||
|
|
|
@ -173,15 +173,7 @@ sub esender_success {
|
|||
my $wwwhost = shift;
|
||||
my %varenv = &Config::envonline("","$wwwhost");
|
||||
|
||||
my $ct = {};
|
||||
if($varenv{syshost} =~ /konrad|tink/i){
|
||||
$ct = &get_content("content","3435","1");
|
||||
$ct->{txt01} = $q->unescapeHTML($ct->{txt01});
|
||||
$ct->{txt01} =~ s/\r\n/<br \/>/g;
|
||||
$ct->{txt01} = Encode::encode('iso-8859-1', Encode::decode('utf-8', $ct->{txt01}));
|
||||
}else{
|
||||
$ct = &get_content("contentuser",$globalconf{shareedms_conf}->{parent_node},"201");
|
||||
}
|
||||
my $ct = &get_content("contentuser",$globalconf{shareedms_conf}->{parent_node},"201");
|
||||
|
||||
|
||||
my $email = $q->unescapeHTML($ctadr->{txt08});
|
||||
|
@ -207,33 +199,12 @@ sub esender_success {
|
|||
|
||||
|
||||
#email html body---------------------------------------------------
|
||||
my $body;
|
||||
|
||||
if($varenv{syshost} =~ /konrad|tink/i){
|
||||
my $body = "";
|
||||
my $encoded_email = $uri_encode->encode($ctadr->{txt08});
|
||||
$body = <<EOF
|
||||
Vielen Dank für Ihre Anmeldung.
|
||||
Vielen Dank für Ihre Registrierung im Mietradsystem.
|
||||
|
||||
Damit wir das Fahrradmietsystem für Sie freischalten können, benötigen wir abschließend eine Bestätigung. Klicken Sie hierzu auf folgenden Link:
|
||||
<a href='http://www.konrad-konstanz.net?confirm_email=$encoded_email&confirm_code=$ctadr->{c_id}'>www.konrad-konstanz.net?confirm_email=$encoded_email&confirm_code=$ctadr->{c_id}</a>
|
||||
Der Link führt Sie zur Website der Stadtwerke Konstanz. Damit sind Sie freigeschaltet.
|
||||
|
||||
Falls Sie zur Eingabe eines Bestätigungscode aufgefordert werden, lautet dieser: <b>$ctadr->{c_id}</b>
|
||||
|
||||
Die hinterlegten Zugangsdaten dienen zum Anmelden im Fahrradmietsystem der APP und im Browser <a href='http://www.konrad-konstanz.de'>www.konrad-konstanz.de</a>
|
||||
|
||||
Viel Spaß beim Radeln.
|
||||
|
||||
EOF
|
||||
;
|
||||
|
||||
}else{#sharee
|
||||
|
||||
my $encoded_email = $uri_encode->encode($ctadr->{txt08});
|
||||
$body = <<EOF
|
||||
Vielen Dank für Ihre Anmeldung.
|
||||
|
||||
Damit wir das Fahrradmietsystem für Sie freischalten können, benötigen wir eine e-Mail Bestätigung.
|
||||
Damit Sie Ihr Nutzerkonto in der App freischalten können, verwenden Sie folgenden e-Mail Bestätigungscode bei Ihrer Registrierung.
|
||||
Der e-Mail Bestätigungscode lautet: <b>$email_ack_digest</b>
|
||||
|
||||
Viel Spaß beim Radeln.
|
||||
|
@ -249,24 +220,17 @@ $ct->{txt11}
|
|||
|
||||
EOF
|
||||
;
|
||||
}
|
||||
|
||||
$body =~ s/\n/<br \/>/g;
|
||||
my $html = "<html><head><title>$varenv{title}</title></head><body style='text-align:left;border:0px solid silver;padding:15px;margin:2%;width:90%;'>\n";
|
||||
$html .= "<div>$body</div>";
|
||||
#if($mandant eq "TINK"){
|
||||
# $html .= "<div><img src=\"https://www2.tink-konstanz.de/img/TINK_Signatur.jpg\" \/></div>";
|
||||
#}
|
||||
if($varenv{syshost} =~ /konrad|tink/i){
|
||||
$html .= "<div>$ct->{txt01}</div>\n";
|
||||
}
|
||||
$html .= "</body></html>";
|
||||
|
||||
|
||||
#-----------------------------------------------------------------
|
||||
|
||||
|
||||
my $subject = "$varenv{title} Anmeldebestätigung";
|
||||
my $subject = "Mietrad Anmeldebestätigung";
|
||||
if($hostname ne "ginger"){
|
||||
$email = $mailxconf{mailx_default}->{mail_to};
|
||||
$subject .= "* offline Test *";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue