mirror of
https://github.com/OpenXE-org/OpenXE.git
synced 2024-12-25 14:10:28 +01:00
Bugfix count(null) www/pages
This commit is contained in:
parent
93e7ee4903
commit
eaa3b1da75
@ -97,7 +97,7 @@ class Shopimporter_Shopify_Adapter
|
|||||||
{
|
{
|
||||||
$len = strlen($header);
|
$len = strlen($header);
|
||||||
$header = explode(':', $header, 2);
|
$header = explode(':', $header, 2);
|
||||||
if (count($header) < 2){
|
if ((!empty($header)?count($header):0) < 2){
|
||||||
// ignore invalid headers
|
// ignore invalid headers
|
||||||
return $len;
|
return $len;
|
||||||
}
|
}
|
||||||
|
@ -73,8 +73,8 @@ class Adapterbox extends GenAdapterbox {
|
|||||||
$this->app->DB->real_escape_string($authkeys[$device])
|
$this->app->DB->real_escape_string($authkeys[$device])
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
$col1 .= "''".str_repeat(')', count($tmpdevices));
|
$col1 .= "''".str_repeat(')', (!empty($tmpdevices)?count($tmpdevices):0));
|
||||||
$col2 .= "''".str_repeat(')', count($tmpdevices));
|
$col2 .= "''".str_repeat(')', (!empty($tmpdevices)?count($tmpdevices):0));
|
||||||
$heading = ['Typ','Bezeichnung','Seriennummer','AuthKey',''];
|
$heading = ['Typ','Bezeichnung','Seriennummer','AuthKey',''];
|
||||||
$width = ['10%', '20%', '20%', '20%', '1%'];
|
$width = ['10%', '20%', '20%', '20%', '1%'];
|
||||||
$findcols = [
|
$findcols = [
|
||||||
|
@ -648,7 +648,7 @@ class Adresse extends GenAdresse {
|
|||||||
{
|
{
|
||||||
$doppelteids = $this->app->Secure->GetGET('id');
|
$doppelteids = $this->app->Secure->GetGET('id');
|
||||||
$ids = preg_split('/\-/',$doppelteids);
|
$ids = preg_split('/\-/',$doppelteids);
|
||||||
if(count($ids) > 1)
|
if((!empty($ids)?count($ids):0) > 1)
|
||||||
{
|
{
|
||||||
$typ = (int)$ids[0];
|
$typ = (int)$ids[0];
|
||||||
$id = (int)$ids[1];
|
$id = (int)$ids[1];
|
||||||
@ -1945,7 +1945,7 @@ class Adresse extends GenAdresse {
|
|||||||
$this->app->YUI->SaveReally();
|
$this->app->YUI->SaveReally();
|
||||||
|
|
||||||
$adresse_kontakte = $this->app->Secure->GetPOST('adresse_kontakte');
|
$adresse_kontakte = $this->app->Secure->GetPOST('adresse_kontakte');
|
||||||
if(!empty($adresse_kontakte) && count($adresse_kontakte) > 0) {
|
if(!empty($adresse_kontakte) && (!empty($adresse_kontakte)?count($adresse_kontakte):0) > 0) {
|
||||||
foreach($adresse_kontakte as $key=>$value)
|
foreach($adresse_kontakte as $key=>$value)
|
||||||
$this->app->DB->Update("UPDATE adresse_kontakte SET kontakt='$value' WHERE id='$key' LIMIT 1");
|
$this->app->DB->Update("UPDATE adresse_kontakte SET kontakt='$value' WHERE id='$key' LIMIT 1");
|
||||||
}
|
}
|
||||||
@ -3047,7 +3047,7 @@ function AdresseAnsprechpartner($als_lieferadresse=false)
|
|||||||
$gruppen = $this->app->DB->real_escape_string($this->app->Secure->GetPOST('gruppen'));
|
$gruppen = $this->app->DB->real_escape_string($this->app->Secure->GetPOST('gruppen'));
|
||||||
$gruppenarray = explode("|", $gruppen);
|
$gruppenarray = explode("|", $gruppen);
|
||||||
|
|
||||||
for ($i=0; $i < count($gruppenarray) ; $i++) {
|
for ($i=0; $i < (!empty($gruppenarray)?count($gruppenarray):0) ; $i++) {
|
||||||
if($gruppenarray[$i] != ''){
|
if($gruppenarray[$i] != ''){
|
||||||
$gruppenid = substr($gruppenarray[$i], 3);
|
$gruppenid = substr($gruppenarray[$i], 3);
|
||||||
$this->app->DB->Insert("INSERT INTO ansprechpartner_gruppen (ansprechpartner, gruppe, aktiv) VALUES ('$lid', '".$gruppenid."', '1')");
|
$this->app->DB->Insert("INSERT INTO ansprechpartner_gruppen (ansprechpartner, gruppe, aktiv) VALUES ('$lid', '".$gruppenid."', '1')");
|
||||||
@ -6241,22 +6241,22 @@ function AdresseVerein()
|
|||||||
|
|
||||||
|
|
||||||
function down($a,$x) {
|
function down($a,$x) {
|
||||||
if( count($a)-1 > $x ) {
|
if( (!empty($a)?count($a):0)-1 > $x ) {
|
||||||
$b = array_slice($a,0,$x,true);
|
$b = array_slice($a,0,$x,true);
|
||||||
$b[] = $a[$x+1];
|
$b[] = $a[$x+1];
|
||||||
$b[] = $a[$x];
|
$b[] = $a[$x];
|
||||||
$b += array_slice($a,$x+2,count($a),true);
|
$b += array_slice($a,$x+2,(!empty($a)?count($a):0),true);
|
||||||
return($b);
|
return($b);
|
||||||
}
|
}
|
||||||
return $a;
|
return $a;
|
||||||
}
|
}
|
||||||
|
|
||||||
function up($a,$x) {
|
function up($a,$x) {
|
||||||
if( $x > 0 && $x < count($a) ) {
|
if( $x > 0 && $x < (!empty($a)?count($a):0) ) {
|
||||||
$b = array_slice($a,0,($x-1),true);
|
$b = array_slice($a,0,($x-1),true);
|
||||||
$b[] = $a[$x];
|
$b[] = $a[$x];
|
||||||
$b[] = $a[$x-1];
|
$b[] = $a[$x-1];
|
||||||
$b += array_slice($a,($x+1),count($a),true);
|
$b += array_slice($a,($x+1),(!empty($a)?count($a):0),true);
|
||||||
return($b);
|
return($b);
|
||||||
}
|
}
|
||||||
return $a;
|
return $a;
|
||||||
|
@ -1171,7 +1171,7 @@ class Ajax {
|
|||||||
$terma = explode( ' ', $term);
|
$terma = explode( ' ', $term);
|
||||||
$term2a = explode( ' ', $term2);
|
$term2a = explode( ' ', $term2);
|
||||||
$term3a = explode( ' ', $term3);
|
$term3a = explode( ' ', $term3);
|
||||||
if(count($terma) === 1)
|
if((!empty($terma)?count($terma):0) === 1)
|
||||||
{
|
{
|
||||||
$wherea = [];
|
$wherea = [];
|
||||||
foreach($fields as $v) {
|
foreach($fields as $v) {
|
||||||
@ -1414,7 +1414,7 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
case "laender":
|
case "laender":
|
||||||
$laender = $this->app->erp->GetSelectLaenderliste();
|
$laender = $this->app->erp->GetSelectLaenderliste();
|
||||||
$_term = explode(',',$term);
|
$_term = explode(',',$term);
|
||||||
$_term = $_term[count($_term)-1];
|
$_term = $_term[(!empty($_term)?count($_term):0)-1];
|
||||||
if($laender){
|
if($laender){
|
||||||
foreach($laender as $key => $value)
|
foreach($laender as $key => $value)
|
||||||
{
|
{
|
||||||
@ -3506,22 +3506,22 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
$terma22 = '';
|
$terma22 = '';
|
||||||
$terma31 = '';
|
$terma31 = '';
|
||||||
$terma32 = '';
|
$terma32 = '';
|
||||||
if(count($terma2) > 1)
|
if((!empty($terma2)?count($terma2):0) > 1)
|
||||||
{
|
{
|
||||||
$terma22 = $terma2[count($terma2)-1];
|
$terma22 = $terma2[(!empty($terma2)?count($terma2):0)-1];
|
||||||
unset($terma2[count($terma2)-1]);
|
unset($terma2[(!empty($terma2)?count($terma2):0)-1]);
|
||||||
$terma21 = implode('%', $terma2);
|
$terma21 = implode('%', $terma2);
|
||||||
}
|
}
|
||||||
if(count($terma3) > 1)
|
if((!empty($terma3)?count($terma3):0) > 1)
|
||||||
{
|
{
|
||||||
$terma32 = $terma3[count($terma3)-1];
|
$terma32 = $terma3[(!empty($terma3)?count($terma3):0)-1];
|
||||||
unset($terma3[count($terma3)-1]);
|
unset($terma3[(!empty($terma3)?count($terma3):0)-1]);
|
||||||
$terma31 = implode('%', $terma3);
|
$terma31 = implode('%', $terma3);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(count($terma) > 1) {
|
if((!empty($terma)?count($terma):0) > 1) {
|
||||||
$terma12 = $terma[count($terma)-1];
|
$terma12 = $terma[(!empty($terma)?count($terma):0)-1];
|
||||||
unset($terma[count($terma)-1]);
|
unset($terma[(!empty($terma)?count($terma):0)-1]);
|
||||||
$terma11 = implode('%', $terma);
|
$terma11 = implode('%', $terma);
|
||||||
$subwheretmpa1 = null;
|
$subwheretmpa1 = null;
|
||||||
$subwheretmpa2 = null;
|
$subwheretmpa2 = null;
|
||||||
@ -4221,7 +4221,7 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if(!empty($searchsql) && count($searchsql) >0){
|
if(!empty($searchsql) && (!empty($searchsql)?count($searchsql):0) >0){
|
||||||
$sWhere = " WHERE $where AND (";
|
$sWhere = " WHERE $where AND (";
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
@ -4230,7 +4230,7 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
for($i=0;$i<count($searchsql)-1;$i++)
|
for($i=0;$i<(!empty($searchsql)?count($searchsql):0)-1;$i++)
|
||||||
{
|
{
|
||||||
$sWhere .= $searchsql[$i]." LIKE '%".$this->app->DB->real_escape_string($sSearch )."%' OR ";
|
$sWhere .= $searchsql[$i]." LIKE '%".$this->app->DB->real_escape_string($sSearch )."%' OR ";
|
||||||
}
|
}
|
||||||
@ -4340,7 +4340,7 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
}
|
}
|
||||||
if(strpos($spalte, 'datum')) {
|
if(strpos($spalte, 'datum')) {
|
||||||
$spaltea = explode('.', $spalte);
|
$spaltea = explode('.', $spalte);
|
||||||
if(count($spaltea) === 2){
|
if((!empty($spaltea)?count($spaltea):0) === 2){
|
||||||
return ' ( DATE_FORMAT('.$spalte.",'%d.%m.%Y %H:%i:%s') LIKE '%".$this->app->DB->real_escape_string($sSearch )."%' OR ".$spalte." LIKE '%".$this->app->DB->real_escape_string($sSearch )."%') ";
|
return ' ( DATE_FORMAT('.$spalte.",'%d.%m.%Y %H:%i:%s') LIKE '%".$this->app->DB->real_escape_string($sSearch )."%' OR ".$spalte." LIKE '%".$this->app->DB->real_escape_string($sSearch )."%') ";
|
||||||
}
|
}
|
||||||
}elseif(($numbercol || $spalte === 'soll' || $spalte === 'gesamtsumme') && strpos($sSearch,','))
|
}elseif(($numbercol || $spalte === 'soll' || $spalte === 'gesamtsumme') && strpos($sSearch,','))
|
||||||
@ -4349,11 +4349,11 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
}elseif((strpos($spalte, 'soll') || strpos($spalte, 'gesamtsumme')) && strpos($sSearch,','))
|
}elseif((strpos($spalte, 'soll') || strpos($spalte, 'gesamtsumme')) && strpos($sSearch,','))
|
||||||
{
|
{
|
||||||
$spaltea = explode('.', $spalte);
|
$spaltea = explode('.', $spalte);
|
||||||
if(count($spaltea) === 2){
|
if((!empty($spaltea)?count($spaltea):0) === 2){
|
||||||
return ' ( '.$spalte." LIKE '%".$this->app->DB->real_escape_string(str_replace(',','.',$sSearch) )."%' OR ".$spalte." LIKE '%".$this->app->DB->real_escape_string($sSearch )."%') ";
|
return ' ( '.$spalte." LIKE '%".$this->app->DB->real_escape_string(str_replace(',','.',$sSearch) )."%' OR ".$spalte." LIKE '%".$this->app->DB->real_escape_string($sSearch )."%') ";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(count($sSearcha) > 1)
|
if((!empty($sSearcha)?count($sSearcha):0) > 1)
|
||||||
{
|
{
|
||||||
return ' ('.$this->AjaxTableWhereBuilderArray($spalte, $sSearcha).')';
|
return ' ('.$this->AjaxTableWhereBuilderArray($spalte, $sSearcha).')';
|
||||||
}
|
}
|
||||||
@ -4366,13 +4366,13 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
{
|
{
|
||||||
return '';
|
return '';
|
||||||
}
|
}
|
||||||
$csSearcha = count($sSearcha);
|
$csSearcha = (!empty($sSearcha)?count($sSearcha):0);
|
||||||
$tmp = [];
|
$tmp = [];
|
||||||
foreach($sSearcha as $v)
|
foreach($sSearcha as $v)
|
||||||
{
|
{
|
||||||
$tmp[strtolower($v)] = 1+(!empty($tmp[strtolower($v)])?$tmp[strtolower($v)]:0);
|
$tmp[strtolower($v)] = 1+(!empty($tmp[strtolower($v)])?$tmp[strtolower($v)]:0);
|
||||||
}
|
}
|
||||||
if(count($tmp) === 1)
|
if((!empty($tmp)?count($tmp):0) === 1)
|
||||||
{
|
{
|
||||||
$sSearch = implode('%', $sSearcha);
|
$sSearch = implode('%', $sSearcha);
|
||||||
|
|
||||||
@ -4540,7 +4540,7 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
//$defaultorderdesc = $this->app->YUI->TableSearch("",$cmd,"defaultorderdesc","","",$frommodule, $fromclass);
|
//$defaultorderdesc = $this->app->YUI->TableSearch("",$cmd,"defaultorderdesc","","",$frommodule, $fromclass);
|
||||||
$defaultorderdesc = $YUIs['defaultorderdesc'];
|
$defaultorderdesc = $YUIs['defaultorderdesc'];
|
||||||
if($defaultorder<=0) {
|
if($defaultorder<=0) {
|
||||||
$defaultorder = count($findcolstmp);
|
$defaultorder = (!empty($findcolstmp)?count($findcolstmp):0);
|
||||||
$defaultorderdesc = 1;
|
$defaultorderdesc = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -4613,7 +4613,7 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
}
|
}
|
||||||
if($this->app->DB->real_escape_string( $sSearch ) !== $this->app->erp->ConvertForTableSearch( $sSearch ))
|
if($this->app->DB->real_escape_string( $sSearch ) !== $this->app->erp->ConvertForTableSearch( $sSearch ))
|
||||||
{
|
{
|
||||||
if(count($sSearcha) > 1)
|
if((!empty($sSearcha)?count($sSearcha):0) > 1)
|
||||||
{
|
{
|
||||||
$SqlElementQuery .= $this->AjaxTableWhereBuilderArray($valWhere, $sSearcha, $sSearcha2);
|
$SqlElementQuery .= $this->AjaxTableWhereBuilderArray($valWhere, $sSearcha, $sSearcha2);
|
||||||
}else{
|
}else{
|
||||||
@ -4621,7 +4621,7 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
{$valWhere} LIKE '%" . $this->app->erp->ConvertForTableSearch($sSearch) . "%' ) ";
|
{$valWhere} LIKE '%" . $this->app->erp->ConvertForTableSearch($sSearch) . "%' ) ";
|
||||||
}
|
}
|
||||||
}else{
|
}else{
|
||||||
if(count($sSearcha) > 1)
|
if((!empty($sSearcha)?count($sSearcha):0) > 1)
|
||||||
{
|
{
|
||||||
$SqlElementQuery .= $this->AjaxTableWhereBuilderArray($valWhere, $sSearcha);
|
$SqlElementQuery .= $this->AjaxTableWhereBuilderArray($valWhere, $sSearcha);
|
||||||
}else{
|
}else{
|
||||||
@ -4634,7 +4634,7 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
{
|
{
|
||||||
$SqlElementQuery .=" OR ({$valWhere} LIKE '%".$this->app->DB->real_escape_string( $sSearch2 )."%' OR {$valWhere} LIKE '%".$this->app->erp->ConvertForTableSearch( $sSearch2 )."%' ) ";
|
$SqlElementQuery .=" OR ({$valWhere} LIKE '%".$this->app->DB->real_escape_string( $sSearch2 )."%' OR {$valWhere} LIKE '%".$this->app->erp->ConvertForTableSearch( $sSearch2 )."%' ) ";
|
||||||
}else{
|
}else{
|
||||||
if(count($sSearcha) > 1)
|
if((!empty($sSearcha)?count($sSearcha):0) > 1)
|
||||||
{
|
{
|
||||||
$SqlElementQuery .= ' OR ('. $this->AjaxTableWhereBuilderArray($valWhere, $sSearcha2).') ';
|
$SqlElementQuery .= ' OR ('. $this->AjaxTableWhereBuilderArray($valWhere, $sSearcha2).') ';
|
||||||
}else{
|
}else{
|
||||||
@ -4720,14 +4720,14 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
{
|
{
|
||||||
$searchsql2[] = $v2;
|
$searchsql2[] = $v2;
|
||||||
if($datesearchcol && in_array($k, $datesearchcol)) {
|
if($datesearchcol && in_array($k, $datesearchcol)) {
|
||||||
$datesearchcol2[] = count($searchsql2)-1;
|
$datesearchcol2[] = (!empty($searchsql2)?count($searchsql2):0)-1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}else{
|
}else{
|
||||||
$searchsql2[] = $v;
|
$searchsql2[] = $v;
|
||||||
if($datesearchcol && in_array($k, $datesearchcol))
|
if($datesearchcol && in_array($k, $datesearchcol))
|
||||||
{
|
{
|
||||||
$datesearchcol2[] = count($searchsql2)-1;
|
$datesearchcol2[] = (!empty($searchsql2)?count($searchsql2):0)-1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -4737,7 +4737,7 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if(count($searchsql) > 0){
|
if((!empty($searchsql)?count($searchsql):0) > 0){
|
||||||
$sWhere = " WHERE $where AND (";
|
$sWhere = " WHERE $where AND (";
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
@ -4780,7 +4780,7 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
{
|
{
|
||||||
$sWhere .= '('.$this->AjaxTableWhereBuilder($searchsql2[$i], $sSearch, true, false).' OR '.$this->AjaxTableWhereBuilder($searchsql2[$i], $this->app->erp->ConvertForTableSearch( $sSearch ), true, false).")";
|
$sWhere .= '('.$this->AjaxTableWhereBuilder($searchsql2[$i], $sSearch, true, false).' OR '.$this->AjaxTableWhereBuilder($searchsql2[$i], $this->app->erp->ConvertForTableSearch( $sSearch ), true, false).")";
|
||||||
}else{
|
}else{
|
||||||
if(count($sSearcha) > 1)
|
if((!empty($sSearcha)?count($sSearcha):0) > 1)
|
||||||
{
|
{
|
||||||
$sWhere .= $this->AjaxTableWhereBuilderArray($searchsql2[$i], $sSearcha, $sSearcha2);
|
$sWhere .= $this->AjaxTableWhereBuilderArray($searchsql2[$i], $sSearcha, $sSearcha2);
|
||||||
}else{
|
}else{
|
||||||
@ -4792,7 +4792,7 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
if($datesearchcol2 && in_array($i, $datesearchcol2)) {
|
if($datesearchcol2 && in_array($i, $datesearchcol2)) {
|
||||||
$sWhere .= $this->AjaxTableWhereBuilder($searchsql2[$i], $sSearch, true, false);
|
$sWhere .= $this->AjaxTableWhereBuilder($searchsql2[$i], $sSearch, true, false);
|
||||||
}else{
|
}else{
|
||||||
if(count($sSearcha) > 1)
|
if((!empty($sSearcha)?count($sSearcha):0) > 1)
|
||||||
{
|
{
|
||||||
$sWhere .= $this->AjaxTableWhereBuilderArray($searchsql2[$i], $sSearcha);
|
$sWhere .= $this->AjaxTableWhereBuilderArray($searchsql2[$i], $sSearcha);
|
||||||
}else{
|
}else{
|
||||||
@ -4808,7 +4808,7 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
{
|
{
|
||||||
$sWhere .=" OR ({$searchsql2[$i]} LIKE '%".$this->app->DB->real_escape_string( $sSearch2 )."%' OR {$searchsql2[$i]} LIKE '%".$this->app->erp->ConvertForTableSearch( $sSearch2 )."%' ) ";
|
$sWhere .=" OR ({$searchsql2[$i]} LIKE '%".$this->app->DB->real_escape_string( $sSearch2 )."%' OR {$searchsql2[$i]} LIKE '%".$this->app->erp->ConvertForTableSearch( $sSearch2 )."%' ) ";
|
||||||
}else{
|
}else{
|
||||||
if(count($sSearcha) > 1)
|
if((!empty($sSearcha)?count($sSearcha):0) > 1)
|
||||||
{
|
{
|
||||||
$sWhere .= ' OR ('. $this->AjaxTableWhereBuilderArray($searchsql2[$i], $sSearcha2).') ';
|
$sWhere .= ' OR ('. $this->AjaxTableWhereBuilderArray($searchsql2[$i], $sSearcha2).') ';
|
||||||
}else{
|
}else{
|
||||||
@ -4839,7 +4839,7 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
$sSearch .= '*';
|
$sSearch .= '*';
|
||||||
$searchfulltext = ' MATCH(e.subject,e.sender,e.action,e.action_html) AGAINST (\''.$this->app->erp->ConvertForTableSearch($sSearch).'\' IN BOOLEAN MODE ) ';
|
$searchfulltext = ' MATCH(e.subject,e.sender,e.action,e.action_html) AGAINST (\''.$this->app->erp->ConvertForTableSearch($sSearch).'\' IN BOOLEAN MODE ) ';
|
||||||
}
|
}
|
||||||
if(count($searchsql2) > 0){
|
if((!empty($searchsql2)?count($searchsql2):0) > 0){
|
||||||
if($searchfulltext == '')
|
if($searchfulltext == '')
|
||||||
{
|
{
|
||||||
$sWhere .= ' 0)';
|
$sWhere .= ' 0)';
|
||||||
@ -5003,7 +5003,7 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
//TODO Alte Prozesse killen
|
//TODO Alte Prozesse killen
|
||||||
$_sql = substr($this->app->YUI->CodiereSQLForOneQuery($tmp, $cmd),0, 100);
|
$_sql = substr($this->app->YUI->CodiereSQLForOneQuery($tmp, $cmd),0, 100);
|
||||||
$processlist = $this->app->DB->SelectArr('SHOW PROCESSLIST');
|
$processlist = $this->app->DB->SelectArr('SHOW PROCESSLIST');
|
||||||
if(count($processlist) > 1) {
|
if((!empty($processlist)?count($processlist):0) > 1) {
|
||||||
foreach($processlist as $v) {
|
foreach($processlist as $v) {
|
||||||
if($v['Time'] > 1 && $v['db'] == $this->app->Conf->WFdbname && $v['User'] == $this->app->Conf->WFdbuser && substr($v['Info'], 0, 100) == $_sql) {
|
if($v['Time'] > 1 && $v['db'] == $this->app->Conf->WFdbname && $v['User'] == $this->app->Conf->WFdbuser && substr($v['Info'], 0, 100) == $_sql) {
|
||||||
$this->app->DB->kill($v['Id']);
|
$this->app->DB->kill($v['Id']);
|
||||||
@ -5056,7 +5056,7 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
};
|
};
|
||||||
$processed++;
|
$processed++;
|
||||||
}
|
}
|
||||||
} while ($processed < count($all_links));
|
} while ($processed < (!empty($all_links)?count($all_links):0));
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
$rResult = $this->app->DB->Query($sQuery);
|
$rResult = $this->app->DB->Query($sQuery);
|
||||||
@ -5107,7 +5107,7 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
};
|
};
|
||||||
$processed++;
|
$processed++;
|
||||||
}
|
}
|
||||||
} while ($processed < count($all_links));
|
} while ($processed < (!empty($all_links)?count($all_links):0));
|
||||||
if(!empty($YUIs['onequeryperuser'])) {
|
if(!empty($YUIs['onequeryperuser'])) {
|
||||||
$this->app->User->deleteParameter('tablesearch_'.$cmd.'_id2');
|
$this->app->User->deleteParameter('tablesearch_'.$cmd.'_id2');
|
||||||
}
|
}
|
||||||
@ -5155,7 +5155,7 @@ select a.kundennummer, (SELECT name FROM adresse a2 WHERE a2.kundennummer = a.ku
|
|||||||
};
|
};
|
||||||
$processed++;
|
$processed++;
|
||||||
}
|
}
|
||||||
} while ($processed < count($all_links));
|
} while ($processed < (!empty($all_links)?count($all_links):0));
|
||||||
if(!empty($YUIs['onequeryperuser'])) {
|
if(!empty($YUIs['onequeryperuser'])) {
|
||||||
$this->app->User->deleteParameter('tablesearch_'.$cmd.'_id2');
|
$this->app->User->deleteParameter('tablesearch_'.$cmd.'_id2');
|
||||||
}
|
}
|
||||||
|
@ -1079,7 +1079,7 @@ class Angebot extends GenAngebot
|
|||||||
$abgeschlossen = $this->app->Secure->GetPOST('abgeschlossen');
|
$abgeschlossen = $this->app->Secure->GetPOST('abgeschlossen');
|
||||||
}
|
}
|
||||||
$wiedervorlage = $this->app->DB->SelectArr("SELECT * from wiedervorlage WHERE module = 'angebot' AND parameter = '$id'");
|
$wiedervorlage = $this->app->DB->SelectArr("SELECT * from wiedervorlage WHERE module = 'angebot' AND parameter = '$id'");
|
||||||
if(count($wiedervorlage)> 0)
|
if((!empty($wiedervorlage)?count($wiedervorlage):0)> 0)
|
||||||
{
|
{
|
||||||
$wiedervorlage = reset($wiedervorlage);
|
$wiedervorlage = reset($wiedervorlage);
|
||||||
$datum_angelegt = $wiedervorlage['datum_angelegt'];
|
$datum_angelegt = $wiedervorlage['datum_angelegt'];
|
||||||
@ -2148,7 +2148,7 @@ class Angebot extends GenAngebot
|
|||||||
//$Brief->ArchiviereDocument();
|
//$Brief->ArchiviereDocument();
|
||||||
}
|
}
|
||||||
|
|
||||||
if(count($tmpfile) > 0)
|
if((!empty($tmpfile)?count($tmpfile):0) > 0)
|
||||||
{
|
{
|
||||||
try {
|
try {
|
||||||
/** @var PdfMerger $pdfMerger */
|
/** @var PdfMerger $pdfMerger */
|
||||||
|
@ -2959,8 +2959,8 @@ XML;
|
|||||||
//$out .= '</'.$position['beleg'].'>';
|
//$out .= '</'.$position['beleg'].'>';
|
||||||
}
|
}
|
||||||
$anz_belegegesamt++;
|
$anz_belegegesamt++;
|
||||||
//$out .= '</beleg_list><anz_gesamt>'.count($belege).'</anz_gesamt><anz_result>'.$j.'</anz_result>';
|
//$out .= '</beleg_list><anz_gesamt>'.(!empty($belege)?count($belege):0).'</anz_gesamt><anz_result>'.$j.'</anz_result>';
|
||||||
$xmlobj->AddChild('anz_gesamt',count($belege));
|
$xmlobj->AddChild('anz_gesamt',(!empty($belege)?count($belege):0));
|
||||||
$xmlobj->AddChild('anz_result',$j);
|
$xmlobj->AddChild('anz_result',$j);
|
||||||
if(!$groupbyartikel)
|
if(!$groupbyartikel)
|
||||||
{
|
{
|
||||||
@ -3823,7 +3823,7 @@ XML;
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
if((get_class($xml) === 'stdClass' && count($xml) > 0) || (isset($xml->xml) && count($xml->xml) > 0)) {
|
if((get_class($xml) === 'stdClass' && (!empty($xml)?count($xml):0) > 0) || (isset($xml->xml) && (!empty($xml->xml)?count($xml->xml):0) > 0)) {
|
||||||
foreach($xml as $key0 => $value0) {
|
foreach($xml as $key0 => $value0) {
|
||||||
if($key0 === 'status') {
|
if($key0 === 'status') {
|
||||||
$status = &$value0;
|
$status = &$value0;
|
||||||
@ -4165,13 +4165,13 @@ XML;
|
|||||||
if(!is_array($xml) && !is_object($xml)) {
|
if(!is_array($xml) && !is_object($xml)) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
if(count($xml) === 0) {
|
if((!empty($xml)?count($xml):0) === 0) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
foreach($xml as $key => $value) {
|
foreach($xml as $key => $value) {
|
||||||
if($key == $typ.'_position_list'){
|
if($key == $typ.'_position_list'){
|
||||||
if((is_array($value) || is_object($value)) && count($value) > 0) {
|
if((is_array($value) || is_object($value)) && (!empty($value)?count($value):0) > 0) {
|
||||||
foreach($value as $key2 => $value2) {
|
foreach($value as $key2 => $value2) {
|
||||||
if($key2 === $typ.'_position' && isset($value2->id_ext)) {
|
if($key2 === $typ.'_position' && isset($value2->id_ext)) {
|
||||||
$id_ext2 = (string)$value2->id_ext;
|
$id_ext2 = (string)$value2->id_ext;
|
||||||
@ -4215,7 +4215,7 @@ XML;
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(count($xml) === 0) {
|
if((!empty($xml)?count($xml):0) === 0) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
$id = 0;
|
$id = 0;
|
||||||
@ -4938,7 +4938,7 @@ XML;
|
|||||||
}
|
}
|
||||||
|
|
||||||
$mhd = $xml->mhd;
|
$mhd = $xml->mhd;
|
||||||
if(!empty($mhd) && !is_string($mhd) && !is_numeric($mhd) && count($mhd) === 1 && empty($mhd->datum)
|
if(!empty($mhd) && !is_string($mhd) && !is_numeric($mhd) && (!empty($mhd)?count($mhd):0) === 1 && empty($mhd->datum)
|
||||||
&& empty($mhd->mhddatum) && empty($mhd->anzahl)) {
|
&& empty($mhd->mhddatum) && empty($mhd->anzahl)) {
|
||||||
$mhd = reset($mhd);
|
$mhd = reset($mhd);
|
||||||
}
|
}
|
||||||
@ -4972,7 +4972,7 @@ XML;
|
|||||||
$mhdcharge = json_decode(json_encode($mhd->charge),true);
|
$mhdcharge = json_decode(json_encode($mhd->charge),true);
|
||||||
}
|
}
|
||||||
elseif(isset($xml->charge)
|
elseif(isset($xml->charge)
|
||||||
&& (is_string($xml->charge) || (!is_numeric($xml->charge) && count($xml->charge) === 1))) {
|
&& (is_string($xml->charge) || (!is_numeric($xml->charge) && (!empty($xml->charge)?count($xml->charge):0) === 1))) {
|
||||||
$mhdcharge = [(string)$xml->charge];
|
$mhdcharge = [(string)$xml->charge];
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -5032,7 +5032,7 @@ XML;
|
|||||||
if($v['mhddatum'] == $datum){
|
if($v['mhddatum'] == $datum){
|
||||||
if($artArr['chargenverwaltung'] > 0 && !empty($charge)){
|
if($artArr['chargenverwaltung'] > 0 && !empty($charge)){
|
||||||
if((string)$charge !== (string)$v['charge']){
|
if((string)$charge !== (string)$v['charge']){
|
||||||
if(count($mhddatum) === 1){
|
if((!empty($mhddatum)?count($mhddatum):0) === 1){
|
||||||
unset($wawimhd[$k]);
|
unset($wawimhd[$k]);
|
||||||
}
|
}
|
||||||
continue;
|
continue;
|
||||||
@ -5371,7 +5371,7 @@ XML;
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
$charge = $xml->charge;
|
$charge = $xml->charge;
|
||||||
if(!empty($charge) && !is_string($charge) && !is_numeric($charge) && count($charge) === 1 && empty($charge->charge)
|
if(!empty($charge) && !is_string($charge) && !is_numeric($charge) && (!empty($charge)?count($charge):0) === 1 && empty($charge->charge)
|
||||||
&& empty($charge->anzahl)) {
|
&& empty($charge->anzahl)) {
|
||||||
$charge = reset($charge);
|
$charge = reset($charge);
|
||||||
}
|
}
|
||||||
@ -7090,7 +7090,7 @@ XML;
|
|||||||
if(!isset($position->mhd_charge_block)) {
|
if(!isset($position->mhd_charge_block)) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
$sCount = count($position->mhd_charge_block);
|
$sCount = (!empty($position->mhd_charge_block)?count($position->mhd_charge_block):0);
|
||||||
if($sCount > 0) {
|
if($sCount > 0) {
|
||||||
$bestBefores = [];
|
$bestBefores = [];
|
||||||
foreach($position->mhd_charge_block as $mhd) {
|
foreach($position->mhd_charge_block as $mhd) {
|
||||||
@ -7128,7 +7128,7 @@ XML;
|
|||||||
if(empty($posDb)) {
|
if(empty($posDb)) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if(count($bestBefores) === 1 && empty($bestBefores[0]['amount'])) {
|
if((!empty($bestBefores)?count($bestBefores):0) === 1 && empty($bestBefores[0]['amount'])) {
|
||||||
$bestBefores[0]['amount'] = $posDb['menge'];
|
$bestBefores[0]['amount'] = $posDb['menge'];
|
||||||
}
|
}
|
||||||
$posDb['menge'] = $this->app->erp->ReplaceMenge(1, $posDb['menge'], 1);
|
$posDb['menge'] = $this->app->erp->ReplaceMenge(1, $posDb['menge'], 1);
|
||||||
@ -7273,7 +7273,7 @@ XML;
|
|||||||
if(!isset($position->serial)) {
|
if(!isset($position->serial)) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
$sCount = count($position->serial);
|
$sCount = (!empty($position->serial)?count($position->serial):0);
|
||||||
if($sCount > 0) {
|
if($sCount > 0) {
|
||||||
$serials = [];
|
$serials = [];
|
||||||
foreach($position->serial as $serial) {
|
foreach($position->serial as $serial) {
|
||||||
@ -11118,8 +11118,8 @@ XML;
|
|||||||
XML;
|
XML;
|
||||||
$_xmlobj = new SimpleXMLExtended($xmlstr);
|
$_xmlobj = new SimpleXMLExtended($xmlstr);
|
||||||
$xmlobj = $_xmlobj->AddChild('kontakte','');
|
$xmlobj = $_xmlobj->AddChild('kontakte','');
|
||||||
$xmlobj->AddChild('anz_gesamt',count($kontakte));
|
$xmlobj->AddChild('anz_gesamt',(!empty($kontakte)?count($kontakte):0));
|
||||||
$xmlobj->AddChild('anz_result',count($kontakte));
|
$xmlobj->AddChild('anz_result',(!empty($kontakte)?count($kontakte):0));
|
||||||
//$sxe->addAttribute('type', 'documentary');
|
//$sxe->addAttribute('type', 'documentary');
|
||||||
|
|
||||||
foreach($kontakte as $kontakt)
|
foreach($kontakte as $kontakt)
|
||||||
@ -11742,7 +11742,7 @@ XML;
|
|||||||
//$xml .= '<adresse>';
|
//$xml .= '<adresse>';
|
||||||
$RowKeys = array_keys($adresse);
|
$RowKeys = array_keys($adresse);
|
||||||
$RowValues = array_values($adresse);
|
$RowValues = array_values($adresse);
|
||||||
$cRowKeys = count($RowKeys);
|
$cRowKeys = (!empty($RowKeys)?count($RowKeys):0);
|
||||||
for($k = 1; $k < $cRowKeys;$k+=2)
|
for($k = 1; $k < $cRowKeys;$k+=2)
|
||||||
{
|
{
|
||||||
if($RowKeys[$k] !== 're_iskat' && $RowKeys[$k] !== 'gu_iskat' && $RowKeys[$k] !== 'be_iskat' && $RowKeys[$k] !== 'ab_iskat' && $RowKeys[$k] !== 'an_iskat')
|
if($RowKeys[$k] !== 're_iskat' && $RowKeys[$k] !== 'gu_iskat' && $RowKeys[$k] !== 'be_iskat' && $RowKeys[$k] !== 'ab_iskat' && $RowKeys[$k] !== 'an_iskat')
|
||||||
@ -11945,7 +11945,7 @@ XML;
|
|||||||
$sql .= " inner join artikelkategorien ak on ak.id = SUBSTRING_INDEX(a.typ,'_',1)";
|
$sql .= " inner join artikelkategorien ak on ak.id = SUBSTRING_INDEX(a.typ,'_',1)";
|
||||||
}
|
}
|
||||||
$wherevorhanden = false;
|
$wherevorhanden = false;
|
||||||
$ckeys = count($keys);
|
$ckeys = (!empty($keys)?count($keys):0);
|
||||||
for($i=0; $i<$ckeys; $i++){
|
for($i=0; $i<$ckeys; $i++){
|
||||||
if( ($keys[$i] != "order") && ($keys[$i] != "field") && ($keys[$i] != "limit") && ($keys[$i] != "offset") ){
|
if( ($keys[$i] != "order") && ($keys[$i] != "field") && ($keys[$i] != "limit") && ($keys[$i] != "offset") ){
|
||||||
$this->app->DB->Select("SELECT '" . $keys[$i] . "' FROM artikel LIMIT 1");
|
$this->app->DB->Select("SELECT '" . $keys[$i] . "' FROM artikel LIMIT 1");
|
||||||
@ -12037,11 +12037,11 @@ XML;
|
|||||||
|
|
||||||
$output = "";
|
$output = "";
|
||||||
|
|
||||||
if(count($ergebnis)>0)
|
if((!empty($ergebnis)?count($ergebnis):0)>0)
|
||||||
{
|
{
|
||||||
$output .= "<items>";
|
$output .= "<items>";
|
||||||
|
|
||||||
$cergebnis = count($ergebnis);
|
$cergebnis = (!empty($ergebnis)?count($ergebnis):0);
|
||||||
for($i=0;$i<$cergebnis;$i++)
|
for($i=0;$i<$cergebnis;$i++)
|
||||||
{
|
{
|
||||||
$output .= "<item>";
|
$output .= "<item>";
|
||||||
@ -12056,7 +12056,7 @@ XML;
|
|||||||
$output .= "</item>";
|
$output .= "</item>";
|
||||||
}
|
}
|
||||||
$output .= "<anz_gesamt>".$anz_gesamt."</anz_gesamt>";
|
$output .= "<anz_gesamt>".$anz_gesamt."</anz_gesamt>";
|
||||||
$output .= "<anz_result>".count($ergebnis)."</anz_result>";
|
$output .= "<anz_result>".(!empty($ergebnis)?count($ergebnis):0)."</anz_result>";
|
||||||
$output .= "<sql>".$sql."</sql>";
|
$output .= "<sql>".$sql."</sql>";
|
||||||
$output .= "</items>";
|
$output .= "</items>";
|
||||||
}
|
}
|
||||||
@ -14094,7 +14094,7 @@ XML;
|
|||||||
$csvseparator = ';';
|
$csvseparator = ';';
|
||||||
}
|
}
|
||||||
while (($data = fgetcsv($handle, 0, $csvseparator,'"')) !== FALSE) {
|
while (($data = fgetcsv($handle, 0, $csvseparator,'"')) !== FALSE) {
|
||||||
$num = count($data);
|
$num = (!empty($data)?count($data):0);
|
||||||
//echo "<p> $num Felder in Zeile $row: <br /></p>\n";
|
//echo "<p> $num Felder in Zeile $row: <br /></p>\n";
|
||||||
|
|
||||||
if($row > 1){
|
if($row > 1){
|
||||||
@ -14258,7 +14258,7 @@ XML;
|
|||||||
if(strpos($data[$c],'.') !== false)
|
if(strpos($data[$c],'.') !== false)
|
||||||
{
|
{
|
||||||
$datuma = explode('.',$data[$c]);
|
$datuma = explode('.',$data[$c]);
|
||||||
if(count($datuma) == 3)
|
if((!empty($datuma)?count($datuma):0) == 3)
|
||||||
{
|
{
|
||||||
if(strlen($datuma[2]) == 2)
|
if(strlen($datuma[2]) == 2)
|
||||||
{
|
{
|
||||||
@ -14279,7 +14279,7 @@ XML;
|
|||||||
if(strpos($data[$c],'.') !== false)
|
if(strpos($data[$c],'.') !== false)
|
||||||
{
|
{
|
||||||
$datuma = explode('.',$data[$c]);
|
$datuma = explode('.',$data[$c]);
|
||||||
if(count($datuma) == 3)
|
if((!empty($datuma)?count($datuma):0) == 3)
|
||||||
{
|
{
|
||||||
if(strlen($datuma[2]) == 2)
|
if(strlen($datuma[2]) == 2)
|
||||||
{
|
{
|
||||||
@ -14300,7 +14300,7 @@ XML;
|
|||||||
if(strpos($data[$c],'.') !== false)
|
if(strpos($data[$c],'.') !== false)
|
||||||
{
|
{
|
||||||
$datuma = explode('.',$data[$c]);
|
$datuma = explode('.',$data[$c]);
|
||||||
if(count($datuma) == 3)
|
if((!empty($datuma)?count($datuma):0) == 3)
|
||||||
{
|
{
|
||||||
if(strlen($datuma[2]) == 2)
|
if(strlen($datuma[2]) == 2)
|
||||||
{
|
{
|
||||||
@ -14321,7 +14321,7 @@ XML;
|
|||||||
if(strpos($data[$c],'.') !== false)
|
if(strpos($data[$c],'.') !== false)
|
||||||
{
|
{
|
||||||
$datuma = explode('.',$data[$c]);
|
$datuma = explode('.',$data[$c]);
|
||||||
if(count($datuma) == 3)
|
if((!empty($datuma)?count($datuma):0) == 3)
|
||||||
{
|
{
|
||||||
if(strlen($datuma[2]) == 2)
|
if(strlen($datuma[2]) == 2)
|
||||||
{
|
{
|
||||||
|
@ -415,11 +415,11 @@ class Artikel extends GenArtikel {
|
|||||||
}else{
|
}else{
|
||||||
$zusatzcols[] = $this->app->erp->FormatMenge('cache.' . $zusatzfeld);
|
$zusatzcols[] = $this->app->erp->FormatMenge('cache.' . $zusatzfeld);
|
||||||
}
|
}
|
||||||
$alignright[] = count($findcols);
|
$alignright[] = (!empty($findcols)?count($findcols):0);
|
||||||
break;
|
break;
|
||||||
case 'Preis':
|
case 'Preis':
|
||||||
$zusatzcols[] = $this->app->erp->FormatPreis('cache.'.$zusatzfeld,2);
|
$zusatzcols[] = $this->app->erp->FormatPreis('cache.'.$zusatzfeld,2);
|
||||||
$alignright[] = count($findcols);
|
$alignright[] = (!empty($findcols)?count($findcols):0);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
$zusatzcols[] = 'cache.'.$zusatzfeld;
|
$zusatzcols[] = 'cache.'.$zusatzfeld;
|
||||||
@ -1101,7 +1101,7 @@ class Artikel extends GenArtikel {
|
|||||||
}
|
}
|
||||||
|
|
||||||
$findcols = array_merge($findcols, array($lpicol, 'p.abkuerzung'));
|
$findcols = array_merge($findcols, array($lpicol, 'p.abkuerzung'));
|
||||||
$alignright = array(count($heading)-1);
|
$alignright = array((!empty($heading)?count($heading):0)-1);
|
||||||
$artikelzusatzfelder = $this->app->erp->getZusatzfelderArtikel();
|
$artikelzusatzfelder = $this->app->erp->getZusatzfelderArtikel();
|
||||||
$artikelcachedfelder = $this->app->erp->getArtikelCachedfelder();
|
$artikelcachedfelder = $this->app->erp->getArtikelCachedfelder();
|
||||||
$zusatzcols = null;
|
$zusatzcols = null;
|
||||||
@ -1126,14 +1126,14 @@ class Artikel extends GenArtikel {
|
|||||||
$zusatzcols[] = $this->app->erp->FormatMenge('cache.' . $zusatzfeld);
|
$zusatzcols[] = $this->app->erp->FormatMenge('cache.' . $zusatzfeld);
|
||||||
}
|
}
|
||||||
$findcols[] = 'cache.'.$zusatzfeld;
|
$findcols[] = 'cache.'.$zusatzfeld;
|
||||||
$alignright[] = count($findcols);
|
$alignright[] = (!empty($findcols)?count($findcols):0);
|
||||||
$numbercols[] = count($findcols) - 1;
|
$numbercols[] = (!empty($findcols)?count($findcols):0) - 1;
|
||||||
break;
|
break;
|
||||||
case 'Preis':
|
case 'Preis':
|
||||||
$findcols[] = 'ROUND(cache.'.$zusatzfeld.',2)';
|
$findcols[] = 'ROUND(cache.'.$zusatzfeld.',2)';
|
||||||
$zusatzcols[] = $this->app->erp->FormatPreis('cache.'.$zusatzfeld,2);
|
$zusatzcols[] = $this->app->erp->FormatPreis('cache.'.$zusatzfeld,2);
|
||||||
$alignright[] = count($findcols);
|
$alignright[] = (!empty($findcols)?count($findcols):0);
|
||||||
$numbercols[] = count($findcols) - 1;
|
$numbercols[] = (!empty($findcols)?count($findcols):0) - 1;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
$zusatzcols[] = 'cache.'.$zusatzfeld;
|
$zusatzcols[] = 'cache.'.$zusatzfeld;
|
||||||
@ -1196,7 +1196,7 @@ class Artikel extends GenArtikel {
|
|||||||
$heading[] = 'Menü';
|
$heading[] = 'Menü';
|
||||||
$width[] = '1%';
|
$width[] = '1%';
|
||||||
$findcols[] = 'a.id';
|
$findcols[] = 'a.id';
|
||||||
$menucol = count($heading) - 1;
|
$menucol = (!empty($heading)?count($heading):0) - 1;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
$heading = array('', 'Bild', 'Nummer', 'Artikel', 'Lagerbestand', 'Projekt', 'Menü');
|
$heading = array('', 'Bild', 'Nummer', 'Artikel', 'Lagerbestand', 'Projekt', 'Menü');
|
||||||
@ -2964,7 +2964,7 @@ class Artikel extends GenArtikel {
|
|||||||
$artikelmarkiert = $this->app->Secure->GetPOST('artikelmarkiert');
|
$artikelmarkiert = $this->app->Secure->GetPOST('artikelmarkiert');
|
||||||
$artikelmarkierthidden = $this->app->Secure->GetPOST('artikelmarkierthidden');
|
$artikelmarkierthidden = $this->app->Secure->GetPOST('artikelmarkierthidden');
|
||||||
|
|
||||||
$cartikelmarkiert = count($artikelmarkiert);
|
$cartikelmarkiert = (!empty($artikelmarkiert)?count($artikelmarkiert):0);
|
||||||
if($jetztgruen!='')
|
if($jetztgruen!='')
|
||||||
{
|
{
|
||||||
for($i=0;$i < $cartikelmarkiert; $i++) {
|
for($i=0;$i < $cartikelmarkiert; $i++) {
|
||||||
@ -3858,7 +3858,7 @@ class Artikel extends GenArtikel {
|
|||||||
if(strpos($v,':'))
|
if(strpos($v,':'))
|
||||||
{
|
{
|
||||||
$va = explode(':',$v);
|
$va = explode(':',$v);
|
||||||
if(count($va) > 1){
|
if((!empty($va)?count($va):0) > 1){
|
||||||
$waehrung = trim($va[0]);
|
$waehrung = trim($va[0]);
|
||||||
$preis = (float)str_replace(',','.',trim($va[1]));
|
$preis = (float)str_replace(',','.',trim($va[1]));
|
||||||
if($waehrung)
|
if($waehrung)
|
||||||
@ -4879,8 +4879,8 @@ class Artikel extends GenArtikel {
|
|||||||
|
|
||||||
$tpl .= "<td class=\"gentable\">".$array_mindestmengen[$j_am].'</td>';
|
$tpl .= "<td class=\"gentable\">".$array_mindestmengen[$j_am].'</td>';
|
||||||
|
|
||||||
if(count($fehlende_preise) > 0) {
|
if((!empty($fehlende_preise)?count($fehlende_preise):0) > 0) {
|
||||||
$tpl3 .= "<td class=\"gentable;\"><font color=red>".count($fehlende_preise).'</font></td>';
|
$tpl3 .= "<td class=\"gentable;\"><font color=red>".(!empty($fehlende_preise)?count($fehlende_preise):0).'</font></td>';
|
||||||
$tpl2 .= '<td class="gentable">-</td>';
|
$tpl2 .= '<td class="gentable">-</td>';
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
@ -4916,7 +4916,7 @@ class Artikel extends GenArtikel {
|
|||||||
}
|
}
|
||||||
$teile_tpl .="<td nowrap>$fehlende_artikel_links</td>";
|
$teile_tpl .="<td nowrap>$fehlende_artikel_links</td>";
|
||||||
|
|
||||||
if(count($fehlende_preise) <=0){
|
if((!empty($fehlende_preise)?count($fehlende_preise):0) <=0){
|
||||||
$tpl22 .='<td>-</td>';
|
$tpl22 .='<td>-</td>';
|
||||||
} else {
|
} else {
|
||||||
$tpl22 .='<td><s>'.number_format($summe_fehlende_preise_max+$preis,2,",","")."</s></td>";
|
$tpl22 .='<td><s>'.number_format($summe_fehlende_preise_max+$preis,2,",","")."</s></td>";
|
||||||
@ -4938,7 +4938,7 @@ class Artikel extends GenArtikel {
|
|||||||
$this->app->Tpl->Set('TAB5',"
|
$this->app->Tpl->Set('TAB5',"
|
||||||
<table width=\"100%\"><tr><td width=\"100\"><b>Artikel-Nr.</b></td><td><b>Name</b></td><td width=100><b>Aktion</b></td></tr>");
|
<table width=\"100%\"><tr><td width=\"100\"><b>Artikel-Nr.</b></td><td><b>Name</b></td><td width=100><b>Aktion</b></td></tr>");
|
||||||
sort($artikel_ohne_ek_eins);
|
sort($artikel_ohne_ek_eins);
|
||||||
$cartikel_ohne_ek_eins = count($artikel_ohne_ek_eins);
|
$cartikel_ohne_ek_eins = (!empty($artikel_ohne_ek_eins)?count($artikel_ohne_ek_eins):0);
|
||||||
for($j_am=0;$j_am<$cartikel_ohne_ek_eins;$j_am++) {
|
for($j_am=0;$j_am<$cartikel_ohne_ek_eins;$j_am++) {
|
||||||
if($j_am % 2) {
|
if($j_am % 2) {
|
||||||
$color='#e0e0e0';
|
$color='#e0e0e0';
|
||||||
@ -7222,7 +7222,7 @@ class Artikel extends GenArtikel {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
if($lvl == count($hw) -1)
|
if($lvl == (!empty($hw)?count($hw):0) -1)
|
||||||
{
|
{
|
||||||
if($found !== null)
|
if($found !== null)
|
||||||
{
|
{
|
||||||
@ -7242,7 +7242,7 @@ class Artikel extends GenArtikel {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
} elseif($lvl < count($hw) -1) {
|
} elseif($lvl < (!empty($hw)?count($hw):0) -1) {
|
||||||
|
|
||||||
$html .= $this->ArtikelgenEigenschaften($hw, $produkte, $foundnew , $lvl +1);
|
$html .= $this->ArtikelgenEigenschaften($hw, $produkte, $foundnew , $lvl +1);
|
||||||
}
|
}
|
||||||
@ -7563,11 +7563,11 @@ class Artikel extends GenArtikel {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if($canimport === 0 || $canimport === count($shops))
|
if($canimport === 0 || $canimport === (!empty($shops)?count($shops):0))
|
||||||
{
|
{
|
||||||
$return['hideallimportplaceholder'];
|
$return['hideallimportplaceholder'];
|
||||||
}
|
}
|
||||||
if($canexport === 0 || $canexport === count($shops))
|
if($canexport === 0 || $canexport === (!empty($shops)?count($shops):0))
|
||||||
{
|
{
|
||||||
$return['hideallexportplaceholder'];
|
$return['hideallexportplaceholder'];
|
||||||
}
|
}
|
||||||
@ -8039,7 +8039,7 @@ class Artikel extends GenArtikel {
|
|||||||
|
|
||||||
$articleLabelPrinter = $this->app->DB->SelectArr("SELECT id, name FROM drucker WHERE aktiv='1' AND art='2'");
|
$articleLabelPrinter = $this->app->DB->SelectArr("SELECT id, name FROM drucker WHERE aktiv='1' AND art='2'");
|
||||||
$articleLabelPrinterSelection = "";
|
$articleLabelPrinterSelection = "";
|
||||||
for($i=0;$i<count($articleLabelPrinter);$i++)
|
for($i=0;$i<(!empty($articleLabelPrinter)?count($articleLabelPrinter):0);$i++)
|
||||||
{
|
{
|
||||||
$articleLabelPrinterSelection .="<option value='".$articleLabelPrinter[$i]['id']."'>".$articleLabelPrinter[$i]['name']."</option>";
|
$articleLabelPrinterSelection .="<option value='".$articleLabelPrinter[$i]['id']."'>".$articleLabelPrinter[$i]['name']."</option>";
|
||||||
}
|
}
|
||||||
@ -8224,7 +8224,7 @@ class Artikel extends GenArtikel {
|
|||||||
{
|
{
|
||||||
if($cols[$i]!='') $colcounter++;
|
if($cols[$i]!='') $colcounter++;
|
||||||
}
|
}
|
||||||
if($colcounter<count($fields))
|
if($colcounter<(!empty($fields)?count($fields):0))
|
||||||
{
|
{
|
||||||
$findcols .= '<div class="error">Alle Spalten müssen auswählt werden</div>';
|
$findcols .= '<div class="error">Alle Spalten müssen auswählt werden</div>';
|
||||||
$importerror++;
|
$importerror++;
|
||||||
@ -8237,7 +8237,7 @@ class Artikel extends GenArtikel {
|
|||||||
$rowcounter = 1;
|
$rowcounter = 1;
|
||||||
while (($data = fgetcsv($handle, 1000, $this->app->User->GetParameter("artikel_stueckliste_delimiter"))) !== FALSE) {
|
while (($data = fgetcsv($handle, 1000, $this->app->User->GetParameter("artikel_stueckliste_delimiter"))) !== FALSE) {
|
||||||
$rowcounter++;
|
$rowcounter++;
|
||||||
$num = count($data);
|
$num = (!empty($data)?count($data):0);
|
||||||
|
|
||||||
if($rowcounter > $row_post){
|
if($rowcounter > $row_post){
|
||||||
for ($c=0; $c < $num; $c++) {
|
for ($c=0; $c < $num; $c++) {
|
||||||
@ -8297,7 +8297,7 @@ border: 1px solid #000;
|
|||||||
padding: 10px;\">
|
padding: 10px;\">
|
||||||
<table border=0 cellpadding=0 cellspacing=0>";
|
<table border=0 cellpadding=0 cellspacing=0>";
|
||||||
while (($data = fgetcsv($handle, 1000, $this->app->User->GetParameter("artikel_stueckliste_delimiter"))) !== FALSE) {
|
while (($data = fgetcsv($handle, 1000, $this->app->User->GetParameter("artikel_stueckliste_delimiter"))) !== FALSE) {
|
||||||
$num = count($data);
|
$num = (!empty($data)?count($data):0);
|
||||||
|
|
||||||
if($row==1)
|
if($row==1)
|
||||||
{
|
{
|
||||||
@ -8309,7 +8309,7 @@ padding: 10px;\">
|
|||||||
<select name=\"cols[$c]\"><option></option>";
|
<select name=\"cols[$c]\"><option></option>";
|
||||||
|
|
||||||
foreach($fields as $key=>$value){
|
foreach($fields as $key=>$value){
|
||||||
if(count($cols)==0) {
|
if((!empty($cols)?count($cols):0)==0) {
|
||||||
if($preselected[$key]==($c+1)) {
|
if($preselected[$key]==($c+1)) {
|
||||||
$selected='selected';
|
$selected='selected';
|
||||||
} else $selected='';
|
} else $selected='';
|
||||||
@ -8750,7 +8750,7 @@ padding: 10px;\">
|
|||||||
}
|
}
|
||||||
if(file_exists($cachefolder)) {
|
if(file_exists($cachefolder)) {
|
||||||
$vorschaua = explode('_',$vorschau);
|
$vorschaua = explode('_',$vorschau);
|
||||||
if(count($vorschaua) == 3) {
|
if((!empty($vorschaua)?count($vorschaua):0) == 3) {
|
||||||
$cachefolderPrev = $cachefolder;
|
$cachefolderPrev = $cachefolder;
|
||||||
$cachefolder = $this->app->erp->GetDMSPath($vorschau, $cachefolderPrev, true);
|
$cachefolder = $this->app->erp->GetDMSPath($vorschau, $cachefolderPrev, true);
|
||||||
if(is_numeric($vorschaua[0]) && is_numeric($vorschaua[1]) && is_numeric($vorschaua[2])
|
if(is_numeric($vorschaua[0]) && is_numeric($vorschaua[1]) && is_numeric($vorschaua[2])
|
||||||
|
@ -203,7 +203,7 @@ class Artikelbaum
|
|||||||
$kategorien = null;
|
$kategorien = null;
|
||||||
$this->getKategorien($kategorien, 0);
|
$this->getKategorien($kategorien, 0);
|
||||||
if($this->app->Secure->GetGET('cmd') === 'suche' && $kategorien) {
|
if($this->app->Secure->GetGET('cmd') === 'suche' && $kategorien) {
|
||||||
$kategorien[count($kategorien)-1] = [
|
$kategorien[(!empty($kategorien)?count($kategorien):0)-1] = [
|
||||||
'id' =>0,
|
'id' =>0,
|
||||||
'bezeichnung' => 'zurücksetzen',
|
'bezeichnung' => 'zurücksetzen',
|
||||||
'parent' => 0
|
'parent' => 0
|
||||||
|
@ -2153,7 +2153,7 @@ CONCAT(if(a.prio=1 OR (a.abgabe_bis <= NOW() AND a.abgabe_bis!='0000-00-00'),CON
|
|||||||
WHERE a.abgabe_bis<='$end' AND a.abgabe_bis >='$start' $subwhere ORDER by a.abgabe_bis");
|
WHERE a.abgabe_bis<='$end' AND a.abgabe_bis >='$start' $subwhere ORDER by a.abgabe_bis");
|
||||||
|
|
||||||
if($data){
|
if($data){
|
||||||
$cdata = count($data);
|
$cdata = (!empty($data)?count($data):0);
|
||||||
for ($i = 0; $i < $cdata; $i++) {
|
for ($i = 0; $i < $cdata; $i++) {
|
||||||
$data[$i]['allDay'] = 1;//(($data[$i]['allDay']=='1')?true:false);
|
$data[$i]['allDay'] = 1;//(($data[$i]['allDay']=='1')?true:false);
|
||||||
$data[$i]['public'] = 1;//(($data[$i]['public']=='1')?true:false);
|
$data[$i]['public'] = 1;//(($data[$i]['public']=='1')?true:false);
|
||||||
|
@ -1453,7 +1453,7 @@ class Auftrag extends GenAuftrag
|
|||||||
foreach($table->datasets as $dataSetKey => $dataset) {
|
foreach($table->datasets as $dataSetKey => $dataset) {
|
||||||
unset($table->datasets[$dataSetKey]['MHD-Menge']);
|
unset($table->datasets[$dataSetKey]['MHD-Menge']);
|
||||||
}
|
}
|
||||||
unset($table->headings[count($table->headings)-1]);
|
unset($table->headings[(!empty($table->headings)?count($table->headings):0)-1]);
|
||||||
} else {
|
} else {
|
||||||
$lastCol = 'MHD-Menge';
|
$lastCol = 'MHD-Menge';
|
||||||
$table->align[2] = 'right';
|
$table->align[2] = 'right';
|
||||||
@ -1496,7 +1496,7 @@ class Auftrag extends GenAuftrag
|
|||||||
foreach($table->datasets as $dataSetKey => $dataset) {
|
foreach($table->datasets as $dataSetKey => $dataset) {
|
||||||
unset($table->datasets[$dataSetKey]['Chargen-Menge']);
|
unset($table->datasets[$dataSetKey]['Chargen-Menge']);
|
||||||
}
|
}
|
||||||
unset($table->headings[count($table->headings)-1]);
|
unset($table->headings[(!empty($table->headings)?count($table->headings):0)-1]);
|
||||||
} else {
|
} else {
|
||||||
$lastCol = 'Chargen-Menge';
|
$lastCol = 'Chargen-Menge';
|
||||||
$table->align[2] = 'right';
|
$table->align[2] = 'right';
|
||||||
@ -1727,10 +1727,10 @@ class Auftrag extends GenAuftrag
|
|||||||
);
|
);
|
||||||
|
|
||||||
if(!empty($angebot)) {
|
if(!empty($angebot)) {
|
||||||
$cangebot = count($angebot);
|
$cangebot = (!empty($angebot)?count($angebot):0);
|
||||||
for($li=0;$li<$cangebot;$li++) {
|
for($li=0;$li<$cangebot;$li++) {
|
||||||
$this->app->Tpl->Add('ANGEBOT',$angebot[$li]['angebot']);
|
$this->app->Tpl->Add('ANGEBOT',$angebot[$li]['angebot']);
|
||||||
if($li<count($angebot)){
|
if($li<(!empty($angebot)?count($angebot):0)){
|
||||||
$this->app->Tpl->Add('ANGEBOT', "<br>");
|
$this->app->Tpl->Add('ANGEBOT', "<br>");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -2675,7 +2675,7 @@ class Auftrag extends GenAuftrag
|
|||||||
}
|
}
|
||||||
if($lastcolumn == $_lastcolumn)
|
if($lastcolumn == $_lastcolumn)
|
||||||
{
|
{
|
||||||
unset($table->headings[count($table->headings)-1]);
|
unset($table->headings[(!empty($table->headings)?count($table->headings):0)-1]);
|
||||||
}else {
|
}else {
|
||||||
$cheading = !empty($table->headings)?count($table->headings):0;
|
$cheading = !empty($table->headings)?count($table->headings):0;
|
||||||
for($hc = 0; $hc < $cheading; $hc++)
|
for($hc = 0; $hc < $cheading; $hc++)
|
||||||
@ -2699,9 +2699,9 @@ class Auftrag extends GenAuftrag
|
|||||||
|
|
||||||
if($lastcolumn == $_lastcolumn)
|
if($lastcolumn == $_lastcolumn)
|
||||||
{
|
{
|
||||||
$lastcolumn = $table->headings[count($table->headings)-1];
|
$lastcolumn = $table->headings[(!empty($table->headings)?count($table->headings):0)-1];
|
||||||
if($lastcolumn == 'Aktion'){
|
if($lastcolumn == 'Aktion'){
|
||||||
$lastcolumn = $table->headings[count($table->headings)-2];
|
$lastcolumn = $table->headings[(!empty($table->headings)?count($table->headings):0)-2];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -4126,9 +4126,9 @@ class Auftrag extends GenAuftrag
|
|||||||
|
|
||||||
$unterartikel = $this->app->DB->SelectArr("SELECT * FROM auftrag_position WHERE explodiert_parent='$sid' ORDER BY sort");
|
$unterartikel = $this->app->DB->SelectArr("SELECT * FROM auftrag_position WHERE explodiert_parent='$sid' ORDER BY sort");
|
||||||
|
|
||||||
if($unterartikel && count($unterartikel)>0 && $sid >0 && $id >0)
|
if($unterartikel && (!empty($unterartikel)?count($unterartikel):0)>0 && $sid >0 && $id >0)
|
||||||
{
|
{
|
||||||
$cunterartikel = count($unterartikel);
|
$cunterartikel = (!empty($unterartikel)?count($unterartikel):0);
|
||||||
for($i=0;$i<$cunterartikel;$i++)
|
for($i=0;$i<$cunterartikel;$i++)
|
||||||
{
|
{
|
||||||
$sidexplodiert = $unterartikel[$i]['id'];
|
$sidexplodiert = $unterartikel[$i]['id'];
|
||||||
@ -4405,7 +4405,7 @@ class Auftrag extends GenAuftrag
|
|||||||
)
|
)
|
||||||
);
|
);
|
||||||
if(!empty($anzahlteillieferungen)) {
|
if(!empty($anzahlteillieferungen)) {
|
||||||
$canzahlteillieferungen = count($anzahlteillieferungen);
|
$canzahlteillieferungen = (!empty($anzahlteillieferungen)?count($anzahlteillieferungen):0);
|
||||||
for($ati=0;$ati<$canzahlteillieferungen;$ati++) {
|
for($ati=0;$ati<$canzahlteillieferungen;$ati++) {
|
||||||
if($canzahlteillieferungen[$ati]['teillieferungnummer'] + 1 > $teillieferungnummermax) {
|
if($canzahlteillieferungen[$ati]['teillieferungnummer'] + 1 > $teillieferungnummermax) {
|
||||||
$teillieferungnummermax = $canzahlteillieferungen[$ati]['teillieferungnummer'] + 1;
|
$teillieferungnummermax = $canzahlteillieferungen[$ati]['teillieferungnummer'] + 1;
|
||||||
@ -4449,8 +4449,8 @@ class Auftrag extends GenAuftrag
|
|||||||
$this->app->Tpl->Add(
|
$this->app->Tpl->Add(
|
||||||
'MESSAGE',
|
'MESSAGE',
|
||||||
"<div class=\"info\">Zu diesem Auftrag gehör"
|
"<div class=\"info\">Zu diesem Auftrag gehör"
|
||||||
.(count($check) == 1?'t':'en')
|
.((!empty($check)?count($check):0) == 1?'t':'en')
|
||||||
." die Bestellung".(count($check) == 1?':':'en:')
|
." die Bestellung".((!empty($check)?count($check):0) == 1?':':'en:')
|
||||||
);
|
);
|
||||||
foreach($check as $supplierOrderId => $supplieryNumber) {
|
foreach($check as $supplierOrderId => $supplieryNumber) {
|
||||||
$this->app->Tpl->Add('MESSAGE',' <a href="index.php?module=bestellung&action=edit&id='
|
$this->app->Tpl->Add('MESSAGE',' <a href="index.php?module=bestellung&action=edit&id='
|
||||||
@ -5589,7 +5589,7 @@ Die Gesamtsumme stimmt nicht mehr mit ursprünglich festgelegten Betrag '.
|
|||||||
{
|
{
|
||||||
// alle anhaenge drucken! wo auftrag datei anhang
|
// alle anhaenge drucken! wo auftrag datei anhang
|
||||||
$this->app->erp->GetDateiSubjektObjekt('anhang','Auftrag',$id);
|
$this->app->erp->GetDateiSubjektObjekt('anhang','Auftrag',$id);
|
||||||
// for($i=0;$i<count($tmpanhang);$i++)
|
// for($i=0;$i<(!empty($tmpanhang)?count($tmpanhang):0);$i++)
|
||||||
// $this->app->printer->Drucken($druckercode,$tmpanhang[$i]);
|
// $this->app->printer->Drucken($druckercode,$tmpanhang[$i]);
|
||||||
$tmpanhang ='';
|
$tmpanhang ='';
|
||||||
}
|
}
|
||||||
@ -6070,7 +6070,7 @@ Die Gesamtsumme stimmt nicht mehr mit ursprünglich festgelegten Betrag '.
|
|||||||
$entfernen = $this->app->Secure->GetPOST('entfernen');
|
$entfernen = $this->app->Secure->GetPOST('entfernen');
|
||||||
$bezeichnung = (string)$this->app->Secure->GetPOST('bezeichnung');
|
$bezeichnung = (string)$this->app->Secure->GetPOST('bezeichnung');
|
||||||
if($entfernen && $auftraegemarkiert){
|
if($entfernen && $auftraegemarkiert){
|
||||||
$cauftraegemarkiert = count($auftraegemarkiert);
|
$cauftraegemarkiert = (!empty($auftraegemarkiert)?count($auftraegemarkiert):0);
|
||||||
for($i=0;$i<$cauftraegemarkiert;$i++) {
|
for($i=0;$i<$cauftraegemarkiert;$i++) {
|
||||||
$this->app->DB->Update("UPDATE auftrag SET cronjobkommissionierung = 0 WHERE id = '".$auftraegemarkiert[$i]."' LIMIT 1");
|
$this->app->DB->Update("UPDATE auftrag SET cronjobkommissionierung = 0 WHERE id = '".$auftraegemarkiert[$i]."' LIMIT 1");
|
||||||
}
|
}
|
||||||
@ -6602,7 +6602,7 @@ Die Gesamtsumme stimmt nicht mehr mit ursprünglich festgelegten Betrag '.
|
|||||||
//$Brief->ArchiviereDocument();
|
//$Brief->ArchiviereDocument();
|
||||||
}
|
}
|
||||||
|
|
||||||
if(count($tmpfile) > 0){
|
if((!empty($tmpfile)?count($tmpfile):0) > 0){
|
||||||
try {
|
try {
|
||||||
/** @var \Xentral\Components\Pdf\PdfMerger $pdfMerger */
|
/** @var \Xentral\Components\Pdf\PdfMerger $pdfMerger */
|
||||||
$pdfMerger = $this->app->Container->get('PdfMerger');
|
$pdfMerger = $this->app->Container->get('PdfMerger');
|
||||||
|
@ -817,12 +817,12 @@ class Benutzer
|
|||||||
$modules = $this->ScanModules();
|
$modules = $this->ScanModules();
|
||||||
if($hwtoken == 4)
|
if($hwtoken == 4)
|
||||||
{
|
{
|
||||||
$modulecount = count($modules);
|
$modulecount = (!empty($modules)?count($modules):0);
|
||||||
$curModule = 0;
|
$curModule = 0;
|
||||||
foreach($modules as $module=>$actions) {
|
foreach($modules as $module=>$actions) {
|
||||||
$lower_m = strtolower($module);
|
$lower_m = strtolower($module);
|
||||||
$curModule++;
|
$curModule++;
|
||||||
$actioncount = count($actions);
|
$actioncount = (!empty($actions)?count($actions):0);
|
||||||
for($i=0;$i<$actioncount;$i++) {
|
for($i=0;$i<$actioncount;$i++) {
|
||||||
$delimiter = (($curModule<$modulecount || $i+1<$actioncount) ? ', ' : ';');
|
$delimiter = (($curModule<$modulecount || $i+1<$actioncount) ? ', ' : ';');
|
||||||
$active = 0;
|
$active = 0;
|
||||||
@ -844,12 +844,12 @@ class Benutzer
|
|||||||
}
|
}
|
||||||
//$sql = 'INSERT INTO userrights (user, module, action, permission) VALUES ';
|
//$sql = 'INSERT INTO userrights (user, module, action, permission) VALUES ';
|
||||||
|
|
||||||
$modulecount = count($modules);
|
$modulecount = (!empty($modules)?count($modules):0);
|
||||||
$curModule = 0;
|
$curModule = 0;
|
||||||
foreach($modules as $module=>$actions) {
|
foreach($modules as $module=>$actions) {
|
||||||
$lower_m = strtolower($module);
|
$lower_m = strtolower($module);
|
||||||
$curModule++;
|
$curModule++;
|
||||||
$actioncount = count($actions);
|
$actioncount = (!empty($actions)?count($actions):0);
|
||||||
for($i=0;$i<$actioncount;$i++) {
|
for($i=0;$i<$actioncount;$i++) {
|
||||||
$delimiter = (($curModule<$modulecount || $i+1<$actioncount) ? ', ' : ';');
|
$delimiter = (($curModule<$modulecount || $i+1<$actioncount) ? ', ' : ';');
|
||||||
$active = ((isset($mytemplate[$lower_m]) && in_array($actions[$i], $mytemplate[$lower_m])) ? '1' : '0');
|
$active = ((isset($mytemplate[$lower_m]) && in_array($actions[$i], $mytemplate[$lower_m])) ? '1' : '0');
|
||||||
@ -885,7 +885,7 @@ class Benutzer
|
|||||||
$group = $this->app->DB->Select("SELECT `type` FROM `user` WHERE id='$id' LIMIT 1");
|
$group = $this->app->DB->Select("SELECT `type` FROM `user` WHERE id='$id' LIMIT 1");
|
||||||
|
|
||||||
$rights = $this->app->Conf->WFconf['permissions'][$group];
|
$rights = $this->app->Conf->WFconf['permissions'][$group];
|
||||||
if(is_array($dbrights) && count($dbrights)>0)
|
if(is_array($dbrights) && (!empty($dbrights)?count($dbrights):0)>0)
|
||||||
$rights = $this->AdaptRights($dbrights, $rights, $group);
|
$rights = $this->AdaptRights($dbrights, $rights, $group);
|
||||||
|
|
||||||
$modules = $this->ScanModules();
|
$modules = $this->ScanModules();
|
||||||
@ -975,7 +975,7 @@ class Benutzer
|
|||||||
|
|
||||||
function AdaptRights($dbarr, $rights)
|
function AdaptRights($dbarr, $rights)
|
||||||
{
|
{
|
||||||
$cnt = count($dbarr);
|
$cnt = (!empty($dbarr)?count($dbarr):0);
|
||||||
for($i=0;$i<$cnt;$i++) {
|
for($i=0;$i<$cnt;$i++) {
|
||||||
$module = $dbarr[$i]['module'];
|
$module = $dbarr[$i]['module'];
|
||||||
$action = $dbarr[$i]['action'];
|
$action = $dbarr[$i]['action'];
|
||||||
@ -1006,7 +1006,7 @@ class Benutzer
|
|||||||
|
|
||||||
$out .= "<tr><td><table class=\"action\">";
|
$out .= "<tr><td><table class=\"action\">";
|
||||||
$module = strtolower($key);
|
$module = strtolower($key);
|
||||||
for($i=0;$i<$maxcols || $i<count($value);$i++) {
|
for($i=0;$i<$maxcols || $i<(!empty($value)?count($value):0);$i++) {
|
||||||
if($i%$maxcols==0) $out .= "<tr>";
|
if($i%$maxcols==0) $out .= "<tr>";
|
||||||
|
|
||||||
if (gettype($rights[$module]) == 'array') {
|
if (gettype($rights[$module]) == 'array') {
|
||||||
|
@ -493,12 +493,12 @@ class Berichte extends GenBerichte {
|
|||||||
$csv = '';
|
$csv = '';
|
||||||
//spaltennamen
|
//spaltennamen
|
||||||
$countcolumns = 0;
|
$countcolumns = 0;
|
||||||
if(count($header) > count($w)) {
|
if((!empty($header)?count($header):0) > (!empty($w)?count($w):0)) {
|
||||||
$countcolumns = count($header);
|
$countcolumns = (!empty($header)?count($header):0);
|
||||||
} else {
|
} else {
|
||||||
$countcolumns = count($w);
|
$countcolumns = (!empty($w)?count($w):0);
|
||||||
}
|
}
|
||||||
$cheader = count($header);
|
$cheader = (!empty($header)?count($header):0);
|
||||||
for($i=0;$i<$cheader;$i++)
|
for($i=0;$i<$cheader;$i++)
|
||||||
{
|
{
|
||||||
if(!isset($header[$i])) {
|
if(!isset($header[$i])) {
|
||||||
@ -619,7 +619,7 @@ class Berichte extends GenBerichte {
|
|||||||
$header = explode(';',$spaltennamen);
|
$header = explode(';',$spaltennamen);
|
||||||
|
|
||||||
$ausrichtung = explode(';',$spaltenausrichtung);
|
$ausrichtung = explode(';',$spaltenausrichtung);
|
||||||
$cw = count($w);
|
$cw = (!empty($w)?count($w):0);
|
||||||
for($i=0;$i<$cw;$i++) {
|
for($i=0;$i<$cw;$i++) {
|
||||||
$pdf->Cell(intval($w[$i],10), 7, intval($header[$i]), 1, 0, intval($ausrichtung[$i],10), true);
|
$pdf->Cell(intval($w[$i],10), 7, intval($header[$i]), 1, 0, intval($ausrichtung[$i],10), true);
|
||||||
}
|
}
|
||||||
|
@ -221,7 +221,7 @@ class Bestellung extends GenBestellung
|
|||||||
$alleLagerArtikelVonBestellung = $this->app->DB->SelectArr($sql);
|
$alleLagerArtikelVonBestellung = $this->app->DB->SelectArr($sql);
|
||||||
|
|
||||||
//nur wenn auch Lagerartikel enthalten sind, soll automatisch abgeschlossen werden können.
|
//nur wenn auch Lagerartikel enthalten sind, soll automatisch abgeschlossen werden können.
|
||||||
if(count($alleLagerArtikelVonBestellung)>0){
|
if((!empty($alleLagerArtikelVonBestellung)?count($alleLagerArtikelVonBestellung):0)>0){
|
||||||
$lagerArtikelIds = [];
|
$lagerArtikelIds = [];
|
||||||
foreach ($alleLagerArtikelVonBestellung as $l){
|
foreach ($alleLagerArtikelVonBestellung as $l){
|
||||||
$lagerArtikelIds[] = $l['id'];
|
$lagerArtikelIds[] = $l['id'];
|
||||||
@ -1482,7 +1482,7 @@ class Bestellung extends GenBestellung
|
|||||||
WHERE bp.bestellung='$id' GROUP BY a.belegnr, a.id ORDER BY a.belegnr, a.id");
|
WHERE bp.bestellung='$id' GROUP BY a.belegnr, a.id ORDER BY a.belegnr, a.id");
|
||||||
if($check)
|
if($check)
|
||||||
{
|
{
|
||||||
$this->app->Tpl->Add('MESSAGE',"<div class=\"info\">Zu dieser Bestellung gehör".(count($check) == 1?'t der Auftrag':'en die Aufträge:'));
|
$this->app->Tpl->Add('MESSAGE',"<div class=\"info\">Zu dieser Bestellung gehör".((!empty($check)?count($check):0) == 1?'t der Auftrag':'en die Aufträge:'));
|
||||||
foreach($check as $row)
|
foreach($check as $row)
|
||||||
{
|
{
|
||||||
$this->app->Tpl->Add('MESSAGE',' <a href="index.php?module=auftrag&action=edit&id='.$row['id'].'" target="_blank"><input type="button" value="'.($row['belegnr']?$row['belegnr']:'Entwurf')." (".$row['name'].')" /></a>');
|
$this->app->Tpl->Add('MESSAGE',' <a href="index.php?module=auftrag&action=edit&id='.$row['id'].'" target="_blank"><input type="button" value="'.($row['belegnr']?$row['belegnr']:'Entwurf')." (".$row['name'].')" /></a>');
|
||||||
@ -1965,7 +1965,7 @@ class Bestellung extends GenBestellung
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(count($tmpfile) > 0){
|
if((!empty($tmpfile)?count($tmpfile):0) > 0){
|
||||||
try {
|
try {
|
||||||
/** @var PdfMerger $pdfMerger */
|
/** @var PdfMerger $pdfMerger */
|
||||||
$pdfMerger = $this->app->Container->get('PdfMerger');
|
$pdfMerger = $this->app->Container->get('PdfMerger');
|
||||||
|
@ -236,7 +236,7 @@ class Bundesstaaten {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$anzahlfehlen = count($fehlende) + count($fehlenat) + count($fehlench) + count($fehlenus) + count($fehlenca);
|
$anzahlfehlen = (!empty($fehlende)?count($fehlende):0) + (!empty($fehlenat)?count($fehlenat):0) + (!empty($fehlench)?count($fehlench):0) + (!empty($fehlenus)?count($fehlenus):0) + (!empty($fehlenca)?count($fehlenca):0);
|
||||||
|
|
||||||
|
|
||||||
if($anzahlfehlen > 0){
|
if($anzahlfehlen > 0){
|
||||||
@ -252,31 +252,31 @@ class Bundesstaaten {
|
|||||||
|
|
||||||
$nachladen = $this->app->Secure->GetPOST("nachladen");
|
$nachladen = $this->app->Secure->GetPOST("nachladen");
|
||||||
if($nachladen != ""){
|
if($nachladen != ""){
|
||||||
if(count($fehlende) > 0){
|
if((!empty($fehlende)?count($fehlende):0) > 0){
|
||||||
foreach($fehlende as $key=>$value){
|
foreach($fehlende as $key=>$value){
|
||||||
$this->app->DB->Insert("INSERT INTO bundesstaaten (land, iso, bundesstaat, aktiv) VALUES ('DE', '$key', '$value', 1)");
|
$this->app->DB->Insert("INSERT INTO bundesstaaten (land, iso, bundesstaat, aktiv) VALUES ('DE', '$key', '$value', 1)");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(count($fehlenat) > 0){
|
if((!empty($fehlenat)?count($fehlenat):0) > 0){
|
||||||
foreach($fehlenat as $key=>$value){
|
foreach($fehlenat as $key=>$value){
|
||||||
$this->app->DB->Insert("INSERT INTO bundesstaaten (land, iso, bundesstaat, aktiv) VALUES ('AT', '$key', '$value', 1)");
|
$this->app->DB->Insert("INSERT INTO bundesstaaten (land, iso, bundesstaat, aktiv) VALUES ('AT', '$key', '$value', 1)");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(count($fehlench) > 0){
|
if((!empty($fehlench)?count($fehlench):0) > 0){
|
||||||
foreach($fehlench as $key=>$value){
|
foreach($fehlench as $key=>$value){
|
||||||
$this->app->DB->Insert("INSERT INTO bundesstaaten (land, iso, bundesstaat, aktiv) VALUES ('CH', '$key', '$value', 1)");
|
$this->app->DB->Insert("INSERT INTO bundesstaaten (land, iso, bundesstaat, aktiv) VALUES ('CH', '$key', '$value', 1)");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(count($fehlenus) > 0){
|
if((!empty($fehlenus)?count($fehlenus):0) > 0){
|
||||||
foreach($fehlenus as $key=>$value){
|
foreach($fehlenus as $key=>$value){
|
||||||
$this->app->DB->Insert("INSERT INTO bundesstaaten (land, iso, bundesstaat, aktiv) VALUES ('US', '$key', '$value', 1)");
|
$this->app->DB->Insert("INSERT INTO bundesstaaten (land, iso, bundesstaat, aktiv) VALUES ('US', '$key', '$value', 1)");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(count($fehlenca) > 0){
|
if((!empty($fehlenca)?count($fehlenca):0) > 0){
|
||||||
foreach($fehlenca as $key=>$value){
|
foreach($fehlenca as $key=>$value){
|
||||||
$this->app->DB->Insert("INSERT INTO bundesstaaten (land, iso, bundesstaat, aktiv) VALUES ('CA', '$key', '$value', 1)");
|
$this->app->DB->Insert("INSERT INTO bundesstaaten (land, iso, bundesstaat, aktiv) VALUES ('CA', '$key', '$value', 1)");
|
||||||
}
|
}
|
||||||
|
@ -368,7 +368,7 @@ class Chat {
|
|||||||
$numOfUrlsToReplace = 0;
|
$numOfUrlsToReplace = 0;
|
||||||
for($i=0; $i<$numOfMatches; $i++) {
|
for($i=0; $i<$numOfMatches; $i++) {
|
||||||
$alreadyAdded = false;
|
$alreadyAdded = false;
|
||||||
$numOfUrlsToReplace = count($urlsToReplace);
|
$numOfUrlsToReplace = (!empty($urlsToReplace)?count($urlsToReplace):0);
|
||||||
for($j=0; $j<$numOfUrlsToReplace; $j++) {
|
for($j=0; $j<$numOfUrlsToReplace; $j++) {
|
||||||
if($urlsToReplace[$j] == $urls[0][$i]) {
|
if($urlsToReplace[$j] == $urls[0][$i]) {
|
||||||
$alreadyAdded = true;
|
$alreadyAdded = true;
|
||||||
@ -378,7 +378,7 @@ class Chat {
|
|||||||
array_push($urlsToReplace, $urls[0][$i]);
|
array_push($urlsToReplace, $urls[0][$i]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$numOfUrlsToReplace = count($urlsToReplace);
|
$numOfUrlsToReplace = (!empty($urlsToReplace)?count($urlsToReplace):0);
|
||||||
for($i=0; $i<$numOfUrlsToReplace; $i++) {
|
for($i=0; $i<$numOfUrlsToReplace; $i++) {
|
||||||
$str = str_replace($urlsToReplace[$i], "<a href=\"".$urlsToReplace[$i]."\" target=\"_blank\">".$urlsToReplace[$i]."</a> ", $str);
|
$str = str_replace($urlsToReplace[$i], "<a href=\"".$urlsToReplace[$i]."\" target=\"_blank\">".$urlsToReplace[$i]."</a> ", $str);
|
||||||
}
|
}
|
||||||
|
@ -108,7 +108,7 @@ class Databaseviewer {
|
|||||||
'SHOW COLUMNS FROM `%s` ', $tableName), 60, 'xcs_column'
|
'SHOW COLUMNS FROM `%s` ', $tableName), 60, 'xcs_column'
|
||||||
);
|
);
|
||||||
$html = '';
|
$html = '';
|
||||||
if(count($tableColumns) > 75) {
|
if((!empty($tableColumns)?count($tableColumns):0) > 75) {
|
||||||
$html = '<div class="warning">Die Tabellenansicht wurde auf 75 Spalten gekürzt</div>';
|
$html = '<div class="warning">Die Tabellenansicht wurde auf 75 Spalten gekürzt</div>';
|
||||||
}
|
}
|
||||||
$this->app->YUI->TableSearch('PAGE', 'database_table_view', 'show', '', '', basename(__FILE__), __CLASS__);
|
$this->app->YUI->TableSearch('PAGE', 'database_table_view', 'show', '', '', basename(__FILE__), __CLASS__);
|
||||||
|
@ -332,10 +332,10 @@ class Dsgvo{
|
|||||||
if($adresse['mitarbeiternummer']!="")
|
if($adresse['mitarbeiternummer']!="")
|
||||||
$numbers[] = array("Mitarbeiter Nr.",$adresse['mitarbeiternummer']);
|
$numbers[] = array("Mitarbeiter Nr.",$adresse['mitarbeiternummer']);
|
||||||
|
|
||||||
if(count($numbers)>0){
|
if((!empty($numbers)?count($numbers):0)>0){
|
||||||
//$pdf->renderInfoBox($numbers);
|
//$pdf->renderInfoBox($numbers);
|
||||||
$height = 5;
|
$height = 5;
|
||||||
for($i=0;$i<count($numbers);$i++)
|
for($i=0;$i<(!empty($numbers)?count($numbers):0);$i++)
|
||||||
{
|
{
|
||||||
$pdf->MultiCell(50,$height,$this->app->erp->ReadyForPDF($numbers[$i][0]).":","BTL",'L');
|
$pdf->MultiCell(50,$height,$this->app->erp->ReadyForPDF($numbers[$i][0]).":","BTL",'L');
|
||||||
$pdf->SetY($pdf->GetY()-$height); $pdf->SetX(50); $pdf->MultiCell(140,$height,$this->app->erp->ReadyForPDF($numbers[$i][1]),"BTR",'L');
|
$pdf->SetY($pdf->GetY()-$height); $pdf->SetX(50); $pdf->MultiCell(140,$height,$this->app->erp->ReadyForPDF($numbers[$i][1]),"BTR",'L');
|
||||||
@ -358,7 +358,7 @@ class Dsgvo{
|
|||||||
|
|
||||||
//$pdf->renderInfoBox($infofields);
|
//$pdf->renderInfoBox($infofields);
|
||||||
$height = 5;
|
$height = 5;
|
||||||
for($i=0;$i<count($infofields);$i++)
|
for($i=0;$i<(!empty($infofields)?count($infofields):0);$i++)
|
||||||
{
|
{
|
||||||
$pdf->MultiCell(50,$height,$this->app->erp->ReadyForPDF($infofields[$i][0]).":","BTL",'L');
|
$pdf->MultiCell(50,$height,$this->app->erp->ReadyForPDF($infofields[$i][0]).":","BTL",'L');
|
||||||
$pdf->SetY($pdf->GetY()-$height); $pdf->SetX(50); $pdf->MultiCell(140,$height,$this->app->erp->ReadyForPDF($infofields[$i][1]),"BTR",'L');
|
$pdf->SetY($pdf->GetY()-$height); $pdf->SetX(50); $pdf->MultiCell(140,$height,$this->app->erp->ReadyForPDF($infofields[$i][1]),"BTR",'L');
|
||||||
@ -367,8 +367,8 @@ class Dsgvo{
|
|||||||
|
|
||||||
$accounts_tmp = $this->app->DB->SelectArr("SELECT CONCAT('Bezeichnung: ', bezeichnung, ', ', 'Art: ', art, ', URL: ', url, ', Benutzername: ', benutzername) as 'value' FROM adresse_accounts WHERE adresse='".$adresse['id']."'");
|
$accounts_tmp = $this->app->DB->SelectArr("SELECT CONCAT('Bezeichnung: ', bezeichnung, ', ', 'Art: ', art, ', URL: ', url, ', Benutzername: ', benutzername) as 'value' FROM adresse_accounts WHERE adresse='".$adresse['id']."'");
|
||||||
|
|
||||||
for($i=0;$i<count($accounts_tmp);$i++) $accounts[] = $accounts_tmp[$i]['value'];
|
for($i=0;$i<(!empty($accounts_tmp)?count($accounts_tmp):0);$i++) $accounts[] = $accounts_tmp[$i]['value'];
|
||||||
if(count($accounts) > 0){
|
if((!empty($accounts)?count($accounts):0) > 0){
|
||||||
$pdf->Ln(5);
|
$pdf->Ln(5);
|
||||||
$height = 8;
|
$height = 8;
|
||||||
$betreffszeile = $this->app->erp->Firmendaten('betreffszeile');
|
$betreffszeile = $this->app->erp->Firmendaten('betreffszeile');
|
||||||
@ -382,7 +382,7 @@ class Dsgvo{
|
|||||||
$height = 5;
|
$height = 5;
|
||||||
if(is_array($accounts))
|
if(is_array($accounts))
|
||||||
{
|
{
|
||||||
for($i=0;$i<count($accounts);$i++)
|
for($i=0;$i<(!empty($accounts)?count($accounts):0);$i++)
|
||||||
{
|
{
|
||||||
$pdf->MultiCell(175,$height,$pdf->WriteHTML($this->app->erp->ReadyForPDF($accounts[$i])),"",'L');
|
$pdf->MultiCell(175,$height,$pdf->WriteHTML($this->app->erp->ReadyForPDF($accounts[$i])),"",'L');
|
||||||
}
|
}
|
||||||
@ -409,8 +409,8 @@ class Dsgvo{
|
|||||||
', E-Mail: ',email
|
', E-Mail: ',email
|
||||||
) as 'value' FROM ansprechpartner WHERE adresse='".$adresse['id']."'");
|
) as 'value' FROM ansprechpartner WHERE adresse='".$adresse['id']."'");
|
||||||
|
|
||||||
for($i=0;$i<count($ansprechpartner_tmp);$i++) $ansprechpartner[] = $ansprechpartner_tmp[$i]['value'];
|
for($i=0;$i<(!empty($ansprechpartner_tmp)?count($ansprechpartner_tmp):0);$i++) $ansprechpartner[] = $ansprechpartner_tmp[$i]['value'];
|
||||||
if(count($ansprechpartner) > 0)
|
if((!empty($ansprechpartner)?count($ansprechpartner):0) > 0)
|
||||||
{
|
{
|
||||||
$pdf->Ln(5);
|
$pdf->Ln(5);
|
||||||
//$pdf->renderHeading("Ansprechpartner",8);
|
//$pdf->renderHeading("Ansprechpartner",8);
|
||||||
@ -427,7 +427,7 @@ class Dsgvo{
|
|||||||
$height = 5;
|
$height = 5;
|
||||||
if(is_array($ansprechpartner))
|
if(is_array($ansprechpartner))
|
||||||
{
|
{
|
||||||
for($i=0;$i<count($ansprechpartner);$i++)
|
for($i=0;$i<(!empty($ansprechpartner)?count($ansprechpartner):0);$i++)
|
||||||
{
|
{
|
||||||
$pdf->MultiCell(175,$height,$pdf->WriteHTML($this->app->erp->ReadyForPDF($ansprechpartner[$i])),"",'L');
|
$pdf->MultiCell(175,$height,$pdf->WriteHTML($this->app->erp->ReadyForPDF($ansprechpartner[$i])),"",'L');
|
||||||
}
|
}
|
||||||
@ -441,7 +441,7 @@ class Dsgvo{
|
|||||||
telefon,email
|
telefon,email
|
||||||
FROM lieferadressen WHERE adresse='".$adresse['id']."' ORDER by standardlieferadresse DESC");
|
FROM lieferadressen WHERE adresse='".$adresse['id']."' ORDER by standardlieferadresse DESC");
|
||||||
|
|
||||||
for($i=0;$i<count($lieferadressen_tmp);$i++) {
|
for($i=0;$i<(!empty($lieferadressen_tmp)?count($lieferadressen_tmp):0);$i++) {
|
||||||
$lieferadressen_tmp[$i]['value']="";
|
$lieferadressen_tmp[$i]['value']="";
|
||||||
foreach($lieferadressen_tmp[$i] as $key=>$value)
|
foreach($lieferadressen_tmp[$i] as $key=>$value)
|
||||||
{
|
{
|
||||||
@ -470,7 +470,7 @@ class Dsgvo{
|
|||||||
$lieferadressen[] = $lieferadressen_tmp[$i]['value'].$standard;
|
$lieferadressen[] = $lieferadressen_tmp[$i]['value'].$standard;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(count($lieferadressen) > 0)
|
if((!empty($lieferadressen)?count($lieferadressen):0) > 0)
|
||||||
{
|
{
|
||||||
$pdf->Ln(5);
|
$pdf->Ln(5);
|
||||||
//$pdf->renderHeading("Lieferadressen",8);
|
//$pdf->renderHeading("Lieferadressen",8);
|
||||||
@ -486,7 +486,7 @@ class Dsgvo{
|
|||||||
$height = 8;
|
$height = 8;
|
||||||
if(is_array($lieferadressen))
|
if(is_array($lieferadressen))
|
||||||
{
|
{
|
||||||
for($i=0;$i<count($lieferadressen);$i++)
|
for($i=0;$i<(!empty($lieferadressen)?count($lieferadressen):0);$i++)
|
||||||
{
|
{
|
||||||
$pdf->MultiCell(175,$height,$pdf->WriteHTML($this->app->erp->ReadyForPDF($lieferadressen[$i])),"",'L');
|
$pdf->MultiCell(175,$height,$pdf->WriteHTML($this->app->erp->ReadyForPDF($lieferadressen[$i])),"",'L');
|
||||||
}
|
}
|
||||||
|
@ -173,7 +173,7 @@ class Etiketten extends GenEtiketten {
|
|||||||
);
|
);
|
||||||
if(!empty($checkserriennummer)){
|
if(!empty($checkserriennummer)){
|
||||||
foreach($checkserriennummer as $checkSeriennummerRow) {
|
foreach($checkserriennummer as $checkSeriennummerRow) {
|
||||||
//for ($ics = 0; $ics < count($checkserriennummer); $ics++) {
|
//for ($ics = 0; $ics < (!empty($checkserriennummer)?count($checkserriennummer):0); $ics++) {
|
||||||
$tmp['name_de'] = $row['bezeichnung'];
|
$tmp['name_de'] = $row['bezeichnung'];
|
||||||
$tmp['nummer'] = $row['nummer'];
|
$tmp['nummer'] = $row['nummer'];
|
||||||
unset($tmp['bezeichnung']);
|
unset($tmp['bezeichnung']);
|
||||||
|
@ -134,7 +134,7 @@ class Exportvorlage extends GenExportvorlage {
|
|||||||
$fields = str_replace(';;',';',$fields);
|
$fields = str_replace(';;',';',$fields);
|
||||||
|
|
||||||
$fieldsarray = explode(';',$fields);
|
$fieldsarray = explode(';',$fields);
|
||||||
for($i=0;$i<count($fieldsarray);$i++)
|
for($i=0;$i<(!empty($fieldsarray)?count($fieldsarray):0);$i++)
|
||||||
{
|
{
|
||||||
$fieldsarray_items = explode(':',$fieldsarray[$i]);
|
$fieldsarray_items = explode(':',$fieldsarray[$i]);
|
||||||
foreach($fieldsarray_items as $k => $v)$fieldsarray_items[$k] = trim($v);
|
foreach($fieldsarray_items as $k => $v)$fieldsarray_items[$k] = trim($v);
|
||||||
@ -244,7 +244,7 @@ ean;';
|
|||||||
$join = implode( ' ', $joins);
|
$join = implode( ' ', $joins);
|
||||||
$subwhere = '';
|
$subwhere = '';
|
||||||
$this->app->erp->RunHook('exportvorlage_export',4,$ziel,$fields_array, $join, $subwhere);
|
$this->app->erp->RunHook('exportvorlage_export',4,$ziel,$fields_array, $join, $subwhere);
|
||||||
//for($i=0;$i<count($fieldsarray);$i++)
|
//for($i=0;$i<(!empty($fieldsarray)?count($fieldsarray):0);$i++)
|
||||||
|
|
||||||
|
|
||||||
$sql_fields = implode(',',$fields_array);
|
$sql_fields = implode(',',$fields_array);
|
||||||
@ -370,7 +370,7 @@ ean;';
|
|||||||
|
|
||||||
$sql .= ' '.$join. ' ';
|
$sql .= ' '.$join. ' ';
|
||||||
|
|
||||||
if(count($fields_array_where) > 0 && trim($sql_fields_where)!=''){
|
if((!empty($fields_array_where)?count($fields_array_where):0) > 0 && trim($sql_fields_where)!=''){
|
||||||
$sql .= ' WHERE ' . trim($sql_fields_where).' '.$subwhere ;
|
$sql .= ' WHERE ' . trim($sql_fields_where).' '.$subwhere ;
|
||||||
} elseif(!empty($subwhere)) {
|
} elseif(!empty($subwhere)) {
|
||||||
$sql .= ' WHERE '.$subwhere;
|
$sql .= ' WHERE '.$subwhere;
|
||||||
@ -1391,7 +1391,7 @@ ean;';
|
|||||||
|
|
||||||
function ExportPrepareHeader($ziel,$csv_fields_keys,$csv_fields)
|
function ExportPrepareHeader($ziel,$csv_fields_keys,$csv_fields)
|
||||||
{
|
{
|
||||||
$number_of_fields =count($csv_fields_keys);
|
$number_of_fields =(!empty($csv_fields_keys)?count($csv_fields_keys):0);
|
||||||
|
|
||||||
switch($ziel)
|
switch($ziel)
|
||||||
{
|
{
|
||||||
@ -1418,7 +1418,7 @@ ean;';
|
|||||||
|
|
||||||
function ExportPrepareRow($rowcounter,$ziel,$data,$csv_fields_keys,$csv_fields)
|
function ExportPrepareRow($rowcounter,$ziel,$data,$csv_fields_keys,$csv_fields)
|
||||||
{
|
{
|
||||||
$number_of_fields =count($csv_fields_keys);
|
$number_of_fields =(!empty($csv_fields_keys)?count($csv_fields_keys):0);
|
||||||
//Standard
|
//Standard
|
||||||
$fields[waehrung] = 'EUR';
|
$fields[waehrung] = 'EUR';
|
||||||
|
|
||||||
|
@ -48,7 +48,7 @@ class Firmendaten {
|
|||||||
foreach($documents as $documentKey => $document) {
|
foreach($documents as $documentKey => $document) {
|
||||||
$colDocument .= sprintf("IF(dci.doctype = '%s', '%s',", $documentKey, $document);
|
$colDocument .= sprintf("IF(dci.doctype = '%s', '%s',", $documentKey, $document);
|
||||||
}
|
}
|
||||||
$colDocument .= 'dci.doctype'. str_repeat(')', count($documents));
|
$colDocument .= 'dci.doctype'. str_repeat(')', (!empty($documents)?count($documents):0));
|
||||||
// headings
|
// headings
|
||||||
$heading = array('', 'Belegart', 'zusätzliche Sprachen', 'Projekt', 'Aktiv','', 'Menü');
|
$heading = array('', 'Belegart', 'zusätzliche Sprachen', 'Projekt', 'Aktiv','', 'Menü');
|
||||||
$width = array('1%', '10%', '20%', '15%', '5%', '1%', '1%');
|
$width = array('1%', '10%', '20%', '15%', '5%', '1%', '1%');
|
||||||
@ -197,7 +197,7 @@ class Firmendaten {
|
|||||||
if(@is_file($filename)) {
|
if(@is_file($filename)) {
|
||||||
@unlink($filename);
|
@unlink($filename);
|
||||||
}
|
}
|
||||||
if($palette && count($palette) == 1) {
|
if($palette && (!empty($palette)?count($palette):0) == 1) {
|
||||||
$color = array_keys($palette);
|
$color = array_keys($palette);
|
||||||
return League\ColorExtractor\Color::fromIntToHex(reset($color));
|
return League\ColorExtractor\Color::fromIntToHex(reset($color));
|
||||||
}
|
}
|
||||||
|
@ -123,7 +123,7 @@ class Generic {
|
|||||||
$data = $this->app->DB->SelectArr("SELECT * FROM accordion ORDER BY position ASC");
|
$data = $this->app->DB->SelectArr("SELECT * FROM accordion ORDER BY position ASC");
|
||||||
|
|
||||||
$out = '';
|
$out = '';
|
||||||
for($i=0;$i<count($data);$i++) {
|
for($i=0;$i<(!empty($data)?count($data):0);$i++) {
|
||||||
$color = (($i%2) ? '#e0e0e0' : '#fff');
|
$color = (($i%2) ? '#e0e0e0' : '#fff');
|
||||||
$out .= "<tr style=\"background-color:$color\">
|
$out .= "<tr style=\"background-color:$color\">
|
||||||
<td class=\"gentable\">{$data[$i]['position']}</td>
|
<td class=\"gentable\">{$data[$i]['position']}</td>
|
||||||
|
@ -728,7 +728,7 @@ class GoogleApi
|
|||||||
|
|
||||||
if ($data['type'] === 'mail') {
|
if ($data['type'] === 'mail') {
|
||||||
$users = $this->gateway->getApiUsersByAccount($data['id_name']);
|
$users = $this->gateway->getApiUsersByAccount($data['id_name']);
|
||||||
if (count($users) > 0) {
|
if ((!empty($users)?count($users):0) > 0) {
|
||||||
$this->auth->removeUserToken($users[0]);
|
$this->auth->removeUserToken($users[0]);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -837,7 +837,7 @@ class GoogleApi
|
|||||||
if ($api !== null && $api->getType() === 'mail') {
|
if ($api !== null && $api->getType() === 'mail') {
|
||||||
$users = $this->gateway->getApiUsersByAccount($api->getIdName());
|
$users = $this->gateway->getApiUsersByAccount($api->getIdName());
|
||||||
$token = '';
|
$token = '';
|
||||||
if (count($users) > 0) {
|
if ((!empty($users)?count($users):0) > 0) {
|
||||||
$token = $users[0]->getAccessToken();
|
$token = $users[0]->getAccessToken();
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
@ -470,7 +470,7 @@ class Gutschrift extends GenGutschrift
|
|||||||
|
|
||||||
$orderIds = [];
|
$orderIds = [];
|
||||||
if(!empty($rechnung)) {
|
if(!empty($rechnung)) {
|
||||||
$cRechnung = count($rechnung);
|
$cRechnung = (!empty($rechnung)?count($rechnung):0);
|
||||||
for($li=0;$li<$cRechnung;$li++) {
|
for($li=0;$li<$cRechnung;$li++) {
|
||||||
$orderIds[] = (int)$rechnung[$li]['auftragid'];
|
$orderIds[] = (int)$rechnung[$li]['auftragid'];
|
||||||
$this->app->Tpl->Add('RECHNUNG',$rechnung[$li]['rechnung']);
|
$this->app->Tpl->Add('RECHNUNG',$rechnung[$li]['rechnung']);
|
||||||
@ -691,7 +691,7 @@ class Gutschrift extends GenGutschrift
|
|||||||
OR (ke.objekt='auftrag' AND ke.parameter='$auftragid' AND ke.parameter>0)
|
OR (ke.objekt='auftrag' AND ke.parameter='$auftragid' AND ke.parameter>0)
|
||||||
OR (ke.objekt='rechnung' AND ke.parameter='$rechnungid' AND ke.parameter>0)"
|
OR (ke.objekt='rechnung' AND ke.parameter='$rechnungid' AND ke.parameter>0)"
|
||||||
);
|
);
|
||||||
$ceingangArr = empty($eingangArr)?0:count($eingangArr);
|
$ceingangArr = empty($eingangArr)?0:(!empty($eingangArr)?count($eingangArr):0);
|
||||||
|
|
||||||
for($i=0;$i<$ceingangArr;$i++) {
|
for($i=0;$i<$ceingangArr;$i++) {
|
||||||
$waehrung = 'EUR';
|
$waehrung = 'EUR';
|
||||||
@ -709,7 +709,7 @@ class Gutschrift extends GenGutschrift
|
|||||||
/*
|
/*
|
||||||
$gutschriften = $this->app->DB->SelectArr("SELECT belegnr, DATE_FORMAT(datum,'%d.%m.%Y') as datum,soll FROM gutschrift WHERE rechnungid='$id'");
|
$gutschriften = $this->app->DB->SelectArr("SELECT belegnr, DATE_FORMAT(datum,'%d.%m.%Y') as datum,soll FROM gutschrift WHERE rechnungid='$id'");
|
||||||
|
|
||||||
for($i=0;$i<count($gutschriften);$i++)
|
for($i=0;$i<(!empty($gutschriften)?count($gutschriften):0);$i++)
|
||||||
$eingang .="<tr><td class=auftrag_cell>".$gutschriften[$i]['datum']."</td><td class=auftrag_cell>GS ".$gutschriften[$i]['belegnr']."</td><td class=auftrag_cell align=right>".$this->app->erp->EUR($gutschriften[$i]['soll'])." EUR</td></tr>";
|
$eingang .="<tr><td class=auftrag_cell>".$gutschriften[$i]['datum']."</td><td class=auftrag_cell>GS ".$gutschriften[$i]['belegnr']."</td><td class=auftrag_cell align=right>".$this->app->erp->EUR($gutschriften[$i]['soll'])." EUR</td></tr>";
|
||||||
|
|
||||||
*/
|
*/
|
||||||
@ -725,7 +725,7 @@ class Gutschrift extends GenGutschrift
|
|||||||
OR (ke.objekt='rechnung' AND ke.parameter='$rechnungid' AND ke.parameter>0)
|
OR (ke.objekt='rechnung' AND ke.parameter='$rechnungid' AND ke.parameter>0)
|
||||||
OR (ke.objekt='auftrag' AND ke.parameter='$auftragid' AND ke.parameter>0)"
|
OR (ke.objekt='auftrag' AND ke.parameter='$auftragid' AND ke.parameter>0)"
|
||||||
);
|
);
|
||||||
$cAusgangArr = empty($ausgangArr)?0:count($ausgangArr);
|
$cAusgangArr = empty($ausgangArr)?0:(!empty($ausgangArr)?count($ausgangArr):0);
|
||||||
for($i=0;$i<$cAusgangArr;$i++) {
|
for($i=0;$i<$cAusgangArr;$i++) {
|
||||||
$waehrung = 'EUR';
|
$waehrung = 'EUR';
|
||||||
if($ausgangArr[$i]['waehrung']) {
|
if($ausgangArr[$i]['waehrung']) {
|
||||||
@ -1257,9 +1257,9 @@ class Gutschrift extends GenGutschrift
|
|||||||
$alle_gutschriften = $this->app->DB->SelectArr("SELECT id,belegnr FROM gutschrift WHERE rechnungid='$rechnungid' AND rechnungid>0");
|
$alle_gutschriften = $this->app->DB->SelectArr("SELECT id,belegnr FROM gutschrift WHERE rechnungid='$rechnungid' AND rechnungid>0");
|
||||||
|
|
||||||
if (!is_null($alle_gutschriften)) {
|
if (!is_null($alle_gutschriften)) {
|
||||||
if(count($alle_gutschriften) > 1)
|
if((!empty($alle_gutschriften)?count($alle_gutschriften):0) > 1)
|
||||||
{
|
{
|
||||||
for($agi=0;$agi<count($alle_gutschriften);$agi++)
|
for($agi=0;$agi<(!empty($alle_gutschriften)?count($alle_gutschriften):0);$agi++)
|
||||||
$gutschriften .= "<a href=\"index.php?module=gutschrift&action=edit&id=".$alle_gutschriften[$agi][id]."\" target=\"_blank\">".$alle_gutschriften[$agi][belegnr]."</a> ";
|
$gutschriften .= "<a href=\"index.php?module=gutschrift&action=edit&id=".$alle_gutschriften[$agi][id]."\" target=\"_blank\">".$alle_gutschriften[$agi][belegnr]."</a> ";
|
||||||
$this->app->Tpl->Add('MESSAGE',"<div class=\"warning\">Für die angebene Rechnung gibt es schon folgende Gutschriften: $gutschriften</div>");
|
$this->app->Tpl->Add('MESSAGE',"<div class=\"warning\">Für die angebene Rechnung gibt es schon folgende Gutschriften: $gutschriften</div>");
|
||||||
}
|
}
|
||||||
@ -1657,7 +1657,7 @@ class Gutschrift extends GenGutschrift
|
|||||||
$tmpfile[] = $Brief->displayTMP();
|
$tmpfile[] = $Brief->displayTMP();
|
||||||
}
|
}
|
||||||
|
|
||||||
if(count($tmpfile) > 0) {
|
if((!empty($tmpfile)?count($tmpfile):0) > 0) {
|
||||||
try {
|
try {
|
||||||
/** @var PdfMerger $pdfMerger */
|
/** @var PdfMerger $pdfMerger */
|
||||||
$pdfMerger = $this->app->Container->get('PdfMerger');
|
$pdfMerger = $this->app->Container->get('PdfMerger');
|
||||||
|
@ -43,7 +43,7 @@ class Hauptmenu {
|
|||||||
|
|
||||||
if (!is_null($menu)) {
|
if (!is_null($menu)) {
|
||||||
|
|
||||||
if (count($menu) > 0) {
|
if ((!empty($menu)?count($menu):0) > 0) {
|
||||||
foreach ($menu as $key => $value) {
|
foreach ($menu as $key => $value) {
|
||||||
$i++;
|
$i++;
|
||||||
if ($value[first][2] != "")
|
if ($value[first][2] != "")
|
||||||
|
@ -112,7 +112,7 @@ class Importvorlage extends GenImportvorlage {
|
|||||||
$this->app->DB->real_escape_string($statusMessage)
|
$this->app->DB->real_escape_string($statusMessage)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
$statusCol .= "'')".str_repeat(')', count($statusMapping));
|
$statusCol .= "'')".str_repeat(')', (!empty($statusMapping)?count($statusMapping):0));
|
||||||
|
|
||||||
$searchsql = [
|
$searchsql = [
|
||||||
'adr.name',
|
'adr.name',
|
||||||
@ -141,7 +141,7 @@ class Importvorlage extends GenImportvorlage {
|
|||||||
.$this->app->Conf->WFconf['defaulttheme']
|
.$this->app->Conf->WFconf['defaulttheme']
|
||||||
.'/images/delete.svg" alt="löschen" class="deletejob" data-id="%value%" />';
|
.'/images/delete.svg" alt="löschen" class="deletejob" data-id="%value%" />';
|
||||||
$menu .= '</td></tr></table>';
|
$menu .= '</td></tr></table>';
|
||||||
$menucol = count($heading);
|
$menucol = (!empty($heading)?count($heading):0);
|
||||||
$filterComplete = $this->app->YUI->TableSearchFilter($name,1 ,'importvorlage-filter-complete',0,0,'checkbox');
|
$filterComplete = $this->app->YUI->TableSearchFilter($name,1 ,'importvorlage-filter-complete',0,0,'checkbox');
|
||||||
$filterCancelled = $this->app->YUI->TableSearchFilter($name,2 ,'importvorlage-filter-cancelled',0,0,'checkbox');
|
$filterCancelled = $this->app->YUI->TableSearchFilter($name,2 ,'importvorlage-filter-cancelled',0,0,'checkbox');
|
||||||
$sql = "SELECT imd.id,
|
$sql = "SELECT imd.id,
|
||||||
@ -827,7 +827,7 @@ class Importvorlage extends GenImportvorlage {
|
|||||||
);
|
);
|
||||||
|
|
||||||
$fieldsarray = explode(';',$fields);
|
$fieldsarray = explode(';',$fields);
|
||||||
$cFieldsarray = count($fieldsarray);
|
$cFieldsarray = (!empty($fieldsarray)?count($fieldsarray):0);
|
||||||
for($i=0;$i<$cFieldsarray;$i++) {
|
for($i=0;$i<$cFieldsarray;$i++) {
|
||||||
$fieldsarray_items = explode(':',$fieldsarray[$i]);
|
$fieldsarray_items = explode(':',$fieldsarray[$i]);
|
||||||
$fieldsarray_items[0] = str_replace('!','',$fieldsarray_items[0]);
|
$fieldsarray_items[0] = str_replace('!','',$fieldsarray_items[0]);
|
||||||
@ -865,7 +865,7 @@ class Importvorlage extends GenImportvorlage {
|
|||||||
$fields = $this->cleanFields($fields);
|
$fields = $this->cleanFields($fields);
|
||||||
|
|
||||||
$fieldsarray = explode(';',$fields);
|
$fieldsarray = explode(';',$fields);
|
||||||
//for($i=0;$i<count($fieldsarray);$i++)
|
//for($i=0;$i<(!empty($fieldsarray)?count($fieldsarray):0);$i++)
|
||||||
foreach($fieldsarray as $key => $fieldsrow) {
|
foreach($fieldsarray as $key => $fieldsrow) {
|
||||||
$fieldsarray_items = explode(':',$fieldsrow,3);
|
$fieldsarray_items = explode(':',$fieldsrow,3);
|
||||||
$fieldsarray_items1 = trim(str_replace('!','',$fieldsarray_items[1]));
|
$fieldsarray_items1 = trim(str_replace('!','',$fieldsarray_items[1]));
|
||||||
@ -911,7 +911,7 @@ class Importvorlage extends GenImportvorlage {
|
|||||||
);
|
);
|
||||||
|
|
||||||
$fieldsarray = explode(';',$fields);
|
$fieldsarray = explode(';',$fields);
|
||||||
$cFieldsarray = count($fieldsarray);
|
$cFieldsarray = (!empty($fieldsarray)?count($fieldsarray):0);
|
||||||
for($i=0;$i<$cFieldsarray;$i++) {
|
for($i=0;$i<$cFieldsarray;$i++) {
|
||||||
$fieldsarray_items = explode(':',$fieldsarray[$i]);
|
$fieldsarray_items = explode(':',$fieldsarray[$i]);
|
||||||
if($fieldsarray_items[1]!=''){
|
if($fieldsarray_items[1]!=''){
|
||||||
@ -946,7 +946,7 @@ class Importvorlage extends GenImportvorlage {
|
|||||||
);
|
);
|
||||||
|
|
||||||
$fieldsarray = explode(';',$fields);
|
$fieldsarray = explode(';',$fields);
|
||||||
$cFieldsarray = count($fieldsarray);
|
$cFieldsarray = (!empty($fieldsarray)?count($fieldsarray):0);
|
||||||
for($i=0;$i<$cFieldsarray;$i++) {
|
for($i=0;$i<$cFieldsarray;$i++) {
|
||||||
$fieldsarray_items = explode(':',$fieldsarray[$i]);
|
$fieldsarray_items = explode(':',$fieldsarray[$i]);
|
||||||
if($fieldsarray_items[1]!=''){
|
if($fieldsarray_items[1]!=''){
|
||||||
@ -1018,7 +1018,7 @@ class Importvorlage extends GenImportvorlage {
|
|||||||
if($importdatenmaskierung==='gaensefuesschen') {
|
if($importdatenmaskierung==='gaensefuesschen') {
|
||||||
$importdatenmaskierung='"';
|
$importdatenmaskierung='"';
|
||||||
}
|
}
|
||||||
//$number_of_fields = count($csv_fields);
|
//$number_of_fields = (!empty($csv_fields)?count($csv_fields):0);
|
||||||
|
|
||||||
|
|
||||||
$limit_erreicht = false;
|
$limit_erreicht = false;
|
||||||
@ -1198,13 +1198,13 @@ class Importvorlage extends GenImportvorlage {
|
|||||||
|
|
||||||
$fieldsarray = explode(';',$fieldstring);
|
$fieldsarray = explode(';',$fieldstring);
|
||||||
foreach($fieldsarray as $field) {
|
foreach($fieldsarray as $field) {
|
||||||
//for($i=0;$i<count($fieldsarray);$i++)
|
//for($i=0;$i<(!empty($fieldsarray)?count($fieldsarray):0);$i++)
|
||||||
//{
|
//{
|
||||||
$fieldsarray_items = explode(':',$field);
|
$fieldsarray_items = explode(':',$field);
|
||||||
foreach($fieldsarray_items as $k => $v) {
|
foreach($fieldsarray_items as $k => $v) {
|
||||||
$fieldsarray_items[$k] = trim($v);
|
$fieldsarray_items[$k] = trim($v);
|
||||||
}
|
}
|
||||||
if(count($fieldsarray_items) > 1){
|
if((!empty($fieldsarray_items)?count($fieldsarray_items):0) > 1){
|
||||||
if($fieldsarray_items[1] != ''){
|
if($fieldsarray_items[1] != ''){
|
||||||
if($fieldsarray_items[0] == (int)$fieldsarray_items[0]){
|
if($fieldsarray_items[0] == (int)$fieldsarray_items[0]){
|
||||||
//$csv_fields[$fieldsarray_items[0]]= $fieldsarray_items[1];
|
//$csv_fields[$fieldsarray_items[0]]= $fieldsarray_items[1];
|
||||||
@ -1303,13 +1303,13 @@ class Importvorlage extends GenImportvorlage {
|
|||||||
$stueckliste_csv
|
$stueckliste_csv
|
||||||
);
|
);
|
||||||
|
|
||||||
$number_of_fields = count($csv_fields_keys);
|
$number_of_fields = (!empty($csv_fields_keys)?count($csv_fields_keys):0);
|
||||||
if (($handle = fopen($stueckliste_csv, 'r')) !== FALSE) {
|
if (($handle = fopen($stueckliste_csv, 'r')) !== FALSE) {
|
||||||
$rowcounter = 0;
|
$rowcounter = 0;
|
||||||
$rowcounter_real = 0;
|
$rowcounter_real = 0;
|
||||||
while (($data = fgetcsv($handle, 0, $importtrennzeichen)) !== FALSE) {
|
while (($data = fgetcsv($handle, 0, $importtrennzeichen)) !== FALSE) {
|
||||||
$rowcounter++;
|
$rowcounter++;
|
||||||
$num = count($data);
|
$num = (!empty($data)?count($data):0);
|
||||||
if($rowcounter >= $importerstezeilenummer) {
|
if($rowcounter >= $importerstezeilenummer) {
|
||||||
if(empty($data)) {
|
if(empty($data)) {
|
||||||
continue;
|
continue;
|
||||||
@ -1976,7 +1976,7 @@ class Importvorlage extends GenImportvorlage {
|
|||||||
$artikelbaumteile = explode("|", $artikelbaumanweisung);
|
$artikelbaumteile = explode("|", $artikelbaumanweisung);
|
||||||
$artikelbaumzumhinzufuegen = array();
|
$artikelbaumzumhinzufuegen = array();
|
||||||
$artikelbaumtmpkategorieid = 0;
|
$artikelbaumtmpkategorieid = 0;
|
||||||
for ($ii=0; $ii < count($artikelbaumteile); $ii++) {
|
for ($ii=0; $ii < (!empty($artikelbaumteile)?count($artikelbaumteile):0); $ii++) {
|
||||||
$kategorieid = $this->app->DB->Select("SELECT id FROM artikelkategorien WHERE bezeichnung = '".$this->app->DB->real_escape_string($artikelbaumteile[$ii])."' AND parent = '$artikelbaumtmpkategorieid' LIMIT 1");
|
$kategorieid = $this->app->DB->Select("SELECT id FROM artikelkategorien WHERE bezeichnung = '".$this->app->DB->real_escape_string($artikelbaumteile[$ii])."' AND parent = '$artikelbaumtmpkategorieid' LIMIT 1");
|
||||||
if($kategorieid == ''){
|
if($kategorieid == ''){
|
||||||
break;
|
break;
|
||||||
@ -1986,7 +1986,7 @@ class Importvorlage extends GenImportvorlage {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
for ($ii=0; $ii < count($artikelbaumzumhinzufuegen); $ii++) {
|
for ($ii=0; $ii < (!empty($artikelbaumzumhinzufuegen)?count($artikelbaumzumhinzufuegen):0); $ii++) {
|
||||||
$vorhanden = $this->app->DB->Select("SELECT id FROM artikelbaum_artikel WHERE artikel = '$artikelid' AND kategorie = '".$artikelbaumzumhinzufuegen[$ii]."' LIMIT 1");
|
$vorhanden = $this->app->DB->Select("SELECT id FROM artikelbaum_artikel WHERE artikel = '$artikelid' AND kategorie = '".$artikelbaumzumhinzufuegen[$ii]."' LIMIT 1");
|
||||||
if($vorhanden == ''){
|
if($vorhanden == ''){
|
||||||
$this->app->DB->Insert("INSERT INTO artikelbaum_artikel (artikel, kategorie) VALUES ('$artikelid','".$artikelbaumzumhinzufuegen[$ii]."')");
|
$this->app->DB->Insert("INSERT INTO artikelbaum_artikel (artikel, kategorie) VALUES ('$artikelid','".$artikelbaumzumhinzufuegen[$ii]."')");
|
||||||
@ -2930,7 +2930,7 @@ class Importvorlage extends GenImportvorlage {
|
|||||||
$artikelbaumteile = explode("|", $artikelbaumanweisung);
|
$artikelbaumteile = explode("|", $artikelbaumanweisung);
|
||||||
$artikelbaumzumhinzufuegen = array();
|
$artikelbaumzumhinzufuegen = array();
|
||||||
$artikelbaumtmpkategorieid = 0;
|
$artikelbaumtmpkategorieid = 0;
|
||||||
for ($ii=0; $ii < count($artikelbaumteile); $ii++) {
|
for ($ii=0; $ii < (!empty($artikelbaumteile)?count($artikelbaumteile):0); $ii++) {
|
||||||
$kategorieid = $this->app->DB->Select("SELECT id FROM artikelkategorien WHERE geloescht = 0 AND bezeichnung = '".$this->app->DB->real_escape_string($artikelbaumteile[$ii])."' AND parent = '$artikelbaumtmpkategorieid' LIMIT 1");
|
$kategorieid = $this->app->DB->Select("SELECT id FROM artikelkategorien WHERE geloescht = 0 AND bezeichnung = '".$this->app->DB->real_escape_string($artikelbaumteile[$ii])."' AND parent = '$artikelbaumtmpkategorieid' LIMIT 1");
|
||||||
if($kategorieid == ''){
|
if($kategorieid == ''){
|
||||||
break;
|
break;
|
||||||
@ -2940,7 +2940,7 @@ class Importvorlage extends GenImportvorlage {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
for ($ii=0; $ii < count($artikelbaumzumhinzufuegen); $ii++) {
|
for ($ii=0; $ii < (!empty($artikelbaumzumhinzufuegen)?count($artikelbaumzumhinzufuegen):0); $ii++) {
|
||||||
$vorhanden = $this->app->DB->Select("SELECT id FROM artikelbaum_artikel WHERE artikel = '$artikelid' AND kategorie = '".$artikelbaumzumhinzufuegen[$ii]."' LIMIT 1");
|
$vorhanden = $this->app->DB->Select("SELECT id FROM artikelbaum_artikel WHERE artikel = '$artikelid' AND kategorie = '".$artikelbaumzumhinzufuegen[$ii]."' LIMIT 1");
|
||||||
if($vorhanden == ''){
|
if($vorhanden == ''){
|
||||||
$this->app->DB->Insert("INSERT INTO artikelbaum_artikel (artikel, kategorie) VALUES ('$artikelid','".$artikelbaumzumhinzufuegen[$ii]."')");
|
$this->app->DB->Insert("INSERT INTO artikelbaum_artikel (artikel, kategorie) VALUES ('$artikelid','".$artikelbaumzumhinzufuegen[$ii]."')");
|
||||||
@ -3990,8 +3990,8 @@ class Importvorlage extends GenImportvorlage {
|
|||||||
foreach ($tmp as $feldname => $feldwerte) {
|
foreach ($tmp as $feldname => $feldwerte) {
|
||||||
if(strpos($feldname,'_') !== false){
|
if(strpos($feldname,'_') !== false){
|
||||||
$feldnametmp = explode('_',$feldname);
|
$feldnametmp = explode('_',$feldname);
|
||||||
$sprache = $feldnametmp[count($feldnametmp)-1];
|
$sprache = $feldnametmp[(!empty($feldnametmp)?count($feldnametmp):0)-1];
|
||||||
unset($feldnametmp[count($feldnametmp)-1]);
|
unset($feldnametmp[(!empty($feldnametmp)?count($feldnametmp):0)-1]);
|
||||||
$feldnameohnepsrache = implode('_',$feldnametmp);
|
$feldnameohnepsrache = implode('_',$feldnametmp);
|
||||||
|
|
||||||
$output_array = [];
|
$output_array = [];
|
||||||
@ -5604,7 +5604,7 @@ class Importvorlage extends GenImportvorlage {
|
|||||||
*/
|
*/
|
||||||
function ImportPrepareHeader($ziel,$fieldset)
|
function ImportPrepareHeader($ziel,$fieldset)
|
||||||
{
|
{
|
||||||
$number_of_fields =count($fieldset);
|
$number_of_fields =(!empty($fieldset)?count($fieldset):0);
|
||||||
|
|
||||||
switch($ziel)
|
switch($ziel)
|
||||||
{
|
{
|
||||||
@ -5648,7 +5648,7 @@ class Importvorlage extends GenImportvorlage {
|
|||||||
*/
|
*/
|
||||||
function ImportPrepareRow($rowcounter,$ziel,$data,$fieldset)
|
function ImportPrepareRow($rowcounter,$ziel,$data,$fieldset)
|
||||||
{
|
{
|
||||||
$number_of_fields =count($fieldset);
|
$number_of_fields =(!empty($fieldset)?count($fieldset):0);
|
||||||
//Standard
|
//Standard
|
||||||
$fields['waehrung'] = 'EUR';
|
$fields['waehrung'] = 'EUR';
|
||||||
|
|
||||||
|
@ -477,7 +477,7 @@ class Inhalt{
|
|||||||
foreach($unterpunkte as $upunkt)
|
foreach($unterpunkte as $upunkt)
|
||||||
$tmp["{$upunkt["id"]}"]=" ".$upunkt["bezeichnung"];
|
$tmp["{$upunkt["id"]}"]=" ".$upunkt["bezeichnung"];
|
||||||
}
|
}
|
||||||
if(count($tmp) < 1) return '<option value=""> -- Keine Navigation vorhanden --</option>';
|
if((!empty($tmp)?count($tmp):0) < 1) return '<option value=""> -- Keine Navigation vorhanden --</option>';
|
||||||
|
|
||||||
$out = '';
|
$out = '';
|
||||||
foreach($tmp as $key=>$value) {
|
foreach($tmp as $key=>$value) {
|
||||||
|
@ -333,8 +333,8 @@ class Kalender {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Schreibe Personen
|
// Schreibe Personen
|
||||||
if(is_numeric($event) && is_array($personen) && count($personen) && $mode!=='delete') {
|
if(is_numeric($event) && is_array($personen) && (!empty($personen)?count($personen):0) && $mode!=='delete') {
|
||||||
$cpersonen = count($personen);
|
$cpersonen = (!empty($personen)?count($personen):0);
|
||||||
for($p=0;$p<$cpersonen;$p++) {
|
for($p=0;$p<$cpersonen;$p++) {
|
||||||
$this->app->DB->Insert("INSERT INTO kalender_user (event, userid) VALUES ('$event', '{$personen[$p]}')");
|
$this->app->DB->Insert("INSERT INTO kalender_user (event, userid) VALUES ('$event', '{$personen[$p]}')");
|
||||||
}
|
}
|
||||||
@ -346,8 +346,8 @@ class Kalender {
|
|||||||
|
|
||||||
|
|
||||||
// Schreibe Gruppenkalender
|
// Schreibe Gruppenkalender
|
||||||
if(is_numeric($event) && is_array($gruppenkalender) && count($gruppenkalender) && $mode!=='delete') {
|
if(is_numeric($event) && is_array($gruppenkalender) && (!empty($gruppenkalender)?count($gruppenkalender):0) && $mode!=='delete') {
|
||||||
$cgruppenkalender = count($gruppenkalender);
|
$cgruppenkalender = (!empty($gruppenkalender)?count($gruppenkalender):0);
|
||||||
for($p=0;$p<$cgruppenkalender;$p++){
|
for($p=0;$p<$cgruppenkalender;$p++){
|
||||||
// stelle farbe von kalender eintrag um wenn gruppe (also erste gruppe in auswahl)
|
// stelle farbe von kalender eintrag um wenn gruppe (also erste gruppe in auswahl)
|
||||||
if($p==0){
|
if($p==0){
|
||||||
@ -1325,7 +1325,7 @@ class Kalender {
|
|||||||
//$to_name="";
|
//$to_name="";
|
||||||
|
|
||||||
$parts = explode(',',$emailcc);
|
$parts = explode(',',$emailcc);
|
||||||
$cparts = count($parts);
|
$cparts = (!empty($parts)?count($parts):0);
|
||||||
for($i=0;$i<$cparts;$i++)
|
for($i=0;$i<$cparts;$i++)
|
||||||
{
|
{
|
||||||
$from = strstr($parts[$i], '<', true); // Ab PHP 5.3.0
|
$from = strstr($parts[$i], '<', true); // Ab PHP 5.3.0
|
||||||
|
@ -71,7 +71,7 @@ class Korrespondenz
|
|||||||
$post['datum'] = date("d.m.Y");
|
$post['datum'] = date("d.m.Y");
|
||||||
|
|
||||||
$userdata = $this->app->DB->SelectArr("SELECT * FROM adresse WHERE id='{$post['user']}' LIMIT 1");
|
$userdata = $this->app->DB->SelectArr("SELECT * FROM adresse WHERE id='{$post['user']}' LIMIT 1");
|
||||||
if(is_array($userdata) && count($userdata)>0) {
|
if(is_array($userdata) && (!empty($userdata)?count($userdata):0)>0) {
|
||||||
$vorname = '';
|
$vorname = '';
|
||||||
if(($userdata[0]['typ']=='herr' || $userdata[0]['typ']=='frau') && $userdata[0]['vorname']!='')
|
if(($userdata[0]['typ']=='herr' || $userdata[0]['typ']=='frau') && $userdata[0]['vorname']!='')
|
||||||
$vorname = "{$userdata[0]['vorname']} ";
|
$vorname = "{$userdata[0]['vorname']} ";
|
||||||
@ -234,7 +234,7 @@ class Korrespondenz
|
|||||||
$selected = $this->app->DB->Select("SELECT standarddrucker FROM user WHERE id='".$this->app->User->GetID()."' LIMIT 1");
|
$selected = $this->app->DB->Select("SELECT standarddrucker FROM user WHERE id='".$this->app->User->GetID()."' LIMIT 1");
|
||||||
|
|
||||||
$drucker = $this->app->DB->SelectArr("SELECT id, name FROM drucker WHERE firma='".$this->app->User->GetFirma()."' AND aktiv='1'");
|
$drucker = $this->app->DB->SelectArr("SELECT id, name FROM drucker WHERE firma='".$this->app->User->GetFirma()."' AND aktiv='1'");
|
||||||
for($i=0;$i<count($drucker);$i++)
|
for($i=0;$i<(!empty($drucker)?count($drucker):0);$i++)
|
||||||
{
|
{
|
||||||
if($drucker[$i]['id']==$selected) $mark="selected"; else $mark="";
|
if($drucker[$i]['id']==$selected) $mark="selected"; else $mark="";
|
||||||
$out .="<option value=\"{$drucker[$i]['id']}\" $mark>{$drucker[$i]['name']}</option>";
|
$out .="<option value=\"{$drucker[$i]['id']}\" $mark>{$drucker[$i]['name']}</option>";
|
||||||
|
@ -2276,7 +2276,7 @@ class Lager extends GenLager {
|
|||||||
|
|
||||||
$this->app->Tpl->Set('SHOWCHRSTART','<!--');
|
$this->app->Tpl->Set('SHOWCHRSTART','<!--');
|
||||||
$this->app->Tpl->Set('SHOWCHREND','-->');
|
$this->app->Tpl->Set('SHOWCHREND','-->');
|
||||||
if(count($mhd) <=0)
|
if((!empty($mhd)?count($mhd):0) <=0)
|
||||||
{
|
{
|
||||||
$this->app->Tpl->Set('SHOWMHDSTART','<!--');
|
$this->app->Tpl->Set('SHOWMHDSTART','<!--');
|
||||||
$this->app->Tpl->Set('SHOWMHDEND','-->');
|
$this->app->Tpl->Set('SHOWMHDEND','-->');
|
||||||
@ -2977,9 +2977,9 @@ class Lager extends GenLager {
|
|||||||
$this->app->Tpl->Set('SUMME', $summe);
|
$this->app->Tpl->Set('SUMME', $summe);
|
||||||
if($anzsrn > 0) {
|
if($anzsrn > 0) {
|
||||||
$this->app->Tpl->Add('SRNINFO',"<tr><td></td><td>{|MHD|}</td><td>{|Seriennummer|}</td><td>{|Charge|}</td></tr>");
|
$this->app->Tpl->Add('SRNINFO',"<tr><td></td><td>{|MHD|}</td><td>{|Seriennummer|}</td><td>{|Charge|}</td></tr>");
|
||||||
} else if (count($tmpmhd) > 0) {
|
} else if ((!empty($tmpmhd)?count($tmpmhd):0) > 0) {
|
||||||
$this->app->Tpl->Add('SRNINFO',"<tr><td></td><td>{|Mindesthalt.|}</td><td width=30></td><td>{|Charge|}</td></tr>");
|
$this->app->Tpl->Add('SRNINFO',"<tr><td></td><td>{|Mindesthalt.|}</td><td width=30></td><td>{|Charge|}</td></tr>");
|
||||||
} else if (count($tmpcharge) > 0) {
|
} else if ((!empty($tmpcharge)?count($tmpcharge):0) > 0) {
|
||||||
$this->app->Tpl->Add('SRNINFO',"<tr><td></td><td>{|Charge|}</td></tr>");
|
$this->app->Tpl->Add('SRNINFO',"<tr><td></td><td>{|Charge|}</td></tr>");
|
||||||
}
|
}
|
||||||
$artikelArr = $this->app->DB->SelectRow(
|
$artikelArr = $this->app->DB->SelectRow(
|
||||||
@ -3651,10 +3651,10 @@ class Lager extends GenLager {
|
|||||||
$nummer = $this->app->DB->Select("SELECT belegnr FROM produktion WHERE id='$produktion' LIMIT 1");
|
$nummer = $this->app->DB->Select("SELECT belegnr FROM produktion WHERE id='$produktion' LIMIT 1");
|
||||||
$this->app->Tpl->Add('TAB1', "<tr><td>Produktion $nummer</td><td>$bezeichnung</td><td align=center><a href=\"index.php?module=lager&action=auslagernproduktion&id=$produktion&cmd=produktion\"><img src=\"./themes/[THEME]/images/forward.svg\"></a></td></tr>");
|
$this->app->Tpl->Add('TAB1', "<tr><td>Produktion $nummer</td><td>$bezeichnung</td><td align=center><a href=\"index.php?module=lager&action=auslagernproduktion&id=$produktion&cmd=produktion\"><img src=\"./themes/[THEME]/images/forward.svg\"></a></td></tr>");
|
||||||
$artikellistesumm = $this->app->DB->SelectArr("SELECT DISTINCT artikel FROM lager_reserviert WHERE objekt='produktion' AND parameter='$produktion'");
|
$artikellistesumm = $this->app->DB->SelectArr("SELECT DISTINCT artikel FROM lager_reserviert WHERE objekt='produktion' AND parameter='$produktion'");
|
||||||
if (count($artikellistesumm) == 0) continue;
|
if ((!empty($artikellistesumm)?count($artikellistesumm):0) == 0) continue;
|
||||||
$artikelliste = $this->app->DB->SelectArr("SELECT DISTINCT artikel FROM lager_reserviert WHERE objekt='produktion' AND parameter='$produktion'");
|
$artikelliste = $this->app->DB->SelectArr("SELECT DISTINCT artikel FROM lager_reserviert WHERE objekt='produktion' AND parameter='$produktion'");
|
||||||
|
|
||||||
$gesamtanzahlartikel = $gesamtanzahlartikel + count($artikelliste);
|
$gesamtanzahlartikel = $gesamtanzahlartikel + (!empty($artikelliste)?count($artikelliste):0);
|
||||||
}
|
}
|
||||||
$this->app->Tpl->Add('TAB1', "</table>");
|
$this->app->Tpl->Add('TAB1', "</table>");
|
||||||
|
|
||||||
@ -3683,11 +3683,11 @@ class Lager extends GenLager {
|
|||||||
if ($projekt == 0 || $projekt == "") $projektName = "Ohne Projekt";
|
if ($projekt == 0 || $projekt == "") $projektName = "Ohne Projekt";
|
||||||
$artikellistesumm = $this->app->DB->SelectArr("SELECT DISTINCT artikel FROM lager_reserviert WHERE objekt='lieferschein' AND projekt='$projekt' ");
|
$artikellistesumm = $this->app->DB->SelectArr("SELECT DISTINCT artikel FROM lager_reserviert WHERE objekt='lieferschein' AND projekt='$projekt' ");
|
||||||
|
|
||||||
if (count($artikellistesumm) == 0) continue;
|
if ((!empty($artikellistesumm)?count($artikellistesumm):0) == 0) continue;
|
||||||
$this->app->Tpl->Add('INHALT', "<h2>$projektName Lieferungen Stand " . date('d.m.Y') . "</h2>");
|
$this->app->Tpl->Add('INHALT', "<h2>$projektName Lieferungen Stand " . date('d.m.Y') . "</h2>");
|
||||||
$artikelliste = $this->app->DB->SelectArr("SELECT DISTINCT artikel FROM lager_reserviert WHERE objekt='lieferschein' AND projekt='$projekt' ");
|
$artikelliste = $this->app->DB->SelectArr("SELECT DISTINCT artikel FROM lager_reserviert WHERE objekt='lieferschein' AND projekt='$projekt' ");
|
||||||
$orderarray = $this->LagerAuslagernArtikelliste($artikelliste,$projekt,true);
|
$orderarray = $this->LagerAuslagernArtikelliste($artikelliste,$projekt,true);
|
||||||
$gesamtanzahlartikel = count($orderarray);
|
$gesamtanzahlartikel = (!empty($orderarray)?count($orderarray):0);
|
||||||
$this->LagerAuslagernArtikellisteRender($orderarray);
|
$this->LagerAuslagernArtikellisteRender($orderarray);
|
||||||
} // ende projekt schleife
|
} // ende projekt schleife
|
||||||
if ($gesamtanzahlartikel <= 0) {
|
if ($gesamtanzahlartikel <= 0) {
|
||||||
@ -3738,7 +3738,7 @@ class Lager extends GenLager {
|
|||||||
|
|
||||||
// neu sortieren
|
// neu sortieren
|
||||||
asort($tmparray);
|
asort($tmparray);
|
||||||
if(count($tmparray)>0)
|
if((!empty($tmparray)?count($tmparray):0)>0)
|
||||||
{
|
{
|
||||||
foreach($tmparray as $key=>$value)
|
foreach($tmparray as $key=>$value)
|
||||||
{
|
{
|
||||||
@ -4338,7 +4338,7 @@ class Lager extends GenLager {
|
|||||||
|
|
||||||
$this->app->Tpl->Set('IMPORT',$lagerimport);
|
$this->app->Tpl->Set('IMPORT',$lagerimport);
|
||||||
|
|
||||||
if(count($tmp) > 0) {
|
if((!empty($tmp)?count($tmp):0) > 0) {
|
||||||
$sorttxt = ($neuesort > 0?" ($neuesort x Reihenfolge angepasst)":"");
|
$sorttxt = ($neuesort > 0?" ($neuesort x Reihenfolge angepasst)":"");
|
||||||
if($neue == 1){
|
if($neue == 1){
|
||||||
$this->app->Tpl->Set('MESSAGE3', "<div class=\"info\">$neue Regal wurde neu angelegt$sorttxt!</div>");
|
$this->app->Tpl->Set('MESSAGE3', "<div class=\"info\">$neue Regal wurde neu angelegt$sorttxt!</div>");
|
||||||
@ -4628,8 +4628,8 @@ class Lager extends GenLager {
|
|||||||
$data = $this->app->erp->base64_url_encode(serialize(array('drucker'=>$etikettendrucker,'etiketten'=>$etikettenauswahl,'von'=>$von,'bis'=>$bis)));
|
$data = $this->app->erp->base64_url_encode(serialize(array('drucker'=>$etikettendrucker,'etiketten'=>$etikettenauswahl,'von'=>$von,'bis'=>$bis)));
|
||||||
$tmp = $this->app->DB->SelectArr("SELECT kurzbezeichnung FROM lager_platz WHERE kurzbezeichnung >='$von' AND kurzbezeichnung<='$bis'");
|
$tmp = $this->app->DB->SelectArr("SELECT kurzbezeichnung FROM lager_platz WHERE kurzbezeichnung >='$von' AND kurzbezeichnung<='$bis'");
|
||||||
|
|
||||||
if(count($tmp)>0){
|
if((!empty($tmp)?count($tmp):0)>0){
|
||||||
echo json_encode(array('status'=>1, 'anzahl' => count($tmp), 'daten'=>$data));
|
echo json_encode(array('status'=>1, 'anzahl' => (!empty($tmp)?count($tmp):0), 'daten'=>$data));
|
||||||
$this->app->ExitXentral();
|
$this->app->ExitXentral();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -815,7 +815,7 @@ class Lieferschein extends GenLieferschein
|
|||||||
for($li=0;$li<$crechnung;$li++)
|
for($li=0;$li<$crechnung;$li++)
|
||||||
{
|
{
|
||||||
$this->app->Tpl->Add('RECHNUNG',$rechnung[$li]['rechnung']);
|
$this->app->Tpl->Add('RECHNUNG',$rechnung[$li]['rechnung']);
|
||||||
if($li<count($rechnung))
|
if($li<(!empty($rechnung)?count($rechnung):0))
|
||||||
$this->app->Tpl->Add('RECHNUNG',"<br>");
|
$this->app->Tpl->Add('RECHNUNG',"<br>");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -2242,7 +2242,7 @@ class Lieferschein extends GenLieferschein
|
|||||||
$tmpfile[] = $Brief->displayTMP();
|
$tmpfile[] = $Brief->displayTMP();
|
||||||
}
|
}
|
||||||
|
|
||||||
if(count($tmpfile) > 0) {
|
if((!empty($tmpfile)?count($tmpfile):0) > 0) {
|
||||||
try {
|
try {
|
||||||
/** @var PdfMerger $pdfMerger */
|
/** @var PdfMerger $pdfMerger */
|
||||||
$pdfMerger = $this->app->Container->get('PdfMerger');
|
$pdfMerger = $this->app->Container->get('PdfMerger');
|
||||||
@ -2464,7 +2464,7 @@ class Lieferschein extends GenLieferschein
|
|||||||
firma,bundesstaat,keinerechnung,ihrebestellnummer,lieferbedingung,internebezeichnung,lieferantenretoure,lieferant FROM lieferschein WHERE id='$id' LIMIT 1");
|
firma,bundesstaat,keinerechnung,ihrebestellnummer,lieferbedingung,internebezeichnung,lieferantenretoure,lieferant FROM lieferschein WHERE id='$id' LIMIT 1");
|
||||||
$this->app->DB->UpdateArr('lieferschein',$newid,'id',$arr, true);
|
$this->app->DB->UpdateArr('lieferschein',$newid,'id',$arr, true);
|
||||||
$pos = $this->app->DB->SelectArr("SELECT * FROM lieferschein_position WHERE lieferschein='$id'");
|
$pos = $this->app->DB->SelectArr("SELECT * FROM lieferschein_position WHERE lieferschein='$id'");
|
||||||
$cpos = !empty(count($pos))?count($pos):0;
|
$cpos = !empty((!empty($pos)?count($pos):0))?count($pos):0;
|
||||||
for($i=0;$i<$cpos;$i++){
|
for($i=0;$i<$cpos;$i++){
|
||||||
$this->app->DB->Insert("INSERT INTO lieferschein_position (lieferschein) VALUES ($newid)");
|
$this->app->DB->Insert("INSERT INTO lieferschein_position (lieferschein) VALUES ($newid)");
|
||||||
$newposid = $this->app->DB->GetInsertID();
|
$newposid = $this->app->DB->GetInsertID();
|
||||||
|
@ -879,7 +879,7 @@ class Onlineshops extends GenShopexport {
|
|||||||
public function ShopexportMinidetail()
|
public function ShopexportMinidetail()
|
||||||
{
|
{
|
||||||
$ida = explode('-',$this->app->Secure->GetGET('id'));
|
$ida = explode('-',$this->app->Secure->GetGET('id'));
|
||||||
if(count($ida) < 2)
|
if((!empty($ida)?count($ida):0) < 2)
|
||||||
{
|
{
|
||||||
$this->app->ExitXentral();
|
$this->app->ExitXentral();
|
||||||
}
|
}
|
||||||
@ -2574,7 +2574,7 @@ class Onlineshops extends GenShopexport {
|
|||||||
}
|
}
|
||||||
$form = $obj->getCreateForm();
|
$form = $obj->getCreateForm();
|
||||||
if(!empty($form)) {
|
if(!empty($form)) {
|
||||||
$form[count($form) - 1]['link'] = [
|
$form[(!empty($form)?count($form):0) - 1]['link'] = [
|
||||||
'link' => 'index.php?module=onlineshops&action=create&auswahl=' . $module,
|
'link' => 'index.php?module=onlineshops&action=create&auswahl=' . $module,
|
||||||
'title' => 'Expertenmodus',
|
'title' => 'Expertenmodus',
|
||||||
];
|
];
|
||||||
@ -2804,7 +2804,7 @@ class Onlineshops extends GenShopexport {
|
|||||||
|
|
||||||
$sequence = array_intersect($sequence, array_keys($importerCapabilities));
|
$sequence = array_intersect($sequence, array_keys($importerCapabilities));
|
||||||
|
|
||||||
$cShops = count($sequence);
|
$cShops = (!empty($sequence)?count($sequence):0);
|
||||||
$cTables = (int)ceil($cShops / 10);
|
$cTables = (int)ceil($cShops / 10);
|
||||||
$cTablesPerRow = (int)ceil($cShops / $cTables);
|
$cTablesPerRow = (int)ceil($cShops / $cTables);
|
||||||
|
|
||||||
@ -3104,7 +3104,7 @@ class Onlineshops extends GenShopexport {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$message = 'Geänderte Felder: '.count($differenceInValues);
|
$message = 'Geänderte Felder: '.(!empty($differenceInValues)?count($differenceInValues):0);
|
||||||
if(empty($differenceInValues)){
|
if(empty($differenceInValues)){
|
||||||
$message = 'Keine Änderung';
|
$message = 'Keine Änderung';
|
||||||
}
|
}
|
||||||
@ -3259,7 +3259,7 @@ class Onlineshops extends GenShopexport {
|
|||||||
$methodName = 'RemoteConnection';
|
$methodName = 'RemoteConnection';
|
||||||
$r = new ReflectionMethod($className, $methodName);
|
$r = new ReflectionMethod($className, $methodName);
|
||||||
$params = $r->getParameters();
|
$params = $r->getParameters();
|
||||||
$anzargs = count($params);
|
$anzargs = (!empty($params)?count($params):0);
|
||||||
try {
|
try {
|
||||||
if($anzargs > 1){
|
if($anzargs > 1){
|
||||||
$pageContents = $this->app->remote->RemoteConnection($id, true);
|
$pageContents = $this->app->remote->RemoteConnection($id, true);
|
||||||
@ -3856,7 +3856,7 @@ class Onlineshops extends GenShopexport {
|
|||||||
return $ret;
|
return $ret;
|
||||||
}
|
}
|
||||||
foreach($attributes as $key => $attribute) {
|
foreach($attributes as $key => $attribute) {
|
||||||
if((is_array($attribute) || is_object($attribute)) && count($attribute) === 1) {
|
if((is_array($attribute) || is_object($attribute)) && (!empty($attribute)?count($attribute):0) === 1) {
|
||||||
$ret .= ' '.$key.'="'.reset($attribute).'"';
|
$ret .= ' '.$key.'="'.reset($attribute).'"';
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
@ -3914,7 +3914,7 @@ class Onlineshops extends GenShopexport {
|
|||||||
unset($arr['@attributes']);
|
unset($arr['@attributes']);
|
||||||
}
|
}
|
||||||
$keys = array_keys($arr);
|
$keys = array_keys($arr);
|
||||||
$count = count($keys);
|
$count = (!empty($keys)?count($keys):0);
|
||||||
if($isObject && !empty($arr)) {
|
if($isObject && !empty($arr)) {
|
||||||
foreach($object as $key => $value) {
|
foreach($object as $key => $value) {
|
||||||
if($key === '@attributes') {
|
if($key === '@attributes') {
|
||||||
@ -3928,8 +3928,8 @@ class Onlineshops extends GenShopexport {
|
|||||||
unset($valueArr['@attributes']);
|
unset($valueArr['@attributes']);
|
||||||
}
|
}
|
||||||
if(is_object($value) && !empty($valueArr)) {
|
if(is_object($value) && !empty($valueArr)) {
|
||||||
$cValue = count($value);
|
$cValue = (!empty($value)?count($value):0);
|
||||||
$cValueArr = count($valueArr);
|
$cValueArr = (!empty($valueArr)?count($valueArr):0);
|
||||||
$attributes = $value->attributes();
|
$attributes = $value->attributes();
|
||||||
$attributeKey = $this->attributeKey($attributes);
|
$attributeKey = $this->attributeKey($attributes);
|
||||||
if(isset($array[$key.$attributeKey])) {
|
if(isset($array[$key.$attributeKey])) {
|
||||||
@ -4094,9 +4094,9 @@ class Onlineshops extends GenShopexport {
|
|||||||
$treeObject = $this->app->loadModule('artikelbaum');
|
$treeObject = $this->app->loadModule('artikelbaum');
|
||||||
$categories = [['id'=> 0, 'bezeichnung'=>'root', 'parent' => 0,],];
|
$categories = [['id'=> 0, 'bezeichnung'=>'root', 'parent' => 0,],];
|
||||||
$treeObject->getKategorien($categories, 0);
|
$treeObject->getKategorien($categories, 0);
|
||||||
if(count($categories) > 1) {
|
if((!empty($categories)?count($categories):0) > 1) {
|
||||||
if((string)$categories[count($categories) -1]['id'] === '0'){
|
if((string)$categories[(!empty($categories)?count($categories):0) -1]['id'] === '0'){
|
||||||
unset($categories[count($categories) - 1]);
|
unset($categories[(!empty($categories)?count($categories):0) - 1]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if($checkedId > 0 && !$this->isIdInCategories($checkedId, $categories)) {
|
if($checkedId > 0 && !$this->isIdInCategories($checkedId, $categories)) {
|
||||||
|
@ -76,7 +76,7 @@ class Pinwand {
|
|||||||
if($id > 0 && $speichern!="" && $name !="")
|
if($id > 0 && $speichern!="" && $name !="")
|
||||||
{
|
{
|
||||||
$this->app->DB->Delete("DELETE FROM pinwand_user WHERE pinwand='$id'");
|
$this->app->DB->Delete("DELETE FROM pinwand_user WHERE pinwand='$id'");
|
||||||
for($i=0;$i<count($personen);$i++)
|
for($i=0;$i<(!empty($personen)?count($personen):0);$i++)
|
||||||
{
|
{
|
||||||
$this->app->DB->Insert("INSERT INTO pinwand_user (id,pinwand,user) VALUES ('','$id','".$personen[$i]."')");
|
$this->app->DB->Insert("INSERT INTO pinwand_user (id,pinwand,user) VALUES ('','$id','".$personen[$i]."')");
|
||||||
}
|
}
|
||||||
@ -87,12 +87,12 @@ class Pinwand {
|
|||||||
$users = $this->app->DB->SelectArr("SELECT u.id, a.name as description FROM user u LEFT JOIN adresse a ON a.id=u.adresse
|
$users = $this->app->DB->SelectArr("SELECT u.id, a.name as description FROM user u LEFT JOIN adresse a ON a.id=u.adresse
|
||||||
WHERE u.activ='1' AND a.geloescht=0 ORDER BY a.name");
|
WHERE u.activ='1' AND a.geloescht=0 ORDER BY a.name");
|
||||||
$permissions = $this->app->DB->SelectArr("SELECT DISTINCT pu.user FROM pinwand_user pu WHERE pu.pinwand='$id'");
|
$permissions = $this->app->DB->SelectArr("SELECT DISTINCT pu.user FROM pinwand_user pu WHERE pu.pinwand='$id'");
|
||||||
for($i=0;$i<count($permissions);$i++)
|
for($i=0;$i<(!empty($permissions)?count($permissions):0);$i++)
|
||||||
{
|
{
|
||||||
$check_permissions[] = $permissions[$i]['user'];
|
$check_permissions[] = $permissions[$i]['user'];
|
||||||
}
|
}
|
||||||
|
|
||||||
for($i=0; $i<count($users);$i++){
|
for($i=0; $i<(!empty($users)?count($users):0);$i++){
|
||||||
|
|
||||||
$select = (($user==$users[$i]['id']) || in_array($users[$i]['id'],$check_permissions) ? "checked" : "");
|
$select = (($user==$users[$i]['id']) || in_array($users[$i]['id'],$check_permissions) ? "checked" : "");
|
||||||
$user_out .= "<input name=\"personen[]\" type=\"checkbox\" value=\"{$users[$i]['id']}\" $select>{$users[$i]['description']}<br>";
|
$user_out .= "<input name=\"personen[]\" type=\"checkbox\" value=\"{$users[$i]['id']}\" $select>{$users[$i]['description']}<br>";
|
||||||
|
@ -149,7 +149,7 @@ class Placetel {
|
|||||||
if($apikey!="")
|
if($apikey!="")
|
||||||
{
|
{
|
||||||
$result = json_decode($this->PlacetelAPI("getVoIPUsers"),true);
|
$result = json_decode($this->PlacetelAPI("getVoIPUsers"),true);
|
||||||
for($i=0;$i<count($result);$i++)
|
for($i=0;$i<(!empty($result)?count($result):0);$i++)
|
||||||
{
|
{
|
||||||
$this->app->Tpl->Add(ACCOUNTROW,"<tr><td>".$result[$i]['name']."</td><td>".$result[$i]['stype']."</td><td>".$result[$i]['uid']."</td></tr>");
|
$this->app->Tpl->Add(ACCOUNTROW,"<tr><td>".$result[$i]['name']."</td><td>".$result[$i]['stype']."</td><td>".$result[$i]['uid']."</td></tr>");
|
||||||
}
|
}
|
||||||
@ -180,7 +180,7 @@ class Placetel {
|
|||||||
// Set some options - we are passing in a useragent too here
|
// Set some options - we are passing in a useragent too here
|
||||||
curl_setopt_array($curl, array(
|
curl_setopt_array($curl, array(
|
||||||
CURLOPT_RETURNTRANSFER => 1,
|
CURLOPT_RETURNTRANSFER => 1,
|
||||||
CURLOPT_POST => count($fields),
|
CURLOPT_POST => (!empty($fields)?count($fields):0),
|
||||||
CURLOPT_POSTFIELDS => $fields_string,
|
CURLOPT_POSTFIELDS => $fields_string,
|
||||||
CURLOPT_URL => 'https://api.placetel.de/api/'.$request.'.json',
|
CURLOPT_URL => 'https://api.placetel.de/api/'.$request.'.json',
|
||||||
CURLOPT_USERAGENT => 'Codular Sample cURL Request'
|
CURLOPT_USERAGENT => 'Codular Sample cURL Request'
|
||||||
@ -203,7 +203,7 @@ class Placetel {
|
|||||||
if(!$target)
|
if(!$target)
|
||||||
{
|
{
|
||||||
$ida = explode('-',$this->app->Secure->GetGET('id'));
|
$ida = explode('-',$this->app->Secure->GetGET('id'));
|
||||||
if(count($ida) == 2)
|
if((!empty($ida)?count($ida):0) == 2)
|
||||||
{
|
{
|
||||||
$id = (int)$ida[1];
|
$id = (int)$ida[1];
|
||||||
switch($ida[0])
|
switch($ida[0])
|
||||||
@ -240,11 +240,11 @@ class Placetel {
|
|||||||
|
|
||||||
$tmp = explode(PHP_EOL,trim($accounts));
|
$tmp = explode(PHP_EOL,trim($accounts));
|
||||||
|
|
||||||
for($i=0;$i<count($tmp);$i++)
|
for($i=0;$i<(!empty($tmp)?count($tmp):0);$i++)
|
||||||
{
|
{
|
||||||
$subtmp = explode(':',trim($tmp[$i]));
|
$subtmp = explode(':',trim($tmp[$i]));
|
||||||
|
|
||||||
if(count($subtmp)>0)
|
if((!empty($subtmp)?count($subtmp):0)>0)
|
||||||
{
|
{
|
||||||
$subtmp[0] = trim($subtmp[0]);
|
$subtmp[0] = trim($subtmp[0]);
|
||||||
$subtmp[1] = trim($subtmp[1]);
|
$subtmp[1] = trim($subtmp[1]);
|
||||||
|
@ -166,7 +166,7 @@ class Projekt extends GenProjekt {
|
|||||||
|
|
||||||
$heading[] = 'Menü';
|
$heading[] = 'Menü';
|
||||||
|
|
||||||
$menucol = count($heading)-1;
|
$menucol = (!empty($heading)?count($heading):0)-1;
|
||||||
|
|
||||||
$width[] = '1%';
|
$width[] = '1%';
|
||||||
$findcols[] = 'p.id';
|
$findcols[] = 'p.id';
|
||||||
@ -577,7 +577,7 @@ class Projekt extends GenProjekt {
|
|||||||
|
|
||||||
$findcols[] = 'w.id';
|
$findcols[] = 'w.id';
|
||||||
|
|
||||||
$menucol = count($findcols)-1;
|
$menucol = (!empty($findcols)?count($findcols):0)-1;
|
||||||
|
|
||||||
$menu = '<input type="hidden" value="%value%">';
|
$menu = '<input type="hidden" value="%value%">';
|
||||||
|
|
||||||
@ -679,7 +679,7 @@ class Projekt extends GenProjekt {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
$parent = -1;
|
$parent = -1;
|
||||||
if(!empty($ret))$parent = count($ret)-1;
|
if(!empty($ret))$parent = (!empty($ret)?count($ret):0)-1;
|
||||||
$stueckliste = $this->app->DB->SelectArr("SELECT id, menge, artikel,stuecklistevonartikel FROM stueckliste WHERE stuecklistevonartikel = '$artikel'");
|
$stueckliste = $this->app->DB->SelectArr("SELECT id, menge, artikel,stuecklistevonartikel FROM stueckliste WHERE stuecklistevonartikel = '$artikel'");
|
||||||
if($stueckliste)
|
if($stueckliste)
|
||||||
{
|
{
|
||||||
@ -1453,7 +1453,7 @@ class Projekt extends GenProjekt {
|
|||||||
foreach($arbeitspakete as $paket)
|
foreach($arbeitspakete as $paket)
|
||||||
{
|
{
|
||||||
$i++;
|
$i++;
|
||||||
if($i < count($arbeitspakete))
|
if($i < (!empty($arbeitspakete)?count($arbeitspakete):0))
|
||||||
{
|
{
|
||||||
$tmp = null;
|
$tmp = null;
|
||||||
$ind = $this->getProjektArtikelBaum($tmp, 0, $id, $paket['id'],'',$ind);
|
$ind = $this->getProjektArtikelBaum($tmp, 0, $id, $paket['id'],'',$ind);
|
||||||
@ -1716,7 +1716,7 @@ class Projekt extends GenProjekt {
|
|||||||
$v['kosten_geplant'] = number_format($v['kosten_geplant'],2,',','.');
|
$v['kosten_geplant'] = number_format($v['kosten_geplant'],2,',','.');
|
||||||
|
|
||||||
}
|
}
|
||||||
$projekteindex = empty($projekte)?0:count($projekte);
|
$projekteindex = empty($projekte)?0:(!empty($projekte)?count($projekte):0);
|
||||||
|
|
||||||
// checken ob es so besser ist
|
// checken ob es so besser ist
|
||||||
//foreach($v as $v_key=>$v_value)
|
//foreach($v as $v_key=>$v_value)
|
||||||
@ -1732,7 +1732,7 @@ class Projekt extends GenProjekt {
|
|||||||
$oldgebucht_summiert = $gebucht_summiert;
|
$oldgebucht_summiert = $gebucht_summiert;
|
||||||
$oldzeit_summiert = $zeit_summiert;
|
$oldzeit_summiert = $zeit_summiert;
|
||||||
|
|
||||||
$anzahlteilprojekte = count($projekte);
|
$anzahlteilprojekte = (!empty($projekte)?count($projekte):0);
|
||||||
$liste = $this->getProjektBaum($projekte, $v['id'], $projekt, $v['nr'],
|
$liste = $this->getProjektBaum($projekte, $v['id'], $projekt, $v['nr'],
|
||||||
array($zeit_summiert,$gebucht_summiert, $kosten_summiert, $abgerechnet_summiert,$offen_summiert
|
array($zeit_summiert,$gebucht_summiert, $kosten_summiert, $abgerechnet_summiert,$offen_summiert
|
||||||
,$gesamt_zeit_ek_geplant,$gesamt_zeit_ek_gebucht,$gesamt_zeit_ek_offen
|
,$gesamt_zeit_ek_geplant,$gesamt_zeit_ek_gebucht,$gesamt_zeit_ek_offen
|
||||||
@ -1743,9 +1743,9 @@ class Projekt extends GenProjekt {
|
|||||||
,$gesamt_rohertrag_zeit_geplant,$gesamt_rohertrag_artikel_geplant,$gesamt_rohertrag_gesamt_geplant
|
,$gesamt_rohertrag_zeit_geplant,$gesamt_rohertrag_artikel_geplant,$gesamt_rohertrag_gesamt_geplant
|
||||||
), $onlynummertitel);
|
), $onlynummertitel);
|
||||||
|
|
||||||
if(count($projekte) == $anzahlteilprojekte)
|
if((!empty($projekte)?count($projekte):0) == $anzahlteilprojekte)
|
||||||
{
|
{
|
||||||
//$projekte[count($projekte)-1]['editierbar'] = true;
|
//$projekte[(!empty($projekte)?count($projekte):0)-1]['editierbar'] = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -1977,9 +1977,9 @@ class Projekt extends GenProjekt {
|
|||||||
$optionen = null;
|
$optionen = null;
|
||||||
$beza = explode('|', $bez);
|
$beza = explode('|', $bez);
|
||||||
$bez = trim($beza[0]);
|
$bez = trim($beza[0]);
|
||||||
if(count($beza) > 1)
|
if((!empty($beza)?count($beza):0) > 1)
|
||||||
{
|
{
|
||||||
for($inds = 1; $inds < count($beza); $inds++)$optionen[] = trim($beza[$inds]);
|
for($inds = 1; $inds < (!empty($beza)?count($beza):0); $inds++)$optionen[] = trim($beza[$inds]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(empty($bez))$bez = 'Freifeld '.$v['index'];
|
if(empty($bez))$bez = 'Freifeld '.$v['index'];
|
||||||
@ -2162,7 +2162,7 @@ class Projekt extends GenProjekt {
|
|||||||
$adresse = $this->app->DB->Select("SELECT kunde FROM projekt WHERE id='$id' LIMIT 1");
|
$adresse = $this->app->DB->Select("SELECT kunde FROM projekt WHERE id='$id' LIMIT 1");
|
||||||
|
|
||||||
// $lieferschein = $this-app->erp->CreateLieferschein($adresse);
|
// $lieferschein = $this-app->erp->CreateLieferschein($adresse);
|
||||||
for($i=0;$i<count($z_id);$i++)
|
for($i=0;$i<(!empty($z_id)?count($z_id):0);$i++)
|
||||||
{
|
{
|
||||||
$single_z_id = $z_id[$i];
|
$single_z_id = $z_id[$i];
|
||||||
//$dauer = $this->app->DB->Select("SELECT TIME_TO_SEC(TIMEDIFF(z.bis, z.von))/3600 AS Dauer FROM zeiterfassung z WHERE z.id='".$single_z_id."'");
|
//$dauer = $this->app->DB->Select("SELECT TIME_TO_SEC(TIMEDIFF(z.bis, z.von))/3600 AS Dauer FROM zeiterfassung z WHERE z.id='".$single_z_id."'");
|
||||||
@ -2184,7 +2184,7 @@ class Projekt extends GenProjekt {
|
|||||||
else
|
else
|
||||||
$options.="<option value=\"ohne\">Ohne</option>";
|
$options.="<option value=\"ohne\">Ohne</option>";
|
||||||
|
|
||||||
for($i=0;$i<count($tmp);$i++)
|
for($i=0;$i<(!empty($tmp)?count($tmp):0);$i++)
|
||||||
{
|
{
|
||||||
|
|
||||||
if($sid==$tmp[$i][id])$checked="selected"; else $checked="";
|
if($sid==$tmp[$i][id])$checked="selected"; else $checked="";
|
||||||
@ -3014,7 +3014,7 @@ class Projekt extends GenProjekt {
|
|||||||
if($abgerechnet!="")
|
if($abgerechnet!="")
|
||||||
{
|
{
|
||||||
$zid = $this->app->Secure->GetPOST("z_id");
|
$zid = $this->app->Secure->GetPOST("z_id");
|
||||||
for($i=0;$i<count($zid);$i++)
|
for($i=0;$i<(!empty($zid)?count($zid):0);$i++)
|
||||||
{
|
{
|
||||||
$zid_i = (int)$zid[$i];
|
$zid_i = (int)$zid[$i];
|
||||||
$this->app->DB->Update("UPDATE zeiterfassung SET ist_abgerechnet=1, abgerechnet=1 WHERE id='$zid_i' LIMIT 1");
|
$this->app->DB->Update("UPDATE zeiterfassung SET ist_abgerechnet=1, abgerechnet=1 WHERE id='$zid_i' LIMIT 1");
|
||||||
@ -3205,8 +3205,8 @@ class Projekt extends GenProjekt {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Schreibe Personen
|
// Schreibe Personen
|
||||||
if(is_numeric($event) && is_array($personen) && count($personen) && $mode!="delete" && $mode != "") {
|
if(is_numeric($event) && is_array($personen) && (!empty($personen)?count($personen):0) && $mode!="delete" && $mode != "") {
|
||||||
for($p=0;$p<count($personen);$p++)
|
for($p=0;$p<(!empty($personen)?count($personen):0);$p++)
|
||||||
$this->app->DB->Insert("INSERT INTO kalender_user (event, userid) VALUES ('$event', '{$personen[$p]}')");
|
$this->app->DB->Insert("INSERT INTO kalender_user (event, userid) VALUES ('$event', '{$personen[$p]}')");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -3239,7 +3239,7 @@ class Projekt extends GenProjekt {
|
|||||||
}
|
}
|
||||||
$user = $this->app->User->GetID();
|
$user = $this->app->User->GetID();
|
||||||
$users = $this->app->DB->SelectArr("SELECT u.id, a.name as description FROM user u LEFT JOIN adresse a ON a.id=u.adresse WHERE u.activ='1' AND u.kalender_ausblenden!=1 ORDER BY u.username");
|
$users = $this->app->DB->SelectArr("SELECT u.id, a.name as description FROM user u LEFT JOIN adresse a ON a.id=u.adresse WHERE u.activ='1' AND u.kalender_ausblenden!=1 ORDER BY u.username");
|
||||||
for($i=0; $i<count($users);$i++){
|
for($i=0; $i<(!empty($users)?count($users):0);$i++){
|
||||||
$user_out .= "<option value=\"{$users[$i]['id']}\" $select>{$users[$i]['description']}</option>";
|
$user_out .= "<option value=\"{$users[$i]['id']}\" $select>{$users[$i]['description']}</option>";
|
||||||
}
|
}
|
||||||
$this->app->Tpl->Set('PERSONEN', $user_out);
|
$this->app->Tpl->Set('PERSONEN', $user_out);
|
||||||
@ -3326,7 +3326,7 @@ class Projekt extends GenProjekt {
|
|||||||
$freifelder[$value['name']] = $value['wert'];
|
$freifelder[$value['name']] = $value['wert'];
|
||||||
}
|
}
|
||||||
|
|
||||||
for ($i=1;$i<=count($freifelder);$i++) {
|
for ($i=1;$i<=(!empty($freifelder)?count($freifelder):0);$i++) {
|
||||||
if($freifelder['projektfreifeld'.$i] === ''){
|
if($freifelder['projektfreifeld'.$i] === ''){
|
||||||
$freifelder['projektfreifeld'.$i] = 'Freifeld '.$i;
|
$freifelder['projektfreifeld'.$i] = 'Freifeld '.$i;
|
||||||
}
|
}
|
||||||
@ -3551,7 +3551,7 @@ class Projekt extends GenProjekt {
|
|||||||
{
|
{
|
||||||
$doppelteids = $this->app->Secure->GetGET("id");
|
$doppelteids = $this->app->Secure->GetGET("id");
|
||||||
$ids = preg_split('/\-/',$doppelteids);
|
$ids = preg_split('/\-/',$doppelteids);
|
||||||
if(count($ids) > 1)
|
if((!empty($ids)?count($ids):0) > 1)
|
||||||
{
|
{
|
||||||
$typ = (int)$ids[0];
|
$typ = (int)$ids[0];
|
||||||
$id = (int)$ids[1];
|
$id = (int)$ids[1];
|
||||||
|
@ -97,7 +97,7 @@ class Prozessstarter extends GenProzessstarter {
|
|||||||
$menu .= '</tr>';
|
$menu .= '</tr>';
|
||||||
$menu .= '</table>';
|
$menu .= '</table>';
|
||||||
$moreinfo = true;
|
$moreinfo = true;
|
||||||
$menucol = count($heading) - 1;
|
$menucol = (!empty($heading)?count($heading):0) - 1;
|
||||||
|
|
||||||
// SQL statement
|
// SQL statement
|
||||||
$sql = "SELECT SQL_CALC_FOUND_ROWS p.id,
|
$sql = "SELECT SQL_CALC_FOUND_ROWS p.id,
|
||||||
@ -239,7 +239,7 @@ class Prozessstarter extends GenProzessstarter {
|
|||||||
if(empty($parmeterList)) {
|
if(empty($parmeterList)) {
|
||||||
return '';
|
return '';
|
||||||
}
|
}
|
||||||
if(count($parmeterList) === 1) {
|
if((!empty($parmeterList)?count($parmeterList):0) === 1) {
|
||||||
return 'Der Prozessstarter '
|
return 'Der Prozessstarter '
|
||||||
.implode(', ', $parmeterList).' läuft häufiger als empfohlen';
|
.implode(', ', $parmeterList).' läuft häufiger als empfohlen';
|
||||||
}
|
}
|
||||||
@ -362,19 +362,19 @@ class Prozessstarter extends GenProzessstarter {
|
|||||||
$cronjobIntervals = [];
|
$cronjobIntervals = [];
|
||||||
foreach($arr as $rowIndex => $row) {
|
foreach($arr as $rowIndex => $row) {
|
||||||
if($row[$fieldValue] > 0) {
|
if($row[$fieldValue] > 0) {
|
||||||
if(empty($cronjobIntervals) || empty($cronjobIntervals[count($cronjobIntervals) - 1])) {
|
if(empty($cronjobIntervals) || empty($cronjobIntervals[(!empty($cronjobIntervals)?count($cronjobIntervals):0) - 1])) {
|
||||||
$cronjobIntervals[] = ['start' => $this->roundDate($row[$dateField]), 'startexact'=>$row[$dateField]];
|
$cronjobIntervals[] = ['start' => $this->roundDate($row[$dateField]), 'startexact'=>$row[$dateField]];
|
||||||
}
|
}
|
||||||
$cronjobIntervals[count($cronjobIntervals) - 1]['end'] = $this->roundDate($row[$dateField], $interval->i);
|
$cronjobIntervals[(!empty($cronjobIntervals)?count($cronjobIntervals):0) - 1]['end'] = $this->roundDate($row[$dateField], $interval->i);
|
||||||
$cronjobIntervals[count($cronjobIntervals) - 1]['endexact'] = $row[$dateField];
|
$cronjobIntervals[(!empty($cronjobIntervals)?count($cronjobIntervals):0) - 1]['endexact'] = $row[$dateField];
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
if(empty($cronjobIntervals)) {
|
if(empty($cronjobIntervals)) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if(!empty($cronjobIntervals[count($cronjobIntervals) - 1])) {
|
if(!empty($cronjobIntervals[(!empty($cronjobIntervals)?count($cronjobIntervals):0) - 1])) {
|
||||||
$cronjobIntervals[count($cronjobIntervals) - 1]['end'] = $this->roundDate($row[$dateField], $interval->i);
|
$cronjobIntervals[(!empty($cronjobIntervals)?count($cronjobIntervals):0) - 1]['end'] = $this->roundDate($row[$dateField], $interval->i);
|
||||||
$cronjobIntervals[count($cronjobIntervals) - 1]['endexact'] = $row[$dateField];
|
$cronjobIntervals[(!empty($cronjobIntervals)?count($cronjobIntervals):0) - 1]['endexact'] = $row[$dateField];
|
||||||
}
|
}
|
||||||
$cronjobIntervals[] = [];
|
$cronjobIntervals[] = [];
|
||||||
}
|
}
|
||||||
|
@ -718,11 +718,11 @@ class Rechnung extends GenRechnung
|
|||||||
|
|
||||||
if(!empty($gutschrift))
|
if(!empty($gutschrift))
|
||||||
{
|
{
|
||||||
$cgutschrift = !empty(count($gutschrift))?:0;
|
$cgutschrift = !empty((!empty($gutschrift)?count($gutschrift):0))?:0;
|
||||||
for($li=0;$li<$cgutschrift;$li++)
|
for($li=0;$li<$cgutschrift;$li++)
|
||||||
{
|
{
|
||||||
$this->app->Tpl->Add('GUTSCHRIFT',$gutschrift[$li]['gutschrift']);
|
$this->app->Tpl->Add('GUTSCHRIFT',$gutschrift[$li]['gutschrift']);
|
||||||
if($li<count($gutschrift)){
|
if($li<(!empty($gutschrift)?count($gutschrift):0)){
|
||||||
$this->app->Tpl->Add('GUTSCHRIFT', "<br>");
|
$this->app->Tpl->Add('GUTSCHRIFT', "<br>");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -893,7 +893,7 @@ class Rechnung extends GenRechnung
|
|||||||
|
|
||||||
if (!is_null($gutschrift)) {
|
if (!is_null($gutschrift)) {
|
||||||
|
|
||||||
if(count($gutschrift) > 0)
|
if((!empty($gutschrift)?count($gutschrift):0) > 0)
|
||||||
$this->app->Tpl->Add('ZAHLUNGEN',"<div class=\"info\">Zu dieser Rechnung existiert eine Gutschrift!</div>");
|
$this->app->Tpl->Add('ZAHLUNGEN',"<div class=\"info\">Zu dieser Rechnung existiert eine Gutschrift!</div>");
|
||||||
else {
|
else {
|
||||||
|
|
||||||
@ -2233,7 +2233,7 @@ class Rechnung extends GenRechnung
|
|||||||
$tmpfile[] = $Brief->displayTMP();
|
$tmpfile[] = $Brief->displayTMP();
|
||||||
}
|
}
|
||||||
|
|
||||||
if(count($tmpfile) > 0) {
|
if((!empty($tmpfile)?count($tmpfile):0) > 0) {
|
||||||
try {
|
try {
|
||||||
/** @var PdfMerger $pdfMerger */
|
/** @var PdfMerger $pdfMerger */
|
||||||
$pdfMerger = $this->app->Container->get('PdfMerger');
|
$pdfMerger = $this->app->Container->get('PdfMerger');
|
||||||
|
@ -287,7 +287,7 @@ class Report
|
|||||||
$heading[] = '';
|
$heading[] = '';
|
||||||
$width[] = '1%';
|
$width[] = '1%';
|
||||||
|
|
||||||
if (count($sumcolumns)) {
|
if ((!empty($sumcolumns)?count($sumcolumns):0)) {
|
||||||
$sumcol = $sumcolumns;
|
$sumcol = $sumcolumns;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -319,7 +319,7 @@ class Report
|
|||||||
|
|
||||||
$queryString = $service->resolveParameters($report);
|
$queryString = $service->resolveParameters($report);
|
||||||
//fix possible semicolon
|
//fix possible semicolon
|
||||||
if (preg_match('/^([^;]+)(\s*;\s*)$/', $queryString, $parts) && count($parts) > 1) {
|
if (preg_match('/^([^;]+)(\s*;\s*)$/', $queryString, $parts) && (!empty($parts)?count($parts):0) > 1) {
|
||||||
$queryString = $parts[1];
|
$queryString = $parts[1];
|
||||||
}
|
}
|
||||||
if (!$service->isSqlStatementAllowed($queryString)) {
|
if (!$service->isSqlStatementAllowed($queryString)) {
|
||||||
@ -3002,7 +3002,7 @@ class Report
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
$nameParts = explode(' ', $apiName);
|
$nameParts = explode(' ', $apiName);
|
||||||
if (count($nameParts) < 2) {
|
if ((!empty($nameParts)?count($nameParts):0) < 2) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
$id = $nameParts[0];
|
$id = $nameParts[0];
|
||||||
@ -3044,7 +3044,7 @@ class Report
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
$nameParts = explode(' ', $projectName);
|
$nameParts = explode(' ', $projectName);
|
||||||
if (count($nameParts) < 2) {
|
if ((!empty($nameParts)?count($nameParts):0) < 2) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
$shortName = $nameParts[0];
|
$shortName = $nameParts[0];
|
||||||
@ -3138,7 +3138,7 @@ class Report
|
|||||||
$importPaths[] = sprintf('%s/%s', $importDir, $filename);
|
$importPaths[] = sprintf('%s/%s', $importDir, $filename);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (count($importPaths) === 0) {
|
if ((!empty($importPaths)?count($importPaths):0) === 0) {
|
||||||
$this->app->erp->LogFile('No files available for import.', $importDir);
|
$this->app->erp->LogFile('No files available for import.', $importDir);
|
||||||
|
|
||||||
return;
|
return;
|
||||||
@ -3158,7 +3158,7 @@ class Report
|
|||||||
$content = file_get_contents($filePath);
|
$content = file_get_contents($filePath);
|
||||||
$data = json_decode($content, true);
|
$data = json_decode($content, true);
|
||||||
$errors = $importer->findJsonStructureErrors($data);
|
$errors = $importer->findJsonStructureErrors($data);
|
||||||
if (count($errors) > 0) {
|
if ((!empty($errors)?count($errors):0) > 0) {
|
||||||
$this->app->erp->Logfile(
|
$this->app->erp->Logfile(
|
||||||
sprintf(
|
sprintf(
|
||||||
'Json parse error in File %s.', $filePath),
|
'Json parse error in File %s.', $filePath),
|
||||||
|
@ -320,7 +320,7 @@ class Shopexport
|
|||||||
$methodName = 'RemoteConnection';
|
$methodName = 'RemoteConnection';
|
||||||
$r = new ReflectionMethod($className, $methodName);
|
$r = new ReflectionMethod($className, $methodName);
|
||||||
$params = $r->getParameters();
|
$params = $r->getParameters();
|
||||||
$anzargs = count($params);
|
$anzargs = (!empty($params)?count($params):0);
|
||||||
if($anzargs > 1) {
|
if($anzargs > 1) {
|
||||||
$pageContents = $this->app->remote->RemoteConnection($id, true);
|
$pageContents = $this->app->remote->RemoteConnection($id, true);
|
||||||
}
|
}
|
||||||
@ -512,7 +512,7 @@ class Shopexport
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
//print_r($checkarray);
|
//print_r($checkarray);
|
||||||
if(is_array($checkarray) && count($checkarray)>0) {
|
if(is_array($checkarray) && (!empty($checkarray)?count($checkarray):0)>0) {
|
||||||
$delete=0;
|
$delete=0;
|
||||||
foreach($checkarray as $key=>$value) {
|
foreach($checkarray as $key=>$value) {
|
||||||
if($checkarray[$key]!=='mark' && $checkarray[$key]!=='delete' && $checkarray[$key]!=='update') {
|
if($checkarray[$key]!=='mark' && $checkarray[$key]!=='delete' && $checkarray[$key]!=='update') {
|
||||||
|
@ -448,12 +448,12 @@ class Shopimport
|
|||||||
{
|
{
|
||||||
$anz = 0;
|
$anz = 0;
|
||||||
$fp = $this->app->erp->ProzessLock('shopimport_alle');
|
$fp = $this->app->erp->ProzessLock('shopimport_alle');
|
||||||
$cshops = count($shops);
|
$cshops = (!empty($shops)?count($shops):0);
|
||||||
for($i=0;$i<$cshops-1;$i++)
|
for($i=0;$i<$cshops-1;$i++)
|
||||||
{
|
{
|
||||||
$anz += $this->ShopimportImport($shops[$i]['id'],$anz,true);
|
$anz += $this->ShopimportImport($shops[$i]['id'],$anz,true);
|
||||||
}
|
}
|
||||||
$lastshop=$shops[count($shops)-1]['id'];
|
$lastshop=$shops[(!empty($shops)?count($shops):0)-1]['id'];
|
||||||
$this->app->erp->ProzessUnlock($fp);
|
$this->app->erp->ProzessUnlock($fp);
|
||||||
}
|
}
|
||||||
if($lastshop && is_numeric($lastshop)){
|
if($lastshop && is_numeric($lastshop)){
|
||||||
@ -1256,7 +1256,7 @@ class Shopimport
|
|||||||
{
|
{
|
||||||
$maxtime = false;
|
$maxtime = false;
|
||||||
$mintime = false;
|
$mintime = false;
|
||||||
$gesamtanzahl = count($result);
|
$gesamtanzahl = (!empty($result)?count($result):0);
|
||||||
for($i = 0; $i < $gesamtanzahl; $i++)
|
for($i = 0; $i < $gesamtanzahl; $i++)
|
||||||
{
|
{
|
||||||
$projekt = $this->app->DB->Select("SELECT projekt FROM shopexport WHERE id = '$id' LIMIT 1");
|
$projekt = $this->app->DB->Select("SELECT projekt FROM shopexport WHERE id = '$id' LIMIT 1");
|
||||||
@ -1754,7 +1754,7 @@ class Shopimport
|
|||||||
}
|
}
|
||||||
|
|
||||||
$arr = $this->app->DB->SelectArr("SELECT sa.*, p.abkuerzung FROM shopimport_auftraege sa left join projekt p on sa.projekt = p.id WHERE sa.imported='0' AND sa.trash='0' $where ORDER BY sa.logdatei LIMIT 100");
|
$arr = $this->app->DB->SelectArr("SELECT sa.*, p.abkuerzung FROM shopimport_auftraege sa left join projekt p on sa.projekt = p.id WHERE sa.imported='0' AND sa.trash='0' $where ORDER BY sa.logdatei LIMIT 100");
|
||||||
if(is_array($arr) && count($arr) > 0)
|
if(is_array($arr) && (!empty($arr)?count($arr):0) > 0)
|
||||||
{
|
{
|
||||||
|
|
||||||
//Alte Auftraege prüfen
|
//Alte Auftraege prüfen
|
||||||
|
@ -945,7 +945,7 @@ class Shopimporter_Shopify extends ShopimporterBase
|
|||||||
foreach ($tmp[$i]['artikel_varianten'][0]['eigenschaften'] as $ekey => $evalue) {
|
foreach ($tmp[$i]['artikel_varianten'][0]['eigenschaften'] as $ekey => $evalue) {
|
||||||
$optionsteile[] = $evalue['name'];
|
$optionsteile[] = $evalue['name'];
|
||||||
}
|
}
|
||||||
if(count($optionsteile) > 0){
|
if((!empty($optionsteile)?count($optionsteile):0) > 0){
|
||||||
$optionsname = implode(' | ', $optionsteile);
|
$optionsname = implode(' | ', $optionsteile);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1163,7 +1163,7 @@ class Shopimporter_Shopify extends ShopimporterBase
|
|||||||
foreach ($value['eigenschaften'] as $ekey => $evalue){
|
foreach ($value['eigenschaften'] as $ekey => $evalue){
|
||||||
$eigenschaftenwerte[] = $evalue['values'];
|
$eigenschaftenwerte[] = $evalue['values'];
|
||||||
}
|
}
|
||||||
if(count($eigenschaftenwerte) > 0){
|
if((!empty($eigenschaftenwerte)?count($eigenschaftenwerte):0) > 0){
|
||||||
$titel = implode(' | ', $eigenschaftenwerte);
|
$titel = implode(' | ', $eigenschaftenwerte);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -2496,10 +2496,10 @@ class Shopimporter_Shopify extends ShopimporterBase
|
|||||||
foreach($result['orders'][$i]['line_items'][$ii]['discount_allocations'] as $discountAll) {
|
foreach($result['orders'][$i]['line_items'][$ii]['discount_allocations'] as $discountAll) {
|
||||||
if(isset($discountAll['discount_application_index']) && $discountAll['discount_application_index'] == $linePercentageDiscountsKey) {
|
if(isset($discountAll['discount_application_index']) && $discountAll['discount_application_index'] == $linePercentageDiscountsKey) {
|
||||||
$rabattItemPrice = -(!empty($discountAll['amount_set']['shop_money']['amount'])?$discountAll['amount_set']['shop_money']['amount']:$discountAll['amount']);
|
$rabattItemPrice = -(!empty($discountAll['amount_set']['shop_money']['amount'])?$discountAll['amount_set']['shop_money']['amount']:$discountAll['amount']);
|
||||||
if(isset($articlearray[count($articlearray) -1]['price_netto'])
|
if(isset($articlearray[(!empty($articlearray)?count($articlearray):0) -1]['price_netto'])
|
||||||
&& $articlearray[count($articlearray) -1]['price_netto'] == -$rabattItemPrice) {
|
&& $articlearray[(!empty($articlearray)?count($articlearray):0) -1]['price_netto'] == -$rabattItemPrice) {
|
||||||
unset($articlearray[count($articlearray) -1]['price_netto']);
|
unset($articlearray[(!empty($articlearray)?count($articlearray):0) -1]['price_netto']);
|
||||||
$articlearray[count($articlearray) -1]['price'] = abs($rabattItemPrice);
|
$articlearray[(!empty($articlearray)?count($articlearray):0) -1]['price'] = abs($rabattItemPrice);
|
||||||
}
|
}
|
||||||
$articlearray[] = array(
|
$articlearray[] = array(
|
||||||
'articleid'=> $linePercentageDiscountsValue['nummer'],
|
'articleid'=> $linePercentageDiscountsValue['nummer'],
|
||||||
@ -2516,7 +2516,7 @@ class Shopimporter_Shopify extends ShopimporterBase
|
|||||||
0
|
0
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
$itemKey = count($articlearray) - 2;
|
$itemKey = (!empty($articlearray)?count($articlearray):0) - 2;
|
||||||
if(!empty($articlearray[$itemKey]['price_netto']) && round(-$rabattItemPrice, 2)
|
if(!empty($articlearray[$itemKey]['price_netto']) && round(-$rabattItemPrice, 2)
|
||||||
=== round($articlearray[$itemKey]['price_netto'] * $articlearray[$itemKey]['quantity'], 2)
|
=== round($articlearray[$itemKey]['price_netto'] * $articlearray[$itemKey]['quantity'], 2)
|
||||||
) {
|
) {
|
||||||
@ -2539,7 +2539,7 @@ class Shopimporter_Shopify extends ShopimporterBase
|
|||||||
$warenkorb['rabattnetto'] -= abs($rabattItemPrice);
|
$warenkorb['rabattnetto'] -= abs($rabattItemPrice);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$lastKey = count($articlearray) - 1;
|
$lastKey = (!empty($articlearray)?count($articlearray):0) - 1;
|
||||||
if($articlearray[$lastKey]['steuersatz'] == 0
|
if($articlearray[$lastKey]['steuersatz'] == 0
|
||||||
&& !empty($articlearray[$lastKey]['price'])
|
&& !empty($articlearray[$lastKey]['price'])
|
||||||
&& !isset($articlearray[$lastKey]['price_netto'])) {
|
&& !isset($articlearray[$lastKey]['price_netto'])) {
|
||||||
@ -2684,14 +2684,14 @@ class Shopimporter_Shopify extends ShopimporterBase
|
|||||||
$summegesamt += (isset($value['price_netto'])?$value['price_netto']:$value['price'])*$value['quantity'];
|
$summegesamt += (isset($value['price_netto'])?$value['price_netto']:$value['price'])*$value['quantity'];
|
||||||
}
|
}
|
||||||
|
|
||||||
if(count($steuergruppen) > 1){
|
if((!empty($steuergruppen)?count($steuergruppen):0) > 1){
|
||||||
if(!empty($discount_applications_absolute) && count($discount_applications_absolute) === 1 && round(-$discount_applications_absolute_sum,2) == round($warenkorb['rabattnetto'],2)){
|
if(!empty($discount_applications_absolute) && (!empty($discount_applications_absolute)?count($discount_applications_absolute):0) === 1 && round(-$discount_applications_absolute_sum,2) == round($warenkorb['rabattnetto'],2)){
|
||||||
$absolutekey = array_keys($discount_applications_absolute);
|
$absolutekey = array_keys($discount_applications_absolute);
|
||||||
$absolutekey = reset($absolutekey);
|
$absolutekey = reset($absolutekey);
|
||||||
$warenkorb['rabattbrutto'] = $warenkorb['rabattnetto'];
|
$warenkorb['rabattbrutto'] = $warenkorb['rabattnetto'];
|
||||||
$warenkorb['rabattsteuer'] = $absolutekey;
|
$warenkorb['rabattsteuer'] = $absolutekey;
|
||||||
unset($warenkorb['rabattnetto']);
|
unset($warenkorb['rabattnetto']);
|
||||||
}elseif(!empty($discount_applications_absolute) && count($discount_applications_absolute) > 1 && round(-$discount_applications_absolute_sum,2) == round($warenkorb['rabattnetto'],2)){
|
}elseif(!empty($discount_applications_absolute) && (!empty($discount_applications_absolute)?count($discount_applications_absolute):0) > 1 && round(-$discount_applications_absolute_sum,2) == round($warenkorb['rabattnetto'],2)){
|
||||||
$rabattartikelid = $this->app->DB->Select("SELECT artikelrabatt FROM shopexport WHERE id='$this->shopid' LIMIT 1");
|
$rabattartikelid = $this->app->DB->Select("SELECT artikelrabatt FROM shopexport WHERE id='$this->shopid' LIMIT 1");
|
||||||
$rabattartikelnummer = $this->app->DB->Select("SELECT nummer FROM artikel WHERE id='$rabattartikelid' LIMIT 1");
|
$rabattartikelnummer = $this->app->DB->Select("SELECT nummer FROM artikel WHERE id='$rabattartikelid' LIMIT 1");
|
||||||
foreach($discount_applications_absolute as $steuersatz => $value)
|
foreach($discount_applications_absolute as $steuersatz => $value)
|
||||||
@ -2716,8 +2716,8 @@ class Shopimporter_Shopify extends ShopimporterBase
|
|||||||
}
|
}
|
||||||
if(is_numeric($steuersatz))
|
if(is_numeric($steuersatz))
|
||||||
{
|
{
|
||||||
$articlearray[count($articlearray)-1]['steuersatz'] = $steuersatz;
|
$articlearray[(!empty($articlearray)?count($articlearray):0)-1]['steuersatz'] = $steuersatz;
|
||||||
$articlearray[count($articlearray)-1]['price_netto'] = $articlearray[count($articlearray)-1]['price'] / (1+$steuersatz/100);
|
$articlearray[(!empty($articlearray)?(!empty($articlearray)?count($articlearray):0):0)-1]['price_netto'] = $articlearray[count($articlearray)-1]['price'] / (1+$steuersatz/100);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
unset($warenkorb['rabattnetto']);
|
unset($warenkorb['rabattnetto']);
|
||||||
@ -2749,8 +2749,8 @@ class Shopimporter_Shopify extends ShopimporterBase
|
|||||||
}
|
}
|
||||||
if(is_numeric($steuersatz))
|
if(is_numeric($steuersatz))
|
||||||
{
|
{
|
||||||
$articlearray[count($articlearray)-1]['steuersatz'] = $steuersatz;
|
$articlearray[(!empty($articlearray)?count($articlearray):0)-1]['steuersatz'] = $steuersatz;
|
||||||
$articlearray[count($articlearray)-1]['price_netto'] = $articlearray[count($articlearray)-1]['price'] / (1+$steuersatz/100);
|
$articlearray[(!empty($articlearray)?(!empty($articlearray)?count($articlearray):0):0)-1]['price_netto'] = $articlearray[count($articlearray)-1]['price'] / (1+$steuersatz/100);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}else{
|
}else{
|
||||||
@ -2812,7 +2812,7 @@ class Shopimporter_Shopify extends ShopimporterBase
|
|||||||
$warenkorb['steuerfrei']=1;
|
$warenkorb['steuerfrei']=1;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(count($steuersaetze) === 1)
|
if((!empty($steuersaetze)?count($steuersaetze):0) === 1)
|
||||||
{
|
{
|
||||||
$steuersaetze = array_keys($steuersaetze);
|
$steuersaetze = array_keys($steuersaetze);
|
||||||
$steuersaetze = reset($steuersaetze);
|
$steuersaetze = reset($steuersaetze);
|
||||||
@ -2822,7 +2822,7 @@ class Shopimporter_Shopify extends ShopimporterBase
|
|||||||
}elseif($steuersaetze <= 10 && $steuersaetze > 0){
|
}elseif($steuersaetze <= 10 && $steuersaetze > 0){
|
||||||
$warenkorb['umsatzsteuer_ermassigt'] = $steuersaetze;
|
$warenkorb['umsatzsteuer_ermassigt'] = $steuersaetze;
|
||||||
}
|
}
|
||||||
}elseif(count($steuersaetze) === 2)
|
}elseif((!empty($steuersaetze)?count($steuersaetze):0) === 2)
|
||||||
{
|
{
|
||||||
$steuersaetze = array_keys($steuersaetze);
|
$steuersaetze = array_keys($steuersaetze);
|
||||||
if($steuersaetze[0] > 0 && $steuersaetze[1] > 0 && $steuersaetze[0] > $steuersaetze[1])
|
if($steuersaetze[0] > 0 && $steuersaetze[1] > 0 && $steuersaetze[0] > $steuersaetze[1])
|
||||||
@ -2855,9 +2855,9 @@ class Shopimporter_Shopify extends ShopimporterBase
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!empty($steuergruppen) && count($steuergruppen) === 1 && empty($warenkorb['rabattsteuer']) && !empty($warenkorb['rabattbrutto']) && empty($warenkorb['rabattnetto']))
|
if(!empty($steuergruppen) && (!empty($steuergruppen)?count($steuergruppen):0) === 1 && empty($warenkorb['rabattsteuer']) && !empty($warenkorb['rabattbrutto']) && empty($warenkorb['rabattnetto']))
|
||||||
{
|
{
|
||||||
if(!empty($discount_applications_percent) && count($discount_applications_percent) === 1){
|
if(!empty($discount_applications_percent) && (!empty($discount_applications_percent)?count($discount_applications_percent):0) === 1){
|
||||||
foreach($discount_applications_percent as $tax_percent => $prices)
|
foreach($discount_applications_percent as $tax_percent => $prices)
|
||||||
{
|
{
|
||||||
if(is_numeric($tax_percent)){
|
if(is_numeric($tax_percent)){
|
||||||
@ -2865,7 +2865,7 @@ class Shopimporter_Shopify extends ShopimporterBase
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}elseif(!empty($discount_applications_absolute) && count($discount_applications_absolute) === 1)
|
}elseif(!empty($discount_applications_absolute) && (!empty($discount_applications_absolute)?count($discount_applications_absolute):0) === 1)
|
||||||
{
|
{
|
||||||
foreach($discount_applications_absolute as $tax_percent => $prices)
|
foreach($discount_applications_absolute as $tax_percent => $prices)
|
||||||
{
|
{
|
||||||
@ -2879,7 +2879,7 @@ class Shopimporter_Shopify extends ShopimporterBase
|
|||||||
|
|
||||||
if($this->autofullfilltax && empty($warenkorb['versandkostennetto']) && !empty($warenkorb['versandkostenbrutto']))
|
if($this->autofullfilltax && empty($warenkorb['versandkostennetto']) && !empty($warenkorb['versandkostenbrutto']))
|
||||||
{
|
{
|
||||||
if(is_array($steuersaetze) && count($steuersaetze) > 1){
|
if(is_array($steuersaetze) && (!empty($steuersaetze)?count($steuersaetze):0) > 1){
|
||||||
$itemtaxes = [];
|
$itemtaxes = [];
|
||||||
foreach ($articlearray as $value) {
|
foreach ($articlearray as $value) {
|
||||||
if(!empty($value['steuersatz']) && $value['steuersatz']){
|
if(!empty($value['steuersatz']) && $value['steuersatz']){
|
||||||
@ -2891,7 +2891,7 @@ class Shopimporter_Shopify extends ShopimporterBase
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(count($itemtaxes) > 1){
|
if((!empty($itemtaxes)?count($itemtaxes):0) > 1){
|
||||||
arsort($itemtaxes);
|
arsort($itemtaxes);
|
||||||
$itemtaxes = array_keys($itemtaxes);
|
$itemtaxes = array_keys($itemtaxes);
|
||||||
$itemtaxes = reset($itemtaxes);
|
$itemtaxes = reset($itemtaxes);
|
||||||
@ -3397,7 +3397,7 @@ class Shopimporter_Shopify extends ShopimporterBase
|
|||||||
if(isset($options[''])){
|
if(isset($options[''])){
|
||||||
unset($options['']);
|
unset($options['']);
|
||||||
}
|
}
|
||||||
if(count($options) === 1) {
|
if((!empty($options)?count($options):0) === 1) {
|
||||||
$options = array_keys($options);
|
$options = array_keys($options);
|
||||||
$data['fulfillment']['location_id'] = reset($options);
|
$data['fulfillment']['location_id'] = reset($options);
|
||||||
}
|
}
|
||||||
@ -3896,7 +3896,7 @@ class Shopimporter_Shopify extends ShopimporterBase
|
|||||||
]
|
]
|
||||||
];
|
];
|
||||||
|
|
||||||
if(count($locations) > 2) {
|
if((!empty($locations)?count($locations):0) > 2) {
|
||||||
$page['form'][] = [
|
$page['form'][] = [
|
||||||
'id' => 0,
|
'id' => 0,
|
||||||
'name' => 'exportArticlesGroup',
|
'name' => 'exportArticlesGroup',
|
||||||
|
@ -183,7 +183,7 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
JOIN gruppen g ON ar.parameter = g.id
|
JOIN gruppen g ON ar.parameter = g.id
|
||||||
WHERE ar.adresse = '$adressId' AND ar.subjekt = 'Mitglied' AND ar.objekt = 'Gruppe'");
|
WHERE ar.adresse = '$adressId' AND ar.subjekt = 'Mitglied' AND ar.objekt = 'Gruppe'");
|
||||||
|
|
||||||
if(count($gruppen)>0){
|
if((!empty($gruppen)?count($gruppen):0)>0){
|
||||||
foreach ($gruppen as $key => $value) {
|
foreach ($gruppen as $key => $value) {
|
||||||
$gruppenfilter = 'filter[0][property]=key&filter[0][expression]==&filter[0][value]='.$value['kennziffer'];
|
$gruppenfilter = 'filter[0][property]=key&filter[0][expression]==&filter[0][value]='.$value['kennziffer'];
|
||||||
$gruppenresult = $this->adapter->get('customerGroups',[],$gruppenfilter);
|
$gruppenresult = $this->adapter->get('customerGroups',[],$gruppenfilter);
|
||||||
@ -582,7 +582,7 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
public function ImportPartnerList()
|
public function ImportPartnerList()
|
||||||
{
|
{
|
||||||
$tmp = $this->CatchRemoteCommand('data');
|
$tmp = $this->CatchRemoteCommand('data');
|
||||||
if(count($tmp) > 0)
|
if((!empty($tmp)?count($tmp):0) > 0)
|
||||||
{
|
{
|
||||||
foreach($tmp as $key=>$value)
|
foreach($tmp as $key=>$value)
|
||||||
{
|
{
|
||||||
@ -648,7 +648,7 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
$staffelpreise[] = array('ab_menge'=>$staffelpreis['from'], 'preis'=>$staffelpreis['price'], 'brutto'=>$staffelpreis['customerGroup']['taxInput']);
|
$staffelpreise[] = array('ab_menge'=>$staffelpreis['from'], 'preis'=>$staffelpreis['price'], 'brutto'=>$staffelpreis['customerGroup']['taxInput']);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(count($staffelpreise) >1){
|
if((!empty($staffelpreise)?count($staffelpreise):0) >1){
|
||||||
$data['staffelpreise'] = $staffelpreise;
|
$data['staffelpreise'] = $staffelpreise;
|
||||||
}
|
}
|
||||||
$data['artikelnummerausshop'] = $result['data']['mainDetail']['number'];
|
$data['artikelnummerausshop'] = $result['data']['mainDetail']['number'];
|
||||||
@ -826,28 +826,28 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
}
|
}
|
||||||
|
|
||||||
$arrayOfArticles[] = $data;
|
$arrayOfArticles[] = $data;
|
||||||
unset($arrayOfArticles[count($arrayOfArticles)-1]['pseudopreis']);
|
unset($arrayOfArticles[(!empty($arrayOfArticles)?count($arrayOfArticles):0)-1]['pseudopreis']);
|
||||||
$arrayOfArticles[count($arrayOfArticles)-1]['nummer'] = $vdetail['number'];
|
$arrayOfArticles[(!empty($arrayOfArticles)?count($arrayOfArticles):0)-1]['nummer'] = $vdetail['number'];
|
||||||
if(!empty($vdetail['number']))
|
if(!empty($vdetail['number']))
|
||||||
{
|
{
|
||||||
$arrayOfArticles[count($arrayOfArticles)-1]['artikelnummerausshop'] = $vdetail['number'];
|
$arrayOfArticles[(!empty($arrayOfArticles)?count($arrayOfArticles):0)-1]['artikelnummerausshop'] = $vdetail['number'];
|
||||||
}
|
}
|
||||||
$arrayOfArticles[count($arrayOfArticles)-1]['name'] = $arrayOfArticles[0]['name'];
|
$arrayOfArticles[(!empty($arrayOfArticles)?count($arrayOfArticles):0)-1]['name'] = $arrayOfArticles[0]['name'];
|
||||||
if(isset($vdetail['price']) && $vdetail['price']!=''){
|
if(isset($vdetail['price']) && $vdetail['price']!=''){
|
||||||
$arrayOfArticles[count($arrayOfArticles) - 1]['preis_netto'] = $vdetail['data']['price'];
|
$arrayOfArticles[(!empty($arrayOfArticles)?count($arrayOfArticles):0) - 1]['preis_netto'] = $vdetail['data']['price'];
|
||||||
}
|
}
|
||||||
elseif(!empty($vdetail['prices']) && !empty($vdetail['prices'][0]) && $vdetail['prices'][0]['price'] != 0){
|
elseif(!empty($vdetail['prices']) && !empty($vdetail['prices'][0]) && $vdetail['prices'][0]['price'] != 0){
|
||||||
$arrayOfArticles[count($arrayOfArticles) - 1]['preis_netto'] = $vdetail['prices'][0]['price'];
|
$arrayOfArticles[(!empty($arrayOfArticles)?count($arrayOfArticles):0) - 1]['preis_netto'] = $vdetail['prices'][0]['price'];
|
||||||
}
|
}
|
||||||
if(isset( $vdetail['prices'][0]['pseudoPrice']) && $vdetail['prices'][0]['pseudoPrice']!='' &&
|
if(isset( $vdetail['prices'][0]['pseudoPrice']) && $vdetail['prices'][0]['pseudoPrice']!='' &&
|
||||||
round($vdetail['prices'][0]['price'],5)!==round($vdetail['prices'][0]['pseudoPrice'],5)){
|
round($vdetail['prices'][0]['price'],5)!==round($vdetail['prices'][0]['pseudoPrice'],5)){
|
||||||
$arrayOfArticles[count($arrayOfArticles)-1]['pseudopreis'] = $vdetail['prices'][0]['pseudoPrice'] * ((100 + $result['data']['tax']['tax']) / 100);
|
$arrayOfArticles[(!empty($arrayOfArticles)?count($arrayOfArticles):0)-1]['pseudopreis'] = $vdetail['prices'][0]['pseudoPrice'] * ((100 + $result['data']['tax']['tax']) / 100);
|
||||||
}
|
}
|
||||||
if(isset($vdetail['shippingTime']) && $vdetail['shippingTime'] != '')$arrayOfArticles[count($arrayOfArticles)-1]['lieferzeitmanuell'] = $vdetail['shippingTime'];
|
if(isset($vdetail['shippingTime']) && $vdetail['shippingTime'] != '')$arrayOfArticles[(!empty($arrayOfArticles)?count($arrayOfArticles):0)-1]['lieferzeitmanuell'] = $vdetail['shippingTime'];
|
||||||
if(isset($vdetail['ean']) && $vdetail['ean'] != '')$arrayOfArticles[count($arrayOfArticles)-1]['ean'] = $vdetail['ean'];
|
if(isset($vdetail['ean']) && $vdetail['ean'] != '')$arrayOfArticles[(!empty($arrayOfArticles)?count($arrayOfArticles):0)-1]['ean'] = $vdetail['ean'];
|
||||||
if(isset($vdetail['supplierNumber']) && $vdetail['supplierNumber'] != '')$arrayOfArticles[count($arrayOfArticles)-1]['herstellernummer'] = $vdetail['supplierNumber'];
|
if(isset($vdetail['supplierNumber']) && $vdetail['supplierNumber'] != '')$arrayOfArticles[(!empty($arrayOfArticles)?count($arrayOfArticles):0)-1]['herstellernummer'] = $vdetail['supplierNumber'];
|
||||||
if(isset($vdetail['weight']) && $vdetail['shippingTime'] > 0)$arrayOfArticles[count($arrayOfArticles)-1]['gewicht'] = $vdetail['weight'];
|
if(isset($vdetail['weight']) && $vdetail['shippingTime'] > 0)$arrayOfArticles[(!empty($arrayOfArticles)?count($arrayOfArticles):0)-1]['gewicht'] = $vdetail['weight'];
|
||||||
if(isset($vdetail['active']))$arrayOfArticles[count($arrayOfArticles)-1]['aktiv'] = $vdetail['active'];
|
if(isset($vdetail['active']))$arrayOfArticles[(!empty($arrayOfArticles)?count($arrayOfArticles):0)-1]['aktiv'] = $vdetail['active'];
|
||||||
if(!empty($vdetail['configuratorOptions']))
|
if(!empty($vdetail['configuratorOptions']))
|
||||||
{
|
{
|
||||||
$namea = null;
|
$namea = null;
|
||||||
@ -859,7 +859,7 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
sort($namea);
|
sort($namea);
|
||||||
$arrayOfArticles[count($arrayOfArticles)-1]['name'] .= ' '.implode(' ', $namea);
|
$arrayOfArticles[(!empty($arrayOfArticles)?count($arrayOfArticles):0)-1]['name'] .= ' '.implode(' ', $namea);
|
||||||
}
|
}
|
||||||
if(!empty($vdetail['attribute']))
|
if(!empty($vdetail['attribute']))
|
||||||
{
|
{
|
||||||
@ -867,7 +867,7 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
{
|
{
|
||||||
if(strpos($k, 'attr') === 0)
|
if(strpos($k, 'attr') === 0)
|
||||||
{
|
{
|
||||||
$arrayOfArticles[count($arrayOfArticles)-1]['freifeld_'.$k] = $v;
|
$arrayOfArticles[(!empty($arrayOfArticles)?count($arrayOfArticles):0)-1]['freifeld_'.$k] = $v;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -963,7 +963,7 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
{
|
{
|
||||||
$tmp = $this->CatchRemoteCommand('data');
|
$tmp = $this->CatchRemoteCommand('data');
|
||||||
$anzahl = 0;
|
$anzahl = 0;
|
||||||
$ctmp = count($tmp);
|
$ctmp = (!empty($tmp)?count($tmp):0);
|
||||||
for($i=0;$i<$ctmp;$i++)
|
for($i=0;$i<$ctmp;$i++)
|
||||||
{
|
{
|
||||||
$artikel = $tmp[$i]['artikel'];
|
$artikel = $tmp[$i]['artikel'];
|
||||||
@ -1089,7 +1089,7 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
$tmp = $this->CatchRemoteCommand('data');
|
$tmp = $this->CatchRemoteCommand('data');
|
||||||
$anzahl = 0;
|
$anzahl = 0;
|
||||||
$bilderarray = array();
|
$bilderarray = array();
|
||||||
$ctmp = count($tmp);
|
$ctmp = (!empty($tmp)?count($tmp):0);
|
||||||
$shopeinstellungen = $this->app->DB->SelectArr("SELECT * FROM shopexport WHERE id = '".$this->shopid."' AND aktiv = 1 LIMIT 1");
|
$shopeinstellungen = $this->app->DB->SelectArr("SELECT * FROM shopexport WHERE id = '".$this->shopid."' AND aktiv = 1 LIMIT 1");
|
||||||
if(!empty($shopeinstellungen))
|
if(!empty($shopeinstellungen))
|
||||||
{
|
{
|
||||||
@ -1392,7 +1392,7 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
'to' => $bismenge-1);
|
'to' => $bismenge-1);
|
||||||
$bismenge = $key;
|
$bismenge = $key;
|
||||||
}
|
}
|
||||||
$prices[count($prices)-1]['from'] = 1;
|
$prices[(!empty($prices)?count($prices):0)-1]['from'] = 1;
|
||||||
}else{
|
}else{
|
||||||
//Einfacher Preis
|
//Einfacher Preis
|
||||||
$prices[] = array(
|
$prices[] = array(
|
||||||
@ -1431,7 +1431,7 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
'to' => $bismenge-1);
|
'to' => $bismenge-1);
|
||||||
$bismenge = $abmenge;
|
$bismenge = $abmenge;
|
||||||
}
|
}
|
||||||
$prices[count($prices)-1]['from'] = 1;
|
$prices[(!empty($prices)?count($prices):0)-1]['from'] = 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1635,7 +1635,7 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
'to' => $vbismenge-1);
|
'to' => $vbismenge-1);
|
||||||
$vbismenge = $vkey;
|
$vbismenge = $vkey;
|
||||||
}
|
}
|
||||||
$vprices[count($vprices)-1]['from'] = 1;
|
$vprices[(!empty($vprices)?count($vprices):0)-1]['from'] = 1;
|
||||||
|
|
||||||
|
|
||||||
if(count($varr[0]['staffelpreise_gruppen'])>0){
|
if(count($varr[0]['staffelpreise_gruppen'])>0){
|
||||||
@ -1667,7 +1667,7 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
'to' => $bismenge-1);
|
'to' => $bismenge-1);
|
||||||
$bismenge = $abmenge;
|
$bismenge = $abmenge;
|
||||||
}
|
}
|
||||||
$vprices[count($vprices)-1]['from'] = 1;
|
$vprices[(!empty($vprices)?count($vprices):0)-1]['from'] = 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2018,7 +2018,7 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
$posbild = 0;
|
$posbild = 0;
|
||||||
if($shopbilderuebertragen){
|
if($shopbilderuebertragen){
|
||||||
foreach ($bilderarray as $key => $value) {
|
foreach ($bilderarray as $key => $value) {
|
||||||
$cvalue = count($value);
|
$cvalue = (!empty($value)?count($value):0);
|
||||||
for ($k = 0; $k < $cvalue; $k++) {
|
for ($k = 0; $k < $cvalue; $k++) {
|
||||||
|
|
||||||
$mediaId = '';
|
$mediaId = '';
|
||||||
@ -2175,7 +2175,7 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(count($uebersetzung) > 0 ){
|
if((!empty($uebersetzung)?count($uebersetzung):0) > 0 ){
|
||||||
$uebersetzungsdaten = array('shopId' => $value['subshopkennung'], 'type' => 'article', 'key' => $artikelid, 'data' => $uebersetzung);
|
$uebersetzungsdaten = array('shopId' => $value['subshopkennung'], 'type' => 'article', 'key' => $artikelid, 'data' => $uebersetzung);
|
||||||
$tresult = $this->adapter->post('translations', $uebersetzungsdaten);
|
$tresult = $this->adapter->post('translations', $uebersetzungsdaten);
|
||||||
}
|
}
|
||||||
@ -2256,7 +2256,7 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
$anzahl = 0;
|
$anzahl = 0;
|
||||||
$this->app->DB->Delete('DELETE FROM inhalt');
|
$this->app->DB->Delete('DELETE FROM inhalt');
|
||||||
if(!empty($tmp)){
|
if(!empty($tmp)){
|
||||||
$ctmp = count($tmp);
|
$ctmp = (!empty($tmp)?count($tmp):0);
|
||||||
for ($i = 0; $i < $ctmp; $i++) {
|
for ($i = 0; $i < $ctmp; $i++) {
|
||||||
$this->app->DB->Insert("INSERT INTO inhalt (id) VALUES ('')");
|
$this->app->DB->Insert("INSERT INTO inhalt (id) VALUES ('')");
|
||||||
$id = $this->app->DB->GetInsertID();
|
$id = $this->app->DB->GetInsertID();
|
||||||
@ -2337,7 +2337,7 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
$anzahl = 0;
|
$anzahl = 0;
|
||||||
//$this->app->DB->Delete("DELETE FROM exportlink WHERE datum < DATE_ADD(NOW(), INTERVAL 5 DAYS)");
|
//$this->app->DB->Delete("DELETE FROM exportlink WHERE datum < DATE_ADD(NOW(), INTERVAL 5 DAYS)");
|
||||||
|
|
||||||
$ctmp = count($tmp);
|
$ctmp = (!empty($tmp)?count($tmp):0);
|
||||||
for($i=0;$i<$ctmp;$i++)
|
for($i=0;$i<$ctmp;$i++)
|
||||||
{
|
{
|
||||||
$this->app->DB->Insert("INSERT INTO exportlink (id,datum) VALUES ('',NOW())");
|
$this->app->DB->Insert("INSERT INTO exportlink (id,datum) VALUES ('',NOW())");
|
||||||
@ -2360,7 +2360,7 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
$tmp = $this->CatchRemoteCommand('data');
|
$tmp = $this->CatchRemoteCommand('data');
|
||||||
$anzahl = 0;
|
$anzahl = 0;
|
||||||
$this->app->DB->Delete('DELETE FROM artikelgruppen');
|
$this->app->DB->Delete('DELETE FROM artikelgruppen');
|
||||||
$ctmp = count($tmp);
|
$ctmp = (!empty($tmp)?count($tmp):0);
|
||||||
for($i=0;$i<$ctmp;$i++)
|
for($i=0;$i<$ctmp;$i++)
|
||||||
{
|
{
|
||||||
$id = $tmp[$i]['id'];
|
$id = $tmp[$i]['id'];
|
||||||
@ -2384,7 +2384,7 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
$tmp = $this->CatchRemoteCommand('data');
|
$tmp = $this->CatchRemoteCommand('data');
|
||||||
$anzahl = 0;
|
$anzahl = 0;
|
||||||
$this->app->DB->Delete('DELETE FROM shopnavigation');
|
$this->app->DB->Delete('DELETE FROM shopnavigation');
|
||||||
$ctmp = count($tmp);
|
$ctmp = (!empty($tmp)?count($tmp):0);
|
||||||
for($i=0;$i<$ctmp;$i++)
|
for($i=0;$i<$ctmp;$i++)
|
||||||
{
|
{
|
||||||
$id = $tmp[$i]['id'];
|
$id = $tmp[$i]['id'];
|
||||||
@ -2408,7 +2408,7 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
$tmp = $this->CatchRemoteCommand('data');
|
$tmp = $this->CatchRemoteCommand('data');
|
||||||
$anzahl = 0;
|
$anzahl = 0;
|
||||||
$this->app->DB->Delete('DELETE FROM artikel_artikelgruppe');
|
$this->app->DB->Delete('DELETE FROM artikel_artikelgruppe');
|
||||||
$ctmp = count($tmp);
|
$ctmp = (!empty($tmp)?count($tmp):0);
|
||||||
for($i=0;$i<$ctmp;$i++)
|
for($i=0;$i<$ctmp;$i++)
|
||||||
{
|
{
|
||||||
$id = $tmp[$i]['id'];
|
$id = $tmp[$i]['id'];
|
||||||
@ -2989,18 +2989,18 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
);
|
);
|
||||||
//$result['data']['details'][$i]['mode'] <- kann der Wert mit Gewissheit für Gutscheine verwendet werden? Wäre mitunter besser als stur vom Preis auszugehen
|
//$result['data']['details'][$i]['mode'] <- kann der Wert mit Gewissheit für Gutscheine verwendet werden? Wäre mitunter besser als stur vom Preis auszugehen
|
||||||
|
|
||||||
$rates[count($articlearray)-1] = $result['data']['details'][$i]['taxRate'];
|
$rates[(!empty($articlearray)?count($articlearray):0)-1] = $result['data']['details'][$i]['taxRate'];
|
||||||
if(!$gutscheinalslagerartikel && $result['data']['details'][$i]['price'] < 0)
|
if(!$gutscheinalslagerartikel && $result['data']['details'][$i]['price'] < 0)
|
||||||
{
|
{
|
||||||
$articlearray[count($articlearray)-1]['lagerartikel'] = 0;
|
$articlearray[(!empty($articlearray)?count($articlearray):0)-1]['lagerartikel'] = 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
//$warenkorb['taxRates'] = $taxRates;
|
//$warenkorb['taxRates'] = $taxRates;
|
||||||
if(count($taxRates) > 1)
|
if((!empty($taxRates)?count($taxRates):0) > 1)
|
||||||
{
|
{
|
||||||
rsort($taxRates);
|
rsort($taxRates);
|
||||||
$warenkorb['steuersatz_normal'] = $taxRates[0];
|
$warenkorb['steuersatz_normal'] = $taxRates[0];
|
||||||
$warenkorb['steuersatz_ermaessigt'] = $taxRates[count($taxRates) - 1];
|
$warenkorb['steuersatz_ermaessigt'] = $taxRates[(!empty($taxRates)?count($taxRates):0) - 1];
|
||||||
if($warenkorb['versandkostenbrutto'] > 0 && (float)$result['data']['invoiceShippingNet'] > 0)
|
if($warenkorb['versandkostenbrutto'] > 0 && (float)$result['data']['invoiceShippingNet'] > 0)
|
||||||
{
|
{
|
||||||
$satz = round(100*(($warenkorb['versandkostenbrutto']/(float)$result['data']['invoiceShippingNet']) - 1));
|
$satz = round(100*(($warenkorb['versandkostenbrutto']/(float)$result['data']['invoiceShippingNet']) - 1));
|
||||||
@ -3019,7 +3019,7 @@ class Shopimporter_Shopware extends ShopimporterBase
|
|||||||
$articlearray[$k]['umsatzsteuer'] = 'ermaessigt';
|
$articlearray[$k]['umsatzsteuer'] = 'ermaessigt';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}elseif(count($taxRates) > 0)
|
}elseif((!empty($taxRates)?count($taxRates):0) > 0)
|
||||||
{
|
{
|
||||||
$steuersatz_normal = (float)$this->app->erp->Firmendaten('steuersatz_normal');
|
$steuersatz_normal = (float)$this->app->erp->Firmendaten('steuersatz_normal');
|
||||||
$steuersatz_ermaessigt = (float)$this->app->erp->Firmendaten('steuersatz_ermaessigt');
|
$steuersatz_ermaessigt = (float)$this->app->erp->Firmendaten('steuersatz_ermaessigt');
|
||||||
|
@ -424,7 +424,7 @@ class Shopimporter_Shopware6 extends ShopimporterBase
|
|||||||
if ($includedInfo['type'] === 'property_group_option') {
|
if ($includedInfo['type'] === 'property_group_option') {
|
||||||
$optionInfo[$includedInfo['id']] = $includedInfo['attributes'];
|
$optionInfo[$includedInfo['id']] = $includedInfo['attributes'];
|
||||||
if (empty($optionGroupInfo[$includedInfo['attributes']['groupId']])) {
|
if (empty($optionGroupInfo[$includedInfo['attributes']['groupId']])) {
|
||||||
$optionGroupInfo[$includedInfo['attributes']['groupId']] = count($optionGroupInfo) + 1;
|
$optionGroupInfo[$includedInfo['attributes']['groupId']] = (!empty($optionGroupInfo)?count($optionGroupInfo):0) + 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1380,7 +1380,7 @@ class Shopimporter_Shopware6 extends ShopimporterBase
|
|||||||
|
|
||||||
foreach ($internalArticleData['Dateien'] as $internalFile) {
|
foreach ($internalArticleData['Dateien'] as $internalFile) {
|
||||||
$filename = explode('.', $internalFile['filename']);
|
$filename = explode('.', $internalFile['filename']);
|
||||||
unset($filename[count($filename) - 1]);
|
unset($filename[(!empty($filename)?count($filename):0) - 1]);
|
||||||
$filename = $internalFile['id'].'_'.implode($filename);
|
$filename = $internalFile['id'].'_'.implode($filename);
|
||||||
$extension = $internalFile['extension'];
|
$extension = $internalFile['extension'];
|
||||||
$imageTitle = (string)$internalFile['titel'];
|
$imageTitle = (string)$internalFile['titel'];
|
||||||
@ -1510,7 +1510,7 @@ class Shopimporter_Shopware6 extends ShopimporterBase
|
|||||||
}
|
}
|
||||||
foreach ($articleInXentral['Dateien'] as $xentralFile) {
|
foreach ($articleInXentral['Dateien'] as $xentralFile) {
|
||||||
$filename = explode('.', $xentralFile['filename']);
|
$filename = explode('.', $xentralFile['filename']);
|
||||||
unset($filename[count($filename) - 1]);
|
unset($filename[(!empty($filename)?count($filename):0) - 1]);
|
||||||
$filename = $xentralFile['id'].'_'.implode($filename);
|
$filename = $xentralFile['id'].'_'.implode($filename);
|
||||||
|
|
||||||
$searchdata = [
|
$searchdata = [
|
||||||
|
@ -124,7 +124,7 @@ class Shopimporter_Woocommerce extends ShopimporterBase
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return count($pendingOrders);
|
return (!empty($pendingOrders)?count($pendingOrders):0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -188,7 +188,7 @@ class Shopimporter_Woocommerce extends ShopimporterBase
|
|||||||
|
|
||||||
|
|
||||||
// Return an empty array in case there are no orders to import
|
// Return an empty array in case there are no orders to import
|
||||||
if (count($pendingOrders) === 0) {
|
if ((!empty($pendingOrders)?count($pendingOrders):0) === 0) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -497,7 +497,7 @@ class Shopimporter_Woocommerce extends ShopimporterBase
|
|||||||
{
|
{
|
||||||
$tmp = $this->CatchRemoteCommand('data');
|
$tmp = $this->CatchRemoteCommand('data');
|
||||||
$anzahl = 0;
|
$anzahl = 0;
|
||||||
$ctmp = count($tmp);
|
$ctmp = (!empty($tmp)?count($tmp):0);
|
||||||
|
|
||||||
for($i=0;$i<$ctmp;$i++)
|
for($i=0;$i<$ctmp;$i++)
|
||||||
{
|
{
|
||||||
@ -585,7 +585,7 @@ class Shopimporter_Woocommerce extends ShopimporterBase
|
|||||||
|
|
||||||
$anzahl = 0;
|
$anzahl = 0;
|
||||||
|
|
||||||
for($i=0;$i<count($tmp);$i++){
|
for($i=0;$i<(!empty($tmp)?count($tmp):0);$i++){
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -754,7 +754,7 @@ class Shopimporter_Woocommerce extends ShopimporterBase
|
|||||||
)
|
)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
if(count($kategorien)>0){
|
if((!empty($kategorien)?count($kategorien):0)>0){
|
||||||
|
|
||||||
// Retrive all WC categories via API
|
// Retrive all WC categories via API
|
||||||
$allWooCommerceCategories = $this->client->get('products/categories', ['per_page' => '100']);
|
$allWooCommerceCategories = $this->client->get('products/categories', ['per_page' => '100']);
|
||||||
|
@ -284,7 +284,7 @@ class Sipgate
|
|||||||
|
|
||||||
if (!$target) {
|
if (!$target) {
|
||||||
$ida = explode('-', $this->app->Secure->GetGET('id'));
|
$ida = explode('-', $this->app->Secure->GetGET('id'));
|
||||||
if (count($ida) == 2) {
|
if ((!empty($ida)?count($ida):0) == 2) {
|
||||||
$id = (int)$ida[1];
|
$id = (int)$ida[1];
|
||||||
switch ($ida[0]) {
|
switch ($ida[0]) {
|
||||||
case '1':
|
case '1':
|
||||||
|
@ -241,7 +241,7 @@ class Supportapp Extends GenSupportapp {
|
|||||||
$artikeltmp = $app->DB->SelectArr("SELECT * FROM supportapp_artikel");
|
$artikeltmp = $app->DB->SelectArr("SELECT * FROM supportapp_artikel");
|
||||||
|
|
||||||
if (!is_null($artikeltmp)) {
|
if (!is_null($artikeltmp)) {
|
||||||
for ($i=0; $i < count($artikeltmp); $i++) {
|
for ($i=0; $i < (!empty($artikeltmp)?count($artikeltmp):0); $i++) {
|
||||||
switch ($artikeltmp[$i]['typ']) {
|
switch ($artikeltmp[$i]['typ']) {
|
||||||
case '1':
|
case '1':
|
||||||
$artikektelefonarr[] = $artikeltmp[$i]['artikel'];
|
$artikektelefonarr[] = $artikeltmp[$i]['artikel'];
|
||||||
@ -345,8 +345,8 @@ class Supportapp Extends GenSupportapp {
|
|||||||
|
|
||||||
if (!is_null($filterschritte)) {
|
if (!is_null($filterschritte)) {
|
||||||
|
|
||||||
if(count($filterschritte) > 0){
|
if((!empty($filterschritte)?count($filterschritte):0) > 0){
|
||||||
for ($i=4; $i < count($filterschritte)+4; $i++) {
|
for ($i=4; $i < (!empty($filterschritte)?count($filterschritte):0)+4; $i++) {
|
||||||
$moredataarray[$i] = $app->Secure->GetGET("more_data".$i);
|
$moredataarray[$i] = $app->Secure->GetGET("more_data".$i);
|
||||||
$schrittearray[$i] = $filterschritte[$i-4]['id'];
|
$schrittearray[$i] = $filterschritte[$i-4]['id'];
|
||||||
}
|
}
|
||||||
@ -372,10 +372,10 @@ class Supportapp Extends GenSupportapp {
|
|||||||
$aktivefilterschritte[] = "wac.schritt = ".$schrittearray[$key];
|
$aktivefilterschritte[] = "wac.schritt = ".$schrittearray[$key];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(count($aktivefilterschritte) > 0 ){
|
if((!empty($aktivefilterschritte)?count($aktivefilterschritte):0) > 0 ){
|
||||||
$filterjoin = "LEFT JOIN (SELECT wac.adresse, SUM(wac.status) AS sumx, COUNT(IF(ws.vorgaenger,IF(wac2.status = 1,1,NULL),wac.status)) AS countx FROM supportapp_auftrag_check wac LEFT JOIN supportapp_schritte ws ON wac.schritt = ws.id LEFT JOIN supportapp_auftrag_check wac2 ON wac2.auftragposition = wac.auftragposition AND wac2.schritt = ws.vorgaenger WHERE (".implode(" OR ", $aktivefilterschritte).") GROUP BY adresse) AS wac ON wac.adresse = ku.id";
|
$filterjoin = "LEFT JOIN (SELECT wac.adresse, SUM(wac.status) AS sumx, COUNT(IF(ws.vorgaenger,IF(wac2.status = 1,1,NULL),wac.status)) AS countx FROM supportapp_auftrag_check wac LEFT JOIN supportapp_schritte ws ON wac.schritt = ws.id LEFT JOIN supportapp_auftrag_check wac2 ON wac2.auftragposition = wac.auftragposition AND wac2.schritt = ws.vorgaenger WHERE (".implode(" OR ", $aktivefilterschritte).") GROUP BY adresse) AS wac ON wac.adresse = ku.id";
|
||||||
$countfilter = "LEFT JOIN (SELECT wac.adresse, SUM(wac.status) AS sumx, COUNT(IF(ws.vorgaenger,IF(wac2.status = 1,1,NULL),wac.status)) AS countx FROM supportapp_auftrag_check wac LEFT JOIN supportapp_schritte ws ON wac.schritt = ws.id LEFT JOIN supportapp_auftrag_check wac2 ON wac2.auftragposition = wac.auftragposition AND wac2.schritt = ws.vorgaenger WHERE (".implode(" OR ", $aktivefilterschritte).") GROUP BY adresse) AS wac ON wac.adresse = w.adresse";
|
$countfilter = "LEFT JOIN (SELECT wac.adresse, SUM(wac.status) AS sumx, COUNT(IF(ws.vorgaenger,IF(wac2.status = 1,1,NULL),wac.status)) AS countx FROM supportapp_auftrag_check wac LEFT JOIN supportapp_schritte ws ON wac.schritt = ws.id LEFT JOIN supportapp_auftrag_check wac2 ON wac2.auftragposition = wac.auftragposition AND wac2.schritt = ws.vorgaenger WHERE (".implode(" OR ", $aktivefilterschritte).") GROUP BY adresse) AS wac ON wac.adresse = w.adresse";
|
||||||
$where .= "AND wac.sumx < wac.countx AND wac.countx>=".count($aktivefilterschritte);
|
$where .= "AND wac.sumx < wac.countx AND wac.countx>=".(!empty($aktivefilterschritte)?count($aktivefilterschritte):0);
|
||||||
}
|
}
|
||||||
|
|
||||||
$sql = "SELECT SQL_CALC_FOUND_ROWS w.id, '<img src=./themes/{$app->Conf->WFconf['defaulttheme']}/images/details_open.png class=details>' as open,
|
$sql = "SELECT SQL_CALC_FOUND_ROWS w.id, '<img src=./themes/{$app->Conf->WFconf['defaulttheme']}/images/details_open.png class=details>' as open,
|
||||||
@ -514,13 +514,13 @@ class Supportapp Extends GenSupportapp {
|
|||||||
if($this->app->DB->real_escape_string($this->app->Secure->GetPOST('schritteerrechnen'))){
|
if($this->app->DB->real_escape_string($this->app->Secure->GetPOST('schritteerrechnen'))){
|
||||||
$kunden = $this->app->DB->SelectArr("SELECT adresse FROM supportapp WHERE status='gestartet'");
|
$kunden = $this->app->DB->SelectArr("SELECT adresse FROM supportapp WHERE status='gestartet'");
|
||||||
$schrittzahl = 0;
|
$schrittzahl = 0;
|
||||||
$kundenzahl = count($kunden);
|
$kundenzahl = (!empty($kunden)?count($kunden):0);
|
||||||
for ($h=0; $h < count($kunden); $h++) {
|
for ($h=0; $h < (!empty($kunden)?count($kunden):0); $h++) {
|
||||||
$kundenid = $kunden[$h]['adresse'];
|
$kundenid = $kunden[$h]['adresse'];
|
||||||
$gruppenzumhinzufuegen= $this->app->DB->SelectArr("SELECT ap.id, was.gruppe FROM auftrag_position ap JOIN auftrag a ON ap.auftrag = a.id LEFT JOIN supportapp_gruppen wag ON ap.artikel = wag.artikel LEFT JOIN supportapp_schritte was ON wag.id = was.gruppe LEFT JOIN supportapp_auftrag_check wac ON wac.schritt = was.id WHERE a.adresse = '$kundenid' AND a.status <> 'storniert' AND a.belegnr <> '' AND wag.aktiv = 1 AND was.aktiv = 1 GROUP BY ap.id, was.id");
|
$gruppenzumhinzufuegen= $this->app->DB->SelectArr("SELECT ap.id, was.gruppe FROM auftrag_position ap JOIN auftrag a ON ap.auftrag = a.id LEFT JOIN supportapp_gruppen wag ON ap.artikel = wag.artikel LEFT JOIN supportapp_schritte was ON wag.id = was.gruppe LEFT JOIN supportapp_auftrag_check wac ON wac.schritt = was.id WHERE a.adresse = '$kundenid' AND a.status <> 'storniert' AND a.belegnr <> '' AND wag.aktiv = 1 AND was.aktiv = 1 GROUP BY ap.id, was.id");
|
||||||
for ($i=0; $i < count($gruppenzumhinzufuegen); $i++) {
|
for ($i=0; $i < (!empty($gruppenzumhinzufuegen)?count($gruppenzumhinzufuegen):0); $i++) {
|
||||||
$einzelschritte = $this->app->DB->SelectArr("SELECT * FROM supportapp_schritte WHERE aktiv = 1 AND gruppe = ".$gruppenzumhinzufuegen[$i]['gruppe']);
|
$einzelschritte = $this->app->DB->SelectArr("SELECT * FROM supportapp_schritte WHERE aktiv = 1 AND gruppe = ".$gruppenzumhinzufuegen[$i]['gruppe']);
|
||||||
for ($j=0; $j < count($einzelschritte); $j++) {
|
for ($j=0; $j < (!empty($einzelschritte)?count($einzelschritte):0); $j++) {
|
||||||
$vorhanden = $this->app->DB->Select("SELECT id FROM supportapp_auftrag_check WHERE auftragposition = '".$gruppenzumhinzufuegen[$i]['id']."' AND gruppe = '".$gruppenzumhinzufuegen[$i]['gruppe']."' AND adresse = '$kundenid' AND schritt = '".$einzelschritte[$j]['id']."' LIMIT 1");
|
$vorhanden = $this->app->DB->Select("SELECT id FROM supportapp_auftrag_check WHERE auftragposition = '".$gruppenzumhinzufuegen[$i]['id']."' AND gruppe = '".$gruppenzumhinzufuegen[$i]['gruppe']."' AND adresse = '$kundenid' AND schritt = '".$einzelschritte[$j]['id']."' LIMIT 1");
|
||||||
if($vorhanden == ''){
|
if($vorhanden == ''){
|
||||||
$schrittzahl += 1;
|
$schrittzahl += 1;
|
||||||
@ -716,10 +716,10 @@ class Supportapp Extends GenSupportapp {
|
|||||||
|
|
||||||
if (!is_null($filterschritte)) {
|
if (!is_null($filterschritte)) {
|
||||||
|
|
||||||
if(count($filterschritte) > 0){
|
if((!empty($filterschritte)?count($filterschritte):0) > 0){
|
||||||
$filterinhalt = "<fieldset style=\"width:33em;\"><legend>Einzelfilter</legend><table>";
|
$filterinhalt = "<fieldset style=\"width:33em;\"><legend>Einzelfilter</legend><table>";
|
||||||
$filtergruppe_tmp = "";
|
$filtergruppe_tmp = "";
|
||||||
for ($i=0; $i < count($filterschritte); $i++) {
|
for ($i=0; $i < (!empty($filterschritte)?count($filterschritte):0); $i++) {
|
||||||
if($filtergruppe_tmp != $filterschritte[$i]['wgb']){
|
if($filtergruppe_tmp != $filterschritte[$i]['wgb']){
|
||||||
$filterinhalt .= '<tr><td></td></tr><tr><td colspan="2"><b>'.$filterschritte[$i]['wgb'].'</b></td></tr>';
|
$filterinhalt .= '<tr><td></td></tr><tr><td colspan="2"><b>'.$filterschritte[$i]['wgb'].'</b></td></tr>';
|
||||||
$filtergruppe_tmp = $filterschritte[$i]['wgb'];
|
$filtergruppe_tmp = $filterschritte[$i]['wgb'];
|
||||||
@ -940,7 +940,7 @@ class Supportapp Extends GenSupportapp {
|
|||||||
|
|
||||||
if (!is_null($artikeltmp)) {
|
if (!is_null($artikeltmp)) {
|
||||||
|
|
||||||
for ($i=0; $i < count($artikeltmp); $i++) {
|
for ($i=0; $i < (!empty($artikeltmp)?count($artikeltmp):0); $i++) {
|
||||||
switch ($artikeltmp[$i]['typ']) {
|
switch ($artikeltmp[$i]['typ']) {
|
||||||
case '1':
|
case '1':
|
||||||
$artikektelefonarr[] = $artikeltmp[$i]['artikel'];
|
$artikektelefonarr[] = $artikeltmp[$i]['artikel'];
|
||||||
@ -977,9 +977,9 @@ class Supportapp Extends GenSupportapp {
|
|||||||
|
|
||||||
if (!is_null($gruppezumhinzufuegen)) {
|
if (!is_null($gruppezumhinzufuegen)) {
|
||||||
|
|
||||||
for ($i=0; $i < count($gruppenzumhinzufuegen); $i++) {
|
for ($i=0; $i < (!empty($gruppenzumhinzufuegen)?count($gruppenzumhinzufuegen):0); $i++) {
|
||||||
$einzelschritte = $this->app->DB->Select("SELECT * FROM supportapp_schritte WHERE aktiv = 1 AND gruppe = ".$gruppenzumhinzufuegen[$i]['gruppe']);
|
$einzelschritte = $this->app->DB->Select("SELECT * FROM supportapp_schritte WHERE aktiv = 1 AND gruppe = ".$gruppenzumhinzufuegen[$i]['gruppe']);
|
||||||
for ($j=0; $j < count($einzelschritte); $j++) {
|
for ($j=0; $j < (!empty($einzelschritte)?count($einzelschritte):0); $j++) {
|
||||||
$vorhanden = $this->app->DB->Select("SELECT id FROM supportapp_auftrag_check WHERE auftragposition = '".$gruppenzumhinzufuegen[$i]['id']."' AND gruppe = '".$gruppenzumhinzufuegen[$i]['gruppe']."' AND adresse = '$kundenid' AND schritt = '".$einzelschritte[$j]['id']."' LIMIT 1");
|
$vorhanden = $this->app->DB->Select("SELECT id FROM supportapp_auftrag_check WHERE auftragposition = '".$gruppenzumhinzufuegen[$i]['id']."' AND gruppe = '".$gruppenzumhinzufuegen[$i]['gruppe']."' AND adresse = '$kundenid' AND schritt = '".$einzelschritte[$j]['id']."' LIMIT 1");
|
||||||
if($vorhanden == ''){
|
if($vorhanden == ''){
|
||||||
$this->app->DB->Insert("INSERT INTO supportapp_auftrag_check (adresse, gruppe, schritt, auftragposition, status) VALUES ('$kundenid','".$gruppenzumhinzufuegen[$i]['gruppe']."','".$einzelschritte[$j]['id']."','".$gruppenzumhinzufuegen[$i]['id']."','0')");
|
$this->app->DB->Insert("INSERT INTO supportapp_auftrag_check (adresse, gruppe, schritt, auftragposition, status) VALUES ('$kundenid','".$gruppenzumhinzufuegen[$i]['gruppe']."','".$einzelschritte[$j]['id']."','".$gruppenzumhinzufuegen[$i]['id']."','0')");
|
||||||
@ -1071,7 +1071,7 @@ class Supportapp Extends GenSupportapp {
|
|||||||
|
|
||||||
if (!is_null($modules)) {
|
if (!is_null($modules)) {
|
||||||
|
|
||||||
for ($i=0; $i < count($modules); $i++) {
|
for ($i=0; $i < (!empty($modules)?count($modules):0); $i++) {
|
||||||
$module .= '
|
$module .= '
|
||||||
<tr>
|
<tr>
|
||||||
<td>'.$modules[$i]['datum'].'</td>
|
<td>'.$modules[$i]['datum'].'</td>
|
||||||
@ -1101,7 +1101,7 @@ class Supportapp Extends GenSupportapp {
|
|||||||
|
|
||||||
if (!is_null($beleges)) {
|
if (!is_null($beleges)) {
|
||||||
|
|
||||||
for ($i=0; $i < count($beleges); $i++) {
|
for ($i=0; $i < (!empty($beleges)?count($beleges):0); $i++) {
|
||||||
$belege .= '
|
$belege .= '
|
||||||
<tr>
|
<tr>
|
||||||
<td>'.$beleges[$i]['art'].'</td>
|
<td>'.$beleges[$i]['art'].'</td>
|
||||||
@ -1126,7 +1126,7 @@ class Supportapp Extends GenSupportapp {
|
|||||||
|
|
||||||
if (!is_null($logbuchs)) {
|
if (!is_null($logbuchs)) {
|
||||||
|
|
||||||
for ($i=0; $i < count($logbuchs); $i++) {
|
for ($i=0; $i < (!empty($logbuchs)?count($logbuchs):0); $i++) {
|
||||||
$logbuch .= '
|
$logbuch .= '
|
||||||
<tr>
|
<tr>
|
||||||
<td>'.date_format(date_create($logbuchs[$i]['logdatei']), 'H:i d.m.y').'</td>
|
<td>'.date_format(date_create($logbuchs[$i]['logdatei']), 'H:i d.m.y').'</td>
|
||||||
@ -1148,7 +1148,7 @@ class Supportapp Extends GenSupportapp {
|
|||||||
|
|
||||||
if (!is_null($einrichtungs)) {
|
if (!is_null($einrichtungs)) {
|
||||||
|
|
||||||
for ($i=0; $i < count($einrichtungs); $i++) {
|
for ($i=0; $i < (!empty($einrichtungs)?count($einrichtungs):0); $i++) {
|
||||||
$einrichtung .= '
|
$einrichtung .= '
|
||||||
<tr>
|
<tr>
|
||||||
<td>'.$einrichtungs[$i]['status'].'</td>
|
<td>'.$einrichtungs[$i]['status'].'</td>
|
||||||
@ -1167,13 +1167,13 @@ class Supportapp Extends GenSupportapp {
|
|||||||
|
|
||||||
if (!is_null($gruppen)) {
|
if (!is_null($gruppen)) {
|
||||||
|
|
||||||
for ($i=0; $i < count($gruppen); $i++) {
|
for ($i=0; $i < (!empty($gruppen)?count($gruppen):0); $i++) {
|
||||||
if($gruppen[$i]['gesamt'] > $gruppen[$i]['erledigt']){
|
if($gruppen[$i]['gesamt'] > $gruppen[$i]['erledigt']){
|
||||||
$schritte = $this->app->DB->SelectArr("SELECT ws.*, IF(wac.status=1,1,0) AS status FROM supportapp_schritte ws LEFT JOIN (SELECT * FROM supportapp_auftrag_check WHERE adresse = '".$kundenid."' AND auftragposition = '".$gruppen[$i]['auftragsposition']."') wac ON ws.id = wac.schritt WHERE ws.gruppe = '".$gruppen[$i]['id']."' AND ws.aktiv = '1' ORDER BY sort ASC");
|
$schritte = $this->app->DB->SelectArr("SELECT ws.*, IF(wac.status=1,1,0) AS status FROM supportapp_schritte ws LEFT JOIN (SELECT * FROM supportapp_auftrag_check WHERE adresse = '".$kundenid."' AND auftragposition = '".$gruppen[$i]['auftragsposition']."') wac ON ws.id = wac.schritt WHERE ws.gruppe = '".$gruppen[$i]['id']."' AND ws.aktiv = '1' ORDER BY sort ASC");
|
||||||
$checkboxen .= '<tr><td colspan="4"><b><u>'.$gruppen[$i]['auftrag']." - ".$gruppen[$i]['bezeichnung'].'<u><b></td><tr>';
|
$checkboxen .= '<tr><td colspan="4"><b><u>'.$gruppen[$i]['auftrag']." - ".$gruppen[$i]['bezeichnung'].'<u><b></td><tr>';
|
||||||
$kopfzeilen++;
|
$kopfzeilen++;
|
||||||
$checkboxen .= '<tr>';
|
$checkboxen .= '<tr>';
|
||||||
for ($j=0; $j < count($schritte); $j++) {
|
for ($j=0; $j < (!empty($schritte)?count($schritte):0); $j++) {
|
||||||
if(($j % 4) == 0 && $j != 0){
|
if(($j % 4) == 0 && $j != 0){
|
||||||
$checkboxen .= '</tr><tr>';
|
$checkboxen .= '</tr><tr>';
|
||||||
}
|
}
|
||||||
@ -1209,7 +1209,7 @@ class Supportapp Extends GenSupportapp {
|
|||||||
|
|
||||||
if (!is_null($vorlagenarray)) {
|
if (!is_null($vorlagenarray)) {
|
||||||
|
|
||||||
for ($i=0; $i < count($vorlagenarray); $i++) {
|
for ($i=0; $i < (!empty($vorlagenarray)?count($vorlagenarray):0); $i++) {
|
||||||
$vorlagen .= '<option value="'.$vorlagenarray[$i]['id'].'">'.$vorlagenarray[$i]['bezeichnung'].'</option>';
|
$vorlagen .= '<option value="'.$vorlagenarray[$i]['id'].'">'.$vorlagenarray[$i]['bezeichnung'].'</option>';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -503,7 +503,7 @@ class Systemlog {
|
|||||||
$tmp['text'] = 'fsocket verfügbar';
|
$tmp['text'] = 'fsocket verfügbar';
|
||||||
$ret[] = $tmp;
|
$ret[] = $tmp;
|
||||||
}
|
}
|
||||||
$typeToMessage['fsocket'] = count($ret) - 1;
|
$typeToMessage['fsocket'] = (!empty($ret)?count($ret):0) - 1;
|
||||||
if(!function_exists('mysqli_connect')) {
|
if(!function_exists('mysqli_connect')) {
|
||||||
$tmp['status'] = 'error';
|
$tmp['status'] = 'error';
|
||||||
$tmp['text'] = 'MYSQLi nicht installiert';
|
$tmp['text'] = 'MYSQLi nicht installiert';
|
||||||
@ -514,7 +514,7 @@ class Systemlog {
|
|||||||
$tmp['text'] = 'MYSQLi verfügbar';
|
$tmp['text'] = 'MYSQLi verfügbar';
|
||||||
$ret[] = $tmp;
|
$ret[] = $tmp;
|
||||||
}
|
}
|
||||||
$typeToMessage['mysqli'] = count($ret) - 1;
|
$typeToMessage['mysqli'] = (!empty($ret)?count($ret):0) - 1;
|
||||||
if(!extension_loaded('mysqlnd')) {
|
if(!extension_loaded('mysqlnd')) {
|
||||||
$tmp['status'] = 'error';
|
$tmp['status'] = 'error';
|
||||||
$tmp['text'] = 'Mysqlnd nicht installiert';
|
$tmp['text'] = 'Mysqlnd nicht installiert';
|
||||||
@ -525,7 +525,7 @@ class Systemlog {
|
|||||||
$tmp['text'] = 'Mysqlnd verfügbar';
|
$tmp['text'] = 'Mysqlnd verfügbar';
|
||||||
$ret[] = $tmp;
|
$ret[] = $tmp;
|
||||||
}
|
}
|
||||||
$typeToMessage['mysqlnd'] = count($ret) - 1;
|
$typeToMessage['mysqlnd'] = (!empty($ret)?count($ret):0) - 1;
|
||||||
if(!class_exists('\PDO')) {
|
if(!class_exists('\PDO')) {
|
||||||
$tmp['status'] = 'error';
|
$tmp['status'] = 'error';
|
||||||
$tmp['text'] = 'PDO nicht installiert';
|
$tmp['text'] = 'PDO nicht installiert';
|
||||||
@ -536,7 +536,7 @@ class Systemlog {
|
|||||||
$tmp['text'] = 'PDO verfügbar';
|
$tmp['text'] = 'PDO verfügbar';
|
||||||
$ret[] = $tmp;
|
$ret[] = $tmp;
|
||||||
}
|
}
|
||||||
$typeToMessage['pdo'] = count($ret) - 1;
|
$typeToMessage['pdo'] = (!empty($ret)?count($ret):0) - 1;
|
||||||
if(!function_exists('curl_init')) {
|
if(!function_exists('curl_init')) {
|
||||||
$tmp['status'] = 'error';
|
$tmp['status'] = 'error';
|
||||||
$tmp['text'] = 'cURL nicht installiert';
|
$tmp['text'] = 'cURL nicht installiert';
|
||||||
@ -547,7 +547,7 @@ class Systemlog {
|
|||||||
$tmp['text'] = 'cURL verfügbar';
|
$tmp['text'] = 'cURL verfügbar';
|
||||||
$ret[] = $tmp;
|
$ret[] = $tmp;
|
||||||
}
|
}
|
||||||
$typeToMessage['curl'] = count($ret) - 1;
|
$typeToMessage['curl'] = (!empty($ret)?count($ret):0) - 1;
|
||||||
if(!function_exists('stream_socket_enable_crypto')) {
|
if(!function_exists('stream_socket_enable_crypto')) {
|
||||||
$tmp['status'] = 'error';
|
$tmp['status'] = 'error';
|
||||||
$tmp['text'] = 'stream_socket_enable_crypto nicht installiert';
|
$tmp['text'] = 'stream_socket_enable_crypto nicht installiert';
|
||||||
@ -558,7 +558,7 @@ class Systemlog {
|
|||||||
$tmp['text'] = 'stream_socket_enable_crypto verfügbar';
|
$tmp['text'] = 'stream_socket_enable_crypto verfügbar';
|
||||||
$ret[] = $tmp;
|
$ret[] = $tmp;
|
||||||
}
|
}
|
||||||
$typeToMessage['crypto'] = count($ret) - 1;
|
$typeToMessage['crypto'] = (!empty($ret)?count($ret):0) - 1;
|
||||||
if(!function_exists('openssl_error_string')) {
|
if(!function_exists('openssl_error_string')) {
|
||||||
$tmp['status'] = 'warning';
|
$tmp['status'] = 'warning';
|
||||||
$tmp['text'] = 'OpenSSL nicht installiert';
|
$tmp['text'] = 'OpenSSL nicht installiert';
|
||||||
@ -569,7 +569,7 @@ class Systemlog {
|
|||||||
$tmp['text'] = 'OpenSSL verfügbar';
|
$tmp['text'] = 'OpenSSL verfügbar';
|
||||||
$ret[] = $tmp;
|
$ret[] = $tmp;
|
||||||
}
|
}
|
||||||
$typeToMessage['openssl'] = count($ret) - 1;
|
$typeToMessage['openssl'] = (!empty($ret)?count($ret):0) - 1;
|
||||||
if(!function_exists('mb_encode_numericentity')) {
|
if(!function_exists('mb_encode_numericentity')) {
|
||||||
$tmp['status'] = 'error';
|
$tmp['status'] = 'error';
|
||||||
$tmp['text'] = 'php-mbstring nicht installiert';
|
$tmp['text'] = 'php-mbstring nicht installiert';
|
||||||
@ -580,7 +580,7 @@ class Systemlog {
|
|||||||
$tmp['text'] = 'php-mbstring verfügbar';
|
$tmp['text'] = 'php-mbstring verfügbar';
|
||||||
$ret[] = $tmp;
|
$ret[] = $tmp;
|
||||||
}
|
}
|
||||||
$typeToMessage['php-mbstring'] = count($ret) - 1;
|
$typeToMessage['php-mbstring'] = (!empty($ret)?count($ret):0) - 1;
|
||||||
if(!class_exists('SoapClient')) {
|
if(!class_exists('SoapClient')) {
|
||||||
$tmp['status'] = 'warning';
|
$tmp['status'] = 'warning';
|
||||||
$tmp['text'] = 'php-soap nicht installiert';
|
$tmp['text'] = 'php-soap nicht installiert';
|
||||||
@ -591,7 +591,7 @@ class Systemlog {
|
|||||||
$tmp['text'] = 'php-soap verfügbar';
|
$tmp['text'] = 'php-soap verfügbar';
|
||||||
$ret[] = $tmp;
|
$ret[] = $tmp;
|
||||||
}
|
}
|
||||||
$typeToMessage['php-soap'] = count($ret) - 1;
|
$typeToMessage['php-soap'] = (!empty($ret)?count($ret):0) - 1;
|
||||||
if(!function_exists('imap_open')) {
|
if(!function_exists('imap_open')) {
|
||||||
$tmp['status'] = 'error';
|
$tmp['status'] = 'error';
|
||||||
$tmp['text'] = 'imap nicht installiert';
|
$tmp['text'] = 'imap nicht installiert';
|
||||||
@ -602,7 +602,7 @@ class Systemlog {
|
|||||||
$tmp['text'] = 'imap verfügbar';
|
$tmp['text'] = 'imap verfügbar';
|
||||||
$ret[] = $tmp;
|
$ret[] = $tmp;
|
||||||
}
|
}
|
||||||
$typeToMessage['imap'] = count($ret) - 1;
|
$typeToMessage['imap'] = (!empty($ret)?count($ret):0) - 1;
|
||||||
if(!function_exists('simplexml_load_string')) {
|
if(!function_exists('simplexml_load_string')) {
|
||||||
$tmp['status'] = 'error';
|
$tmp['status'] = 'error';
|
||||||
$tmp['text'] = 'php-xml nicht installiert';
|
$tmp['text'] = 'php-xml nicht installiert';
|
||||||
@ -613,7 +613,7 @@ class Systemlog {
|
|||||||
$tmp['text'] = 'php-xml verfügbar';
|
$tmp['text'] = 'php-xml verfügbar';
|
||||||
$ret[] = $tmp;
|
$ret[] = $tmp;
|
||||||
}
|
}
|
||||||
$typeToMessage['php-xml'] = count($ret) - 1;
|
$typeToMessage['php-xml'] = (!empty($ret)?count($ret):0) - 1;
|
||||||
if(!class_exists('ZipArchive')) {
|
if(!class_exists('ZipArchive')) {
|
||||||
$tmp['status'] = 'error';
|
$tmp['status'] = 'error';
|
||||||
$tmp['text'] = 'php-zip nicht installiert';
|
$tmp['text'] = 'php-zip nicht installiert';
|
||||||
@ -624,7 +624,7 @@ class Systemlog {
|
|||||||
$tmp['text'] = 'php-zip verfügbar';
|
$tmp['text'] = 'php-zip verfügbar';
|
||||||
$ret[] = $tmp;
|
$ret[] = $tmp;
|
||||||
}
|
}
|
||||||
$typeToMessage['php-zip'] = count($ret) - 1;
|
$typeToMessage['php-zip'] = (!empty($ret)?count($ret):0) - 1;
|
||||||
try {
|
try {
|
||||||
$hasZip = $this->hasExectuableExtension('zip');
|
$hasZip = $this->hasExectuableExtension('zip');
|
||||||
}
|
}
|
||||||
@ -658,7 +658,7 @@ class Systemlog {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$typeToMessage['extension-zip'] = count($ret) - 1;
|
$typeToMessage['extension-zip'] = (!empty($ret)?count($ret):0) - 1;
|
||||||
|
|
||||||
if(!function_exists('imagejpeg')) {
|
if(!function_exists('imagejpeg')) {
|
||||||
$tmp['status'] = 'warning';
|
$tmp['status'] = 'warning';
|
||||||
@ -670,7 +670,7 @@ class Systemlog {
|
|||||||
$tmp['text'] = 'PHP GD-Erweiterung verfügbar';
|
$tmp['text'] = 'PHP GD-Erweiterung verfügbar';
|
||||||
$ret[] = $tmp;
|
$ret[] = $tmp;
|
||||||
}
|
}
|
||||||
$typeToMessage['php-gd'] = count($ret) - 1;
|
$typeToMessage['php-gd'] = (!empty($ret)?count($ret):0) - 1;
|
||||||
if(!function_exists('ldap_connect')) {
|
if(!function_exists('ldap_connect')) {
|
||||||
$tmp['status'] = 'warning';
|
$tmp['status'] = 'warning';
|
||||||
$tmp['text'] = 'PHP LDAP-Erweiterung nicht installiert';
|
$tmp['text'] = 'PHP LDAP-Erweiterung nicht installiert';
|
||||||
@ -681,7 +681,7 @@ class Systemlog {
|
|||||||
$tmp['text'] = 'PHP LDAP-Erweiterung verfügbar';
|
$tmp['text'] = 'PHP LDAP-Erweiterung verfügbar';
|
||||||
$ret[] = $tmp;
|
$ret[] = $tmp;
|
||||||
}
|
}
|
||||||
$typeToMessage['php-ldap'] = count($ret) - 1;
|
$typeToMessage['php-ldap'] = (!empty($ret)?count($ret):0) - 1;
|
||||||
if(!function_exists('ssh2_connect')) {
|
if(!function_exists('ssh2_connect')) {
|
||||||
$tmp['status'] = 'warning';
|
$tmp['status'] = 'warning';
|
||||||
$tmp['text'] = 'PHP SSH2-Erweiterung nicht installiert';
|
$tmp['text'] = 'PHP SSH2-Erweiterung nicht installiert';
|
||||||
@ -692,7 +692,7 @@ class Systemlog {
|
|||||||
$tmp['text'] = 'PHP SSH2-Erweiterung verfügbar';
|
$tmp['text'] = 'PHP SSH2-Erweiterung verfügbar';
|
||||||
$ret[] = $tmp;
|
$ret[] = $tmp;
|
||||||
}
|
}
|
||||||
$typeToMessage['tls1-2'] = count($ret) - 1;
|
$typeToMessage['tls1-2'] = (!empty($ret)?count($ret):0) - 1;
|
||||||
if(!$this->isTls12Available()) {
|
if(!$this->isTls12Available()) {
|
||||||
$tmp['status'] = 'warning';
|
$tmp['status'] = 'warning';
|
||||||
$tmp['text'] = 'TLS 1.2 ist nicht verfügbar';
|
$tmp['text'] = 'TLS 1.2 ist nicht verfügbar';
|
||||||
@ -719,7 +719,7 @@ class Systemlog {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$typeToMessage['php-ssh2'] = count($ret) - 1;
|
$typeToMessage['php-ssh2'] = (!empty($ret)?count($ret):0) - 1;
|
||||||
if(!function_exists('ioncube_loader_version')) {
|
if(!function_exists('ioncube_loader_version')) {
|
||||||
$tmp['status'] = 'warning';
|
$tmp['status'] = 'warning';
|
||||||
$tmp['text'] = 'Ioncube ist nicht installiert (Eine Installation ist trotzdem möglich)';
|
$tmp['text'] = 'Ioncube ist nicht installiert (Eine Installation ist trotzdem möglich)';
|
||||||
@ -738,7 +738,7 @@ class Systemlog {
|
|||||||
$ret[] = $tmp;
|
$ret[] = $tmp;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$typeToMessage['ioncube'] = count($ret) - 1;
|
$typeToMessage['ioncube'] = (!empty($ret)?count($ret):0) - 1;
|
||||||
$post_max_size = @ini_get('client_max_body_size');
|
$post_max_size = @ini_get('client_max_body_size');
|
||||||
if($post_max_size == ''){
|
if($post_max_size == ''){
|
||||||
$post_max_size = @ini_get('post_max_size');
|
$post_max_size = @ini_get('post_max_size');
|
||||||
|
@ -110,7 +110,7 @@ class Umkreissuche
|
|||||||
if(strlen($this->plz) > 1){
|
if(strlen($this->plz) > 1){
|
||||||
try {
|
try {
|
||||||
$plzundland = explode(' ', $this->plz);
|
$plzundland = explode(' ', $this->plz);
|
||||||
if(count($plzundland) > 1) {
|
if((!empty($plzundland)?count($plzundland):0) > 1) {
|
||||||
$res = $this->plzToCoord($plzundland[0], $plzundland[1]);
|
$res = $this->plzToCoord($plzundland[0], $plzundland[1]);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
@ -374,8 +374,8 @@ class Umkreissuche
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
*/
|
*/
|
||||||
if(count($this->adresses) > 200){
|
if((!empty($this->adresses)?count($this->adresses):0) > 200){
|
||||||
$this->errorMsg = 'Zu viele Treffer (' . count($this->adresses) . '), bitte Suchradius verringern';
|
$this->errorMsg = 'Zu viele Treffer (' . (!empty($this->adresses)?count($this->adresses):0) . '), bitte Suchradius verringern';
|
||||||
}
|
}
|
||||||
if($new > 0){
|
if($new > 0){
|
||||||
$this->displayInfo("$new adressen neu konvertiert");
|
$this->displayInfo("$new adressen neu konvertiert");
|
||||||
@ -458,7 +458,7 @@ class Umkreissuche
|
|||||||
|
|
||||||
foreach ($result->results as $key => $value) {
|
foreach ($result->results as $key => $value) {
|
||||||
//Für jede zurückgegebene Adresse, durchsuche Komponenten nach Länderkennung
|
//Für jede zurückgegebene Adresse, durchsuche Komponenten nach Länderkennung
|
||||||
$cadress_components = count($value->address_components);
|
$cadress_components = (!empty($value->address_components)?count($value->address_components):0);
|
||||||
for ($i=0; $i < $cadress_components; $i++) {
|
for ($i=0; $i < $cadress_components; $i++) {
|
||||||
if($value->address_components[$i]->short_name == $land){
|
if($value->address_components[$i]->short_name == $land){
|
||||||
//Bei Fund der Länderkennung Geodatenspeichern und zurückgeben
|
//Bei Fund der Länderkennung Geodatenspeichern und zurückgeben
|
||||||
|
@ -505,7 +505,7 @@ class Verkaufszahlen {
|
|||||||
if(!empty($diagramme))
|
if(!empty($diagramme))
|
||||||
{
|
{
|
||||||
$projektefirst = $this->GetDiagrammProjekte($diagramme[0]['id'],true);
|
$projektefirst = $this->GetDiagrammProjekte($diagramme[0]['id'],true);
|
||||||
if(count($diagramme) <= 1)
|
if((!empty($diagramme)?count($diagramme):0) <= 1)
|
||||||
{
|
{
|
||||||
$this->app->Tpl->Set('VORDEAKTIVIEREN','/*');
|
$this->app->Tpl->Set('VORDEAKTIVIEREN','/*');
|
||||||
$this->app->Tpl->Set('NACHDEAKTIVIEREN','*/');
|
$this->app->Tpl->Set('NACHDEAKTIVIEREN','*/');
|
||||||
@ -523,7 +523,7 @@ class Verkaufszahlen {
|
|||||||
|
|
||||||
$projekte_arr = $this->app->DB->SelectArr("SELECT id as projekt FROM projekt WHERE verkaufszahlendiagram='1' AND geloescht!='1' ".$this->app->erp->ProjektRechte('id').' order by abkuerzung');
|
$projekte_arr = $this->app->DB->SelectArr("SELECT id as projekt FROM projekt WHERE verkaufszahlendiagram='1' AND geloescht!='1' ".$this->app->erp->ProjektRechte('id').' order by abkuerzung');
|
||||||
if(!empty($projekte_arr)){
|
if(!empty($projekte_arr)){
|
||||||
$cprojekte_arr = count($projekte_arr);
|
$cprojekte_arr = (!empty($projekte_arr)?count($projekte_arr):0);
|
||||||
for ($i = 0; $i < $cprojekte_arr; $i++) {
|
for ($i = 0; $i < $cprojekte_arr; $i++) {
|
||||||
$projekte[] = $projekte_arr[$i]['projekt'];
|
$projekte[] = $projekte_arr[$i]['projekt'];
|
||||||
|
|
||||||
@ -534,7 +534,7 @@ class Verkaufszahlen {
|
|||||||
$farbe = '#eee';
|
$farbe = '#eee';
|
||||||
}
|
}
|
||||||
|
|
||||||
if($i < count($projekte_arr) - 1){
|
if($i < (!empty($projekte_arr)?count($projekte_arr):0) - 1){
|
||||||
$this->app->Tpl->Add('PLOTLEGENDS', '{ label: "' . $abkuerzung . '", data: d' . ($i + 1) . ', color: "' . $farbe . '"},');
|
$this->app->Tpl->Add('PLOTLEGENDS', '{ label: "' . $abkuerzung . '", data: d' . ($i + 1) . ', color: "' . $farbe . '"},');
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
|
@ -207,7 +207,7 @@ class Versandarten {
|
|||||||
try {
|
try {
|
||||||
$r = new ReflectionMethod($classname, '__construct');
|
$r = new ReflectionMethod($classname, '__construct');
|
||||||
$params = $r->getParameters();
|
$params = $r->getParameters();
|
||||||
$anzargs = count($params);
|
$anzargs = (!empty($params)?count($params):0);
|
||||||
}
|
}
|
||||||
catch(Exception $e) {
|
catch(Exception $e) {
|
||||||
$anzargs = 1;
|
$anzargs = 1;
|
||||||
@ -329,12 +329,12 @@ class Versandarten {
|
|||||||
))
|
))
|
||||||
{
|
{
|
||||||
$typa = explode('_', $input['typ']);
|
$typa = explode('_', $input['typ']);
|
||||||
if(count($typa) == 1 || !is_numeric($typa[count($typa)-1]))
|
if((!empty($typa)?(!empty($typa)?count($typa):0):0) == 1 || !is_numeric($typa[count($typa)-1]))
|
||||||
{
|
{
|
||||||
$input['typ'] .= '_1';
|
$input['typ'] .= '_1';
|
||||||
}else{
|
}else{
|
||||||
$counter = $typa[count($typa)-1]+1;
|
$counter = $typa[(!empty($typa)?count($typa):0)-1]+1;
|
||||||
unset($typa[count($typa)-1]);
|
unset($typa[(!empty($typa)?count($typa):0)-1]);
|
||||||
$input['typ'] = implode('_', $typa).'_'.$counter;
|
$input['typ'] = implode('_', $typa).'_'.$counter;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -396,12 +396,12 @@ class Versandarten {
|
|||||||
|
|
||||||
while($this->app->DB->Select(sprintf("SELECT `id` FROM `versandarten` WHERE `type` = '%s' LIMIT 1", $input['typ']))) {
|
while($this->app->DB->Select(sprintf("SELECT `id` FROM `versandarten` WHERE `type` = '%s' LIMIT 1", $input['typ']))) {
|
||||||
$typa = explode('_', $input['typ']);
|
$typa = explode('_', $input['typ']);
|
||||||
if(count($typa) == 1 || !is_numeric($typa[count($typa)-1]))
|
if((!empty($typa)?(!empty($typa)?count($typa):0):0) == 1 || !is_numeric($typa[count($typa)-1]))
|
||||||
{
|
{
|
||||||
$input['typ'] .= '_1';
|
$input['typ'] .= '_1';
|
||||||
}else{
|
}else{
|
||||||
$counter = $typa[count($typa)-1]+1;
|
$counter = $typa[(!empty($typa)?count($typa):0)-1]+1;
|
||||||
unset($typa[count($typa)-1]);
|
unset($typa[(!empty($typa)?count($typa):0)-1]);
|
||||||
$input['typ'] = implode('_', $typa).'_'.$counter;
|
$input['typ'] = implode('_', $typa).'_'.$counter;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -839,7 +839,7 @@ class Versandarten {
|
|||||||
}
|
}
|
||||||
$form = $obj->getCreateForm();
|
$form = $obj->getCreateForm();
|
||||||
if(!empty($form)) {
|
if(!empty($form)) {
|
||||||
$form[count($form) - 1]['link'] = [
|
$form[(!empty($form)?count($form):0) - 1]['link'] = [
|
||||||
'link' => 'index.php?module=versandarten&action=create&auswahl=' . $module,
|
'link' => 'index.php?module=versandarten&action=create&auswahl=' . $module,
|
||||||
'title' => 'Expertenmodus',
|
'title' => 'Expertenmodus',
|
||||||
];
|
];
|
||||||
|
@ -245,7 +245,7 @@ class Wareneingang
|
|||||||
'Nummer', 'Beschreibung', 'Retoure', 'Datum', 'Projekt', 'Menge',
|
'Nummer', 'Beschreibung', 'Retoure', 'Datum', 'Projekt', 'Menge',
|
||||||
'Geliefert', 'Offen', 'Aktion'
|
'Geliefert', 'Offen', 'Aktion'
|
||||||
);
|
);
|
||||||
$menucol = count($heading);
|
$menucol = (!empty($heading)?count($heading):0);
|
||||||
$width = array('5%', '5%', '5%', '30%', '5%', '5%', '5%', '5%', '5%', '5%');
|
$width = array('5%', '5%', '5%', '30%', '5%', '5%', '5%', '5%', '5%', '5%');
|
||||||
$findcols = array('art.nummer','art.name_de', 'b.belegnr',
|
$findcols = array('art.nummer','art.name_de', 'b.belegnr',
|
||||||
"DATE_FORMAT(b.datum,'%d.%m.%Y')",
|
"DATE_FORMAT(b.datum,'%d.%m.%Y')",
|
||||||
@ -2350,7 +2350,7 @@ class Wareneingang
|
|||||||
if($etiketten=='') {
|
if($etiketten=='') {
|
||||||
$etiketten='artikel_klein';
|
$etiketten='artikel_klein';
|
||||||
}
|
}
|
||||||
if(!empty($tmpdataseriennummern) && is_array($tmpdataseriennummern) && count($tmpdataseriennummern)>0) {
|
if(!empty($tmpdataseriennummern) && is_array($tmpdataseriennummern) && (!empty($tmpdataseriennummern)?count($tmpdataseriennummern):0)>0) {
|
||||||
if($etiketten!=='keineetiketten') {
|
if($etiketten!=='keineetiketten') {
|
||||||
foreach($tmpdataseriennummern as $srn) {
|
foreach($tmpdataseriennummern as $srn) {
|
||||||
$data['seriennummer']=$srn;
|
$data['seriennummer']=$srn;
|
||||||
@ -2949,7 +2949,7 @@ public function WareneingangPaketannahme()
|
|||||||
}
|
}
|
||||||
$this->app->Tpl->Add('INFO','<div class="warning">Es wurde keine offene Bestellung mit diesem Artikel gefunden.</div>');
|
$this->app->Tpl->Add('INFO','<div class="warning">Es wurde keine offene Bestellung mit diesem Artikel gefunden.</div>');
|
||||||
}
|
}
|
||||||
elseif(count($best) > 1) {
|
elseif((!empty($best)?count($best):0) > 1) {
|
||||||
$this->app->Tpl->Add('INFO','<div class="warning">Es wurden mehrere offene Bestellung mit diesem Artikel gefunden.</div>');
|
$this->app->Tpl->Add('INFO','<div class="warning">Es wurden mehrere offene Bestellung mit diesem Artikel gefunden.</div>');
|
||||||
}else{
|
}else{
|
||||||
$vorlage = 'bestellung';
|
$vorlage = 'bestellung';
|
||||||
@ -3024,7 +3024,7 @@ public function WareneingangPaketannahme()
|
|||||||
if(!$this->app->erp->RechteVorhanden('wareneingang','distriabschluss')){
|
if(!$this->app->erp->RechteVorhanden('wareneingang','distriabschluss')){
|
||||||
$rechteproblem[] = 'distriabschluss';
|
$rechteproblem[] = 'distriabschluss';
|
||||||
}
|
}
|
||||||
if(count($rechteproblem) > 0){
|
if((!empty($rechteproblem)?count($rechteproblem):0) > 0){
|
||||||
$this->app->Tpl->Set('INFO','<br /><div class="info">Es werden im Menü nicht alle Icons angezeigt, da die nötigen Rechte nicht vorliegen für: Wareneingang > '.implode(', ', $rechteproblem).'</div>');
|
$this->app->Tpl->Set('INFO','<br /><div class="info">Es werden im Menü nicht alle Icons angezeigt, da die nötigen Rechte nicht vorliegen für: Wareneingang > '.implode(', ', $rechteproblem).'</div>');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -373,7 +373,7 @@ class Welcome
|
|||||||
protected function GetMeineApps()
|
protected function GetMeineApps()
|
||||||
{
|
{
|
||||||
if(is_array($this->_meineapps)) {
|
if(is_array($this->_meineapps)) {
|
||||||
return count($this->_meineapps);
|
return (!empty($this->_meineapps)?count($this->_meineapps):0);
|
||||||
}
|
}
|
||||||
|
|
||||||
$anz = 0;
|
$anz = 0;
|
||||||
@ -1759,7 +1759,7 @@ $this->app->Tpl->Add('TAB1',"<h2>Schritt 1 von 2: Dateien aktualisieren</h2><tab
|
|||||||
$this->app->erp->check_column_missing_run = true;
|
$this->app->erp->check_column_missing_run = true;
|
||||||
$this->app->erp->UpgradeDatabase();
|
$this->app->erp->UpgradeDatabase();
|
||||||
|
|
||||||
if(count($this->app->erp->check_column_missing) > 0)
|
if((!empty($this->app->erp->check_column_missing)?count($this->app->erp->check_column_missing):0) > 0)
|
||||||
{
|
{
|
||||||
$result .= "\r\n**** INFORMATION DATENBANK ****\r\n";
|
$result .= "\r\n**** INFORMATION DATENBANK ****\r\n";
|
||||||
foreach($this->app->erp->check_column_missing as $tablename=>$columns)
|
foreach($this->app->erp->check_column_missing as $tablename=>$columns)
|
||||||
@ -1771,7 +1771,7 @@ $this->app->Tpl->Add('TAB1',"<h2>Schritt 1 von 2: Dateien aktualisieren</h2><tab
|
|||||||
}
|
}
|
||||||
$result .= "\r\n**** INFORMATION DATENBANK ****\r\n\r\n";
|
$result .= "\r\n**** INFORMATION DATENBANK ****\r\n\r\n";
|
||||||
}
|
}
|
||||||
if(count($this->app->erp->check_index_missing) > 0)
|
if((!empty($this->app->erp->check_index_missing)?count($this->app->erp->check_index_missing):0) > 0)
|
||||||
{
|
{
|
||||||
$result .= "\r\n**** INFORMATION DATENBANK INDEXE ****\r\n";
|
$result .= "\r\n**** INFORMATION DATENBANK INDEXE ****\r\n";
|
||||||
foreach($this->app->erp->check_index_missing as $tablename=>$columns)
|
foreach($this->app->erp->check_index_missing as $tablename=>$columns)
|
||||||
@ -1852,7 +1852,7 @@ $this->app->Tpl->Add('TAB1',"<h2>Schritt 2 von 2: Datenbank anpassen</h2><table
|
|||||||
}</script>';
|
}</script>';
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!$termine || count($termine)==0) {
|
if(!$termine || (!empty($termine)?count($termine):0)==0) {
|
||||||
$out = '<center><i>{|Keine Termine vorhanden|}</i></center>';
|
$out = '<center><i>{|Keine Termine vorhanden|}</i></center>';
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2321,7 +2321,7 @@ $this->app->Tpl->Add('TAB1',"<h2>Schritt 2 von 2: Datenbank anpassen</h2><table
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Einzelne Datei herunterladen
|
// Einzelne Datei herunterladen
|
||||||
if (count($unprinted) === 1) {
|
if ((!empty($unprinted)?count($unprinted):0) === 1) {
|
||||||
$this->DownloadSpoolerFile($unprinted[0]);
|
$this->DownloadSpoolerFile($unprinted[0]);
|
||||||
} else {
|
} else {
|
||||||
$this->DownloadSpoolerZipCompilation($unprinted, $printerId);
|
$this->DownloadSpoolerZipCompilation($unprinted, $printerId);
|
||||||
@ -2746,7 +2746,7 @@ $this->app->Tpl->Add('TAB1',"<h2>Schritt 2 von 2: Datenbank anpassen</h2><table
|
|||||||
$params = explode('&',$url['query']);
|
$params = explode('&',$url['query']);
|
||||||
foreach($params as $value){
|
foreach($params as $value){
|
||||||
$attribut = explode('=',$value);
|
$attribut = explode('=',$value);
|
||||||
$arrPara[$attribut[0]] = count($attribut) > 1?$attribut[1]:'';
|
$arrPara[$attribut[0]] = (!empty($attribut)?count($attribut):0) > 1?$attribut[1]:'';
|
||||||
}
|
}
|
||||||
|
|
||||||
$adresse = $this->app->User->GetAdresse();
|
$adresse = $this->app->User->GetAdresse();
|
||||||
|
@ -453,7 +453,7 @@ class Zahlungsweisen {
|
|||||||
$form = $obj->getCreateForm();
|
$form = $obj->getCreateForm();
|
||||||
|
|
||||||
if(!empty($form)) {
|
if(!empty($form)) {
|
||||||
$form[count($form) - 1]['link'] = [
|
$form[(!empty($form)?count($form):0) - 1]['link'] = [
|
||||||
'link' => 'index.php?module=zahlungsweisen&action=create&auswahl=' . $module,
|
'link' => 'index.php?module=zahlungsweisen&action=create&auswahl=' . $module,
|
||||||
'title' => 'Expertenmodus',
|
'title' => 'Expertenmodus',
|
||||||
];
|
];
|
||||||
@ -1013,13 +1013,13 @@ class Zahlungsweisen {
|
|||||||
)
|
)
|
||||||
) {
|
) {
|
||||||
$typa = explode('_', $input['type']);
|
$typa = explode('_', $input['type']);
|
||||||
if(count($typa) == 1 || !is_numeric($typa[count($typa)-1]))
|
if((!empty($typa)?(!empty($typa)?count($typa):0):0) == 1 || !is_numeric($typa[count($typa)-1]))
|
||||||
{
|
{
|
||||||
$input['type'] .= '_1';
|
$input['type'] .= '_1';
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
$counter = $typa[count($typa)-1]+1;
|
$counter = $typa[(!empty($typa)?count($typa):0)-1]+1;
|
||||||
unset($typa[count($typa)-1]);
|
unset($typa[(!empty($typa)?count($typa):0)-1]);
|
||||||
$input['type'] = implode('_', $typa).'_'.$counter;
|
$input['type'] = implode('_', $typa).'_'.$counter;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1093,12 +1093,12 @@ class Zahlungsweisen {
|
|||||||
)
|
)
|
||||||
) {
|
) {
|
||||||
$typa = explode('_', $input['type']);
|
$typa = explode('_', $input['type']);
|
||||||
if(count($typa) == 1 || !is_numeric($typa[count($typa)-1])) {
|
if((!empty($typa)?(!empty($typa)?count($typa):0):0) == 1 || !is_numeric($typa[count($typa)-1])) {
|
||||||
$input['type'] .= '_1';
|
$input['type'] .= '_1';
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
$counter = $typa[count($typa)-1]+1;
|
$counter = $typa[(!empty($typa)?count($typa):0)-1]+1;
|
||||||
unset($typa[count($typa)-1]);
|
unset($typa[(!empty($typa)?count($typa):0)-1]);
|
||||||
$input['type'] = implode('_', $typa).'_'.$counter;
|
$input['type'] = implode('_', $typa).'_'.$counter;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -432,7 +432,7 @@ class Zeiterfassung { //extends GenZeiterfassung {
|
|||||||
|
|
||||||
// Data
|
// Data
|
||||||
$fill = false;
|
$fill = false;
|
||||||
for($i=0;$i<count($tmp);$i++)
|
for($i=0;$i<(!empty($tmp)?count($tmp):0);$i++)
|
||||||
{
|
{
|
||||||
if($tmp[$i]["prio"]==0) $prio="";
|
if($tmp[$i]["prio"]==0) $prio="";
|
||||||
else if($tmp[$i]["prio"]==1) $prio="Ja";
|
else if($tmp[$i]["prio"]==1) $prio="Ja";
|
||||||
|
Loading…
Reference in New Issue
Block a user