/** Medieval type details page * @access public * @return void * @throws Pas_Exception_Param */ public function typeAction() { if ($this->getParam('id', false)) { $this->view->types = $this->_types->getTypeDetails((int) $this->getParam('id')); } else { throw new Pas_Exception_Param($this->_missingParameter, 500); } }
/** Set up the individual types */ public function typeAction() { if ($this->_getParam('id', false)) { $this->view->id = $this->_getParam('id'); $types = new MedievalTypes(); $this->view->types = $types->getTypeDetails($this->_getParam('id')); } else { throw new Pas_Exception_Param($this->_missingParameter); } }
/** Individual category page * @access public * @return void * @throws Pas_Exception_Param */ public function categoryAction() { if ($this->getParam('id', false)) { $this->view->categories = $this->_categories->getCategory($this->getParam('id')); $this->view->rulers = $this->_categories->getMedievalRulersToType($this->getParam('id')); $types = new MedievalTypes(); $this->view->types = $types->getCoinTypeCategory($this->getParam('id')); } else { throw new Pas_Exception_Param($this->_missingParameter, 500); } }
/** Medieval type details page */ public function typeAction() { if ($this->_getParam('id', false)) { $types = new MedievalTypes(); $this->view->types = $types->getTypeDetails((int) $this->_getParam('id')); $images = new Slides(); $this->view->images = $images->getExamplesCoinsMedTypes((int) $this->_getParam('id'), 4); } else { throw new Pas_Exception_Param($this->_missingParameter); } }
public function optionsAddClone($broadperiod, $coinDataFlat) { Zend_Controller_Action_HelperBroker::getStaticHelper('FlashMessenger')->addMessage('Your last record data has been cloned'); switch ($broadperiod) { case 'IRON AGE': if (isset($coinDataFlat['denomination'])) { $geographies = new Geography(); $geography_options = $geographies->getIronAgeGeographyMenu($coinDataFlat['denomination']); $this->_view->form->geographyID->addMultiOptions(array(NULL => 'Choose geographic region', 'Available regions' => $geography_options)); } break; case 'ROMAN': if (isset($coinDataFlat['ruler'])) { $reverses = new Revtypes(); $reverse_options = $reverses->getRevTypesForm($coinDataFlat['ruler']); if ($reverse_options) { $this->_view->form->revtypeID->addMultiOptions(array(NULL => 'Choose reverse type', 'Available reverses' => $reverse_options)); } else { $this->_view->form->revtypeID->addMultiOptions(array(NULL => 'No options available')); } } else { $this->_view->form->revtypeID->addMultiOptions(array(NULL => 'No options available')); } if (isset($coinDataFlat['ruler']) && $coinDataFlat['ruler'] == 242) { $moneyers = new Moneyers(); $moneyer_options = $moneyers->getRepublicMoneyers(); $this->_view->form->moneyer->addMultiOptions(array(NULL => NULL, 'Choose reverse type' => $moneyer_options)); } else { $this->_view->form->moneyer->addMultiOptions(array(NULL => 'No options available')); //$this->_view->form->moneyer->disabled=true; } break; case 'EARLY MEDIEVAL': $types = new MedievalTypes(); $type_options = $types->getMedievalTypeToRulerMenu($coinDataFlat['ruler']); $this->_view->form->typeID->addMultiOptions(array(NULL => 'Choose Early Medieval type', 'Available types' => $type_options)); break; case 'MEDIEVAL': $types = new MedievalTypes(); $type_options = $types->getMedievalTypeToRulerMenu($coinDataFlat['ruler']); $this->_view->form->typeID->addMultiOptions(array(NULL => 'Choose Medieval type', 'Available types' => $type_options)); break; case 'POST MEDIEVAL': $types = new MedievalTypes(); $type_options = $types->getMedievalTypeToRulerMenu($coinDataFlat['ruler']); $this->_view->form->typeID->addMultiOptions(array(NULL => 'Choose Post Medieval type', 'Available types' => $type_options)); break; } }
/** Set up the individual page per ruler with examples, map and types */ public function rulerAction() { if ($this->_getParam('id', false)) { $id = $this->_getParam('id'); $this->view->rulers = $this->_rulers->getRulerImage($id); $this->view->monarchs = $this->_rulers->getRulerProfileMed($id); $denominations = new Denominations(); $this->view->denominations = $denominations->getEarlyMedRulerToDenomination($id); $types = new MedievalTypes(); $this->view->types = $types->getEarlyMedievalTypeToRuler($id); $mints = new Mints(); $this->view->mints = $mints->getMedMintRuler($id); } else { throw new Pas_Exception_Param($this->_missingParameter); } }
/** The constructor * @access public * @param array $options * @return void */ public function __construct(array $options = null) { $institutions = new Institutions(); $inst_options = $institutions->getInsts(); $rallies = new Rallies(); $rally_options = $rallies->getRallies(); $counties = new OsCounties(); $county_options = $counties->getCountiesID(); $rulers = new Rulers(); $ruler_options = $rulers->getEarlyMedRulers(); $denominations = new Denominations(); $denomination_options = $denominations->getOptionsEarlyMedieval(); $mints = new Mints(); $mint_options = $mints->getEarlyMedievalMints(); $axis = new Dieaxes(); $axis_options = $axis->getAxes(); $types = new MedievalTypes(); $type_options = $types->getMedievalTypesForm(47); $cats = new CategoriesCoins(); $cat_options = $cats->getPeriodEarlyMed(); $regions = new OsRegions(); $region_options = $regions->getRegionsID(); parent::__construct($options); $this->setName('earlymedsearch'); $old_findID = new Zend_Form_Element_Text('old_findID'); $old_findID->setLabel('Find number: ')->setRequired(false)->addFilters(array('StripTags', 'StringTrim'))->addErrorMessage('Please enter a valid number!'); $description = new Zend_Form_Element_Text('description'); $description->setLabel('Object description contains: ')->setRequired(false)->addFilters(array('StripTags', 'StringTrim'))->addErrorMessage('Please enter a valid term'); $workflow = new Zend_Form_Element_Select('workflow'); $workflow->setLabel('Workflow stage: ')->setRequired(false)->setAttrib('class', 'input-xxlarge selectpicker show-menu-arrow')->addFilters(array('StringTrim', 'StripTags'))->addValidator('Int'); if (in_array($this->_role, $this->_higherlevel)) { $workflow->addMultiOptions(array(null => 'Available Workflow stages', 'Choose Worklow stage' => array('1' => 'Quarantine', '2' => 'On review', '4' => 'Awaiting validation', '3' => 'Published'))); } if (in_array($this->_role, $this->_restricted)) { $workflow->addMultiOptions(array(null => 'Available Workflow stages', 'Choose Worklow stage' => array('4' => 'Awaiting validation', '3' => 'Published'))); } //Rally details $rally = new Zend_Form_Element_Checkbox('rally'); $rally->setLabel('Rally find: ')->setRequired(false)->addValidator('Int')->addFilters(array('StringTrim', 'StripTags'))->setUncheckedValue(null); $rallyID = new Zend_Form_Element_Select('rallyID'); $rallyID->setLabel('Found at this rally: ')->setRequired(false)->setAttrib('class', 'input-xxlarge selectpicker show-menu-arrow')->addFilters(array('StringTrim', 'StripTags'))->addMultiOptions(array(null => 'Choose a rally', 'Available rallies' => $rally_options)); $county = new Zend_Form_Element_Select('countyID'); $county->setLabel('County: ')->addValidators(array('NotEmpty'))->setAttrib('class', 'input-xxlarge selectpicker show-menu-arrow')->addFilters(array('StringTrim', 'StripTags'))->addMultiOptions(array(null => 'Choose county', 'Available counties' => $county_options)); $district = new Zend_Form_Element_Select('districtID'); $district->setLabel('District: ')->addMultiOptions(array(null => 'Choose district after county'))->setAttrib('class', 'input-xxlarge selectpicker show-menu-arrow')->setRegisterInArrayValidator(false)->addFilters(array('StringTrim', 'StripTags'))->setDisableTranslator(true); $parish = new Zend_Form_Element_Select('parishID'); $parish->setLabel('Parish: ')->setRegisterInArrayValidator(false)->setAttrib('class', 'input-xxlarge selectpicker show-menu-arrow')->addFilters(array('StringTrim', 'StripTags'))->addMultiOptions(array(null => 'Choose parish after county'))->setDisableTranslator(true); $regionID = new Zend_Form_Element_Select('regionID'); $regionID->setLabel('European region: ')->setRegisterInArrayValidator(false)->setAttrib('class', 'input-xxlarge selectpicker show-menu-arrow')->addValidator('Int')->addMultiOptions(array(null => 'Choose a region for a wide result', 'Choose region' => $region_options)); $gridref = new Zend_Form_Element_Text('gridref'); $gridref->setLabel('Grid reference: ')->addValidators(array('NotEmpty', 'ValidGridRef'))->addFilters(array('StringTrim', 'StripTags')); $fourFigure = new Zend_Form_Element_Text('fourFigure'); $fourFigure->setLabel('Four figure grid reference: ')->addValidators(array('NotEmpty'))->addFilters(array('StringTrim', 'StripTags')); $denomination = new Zend_Form_Element_Select('denomination'); $denomination->setLabel('Denomination: ')->setRequired(false)->addFilters(array('StripTags', 'StringTrim'))->setAttrib('class', 'input-xxlarge selectpicker show-menu-arrow')->addValidator('Int')->addMultiOptions(array(null => 'Choose denomination type', 'Available denominations' => $denomination_options)); $cat = new Zend_Form_Element_Select('category'); $cat->setLabel('Category: ')->setRequired(false)->addValidator('Int')->addFilters(array('StripTags', 'StringTrim'))->setAttrib('class', 'input-xxlarge selectpicker show-menu-arrow')->addMultiOptions(array(null => 'Choose an Early Medieval category', 'Available categories' => $cat_options)); $type = new Zend_Form_Element_Select('type'); $type->setLabel('Coin type: ')->setRequired(false)->addValidator('Int')->setAttrib('class', 'input-xxlarge selectpicker show-menu-arrow')->addFilters(array('StripTags', 'StringTrim'))->addMultiOptions(array(null => 'Choose type after choosing ruler', 'Available types' => $type_options))->addValidator('InArray', false, array(array_keys($type_options))); //Primary ruler $ruler = new Zend_Form_Element_Select('ruler'); $ruler->setLabel('Ruler / issuer: ')->setRequired(false)->addValidator('Int')->addFilters(array('StripTags', 'StringTrim'))->setAttrib('class', 'input-xxlarge selectpicker show-menu-arrow')->addMultiOptions(array(null => 'Choose primary ruler', 'Available options' => $ruler_options))->addValidator('InArray', false, array(array_keys($ruler_options))); //Mint $mint = new Zend_Form_Element_Select('mint'); $mint->setLabel('Issuing mint: ')->setRequired(false)->addValidator('Int')->addFilters(array('StripTags', 'StringTrim'))->setAttrib('class', 'input-xxlarge selectpicker show-menu-arrow')->addMultiOptions(array(null => 'Choose issuing mint', 'Available mints' => $mint_options)); //Obverse inscription $obverseinsc = new Zend_Form_Element_Text('obverseLegend'); $obverseinsc->setLabel('Obverse inscription contains: ')->setRequired(false)->addFilters(array('StripTags', 'StringTrim'))->addErrorMessage('Please enter a valid term'); //Obverse description $obversedesc = new Zend_Form_Element_Text('obverseDescription'); $obversedesc->setLabel('Obverse description contains: ')->setRequired(false)->addFilters(array('StripTags', 'StringTrim'))->addErrorMessage('Please enter a valid term'); //reverse inscription $reverseinsc = new Zend_Form_Element_Text('reverseLegend'); $reverseinsc->setLabel('Reverse inscription contains: ')->setRequired(false)->addFilters(array('StripTags', 'StringTrim'))->addErrorMessage('Please enter a valid term'); //reverse description $reversedesc = new Zend_Form_Element_Text('reverseDescription'); $reversedesc->setLabel('Reverse description contains: ')->setRequired(false)->addFilters(array('StripTags', 'StringTrim'))->addErrorMessage('Please enter a valid term'); //Die axis $axis = new Zend_Form_Element_Select('axis'); $axis->setLabel('Die axis measurement: ')->setRegisterInArrayValidator(false)->setRequired(false)->setAttrib('class', 'input-xxlarge selectpicker show-menu-arrow')->addFilters(array('StripTags', 'StringTrim'))->addValidator('Int')->addMultiOptions(array(null => 'Choose a die axis measurement', 'Available options' => $axis_options)); $objecttype = new Zend_Form_Element_Hidden('objecttype'); $objecttype->setValue('coin')->addFilter('StringToUpper'); $broadperiod = new Zend_Form_Element_Hidden('broadperiod'); $broadperiod->setValue('Early Medieval')->addFilter('StringToUpper'); //Submit button $submit = new Zend_Form_Element_Submit('submit'); $institution = new Zend_Form_Element_Select('institution'); $institution->setLabel('Recording institution: ')->setRequired(false)->addFilters(array('StringTrim', 'StripTags'))->setAttrib('class', 'input-xxlarge selectpicker show-menu-arrow')->addValidator('Alpha', true)->addMultiOptions(array(null => 'Choose an institution', 'Available institutions' => $inst_options)); $hash = new Zend_Form_Element_Hash('csrf'); $hash->setValue($this->_salt)->setTimeout(4800); $this->addElements(array($old_findID, $type, $description, $workflow, $rally, $rallyID, $county, $regionID, $district, $parish, $fourFigure, $gridref, $denomination, $ruler, $mint, $axis, $obverseinsc, $obversedesc, $reverseinsc, $reversedesc, $objecttype, $broadperiod, $cat, $submit, $institution, $hash)); $this->addDisplayGroup(array('category', 'ruler', 'type', 'denomination', 'mint', 'moneyer', 'axis', 'obverseLegend', 'obverseDescription', 'reverseLegend', 'reverseDescription'), 'numismatics'); $this->numismatics->setLegend('Numismatic details: '); $this->addDisplayGroup(array('old_findID', 'description', 'rally', 'rallyID', 'workflow'), 'details'); $this->details->setLegend('Object details: '); $this->addDisplayGroup(array('countyID', 'regionID', 'districtID', 'parishID', 'gridref', 'fourFigure', 'institution'), 'spatial'); $this->spatial->setLegend('Spatial details: '); $this->addDisplayGroup(array('submit'), 'buttons'); parent::init(); }
/** Clone the options * @access public * @param string $broadperiod * @param array $coinDataFlat * @throw Exeption */ public function optionsAddClone($broadperiod, array $coinDataFlat) { switch ($broadperiod) { case 'IRON AGE': if (isset($coinDataFlat['denomination'])) { $geographies = new Geography(); $geography_options = $geographies->getIronAgeGeographyMenu($coinDataFlat['denomination']); $form->geographyID->addMultiOptions(array(null => 'Choose geographic region', 'Available regions' => $geography_options)); $form->geographyID->addValidator('InArray', false, array(array_keys($geography_options))); } break; case 'ROMAN': if (isset($coinDataFlat['ruler'])) { $reverses = new RevTypes(); $reverse_options = $reverses->getRevTypesForm($coinDataFlat['ruler']); if ($reverse_options) { $form->revtypeID->addMultiOptions(array(null => 'Choose reverse type', 'Available reverses' => $reverse_options)); } else { $form->revtypeID->addMultiOptions(array(null => 'No options available')); } } else { $form->revtypeID->addMultiOptions(array(null => 'No options available')); } if (isset($coinDataFlat['ruler']) && $coinDataFlat['ruler'] == 242) { $moneyers = new Moneyers(); $moneyer_options = $moneyers->getRepublicMoneyers(); $form->moneyer->addMultiOptions(array(null => 'Choose moneyer', 'Available moneyers' => $moneyer_options)); } else { $form->moneyer->addMultiOptions(array(null => 'No options available')); } break; case 'EARLY MEDIEVAL': $types = new MedievalTypes(); $type_options = $types->getMedievalTypeToRulerMenu($coinDataFlat['ruler']); $form->typeID->addMultiOptions(array(null => 'Choose Early Medieval type', 'Available types' => $type_options)); break; case 'MEDIEVAL': $types = new MedievalTypes(); $type_options = $types->getMedievalTypeToRulerMenu($coinDataFlat['ruler']); $form->typeID->addMultiOptions(array(null => 'Choose Medieval type', 'Available types' => $type_options)); break; case 'POST MEDIEVAL': $types = new MedievalTypes(); $type_options = $types->getMedievalTypeToRulerMenu($coinDataFlat['ruler']); $form->typeID->addMultiOptions(array(null => 'Choose Post Medieval type', 'Available types' => $type_options)); break; default: throw new Exception('No period supplied', 500); } }
public function earlymedtyperulerAction() { if ($this->_getParam('term', false)) { $types = new MedievalTypes(); $ruler_options = $types->getEarlyMedTypeRuler($this->_getParam('term')); if ($ruler_options) { echo Zend_Json::encode($ruler_options); } else { $data = array(array('id' => NULL, 'term' => 'No options available')); echo Zend_Json::encode($data); } } else { $data = array(array('id' => NULL, 'term' => 'No ruler specified')); echo Zend_Json::encode($data); } }
/** add and clone last record * @access public * @param string $broadperiod * @param array $coinDataFlat * @return void */ public function optionsAddClone($broadperiod, array $coinDataFlat) { $coinDataFlat = $coinDataFlat[0]; switch ($broadperiod) { case 'IRON AGE': if (array_key_exists('denomination', $coinDataFlat)) { $geographies = new Geography(); $geography_options = $geographies->getIronAgeGeographyMenu($coinDataFlat['denomination']); $this->_view->form->geographyID->addMultiOptions(array(null => 'Choose geographic region', 'Available regions' => $geography_options)); $this->_view->form->geographyID->addValidator('InArray', false, array(array_keys($geography_options))); } break; case 'ROMAN': if (array_key_exists('ruler_id', $coinDataFlat)) { if (!is_null($coinDataFlat['ruler_id'])) { $rulers = new Rulers(); $identifier = $rulers->fetchRow($rulers->select()->where('id = ?', $coinDataFlat['ruler_id'])); if ($identifier) { $nomisma = $identifier->nomismaID; $rrcTypes = new Nomisma(); $this->_view->form->ricID->addMultiOptions(array(null => 'Choose RIC type', 'Available RIC types' => $rrcTypes->getRICDropdownsFlat($nomisma))); } } $reverses = new RevTypes(); $reverse_options = $reverses->getRevTypesForm($coinDataFlat['ruler_id']); if ($reverse_options) { $this->_view->form->revtypeID->addMultiOptions(array(null => 'Choose reverse type', 'Available reverses' => $reverse_options)); $this->_view->form->revtypeID->setRegisterInArrayValidator(false); } else { $this->_view->form->revtypeID->addMultiOptions(array(null => 'No options available')); $this->_view->form->revtypeID->setRegisterInArrayValidator(false); } } else { $this->_view->form->revtypeID->addMultiOptions(array(null => 'No options available')); $this->_view->form->revtypeID->setRegisterInArrayValidator(false); } if (array_key_exists('ruler_id', $coinDataFlat) && $coinDataFlat['ruler_id'] == '242') { $moneyers = new Moneyers(); $moneyer_options = $moneyers->getRepublicMoneyers(); $this->_view->form->moneyer->addMultiOptions(array(null => 'Choose moneyer', 'Available moneyers' => $moneyer_options)); if (array_key_exists('moneyer', $coinDataFlat)) { if (!is_null($coinDataFlat['moneyer'])) { $identifier = $moneyers->fetchRow($moneyers->select()->where('id = ?', $coinDataFlat['moneyer'])); if ($identifier) { $nomisma = $identifier->nomismaID; $rrcTypes = new Nomisma(); $this->_view->form->rrcID->addMultiOptions(array(null => 'Choose RRC type', 'Available RRC types' => $rrcTypes->getRRCDropdownsFlat($nomisma))); } } } } else { $this->_view->form->moneyer->addMultiOptions(array(null => 'No options available')); } break; case 'EARLY MEDIEVAL': if (array_key_exists('ruler_id', $coinDataFlat)) { $types = new MedievalTypes(); $type_options = $types->getMedievalTypeToRulerMenu($coinDataFlat['ruler_id']); $this->_view->form->typeID->addMultiOptions(array(null => 'Choose Early Medieval type', 'Available types' => $type_options)); } break; case 'MEDIEVAL': if (array_key_exists('ruler_id', $coinDataFlat)) { $types = new MedievalTypes(); $type_options = $types->getMedievalTypeToRulerMenu($coinDataFlat['ruler_id']); $this->_view->form->typeID->addMultiOptions(array(null => 'Choose Medieval type', 'Available types' => $type_options)); } break; case 'POST MEDIEVAL': if (array_key_exists('ruler_id', $coinDataFlat)) { $types = new MedievalTypes(); $type_options = $types->getMedievalTypeToRulerMenu((int) $coinDataFlat['ruler_id']); $this->_view->form->typeID->addMultiOptions(array(null => 'Choose Post Medieval type', 'Available types' => $type_options)); } break; default: return false; } }
public function optionsAddClone($broadperiod, $coinDataFlat) { switch ($broadperiod) { case 'IRON AGE': if (isset($coinDataFlat['denomination'])) { $geographies = new Geography(); $geography_options = $geographies->getIronAgeGeographyMenu($coinDataFlat['denomination']); $form->geographyID->addMultiOptions(array(NULL => 'Choose geographic region', 'Available regions' => $geography_options)); } break; case 'ROMAN': if (isset($coinDataFlat['ruler'])) { $reverses = new Revtypes(); $reverse_options = $reverses->getRevTypesForm($coinDataFlat['ruler']); if ($reverse_options) { $form->revtypeID->addMultiOptions(array(NULL => 'Choose reverse type', 'Available reverses' => $reverse_options)); } else { $form->revtypeID->addMultiOptions(array(NULL => 'No options available')); } } else { $form->revtypeID->addMultiOptions(array(NULL => 'No options available')); } if (isset($coinDataFlat['ruler']) && $coinDataFlat['ruler'] == 242) { $moneyers = new Moneyers(); $moneyer_options = $moneyers->getRepublicMoneyers(); $form->moneyer->addMultiOptions(array(NULL => NULL, 'Choose reverse type' => $moneyer_options)); } else { $form->moneyer->addMultiOptions(array(NULL => 'No options available')); //$form->moneyer->disabled=true; } break; case 'EARLY MEDIEVAL': $types = new MedievalTypes(); $type_options = $types->getMedievalTypeToRulerMenu($coinDataFlat['ruler']); $form->typeID->addMultiOptions(array(NULL => 'Choose Early Medieval type', 'Available types' => $type_options)); break; case 'MEDIEVAL': $types = new MedievalTypes(); $type_options = $types->getMedievalTypeToRulerMenu($coinDataFlat['ruler']); $form->typeID->addMultiOptions(array(NULL => 'Choose Medieval type', 'Available types' => $type_options)); break; case 'POST MEDIEVAL': $types = new MedievalTypes(); $type_options = $types->getMedievalTypeToRulerMenu($coinDataFlat['ruler']); $form->typeID->addMultiOptions(array(NULL => 'Choose Post Medieval type', 'Available types' => $type_options)); break; } }
/** The configuration * @access public * @return void */ public function configurationAction() { $content = new Content(); $this->view->conservation = $content->getConservationNotes(); $this->view->treasure = $content->getTreasureContent(); $denoms = new Denominations(); $this->view->romanDenoms = $denoms->getDenominationsSitemap('21'); $this->view->ironageDenoms = $denoms->getDenominationsSitemap('16'); $this->view->earlymedDenoms = $denoms->getDenominationsSitemap('47'); $this->view->medievalDenoms = $denoms->getDenominationsSitemap('29'); $this->view->byzantineDenoms = $denoms->getDenominationsSitemap('67'); $this->view->greekDenoms = $denoms->getDenominationsSitemap('66'); $this->view->postMedDenoms = $denoms->getDenominationsSitemap('36'); $emperors = new Emperors(); $this->view->emperors = $emperors->getEmperorsSiteMap(); $rulers = new Rulers(); $this->view->medrulers = $rulers->getMedievalRulersList(); $this->view->earlymedrulers = $rulers->getEarlyMedievalRulersList(); $this->view->postmedrulers = $rulers->getPostMedievalRulersList(); $this->view->ironagerulers = $rulers->getIARulersList(); $this->view->byzantinerulers = $rulers->getByzRulersList(); $this->view->greekrulers = $rulers->getGreekRulersList(); $mints = new Mints(); $this->view->romanMints = $mints->getMintsSiteMap(21); $this->view->ironageMints = $mints->getMintsSiteMap(16); $this->view->byzantineMints = $mints->getMintsSiteMap(67); $this->view->earlymedMints = $mints->getMintsSiteMap(47); $this->view->medMints = $mints->getMintsSiteMap(29); $this->view->postmedMints = $mints->getMintsSiteMap(36); $this->view->greekMints = $mints->getMintsSiteMap(66); $reeces = new Reeces(); $this->view->reeces = $reeces->getSiteMap(); $types = new MedievalTypes(); $this->view->medtypes = $types->getTypesSiteMap(29); $this->view->postmedtypes = $types->getTypesSiteMap(36); $this->view->earlymedtypes = $types->getTypesSiteMap(47); $cats = new CategoriesCoins(); $this->view->medcats = $cats->getCatsSiteMap(29); $this->view->earlymedcats = $cats->getCatsSiteMap(47); $this->view->postmedcats = $cats->getCatsSiteMap(36); $tribes = new Tribes(); $this->view->tribes = $tribes->getSitemap(); $news = new News(); $this->view->news = $news->getSitemapNews(); }
/** Delete a medieval type * @access public * @return void */ public function deletetypeAction() { if ($this->_request->isPost()) { $id = (int) $this->_request->getPost('id'); $del = $this->_request->getPost('del'); if ($del == 'Yes' && $id > 0) { $medtypes = new MedievalTypes(); $where = 'id = ' . $id; $medtypes->delete($where); } $this->redirect($this->_redirectUrl . 'types'); } else { $id = (int) $this->_request->getParam('id'); if ($id > 0) { $medtypes = new MedievalTypes(); $this->view->medtype = $medtypes->fetchRow('id =' . $id); } } }