本文整理汇总了PHP中products_minierp::retrieveList方法的典型用法代码示例。如果您正苦于以下问题:PHP products_minierp::retrieveList方法的具体用法?PHP products_minierp::retrieveList怎么用?PHP products_minierp::retrieveList使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类products_minierp
的用法示例。
在下文中一共展示了products_minierp::retrieveList方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: array
$value = $brand_id;
$type = str_replace('set-', '', $type);
} else {
$pbgs = array('value' => $value);
tep_db_perform('products_best_good_settings', $pbgs, 'update', "id={$type}");
}
$result['type'] = $type;
$result['value'] = $value;
ajaxReturn($result);
exit;
} elseif ($_POST['me_action'] == 'RECALCMARGIN') {
set_time_limit(0);
use_class('logger');
$logger = new logger('cron', 'daily-counter-products-matexp');
$logger->write('Margin is recalculated manually by ' . $session_userinfo['username']);
$products = $class_pm->retrieveList("active_status=1");
$pcounter = 0;
foreach ($products as $p) {
$pcounter++;
$class_pm->updateMargin($p['products_id']);
echo '. ';
}
$logger->write($pcounter . ' products updated successfully');
$logger->close();
echo 'DONE!';
exit;
}
}
$sop_mouse_over = array();
$sop_mouse_over['hide_hard'] = 'Report 0 stock for products with Hard Complexity and no depot stock on J&G and all SP Websites';
$sop_mouse_over['hide_extreme'] = 'Report 0 stock for products with Extreme Complexity and no depot stock on J&G and all SP Websites';
示例2: elseif
}
//PAGE INITALIZER (Finding what parameters are sent to module)
$showsearchform = true;
if (isset($_POST['product']) || isset($_GET['product'])) {
$p = tep_db_prepare_input(isset($_POST['product']) ? $_POST['product'] : $_GET['product']);
if ($p == '') {
$messagebox->add('Please enter a Product ID / Code / EAN');
} elseif (strlen($p) == 13 && is_numeric($p)) {
$pinfo = $class_ean->getProductArticle($p);
$pid = $pinfo['products_id'];
$aid = $pinfo['products_articles_id'];
$ps = $class_pm->stockRetrieveDetail($fg_whid, $pid, $aid);
openStockDetail($ps['products_stock_id']);
} else {
if (substr($p, 0, 1) == '0') {
$products = $class_pm->retrieveList("products_model='{$p}'");
if (count($products) > 0) {
$p = $products[0]['products_id'];
}
}
$articles = $class_pa->retrieveList($p);
if (count($articles) == 0) {
$ps = $class_pm->stockRetrieveDetail($fg_whid, $p, '0');
if (!is_null($ps)) {
openStockDetail($ps['products_stock_id']);
}
} else {
$content .= drawProductInfo($p, $articles);
$content .= '<h3 style="clear:both;padding-top:30px;">or open another product below</h3>';
}
}
示例3: IN
<?php
//SUBMIT ACTION
$PR_SUSPICIOUS_LIMIT = 10;
if (isset($_POST)) {
if ($_POST['me_action'] == 'RECOUNTPRODUCTSMATEXPENSES') {
$products_id = tep_db_prepare_input($_POST['products_id']);
use_class("products_minierp");
$class_pm = new products_minierp();
$filter = $products_id == '*' ? 'material_expenses=0' : "products_id IN ({$products_id})";
$products = $class_pm->retrieveList($filter);
foreach ($products as $p) {
$class_pm->calculateMaterialExpenses($p['products_id']);
}
$messagebox->add('Material Expenses is Recalculated', 'green');
} elseif ($_POST['me_action'] == 'RECOUNTPRODUCTSBOUGHT') {
tep_db_query("UPDATE products SET products_ordered=0");
$products_query = tep_db_query("SELECT op.products_id, COUNT(op.products_id) AS count_result FROM orders_products op INNER JOIN orders o ON o.orders_id=op.orders_id AND o.orders_status<=10 GROUP BY op.products_id");
while ($row = tep_db_fetch_array($products_query)) {
$product_id = $row['products_id'];
$count_result = $row['count_result'];
$recount_query = "UPDATE products SET products_ordered={$count_result} WHERE products_id={$product_id}";
tep_db_query($recount_query);
}
$messagebox->add('Products Bought is Recount', 'green');
} elseif ($_POST['me_action'] == 'RECOUNTPRODUCTSRATING') {
if (isset($_POST['products_id']) && $_POST['products_id'] != '') {
$products_id = tep_db_prepare_input($_POST['products_id']);
$counter = 0;
if ($products_id == '*') {
$ratequery = tep_db_query("SELECT products_id, COUNT(products_id) AS total_rated, SUM(rating_point)/COUNT(rating_point) AS rate_point FROM products_rating GROUP BY products_id");