some fix
This commit is contained in:
parent
043a699c6d
commit
01ea22d089
@ -16,9 +16,17 @@ use Itguild\Tables\ViewJsonTable;
|
|||||||
use kernel\Controller;
|
use kernel\Controller;
|
||||||
use kernel\IGTabel\ListJsonTableEloquentCollection;
|
use kernel\IGTabel\ListJsonTableEloquentCollection;
|
||||||
use kernel\IGTabel\ViewJsonTableEloquentModel;
|
use kernel\IGTabel\ViewJsonTableEloquentModel;
|
||||||
|
use Twig\Error\LoaderError;
|
||||||
|
use Twig\Error\RuntimeError;
|
||||||
|
use Twig\Error\SyntaxError;
|
||||||
use Twig\TwigFunction;
|
use Twig\TwigFunction;
|
||||||
|
|
||||||
class UserController extends Controller{
|
class UserController extends Controller{
|
||||||
|
/**
|
||||||
|
* @throws SyntaxError
|
||||||
|
* @throws RuntimeError
|
||||||
|
* @throws LoaderError
|
||||||
|
*/
|
||||||
public function actionCreate(): void
|
public function actionCreate(): void
|
||||||
{
|
{
|
||||||
echo $this->twig->render('user_create.html.twig');
|
echo $this->twig->render('user_create.html.twig');
|
||||||
@ -87,6 +95,11 @@ class UserController extends Controller{
|
|||||||
echo $this->twig->render('user_table.html.twig');
|
echo $this->twig->render('user_table.html.twig');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @throws RuntimeError
|
||||||
|
* @throws SyntaxError
|
||||||
|
* @throws LoaderError
|
||||||
|
*/
|
||||||
public function actionUpdate(): void
|
public function actionUpdate(): void
|
||||||
{
|
{
|
||||||
// $loader = new \Twig\Loader\FilesystemLoader(__DIR__.'/../views');
|
// $loader = new \Twig\Loader\FilesystemLoader(__DIR__.'/../views');
|
||||||
|
@ -3,6 +3,9 @@ namespace app\models;
|
|||||||
|
|
||||||
use \Illuminate\Database\Eloquent\Model;
|
use \Illuminate\Database\Eloquent\Model;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @method static where(string $string, $user_id)
|
||||||
|
*/
|
||||||
class Question extends Model {
|
class Question extends Model {
|
||||||
protected $table = 'question';
|
protected $table = 'question';
|
||||||
protected $fillable = ['question','user_id'];
|
protected $fillable = ['question','user_id'];
|
||||||
|
@ -6,6 +6,8 @@ use Illuminate\Database\Eloquent\Model;
|
|||||||
* @property string $username
|
* @property string $username
|
||||||
* @property string $email
|
* @property string $email
|
||||||
* @property string $password_hash
|
* @property string $password_hash
|
||||||
|
* @method static where(int[] $array)
|
||||||
|
* @method static find($id)
|
||||||
*/
|
*/
|
||||||
class User extends Model {
|
class User extends Model {
|
||||||
protected $table = 'user';
|
protected $table = 'user';
|
||||||
|
Loading…
Reference in New Issue
Block a user