| Conditions | 1 |
| Paths | 1 |
| Total Lines | 10 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 22 | protected static function createFieldObject($postValues, $title, $fieldType) |
||
| 23 | { |
||
| 24 | $fieldObject = new \stdClass(); |
||
| 25 | $fieldObject->title = $title; |
||
| 26 | $fieldObject->slug = StringUtil::slugify($title); |
||
| 27 | $fieldObject->type = $postValues['fieldTypes'][$fieldType]; |
||
| 28 | $fieldObject->required = ($postValues['fieldRequired'][$fieldType] === 'true'); |
||
| 29 | $fieldObject->multiple = ($postValues['fieldMultiple'][$fieldType] === 'true'); |
||
| 30 | |||
| 31 | return $fieldObject; |
||
| 32 | } |
||
| 33 | } |