|
Project Information
Links
|
はじめにteeple2は「Java屋のためのPHP5フレームワーク」をコンセプトににseasar2ファミリーのteedaやSAStrutsのエッセンスを取り込んだ、PHP5のWebアプリケーションフレームワークです。 以下のような特徴を持っています。
ハイライト
class Example_Search extends Teeple_ActionBase {
// フォームに入力された検索条件で、employeeの一覧を表示する。
public function doSearch() {
$this->searchResults = Entity_Employee::get()
->contains('name', $this->name)
->contains('name_kana', $this->name_kana)
->limit($this->limit)
->offset($this->offset)
->order('employee_no ASC')
->select();
return '/example/search.html';
}
}
class Example_Create extends Teeple_ActionBase {
// フォームに入力された内容で employee を登録する。
public function doCreate() {
$entity = Entity_Employee::get();
$entity->convert2Entity($this); // formの値をentityにコピー
$entity->insert();
return '/example/create.html';
}
}
class Example_Update extends Teeple_ActionBase {
// フォームに入力された内容で employee を更新する。
public function doUpdate() {
$entity = Entity_Employee::get()->find($this->id);
$entity->convert2Entity($this); // formの値をentityにコピー
$entity->update();
return '/example/update.html';
}
}
class Example_Read extends Teeple_ActionBase {
// 指定されたIDの employee を表示する。
public function execute() {
$entity = Entity_Employee::get()->find($this->id);
$entity->convert2Page($this); // entityの値をページにコピー
return '/example/read.html';
}
}ドキュメント最新情報
ダウンロード⇒ こちらから お問い合わせteeple2に関するお問い合わせは 「info @ honestyworks.jp」までお願いします。 |