Commit Graph

7597 Commits

Author SHA1 Message Date
Dmitry V. Alexeev
1761a10c13 Added phpdoc to migration template [skip ci] 2017-08-03 13:15:23 +03:00
bscheshirwork
0c0cc1074d fix current time in formatter (#14203)
* fix current time in formatter

* expand testAsDatetime

* Update FormatterDateTest.php

* Update CHANGELOG.md
2017-08-03 10:20:37 +02:00
Wanderson Bragança
5a1b12afa4 Updates the translations of messages into Brazilian Portuguese [skip ci] (#14580) 2017-08-02 23:26:30 +03:00
Alexander Makarov
89d8c0f20c Fixed changelog [skip ci] 2017-08-01 13:14:12 +03:00
Alexander Makarov
ff2bde4939 Added CVE number to escaping issue in changelog [skip ci] 2017-08-01 11:14:28 +03:00
Dmitry Dorogin
f7fb7cdd87 Fixes #14022: Added posibility to use aliases in yii\web\UrlManager::setBaseUrl() (#14540) 2017-07-31 13:32:08 +02:00
Dmitry Dorogin
e18e98ffb3 Fixes #14363: Added yii\widgets\LinkPager::$linkContainerOptions and possibility to override tag in yii\widgets\LinkPager::$options 2017-07-30 13:27:32 +03:00
PowerGamer1
459721d471 Fixes #14471: ContentNegotiator will always set one of the configured server response formats even if the client does not accept any of them 2017-07-30 00:49:33 +03:00
Alexey Rogachev
8f2d9baf98 Fixes #14186, Fixes #14510: yiiActiveForm regressions
- #14186: Forced validation in `yiiActiveForm` do not trigger `afterValidate` event
- #14510: The state of a form is always "not validated" when using forced validation in `yiiActiveForm`
2017-07-29 14:37:29 +03:00
Ondřej Vašíček
203e3d3441 Updates Czech translations (#14547) [skip ci] 2017-07-27 21:28:13 +03:00
Michaël Arnauts
e472b4e29c Fixes #14525: Fixed 2.0.12 regression of loading of global fixtures trough yii fixture/load 2017-07-26 14:35:20 +03:00
rhertogh
2ada766d83 Restored part of original Yii::trace documentation (#14534) [skip ci]
Restored original warning in the Yii::trace documentation that this method will only log a message when the application is in debug mode.
2017-07-25 16:36:14 +03:00
Klimov Paul
2466d397ae Fixed yii\validators\ExistValidator and yii\validators\UniqueValidator throw exception in case they are set for yii\db\ActiveRecord with $targetClass pointing to NOSQL ActiveRecord 2017-07-25 16:17:37 +03:00
Dmitry Dorogin
a731fd4142 Fixes #14318: Trigger yiiActiveForm.events.afterValidateAttribute after updating attribute 2017-07-24 23:25:47 +03:00
Dmitry Dorogin
d4ded67f69 Fixes #14513: Updated phpdoc and added tests for yii\rbac\ManagerInterface::assign and yii\rbac\ManagerInterface::revoke functions (#14528) 2017-07-24 23:20:03 +03:00
Dmitry Dorogin
1ee29c630d Fixes #14493: Fixed getting permissions in yii\rbac\Dbmanger::getPermissionsByUser by user with id equals 0 2017-07-24 18:42:40 +03:00
Dmitry Dorogin
e2ba94abd6 Fixes #7823: Added yii\filters\AjaxFilter filter 2017-07-24 17:25:16 +03:00
Klimov Paul
578b2caf42 Added yii\web\MultipartFormDataParser::$force option allowing to enforce parsing even on 'POST' request 2017-07-24 15:28:22 +03:00
Alexander Makarov
915c78facd Fixed ExitCode::getReason() 2017-07-24 01:06:18 +03:00
PowerGamer1
8a6f5829d4 Fix for invalid example in Request phpdoc [skip ci] 2017-07-23 23:28:54 +03:00
Dmitry Dorogin
8ae2223c6a Fixes #14370: Fixed creating built-in validator in model with same function name 2017-07-23 17:17:20 +03:00
Alexander Makarov
1f26db9fb7 Applied code style fixes 2017-07-21 15:42:06 +03:00
Alexander Makarov
acf29e0001 Fixes #14492: Fixed error handler not escaping error info debug mode 2017-07-21 12:49:33 +03:00
Dmitry Dorogin
21d2d72534 Fixes #14487: Changed i18n message error to warning 2017-07-21 12:21:46 +03:00
Sergey Makinen
92d2245ca6 Add support for an older SQLite in constraints (fixes #14483) (#14497) 2017-07-21 00:03:16 +03:00
Dmitry Dorogin
6d2e0aff82 Fixes #14406: Fixed caching rules in yii\web\UrlManager with different ruleConfig configuration 2017-07-19 23:45:03 +03:00
Carsten Brandt
393fc2744a Added yii\base\Object for backwards compatibility
fixes #7936
close #14478
2017-07-19 10:53:33 +02:00
Carsten Brandt
69673c0c94 Rename Object -> BaseObject for PHP 7.2 compatibility
issue #7936
2017-07-19 10:51:46 +02:00
Carsten Brandt
d4e584f7a7 UPGRADE notes for Object -> BaseObject for PHP 7.2 compatibility
issue #7936
2017-07-19 10:51:46 +02:00
PowerGamer1
40e242b562 Fixes #14469: updated RFC links [skip ci] 2017-07-18 22:59:25 +03:00
Nikolay Oleynikov
ea33bbd369 Fix docs of a base file helper (#14477) [skip ci] 2017-07-18 13:45:22 +03:00
Alexander Makarov
d38908fc13 Fixed #14469: updated RFC links 2017-07-17 16:21:49 +03:00
Alexander Makarov
062e1c7e67 Uppercased HTTP methods as required by RFC [skip ci] 2017-07-16 18:06:25 +03:00
Alex
59002a9e1e Fixes #6644: Added yii\helpers\ArrayHelper::setValue() 2017-07-16 00:25:44 +03:00
Carsten Brandt
2f9f15bf92 Fixes #14188: Add constants and function for sysexits(3) to ConsoleHelper 2017-07-15 23:26:15 +03:00
Alexander Makarov
0adae899ce Additional fix for SluggableBehavior immutability after merge of #13449 2017-07-15 22:07:43 +03:00
Boudewijn Vahrmeijer
03d53b785d Fixes #14449: Fix PHP 7.2 compatibility bugs and add explicit closure support in yii\base\Application 2017-07-14 12:23:03 +03:00
SilverFire - Dmitry Naumenko
b0162d3a48 Revert "Fixes #14294: Added InputWidget::renderInput() to move behavior described in InputWidget class docs to the class itself"
This reverts commit a5b393a3c1.

See https://github.com/yiisoft/yii2/pull/14441#issuecomment-315127527 for reasons
2017-07-13 21:40:29 +03:00
Carsten Brandt
a5b393a3c1 Fixes #14294: Added InputWidget::renderInput() to move behavior described in InputWidget class docs to the class itself 2017-07-13 17:04:43 +03:00
Robert Korulczyk
2fa4ccc1da Fix phpdoc for $_master and $_slave properties in yii\db\Connection (#14447) 2017-07-13 12:24:14 +02:00
Carsten Brandt
6fa48eab38 Update CHANGELOG for #14206 2017-07-13 12:12:10 +02:00
Dmitry Dorogin
6e223e6db2 Fixes #14423: Fixed ArrayHelper::merge behavior with null values for integer-keyed elements 2017-07-13 10:36:59 +03:00
nikosid
fe607b83d2 Fixes #14434: fixed metadata cache regression 2017-07-13 09:54:36 +03:00
Carsten Brandt
445019779f Fixes #14206: MySqlMutex, PgsqlMutex and OracleMutex now use useMaster() to ensure lock is aquired on the same DB server 2017-07-13 09:52:38 +03:00
qihuajun
f5e8a89319 Fix slave usage disabled after Connection::close, set _slave to false instead of nulll
fixes #14165
close #14168
2017-07-12 15:03:48 +02:00
Carsten Brandt
c9347b0a57 Fixed ambiguous column error on indexBy with JOIN
fixes #13859
close #14431
2017-07-12 12:26:30 +02:00
Carsten Brandt
173108b5b0 Move getTablesUsedInFrom() from ActiveQuery to Query
enable this feature on the Query level

close #14431
2017-07-12 12:26:20 +02:00
Carsten Brandt
0070b97837 allow migrate/mark to mark the history base (#14428)
fixes #7890
2017-07-12 11:48:03 +02:00
yyxx9988
46bf3c410a Add yii\web\Request::getOrigin() method that returns HTTP_ORIGIN of current CORS request
>The Origin request header indicates where a fetch originates from. It doesn't include any path information, but only the server name. It is sent with CORS requests, as well as with POST requests. It is similar to the Referer header, but, unlike this header, it doesn't disclose the whole path.

From https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Origin

Working code samples

```php
<?php

// We'll be granting access to only the arunranga.com domain
// which we think is safe to access this resource as application/xml

if($_SERVER['HTTP_ORIGIN'] == "http://arunranga.com") {
    header('Access-Control-Allow-Origin: http://arunranga.com');
    header('Content-type: application/xml');
    readfile('arunerDotNetResource.xml');
} else {
  header('Content-Type: text/html');
  echo "<html>";
  echo "<head>";
  echo "   <title>Another Resource</title>";
  echo "</head>";
  echo "<body>",
       "<p>This resource behaves two-fold:";
  echo "<ul>",
         "<li>If accessed from <code>http://arunranga.com</code> it returns an XML document</li>";
  echo   "<li>If accessed from any other origin including from simply typing in the URL into the browser's address bar,";
  echo   "you get this HTML document</li>",
       "</ul>",
     "</body>",
   "</html>";
}
?>
```
See https://developer.mozilla.org/en-US/docs/Web/HTTP/Server-Side_Access_Control for more info.

close #13835
2017-07-12 11:10:21 +02:00
Carsten Brandt
0559a95db9 Fixed ambiguous column error in BaseActiveRecord::refresh()
when the query adds a JOIN by default

fixes #13757
2017-07-11 11:47:35 +02:00