Eingabe, Anzeige und Filter für Mindesthaltbarkeitsanzeige ist
authorBernd Blessmann <bibi@online.de>
Sat, 6 Mar 2010 01:06:05 +0000 (02:06 +0100)
committerBernd Blessmann <bibi@online.de>
Sat, 6 Mar 2010 01:06:05 +0000 (02:06 +0100)
über show_best_before einschaltbar.

13 files changed:
SL/Form.pm
config/lx-erp.conf
config/lx-erp.conf.default
templates/webpages/do/stock_in_form_master.html
templates/webpages/do/stock_out_form_master.html
templates/webpages/generic/select_part_master.html
templates/webpages/wh/journal_filter_master.html
templates/webpages/wh/removal_parts_selection_master.html
templates/webpages/wh/report_filter_master.html
templates/webpages/wh/transfer_parts_selection_master.html
templates/webpages/wh/warehouse_selection_assembly_master.html
templates/webpages/wh/warehouse_selection_master.html
templates/webpages/wh/warehouse_selection_stock_master.html

index 905c629..51c43d1 100644 (file)
@@ -772,6 +772,7 @@ sub _prepare_html_template {
   $additional_params->{"conf_latex_templates"}        = $main::latex;
   $additional_params->{"conf_opendocument_templates"} = $main::opendocument_templates;
   $additional_params->{"conf_vertreter"}              = $main::vertreter;
+  $additional_params->{"conf_show_best_before"}       = $main::show_best_before;
 
   if (%main::debug_options) {
     map { $additional_params->{'DEBUG_' . uc($_)} = $main::debug_options{$_} } keys %main::debug_options;
index 21973a4..91bfc83 100644 (file)
@@ -2,7 +2,7 @@ use Cwd;
 
 use vars qw($dbcharset $eur $ghostscript_bin $html2ps_bin $language $latex_bin $latex_templates $lizenzen $memberfile
             $opendocument_templates $openofficeorg_daemon $openofficeorg_daemon_port $openofficeorg_writer_bin
-            $pg_dump_exe $pg_restore_exe $sendmail $sid $spool $templates $userspath $vertreter $webdav $xvfb_bin);
+            $pg_dump_exe $pg_restore_exe $sendmail $show_best_before $sid $spool $templates $userspath $vertreter $webdav $xvfb_bin);
 
 # path to user configuration files
 $userspath = "users";
@@ -43,6 +43,9 @@ $webdav = 0;
 $lizenzen = 1;
 $vertreter = 0;
 
+# Zeige Felder für Mindesthaltbarkeitsdatum
+$show_best_before = 0;
+
 ## Support fuer OpenDocument-Vorlagen
 # Diese Option legt fest, ob OpenDocument-Vorlagen generell verfuegbar sind.
 $opendocument_templates = 1;
index 8e7280d..e031c3e 100644 (file)
@@ -2,7 +2,7 @@ use Cwd;
 
 use vars qw($dbcharset $eur $ghostscript_bin $html2ps_bin $language $latex_bin $latex_templates $lizenzen $memberfile
             $opendocument_templates $openofficeorg_daemon $openofficeorg_daemon_port $openofficeorg_writer_bin
-            $pg_dump_exe $pg_restore_exe $sendmail $sid $spool $templates $userspath $vertreter $webdav $xvfb_bin);
+            $pg_dump_exe $pg_restore_exe $sendmail $show_best_before $sid $spool $templates $userspath $vertreter $webdav $xvfb_bin);
 
 # path to user configuration files
 $userspath = "users";
@@ -43,6 +43,9 @@ $webdav = 0;
 $lizenzen = 1;
 $vertreter = 0;
 
+# Zeige Felder für Mindesthaltbarkeitsdatum
+$show_best_before = 0;
+
 ## Support fuer OpenDocument-Vorlagen
 # Diese Option legt fest, ob OpenDocument-Vorlagen generell verfuegbar sind.
 $opendocument_templates = 1;
index 6b2caab..e8c411b 100644 (file)
@@ -92,7 +92,9 @@
      <th class="listheading"><translate>Warehouse</translate></th>
      <th class="listheading"><translate>Bin</translate></th>
      <th class="listheading"><translate>Charge Number</translate></th>
+     [% IF conf_show_best_before %]
      <th class="listheading"><translate>Best Before</translate></th>
