else {
$html->{result} = $db->queryarray($p->{sql});
}
- }
+ }
+ elsif (exists($p->{ins})){
+
+ }
+ elsif (exists($p->{dupl})){
+
+ }
+ elsif (exists($p->{save})){
+ $html->{result} = $db->exec("UPDATE ".$db->securetext($p->{table})." SET ".$db->securetext($p->{column})."='".$db->securetext($p->{value})."' WHERE id='".$db->securetext($p->{id})."';");
+ }
elsif (exists($p->{exec})){
$html->{result} = $db->exec($p->{exec});
}
dsn => 'DBI:SQLite:dbname='.$cfgpath.'/'.$name.'.sqlite',
# dbuser => '',
# dbpassword => '',
- basepath => '/',
staticpath => 'htdocs/',
#dsn => 'DBI:PgPP:dbname=fldlu_db;host=DKS-LAPTOP.fritz.box',
#dsn => 'DBI:PgPP:dbname=fldlu_db;host=sql629.your-server.de',
#dbpassword => 'Tm6G1bjQSudiEBAY',
page => 'index.tt',
pagename => 'index',
+ basename => '/',
# basepath => substr((exists($ENV{"SCRIPT_FILENAME"})?dirname($ENV{"SCRIPT_FILENAME"}):dirname($0)),length($ENV{"DOCUMENT_ROOT"})),
# datapath => substr((exists($ENV{"SCRIPT_FILENAME"})?dirname($ENV{"SCRIPT_FILENAME"}):dirname($0)),length($ENV{"DOCUMENT_ROOT"})).'/data/',
- # docroot => $ENV{"DOCUMENT_ROOT"},
+ docroot => $ENV{"DOCUMENT_ROOT"},
# registration_enabled => '1',
# default_group => 'users',
# sitename => 'FLD Member Area',
--- /dev/null
+#!/usr/local/bin/perl
+use strict;
+use lib ('./server/CGI/api/lib/perl5');
+use lib ('./server/CGI/api/lib');
+use lib ('./lib/perl5');
+use lib ('./lib');
+use CGI;
+use CGI::Cookie;
+use CGI::Carp qw/fatalsToBrowser/;
+use File::Basename;
+use FindBin qw/$RealBin/;
+use Template;
+#use session;
+use dksconfig qw/$sitecfg/;
+use JSON::PP;
+use Data::Dumper;
+my $cgi = new CGI();
+my $scriptpath = $cgi->url(-absolute => 1);
+my $p = ();
+my @params = $cgi->param();
+foreach my $pe (@params){
+ $p->{$pe} = $cgi->param($pe);
+}
+print $cgi->header(-type=>"text/html", -charset => "utf-8");
+my $html->{result} = ();
+# $p->{sid} = $cgi->cookie($sitecfg->{cookiename});
+#print Dumper($p);
+#my $se = session->new();
+#my $sess = $se->getsession($p->{sid});
+#print Dumper($sess);
+# if ($sess == undef){
+# $html->{error} = "No Authorisation";
+# print JSON::PP::encode_json($html);
+# exit(0);
+# }
+my $vars = $sitecfg;
+#$vars->{session} = $sess;
+$vars->{params} = $p;
+$vars->{filepath} = 'module/'.$p->{page}.'.tt';
+$vars->{baseurl} = $cgi->url({-base=>1});
+$vars->{siteurl} = $cgi->url({-base=>1}).'/'.$sitecfg->{staticpath};
+
+if ($vars->{filepath} ne ""){
+ $vars->{suffix} = substr($vars->{filepath},rindex($vars->{filepath},'.'));
+ $vars->{page} = $vars->{filepath};
+ $vars->{page} =~ s/html$/tt/;
+}
+my $tmplincpath2 = $RealBin.'/CGI/tmpl';
+my ($browserlang2) = $ENV{HTTP_ACCEPT_LANGUAGE} =~ /^(\w+)[,|;|-]/;
+$vars->{lang} = 'de';
+if (-e $tmplincpath2.'/lang/'.$browserlang2.'.tt'){
+ $vars->{lang} = $browserlang2;
+}
+#print '<pre>'.Dumper($vars).'</pre>';
+my $template = Template->new({INCLUDE_PATH => [$tmplincpath2]});
+
+$template->process($vars->{filepath},$vars) || die "Template process failed: ", $template->error(), "\n";
#$vars->{filepath} = substr($cgi->url({-absolute=>1}),length($vars->{basepath})+1);
$vars->{filepath} = substr($ENV{PATH_INFO},1);
-$vars->{baseurl} = $cgi->url({-base=>1}).$vars->{basepath};
-if ($vars->{basepath} eq "/"){
- $vars->{siteurl} = $cgi->url({-base=>1});
-}else {
- $vars->{siteurl} = $cgi->url({-base=>1}).dirname($vars->{basepath});
- $vars->{docroot} = $vars->{docroot}.dirname($vars->{basepath});
- #$vars->{sitepath} = dirname($vars->{basepath});
-}
+# $vars->{baseurl} = $cgi->url({-base=>1}).$vars->{basepath};
+# if ($vars->{basepath} eq "/"){
+# $vars->{siteurl} = $cgi->url({-base=>1});
+# }else {
+# $vars->{siteurl} = $cgi->url({-base=>1}).dirname($vars->{basepath});
+# $vars->{docroot} = $vars->{docroot}.dirname($vars->{basepath});
+# #$vars->{sitepath} = dirname($vars->{basepath});
+# }
if ($vars->{filepath} ne ""){
$vars->{suffix} = substr($vars->{filepath},rindex($vars->{filepath},'.'));
$vars->{page} = $vars->{filepath};
for (my $i=0;$i<$absnum;$i++){
$vars->{abspath} .= "../";
}
-$vars->{appname} = 'invoicejournal';
-$vars->{pagename} = basename($vars->{page});
-$vars->{pagename} =~ s/\.tt$//;
if ($vars->{page} !~ /\.tt$/) {
- $skl = "skeleton/file.tt";
-} elsif ($vars->{page} =~ /module/){
- $skl = "skeleton/module.tt";
+ $skl = "skeleton/file.tt";
} else {
- $vars->{page} = "app/".$vars->{page};
+ $vars->{page} = 'module/'.$vars->{page};
}
+$vars->{appname} = 'invoicejournal';
+$vars->{pagename} = basename($vars->{page});
+$vars->{pagename} =~ s/\.tt$//;
+
$vars->{params}= $p;
my ($browserlang) = $ENV{HTTP_ACCEPT_LANGUAGE} =~ /^(\w+)[,|;|-]/;
$vars->{lang} = 'de';
}
$template->process($skl,$vars) || die "Template process failed: ", $template->error(), "\n";
-# print '/*<pre>'.Dumper($vars)."<pre>*/";
+# print '<pre>'.Dumper($vars)."<pre>";
-[% PROCESS macro/fields.tt %]
-<div id="dlgdeleterow" class="w3-modal">
+<div id="dlgdeleterow" class="w3-modal">
<div class="w3-modal-content w3-animate-top w3-card-4">
<header class="w3-container">
<span onclick="document.getElementById('dlgdeleterow').style.display='none'; return false;"
class="w3-button w3-display-topright">×</span>
- <h2 id="dlgdelete_title">Supprimer</h2>
+ <h2 id="dlgdelete_title">[% lbl.deletedatasettitle %]</h2>
</header>
<div class="w3-container">
- <span id="askdelete">êtes vous sûre de vouloir supprimer la rangé sélectionné?</span>
- [% fieldhidden("dlgdeltable","delete",'','') %]
- [% fieldhidden("dlgdelrowid","delete",'','') %]
+ <span id="askdelete">[% lbl.deletedatasetmessage %]</span>
+
</div>
<footer class="w3-container w3-right-align w3-padding-16">
- <button class="w3-button w3-theme-light w3-margin-right w3-border" onclick="document.getElementById('dlgdeleterow').style.display='none'; return false;">Annuler</button>
- <button class="w3-button w3-red w3-margin-right w3-border" onclick="deleterow_confirmed();">Supprimer</button>
+ <button class="w3-button w3-theme-light w3-margin-right w3-border" onclick="document.getElementById('dlgdeleterow').style.display='none'; return false;">[% lbl.cancel %]</button>
+ <button class="w3-button w3-red w3-margin-right w3-border" onclick="record.confirm();">[% lbl.delte %]</button>
</footer>
</div>
</div>
-<script>
-var afterdeletecallback = null;
-
-function showdeletedlg(deltable,delid,question,callback){
- if (question){
- document.getElementById('askdelete').innerHTML = question;
- }
-
- document.getElementById('dlgdeltable').value=deltable;
- document.getElementById('dlgdelrowid').value=delid;
- afterdeletecallback = callback;
- document.getElementById('dlgdeleterow').style.display='block';
- return false;
-}
-
-function deleterow_confirmed(){
- //var deltbl = "ident_"+ document.getElementById('dlgdeltable').value + "_id";
- req.reqdata("POST", "db.cgi", {
- "del2": "1",
- "schemata": schemata,
- "id" : document.getElementById('dlgdelrowid').value,
- "table": document.getElementById('dlgdeltable').value
- }, afterdelete);
- document.getElementById('askdelete').innerHTML = "êtes vous sûre de vouloir supprimer la rangé sélectionné?";
- document.getElementById('dlgdeltable').value="";
- document.getElementById('dlgdelrowid').value="";
- return false;
-}
-
-function afterdelete(){
-
- if (afterdeletecallback != null){
- console.log("lauch after callback");
- console.log(afterdeletecallback);
- afterdeletecallback(null);
- }
- document.getElementById('dlgdeleterow').style.display='none';
- var sb = document.getElementById("snackbar");
- sb.className="show w3-green";
- sb.innerHTML = 'Les données ont été supprimées!';
- setTimeout(function(){ sb.className = sb.className.replace("show w3-green", ""); }, 3000);
- afterdeletecallback =null;
- return false;
-}
-</script>
\ No newline at end of file
<div class="">
[% IF title %]<label for="[% table %]_[% column %]" class="w3-label">[% title %]</label>[% END %]
- <input type="[% IF type == 'currency' %]number[% ELSE %][% type %][% END %]" data-id="[% id %]" data-column="[% column %]" data-table="[% table %]" class="w3-input w3-border[% IF type == 'currency'%]w3-right-align w3-currency[% END %] [% IF state %][% state %][% END %]" id="[% table %]_[% column %][% IF id %]-[% id %][% END %]" name="[% table %]_[% column %]" value="[% ivalue %]" [% IF plhold %]placeholder="[% plhold %]" [% END %] [% IF state %][% state %][% END %]/>
+ <input type="[% IF type == 'currency' %]number[% ELSE %][% type %][% END %]" data-id="[% id %]" data-column="[% column %]" data-table="[% table %]" class="w3-input w3-border[% IF type == 'currency'%]w3-right-align w3-currency[% END %] [% IF state %][% state %][% END %]" id="[% table %]_[% column %][% IF id %]-[% id %][% END %]" name="[% table %]_[% column %]" value="[% ivalue %]" [% IF plhold %]placeholder="[% plhold %]" [% END %] [% IF state %][% state %][% END %] onblur="record.savefield(this);"/>
</div>
[% END -%]
[% ELSE %]
<div class="">
[% IF title %]<label for="[% table %]_[% column %]" class="w3-label">[% title %]</label>[% END %]
- <select class="w3-select w3-border data_[% table %] [% IF state.length > 0 %][% state %][% END %]" [% IF type == 'multiple' %]multiple=1[% END %] data-selected="[% value %]" data-id="[% id %]" data-column="[% column %]" data-table="[% table %]" value="[% value %]" id="[% table %]_[% column %][% IF id %]-[% id %][% END %]" name="[% table %]_[% column %]" [% IF plhold %]placeholder="[% plhold %]" [% END %] [% IF state.length > 0 %][% state %][% END %]>
+ <select class="w3-select w3-border data_[% table %] [% IF state.length > 0 %][% state %][% END %]" [% IF type == 'multiple' %]multiple=1[% END %] data-selected="[% value %]" data-id="[% id %]" data-column="[% column %]" data-table="[% table %]" value="[% value %]" id="[% table %]_[% column %][% IF id %]-[% id %][% END %]" name="[% table %]_[% column %]" [% IF plhold %]placeholder="[% plhold %]" [% END %] [% IF state.length > 0 %][% state %][% END %] onblur="record.savefield(this);">
[% IF xoptions %]
[% FOREACH opt IN xoptions %]
<option value="[% opt.value %]" class="[% opt.class %]">[% opt.text %]</option>
--- /dev/null
+[% USE dksdb = DBI(dsn,dbuser,dbpassword) %]
+[% #PROCESS macro/fields.tt %]
+[% PROCESS "lang/${lang}.tt" %]
+[% cols = { clientnumber => 100 , displayname=> 350, address => 200, email => 200, phone => 200, action=> 120 }%]
+<div class="w3-display-container w3-animate-right">
+ <div class="w3-container w3-bar TopNavigation" id="addresses_toolbar">
+ <!-- <button class="w3-bar-item Button_Navigation" onclick="parent.app.loadapppage('index');"/><img src="[% abspath %][% staticpath %]img/icons/back_white.svg" style="color: #fff; height: 24px;"/><br/>[% lbl.back %]</button> -->
+ <div class="w3-bar-item PageHeadTitle">[% lbl.addresses %]</div>
+ <!-- <button class="w3-bar-item Button_Navigation w3-right" onclick="parent.app.loadmodulepage('addresses/index.html',null);"/><img src="[% abspath %][% staticpath %]img/icons/Reload_white.svg" style="color: #fff; height: 24px;"/><br/>[% lbl.reload %]</button> -->
+ <button class="w3-bar-item Button_Navigation w3-right" onclick="record.remove('addresses');"><img src="[% abspath %][% staticpath %]img/icons/Trash_red.svg" style="color: #fff; height: 16px;"><br>
+ [% lbl.remove %]</button>
+ <button class="w3-bar-item Button_Navigation w3-right" onclick="record.duplicate('addresses/address');"><img src="[% abspath %][% staticpath %]img/icons/Duplicate_white.svg" style="color: #fff; height: 16px;"><br>[% lbl.duplicate %]</button>
+ <button class="w3-bar-item Button_Navigation w3-right" onclick="record.edit('addresses/address');"><img src="[% abspath %][% staticpath %]img/icons/Edit_white.svg" style="color: #fff; height: 16px;"><br>
+ [% lbl.edit %]</button>
+ <button class="w3-bar-item Button_Navigation w3-right" onclick="record.add('addresses/address');"><img src="[% abspath %][% staticpath %]img/icons/Add_white.svg" style="color: #fff; height: 16px;"><br>
+ [% lbl.add %]</button>
+
+ </div>
+ <div class="portalpanel">
+
+ <table class="portal" id="addresses_portal" sytle="height: calc(100vh - 60px);">
+ <thead>
+ <tr id="tblhead_addresses">
+ <th style="min-width: [% cols.clientnumber %]px;width: [% cols.clientnumber %]px;max-width: [% cols.clientnumber %]px;"><div class="portaltextheader">Kd-Nr.</div></th>
+ <th style="min-width: [% cols.displayname %]px;width: [% cols.displayname %]px;max-width: [% cols.displayname %]px;"><div class="portaltextheader">Name</div></th>
+ <th style="min-width: [% cols.address %]px;width: [% cols.address %]px;max-width: [% cols.address %]px;"><div class="portalheader">Adresse</div></th>
+ <th style="min-width: [% cols.email %]px;width: [% cols.email %]px;max-width: [% cols.email %]px;"><div class="portalheader">E-Mail</div></th>
+ <th style="min-width: [% cols.phone %]px;width: [% cols.phone %]px;max-width: [% cols.phone %]px;"><div class="portalheader">Telefon</div></th>
+ <th></th>
+ </tr>
+ </thead>
+
+ <tbody style="height: calc(100vh - 180px);" id="ds_addresses">
+ [% FOREACH adr = dksdb.query("select * from addresses order by receipient;") %]
+ <tr class="" id="ds_[% adr.id %]" data-id="[% adr.id %]" onclick="table.setselection('[% adr.id %]');">
+ <td style="min-width: [% cols.clientnumber %]px;width: [% cols.clientnumber %]px;max-width: [% cols.clientnumber %]px;">[% adr.clientnumber %]</td>
+ <td style="min-width: [% cols.displayname %]px;width: [% cols.displayname %]px;max-width: [% cols.displayname %]px;">[% adr.receipient %]</td>
+ <td style="min-width: [% cols.address %]px;width: [% cols.address %]px;max-width: [% cols.address %]px;">[% adr.address %] <br/> [% adr.country %] [% adr.zip %] [% adr.city %]</td>
+ <td style="min-width: [% cols.email %]px;width: [% cols.email %]px;max-width: [% cols.email %]px;">[% adr.email %]</td>
+ <td style="min-width: [% cols.phone %]px;width: [% cols.phone %]px;max-width: [% cols.phone %]px;">[% adr.phone %]</td>
+ <td></td>
+ </tr>
+ [% END %]
+ </tbody>
+
+ </table>
+ </div>
+ <!-- <div class="w3-row">
+ <div class="w3-cell">
+ <div class="w3-display-container">
+ [% inputbox('preference','preferences','address_filter','','text','','','','','Filter...') %]
+ </div>
+ <div class="w3-display-container" style="width: 250px; height: calc(100vh - 90px); overflow-y: scroll">
+
+ [% FOREACH adr=dksdb.query("select * from addresses;") %]
+
+ <div class="w3-container w3-border" style="pointer: cursor;" onclick="">
+ [% adr.receipient %]
+ </div>
+ [% END %]
+ </div>
+ </div>
+ <div class="w3-cell">
+
+ </div>
+ </div> -->
+</div>
--- /dev/null
+[% PROCESS macro/fields.tt %]
+[% USE dksdb = DBI(dsn,dbuser,dbpassword) %]
+[% PROCESS "lang/${lang}.tt" %]
+[% #USE Dumper %]
+[% qadr =dksdb.query("select * from addresses where id='${params.id}';") %]
+[% adr = qadr.get_all() %]
+<div class="w3-display-container w3-animate-left">
+ <div class="w3-container w3-bar TopNavigation">
+ <button class="w3-bar-item Button_Navigation" onclick="app.getpage('addresses');"><img src="[% abspath %][% staticpath %]img/icons/back_white.svg" style="color: #fff; height: 24px;"><br>[% lbl.back %]</button>
+ <div class="w3-bar-item PageHeadTitle">[% lbl.address %]</div>
+
+ <!-- <button class="w3-bar-item Button_Navigation w3-right" onclick="parent.app.reloadpage();"><img src="[% abspath %][% staticpath %]img/icons/Reload_white.svg" style="color: #fff; height: 24px;"><br>[% lbl.reload %]</button> -->
+ </div>
+ <div class="w3-container">
+ <!-- [% Dumper.dump(params) %] -->
+ <div class="w3-row">
+ <div class="w3-cell w3-container" style="width: 510px;">
+ [% inputbox('receipient','addresses',params.id,lbl.displayname,'text','','','',adr.0.receipient,'') %]
+ </div>
+ <div class="w3-cell w3-container" style="width: 150px;">
+ [% inputbox('clientnumber','addresses',params.id,lbl.clientnumber,'text','','','',adr.0.clientnumber,'YYMMDDNNN') %]
+ </div>
+ </div>
+ <div class="w3-row" >
+ <div class="w3-cell w3-container" style="width: 60px;">
+ [% inputbox('title','addresses',params.id,lbl.title,'text','','','',adr.0.title,'') %]
+ </div>
+ <div class="w3-cell w3-container" style="width: 300px;">
+ [% inputbox('prename','addresses',params.id,lbl.prename,'text','','','','',adr.0.prename,'') %]
+ </div>
+ <div class="w3-cell w3-container" style="width: 300px;">
+ [% inputbox('surname','addresses',params.id,lbl.surname,'text','','','',adr.0.surname,'') %]
+ </div>
+ </div>
+ <div class="w3-row">
+ <div class="w3-cell w3-container" style="width: 660px;">
+ [% inputbox('address','addresses',params.id,lbl.address,'text','','','',adr.0.address,'') %]
+ </div>
+ </div>
+ <div class="w3-row">
+ <div class="w3-cell w3-container" style="width: 60px;">
+ [% inputbox('country','addresses',params.id,lbl.country,'text','','','',adr.0.country,'') %]
+ </div>
+ <div class="w3-cell w3-container" style="width: 120px;">
+ [% inputbox('zip','addresses',params.id,lbl.zip,'text','','','',adr.0.zip,'') %]
+ </div>
+ <div class="w3-cell w3-container" style="width: 480px;">
+ [% inputbox('city','addresses',params.id,lbl.city,'text','','','',adr.0.city,'') %]
+ </div>
+ </div>
+ <div class="w3-row">
+ <div class="w3-cell w3-container" style="width: 400px;">
+ [% inputbox('email','addresses',params.id,lbl.email,'text','','','',adr.0.email,'') %]
+ </div>
+ </div>
+ <div class="w3-row">
+ <div class="w3-cell w3-container" style="width: 400px;">
+ [% inputbox('phone','addresses',params.id,lbl.phone,'text','','','',adr.0.phone,'') %]
+ </div>
+ </div>
+ <div class="w3-row">
+ <div class="w3-cell w3-container" style="width: 300px;">
+ [% inputbox('iban','addresses',params.id,lbl.iban,'text','','','',adr.0.iban,'') %]
+ </div>
+ <div class="w3-cell w3-container" style="width: 150px;">
+ [% inputbox('bic','addresses',params.id,lbl.bic,'text','','','',adr.0.bic,'') %]
+ </div>
+ </div>
+ <div class="w3-row" >
+ <div class="w3-cell w3-container" style="width: 200px;">
+ [% inputbox('vatid','addresses',params.id,lbl.vatid,'text','','','',adr.0.vatid,'') %]
+ </div>
+ <div class="w3-cell w3-container" style="width: 200px;">
+ [% inputbox('lang','addresses',params.id,lbl.lang,'text','','','',adr.0.lang,'') %]
+ </div>
+ </div>
+ </div>
+
+</div>
\ No newline at end of file
-<div class="w3-display-container w3-display-top">
+<!-- <div class="w3-display-container w3-display-top">
<div class="w3-container w3-bar DKS">
<img class="w3-bar-item" src="[% abspath %][% staticpath %]img/invoicejournal.png" style="height: 50px;"/></button>
<div class="w3-bar-item PageHeadTitle">Invoice Journal</div>
<div class="w3-cell" style="padding: 20px;"><button class="Buttom_BodyNav" style="width: 200px;padding: 30px; font-size: 10px;" onclick="app.loadmodulepage('reports/index.html',null);"/><img src="[% abspath %][% staticpath %]img/icons/Template.svg" style="color: #fff;height: 48px;"/><br/>Vorlagen</button></div>
</div>
</div>
-</div>
\ No newline at end of file
+</div> -->
\ No newline at end of file
[% PROCESS macro/fields.tt %]
+[% PROCESS "lang/${lang}.tt" %]
<div class="w3-display-container">
<div class="w3-container w3-bar TopNavigation">
- <button class="w3-bar-item Button_Navigation" onclick="parent.app.loadapppage('index');"/><img src="[% abspath %][% staticpath %]img/icons/back_white.svg" style="color: #fff; height: 24px;"/><br/>[% lbl.back %]</button>
+
+ <!-- <button class="w3-bar-item Button_Navigation w3-right" onclick="app.loadpage('index');"/><img src="[% abspath %][% staticpath %]img/icons/back_white.svg" style="color: #fff; height: 24px;"/><br/>[% lbl.back %]</button> -->
<div class="w3-bar-item PageHeadTitle">[% lbl.invoices %]</div>
- <button class="w3-bar-item Button_Navigation w3-right" onclick="parent.app.reloadpage();"/><img src="[% abspath %][% staticpath %]img/icons/Reload_white.svg" style="color: #fff; height: 24px;"/><br/>[% lbl.reload %]</button>
+ <!-- <button class="w3-bar-item Button_Navigation w3-right" onclick="parent.app.reloadpage();"/><img src="[% abspath %][% staticpath %]img/icons/Reload_white.svg" style="color: #fff; height: 24px;"/><br/>[% lbl.reload %]</button> -->
+ <button class="w3-bar-item Button_Navigation w3-right" onclick="form.deleteRecord();"><img src="[% abspath %][% staticpath %]img/icons/remove_white.svg" style="width: 16px;"><br/>[% lbl.remove %]</button>
+ <button class="w3-bar-item Button_Navigation w3-right" onclick="form.edit('webpages/webpage');"><img src="[% abspath %][% staticpath %]img/icons/edit_white.svg" style="width: 16px;"><br/>[% lbl.edit %]</button>
+ <button class="w3-bar-item Button_Navigation w3-right" onclick="form.edit('webpages/webpage');"><img src="[% abspath %][% staticpath %]img/icons/plus_white.svg" style="width: 16px;"><br/>[% lbl.add %]</button>
</div>
<div class="portalpanel">
[% cols = { date => 100 , inout=> 80, receipient => 350, reference => 350, status => 110, amount => 110 , action=> 120 }%]
-<table class="portal" sytle="height: calc(100vh - 60px);">
+<table class="portal">
<thead>
<tr>
<th style="min-width: [% cols.date %]px;width: [% cols.date %]px;max-width: [% cols.date %]px;">[% selectbox('preferences','preferences',pagename,'','','','','','test','Zeitraum','') %]</th>
</tr>
</thead>
- <tbody style="height: calc(100vh - 101px);">
+ <tbody style="height: calc(100vh - 180px);">
[% WHILE i < 100 %]
<tr>
<td style="min-width: [% cols.date %]px;width: [% cols.date %]px;max-width: [% cols.date %]px;">DD.MM.YYYY</td>
+++ /dev/null
-function initpage(){
- console.log("init page " + location.href);
-}
-
+++ /dev/null
-[% PROCESS macro/fields.tt %]
-[% USE Dumper %]
-[% qadr =dksdb.query("select * from addresses where id='${params.id}';") %]
-[% adr = qadr.get_all() %]
-<div class="w3-display-container w3-animate-left">
- <div class="w3-container w3-bar TopNavigation">
- <button class="w3-bar-item Button_Navigation" onclick="parent.app.loadmodulepage('addresses/index.html',null);"><img src="[% abspath %][% staticpath %]img/icons/back_white.svg" style="color: #fff; height: 24px;"><br>[% lbl.back %]</button>
- <div class="w3-bar-item PageHeadTitle">[% lbl.address %]</div>
-
- <button class="w3-bar-item Button_Navigation w3-right" onclick="parent.app.reloadpage();"><img src="[% abspath %][% staticpath %]img/icons/Reload_white.svg" style="color: #fff; height: 24px;"><br>[% lbl.reload %]</button>
- </div>
- <div class="w3-container">
- [% Dumper.dump(params) %]
- <div class="w3-row">
- <div class="w3-cell w3-container" style="width: 510px;">
- [% inputbox('receipient','addresses','',lbl.displayname,'text','','','',adr.0.receipient,'') %]
- </div>
- <div class="w3-cell w3-container" style="width: 150px;">
- [% inputbox('clientnumber','addresses','',lbl.clientnumber,'text','','','',adr.0.clientnumber,'YYMMDDNNN') %]
- </div>
- </div>
- <div class="w3-row" >
- <div class="w3-cell w3-container" style="width: 60px;">
- [% inputbox('title','addresses','',lbl.title,'text','','','',adr.0.title,'') %]
- </div>
- <div class="w3-cell w3-container" style="width: 300px;">
- [% inputbox('prename','addresses','',lbl.prename,'text','','','','',adr.0.prename,'') %]
- </div>
- <div class="w3-cell w3-container" style="width: 300px;">
- [% inputbox('surname','addresses','',lbl.surname,'text','','','',adr.0.surname,'') %]
- </div>
- </div>
- <div class="w3-row">
- <div class="w3-cell w3-container" style="width: 660px;">
- [% inputbox('address','addresses','',lbl.address,'text','','','',adr.0.address,'') %]
- </div>
- </div>
- <div class="w3-row">
- <div class="w3-cell w3-container" style="width: 60px;">
- [% inputbox('country','addresses','',lbl.country,'text','','','',adr.0.country,'') %]
- </div>
- <div class="w3-cell w3-container" style="width: 120px;">
- [% inputbox('zip','addresses','',lbl.zip,'text','','','',adr.0.zip,'') %]
- </div>
- <div class="w3-cell w3-container" style="width: 480px;">
- [% inputbox('city','addresses','',lbl.city,'text','','','',adr.0.city,'') %]
- </div>
- </div>
- <div class="w3-row">
- <div class="w3-cell w3-container" style="width: 400px;">
- [% inputbox('email','addresses','',lbl.email,'text','','','',adr.0.email,'') %]
- </div>
- </div>
- <div class="w3-row">
- <div class="w3-cell w3-container" style="width: 400px;">
- [% inputbox('phone','addresses','',lbl.phone,'text','','','',adr.0.phone,'') %]
- </div>
- </div>
- <div class="w3-row">
- <div class="w3-cell w3-container" style="width: 300px;">
- [% inputbox('iban','addresses','',lbl.iban,'text','','','',adr.0.iban,'LU 0000 0000 0000 0000 0000') %]
- </div>
- <div class="w3-cell w3-container" style="width: 150px;">
- [% inputbox('bic','addresses','',lbl.bic,'text','','','',adr.0.bic,'XXXXXXXXXX') %]
- </div>
- </div>
- <div class="w3-row" >
- <div class="w3-cell w3-container" style="width: 200px;">
- [% inputbox('vatid','addresses','',lbl.vatid,'text','','','',adr.0.vatid,'LU 0000 0000 00') %]
- </div>
- <div class="w3-cell w3-container" style="width: 200px;">
- [% inputbox('lang','addresses','',lbl.lang,'text','','','',adr.0.lang,'') %]
- </div>
- </div>
- </div>
-
-</div>
\ No newline at end of file
+++ /dev/null
-function initpage(){
- console.log("init page " + location.href);
- addresses.inittable();
- addresses.gettabledata();
-}
-
- var addresses = {
- data: null,
- tbl: null,
- cols: null,
- selection: null,
- inittable: function(){
- addresses.tbl = document.getElementById("tbl_addresses");
- addresses.cols = document.getElementById("tblhead_addresses").children;
- addresses.settableheight();
- },
- settableheight: function(){
- var tbl_height = document.getElementById("addresses_toolbar").style.height;
- var tblhead_addresses = document.getElementById("tblhead_addresses").style.height;
- var winh = window.innerHeight;
- console.log("height: " + winh + " - " + tbl_height + " - " +tblhead_addresses );
- addresses.tbl.style.height = winh-101 + 'px';
- return false;
- },
- gettabledata: function(){
- req.reqdata("POST","db.cgi",{"sql":"select * from addresses order by receipient,clientnumber;"},addresses.filltable);
- },
- filltable: function(data){
- addresses.data = data;
- addresses.tbl.innerHTML = '';
- console.log(data);
- console.log(addresses.cols);
- for (var r in addresses.data){
- var row = '<tr class="ds_addresses" id="ds_'+addresses.data[r].id+'" data-id="'+ addresses.data[r].id +'">';
- row += '<td style="'+addresses.cols[0].style.cssText+'">'+ ((addresses.data[r].clientnumber)?addresses.data[r].clientnumber:'') +'</td>';
- row += '<td style="'+addresses.cols[1].style.cssText+'">'+ ((addresses.data[r].receipient)?addresses.data[r].receipient:'') + '</td>';
- row += '<td style="'+addresses.cols[2].style.cssText+'">'+ ((addresses.data[r].address)?addresses.data[r].address+ '<br/>':'') + ((addresses.data[r].country)? addresses.data[r].country +' - ':'') + ((addresses.data[r].zip)?addresses.data[r].zip + ' ':'') + ((addresses.data[r].city)? addresses.data[r].city:'') +'</td>';
- row += '<td style="'+addresses.cols[3].style.cssText+'">'+ ((addresses.data[r].email)?addresses.data[r].email:'') +'</td>';
- row += '<td style="'+addresses.cols[4].style.cssText+'">'+ ((addresses.data[r].phone)?addresses.data[r].phone:'')+'</td>';
- // row += '<td style="'+addresses.cols[5].style.cssText+'"><button class="w3-button w3-grey" onclick="addresses.edit(\''+ addresses.data[r].id+ '\');">bearb.</button></td>';
- row += '<td></td></tr>';
- addresses.tbl.innerHTML += row;
- }
- var selrows = document.getElementsByClassName("ds_addresses");
- for (var i=0;i<selrows.length;i++){
- selrows[i].addEventListener("click",function(){addresses.setselection(this.id);});
- }
-
- },
- setselection: function(objid){
- if (addresses.selection != null){
- document.getElementById("ds_" + addresses.selection).classList.remove("portal_selected");
- if (objid == "ds_" + addresses.selection){
- addresses.selection = null;
- return false;
- }
- }
- addresses.selection = objid.replace(/^ds_/,'');
- document.getElementById(objid).classList.add("portal_selected");
- return false;
- },
- edit: function(){
- if (addresses.selection){
- parent.app.loadmodulepage('addresses/address.html',{id:addresses.selection});
- }
- return false;
- },
- add: function(objid){
-
- },
- remove: function(objid){
-
- },
- duplicate: function(objid){
-
- },
- }
-
-
\ No newline at end of file
+++ /dev/null
-[% PROCESS macro/fields.tt %]
-[% cols = { clientnumber => 100 , displayname=> 350, address => 200, email => 200, phone => 200, action=> 120 }%]
-<div class="w3-display-container w3-animate-right">
- <div class="w3-container w3-bar DKS" id="addresses_toolbar">
- <button class="w3-bar-item Button_Navigation" onclick="parent.app.loadapppage('index');"/><img src="[% abspath %][% staticpath %]img/icons/back_white.svg" style="color: #fff; height: 24px;"/><br/>[% lbl.back %]</button>
- <div class="w3-bar-item PageHeadTitle">[% lbl.addresses %]</div>
- <button class="w3-bar-item Button_Navigation w3-right" onclick="parent.app.loadmodulepage('addresses/index.html',null);"/><img src="[% abspath %][% staticpath %]img/icons/Reload_white.svg" style="color: #fff; height: 24px;"/><br/>[% lbl.reload %]</button>
- <button class="w3-bar-item Button_Navigation w3-right" onclick="addresses.remove();"><img src="[% abspath %][% staticpath %]img/icons/Trash_red.svg" style="color: #fff; height: 24px;"><br>
- [% lbl.remove %]</button>
- <button class="w3-bar-item Button_Navigation w3-right" onclick="addresses.duplicate();"><img src="[% abspath %][% staticpath %]img/icons/Duplicate_white.svg" style="color: #fff; height: 24px;"><br>[% lbl.duplicate %]</button>
- <button class="w3-bar-item Button_Navigation w3-right" onclick="addresses.edit();"><img src="[% abspath %][% staticpath %]img/icons/Edit_white.svg" style="color: #fff; height: 24px;"><br>
- [% lbl.edit %]</button>
- <button class="w3-bar-item Button_Navigation w3-right" onclick="addresses.add();"><img src="[% abspath %][% staticpath %]img/icons/Add_white.svg" style="color: #fff; height: 24px;"><br>
- [% lbl.add %]</button>
-
- </div>
- <div class="portalpanel">
-
- <table class="portal" id="addresses_portal" sytle="height: calc(100vh - 60px);">
- <thead>
- <tr id="tblhead_addresses">
- <th style="min-width: [% cols.clientnumber %]px;width: [% cols.clientnumber %]px;max-width: [% cols.clientnumber %]px;"><div class="portaltextheader">Kd-Nr.</div></th>
- <th style="min-width: [% cols.displayname %]px;width: [% cols.displayname %]px;max-width: [% cols.displayname %]px;"><div class="portaltextheader">Name</div></th>
- <th style="min-width: [% cols.address %]px;width: [% cols.address %]px;max-width: [% cols.address %]px;"><div class="portalheader">Adresse</div></th>
- <th style="min-width: [% cols.email %]px;width: [% cols.email %]px;max-width: [% cols.email %]px;"><div class="portalheader">E-Mail</div></th>
- <th style="min-width: [% cols.phone %]px;width: [% cols.phone %]px;max-width: [% cols.phone %]px;"><div class="portalheader">Telefon</div></th>
- <th></th>
- </tr>
- </thead>
-
- <tbody id="tbl_addresses">
- </tbody>
-
- </table>
- </div>
- <!-- <div class="w3-row">
- <div class="w3-cell">
- <div class="w3-display-container">
- [% inputbox('preference','preferences','address_filter','','text','','','','','Filter...') %]
- </div>
- <div class="w3-display-container" style="width: 250px; height: calc(100vh - 90px); overflow-y: scroll">
-
- [% FOREACH adr=dksdb.query("select * from addresses;") %]
-
- <div class="w3-container w3-border" style="pointer: cursor;" onclick="">
- [% adr.receipient %]
- </div>
- [% END %]
- </div>
- </div>
- <div class="w3-cell">
-
- </div>
- </div> -->
-</div>
+++ /dev/null
-function initpage(){
- console.log("init page " + location.href);
-}
\ No newline at end of file
+++ /dev/null
-function initpage(){
- console.log("init page " + location.href);
-}
\ No newline at end of file
+++ /dev/null
-function initpage(){
- console.log("init page " + location.href);
-}
\ No newline at end of file
+++ /dev/null
-function initpage(){
- console.log("init page " + location.href);
-}
\ No newline at end of file
+++ /dev/null
-function initpage(){
- console.log("init page " + location.href);
-}
\ No newline at end of file
+++ /dev/null
-function initpage(){
- console.log("init page " + location.href);
-}
\ No newline at end of file
+++ /dev/null
-function initpage(){
- console.log("init page " + location.href);
-}
\ No newline at end of file
+++ /dev/null
-function initpage(){
- console.log("init page " + location.href);
-}
\ No newline at end of file
+++ /dev/null
-function initpage(){
- console.log("init page " + location.href);
-}
\ No newline at end of file
+++ /dev/null
-function initpage(){
- console.log("init page " + location.href);
-}
\ No newline at end of file
+++ /dev/null
-function initpage(){
- console.log("init page " + location.href);
-}
\ No newline at end of file
+++ /dev/null
-function initpage(){
- console.log("init page " + location.href);
-}
\ No newline at end of file
<title>[% appname %] - [% pagename %]</title>
</head>
<body>
-<div class="w3-display-container apppanel w3-white w3-animate-top" id="appview">
- [% INCLUDE $page %]
-</div>
-<div class="w3-display-container apppanel w3-animate-bottom" id="modules" style="display: none;">
- <iframe id="moduleframe" sandbox="allow-forms allow-pointer-lock allow-same-origin allow-scripts allow-top-navigation allow-modals allow-popups allow-popups-to-escape-sandbox" src="" style="margin-top: 0px; bottom: 0px;border: 0px; height: 98.5vh; width: 100%; overflow-y: hidden;background-color: #52638e;"></iframe>
-</div>
+ <div class="w3-display-container">
+ <div class="w3-bar DKS" id="toolbar">
+ <button onclick="app.refesh();" class="Button_Navigation w3-bar-item"><img src="[% abspath %][% staticpath %]img/invoicejournal.png" style="height: 28px;"/><br/></button>
+ <div class="w3-bar-item PageHeadTitle">Invoice Journal</div>
+ <!--<button class="w3-bar-item Button_Navigation" onclick="app.getpage('profile');"><img src="[% abspath %]img/icons/user_white.svg" style="width: 28px;"><br/>Profile</button>
+ <button class="w3-bar-item Button_Navigation" onclick="app.getpage('users');"><img src="[% abspath %]img/icons/group_white.svg" style="width: 28px;"><br/>Benutzer</button>-->
+
+ <button class="w3-bar-item Button_Navigation" onclick="app.getpage('invoices',null);"><img src="[% abspath %][% staticpath %]img/icons/Bill2_white.svg" style="width: 28px;"><br/>[% lbl.invoices %]</button>
+ <button class="w3-bar-item Button_Navigation" onclick="app.getpage('addresses',null);"><img src="[% abspath %][% staticpath %]img/icons/Contacts_white.svg" style="width: 28px;"><br/>[% lbl.addresses %]</button>
+ <button class="w3-bar-item Button_Navigation" onclick="app.getpage('products',null);"><img src="[% abspath %][% staticpath %]img/icons/Product2_white.svg" style="width: 28px;"><br/>[% lbl.products %]</button>
+ <button class="w3-bar-item Button_Navigation" onclick="app.getpage('offers',null);"><img src="[% abspath %][% staticpath %]img/icons/Box_white.svg" style="width: 28px;"><br/>[% lbl.offers %]</button>
+ <button class="w3-bar-item Button_Navigation" onclick="app.getpage('bookings',null);"><img src="[% abspath %][% staticpath %]img/icons/Bookings2_white.svg" style="width: 28px;"><br/>[% lbl.bookings %]</button>
+ <button class="w3-bar-item Button_Navigation" onclick="app.getpage('transactions',null);"><img src="[% abspath%][% staticpath %]img/icons/Banking_Transaction_white.svg" style="height: 28px;"><br/>[% lbl.transactions %]</button>
+ <button class="w3-bar-item Button_Navigation w3-right" onclick="app.getpage('settings',null);"><img src="[% abspath %][% staticpath %]img/icons/Settings_white.svg" style="width: 28px;"><br/>[% lbl.settings %]</button>
+ <button class="w3-bar-item Button_Navigation w3-right" onclick="app.reloadpage();"><img src="[% abspath %][% staticpath %]img/icons/Reload_white.svg" style="width: 28px;"><br/>[% lbl.reload %]</button>
+ </div>
+ </div>
+ <div class="w3-display-container" id="mainapp" style="height: calc(100vh - 63px);">
+ [% INCLUDE $page %]
+ </div>
<script src="[% abspath %][% staticpath %]js/request.js?v=[% vstamp %]"></script>
<script src="[% abspath %][% staticpath %]js/app.js?v=[% vstamp %]"></script>
+<script src="[% abspath %][% staticpath %]js/table.js?v=[% vstamp %]"></script>
+<script src="[% abspath %][% staticpath %]js/record.js?v=[% vstamp %]"></script>
<!-- <script src="[% abspath %][% staticpath %]js/admin.js?v=[% vstamp %]"></script> -->
</body>
+++ /dev/null
-[% USE dksdb = DBI(dsn,dbuser,dbpassword) %]
-[% USE date %]
-[% vstamp=date.format(date.now, '%d%m%Y%H%M%S') %]
-[% PROCESS "lang/${lang}.tt" %]
-<!DOCTYPE html>
-<html lang="[% lang %]">
-<head>
-<meta charset="UTF-8">
-<!-- <meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate" />
-<meta http-equiv="Pragma" content="no-cache" />
-<meta http-equiv="Expires" content="0" /> -->
-<link rel="stylesheet" href="[% abspath %][% staticpath %]css/w3pro.css?v=[% vstamp %]">
-<link rel="stylesheet" href="[% abspath %][% staticpath %]css/dkstheme.css?v=[% vstamp %]">
-<title>[% appname %] -> [% pagename %]</title>
-</head>
-<body>
-<div class="w3-display-container">
- [% INCLUDE $page %]
-</div>
-<script src="[% abspath %][% staticpath %]js/request.js?v=[% vstamp %]"></script>
-<script src="[% abspath %][% staticpath %]js/form.js?v=[% vstamp %]"></script>
-<script src="[% abspath %][% staticpath %]js/module.js?v=[% vstamp %]"></script>
-<script src="[% pagename %].js?v=[% vstamp %]"></script>
-<!-- <script src="[% abspath %][% staticpath %]js/admin.js?v=[% vstamp %]"></script> -->
-</body>
-</html>
\ No newline at end of file
--- /dev/null
+<?xml version="1.0" encoding="utf-8"?>
+<svg version="1.2" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
+ x="0px" y="0px" width="50px" height="50px" viewBox="0 0 64 60.11">
+<path fill="#fff" d="M1.7490486,48.97502L32.389891,48.97502C32.893904,51.558016,33.977934,53.930014,35.486975,55.97201L0,55.97201z M45.792979,41.23501L45.792979,44.381369 49.520987,44.381369 53.248991,44.381369 53.248991,41.23501 55.955996,43.431261 58.664,45.627512 55.955996,47.823763 53.248991,50.020014 53.248991,46.593622 52.832991,46.593622 46.208979,46.593622 45.792979,46.593622 45.792979,50.020014 43.085974,47.823763 40.378973,45.627512 43.085974,43.431261z M49.522505,33.831042C43.01673,33.831042 37.724913,39.123038 37.724913,45.628031 37.724913,52.132021 43.01673,57.422018 49.522505,57.422018 56.025279,57.422018 61.316092,52.132021 61.316092,45.628031 61.316092,39.123038 56.025279,33.831042 49.522505,33.831042z M49.522505,31.148045C57.504225,31.148045 63.998999,37.645037 63.998999,45.628031 63.998999,53.611021 57.504225,60.105013 49.522505,60.105013 41.538783,60.105013 35.042006,53.611021 35.042006,45.628031 35.042006,37.645037 41.538783,31.148045 49.522505,31.148045z M43.727011,20.990004L54.222014,20.990004 52.473013,24.488018 52.473013,28.435034C51.512015,28.270033 50.531012,28.166033 49.523013,28.166033 48.128012,28.166033 46.77801,28.347035 45.477011,28.658036L45.477011,24.488018z M22.738024,20.990004L33.233027,20.990004 31.484028,24.488005 31.484028,45.477003 24.487025,45.477003 24.487025,24.488005z M1.7489761,20.990004L12.244019,20.990004 10.494845,24.488005 10.494845,45.477003 3.4981506,45.477003 3.4981506,24.488005z M27.98654,6.9969799C26.053462,6.9969799 24.487454,8.5629895 24.487454,10.494997 24.487454,12.427004 26.053462,13.993014 27.98654,13.993014 29.917544,13.993014 31.48355,12.427004 31.48355,10.494997 31.48355,8.5629895 29.917544,6.9969799 27.98654,6.9969799z M27.98654,0L55.972022,17.490999 2.0026847E-05,17.490999z"/>
+</svg>
\ No newline at end of file
--- /dev/null
+<?xml version="1.0" encoding="utf-8"?>
+<svg version="1.2" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
+ x="0px" y="0px" width="50px" height="50px" viewBox="0 0 994.48 1093.96">
+<path fill="#fff" d="M239.750991821289,1043.58226607392C253.667999267578,1043.58226607392 264.940994262695,1054.86205123017 264.940994262695,1068.75072310517 264.940994262695,1082.67845748017 253.667999267578,1093.95921919892 239.750991821289,1093.95921919892 225.835983276367,1093.95921919892 214.56298828125,1082.67845748017 214.56298828125,1068.75072310517 214.56298828125,1054.86205123017 225.835983276367,1043.58226607392 239.750991821289,1043.58226607392z M93.8241809606552,1043.39928267548C107.740937232971,1043.39928267548 119.010982513428,1054.68028853486 119.010984420776,1068.56920455048 119.010982513428,1082.49522994111 107.740937232971,1093.77428267548 93.8241809606552,1093.77428267548 79.9073276519775,1093.77428267548 68.6359844207764,1082.49522994111 68.6359920501709,1068.56920455048 68.6359844207764,1054.68028853486 79.9073276519775,1043.39928267548 93.8241809606552,1043.39928267548z M94.459946513176,871.199758749703L94.459946513176,934.453237753609 253.355880737305,928.042227011421 259.93489074707,871.199758749703z M0,803.720205527046L85.5028266906738,803.720205527046 85.5028266906738,836.403555136421 301.004974365234,836.403555136421 283.605941772461,958.227224570015 85.5028266906738,974.964224081734 85.5028266906738,994.916250448921 286.150939941406,994.916250448921 286.150939941406,1029.01427290986 56.5215606689453,1029.01427290986 56.5215606689453,836.403555136421 0,836.403555136421z M433.031234741211,798.150137167671C510.973281860352,798.300100546578 588.914352416992,798.240102987984 666.855422973633,798.240102987984 715.149429321289,798.240102987984 763.445449829102,798.230154257515 811.739517211914,798.250112753609 823.695510864258,798.250112753609 830.530532836914,804.039785605171 832.198501586914,816.028982382515 833.292495727539,823.878469687203 833.953506469727,831.577993612984 829.486526489258,839.117544394234 823.336502075195,849.486868124703 813.423477172852,852.526663046578 802.928482055664,852.596670370796 742.20344543457,852.966665487984 681.474380493164,852.776663046578 620.746353149414,852.766653280953 560.260330200195,852.766653280953 499.770278930664,852.926626425484 439.283248901367,852.616689902046 427.385238647461,852.556692343453 417.195236206055,847.856985312203 411.486221313477,836.287710409859 406.551223754883,826.278372030953 408.001235961914,816.028982382515 413.514236450195,807.57951949189 417.387222290039,801.649893027046 424.71223449707,798.140127402046 433.031234741211,798.150137167671z M431.592758178711,677.630178671578C556.891738891602,677.690176230171 682.19075012207,677.680166464546 807.488723754883,677.680166464546 825.322708129883,677.680166464546 838.240737915039,694.37932417939 833.302749633789,711.418508749703 829.617752075195,724.117849570015 822.383743286133,731.237539511421 807.718704223633,731.077505331734 746.033767700195,730.377554159859 684.33674621582,730.777517538765 622.643753051758,730.777517538765 559.276748657227,730.777517538765 495.910751342773,730.78752730439 432.542770385742,730.777517538765 418.729751586914,730.777517538765 406.304763793945,715.558279257515 408.729751586914,701.76897261689 410.153762817383,693.66936324189 411.993759155273,686.169729452828 419.903762817383,681.26994917939 423.733749389648,678.900076132515 427.197769165039,677.630178671578 431.592758178711,677.630178671578z M808.221389770508,558.360403280953C829.822463989258,558.280447226265 837.41145324707,582.110891562203 831.487442016602,595.97112105439 827.14143371582,606.15129683564 819.18440246582,611.961416464546 807.66438293457,611.881399374703 745.491287231445,611.411428671578 683.314102172852,611.661428671578 621.13801574707,611.661428671578 559.19987487793,611.661428671578 497.262741088867,611.661428671578 435.326583862305,611.661428671578 419.242568969727,611.661428671578 413.15153503418,606.501333456734 410.170547485352,590.340994101265 407.644546508789,576.650747519234 411.132553100586,568.530630331734 422.345565795898,561.480459433296 425.881576538086,559.25041792939 429.671585083008,558.550405722359 433.728591918945,558.550405722359 558.559860229492,558.560415487984 683.391128540039,558.79045699189 808.221389770508,558.360403280953z M67.4396743774414,454.068105917671C67.699275970459,453.980581503609 67.994815826416,454.090627890328 68.3479804992676,454.515951376656 67.9948139190674,454.776113730171 67.6430473327637,455.04631636689 66.7469844818115,454.806143027046 66.9564056396484,454.440908652046 67.1800708770752,454.15569136689 67.4396743774414,454.068105917671z M456.319046020508,278.471029501656C470.538101196289,278.341024618843 486.855117797852,293.50334761689 482.146102905273,311.196096640328 477.77311706543,327.628622275093 471.279098510742,333.219473105171 454.388046264648,333.219473105171 426.166000366211,333.219473105171 397.942947387695,333.219473105171 369.720901489258,333.219473105171 341.257827758789,333.219473105171 312.750778198242,332.229330282906 284.350723266602,333.559530478218 265.465682983398,334.449667196968 248.749649047852,309.945883017281 260.752670288086,292.643209677437 266.106689453125,284.922018271187 272.882705688477,278.641073446968 283.397705078125,278.651052695015 341.038833618164,278.691061239937 398.68196105957,278.961111288765 456.319046020508,278.471029501656z M457.827621459961,159.400381308296C466.018600463867,159.330373984078 481.000564575195,171.681036215523 482.163558959961,181.961553793648 484.918563842773,206.292883139351 468.656600952148,216.193395834664 448.661636352539,216.773428183296 421.895706176758,217.55347273896 395.089767456055,216.963445883492 368.301834106445,216.963445883492 342.46989440918,216.963445883492 316.637954711914,216.92343733857 290.80598449707,216.983450155953 270.446060180664,217.023443442085 261.384078979492,204.472784262398 256.790084838867,189.792013388374 254.376098632813,182.071584921578 264.391067504883,166.490759115914 273.337051391602,162.500539999703 277.983032226563,160.430441122749 282.698028564453,159.39038680146 287.880020141602,159.470403891304 303.901977539063,159.700399618843 319.929946899414,159.55039046357 335.954879760742,159.55039046357 376.579818725586,159.55039046357 417.205703735352,159.740392904976 457.827621459961,159.400381308296z M617.639724731445,0.000119525742775295C626.194717407227,-0.0198438761144644 632.624771118164,2.46013639519515 638.251724243164,8.04017947266402 646.269729614258,15.9901649768144 654.751724243164,23.4301054293901 662.619827270508,31.6002466494829 671.879776000977,41.2101347262651 681.54377746582,50.6503202731401 691.235794067383,59.9400884921342 721.956802368164,89.3803007418901 752.151809692383,119.400312643746 781.764785766602,149.960119467476 794.655838012695,163.260168295601 808.554885864258,175.510168295601 821.174880981445,189.020178061226 850.166885375977,220.050207358101 882.315872192383,247.850256186226 911.730911254883,278.440115195015 937.196914672852,304.930074911812 964.235916137695,329.880270224312 989.055923461914,357.020162802437 992.732925415039,361.040182333687 994.484939575195,365.230123739937 994.47395324707,370.900289755562 994.303909301758,468.010153036812 994.34992980957,565.120229941109 994.34992980957,662.230093222359 994.34992980957,757.910269003609 994.381912231445,853.590200644234 994.330947875977,949.270132284859 994.316909790039,975.850210409859 987.547927856445,1000.48009322236 971.929946899414,1022.25011275361 958.618911743164,1040.81017134736 942.809951782227,1056.54015181611 922.774917602539,1068.24010298798 899.567886352539,1081.78014205048 874.912857055664,1088.21019576142 848.211868286133,1088.2001859958 681.733779907227,1088.13011763642 515.255722045898,1088.1201078708 348.776596069336,1088.33019087861 342.311614990234,1088.34020064423 341.137619018555,1086.63011763642 341.129623413086,1080.54015181611 341.104614257813,1062.4501859958 342.310623168945,1044.34020064423 340.549606323242,1026.26012251923 340.337615966797,1024.07018111298 341.270614624023,1021.68004439423 344.589614868164,1022.10021040986 346.236618041992,1022.32018111298 347.934616088867,1022.14024947236 349.608627319336,1022.14024947236 509.866714477539,1022.14024947236 670.127822875977,1022.36022017548 830.386856079102,1021.94005415986 858.913833618164,1021.86022017548 886.035842895508,1015.47008345673 906.68489074707,993.190054159859 920.51692199707,978.260122519234 928.294937133789,960.740102987984 928.304946899414,940.310171347359 928.386917114258,767.860220175484 928.298904418945,595.410269003609 928.479934692383,422.950094443062 928.487930297852,416.500143271187 926.983901977539,414.840231161812 920.443923950195,414.860250693062 856.58088684082,415.140279989937 792.710891723633,415.470113974312 728.853775024414,414.800192099312 703.994827270508,414.540182333687 679.350784301758,410.480123739937 656.656814575195,399.400289755562 645.180740356445,393.800192099312 634.195755004883,387.400289755562 624.813735961914,378.110250693062 612.802749633789,366.220113974312 601.034744262695,354.160299521187 592.772750854492,339.450094443062 582.744735717773,321.600240927437 575.212753295898,302.730123739937 575.233749389648,281.65032027314 575.297744750977,212.760168295601 575.179733276367,143.870290976265 575.396743774414,74.980138998726 575.415725708008,69.2001249606401 574.319747924805,67.5302030856401 568.172744750977,67.5402128512651 457.903671264648,67.7601835543901 347.636611938477,67.5702421481401 237.368591308594,67.7901899630815 210.406555175781,67.8402616793901 189.527351379395,80.0802519137651 173.675918579102,101.790189963082 162.904037475586,116.550214987496 159.235038757324,133.32024214814 159.162002563477,150.850271445015 158.858337402344,225.000158529976 158.947334289551,299.150289755562 159.150314331055,373.300192099312 159.175140380859,381.980123739937 156.811336517334,723.560171347359 148.943313598633,722.810171347359 132.008724212646,721.200063925484 115.716413497925,723.810171347359 100.084028720856,730.580190878609 95.4894044399261,732.570181112984 92.8774433415383,732.350210409859 92.8920095348312,725.860220175484 93.0745536088943,643.580190878609 92.9095735978335,221.910314779976 93.0934931337833,139.620290976265 93.1344138681889,121.480146628121 98.7642164230347,104.440107565621 106.163519859314,88.1002790744096 111.540782928467,76.2201444918901 116.754514694214,64.2802030856401 126.119003295898,54.530172568062 139.469326019287,40.6303007418901 152.51602935791,25.7401640231401 169.966026306152,17.710104208687 186.287551879883,10.2001259143144 203.18856048584,2.91033170769515 221.881591796875,1.36024795124831 230.645568847656,0.630302589634084 239.355575561523,0.300224464634084 248.086547851563,0.300176870325231 371.270645141602,0.210136574009084 494.455673217773,0.350273292759084 617.639724731445,0.000119525742775295z"/>
+</svg>
\ No newline at end of file
--- /dev/null
+<?xml version="1.0" encoding="utf-8"?>
+<svg version="1.2" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
+ x="0px" y="0px" width="50px" height="50px" viewBox="0 0 36.15 64">
+<path fill="#fff" d="M34.121552,40.051L36.144999,43.16945 15.130303,56.796999 13.106756,53.677217 13.106756,53.675916 8.6079996,46.735841 11.726523,44.71375 16.22783,51.65373z M0,36.751001L27.249001,36.751001 27.249001,42.554475 23.151356,45.210752 23.151356,40.848707 4.0964856,40.848707 4.0964856,59.901056 23.151356,59.901056 23.151356,53.548086 27.249001,50.890455 27.249001,64.000001 0,64.000001z M34.121553,3.3010007L36.145,6.4182236 15.130303,20.046001 13.106757,16.926167 13.106757,16.924866 8.6079996,9.9846706 11.726523,7.9638004 16.227831,14.904045z M0,0L27.249001,0 27.249001,5.8034441 23.151356,8.4597235 23.151356,4.0990154 4.0964847,4.0990154 4.0964847,23.149955 23.151356,23.149955 23.151356,16.798385 27.249001,14.140756 27.249001,27.249 0,27.249z"/>
+</svg>
\ No newline at end of file
--- /dev/null
+<?xml version="1.0" encoding="utf-8"?>
+<svg version="1.2" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
+ x="0px" y="0px" width="24px" height="24px" viewBox="0 0 24 24">
+<polygon fill="#fff" points="11.476,7.766 11.476,22.481 0,17.21 0,3.677 "/>
+<polygon fill="#fff" points="24,3.677 20.336,4.936 20.336,13.163 17.261,14.168 17.261,5.991 12.532,7.617 12.534,22.63
+ 24,17.847 "/>
+<polygon fill="#fff" points="20.129,3.875 23.409,2.758 11.744,0 8.986,0.749 "/>
+<polyline fill="#fff" points="0.709,2.996 11.586,6.779 16.823,4.998 5.616,1.694 "/>
+</svg>
--- /dev/null
+<?xml version="1.0" encoding="utf-8"?>
+<svg version="1.2" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
+ x="0px" y="0px" width="50px" height="50px" viewBox="0 0 769.77 768">
+<path fill="#fff" d="M421.284,381.888C339.661,381.888,268.338,443.52,228.7,535.488L613.911,535.488C574.229,443.52,502.906,381.888,421.284,381.888z M421.327,232.512C379.604,232.512 345.833,262.387 345.833,299.212 345.833,336 379.604,365.913 421.327,365.913 463.008,365.913 496.778,336 496.778,299.212 496.778,262.387 463.008,232.512 421.327,232.512z M72.7557,0L769.768,0 769.768,768 72.7557,768 72.7557,717.964 0,717.964 0,666.662 72.7557,666.662 72.7557,562.752 0,562.752 0,511.45 72.7557,511.45 72.7557,407.539 0,407.539 0,356.237 72.7557,356.237 72.7557,252.364 0,252.364 0,201.062 72.7557,201.062 72.7557,97.1519 0,97.1519 0,45.8496 72.7557,45.8496z"/>
+</svg>
\ No newline at end of file
--- /dev/null
+<?xml version="1.0" encoding="utf-8"?>
+<svg version="1.2" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
+ x="0px" y="0px" width="50px" height="50px" viewBox="0 0 59.52 64.89">
+<path fill="#fff" d="M42.5273,41.723001C43.526165,41.723001 44.334997,42.532689 44.334997,43.52985 44.334997,44.527212 43.526165,45.337 42.5273,45.337 41.529735,45.337 40.721001,44.527212 40.721001,43.52985 40.721001,42.532689 41.529735,41.723001 42.5273,41.723001z M42.526852,38.675563C39.845855,38.675563 37.672762,40.848755 37.672762,43.529648 37.672762,46.21204 39.845855,48.383831 42.526852,48.383831 45.209139,48.383831 47.382336,46.21204 47.382336,43.529648 47.382336,40.848755 45.209139,38.675563 42.526852,38.675563z M42.526852,26.538999C51.91102,26.538999 59.519001,34.145677 59.519001,43.529648 59.519001,52.91382 51.91102,60.521997 42.526852,60.521997 33.142777,60.521997 25.535999,52.91382 25.536,43.529648 25.535999,34.145677 33.142777,26.538999 42.526852,26.538999z M42.526997,2.0219994L41.908512,25.210945C32.078032,25.541048 24.17721,33.62052 24.17721,43.530008 24.17721,48.569153 26.220764,53.138992 29.52009,56.459223L12.752867,64.890997 11.296,5.1781483z M31.717268,0L40.941,1.1314697 9.709528,4.2877789 11.166617,63.999998 1.9426556,59.144499 0,2.9126587z"/>
+</svg>
\ No newline at end of file
var app = {\r
dataset: null,\r
+ getpage: function(modulepage,data) {\r
+ var rdata = {"page":modulepage};\r
+ if (typeof data == 'object') {\r
+ for (var i in data) {\r
+ rdata[i] = data[i];\r
+ }\r
+ }\r
+ req.reqdata("POST","page.cgi",rdata,app.loadpage);\r
+ },\r
+ loadpage: function(data){\r
+ document.getElementById("mainapp").innerHTML = data;\r
+ \r
+ },\r
loadappview: function(panelid) {\r
document.getElementById('modules').style.display = 'none';\r
document.getElementById('appview').style.display = 'block';\r
--- /dev/null
+var record = {
+ redirectpage:null,
+ add: function(page,tbl){
+ record.redirectpage = page;
+ req.reqdata("POST","db.cgi",{"ins":tbl},record.afterrequest);
+ },
+ remove: function(page){
+ record.redirectpage = page;
+ req.reqdata("POST","db.cgi",{"del":tbl},record.afterrequest);
+ },
+ edit: function(page){
+ record.redirectpage = page;
+ app.getpage(page,{"id":table.selection});
+ },
+ duplicate: function(page){
+ record.redirectpage = page;
+ req.reqdata("POST","db.cgi",{"dupl":tbl},record.afterrequest);
+ },
+ afterrequest: function(data){
+ app.getpage(tecord.redirectpage,null);
+ },
+ confirm: function(){
+
+ },
+ savefield: function(obj){
+
+ var fdata = obj.dataset;
+ fdata["save"] = "field";
+ fdata["value"] = obj.value;
+ console.log(obj.tagName);
+ console.log(obj.dataset);
+ console.log("Value:" + obj.value);
+ req.reqdata("POST","db.cgi",fdata,record.saveresult);
+ // if (obj.TagName == "INPUT"){
+
+ // }
+ // if (obj.TagName == "SELECT"){
+
+ // }
+ },
+ saveresult: function(data){
+ console.log(data);
+ }
+}
\ No newline at end of file
--- /dev/null
+var table = {
+ table:null,
+ selection:null,
+ setselection(objid){
+ //table.selection = objid;
+ console.log(table.selection);
+ if (table.selection != null){
+ document.getElementById("ds_" + table.selection).classList.remove("portal_selected");
+ if (objid == table.selection){
+ table.selection = null;
+ return false;
+ }
+ }
+ table.selection = objid;
+ document.getElementById("ds_" + objid).classList.add("portal_selected");
+ return false;
+ }
+}
\ No newline at end of file
};
-my @args = ("-p","6060","--error-log",$RealBin."/error.log","--access-log",$RealBin."/access.log");#,"-R",$RealBin.'/CGI,'.$RealBin.'/CGI/api,'.$RealBin.'/CGI/api/lib'
+my @args = ("-p","6060");#,"-R",$RealBin.'/CGI,'.$RealBin.'/CGI/api,'.$RealBin.'/CGI/api/lib',"--error-log",$RealBin."/error.log","--access-log",$RealBin."/access.log"
my $runner = Plack::Runner->new(server => 'Starlight', env => 'deployment', ipv6 => '1' );#env => ,deployment,development, test
$runner->parse_options(@args);
$runner->run($allapp);