コード例 #1
0
 function loadFields()
 {
     $detail = new Profile_detail();
     $detail->profile_id = $this->profile->id;
     $detail->find();
     while ($detail->get()) {
         $fields[$detail->field][] = clone $detail;
     }
     return $fields;
 }
コード例 #2
0
 /**
  * Load extended profile fields
  *
  * @return array $fields the list of fields
  */
 function loadFields()
 {
     $detail = new Profile_detail();
     $detail->profile_id = $this->profile->getID();
     $detail->find();
     $fields = array();
     while ($detail->fetch()) {
         $fields[$detail->field_name][] = clone $detail;
     }
     return $fields;
 }
コード例 #3
0
 function onCheckSchema()
 {
     $schema = Schema::get();
     $schema->ensureTable('profile_detail', Profile_detail::schemaDef());
     // @hack until key definition support is merged
     Profile_detail::fixIndexes($schema);
     return true;
 }
コード例 #4
0
 function removeAll($user, $name)
 {
     $profile = $user->getProfile();
     $detail = new Profile_detail();
     $detail->profile_id = $profile->id;
     $detail->field_name = $name;
     $detail->delete();
     $detail->free();
 }
コード例 #5
0
 function onCheckSchema()
 {
     $schema = Schema::get();
     $schema->ensureTable('profile_detail', Profile_detail::schemaDef());
     return true;
 }
コード例 #6
0
 function removeAll($name)
 {
     $detail = new Profile_detail();
     $detail->profile_id = $this->scoped->getID();
     $detail->field_name = $name;
     $detail->delete();
     $detail->free();
 }