File tree 4 files changed +9
-4
lines changed
4 files changed +9
-4
lines changed Original file line number Diff line number Diff line change 11
11
}
12
12
],
13
13
"require" : {
14
- "php-mvc-project/php-mvc" : " ^1.1.1 " ,
14
+ "php-mvc-project/php-mvc" : " ^1.2 " ,
15
15
"components/jquery" : " 3.3.1" ,
16
16
"twbs/bootstrap" : " 4.1.1"
17
17
}
Original file line number Diff line number Diff line change @@ -17,7 +17,7 @@ class AccountController extends Controller {
17
17
18
18
public function __construct () {
19
19
// set model type for actions
20
- Model::use (array ('index ' , 'login ' ), 'Login ' );
20
+ Model::set (array ('index ' , 'login ' ), 'Login ' );
21
21
22
22
// required fields
23
23
Model::required ('Login ' , 'username ' );
Original file line number Diff line number Diff line change 47
47
// AppBuilder::useCache(new PhpMvc\FileCacheProvider());
48
48
49
49
// custom handlers
50
- AppBuilder::use (function (PhpMvc \AppContext $ appContext ) {
50
+ AppBuilder::useAppContext (function (PhpMvc \AppContext $ appContext ) {
51
51
/*
52
52
// pre-init application handler
53
53
$appContext->addPreInit(function(PhpMvc\ActionContext $actionContext) {
Original file line number Diff line number Diff line change 46
46
47
47
<footer>
48
48
<div class="container">
49
- Copyright © My Application, <?= date ('Y ' )?>
49
+ Copyright © My Application, <?= date ('Y ' )?> <br />
50
+ <small>
51
+ This page is created in <?= round (microtime (true ) - PhpMvc \HttpContext::getCurrent ()->getRequest ()->server ('REQUEST_TIME_FLOAT ' ), 5 )?> seconds
52
+ <br />
53
+ PHP v<?= phpversion ()?> · PHP MVC Project v<?= PhpMvc \Info::VERSION ?>
54
+ </small>
50
55
</div>
51
56
</footer>
52
57
</body>
You can’t perform that action at this time.
0 commit comments