本文整理汇总了PHP中ExtraFields::deleteOptionFromColumn方法的典型用法代码示例。如果您正苦于以下问题:PHP ExtraFields::deleteOptionFromColumn方法的具体用法?PHP ExtraFields::deleteOptionFromColumn怎么用?PHP ExtraFields::deleteOptionFromColumn使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ExtraFields
的用法示例。
在下文中一共展示了ExtraFields::deleteOptionFromColumn方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: onCustomizeExtraFields
private function onCustomizeExtraFields()
{
if ($this->_realAccessLevel < ACCESS_LEVEL_SA) {
CommonErrors::fatal(COMMONERROR_PERMISSION, $this);
return;
//$this->fatal(ERROR_NO_PERMISSION);
}
$extraFieldsMaintScript = $this->getTrimmedInput('commandList', $_POST);
$extraFieldsMaintScriptArray = explode(',', $extraFieldsMaintScript);
foreach ($extraFieldsMaintScriptArray as $index => $commandEncoded) {
$command = urldecode($commandEncoded);
$args = explode(' ', $command);
if (!isset($args[0])) {
continue;
}
switch ($args[0]) {
case 'ADDFIELD':
$args = explode(' ', $command, 4);
$extraFields = new ExtraFields($this->_siteID, intval($args[1]));
$extraFields->define(urldecode($args[3]), intval($args[2]));
break;
case 'DELETEFIELD':
$args = explode(' ', $command, 3);
$extraFields = new ExtraFields($this->_siteID, intval($args[1]));
$extraFields->remove(urldecode($args[2]));
break;
case 'ADDOPTION':
$args = explode(' ', $command, 3);
$args2 = explode(':', $args[2]);
$extraFields = new ExtraFields($this->_siteID, intval($args[1]));
$extraFields->addOptionToColumn(urldecode($args2[0]), urldecode($args2[1]));
break;
case 'DELETEOPTION':
$args = explode(' ', $command, 3);
$args2 = explode(':', $args[2]);
$extraFields = new ExtraFields($this->_siteID, intval($args[1]));
$extraFields->deleteOptionFromColumn(urldecode($args2[0]), urldecode($args2[1]));
break;
case 'SWAPFIELDS':
$args = explode(' ', $command, 3);
$args2 = explode(':', $args[2]);
$extraFields = new ExtraFields($this->_siteID, intval($args[1]));
$extraFields->swapColumns(urldecode($args2[0]), urldecode($args2[1]));
break;
case 'RENAMEROW':
$args = explode(' ', $command, 3);
$args2 = explode(':', $args[2]);
$extraFields = new ExtraFields($this->_siteID, intval($args[1]));
$extraFields->renameColumn(urldecode($args2[0]), urldecode($args2[1]));
break;
}
}
CATSUtility::transferRelativeURI('m=settings&a=customizeExtraFields');
}