Esempio n. 1
0
 public function __construct()
 {
     parent::__construct();
     if ($this->viewPath) {
         $this->view = new View($this->viewPath);
         if (preg_match('/Concrete\\\\Package\\\\(.*)\\\\Controller/i', get_class($this), $matches)) {
             $pkgHandle = uncamelcase($matches[1]);
             $this->view->setPackageHandle($pkgHandle);
         }
         $this->view->setController($this);
     }
 }
Esempio n. 2
0
 public function post($field = false, $defaultValue = null)
 {
     // the only post that matters is the one for this attribute's name space
     $req = $this->requestArray == false ? $_POST : $this->requestArray;
     if (is_array($req['_bf'])) {
         $identifier = $this->identifier;
         $b = $this->getBlockObject();
         if (is_object($b)) {
             $xc = $b->getBlockCollectionObject();
             if (is_object($xc)) {
                 $identifier .= '_' . $xc->getCollectionID();
             }
         }
         $p = $req['_bf'][$identifier];
         if ($field) {
             return $p[$field];
         }
         return $p;
     }
     return parent::post($field, $defaultValue);
 }
Esempio n. 3
0
 public function request($field = false)
 {
     $req = $this->requestArray == false ? $_REQUEST : $this->requestArray;
     if (is_object($this->attributeKey) && is_array($req['akID'])) {
         $p = $req['akID'][$this->attributeKey->getAttributeKeyID()];
         if ($field) {
             return $p[$field];
         }
         return $p;
     }
     return parent::request($field);
 }
Esempio n. 4
0
 public function __construct(EntityManager $entityManager, Token $token)
 {
     parent::__construct();
     $this->entityManager = $entityManager;
     $this->token = $token;
 }
Esempio n. 5
0
 public function __construct()
 {
     parent::__construct();
     $this->filesystem = new Filesystem();
 }
Esempio n. 6
0
 public function __construct(EntityManager $entityManager)
 {
     parent::__construct();
     $this->entityManager = $entityManager;
 }
Esempio n. 7
0
 public function request($field = false)
 {
     $request = array_merge($this->request->request->all(), $this->request->query->all());
     $req = $this->requestArray == false ? $request : $this->requestArray;
     if (is_object($this->attributeKey) && is_array($req['akID'])) {
         $p = $req['akID'][$this->attributeKey->getAttributeKeyID()];
         if ($field) {
             return $p[$field];
         }
         return $p;
     }
     return parent::request($field);
 }