当前位置: 首页>>代码示例>>PHP>>正文


PHP AttributeKeyCategory::getList方法代码示例

本文整理汇总了PHP中AttributeKeyCategory::getList方法的典型用法代码示例。如果您正苦于以下问题:PHP AttributeKeyCategory::getList方法的具体用法?PHP AttributeKeyCategory::getList怎么用?PHP AttributeKeyCategory::getList使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在AttributeKeyCategory的用法示例。


在下文中一共展示了AttributeKeyCategory::getList方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: parseManual

 /**
  * {@inheritdoc}
  *
  * @see \C5TL\Parser\DynamicItem::parseManual()
  */
 public function parseManual(\Gettext\Translations $translations, $concrete5version)
 {
     if (class_exists('\\AttributeKeyCategory', true) && class_exists('\\AttributeSet', true)) {
         foreach (\AttributeKeyCategory::getList() as $akc) {
             foreach ($akc->getAttributeSets() as $as) {
                 $this->addTranslation($translations, $as->getAttributeSetName(), 'AttributeSetName');
             }
         }
     }
 }
开发者ID:ppiedaderawnet,项目名称:concrete5,代码行数:15,代码来源:AttributeSet.php

示例2: save_attribute_type_associations

 public function save_attribute_type_associations()
 {
     $list = AttributeKeyCategory::getList();
     foreach ($list as $cat) {
         $cat->clearAttributeKeyCategoryTypes();
         if (is_array($this->post($cat->getAttributeKeyCategoryHandle()))) {
             foreach ($this->post($cat->getAttributeKeyCategoryHandle()) as $id) {
                 $type = AttributeType::getByID($id);
                 $cat->associateAttributeKeyType($type);
             }
         }
     }
     $this->redirect('dashboard/system/attributes/types', 'saved', 'associations_updated');
 }
开发者ID:ricardomccerqueira,项目名称:rcerqueira.portfolio,代码行数:14,代码来源:types.php

示例3: parseManual

 /**
  * @see \C5TL\Parser\DynamicItem::parseManual()
  */
 public function parseManual(\Gettext\Translations $translations, $concrete5version)
 {
     if (class_exists('\\AttributeKeyCategory', true) && class_exists('\\AttributeKey', true) && class_exists('\\AttributeType', true)) {
         foreach (\AttributeKeyCategory::getList() as $akc) {
             $akcHandle = $akc->getAttributeKeyCategoryHandle();
             foreach (\AttributeKey::getList($akcHandle) as $ak) {
                 if ($ak->getAttributeType()->getAttributeTypeHandle() === 'select') {
                     foreach ($ak->getController()->getOptions() as $option) {
                         $this->addTranslation($translations, $option->getSelectAttributeOptionValue(false), 'SelectAttributeValue');
                     }
                 }
             }
         }
     }
 }
开发者ID:ngreimel,项目名称:kovent,代码行数:18,代码来源:SelectAttributeValue.php

示例4: defined

<? defined('C5_EXECUTE') or die("Access Denied.");

$types = AttributeType::getList();
$categories = AttributeKeyCategory::getList();
$txt = Loader::helper('text');
$form = Loader::helper('form');
$interface = Loader::helper('concrete/interface');

echo Loader::helper('concrete/dashboard')->getDashboardPaneHeaderWrapper(t('Attribute Type Associations'), false, 'span12 offset2');?>
<form method="post" class="" id="attribute_type_associations_form" action="<?=$this->action('save_attribute_type_associations')?>">
	<table border="0" cellspacing="1" cellpadding="0" border="0" class="zebra-striped">
		<tr>
			<th><?=t('Name')?></th>
			<? foreach($categories as $cat) { ?>
				<th><?=$txt->unhandle($cat->getAttributeKeyCategoryHandle())?></th>
			<? } ?>
		</tr>
		<?php foreach($types as $at) { ?>

			<tr>
				<td><?=$at->getAttributeTypeName()?></td>
				<? foreach($categories as $cat) { ?>
					<td style="width: 1px; text-align: center"><?=$form->checkbox($cat->getAttributeKeyCategoryHandle() . '[]', $at->getAttributeTypeID(), $at->isAssociatedWithCategory($cat))?></td>
				<? } ?>
			</tr>

		<? } ?>

	</table>
	<div class="well clearfix">
	<?
开发者ID:nbourguig,项目名称:concrete5,代码行数:31,代码来源:types.php

示例5: exportList

 public static function exportList($xml)
 {
     $categories = AttributeKeyCategory::getList();
     $axml = $xml->addChild('attributekeys');
     foreach ($categories as $cat) {
         $attributes = AttributeKey::getList($cat->getAttributeKeyCategoryHandle());
         foreach ($attributes as $at) {
             $at->export($axml);
         }
     }
 }
开发者ID:ojalehto,项目名称:concrete5-legacy,代码行数:11,代码来源:key.php

示例6: view

 public function view()
 {
     $this->set('categories', AttributeKeyCategory::getList());
 }
开发者ID:ojalehto,项目名称:concrete5-legacy,代码行数:4,代码来源:sets.php


注:本文中的AttributeKeyCategory::getList方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。