Changeset 465 for trunk/Common/Forms.php


Ignore:
Timestamp:
Nov 28, 2012, 10:00:45 PM (12 years ago)
Author:
chronos
Message:
  • Přidáno: Podpora pro položky pouze pro čtení a pro příponu položek.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Common/Forms.php

    r448 r465  
    4141      $Edit = $System->Type->ExecuteTypeEvent($UseType, 'OnView',
    4242        array('Value' => $this->Values[$Index], 'Name' => $Index, 'Type' => $Item['Type']));
     43      if(array_key_exists('Suffix', $Item)) $Edit .= ' '.$Item['Suffix'];
    4344      array_push($Table['Rows'], array($Item['Caption'].':', $Edit));
    4445    }
     
    6768    if($Context != '') $Context = $Context.'-';
    6869    foreach($this->Definition['Items'] as $Index => $Item)
     70    {
     71      if(!array_key_exists('ReadOnly', $Item)) $Item['ReadOnly'] = false;
     72    if($Item['ReadOnly'] == false)
    6973    if(!array_key_exists($Item['Type'], $FormTypes) or
    7074    (array_key_exists($Item['Type'], $FormTypes) and ($FormTypes[$Item['Type']]['Type'] != 'ManyToOne')))
     
    8892        } else $UseType = $Item['Type'];
    8993        $Edit = $System->Type->ExecuteTypeEvent($UseType, 'OnEdit', $Parameters);
     94        if(array_key_exists('Suffix', $Item)) $Edit .= $Item['Suffix'];
    9095
    9196      array_push($Table['Rows'], array($Item['Caption'].':', $Edit));
     97    }
    9298    }
    9399    $Output = '<fieldset><legend>'.$this->Definition['Title'].'</legend>'.Table($Table).
Note: See TracChangeset for help on using the changeset viewer.