예제 #1
0
파일: object.php 프로젝트: uinerd/Code
 /**
  * Make object's properties into SQL set-values list
  */
 private function sqlValues($priKey = true)
 {
     $vals = array();
     foreach (LigminchaGlobalDistributed::$tableStruct as $field => $type) {
         if ($priKey || $field != 'id') {
             $prop = "{$field}";
             $val = LigminchaGlobalDistributed::sqlField($this->{$prop}, $type);
             $vals[] = "`{$field}`={$val}";
         }
     }
     return implode(',', $vals);
 }