HomeHelpTrac

Changeset 15793 for trunk/templates


Ignore:
Timestamp:
12/22/11 00:15:32 (5 months ago)
Author:
Alexander Trofimov
Message:

Form objects

Location:
trunk/templates/base
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/templates/base/css/forms.css

    r15788 r15793  
    9898/* form inputs */ 
    9999 
    100 .bx-form-input-wrapper-range, 
    101100.bx-form-input-slider, 
    102101.bx-form-input-doublerange, 
     
    105104.bx-form-input-radio_set, 
    106105.bx-form-input-checkbox_set, 
    107 .bx-form-input-email, 
    108106.bx-form-input-number, 
    109107.bx-form-input-datepicker, 
     
    149147.bx-form-input-slider:focus, 
    150148.bx-form-input-doublerange:focus, 
    151 .bx-form-input-email:focus, 
    152149.bx-form-input-number:focus, 
    153150.bx-form-input-datepicker:focus, 
     
    196193 
    197194.bx-form-input-number { 
    198     width:60px; 
     195    width:80px; 
    199196} 
    200197 
  • trunk/templates/base/scripts/BxBaseFormView.php

    r15718 r15793  
    181181            $aInput['type'] = false; 
    182182 
     183        if (!empty($aInput['name'])) { 
     184            $sCustomMethod = 'genCustomRow' . ucfirst($aInput['name']); 
     185            if (method_exists($this, $sCustomMethod)) 
     186                return $this->$sCustomMethod($aInput); 
     187        } 
     188 
    183189        switch ($aInput['type']) { 
    184190 
     
    387393    function genInput(&$aInput) {         
    388394 
     395        if (!empty($aInput['name'])) { 
     396            $sCustomMethod = 'genCustomInput' . ucfirst($aInput['name']); 
     397            if (method_exists($this, $sCustomMethod)) 
     398                return $this->$sCustomMethod($aInput); 
     399        } 
     400 
    389401        switch ($aInput['type']) { 
    390402 
     
    394406            case 'datetime': 
    395407            case 'number': 
    396             case 'email': 
    397             case 'url': 
    398408            case 'checkbox':             
    399409            case 'radio': 
     
    402412            case 'password': 
    403413            case 'slider': 
    404             case 'range': 
    405414            case 'doublerange': 
    406415            case 'hidden': 
     
    526535        // add default className to attributes 
    527536        $aAttrs['type'] = $aInput['type']; 
     537        if ('datetime' == $aAttrs['type'])  
     538            $aAttrs['type'] = 'text'; 
     539 
    528540        if (isset($aInput['name'])) $aAttrs['name'] = $aInput['name']; 
    529541        if (isset($aInput['value'])) $aAttrs['value'] = $aInput['value']; 
     542 
     543         
    530544 
    531545        // for inputs with labels generate id 
Note: See TracChangeset for help on using the changeset viewer.