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
4321503b
Commit
4321503b
authored
Oct 23, 2014
by
Nobuo Kihara
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' into docs-ja-2014-10-23
parents
62e50f46
35e7f27d
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
23 additions
and
8 deletions
+23
-8
getting-started.md
docs/internals/getting-started.md
+1
-1
git-workflow.md
docs/internals/git-workflow.md
+1
-1
CHANGELOG.md
framework/CHANGELOG.md
+2
-0
BaseConsole.php
framework/helpers/BaseConsole.php
+2
-2
exception.php
framework/views/errorHandler/exception.php
+1
-0
Session.php
framework/web/Session.php
+13
-1
ActiveField.php
framework/widgets/ActiveField.php
+1
-1
ActiveFieldTest.php
tests/unit/framework/widgets/ActiveFieldTest.php
+2
-2
No files found.
docs/internals/getting-started.md
View file @
4321503b
Getting started with Yii2 development
=====================================
1.
Clone your fork of yii2
`git clone git@github.com:<yourname>/yii2`
.
1.
Clone your fork of yii2
`git clone git@github.com:<yourname>/yii2
.git
`
.
2.
Change into the repo folder
`cd yii2`
.
3.
run
`./build/build app/link basic`
to install composer dependecies for the basic app.
This command will install foreign composer packages as normal but will link the yii2 repo to
...
...
docs/internals/git-workflow.md
View file @
4321503b
...
...
@@ -24,7 +24,7 @@ Change to the directory where you cloned Yii, normally, "yii2". Then enter the f
git remote add upstream git://github.com/yiisoft/yii2.git
```
### 3. Make sure there is an issue created for the thing you are working on if it requires signifcant effort to fix
### 3. Make sure there is an issue created for the thing you are working on if it requires signif
i
cant effort to fix
All new features and bug fixes should have an associated issue to provide a single point of reference for discussion
and documentation. Take a few minutes to look through the existing issue list for one that matches the contribution you
...
...
framework/CHANGELOG.md
View file @
4321503b
...
...
@@ -12,6 +12,7 @@ Yii Framework 2 Change Log
-
Bug #5657:
`yii\caching\ApcCache::mset()`
and
`madd()`
may cause warning in some APC setup (LAV45)
-
Bug #5665: The
`currentPage`
meta data in the RESTful result should be 1-based, similar to that in HTTP headers (qiangxue)
-
Bug #5682: The
`asset`
command would incorrectly combine CSS files when
`UrlManager::linkAssets`
is true (dmvslv)
-
Bug #5702: Parenthesis should be automatically added to
`Validator::whenClient`
to avoid js error (mdmunir, qiangxue)
-
Bug: Gii console command help information does not contain global options (qiangxue)
-
Enh #3760: Gii model generator now imports classes when necessary instead of using fully qualified class names (umneeq, samdark)
-
Enh #5223: Query builder now supports selecting sub-queries as columns (qiangxue)
...
...
@@ -21,6 +22,7 @@ Yii Framework 2 Change Log
-
Enh #5600: Allow configuring debug panels in
`yii\debug\Module::panels`
as panel class name strings (qiangxue)
-
Enh #5613: Added
`--overwrite`
option to Gii console command to support overwriting all files (motin, qiangxue)
-
Enh #5646: Call
`yii\base\ErrorHandler::unregister()`
instead of
`restore_*_handlers`
directly (aivus)
-
Enh:
`Console::confirm()`
now uses
`Console::stdout()`
instead of
`echo`
to be consistent with all other functions (cebe)
2.
0.0 October 12, 2014
----------------------
...
...
framework/helpers/BaseConsole.php
View file @
4321503b
...
...
@@ -763,13 +763,13 @@ class BaseConsole
/**
* Asks user to confirm by typing y or n.
*
* @param string $message to
echo
out before waiting for user input
* @param string $message to
print
out before waiting for user input
* @param boolean $default this value is returned if no selection is made.
* @return boolean whether user confirmed
*/
public
static
function
confirm
(
$message
,
$default
=
false
)
{
echo
$message
.
' (yes|no) ['
.
(
$default
?
'yes'
:
'no'
)
.
']:'
;
static
::
stdout
(
$message
.
' (yes|no) ['
.
(
$default
?
'yes'
:
'no'
)
.
']:'
)
;
$input
=
trim
(
static
::
stdin
());
return
empty
(
$input
)
?
$default
:
!
strncasecmp
(
$input
,
'y'
,
1
);
...
...
framework/views/errorHandler/exception.php
View file @
4321503b
...
...
@@ -88,6 +88,7 @@ html,body{
}
.header
pre
{
margin
:
10px
0
;
overflow-y
:
scroll
;
}
/* previous exceptions */
...
...
framework/web/Session.php
View file @
4321503b
...
...
@@ -229,6 +229,8 @@ class Session extends Component implements \IteratorAggregate, \ArrayAccess, \Co
}
/**
* Gets the session ID.
* This is a wrapper for [PHP session_id()](http://php.net/manual/en/function.session-id.php).
* @return string the current session ID
*/
public
function
getId
()
...
...
@@ -237,6 +239,8 @@ class Session extends Component implements \IteratorAggregate, \ArrayAccess, \Co
}
/**
* Sets the session ID.
* This is a wrapper for [PHP session_id()](http://php.net/manual/en/function.session-id.php).
* @param string $value the session ID for the current session
*/
public
function
setId
(
$value
)
...
...
@@ -257,6 +261,8 @@ class Session extends Component implements \IteratorAggregate, \ArrayAccess, \Co
}
/**
* Gets the name of the current session.
* This is a wrapper for [PHP session_name()](http://php.net/manual/en/function.session-name.php).
* @return string the current session name
*/
public
function
getName
()
...
...
@@ -265,6 +271,8 @@ class Session extends Component implements \IteratorAggregate, \ArrayAccess, \Co
}
/**
* Sets the name for the current session.
* This is a wrapper for [PHP session_name()](http://php.net/manual/en/function.session-name.php).
* @param string $value the session name for the current session, must be an alphanumeric string.
* It defaults to "PHPSESSID".
*/
...
...
@@ -274,6 +282,8 @@ class Session extends Component implements \IteratorAggregate, \ArrayAccess, \Co
}
/**
* Gets the current session save path.
* This is a wrapper for [PHP session_save_path()](http://php.net/manual/en/function.session-save-path.php).
* @return string the current session save path, defaults to '/tmp'.
*/
public
function
getSavePath
()
...
...
@@ -282,6 +292,8 @@ class Session extends Component implements \IteratorAggregate, \ArrayAccess, \Co
}
/**
* Sets the current session save path.
* This is a wrapper for [PHP session_save_path()](http://php.net/manual/en/function.session-save-path.php).
* @param string $value the current session save path. This can be either a directory name or a path alias.
* @throws InvalidParamException if the path is not a valid directory
*/
...
...
@@ -297,7 +309,7 @@ class Session extends Component implements \IteratorAggregate, \ArrayAccess, \Co
/**
* @return array the session cookie parameters.
* @see http://
us2.
php.net/manual/en/function.session-get-cookie-params.php
* @see http://php.net/manual/en/function.session-get-cookie-params.php
*/
public
function
getCookieParams
()
{
...
...
framework/widgets/ActiveField.php
View file @
4321503b
...
...
@@ -710,7 +710,7 @@ class ActiveField extends Component
$js
=
$validator
->
clientValidateAttribute
(
$this
->
model
,
$attribute
,
$this
->
form
->
getView
());
if
(
$validator
->
enableClientValidation
&&
$js
!=
''
)
{
if
(
$validator
->
whenClient
!==
null
)
{
$js
=
"if (
{
$validator
->
whenClient
}
(attribute, value)) {
$js
}"
;
$js
=
"if (
(
{
$validator
->
whenClient
}
)
(attribute, value)) {
$js
}"
;
}
$validators
[]
=
$js
;
}
...
...
tests/unit/framework/widgets/ActiveFieldTest.php
View file @
4321503b
...
...
@@ -301,8 +301,8 @@ EOD;
}
$actualValue
=
$this
->
activeField
->
getClientOptions
();
$expectedJsExpression
=
"function (attribute, value, messages, deferred) {if (function (attribute, value) "
.
"{ return 'yii2' == 'yii2'; }(attribute, value)) { return true; }}"
;
$expectedJsExpression
=
"function (attribute, value, messages, deferred) {if (
(
function (attribute, value) "
.
"{ return 'yii2' == 'yii2'; }
)
(attribute, value)) { return true; }}"
;
$this
->
assertEquals
(
$expectedJsExpression
,
$actualValue
[
'validate'
]
->
expression
);
}
...
...
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