+     [% END %]
      <th align="right" class="listheading"><translate>Qty</translate></th>
      <th align="right" class="listheading"><translate>Unit</translate></th>
     </tr>
      <td>[% HTML.escape(row.warehouse_description) %]</td>
      <td>[% HTML.escape(row.bin_description) %]</td>
      <td>[% HTML.escape(row.chargenumber) %]</td>
+     [% IF conf_show_best_before %]
      <td>[% HTML.escape(row.bestbefore) %]</td>
+     [% END %]
      <td>[% HTML.escape(LxERP.format_amount(row.qty)) %]</td>
      <td>[% HTML.escape(row.unit) %]</td>
 
 
      <td><select name="bin_id_[% loop.count %]" id="bin_id_[% loop.count %]"></select></td>
      <td><input name="chargenumber_[% loop.count %]" value="[% HTML.escape(row.chargenumber) %]"></td>
-
+     [% IF conf_show_best_before %]
      <td>
        <input name="bestbefore_[% loop.count %]" id="bestbefore_[% loop.count %]" value="[% HTML.escape(row.bestbefore) %]" size="11" title="[% myconfig_dateformat %]">
        <input type="button" name="b_bestbefore_[% loop.count %]" id="bestbefore_trigger_[% loop.count %]" value="?">
      </td>
-
+     [% END %]
      <td><input name="qty_[% loop.count %]" size="12" value="[% HTML.escape(LxERP.format_amount(row.qty)) %]"></td>
 
      <td>
  </form>
 
  [%- IF NOT delivered %]
+ [% IF conf_show_best_before %]
   <script type="text/javascript">
     <!--
     [%- FOREACH row = STOCK_INFO %]
     [%- END %]
     //-->
   </script>
+  [% END %]
   [%- END %]
 
 </body>
index 8e77f96..e8f7a13 100644 (file)
@@ -60,7 +60,9 @@
      <th class="listheading"><translate>Warehouse</translate></th>
      <th class="listheading"><translate>Bin</translate></th>
      <th class="listheading"><translate>Charge Number</translate></th>
+     [% IF conf_show_best_before %]
      <th class="listheading"><translate>Best Before</translate></th>
+     [% END %]
      [%- UNLESS delivered %]
      <th align="right" class="listheading"><translate>Available qty</translate></th>
      [%- END %]
@@ -74,8 +76,9 @@
      <td>[% HTML.escape(row.warehousedescription) %]</td>
      <td>[% HTML.escape(row.bindescription) %]</td>
      <td>[% HTML.escape(row.chargenumber) %]</td>
+     [% IF conf_show_best_before %]
      <td>[% HTML.escape(row.bestbefore) %]</td>
-
+     [% END %]
      [%- IF delivered %]
 
      <td>[% HTML.escape(LxERP.format_amount(row.stock_qty)) %]</td>
     <input type="hidden" name="warehouse_id_[% loop.count %]" value="[% HTML.escape(row.warehouse_id) %]">
     <input type="hidden" name="bin_id_[% loop.count %]"       value="[% HTML.escape(row.bin_id) %]">
     <input type="hidden" name="chargenumber_[% loop.count %]" value="[% HTML.escape(row.chargenumber) %]">
+    [% IF conf_show_best_before %]
     <input type="hidden" name="bestbefore_[% loop.count %]" value="[% HTML.escape(row.bestbefore) %]">
+    [% END %]
     [%- END %]
    </table>
   </p>
index 732ed2f..433bceb 100644 (file)
      <th class="listheading"><translate>Charge number</translate></th>
      [% END %]
      [% IF has_bestbefore %]
+     [% IF conf_show_best_before %]
      <th class="listheading"><translate>Best Before</translate></th>
      [% END %]
+     [% END %]
      [% IF has_ean %]
      <th class="listheading"><translate>EAN</translate></th>
      [% END %]
      </td>
      [% END %]
      [% IF has_bestbefore %]
+     [% IF conf_show_best_before %]
      <td>
       <input type="hidden" name="new_bestbefore_id_[% loop.count %]" value="[% HTML.escape(part.bestbefore_id) %]">
       <input type="hidden" name="new_bestbefore_[% loop.count %]" value="[% HTML.escape(part.bestbefore) %]">
       [% HTML.escape(part.bestbefore) %]
      </td>
      [% END %]
+     [% END %]
      [% IF has_ean %]
      <td>
       <input type="hidden" name="new_ean_[% loop.count %]" value="[% HTML.escape(part.ean) %]">
index 946a04c..5506045 100644 (file)
         <th align="right" nowrap><translate>Charge Number</translate>:</th>
         <td><input name="chargenumber" size=40></td>
        </tr>
