CMXX - Update whereclause get/post
This commit is contained in:
@@ -12,7 +12,7 @@ $pdo = dbConnect($dbname);
|
||||
if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} else {$soldto_search = '-%';}
|
||||
|
||||
//default whereclause
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner,'get');
|
||||
|
||||
|
||||
//NEW ARRAY
|
||||
|
||||
@@ -30,7 +30,7 @@ if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} el
|
||||
//default whereclause
|
||||
//------------------------------------------
|
||||
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner,'get');
|
||||
|
||||
//------------------------------------------
|
||||
//NEW ARRAY
|
||||
|
||||
@@ -12,7 +12,7 @@ $pdo = dbConnect($dbname);
|
||||
if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} else {$soldto_search = '-%';}
|
||||
|
||||
//default whereclause
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner,'get');
|
||||
|
||||
|
||||
//NEW ARRAY
|
||||
|
||||
@@ -12,7 +12,7 @@ $pdo = dbConnect($dbname);
|
||||
if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} else {$soldto_search = '-%';}
|
||||
|
||||
//default whereclause
|
||||
list($whereclause,$condition) = getWhereclauselvl2('communications',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclauselvl2('communications',$permission,$partner,'get');
|
||||
|
||||
//NEW ARRAY
|
||||
$criterias = [];
|
||||
|
||||
@@ -15,7 +15,7 @@ $partner = json_decode($partnerhierarchy);
|
||||
if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} else {$soldto_search = '-%';}
|
||||
|
||||
//default whereclause
|
||||
list($whereclause,$condition) = getWhereclause('equipment',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclause('equipment',$permission,$partner,'get');
|
||||
|
||||
//------------------------------------------
|
||||
//NEW ARRAY
|
||||
|
||||
@@ -16,7 +16,7 @@ $partner = json_decode($partnerhierarchy);
|
||||
if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} else {$soldto_search = '-%';}
|
||||
|
||||
//default whereclause
|
||||
list($whereclause,$condition) = getWhereclause('equipment',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclause('equipment',$permission,$partner,'get');
|
||||
|
||||
//------------------------------------------
|
||||
//NEW ARRAY
|
||||
|
||||
@@ -12,7 +12,7 @@ $pdo = dbConnect($dbname);
|
||||
if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} else {$soldto_search = '-%';}
|
||||
|
||||
//default whereclause
|
||||
list($whereclause,$condition) = getWhereclauselvl2('partners',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclauselvl2('partners',$permission,$partner,'get');
|
||||
|
||||
//NEW ARRAY
|
||||
$criterias = [];
|
||||
|
||||
@@ -14,7 +14,7 @@ if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} el
|
||||
//default whereclause
|
||||
$whereclause = '';
|
||||
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner,'get');
|
||||
|
||||
//NEW ARRAY
|
||||
$criterias = [];
|
||||
|
||||
@@ -14,7 +14,7 @@ if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} el
|
||||
//default whereclause
|
||||
$whereclause = '';
|
||||
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner,'get');
|
||||
|
||||
//NEW ARRAY
|
||||
$criterias = [];
|
||||
|
||||
@@ -14,7 +14,7 @@ if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} el
|
||||
//default whereclause
|
||||
$whereclause = '';
|
||||
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner,'get');
|
||||
|
||||
//NEW ARRAY
|
||||
$criterias = [];
|
||||
|
||||
@@ -12,7 +12,7 @@ $partner = json_decode($partnerhierarchy);
|
||||
if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} else {$soldto_search = '-%';}
|
||||
|
||||
//default whereclause
|
||||
list($whereclause,$condition) = getWhereclause('profile',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclause('profile',$permission,$partner,'get');
|
||||
|
||||
//NEW ARRAY
|
||||
$criterias = [];
|
||||
|
||||
@@ -12,7 +12,7 @@ $partner = json_decode($partnerhierarchy);
|
||||
if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} else {$soldto_search = '-%';}
|
||||
|
||||
//default whereclause
|
||||
list($whereclause,$condition) = getWhereclause('profile',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclause('profile',$permission,$partner,'get');
|
||||
|
||||
//NEW ARRAY
|
||||
$criterias = [];
|
||||
|
||||
@@ -14,7 +14,7 @@ $post_content = json_decode(decode_payload($input),true);
|
||||
if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} else {$soldto_search = '-%';}
|
||||
|
||||
//default whereclause
|
||||
list($whereclause,$condition) = getWhereclause('equipment',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclause('equipment',$permission,$partner,'');
|
||||
|
||||
|
||||
//SET PARAMETERS FOR QUERY
|
||||
|
||||
@@ -14,7 +14,7 @@ $post_content = json_decode(decode_payload($input),true);
|
||||
if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} else {$soldto_search = '-%';}
|
||||
|
||||
//default whereclause
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner,'');
|
||||
|
||||
|
||||
//SET PARAMETERS FOR QUERY
|
||||
|
||||
@@ -16,7 +16,7 @@ if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} el
|
||||
//default whereclause
|
||||
$whereclause = '';
|
||||
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner,'');
|
||||
|
||||
//SET PARAMETERS FOR QUERY
|
||||
$id = $post_content['rowID'] ?? ''; //check for rowID
|
||||
|
||||
@@ -16,7 +16,7 @@ if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} el
|
||||
//default whereclause
|
||||
$whereclause = '';
|
||||
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner,'');
|
||||
|
||||
//SET PARAMETERS FOR QUERY
|
||||
$id = $post_content['rowID'] ?? ''; //check for rowID
|
||||
|
||||
@@ -14,7 +14,7 @@ $post_content = json_decode(decode_payload($input),true);
|
||||
if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} else {$soldto_search = '-%';}
|
||||
|
||||
//default whereclause to check if data is owned by user
|
||||
list($whereclause,$condition) = getWhereclauselvl2('partners',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclauselvl2('partners',$permission,$partner,'');
|
||||
|
||||
//SET PARAMETERS FOR QUERY
|
||||
$id = $post_content['partnerID'] ?? ''; //check for rowID
|
||||
|
||||
@@ -14,7 +14,7 @@ $post_content = json_decode(decode_payload($input),true);
|
||||
if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} else {$soldto_search = '-%';}
|
||||
|
||||
//default whereclause
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner,'');
|
||||
|
||||
|
||||
//SET PARAMETERS FOR QUERY
|
||||
|
||||
@@ -14,7 +14,7 @@ $post_content = json_decode(decode_payload($input),true);
|
||||
if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} else {$soldto_search = '-%';}
|
||||
|
||||
//default whereclause
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner,'');
|
||||
|
||||
|
||||
//ENSURE PRODUCTROWID IS SEND
|
||||
|
||||
@@ -14,7 +14,7 @@ $post_content = json_decode(decode_payload($input),true);
|
||||
if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} else {$soldto_search = '-%';}
|
||||
|
||||
//default whereclause
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclause('',$permission,$partner,'');
|
||||
|
||||
|
||||
//ENSURE PRODUCTROWID IS SEND
|
||||
|
||||
@@ -15,7 +15,7 @@ $owner_user = 0;
|
||||
if (empty($partner->soldto) || $partner->soldto == ''){$soldto_search = '%';} else {$soldto_search = '-%';}
|
||||
|
||||
//default whereclause to check if data is owned by user
|
||||
list($whereclause,$condition) = getWhereclause('profile',$permission,$partner);
|
||||
list($whereclause,$condition) = getWhereclause('profile',$permission,$partner,'');
|
||||
|
||||
|
||||
//SET PARAMETERS FOR QUERY
|
||||
|
||||
Reference in New Issue
Block a user