mirror of
https://github.com/OpenXE-org/OpenXE.git
synced 2024-12-24 13:40:29 +01:00
Auftrag deckungsbeitrag implemented
This commit is contained in:
parent
2ae5e9f44a
commit
7cfb87c2c5
@ -2578,11 +2578,19 @@ class YUI {
|
||||
if(CHAR_LENGTH(b.bezeichnung)>" . $this->app->erp->MaxArtikelbezeichnung() . ",CONCAT(SUBSTR(b.bezeichnung,1," . $this->app->erp->MaxArtikelbezeichnung() . "),'...'),b.bezeichnung))
|
||||
) $erweiterte_ansicht)
|
||||
as Artikel,
|
||||
p.abkuerzung as projekt,
|
||||
b.nummer as nummer,
|
||||
DATE_FORMAT(lieferdatum,'%d.%m.%Y') as lieferdatum,
|
||||
trim(b.menge)+0 as menge,
|
||||
".$this->FormatPreis($preiscell)." as preis,
|
||||
b.waehrung,
|
||||
".$this->FormatPreis('b.rabatt')." as rabatt,";
|
||||
|
||||
|
||||
|
||||
p.abkuerzung as projekt, b.nummer as nummer, DATE_FORMAT(lieferdatum,'%d.%m.%Y') as lieferdatum, trim(b.menge)+0 as menge, ".$this->FormatPreis($preiscell)." as preis,b.waehrung, ".$this->FormatPreis('b.rabatt')." as rabatt, ";
|
||||
|
||||
if ($this->app->erp->RechteVorhanden('auftrag','einkaufspreise')) {
|
||||
$sql .= $this->FormatPreis('einkaufspreis')." as einkaufspreis,
|
||||
CONCAT(ROUND(deckungsbeitrag*100),'%') AS DB,
|
||||
";
|
||||
}
|
||||
|
||||
$sql .= "b.id as id
|
||||
FROM $table b
|
||||
@ -14718,7 +14726,7 @@ source: "index.php?module=ajax&action=filter&filtername=' . $filter . $extendurl
|
||||
if ($module == "angebot" || $module == "auftrag" || $module == "rechnung" || $module == "gutschrift" || $module == "proformarechnung") {
|
||||
|
||||
if ($schreibschutz != 1) {
|
||||
$addrow = array('<form action="" method="post" id="myform">', '[ARTIKELSTART]<input type="text" size="30" name="artikel" id="artikel" onblur="window.setTimeout(\'selectafterblur()\',200);">[ARTIKELENDE]', '<input type="text" name="projekt" id="projekt" size="10" readonly onclick="checkhere()" >', '<input type="text" name="nummer" id="nummer" size="7">', '<input type="text" size="8" name="lieferdatum" id="lieferdatum">', '<input type="text" name="menge" id="menge" size="5" onblur="window.setTimeout(\'selectafterblurmenge()\',200); document.getElementById(\'preis\').style.background =\'none\';">', '<input type="text" name="preis" id="preis" size="10" onclick="checkhere();">', '<input type="text" name="waehrung" id="waehrung" size="10" onclick="checkhere();">' ,'<input type="text" name="rabatt" id="rabatt" size="7">');
|
||||
$addrow = array('<form action="" method="post" id="myform">', '[ARTIKELSTART]<input type="text" size="30" name="artikel" id="artikel" onblur="window.setTimeout(\'selectafterblur()\',200);">[ARTIKELENDE]', '<input type="text" name="projekt" id="projekt" size="10" readonly onclick="checkhere()" >', '<input type="text" name="nummer" id="nummer" size="7">', '<input type="text" size="8" name="lieferdatum" id="lieferdatum">', '<input type="text" name="menge" id="menge" size="5" onblur="window.setTimeout(\'selectafterblurmenge()\',200); document.getElementById(\'preis\').style.background =\'none\';">', '<input type="text" name="preis" id="preis" size="10" onclick="checkhere();">', '<input type="text" name="waehrung" id="waehrung" size="10" onclick="checkhere();">' ,'<input type="text" name="rabatt" id="rabatt" size="7">','','');
|
||||
$addrow[] = '<input type="submit" value="einfügen" name="ajaxbuchen">
|
||||
<script type="text/javascript">
|
||||
document.onkeydown = function(evt) {
|
||||
@ -14881,9 +14889,11 @@ source: "index.php?module=ajax&action=filter&filtername=' . $filter . $extendurl
|
||||
}
|
||||
$table->headings[6] = 'Preis';
|
||||
$mengencol = 5;
|
||||
if ($module == "angebot" || $module == "auftrag" || $module == "rechnung" || $module == "gutschrift") $table->headings[7] = 'Währung';
|
||||
if ($module == "angebot" || $module == "auftrag" || $module == "rechnung" || $module == "gutschrift") $table->headings[8] = 'Rabatt';
|
||||
if ($module == "angebot" || $module == "auftrag" || $module == "rechnung" || $module == "gutschrift") $rabattcol = 8;
|
||||
if ($module == "angebot" || $module == "auftrag" || $module == "rechnung" || $module == "gutschrift") {
|
||||
$table->headings[7] = 'Währung';
|
||||
$table->headings[8] = 'Rabatt';
|
||||
$rabattcol = 8;
|
||||
}
|
||||
}
|
||||
$__arr = array($summencol, $mengencol, $rabattcol, $ecol, $dcol,$zwischensumme);
|
||||
$this->app->erp->RunHook('yui_sortlistadd_draw', 2,$table,$__arr);
|
||||
|
@ -1990,8 +1990,30 @@ class Auftrag extends GenAuftrag
|
||||
$gebuchtezeit = str_replace(".", ",", round($gebuchtezeit,2));
|
||||
}
|
||||
$summebrutto = $this->app->DB->Select("SELECT gesamtsumme FROM auftrag WHERE id='$id' LIMIT 1");
|
||||
$this->app->Tpl->Set('DECKUNGSBEITRAG',0);
|
||||
$this->app->Tpl->Set('DBPROZENT',0);
|
||||
|
||||
$sql = "
|
||||
SELECT
|
||||
umsatz_netto_gesamt,
|
||||
artikel,
|
||||
menge
|
||||
FROM
|
||||
`auftrag_position`
|
||||
WHERE
|
||||
`auftrag` = ".$id."
|
||||
";
|
||||
|
||||
$positionen = $this->app->DB->SelectArr($sql);
|
||||
$umsatz_gesamt = 0;
|
||||
$db_gesamt = 0;
|
||||
foreach ($positionen as $position) {
|
||||
$ek = $this->app->erp->GetEinkaufspreis($position['artikel'],$position['menge']);
|
||||
$db = $position['umsatz_netto_gesamt']-($ek*$position['menge']);
|
||||
$db_gesamt += $db;
|
||||
$umsatz_gesamt = $position['umsatz_netto_gesamt'];
|
||||
}
|
||||
|
||||
$this->app->Tpl->Set('DECKUNGSBEITRAG',$db_gesamt);
|
||||
$this->app->Tpl->Set('DBPROZENT',$umsatz_gesamt==0?"-":(round($db_gesamt/$umsatz_gesamt*100)."%"));
|
||||
$this->app->Tpl->Set('GEBUCHTEZEIT',0);
|
||||
|
||||
if($auftragArr[0]['ust_befreit']==0){
|
||||
@ -4947,6 +4969,9 @@ class Auftrag extends GenAuftrag
|
||||
$this->app->erp->LieferadresseButton($adresse);
|
||||
$this->app->erp->AnsprechpartnerAlsLieferadresseButton($adresse);
|
||||
$this->app->erp->AdresseAlsLieferadresseButton($adresse);
|
||||
|
||||
$this->app->erp->BerechneDeckungsbeitrag($id,'auftrag');
|
||||
|
||||
}
|
||||
|
||||
if($nummer!='') {
|
||||
|
@ -118,12 +118,13 @@
|
||||
</div>
|
||||
<div style="background-color:white">
|
||||
<h2 class="greyh2">{|Deckungsbeitrag|}</h2>
|
||||
<div style="padding:10px">
|
||||
|
||||
<div class="info">{|Dieses Modul ist erst ab Version Professional verfügbar|}</div>
|
||||
|
||||
|
||||
</div>
|
||||
<table width="100%">
|
||||
<tbody><tr><td>Deckungsbeitrag (netto) in EUR</td><td>DB (netto) in %</td></tr>
|
||||
<tr>
|
||||
<td class="greybox" width="50%">[DECKUNGSBEITRAG]</td>
|
||||
<td class="greybox" width="50%">[DBPROZENT]</td>
|
||||
</tr>
|
||||
</tbody></table>
|
||||
</div>
|
||||
[INTERNEBEMERKUNGEDIT]
|
||||
|
||||
|
@ -1,308 +1,312 @@
|
||||
<?php
|
||||
/*
|
||||
**** COPYRIGHT & LICENSE NOTICE *** DO NOT REMOVE ****
|
||||
*
|
||||
* Xentral (c) Xentral ERP Sorftware GmbH, Fuggerstrasse 11, D-86150 Augsburg, * Germany 2019
|
||||
*
|
||||
* This file is licensed under the Embedded Projects General Public License *Version 3.1.
|
||||
*
|
||||
* You should have received a copy of this license from your vendor and/or *along with this file; If not, please visit www.wawision.de/Lizenzhinweis
|
||||
* to obtain the text of the corresponding license version.
|
||||
*
|
||||
**** END OF COPYRIGHT & LICENSE NOTICE *** DO NOT REMOVE ****
|
||||
/*
|
||||
**** COPYRIGHT & LICENSE NOTICE *** DO NOT REMOVE ****
|
||||
*
|
||||
* Xentral (c) Xentral ERP Sorftware GmbH, Fuggerstrasse 11, D-86150 Augsburg, * Germany 2019
|
||||
*
|
||||
* This file is licensed under the Embedded Projects General Public License *Version 3.1.
|
||||
*
|
||||
* You should have received a copy of this license from your vendor and/or *along with this file; If not, please visit www.wawision.de/Lizenzhinweis
|
||||
* to obtain the text of the corresponding license version.
|
||||
*
|
||||
**** END OF COPYRIGHT & LICENSE NOTICE *** DO NOT REMOVE ****
|
||||
*/
|
||||
?>
|
||||
<?php
|
||||
|
||||
class WidgetGenauftrag_position
|
||||
{
|
||||
|
||||
private $app; //application object
|
||||
public $form; //store form object
|
||||
protected $parsetarget; //target for content
|
||||
|
||||
public function __construct($app,$parsetarget)
|
||||
{
|
||||
$this->app = $app;
|
||||
$this->parsetarget = $parsetarget;
|
||||
$this->Form();
|
||||
}
|
||||
|
||||
public function auftrag_positionDelete()
|
||||
{
|
||||
|
||||
$this->form->Execute("auftrag_position","delete");
|
||||
|
||||
$this->auftrag_positionList();
|
||||
}
|
||||
|
||||
function Edit()
|
||||
{
|
||||
$this->form->Edit();
|
||||
}
|
||||
|
||||
function Copy()
|
||||
{
|
||||
$this->form->Copy();
|
||||
}
|
||||
|
||||
public function Create()
|
||||
{
|
||||
$this->form->Create();
|
||||
}
|
||||
|
||||
public function Search()
|
||||
{
|
||||
$this->app->Tpl->Set($this->parsetarget,"SUUUCHEEE");
|
||||
}
|
||||
|
||||
public function Summary()
|
||||
{
|
||||
$this->app->Tpl->Set($this->parsetarget,"grosse Tabelle");
|
||||
}
|
||||
|
||||
function Form()
|
||||
{
|
||||
$this->form = $this->app->FormHandler->CreateNew("auftrag_position");
|
||||
$this->form->UseTable("auftrag_position");
|
||||
$this->form->UseTemplate("auftrag_position.tpl",$this->parsetarget);
|
||||
|
||||
$field = new HTMLInput("nummer","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("bezeichnung","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
$this->form->AddMandatory("bezeichnung","notempty","Pflichtfeld!","MSGBEZEICHNUNG");
|
||||
|
||||
$field = new HTMLTextarea("beschreibung",8,48,"","","","","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("menge","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
$this->form->AddMandatory("menge","notempty","Pflichtfeld!","MSGMENGE");
|
||||
|
||||
$field = new HTMLInput("preis","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLTextarea("formelmenge",2,48,"","","","","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLTextarea("formelpreis",2,48,"","","","","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLCheckbox("ohnepreis","","","1","0","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLCheckbox("ausblenden_im_pdf","","","1","0","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("waehrung","text","","15","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLSelect("umsatzsteuer",0,"umsatzsteuer","","","0");
|
||||
$field->AddOption('Standard','');
|
||||
$field->AddOption('Ermäßigt','ermaessigt');
|
||||
$field->AddOption('Befreit','befreit');
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLCheckbox("anderersteuersatz","","","","0","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("steuersatz","text","","15","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLTextarea("steuertext",3,50,"","","","","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("grundrabatt","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("rabatt1","text","","5","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("rabatt2","text","","5","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("rabatt3","text","","5","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("rabatt4","text","","5","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("rabatt5","text","","5","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLCheckbox("keinrabatterlaubt","","","1","0","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("rabatt","text","","15","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("einheit","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("vpe","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("lieferdatum","text","","15","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLCheckbox("lieferdatumkw","","","1","0","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("artikelnummerkunde","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("zolltarifnummer","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("herkunftsland","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld1","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld2","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld3","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld4","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld5","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld6","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld7","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld8","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld9","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld10","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld11","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld12","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld13","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld14","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld15","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld16","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld17","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld18","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld19","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld20","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld21","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld22","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld23","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld24","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld25","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld26","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld27","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld28","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld29","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld30","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld31","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld32","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld33","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld34","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld35","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld36","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld37","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld38","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld39","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld40","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("punkte","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("bonuspunkte","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("mlmdirektpraemie","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
|
||||
$field = new HTMLInput("kostenstelle","text","","15","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("erloese","text","","15","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLCheckbox("erloesefestschreiben","","","1","0","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLTextarea("bemerkung",3,40,"","","","","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
?>
|
||||
<?php
|
||||
|
||||
class WidgetGenauftrag_position
|
||||
{
|
||||
|
||||
private $app; //application object
|
||||
public $form; //store form object
|
||||
protected $parsetarget; //target for content
|
||||
|
||||
public function __construct($app,$parsetarget)
|
||||
{
|
||||
$this->app = $app;
|
||||
$this->parsetarget = $parsetarget;
|
||||
$this->Form();
|
||||
}
|
||||
|
||||
public function auftrag_positionDelete()
|
||||
{
|
||||
|
||||
$this->form->Execute("auftrag_position","delete");
|
||||
|
||||
$this->auftrag_positionList();
|
||||
}
|
||||
|
||||
function Edit()
|
||||
{
|
||||
$this->form->Edit();
|
||||
}
|
||||
|
||||
function Copy()
|
||||
{
|
||||
$this->form->Copy();
|
||||
}
|
||||
|
||||
public function Create()
|
||||
{
|
||||
$this->form->Create();
|
||||
}
|
||||
|
||||
public function Search()
|
||||
{
|
||||
$this->app->Tpl->Set($this->parsetarget,"SUUUCHEEE");
|
||||
}
|
||||
|
||||
public function Summary()
|
||||
{
|
||||
$this->app->Tpl->Set($this->parsetarget,"grosse Tabelle");
|
||||
}
|
||||
|
||||
function Form()
|
||||
{
|
||||
$this->form = $this->app->FormHandler->CreateNew("auftrag_position");
|
||||
$this->form->UseTable("auftrag_position");
|
||||
$this->form->UseTemplate("auftrag_position.tpl",$this->parsetarget);
|
||||
|
||||
$field = new HTMLInput("nummer","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("bezeichnung","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
$this->form->AddMandatory("bezeichnung","notempty","Pflichtfeld!","MSGBEZEICHNUNG");
|
||||
|
||||
$field = new HTMLTextarea("beschreibung",8,48,"","","","","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("menge","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
$this->form->AddMandatory("menge","notempty","Pflichtfeld!","MSGMENGE");
|
||||
|
||||
$field = new HTMLInput("preis","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLTextarea("formelmenge",2,48,"","","","","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLTextarea("formelpreis",2,48,"","","","","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLCheckbox("ohnepreis","","","1","0","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLCheckbox("ausblenden_im_pdf","","","1","0","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("waehrung","text","","15","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLSelect("umsatzsteuer",0,"umsatzsteuer","","","0");
|
||||
$field->AddOption('Standard','');
|
||||
$field->AddOption('Ermäßigt','ermaessigt');
|
||||
$field->AddOption('Befreit','befreit');
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLCheckbox("anderersteuersatz","","","","0","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("steuersatz","text","","15","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLTextarea("steuertext",3,50,"","","","","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("grundrabatt","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("rabatt1","text","","5","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("rabatt2","text","","5","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("rabatt3","text","","5","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("rabatt4","text","","5","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("rabatt5","text","","5","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLCheckbox("keinrabatterlaubt","","","1","0","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("rabatt","text","","15","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("einheit","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("vpe","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("lieferdatum","text","","15","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLCheckbox("lieferdatumkw","","","1","0","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("artikelnummerkunde","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("zolltarifnummer","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("herkunftsland","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld1","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld2","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld3","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld4","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld5","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld6","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld7","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld8","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld9","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld10","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld11","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld12","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld13","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld14","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld15","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld16","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld17","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld18","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld19","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld20","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld21","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld22","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld23","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld24","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld25","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld26","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld27","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld28","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld29","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld30","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld31","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld32","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld33","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld34","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld35","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld36","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld37","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld38","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld39","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("freifeld40","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("punkte","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("bonuspunkte","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("mlmdirektpraemie","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("kostenstelle","text","","15","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLInput("erloese","text","","15","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
|
||||
$field = new HTMLCheckbox("erloesefestschreiben","","","1","0","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
if ($this->app->erp->RechteVorhanden('auftrag','einkaufspreise')) {
|
||||
$field = new HTMLInput("einkaufspreis","text","","50","","","","","","","","0","","");
|
||||
$this->form->NewField($field);
|
||||
}
|
||||
|
||||
$field = new HTMLTextarea("bemerkung",3,40,"","","","","0");
|
||||
$this->form->NewField($field);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
?>
|
||||
|
@ -222,34 +222,47 @@ $( document ).ready(function() {
|
||||
</table>
|
||||
</td>
|
||||
<td width="30%" [STYLERECHTS]>
|
||||
<table width="100%"><tr><td align="right"><input type="submit" value="Speichern" ></td></tr></table>
|
||||
<div id="positionaccordion">
|
||||
[ANZEIGEEINKAUFLAGER]
|
||||
|
||||
<h3>{|Steuer|}</h3>
|
||||
<div class="table-responsive">
|
||||
<table>
|
||||
<tbody>
|
||||
[VORSTEUER]
|
||||
<tr><td>{|Kostenstelle|}:</td><td>[KOSTENSTELLE][MSGKOSTENSTELLE]</td></tr>
|
||||
<tr><td>{|Erlöse|}:</td><td>[ERLOESE][MSGERLOESE]</td></tr>
|
||||
<tr><td>{|festschreiben|}:</td><td>[ERLOESEFESTSCHREIBEN][MSGERLOESEFESTSCHREIBEN]</td></tr>
|
||||
[NACHSTEUER]
|
||||
</tbody>
|
||||
</table>
|
||||
<table width="100%"><tr><td align="right"><input type="submit" value="Speichern" ></td></tr></table>
|
||||
<div id="positionaccordion"> [ANZEIGEEINKAUFLAGER]
|
||||
<h3>{|Steuer|}</h3>
|
||||
<div class="table-responsive">
|
||||
<table>
|
||||
<tbody> [VORSTEUER]
|
||||
<tr>
|
||||
<td>{|Kostenstelle|}:</td>
|
||||
<td>[KOSTENSTELLE][MSGKOSTENSTELLE]</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{|Erlöse|}:</td>
|
||||
<td>[ERLOESE][MSGERLOESE]</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{|festschreiben|}:</td>
|
||||
<td>[ERLOESEFESTSCHREIBEN][MSGERLOESEFESTSCHREIBEN]</td>
|
||||
</tr> [NACHSTEUER] </tbody>
|
||||
</table>
|
||||
</div>
|
||||
<h3>{|Einkaufspreis für Deckungsbeitrag|}</h3>
|
||||
<div class="table-responsive">
|
||||
<table>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>[EINKAUFSPREIS][MSGEINKAUFSPREIS]</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<h3>{|Bemerkung|}</h3>
|
||||
<div class="table-responsive">
|
||||
<table>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td> [BEMERKUNG][MSGBEMERKUNG] </td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<h3>{|Bemerkung|}</h3>
|
||||
<div class="table-responsive">
|
||||
<table>
|
||||
<tbody>
|
||||
<tr><td>
|
||||
[BEMERKUNG][MSGBEMERKUNG]
|
||||
</td></tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
|
@ -43,6 +43,7 @@ class WidgetAuftrag_position extends WidgetGenAuftrag_position
|
||||
$this->app->YUI->DatePicker("lieferdatum");
|
||||
$this->form->ReplaceFunction("lieferdatum",$this,"ReplaceDatum");
|
||||
$this->form->ReplaceFunction("preis",$this,"ReplaceMengeBetrag");
|
||||
$this->form->ReplaceFunction("einkaufspreis",$this,"ReplaceMengeBetrag");
|
||||
$this->form->ReplaceFunction("steuersatz",$this,"ReplaceSteuersatz");
|
||||
$this->form->ReplaceFunction("menge",$this,"ReplaceMenge");
|
||||
$this->form->ReplaceFunction("grundrabatt",$this,"ReplaceDecimal");
|
||||
|
Loading…
Reference in New Issue
Block a user