+       [% IF conf_show_best_before %]
        <tr>
         <th align="right" nowrap><translate>Best Before</translate>:</th>
         <td>
          <input type="button" name="b_bestbefore" id="bestbefore_trigger" value="?">
         </td>
        </tr>
+       [% END %]
        <tr>
         <th align="right" nowrap><translate>Transfer Quantity</translate>:</th>
         <td>
         <td nowrap><label for="l_partnumber"><translate>Part Number</translate></label></td>
         <td align="right"><input name="l_chargenumber" id="l_chargenumber" class="checkbox" type="checkbox" value="Y" checked></td>
         <td nowrap><label for="l_chargenumber"><translate>Charge Number</translate></label></td>
+        [% IF conf_show_best_before %]
         <td align="right"><input name="l_bestbefore" id="l_bestbefore" class="checkbox" type="checkbox" value="Y" checked></td>
         <td nowrap><label for="l_bestbefore"><translate>Best Before</translate></label></td>
+        [% END %]
        </tr>
        <tr>
         <td align="right"><input name="l_trans_id" id="l_trans_id" class="checkbox" type="checkbox" value="Y"></td>
 
   <script type="text/javascript">
     <!--
+    [% IF conf_show_best_before %]
     Calendar.setup( {
       inputField : "bestbefore",
       ifFormat :"[% myconfig_jsc_dateformat %]",
       align : "BR",
       button : "bestbefore_trigger"
     });
