static function setCustomData($obj, $values)
 {
     parent::_setCustomData($obj, $values);
 }
 static function bulkCMSSave($result, $action, $type)
 {
     return parent::bulkSave($result, $action, $type, NULL, self::fields());
 }
示例#3
0
    /**
     * Displays the edit fields for zenpage objects
     *
     * @param string $html
     * @param object $object
     * @return string
     */
    static function _cmsItemEdit($html, $object, $fields)
    {
        foreach ($fields as $field) {
            if ($field['table'] == $object->table) {
                list($item, $formatted) = fieldExtender::_editHandler($object, $field, NULL);
                if (!is_null($formatted)) {
                    $html .= "<tr>\n" . '<td><span class="topalign-padding nowrap">' . $field['desc'] . "</span></td>\n" . '<td>' . "\n";
                    if ($formatted) {
                        $html .= $item;
                    } else {
                        if (in_array(strtolower($field['type']), array('varchar', 'int', 'tinytext'))) {
                            $html .= '<input name="' . $field['name'] . '" type="text" style = "width:97%;"
value="' . $item . '" />';
                        } else {
                            $html .= '<textarea name = "' . $field['name'] . '" style = "width:97%;" "rows="6">' . $item . '</textarea>';
                        }
                    }
                    $html .= "</td>\n" . "</tr>\n";
                }
            }
        }
        return $html;
    }