public function getAttributesMappedToRealAttributesMetadata() { return array_merge(parent::getAttributesMappedToRealAttributesMetadata(), array('ownedItemsOnly' => array(array('owner', 'id', null, 'resolveValueByRules')))); }
/** * @param array $stickyData * @param SavedDynamicSearchForm $model * @internal param $sourceData */ public static function resolveSearchFormByStickyDataAndModel($stickyData, SavedDynamicSearchForm $model) { assert('$stickyData != null && is_array($stickyData)'); if (isset($stickyData['savedSearchId']) && $stickyData['savedSearchId'] != '') { try { $savedSearch = SavedSearch::getById((int) $stickyData['savedSearchId']); $model->savedSearchName = $savedSearch->name; $model->savedSearchId = $savedSearch->id; } catch (NotFoundException $e) { } } if (isset($stickyData['anyMixedAttributes'])) { $model->anyMixedAttributes = $stickyData['anyMixedAttributes']; } if (isset($stickyData['anyMixedAttributesScope'])) { $model->setAnyMixedAttributesScope($stickyData['anyMixedAttributesScope']); } if (isset($stickyData['dynamicStructure'])) { $model->dynamicStructure = $stickyData['dynamicStructure']; } if (isset($stickyData['dynamicClauses'])) { $model->dynamicClauses = $stickyData['dynamicClauses']; } if (isset($stickyData[SearchForm::SELECTED_LIST_ATTRIBUTES]) && $model->getListAttributesSelector() != null) { $model->getListAttributesSelector()->setSelected($stickyData[SearchForm::SELECTED_LIST_ATTRIBUTES]); } if (isset($stickyData[KanbanBoard::GROUP_BY_ATTRIBUTE_VISIBLE_VALUES]) && $model->getKanbanBoard() != null && !$model->getKanbanBoard()->getClearSticky()) { $model->getKanbanBoard()->setIsActive(); $model->getKanbanBoard()->setGroupByAttributeVisibleValues($stickyData[KanbanBoard::GROUP_BY_ATTRIBUTE_VISIBLE_VALUES]); } if (isset($stickyData[KanbanBoard::SELECTED_THEME]) && $model->getKanbanBoard() != null && !$model->getKanbanBoard()->getClearSticky()) { $model->getKanbanBoard()->setSelectedTheme($stickyData[KanbanBoard::SELECTED_THEME]); } // If the sort attribute is not in get request but in sticky data, set it into get array $listModelClassName = get_class($model->getModel()); if (!isset($_GET[$listModelClassName . '_sort']) && isset($stickyData['sortAttribute'])) { if ($stickyData['sortAttribute'] != '') { $model->sortAttribute = $stickyData['sortAttribute']; } if (isset($stickyData['sortDescending'])) { if ($stickyData['sortDescending'] == true) { $model->sortDescending = ".desc"; } } } }
public function attributeLabels() { return array_merge(parent::attributeLabels(), array('filteredBy' => Zurmo::t('GameRewardsModule', 'Filtered By'))); }
public function getAttributesMappedToRealAttributesMetadata() { return array_merge(parent::getAttributesMappedToRealAttributesMetadata(), array('anyEmail' => array(array('primaryEmail', 'emailAddress')), 'fullName' => array(array('firstName'), array('lastName'), array('concatedAttributeNames' => array('firstName', 'lastName'))))); }
public function getAttributesMappedToRealAttributesMetadata() { return array_merge(parent::getAttributesMappedToRealAttributesMetadata(), array('AAAName' => array(array('aaaMember'), array('aaaMember2')), 'differentOperatorA' => array(array('aaaMember', null, null, 'resolveValueByRules')), 'differentOperatorB' => array(array('aaaMember', null, 'endsWith')), 'concatedName' => array(array('aaaMember'), array('aaaMember2'), array('concatedAttributeNames' => array('aaaMember', 'aaaMember2'))))); }