Added quick entries in supplier invoice/credit note as well. Based on bank payments
[fa-stable.git] / purchasing / includes / ui / invoice_ui.inc
index a5944816176b822aab497b4a16c13df6a4032113..693b6f92ea8c777cafc955c5136030e34083df31 100644 (file)
@@ -194,8 +194,28 @@ function display_gl_items(&$supp_trans, $mode=0)
        else
                $heading = _("GL Items for this Credit Note");
 
+       start_outer_table("width=100%");
+
+       if ($mode == 1)
+       {
+               $qes = has_quick_entries(-1, 0);
+               if ($qes !== false)
+               {
+                       echo "<div style='float:right;'>";
+                       echo _("Quick Entry:")."&nbsp;"; 
+                       quick_entries_list('qid', null, 0, 1);
+                       echo "&nbsp;"._("Amount")."&nbsp;";
+                       $amount = input_num('totamount');
+                       $dec = user_price_dec();
+                       echo "<input class='amount' type='text' name='totamount' size='7' maxlength='12' dec='$dec' value='$amount'>&nbsp;";
+                       submit('go', _("Go"), true, false, true);
+                       echo "</div>";
+               }       
+       }
        display_heading($heading);
 
+       end_outer_table(0, false);
+
        vertical_space(); // ouer table
 
        div_start('gl_items');