Beispiel #1
0
     break;
 case 'date':
     $attributes = array();
     $attributes['style'] = "width:180px;";
     if (isset($e[1]) && !empty($e[1])) {
         $attributes = $e[1];
     }
     echo __date('data.' . $field, $attributes);
     break;
 case 'datetime':
     $attributes = array();
     $attributes['style'] = "width:180px;";
     if (isset($e[1]) && !empty($e[1])) {
         $attributes = $e[1];
     }
     echo __datetime('data.' . $field, $attributes);
     break;
 case 'textarea':
     $attributes = array();
     if (isset($e[1]) && !empty($e[1])) {
         $attributes = $e[1];
     }
     echo __textarea('data.' . $field, $attributes);
     break;
 case 'editor':
     $attributes = array();
     $attributes['style'] = 'width:680px; height:400px;';
     if (isset($e[1]) && !empty($e[1])) {
         $attributes = $e[1];
     }
     echo __editor('data.' . $field, $attributes);
Beispiel #2
0
<?php

if ($property->getSchema()->isMultiValue()) {
    ?>
<ul class="multivalue">
	<?php 
    foreach ($property->getValue() as $value) {
        ?>
	<li><time datetime="<?php 
        __(date('Y-m-d\\TH:i:sP', $value));
        ?>
"><?php 
        __datetime($value);
        ?>
</time></li>
	<?php 
    }
    ?>
</ul>
<?php 
} else {
    ?>
<time datetime="<?php 
    __(date('Y-m-d\\TH:i:sP', $property->getValue()));
    ?>
"><?php 
    __datetime($property->getValue());
    ?>
</time>
<?php 
}
Beispiel #3
0
function __date($value)
{
    __datetime($value, 'property_date_value');
}
Beispiel #4
0
     break;
 case 'date':
     $attributes = array();
     $attributes['style'] = "width:180px;";
     if (isset($e[1]) && !empty($e[1])) {
         $attributes = $e[1];
     }
     echo __date('src.' . $field, $attributes);
     break;
 case 'datetime':
     $attributes = array();
     $attributes['style'] = "width:180px;";
     if (isset($e[1]) && !empty($e[1])) {
         $attributes = $e[1];
     }
     echo __datetime('src.' . $field, $attributes);
     break;
 case 'radio':
     $options = array();
     $params = array();
     if (isset($e[1]) && !empty($e[1])) {
         if (array_key_exists('option_table', $e[1])) {
             if (array_key_exists('option_key', $e[1]) && array_key_exists('option_value', $e[1])) {
                 $_dao = new ScrudDao($e[1]['option_table'], $CI->db);
                 $params['fields'] = array($e[1]['option_key'], $e[1]['option_value']);
                 $rs = $_dao->find($params);
                 if (!empty($rs)) {
                     foreach ($rs as $v) {
                         $options[$v[$e[1]['option_key']]] = $v[$e[1]['option_value']];
                     }
                 }