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
5567caf4
Commit
5567caf4
authored
Mar 26, 2014
by
Qiang Xue
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
git://github.com/yiisoft/yii2
parents
bc378d1c
d1663a5f
Hide whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
32 additions
and
31 deletions
+32
-31
PhpDocController.php
build/controllers/PhpDocController.php
+2
-2
ApiController.php
extensions/apidoc/commands/ApiController.php
+2
-2
GuideController.php
extensions/apidoc/commands/GuideController.php
+2
-2
BaseController.php
extensions/apidoc/components/BaseController.php
+2
-2
FixtureController.php
extensions/faker/FixtureController.php
+3
-4
View.php
framework/base/View.php
+0
-1
MemCache.php
framework/caching/MemCache.php
+1
-0
Controller.php
framework/console/Controller.php
+2
-2
FixtureController.php
framework/console/controllers/FixtureController.php
+4
-5
MigrateController.php
framework/console/controllers/MigrateController.php
+4
-5
ArrayDataProvider.php
framework/data/ArrayDataProvider.php
+1
-0
ActiveQuery.php
framework/db/ActiveQuery.php
+1
-0
BaseFileHelper.php
framework/helpers/BaseFileHelper.php
+2
-2
BaseHtml.php
framework/helpers/BaseHtml.php
+1
-1
MessageFormatter.php
framework/i18n/MessageFormatter.php
+3
-1
Request.php
framework/web/Request.php
+2
-2
No files found.
build/controllers/PhpDocController.php
View file @
5567caf4
...
@@ -115,9 +115,9 @@ class PhpDocController extends Controller
...
@@ -115,9 +115,9 @@ class PhpDocController extends Controller
/**
/**
* @inheritdoc
* @inheritdoc
*/
*/
public
function
options
(
$
i
d
)
public
function
options
(
$
actionI
d
)
{
{
return
array_merge
(
parent
::
options
(
$
i
d
),
[
'updateFiles'
]);
return
array_merge
(
parent
::
options
(
$
actionI
d
),
[
'updateFiles'
]);
}
}
protected
function
updateClassPropertyDocs
(
$file
,
$className
,
$propertyDoc
)
protected
function
updateClassPropertyDocs
(
$file
,
$className
,
$propertyDoc
)
...
...
extensions/apidoc/commands/ApiController.php
View file @
5567caf4
...
@@ -159,8 +159,8 @@ class ApiController extends BaseController
...
@@ -159,8 +159,8 @@ class ApiController extends BaseController
/**
/**
* @inheritdoc
* @inheritdoc
*/
*/
public
function
options
(
$
i
d
)
public
function
options
(
$
actionI
d
)
{
{
return
array_merge
(
parent
::
options
(
$
i
d
),
[
'template'
,
'guide'
]);
return
array_merge
(
parent
::
options
(
$
actionI
d
),
[
'template'
,
'guide'
]);
}
}
}
}
extensions/apidoc/commands/GuideController.php
View file @
5567caf4
...
@@ -114,8 +114,8 @@ class GuideController extends BaseController
...
@@ -114,8 +114,8 @@ class GuideController extends BaseController
/**
/**
* @inheritdoc
* @inheritdoc
*/
*/
public
function
options
(
$
i
d
)
public
function
options
(
$
actionI
d
)
{
{
return
array_merge
(
parent
::
options
(
$
i
d
),
[
'apiDocs'
]);
return
array_merge
(
parent
::
options
(
$
actionI
d
),
[
'apiDocs'
]);
}
}
}
}
extensions/apidoc/components/BaseController.php
View file @
5567caf4
...
@@ -126,8 +126,8 @@ abstract class BaseController extends Controller
...
@@ -126,8 +126,8 @@ abstract class BaseController extends Controller
/**
/**
* @inheritdoc
* @inheritdoc
*/
*/
public
function
options
(
$
i
d
)
public
function
options
(
$
actionI
d
)
{
{
return
array_merge
(
parent
::
options
(
$
i
d
),
[
'template'
,
'exclude'
]);
return
array_merge
(
parent
::
options
(
$
actionI
d
),
[
'template'
,
'exclude'
]);
}
}
}
}
extensions/faker/FixtureController.php
View file @
5567caf4
...
@@ -171,12 +171,11 @@ class FixtureController extends \yii\console\controllers\FixtureController
...
@@ -171,12 +171,11 @@ class FixtureController extends \yii\console\controllers\FixtureController
/**
/**
* Returns the names of the global options for this command.
* @inheritdoc
* @return array the names of the global options for this command.
*/
*/
public
function
options
(
$
i
d
)
public
function
options
(
$
actionI
d
)
{
{
return
array_merge
(
parent
::
options
(
$
i
d
),
[
return
array_merge
(
parent
::
options
(
$
actionI
d
),
[
'templatePath'
,
'language'
,
'fixtureDataPath'
'templatePath'
,
'language'
,
'fixtureDataPath'
]);
]);
}
}
...
...
framework/base/View.php
View file @
5567caf4
...
@@ -141,7 +141,6 @@ class View extends Component
...
@@ -141,7 +141,6 @@ class View extends Component
public
function
render
(
$view
,
$params
=
[],
$context
=
null
)
public
function
render
(
$view
,
$params
=
[],
$context
=
null
)
{
{
$viewFile
=
$this
->
findViewFile
(
$view
,
$context
);
$viewFile
=
$this
->
findViewFile
(
$view
,
$context
);
return
$this
->
renderFile
(
$viewFile
,
$params
,
$context
);
return
$this
->
renderFile
(
$viewFile
,
$params
,
$context
);
}
}
...
...
framework/caching/MemCache.php
View file @
5567caf4
...
@@ -78,6 +78,7 @@ class MemCache extends Cache
...
@@ -78,6 +78,7 @@ class MemCache extends Cache
*/
*/
private
$_servers
=
[];
private
$_servers
=
[];
/**
/**
* Initializes this application component.
* Initializes this application component.
* It creates the memcache instance and adds memcache servers.
* It creates the memcache instance and adds memcache servers.
...
...
framework/console/Controller.php
View file @
5567caf4
...
@@ -264,10 +264,10 @@ class Controller extends \yii\base\Controller
...
@@ -264,10 +264,10 @@ class Controller extends \yii\base\Controller
* Note that the values setting via options are not available
* Note that the values setting via options are not available
* until [[beforeAction()]] is being called.
* until [[beforeAction()]] is being called.
*
*
* @param string $
id action name
* @param string $
actionId the action id of the current request
* @return array the names of the options valid for the action
* @return array the names of the options valid for the action
*/
*/
public
function
options
(
$
i
d
)
public
function
options
(
$
actionI
d
)
{
{
// $id might be used in subclass to provide options specific to action id
// $id might be used in subclass to provide options specific to action id
return
[
'color'
,
'interactive'
];
return
[
'color'
,
'interactive'
];
...
...
framework/console/controllers/FixtureController.php
View file @
5567caf4
...
@@ -33,7 +33,6 @@ use yii\test\FixtureTrait;
...
@@ -33,7 +33,6 @@ use yii\test\FixtureTrait;
*/
*/
class
FixtureController
extends
Controller
class
FixtureController
extends
Controller
{
{
use
FixtureTrait
;
use
FixtureTrait
;
/**
/**
...
@@ -57,13 +56,13 @@ class FixtureController extends Controller
...
@@ -57,13 +56,13 @@ class FixtureController extends Controller
'yii\test\InitDb'
,
'yii\test\InitDb'
,
];
];
/**
/**
* Returns the names of the global options for this command.
* @inheritdoc
* @return array the names of the global options for this command.
*/
*/
public
function
options
(
$
i
d
)
public
function
options
(
$
actionI
d
)
{
{
return
array_merge
(
parent
::
options
(
$
i
d
),
[
return
array_merge
(
parent
::
options
(
$
actionI
d
),
[
'namespace'
,
'globalFixtures'
'namespace'
,
'globalFixtures'
]);
]);
}
}
...
...
framework/console/controllers/MigrateController.php
View file @
5567caf4
...
@@ -92,14 +92,13 @@ class MigrateController extends Controller
...
@@ -92,14 +92,13 @@ class MigrateController extends Controller
public
$db
=
'db'
;
public
$db
=
'db'
;
/**
/**
* Returns the names of the global options for this command.
* @inheritdoc
* @return array the names of the global options for this command.
*/
*/
public
function
options
(
$
i
d
)
public
function
options
(
$
actionI
d
)
{
{
return
array_merge
(
parent
::
options
(
$
i
d
),
return
array_merge
(
parent
::
options
(
$
actionI
d
),
[
'migrationPath'
,
'migrationTable'
,
'db'
],
// global for all actions
[
'migrationPath'
,
'migrationTable'
,
'db'
],
// global for all actions
(
$
i
d
==
'create'
)
?
[
'templateFile'
]
:
[]
// action create
(
$
actionI
d
==
'create'
)
?
[
'templateFile'
]
:
[]
// action create
);
);
}
}
...
...
framework/data/ArrayDataProvider.php
View file @
5567caf4
...
@@ -64,6 +64,7 @@ class ArrayDataProvider extends BaseDataProvider
...
@@ -64,6 +64,7 @@ class ArrayDataProvider extends BaseDataProvider
*/
*/
public
$allModels
;
public
$allModels
;
/**
/**
* @inheritdoc
* @inheritdoc
*/
*/
...
...
framework/db/ActiveQuery.php
View file @
5567caf4
...
@@ -91,6 +91,7 @@ class ActiveQuery extends Query implements ActiveQueryInterface
...
@@ -91,6 +91,7 @@ class ActiveQuery extends Query implements ActiveQueryInterface
*/
*/
public
$joinWith
;
public
$joinWith
;
/**
/**
* Executes query and returns all results as an array.
* Executes query and returns all results as an array.
* @param Connection $db the DB connection used to create the DB command.
* @param Connection $db the DB connection used to create the DB command.
...
...
framework/helpers/BaseFileHelper.php
View file @
5567caf4
...
@@ -285,14 +285,14 @@ class BaseFileHelper
...
@@ -285,14 +285,14 @@ class BaseFileHelper
if
(
isset
(
$options
[
'except'
]))
{
if
(
isset
(
$options
[
'except'
]))
{
foreach
(
$options
[
'except'
]
as
$key
=>
$value
)
{
foreach
(
$options
[
'except'
]
as
$key
=>
$value
)
{
if
(
is_string
(
$value
))
{
if
(
is_string
(
$value
))
{
$options
[
'except'
][
$key
]
=
s
tatic
::
parseExcludePattern
(
$value
);
$options
[
'except'
][
$key
]
=
s
elf
::
parseExcludePattern
(
$value
);
}
}
}
}
}
}
if
(
isset
(
$options
[
'only'
]))
{
if
(
isset
(
$options
[
'only'
]))
{
foreach
(
$options
[
'only'
]
as
$key
=>
$value
)
{
foreach
(
$options
[
'only'
]
as
$key
=>
$value
)
{
if
(
is_string
(
$value
))
{
if
(
is_string
(
$value
))
{
$options
[
'only'
][
$key
]
=
s
tatic
::
parseExcludePattern
(
$value
);
$options
[
'only'
][
$key
]
=
s
elf
::
parseExcludePattern
(
$value
);
}
}
}
}
}
}
...
...
framework/helpers/BaseHtml.php
View file @
5567caf4
...
@@ -342,7 +342,7 @@ class BaseHtml
...
@@ -342,7 +342,7 @@ class BaseHtml
/**
/**
* Generates an image tag.
* Generates an image tag.
* @param string $src the image URL. This parameter will be processed by [[yii\helpers\Url::to()]].
* @param
array|
string $src the image URL. This parameter will be processed by [[yii\helpers\Url::to()]].
* @param array $options the tag options in terms of name-value pairs. These will be rendered as
* @param array $options the tag options in terms of name-value pairs. These will be rendered as
* the attributes of the resulting tag. The values will be HTML-encoded using [[encode()]].
* the attributes of the resulting tag. The values will be HTML-encoded using [[encode()]].
* If a value is null, the corresponding attribute will not be rendered.
* If a value is null, the corresponding attribute will not be rendered.
...
...
framework/i18n/MessageFormatter.php
View file @
5567caf4
...
@@ -220,7 +220,9 @@ class MessageFormatter extends Component
...
@@ -220,7 +220,9 @@ class MessageFormatter extends Component
if
(
!
isset
(
$token
[
2
]))
{
if
(
!
isset
(
$token
[
2
]))
{
return
false
;
return
false
;
}
}
$subtokens
=
self
::
tokenizePattern
(
$token
[
2
]);
if
((
$subtokens
=
self
::
tokenizePattern
(
$token
[
2
]))
===
false
)
{
return
false
;
}
$c
=
count
(
$subtokens
);
$c
=
count
(
$subtokens
);
for
(
$k
=
0
;
$k
+
1
<
$c
;
$k
++
)
{
for
(
$k
=
0
;
$k
+
1
<
$c
;
$k
++
)
{
if
(
is_array
(
$subtokens
[
$k
])
||
!
is_array
(
$subtokens
[
++
$k
]))
{
if
(
is_array
(
$subtokens
[
$k
])
||
!
is_array
(
$subtokens
[
++
$k
]))
{
...
...
framework/web/Request.php
View file @
5567caf4
...
@@ -124,8 +124,8 @@ class Request extends \yii\base\Request
...
@@ -124,8 +124,8 @@ class Request extends \yii\base\Request
*/
*/
public
$enableCookieValidation
=
true
;
public
$enableCookieValidation
=
true
;
/**
/**
* @var string
|boolean
the name of the POST parameter that is used to indicate if a request is a PUT, PATCH or DELETE
* @var string the name of the POST parameter that is used to indicate if a request is a PUT, PATCH or DELETE
* request tunneled through POST. Default to '_method'.
* request tunneled through POST. Default
s
to '_method'.
* @see getMethod()
* @see getMethod()
* @see getBodyParams()
* @see getBodyParams()
*/
*/
...
...
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