+    [% END %]
 
     Calendar.setup( {
       inputField : "fromdate",
index 0f37513..ec48a78 100644 (file)
@@ -34,7 +34,9 @@
      <th class="listheading"><translate>Part Number</translate></th>
      <th class="listheading"><translate>Part Description</translate></th>
      <th class="listheading"><translate>Charge Number</translate></th>
+     [% IF conf_show_best_before %]
      <th class="listheading"><translate>Best Before</translate></th>
+     [% END %]
      <th class="listheading"><translate>EAN</translate></th>
      <th class="listheading"><translate>Available qty</translate></th>
      <th class="listheading"><translate>Removal qty</translate></th>
      <input type="hidden" name="partnumber_[% loop.count %]" value="[% HTML.escape(row.partnumber) %]">
      <input type="hidden" name="partdescription_[% loop.count %]" value="[% HTML.escape(row.partdescription) %]">
      <input type="hidden" name="chargenumber_[% loop.count %]" value="[% HTML.escape(row.chargenumber) %]">
+     [% IF conf_show_best_before %]
      <input type="hidden" name="bestbefore_[% loop.count %]" value="[% HTML.escape(row.bestbefore) %]">
+     [% END %]
      <input type="hidden" name="ean_[% loop.count %]" value="[% HTML.escape(row.ean) %]">
      <td>[% HTML.escape(row.bindescription) %]</td>
      <td>[% HTML.escape(row.partnumber) %]</td>
      <td>[% HTML.escape(row.partdescription) %]</td>
      <td>[% HTML.escape(row.chargenumber) %]</td>
+     [% IF conf_show_best_before %]
      <td>[% HTML.escape(row.bestbefore) %]</td>
+     [% END %]
      <td>[% HTML.escape(row.ean) %]</td>
      <td>[% HTML.escape(row.qty) %]</td>
      <td>
index 0c789a6..4a65f66 100644 (file)
         <th align="right" nowrap><translate>Charge Number</translate>:</th>
         <td><input name="chargenumber" size=40></td>
        </tr>
+       [% IF conf_show_best_before %]
        <tr>
         <th align="right" nowrap><translate>Best Before</translate>:</th>
         <td>
          <input type="button" name="b_bestbefore" id="bestbefore_trigger" value="?">
         </td>
        </tr>
+       [% END %]
        <tr>
         <th align="right" nowrap><translate>Qty in stock</translate>:</th>
         <td>
         <td nowrap><label for="l_partnumber"><translate>Part Number</translate></label></td>
         <td align="right"><input name="l_chargenumber" id="l_chargenumber" class="checkbox" type="checkbox" value="Y" checked></td>
         <td nowrap><label for="l_chargenumber"><translate>Charge Number</translate></label></td>
+        [% IF conf_show_best_before %]
         <td align="right"><input name="l_bestbefore" id="l_bestbefore" class="checkbox" type="checkbox" value="Y" checked></td>
         <td nowrap><label for="l_bestbefore"><translate>Best Before</translate></label></td>
+        [% END %]
        </tr>
 
        <tr><td colspan="4"><hr noshade height="1"></td></tr>
   </p>
  </form>
 
+ [% IF conf_show_best_before %]
  <script type="text/javascript">
    <!--
      Calendar.setup( {
      });
    //-->
  </script>
+ [% END %]
 
 </body>
 </html>
index 8b78a77..cbe2429 100644 (file)
@@ -66,7 +66,9 @@
      <th class="listheading"><translate>Part Number</translate></th>
      <th class="listheading"><translate>Part Description</translate></th>
      <th class="listheading"><translate>Charge Number</translate></th>
+     [% IF conf_show_best_before %]
      <th class="listheading"><translate>Best Before</translate></th>
+     [% END %]
      <th class="listheading"><translate>EAN</translate></th>
      <th class="listheading"><translate>Available qty</translate></th>
      <th class="listheading" colspan="2"><translate>Transfer qty</translate></th>
      <input type="hidden" name="partnumber_[% loop.count %]" value="[% HTML.escape(row.partnumber) %]">
      <input type="hidden" name="partdescription_[% loop.count %]" value="[% HTML.escape(row.partdescription) %]">
      <input type="hidden" name="chargenumber_[% loop.count %]" value="[% HTML.escape(row.chargenumber) %]">
+     [% IF conf_show_best_before %]
      <input type="hidden" name="bestbefore_[% loop.count %]" value="[% HTML.escape(row.bestbefore) %]">
+     [% END %]
      <input type="hidden" name="ean_[% loop.count %]" value="[% HTML.escape(row.ean) %]">
      <td>[% HTML.escape(row.bindescription) %]</td>
      <td>[% HTML.escape(row.partnumber) %]</td>
      <td>[% HTML.escape(row.partdescription) %]</td>
      <td>[% HTML.escape(row.chargenumber) %]</td>
+     [% IF conf_show_best_before %]
      <td>[% HTML.escape(row.bestbefore) %]</td>
+     [% END %]
      <td>[% HTML.escape(row.ean) %]</td>
      <td>[% HTML.escape(row.qty) %]</td>
      <td><input name="qty_[% loop.count %]" size="8" style="text-align: right"></td>
index 27f0344..7272fe8 100644 (file)
      <td><input name="chargenumber" size="30" value="[% HTML.escape(chargenumber) %]"></td>
     </tr>
 
+    [% IF conf_show_best_before %]
     <tr>
      <th align="right" nowrap><translate>Best Before</translate></th>
      <td>
        <input name="bestbefore" id="bestbefore" size="11" value="[% HTML.escape(bestbefore) %]" title="[% myconfig_dateformat %]">
        <input type="button" name="b_bestbefore" id="bestbefore_trigger" value="?">
-       </td>
+     </td>
     </tr>
+    [% END %]
 
     <tr>
      <th align="right" nowrap><translate>Quantity</translate></th>
   </p>
  </form>
 
+ [% IF conf_show_best_before %]
  <script type="text/javascript">
    <!--
      Calendar.setup( {
      });
    //-->
  </script>
+ [% END %]
 
 </body>
 </html>
index c6da317..e070a46 100644 (file)
      <td><input name="chargenumber" size="30"></td>
     </tr>
 
+    [% IF conf_show_best_before %]
     <tr>
      <th align="right" nowrap><translate>Best Before</translate></th>
      <td>
        <input type="button" name="b_bestbefore" id="bestbefore_trigger" value="?">
      </td>
     </tr>
+    [% END %]
 
     <tr>
      <th align="right" nowrap><translate>EAN</translate></th>
   </p>
  </form>
 
+ [% IF conf_show_best_before %]
  <script type="text/javascript">
    <!--
      Calendar.setup( {
      });
    //-->
  </script>
+ [% END %]
 
 </body>
 </html>
index 9b68561..e8b072c 100644 (file)
      <td><input name="chargenumber" size="30" value="[% HTML.escape(chargenumber) %]"></td>
     </tr>
 
+    [% IF conf_show_best_before %]
     <tr>
      <th align="right" nowrap><translate>Best Before</translate></th>
      <td>
        <input type="button" name="b_bestbefore" id="bestbefore_trigger" value="?">
      </td>
     </tr>
+    [% END %]
 
     <tr>
      <th align="right" nowrap><translate>EAN</translate></th>
   </p>
  </form>
 
+ [% IF conf_show_best_before %]
  <script type="text/javascript">
    <!--
      Calendar.setup( {
      });
    //-->
  </script>
+  [% END %]
 
 </body>
 </html>