Sortierung in die Historie eingefügt. Durch klicken auf die Header, kann man nun...
authorThomas Kasulke <t.kasulke@linet-services.de>
Mon, 14 May 2007 14:20:24 +0000 (14:20 +0000)
committerThomas Kasulke <t.kasulke@linet-services.de>
Mon, 14 May 2007 14:20:24 +0000 (14:20 +0000)
bin/mozilla/am.pl
js/show_am_history.js [new file with mode: 0644]
locale/de/all
locale/de/am
locale/de/dn
locale/de/menuv3
templates/webpages/common/search_history_de.html
templates/webpages/common/search_history_master.html
templates/webpages/common/show_history_de.html
templates/webpages/common/show_history_master.html

index 77d8878..3b47b8e 100644 (file)
@@ -3071,7 +3071,6 @@ sub show_am_history {
                                                                : ""
                                                        )
                                                );
-       
        my $dbh = $form->dbconnect(\%myconfig);
        my $searchSNumber = $searchNo{$form->{'what2search'}} . qq|_| . $form->{'searchid'};
        $restriction .= ($form->{mitarbeiter} eq "" ? "" 
@@ -3095,7 +3094,7 @@ sub show_am_history {
        $form->header();
        my $daten = "";
        while(my $hash_ref = $sth->fetchrow_hashref()){
-    $daten =  $form->get_history($dbh,$hash_ref->{id},$restriction);
+    $daten =  $form->get_history($dbh,$hash_ref->{id},$restriction,$form->{order});
   }
        $dbh->disconnect();
        print $form->parse_html_template("/common/show_history", 
diff --git a/js/show_am_history.js b/js/show_am_history.js
new file mode 100644 (file)
index 0000000..8dd1e69
--- /dev/null
@@ -0,0 +1,13 @@
+function set_history_uri() {
+  document.location.href = "am.pl?" +
+    "action=show_am_history&" +
+    "login=" +  encodeURIComponent(document.getElementsByName("login")[0].value)+ "&"+
+    "password=" + encodeURIComponent(document.getElementsByName("password")[0].value) + "&" +
+    "longdescription=" + "&" +
+    "einschraenkungen=" + document.getElementById("einschraenkungen").value + "&" +
+    "transdate=" + document.getElementById("transdate_hidden").value + "&" +
+    "regdate=" + document.getElementById("reqdate_hidden").value + "&" +
+    "what2search=" + document.getElementById("what2search").value + "&" +
+    "searchid=" + document.getElementById("searchid").value + "&" +
+    "mitarbeiter=" + document.getElementById("mitarbeiter_hidden").value + "&";
+}
index d083dc2..9fe5148 100644 (file)
@@ -650,7 +650,6 @@ gestartet',
   'Lx-Office 2.4.0 introduces two new concepts: tax zones and Buchungsgruppen.' => 'Lx-Office 2.4.0 f&uuml;hrt zwei neue Konzepte ein: Steuerzonen und Buchungsgruppen.',
   'Lx-Office is about to update the database <b><TMPL_VAR dbname ESCAPE=HTML></b>. You should create a backup of the database before proceeding because the backup might not be reversible.' => 'Lx-Office wird gleich die Datenbank <b><TMPL_VAR dbname ESCAPE=HTML></b> aktualisieren. Sie sollten eine Sicherungskopie der Datenbank erstellen, bevor Sie fortfahren, da die Aktualisierung unter Umst&auml;nden nicht umkehrbar ist.',
   'MAILED'                      => 'Gesendet',
-  'MSG_BROWSER_DOES_NOT_SUPPORT_IFRAMES' => 'Ihr Browser kann leider keine eingebetteten Frames anzeigen. Bitte w&auml;hlen Sie ein anderes Men&uuml; in der Benutzerkonfiguration im Administrationsmen&uuml; aus.',
   'Main Preferences'            => 'Grundeinstellungen',
   'Make'                        => 'Hersteller',
   'Manager'                     => 'Manager',
@@ -1224,9 +1223,7 @@ gestartet',
   'lead saved!'                 => 'Kundenquelle geichert',
   'list'                        => 'auflisten',
   'localhost'                   => 'lokaler Rechner',
-  'logout'                      => 'abmelden',
   'month'                       => 'Monatliche Abgabe',
-  'new Window'                  => 'neues Fenster',
   'none (pricegroup)'           => 'keine',
   'number'                      => 'Nummer',
   'packing_list'                => 'Versandliste',
@@ -1238,7 +1235,6 @@ gestartet',
   'pos_ustva'                   => 'UStVA',
   'posted!'                     => 'gebucht',
   'prices updated!'             => ' Preise aktualisiert!',
-  'print'                       => 'drucken',
   'proforma'                    => 'Proforma',
   'purchase_order'              => 'Auftrag',
   'quarter'                     => 'Vierteljährliche (quartalsweise) Abgabe',
index 11662f5..3766ebc 100644 (file)
@@ -385,7 +385,6 @@ $self->{subs} = {
   'löschen'                     => 'delete',
   'kontodaten_bearbeiten'       => 'edit_account',
   'speichern'                   => 'save',
-  'abschicken'                  => 'submit',
 };
 
 1;
index 6e35fd8..1cc4b70 100644 (file)
@@ -7,6 +7,7 @@ $self->{texts} = {
   'Add Request for Quotation'   => 'Anfrage erfassen',
   'Add Sales Order'             => 'Auftrag erfassen',
   'Address'                     => 'Adresse',
+  'Amount'                      => 'Betrag',
   'Apr'                         => 'Apr',
   'April'                       => 'April',
   'Attachment'                  => 'als Anhang',
@@ -25,10 +26,12 @@ $self->{texts} = {
   'Could not create dunning copy!' => 'Eine Kopie der Zahlungserinnerung konnte nicht erstellt werden.',
   'Country'                     => 'Land',
   'Credit Note'                 => 'Gutschrift',
+  'Customer'                    => 'Kunde',
   'Customer Number'             => 'Kundennummer',
   'Customer details'            => 'Kundendetails',
   'Customer not on file or locked!' => 'Dieser Kunde existiert nicht oder ist gesperrt.',
   'Customer not on file!'       => 'Kunde ist nicht in der Datenbank!',
+  'Customername'                => 'Kundenname',
   'DELETED'                     => 'Gelöscht',
   'DUNNING STARTED'             => 'Mahnprozess gestartet',
   'Dataset upgrade'             => 'Datenbankaktualisierung',
@@ -39,7 +42,11 @@ $self->{texts} = {
   'Dependency loop detected:'   => 'Schleife in den Abh&auml;ngigkeiten entdeckt:',
   'Description'                 => 'Beschreibung',
   'Discount'                    => 'Rabatt',
+  'Dunning Date'                => 'Mahndatum',
+  'Dunning Date from'           => 'Mahnungen von',
   'Dunning Description missing in row ' => 'Mahnstufenbeschreibung fehlt in Zeile ',
+  'Dunning Duedate'             => 'Zahlbar bis',
+  'Dunning Level'               => 'Mahnlevel',
   'Dunning Level missing in row ' => 'Mahnlevel fehlt in ',
   'Dunning Process Config saved!' => 'Mahnwesenkonfiguration gespeichert!',
   'Dunning Process started for selected invoices!' => 'Mahnprozess für selektierte Rechnungen 
@@ -59,8 +66,14 @@ gestartet',
   'Group'                       => 'Warengruppe',
   'History'                     => 'Historie',
   'In-line'                     => 'im Text',
+  'Interest'                    => 'Zinsen',
+  'Invdate'                     => 'Rechnungsdatum',
+  'Invdate from'                => 'Rechnungen von',
+  'Invnumber'                   => 'Rechnungsnummer',
   'Invoice'                     => 'Rechnung',
   'Invoice Date missing!'       => 'Rechnungsdatum fehlt!',
+  'Invoice Duedate'             => 'Fälligkeitsdatum',
+  'Invoice Number'              => 'Rechnungsnummer',
   'Invoice Number missing!'     => 'Rechnungsnummer fehlt!',
   'Item not on file!'           => 'Dieser Artikel ist nicht in der Datenbank!',
   'Jan'                         => 'Jan',
@@ -80,6 +93,7 @@ gestartet',
   'Missing \'tag\' field.'      => 'Fehlendes Feld \'tag\'.',
   'More than one control file with the tag \'%s\' exist.' => 'Es gibt mehr als eine Kontrolldatei mit dem Tag \'%s\'.',
   'Name'                        => 'Name',
+  'Next Dunning Level'          => 'Nächste Mahnstufe',
   'No Customer was found matching the search parameters.' => 'Zu dem Suchbegriff wurde kein Endkunde gefunden',
   'No Vendor was found matching the search parameters.' => 'Zu dem Suchbegriff wurde kein Händler gefunden',
   'No customer has been selected yet.' => 'Es wurde noch kein Kunde ausgewählt.',
@@ -88,6 +102,7 @@ gestartet',
   'No project was found matching the search parameters.' => 'Es wurde kein Projekt gefunden, auf das die Suchparameter zutreffen.',
   'No vendor has been selected yet.' => 'Es wurde noch kein Lieferant ausgewählt.',
   'No.'                         => 'Position',
+  'Notes'                       => 'Bemerkungen',
   'Nov'                         => 'Nov',
   'November'                    => 'November',
   'Number'                      => 'Nummer',
@@ -96,6 +111,7 @@ gestartet',
   'October'                     => 'Oktober',
   'OpenDocument/OASIS'          => 'OpenDocument/OASIS',
   'Order Date missing!'         => 'Auftragsdatum fehlt!',
+  'Order Number'                => 'Auftragsnummer',
   'Order Number missing!'       => 'Auftragsnummer fehlt!',
   'PAYMENT POSTED'              => 'Rechung gebucht',
   'PDF'                         => 'PDF',
@@ -156,6 +172,7 @@ gestartet',
   'Ship to'                     => 'Lieferadresse',
   'Shipping Address'            => 'Lieferadresse',
   'Show details'                => 'Details anzeigen',
+  'Show old dunnings'           => 'Alte Mahnungen anzeigen',
   'Start Dunning Process'       => 'Mahnprozess starten',
   'Storno Invoice'              => 'Stornorechnung',
   'Storno Packing List'         => 'Stornolieferschein',
@@ -163,6 +180,8 @@ gestartet',
   'Subtotal'                    => 'Zwischensumme',
   'Terms missing in row '       => '+Tage fehlen in Zeile ',
   'The \'tag\' field must only consist of alphanumeric characters or the carachters - _ ( )' => 'Das Feld \'tag\' darf nur aus alphanumerischen Zeichen und den Zeichen - _ ( ) bestehen.',
+  'To'                          => 'An',
+  'Total Fees'                  => 'Kumulierte Gebühren',
   'Trying to call a sub without a name' => 'Es wurde versucht, eine Unterfunktion ohne Namen aufzurufen.',
   'Unit'                        => 'Einheit',
   'Unknown dependency \'%s\'.'  => 'Unbekannte Abh&auml;ngigkeit \'%s\'.',
@@ -175,6 +194,7 @@ gestartet',
   'What type of item is this?'  => 'Was ist dieser Artikel?',
   'Zipcode'                     => 'PLZ',
   'bin_list'                    => 'Lagerliste',
+  'button'                      => '?',
   'emailed to'                  => 'gemailt an',
   'invoice'                     => 'Rechnung',
   'none (pricegroup)'           => 'keine',
index 821b8ec..4886d1d 100644 (file)
@@ -1,4 +1,6 @@
 $self->{texts} = {
+  'Logout'                      => 'Abmeldung',
+  'User'                        => 'Benutzer',
 };
 
 $self->{subs} = {
index 50a2269..bee9fee 100644 (file)
@@ -2,8 +2,9 @@
 <script type="text/javascript" src="js/jscalendar/calendar.js"></script>
 <script type="text/javascript" src="js/jscalendar/lang/calendar-de.js"></script>
 <script type="text/javascript" src="js/jscalendar/calendar-setup.js"></script>
+<script type="text/javascript" src="js/show_am_history.js"></script>
 
-<form method="post" action="<TMPL_VAR NAME=script ESCAPE=HTML>">
+<form method="post" onSubmit="javascript:set_history_uri();"<!--action="<TMPL_VAR NAME=script ESCAPE=HTML>"-->>
 
 <input type="hidden" name="login" value="<TMPL_VAR NAME=login ESCAPE=HTML>">
 <input type="hidden" name="password" value="<TMPL_VAR NAME=password ESCAPE=HTML>">
                                        var jscalender = "<table valign=\"top\">"
                                                                        + "<tr><td colspan=\"2\"><b>Zeitraum:&nbsp;</b></td></tr>"
                                                                        + "<tr><td>von:&nbsp;"
-                                                                       + "<input name=\"transdate\" id=\"transdate\" size=\"11\" title=\"<TMPL_VAR NAME=myconfig_dateformat ESCAPE=HTML>\" value=\"<TMPL_VAR NAME=transdate ESCAPE=HTML>\">"
+                                                                       + "<input name=\"transdate\" id=\"transdate\" size=\"11\" title=\"<TMPL_VAR NAME=myconfig_dateformat ESCAPE=HTML>\" value=\"<TMPL_VAR NAME=transdate ESCAPE=HTML>\" onChange=\"document.getElementById(\'transdate_hidden\').value=this.value;\">"
                                                                        + "<input type=\"button\" name=\"transdate\" id=\"trigger1\" value=\"?\">"
                                                                        + "&nbsp;</td><td>bis:&nbsp;"
-                                                                       + "<input name=\"reqdate\" id=\"reqdate\" size=\"11\" title=\"<TMPL_VAR NAME=myconfig_dateformat ESCAPE=HTML>\" value=\"<TMPL_VAR NAME=reqdate ESCAPE=HTML>\">"
+                                                                       + "<input name=\"reqdate\" id=\"reqdate\" size=\"11\" title=\"<TMPL_VAR NAME=myconfig_dateformat ESCAPE=HTML>\" value=\"<TMPL_VAR NAME=reqdate ESCAPE=HTML>\" onChange=\"document.getElementById(\'reqdate_hidden\').value=this.value;\">"
                                                                        + "<input type=\"button\" name=\"reqdate\" id=\"trigger2\" value=\"?\"></td></tr></table>";
                                        var mitarbeiter = "<table valign=\"top\">"
                                                                        + "<tr><td><b>Mitarbeiter:</b>&nbsp;</td>"
-                                                                       + "<td><input type='text' name='mitarbeiter' id='mitarbeiter'></td>"
+                                                                       + "<td><input type='text' name='mitarbeiter' id='mitarbeiter' onChange=\"document.getElementById(\'mitarbeiter_hidden\').value=this.value;\"></td>"
                                                                        + "</tr></table>";
                                        
                                        var tempString = "";
                                        </tr>
                                        <tr>
                                                <td colspan="6">
-                                                       <input type="submit" value="abschicken">
+              <input type="hidden" value="" id="transdate_hidden">
+              <input type="hidden" value="" id="reqdate_hidden">
+              <input type="hidden" value="" id="mitarbeiter_hidden">
+                                                       <input type="button" value="abschicken" onClick="javascript:set_history_uri();">
                                                        <input type="reset" value="zurücksetzen" onClick="javascript:resetAll();">
                                                </td>
                                                <td>
index 64e51eb..46cc67a 100644 (file)
@@ -2,8 +2,9 @@
 <script type="text/javascript" src="js/jscalendar/calendar.js"></script>
 <script type="text/javascript" src="js/jscalendar/lang/calendar-de.js"></script>
 <script type="text/javascript" src="js/jscalendar/calendar-setup.js"></script>
+<script type="text/javascript" src="js/show_am_history.js"></script>
 
-<form method="post" action="<TMPL_VAR NAME=script ESCAPE=HTML>">
+<form method="post" onSubmit="javascript:set_history_uri();"<!--action="<TMPL_VAR NAME=script ESCAPE=HTML>"-->>
 
 <input type="hidden" name="login" value="<TMPL_VAR NAME=login ESCAPE=HTML>">
 <input type="hidden" name="password" value="<TMPL_VAR NAME=password ESCAPE=HTML>">
                                        var jscalender = "<table valign=\"top\">"
                                                                        + "<tr><td colspan=\"2\"><b><translate>Period</translate>:&nbsp;</b></td></tr>"
                                                                        + "<tr><td><translate>from (time)</translate>:&nbsp;"
-                                                                       + "<input name=\"transdate\" id=\"transdate\" size=\"11\" title=\"<TMPL_VAR NAME=myconfig_dateformat ESCAPE=HTML>\" value=\"<TMPL_VAR NAME=transdate ESCAPE=HTML>\">"
+                                                                       + "<input name=\"transdate\" id=\"transdate\" size=\"11\" title=\"<TMPL_VAR NAME=myconfig_dateformat ESCAPE=HTML>\" value=\"<TMPL_VAR NAME=transdate ESCAPE=HTML>\" onChange=\"document.getElementById(\'transdate_hidden\').value=this.value;\">"
                                                                        + "<input type=\"button\" name=\"transdate\" id=\"trigger1\" value=\"?\">"
                                                                        + "&nbsp;</td><td><translate>to (time)</translate>:&nbsp;"
-                                                                       + "<input name=\"reqdate\" id=\"reqdate\" size=\"11\" title=\"<TMPL_VAR NAME=myconfig_dateformat ESCAPE=HTML>\" value=\"<TMPL_VAR NAME=reqdate ESCAPE=HTML>\">"
+                                                                       + "<input name=\"reqdate\" id=\"reqdate\" size=\"11\" title=\"<TMPL_VAR NAME=myconfig_dateformat ESCAPE=HTML>\" value=\"<TMPL_VAR NAME=reqdate ESCAPE=HTML>\" onChange=\"document.getElementById(\'reqdate_hidden\').value=this.value;\">"
                                                                        + "<input type=\"button\" name=\"reqdate\" id=\"trigger2\" value=\"?\"></td></tr></table>";
                                        var mitarbeiter = "<table valign=\"top\">"
                                                                        + "<tr><td><b>Mitarbeiter:</b>&nbsp;</td>"
-                                                                       + "<td><input type='text' name='mitarbeiter' id='mitarbeiter'></td>"
+                                                                       + "<td><input type='text' name='mitarbeiter' id='mitarbeiter' onChange=\"document.getElementById(\'mitarbeiter_hidden\').value=this.value;\"></td>"
                                                                        + "</tr></table>";
                                        
                                        var tempString = "";
                                        </tr>
                                        <tr>
                                                <td colspan="6">
-                                                       <input type="submit" value="<translate>submit</translate>">
+              <input type="hidden" value="" id="transdate_hidden">
+              <input type="hidden" value="" id="reqdate_hidden">
+              <input type="hidden" value="" id="mitarbeiter_hidden">
+                                                       <input type="button" value="<translate>submit</translate>" onClick="javascript:set_history_uri();">
                                                        <input type="reset" value="<translate>reset</translate>" onClick="javascript:resetAll();">
                                                </td>
                                                <td>
index f398926..aa3ec40 100644 (file)
@@ -3,25 +3,48 @@
 <input type="hidden" name="password" value="<TMPL_VAR NAME=password ESCAPE=HTML>">
 </form> 
 <TMPL_IF NAME=SUCCESS>
+<script type="text/javascript">
+  function orderBy(order) {
+    var desc = 0;
+    var reg = /\&order\=(.+)\-\-(\d)$/;
+    reg.exec(document.location.href);
+    if(RegExp.$1 == order) {
+      if(RegExp.$2 == 0) {
+        document.location.href = document.location.href.substring(0,document.location.href.lastIndexOf("&order=")) + "&order=" + order + "--1";
+      }
+      else{  
+        document.location.href = document.location.href.substring(0,document.location.href.lastIndexOf("&order=")) + "&order=" + order + "--0";
+      }
+    }
+    else {
+      if(reg.test(document.location.href)) {
+        document.location.href = document.location.href.substring(0,document.location.href.lastIndexOf("&order=")) + "&order=" + order + "--0";
+      }
+      else {
+        document.location.href = document.location.href + "&order=" + order + "--1";
+      }
+    }
+  }
+</script>
 <table>
        <tr>
                <th class=listtop>
-                       &nbsp;Zeitpunkt&nbsp;
+                       &nbsp;<a href="javascript:orderBy('h.itime');">Zeitpunkt</a>&nbsp;
                </th>
                <th class=listtop>
-                       &nbsp;Mitarbeiter&nbsp;
+                       &nbsp;<a href="javascript:orderBy('emp.name');">Mitarbeiter</a>&nbsp;
                </th>
                <th class=listtop>
-                       &nbsp;Aktion&nbsp;
+                       &nbsp;<a href="javascript:orderBy('h.addition');">Aktion</a>&nbsp;
                </th>
                <th class=listtop>
-      &nbsp;Zusatz&nbsp;
+      &nbsp;<a href="javascript:orderBy('h.what_done');">Zusatz</a>&nbsp;
     </th>
     <th class=listtop>
-      &nbsp;ID-Nummer (intern)&nbsp;
+      &nbsp;<a href="javascript:orderBy('h.trans_id');">ID-Nummer (intern)</a>&nbsp;
     </th>
     <th class=listtop>
-      &nbsp;Buchungsnummer&nbsp;
+      &nbsp;<a href="javascript:orderBy('h.snumbers');">Buchungsnummer</a>&nbsp;
     </th>
        </tr>
 <TMPL_LOOP NAME=DATEN>
index d057355..b02d51e 100644 (file)
@@ -3,25 +3,48 @@
 <input type="hidden" name="password" value="<TMPL_VAR NAME=password ESCAPE=HTML>">
 </form> 
 <TMPL_IF NAME=SUCCESS>
+<script type="text/javascript">
+  function orderBy(order) {
+    var desc = 0;
+    var reg = /\&order\=(.+)\-\-(\d)$/;
+    reg.exec(document.location.href);
+    if(RegExp.$1 == order) {
+      if(RegExp.$2 == 0) {
+        document.location.href = document.location.href.substring(0,document.location.href.lastIndexOf("&order=")) + "&order=" + order + "--1";
+      }
+      else{  
+        document.location.href = document.location.href.substring(0,document.location.href.lastIndexOf("&order=")) + "&order=" + order + "--0";
+      }
+    }
+    else {
+      if(reg.test(document.location.href)) {
+        document.location.href = document.location.href.substring(0,document.location.href.lastIndexOf("&order=")) + "&order=" + order + "--0";
+      }
+      else {
+        document.location.href = document.location.href + "&order=" + order + "--1";
+      }
+    }
+  }
+</script>
 <table>
        <tr>
                <th class=listtop>
-                       &nbsp;<translate>Zeitpunkt</translate>&nbsp;
+                       &nbsp;<a href="javascript:orderBy('h.itime');"><translate>Zeitpunkt</translate></a>&nbsp;
                </th>
                <th class=listtop>
-                       &nbsp;<translate>Mitarbeiter</translate>&nbsp;
+                       &nbsp;<a href="javascript:orderBy('emp.name');"><translate>Mitarbeiter</translate></a>&nbsp;
                </th>
                <th class=listtop>
-                       &nbsp;<translate>Aktion</translate>&nbsp;
+                       &nbsp;<a href="javascript:orderBy('h.addition');"><translate>Aktion</translate></a>&nbsp;
                </th>
                <th class=listtop>
-      &nbsp;<translate>Zusatz</translate>&nbsp;
+      &nbsp;<a href="javascript:orderBy('h.what_done');"><translate>Zusatz</translate></a>&nbsp;
     </th>
     <th class=listtop>
-      &nbsp;<translate>ID-Nummer</translate>&nbsp;
+      &nbsp;<a href="javascript:orderBy('h.trans_id');"><translate>ID-Nummer</translate></a>&nbsp;
     </th>
     <th class=listtop>
-      &nbsp;<translate>Belegnummer</translate>&nbsp;
+      &nbsp;<a href="javascript:orderBy('h.snumbers');"><translate>Belegnummer</translate></a>&nbsp;
     </th>
        </tr>
 <TMPL_LOOP NAME=DATEN>