Beispiel #1
0
 function post_addItem()
 {
     //Create label translation
     PluginFieldsLabelTranslation::createForItem($this);
 }
Beispiel #2
0
 function post_addItem()
 {
     //create profiles associated to this container
     PluginFieldsProfile::createForContainer($this);
     //Create label translation
     PluginFieldsLabelTranslation::createForItem($this);
     //create class file
     if (!self::generateTemplate($this->fields)) {
         return false;
     }
     foreach (json_decode($this->fields['itemtypes']) as $itemtype) {
         //install table for receive field
         $classname = "PluginFields" . ucfirst($itemtype . preg_replace('/s$/', '', $this->fields['name']));
         $classname::install();
     }
 }