Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yii2
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
PSDI Army
yii2
Commits
311f876b
Commit
311f876b
authored
Jan 30, 2013
by
Qiang Xue
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
MVC WIP
parent
bd320533
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
4 additions
and
4 deletions
+4
-4
Controller.php
framework/base/Controller.php
+2
-2
ErrorHandler.php
framework/base/ErrorHandler.php
+1
-1
View.php
framework/base/View.php
+0
-0
Widget.php
framework/base/Widget.php
+1
-1
No files found.
framework/base/Controller.php
View file @
311f876b
...
@@ -265,9 +265,9 @@ class Controller extends Component
...
@@ -265,9 +265,9 @@ class Controller extends Component
return
$this
->
createView
()
->
render
(
$view
,
$params
);
return
$this
->
createView
()
->
render
(
$view
,
$params
);
}
}
public
function
render
Text
(
$tex
t
)
public
function
render
Content
(
$conten
t
)
{
{
return
$this
->
createView
()
->
render
Text
(
$tex
t
);
return
$this
->
createView
()
->
render
Content
(
$conten
t
);
}
}
public
function
renderPartial
(
$view
,
$params
=
array
())
public
function
renderPartial
(
$view
,
$params
=
array
())
...
...
framework/base/ErrorHandler.php
View file @
311f876b
...
@@ -321,7 +321,7 @@ class ErrorHandler extends Component
...
@@ -321,7 +321,7 @@ class ErrorHandler extends Component
public
function
renderAsHtml
(
$exception
)
public
function
renderAsHtml
(
$exception
)
{
{
$view
=
new
View
;
$view
=
new
View
;
$view
->
_
owner
=
$this
;
$view
->
owner
=
$this
;
$name
=
!
YII_DEBUG
||
$exception
instanceof
HttpException
?
$this
->
errorView
:
$this
->
exceptionView
;
$name
=
!
YII_DEBUG
||
$exception
instanceof
HttpException
?
$this
->
errorView
:
$this
->
exceptionView
;
echo
$view
->
render
(
$name
,
array
(
echo
$view
->
render
(
$name
,
array
(
'exception'
=>
$exception
,
'exception'
=>
$exception
,
...
...
framework/base/View.php
View file @
311f876b
This diff is collapsed.
Click to expand it.
framework/base/Widget.php
View file @
311f876b
...
@@ -49,7 +49,7 @@ class Widget extends Component
...
@@ -49,7 +49,7 @@ class Widget extends Component
public
function
getId
(
$autoGenerate
=
true
)
public
function
getId
(
$autoGenerate
=
true
)
{
{
if
(
$autoGenerate
&&
$this
->
_id
===
null
)
{
if
(
$autoGenerate
&&
$this
->
_id
===
null
)
{
$this
->
_id
=
'
y
w'
.
self
::
$_counter
++
;
$this
->
_id
=
'w'
.
self
::
$_counter
++
;
}
}
return
$this
->
_id
;
return
$this
->
_id
;
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment