本文整理匯總了PHP中FeatureValue::deleteMulti方法的典型用法代碼示例。如果您正苦於以下問題:PHP FeatureValue::deleteMulti方法的具體用法?PHP FeatureValue::deleteMulti怎麽用?PHP FeatureValue::deleteMulti使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類FeatureValue
的用法示例。
在下文中一共展示了FeatureValue::deleteMulti方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: FeatureValue
<?php
if (Tools::G('delete') > 0) {
$feature = new FeatureValue(Tools::G('delete'));
if (Validate::isLoadedObject($feature)) {
$feature->delete();
}
if (is_array($feature->_errors) and count($feature->_errors) > 0) {
$errors = $feature->_errors;
} else {
UIAdminAlerts::conf('商品特征值已刪除');
}
} elseif (Tools::isSubmit('delSelected')) {
$select_cat = Tools::P('itemsBox');
$feature = new FeatureValue();
if ($feature->deleteMulti($select_cat)) {
UIAdminAlerts::conf('商品特征值已刪除');
}
}
/** 輸出錯誤信息 */
if (isset($errors)) {
UIAdminAlerts::MError($errors);
}
/** 導航 */
$breadcrumb = new UIAdminBreadcrumb();
$breadcrumb->home();
$breadcrumb->add(array('title' => '商品特征', 'href' => 'index.php?rule=feature'));
$breadcrumb->add(array('title' => '商品特征值', 'active' => true));
$bread = $breadcrumb->draw();
$btn_group = array(array('type' => 'a', 'title' => '返回', 'href' => 'index.php?rule=feature', 'class' => 'btn-primary', 'icon' => 'level-up'), array('type' => 'a', 'title' => '新商品屬性值', 'href' => 'index.php?rule=feature_value_edit&id_feature=' . Tools::G('id'), 'class' => 'btn-success', 'icon' => 'plus'));
echo UIViewBlock::area(array('bread' => $bread, 'btn_groups' => $btn_group), 'breadcrumb');