N°2313 - Markup extensibility: Add meta information and hooks

Admin. console:
- Class and id on object form
- Class current and target state on object transition form
- Object form mode (view/edit/create/stimulus)
- Object attributes: Attribute code, attribute definition class and raw value
- Navigation menu: Their IDs on group and items
- Actions menu: Their IDs on items

Portal:
- Object attributes: Attribute code, attribute definition class and raw value
This commit is contained in:
Molkobain
2019-12-04 15:21:27 +01:00
parent d36340a3cd
commit 4db114f64d
22 changed files with 631 additions and 358 deletions

View File

@@ -21,7 +21,6 @@
namespace Combodo\iTop\Renderer\Bootstrap\FieldRenderer;
use ApplicationContext;
use Combodo\iTop\Renderer\FieldRenderer;
use Combodo\iTop\Renderer\RenderingOutput;
use ContextTag;
use CoreException;
@@ -38,22 +37,15 @@ use MetaModel;
*
* @property \Combodo\iTop\Form\Field\SelectObjectField $oField
*/
class BsSelectObjectFieldRenderer extends FieldRenderer
class BsSelectObjectFieldRenderer extends BsFieldRenderer
{
/**
* Returns a RenderingOutput for the FieldRenderer's Field
*
* @return \Combodo\iTop\Renderer\RenderingOutput
*
* @throws \Exception
* @throws \CoreException
* @throws \ArchivedObjectException
* @inheritDoc
*/
public function Render()
{
$oOutput = new RenderingOutput();
$oOutput->AddCssClass('form_field_' . $this->oField->GetDisplayMode());
$oOutput = parent::Render();
$sFieldValueClass = $this->oField->GetSearch()->GetClass();
$sFieldMandatoryClass = ($this->oField->GetMandatory()) ? 'form_mandatory' : '';