Beispiel #1
0
 /**
  * (non-PHPdoc)
  * @see Syncroton_Backend_ABackend::_getObject()
  */
 protected function _getObject($data)
 {
     $model = parent::_getObject($data);
     if ($model->pendingdata !== NULL) {
         $model->pendingdata = json_decode($model->pendingdata, true);
     }
     return $model;
 }
Beispiel #2
0
 /**
  * convert array to object
  *
  * @param  array  $data
  * @return object
  */
 protected function _getObject($data)
 {
     $policy = json_decode($data['json_policy'], true);
     foreach ($policy as $policyKey => $policyValue) {
         $data[$policyKey] = $policyValue;
     }
     unset($data['json_policy']);
     return parent::_getObject($data);
 }
Beispiel #3
0
 /**
  * (non-PHPdoc)
  * @see Syncroton_Backend_ABackend::_toCamelCase()
  */
 protected function _toCamelCase($string, $ucFirst = true)
 {
     switch ($string) {
         case 'displayname':
             return 'displayName';
             break;
         case 'parentid':
             return 'parentId';
             break;
         case 'folderid':
             return 'serverId';
             break;
         default:
             return parent::_toCamelCase($string, $ucFirst);
             break;
     }
 }