示例#1
0
文件: Product.php 项目: 06romix/store
 /**
  * @param int $id
  * @return int|int
  */
 public static function getOne($id)
 {
     return DbFunctions::getEntity('product', $id);
 }
示例#2
0
文件: User.php 项目: 06romix/store
 public static function getUserLogin($id)
 {
     return DbFunctions::getEntity('user', $id)['user_name'];
 }
示例#3
0
 public function viewAction()
 {
     $id = $this->params()->fromRoute('id', 0);
     return new ViewModel(array('user' => DbFunctions::getEntity('user', $id)));
 }