69 Commits

Author SHA1 Message Date
40b1ec3799 release version 2.0.52 2025-02-13 23:02:28 +03:00
02ef942c53 Added missing underscore in front of private property #20267 2024-10-19 20:48:31 +03:00
8a0992d5c0 Fixed called class check in Widget::end() when widget configured using callable
See #20267
2024-10-19 20:37:49 +03:00
52e4a3e645 release version 2.0.50 2024-05-30 20:23:31 +03:00
e2a167028b Upgrade to PSR12 coding standard (#20121) 2024-03-19 17:21:27 +03:00
161526cd41 HTTPS everywhere (#19503) 2022-08-03 12:32:18 +03:00
4768cb0f1d Fix returning type of yii\base\Widget::run() (#19378) 2022-05-04 10:34:41 +03:00
a87c02c712 Fix more types (#19333)
* Migration::upsert() returns void

* Unneeded `@property` tags

* Add missing `null` param/return types

* Null types for db\Query + db\ActiveQuery

* Fixed testSelect

* Null types for Validator

* Several more null types

* One more

* Make AccessRule::$allow always a boolean

It doesn't have any special null handling, so it's safe to default to false

* Validator::$skipOnEmpty is always a boolean

* Catch all throwable from Widget::widget()

* Don't limit $previous args to \Exception

The actual \Exception allows $previous to be any throwable in PHP 7+

* Add Throwable catch block to Instance::get()

* Throwable cleanup

Comment changes only.

- Document \Throwable instead of \Exception wherever appropriate
- Removed redundant exception/error classes when \Throwable is referenced

* Yii::setlogger() accepts null

* ArrayHelper::removeValue() can remove any type of value

* Change default $allow value to false
2022-04-03 11:20:21 +02:00
655786b7ed release version 2.0.44 2021-12-30 10:50:56 +03:00
0d899fa18b Fix #19030: Add DI container usage to yii\base\Widget::end() 2021-11-30 23:58:24 +03:00
4e2045c040 release version 2.0.41 2021-03-04 00:51:35 +03:00
ccb14ff667 release version 2.0.39 2020-11-10 13:58:35 +03:00
2ce927788a Update phpdoc for widget->getId (#18295)
The private variable `$_id`  is only set when `$autogenerate` is true, else it stays null, and will be returned by the function.
2020-09-21 14:56:52 +03:00
2c997cdb82 Fixes #16184: Fixed yii\base\Widget to access stack property with self instead of static 2018-04-29 12:36:10 +03:00
e6f5c46cdc Fixes #15633: Deprecate some things going away/changing in 2.1
- Deprecated `yii\base\BaseObject::className()` in favor of native PHP syntax `::class`, which does not trigger autoloading
- Deprecated XCache and Zend data cache support as caching backends
- Deprecated `yii\BaseYii::powered()` method
- Added `yii\base\InvalidArgumentException` and deprecated `yii\base\InvalidParamException`
- Added `yii\BaseYii::debug()` and deprecated `yii\BaseYii::trace()`
2018-02-11 01:48:29 +03:00
5a8c3d537b Enable phpdoc_summary rule in php-cs-fixer config (#14675)
* Enable `phpdoc_summary` rule in php-cs-fixer config.

* Fix case in "PHPDoc".
2017-08-21 11:19:35 +02:00
1501c659ac Add empty lines before return statements. (#14682) [skip ci] 2017-08-21 01:58:49 +03:00
fe8a0a6a2e Enable no_useless_else rule in php-cs-fixer (#14420) 2017-07-10 11:26:21 +03:00
ba0ab403b5 Added php-cs-fixer coding standards validation to Travis CI (#14100)
* php-cs-fixer: PSR2 rule.

* php-cs-fixer: PSR2 rule - fix views.

* Travis setup refactoring.

* Add php-cs-fixer to travis cs tests.

* Fix tests on hhvm-3.12

* improve travis config

* composer update

* revert composer update

* improve travis config

* Fix CS.

* Extract config to separate classes.

* Extract config to separate classes.

* Add file header.

* Force short array syntax.

* binary_operator_spaces fixer

* Fix broken tests

* cast_spaces fixer

* concat_space fixer

* dir_constant fixer

* ereg_to_preg fixer

* function_typehint_space fixer

* hash_to_slash_comment fixer

* is_null fixer

* linebreak_after_opening_tag fixer

* lowercase_cast fixer

* magic_constant_casing fixer

* modernize_types_casting fixer

* native_function_casing fixer

* new_with_braces fixer

* no_alias_functions fixer

* no_blank_lines_after_class_opening fixer

* no_blank_lines_after_phpdoc fixer

* no_empty_comment fixer

* no_empty_phpdoc fixer

* no_empty_statement fixer

* no_extra_consecutive_blank_lines fixer

* no_leading_import_slash fixer

* no_leading_namespace_whitespace fixer

* no_mixed_echo_print fixer

* no_multiline_whitespace_around_double_arrow fixer

* no_multiline_whitespace_before_semicolons fixer

* no_php4_constructor fixer

* no_short_bool_cast fixer

* no_singleline_whitespace_before_semicolons fixer

* no_spaces_around_offset fixer

* no_trailing_comma_in_list_call fixer

* no_trailing_comma_in_singleline_array fixer

* no_unneeded_control_parentheses fixer

* no_unused_imports fixer

* no_useless_return fixer

* no_whitespace_before_comma_in_array fixer

* no_whitespace_in_blank_line fixer

* not_operator_with_successor_space fixer

* object_operator_without_whitespace fixer

* ordered_imports fixer

* php_unit_construct fixer

* php_unit_dedicate_assert fixer

* php_unit_fqcn_annotation fixer

* phpdoc_indent fixer

* phpdoc_no_access fixer

* phpdoc_no_empty_return fixer

* phpdoc_no_package fixer

* phpdoc_no_useless_inheritdoc fixer

* Fix broken tests

* phpdoc_return_self_reference fixer

* phpdoc_single_line_var_spacing fixer

* phpdoc_single_line_var_spacing fixer

* phpdoc_to_comment fixer

* phpdoc_trim fixer

* phpdoc_var_without_name fixer

* psr4 fixer

* self_accessor fixer

* short_scalar_cast fixer

* single_blank_line_before_namespace fixer

* single_quote fixer

* standardize_not_equals fixer

* ternary_operator_spaces fixer

* trailing_comma_in_multiline_array fixer

* trim_array_spaces fixer

* protected_to_private fixer

* unary_operator_spaces fixer

* whitespace_after_comma_in_array fixer

* `parent::setRules()` -> `$this->setRules()`

* blank_line_after_opening_tag fixer

* Update finder config.

* Revert changes for YiiRequirementChecker.

* Fix array formatting.

* Add missing import.

* Fix CS for new code merged from master.

* Fix some indentation issues.
2017-06-12 12:25:45 +03:00
4b9e48b8dc improved docs: link term "path alias" to the guide 2017-06-02 10:45:20 +02:00
323568c2e9 Remove trailing spaces from sources and tests (#13621) [skip ci] 2017-02-19 17:34:22 +03:00
c19b2f7dc8 release version 2.0.11 2017-02-01 17:46:29 +01:00
920877c815 Fixed WidgetEvent construction 2017-01-28 11:55:24 +03:00
7c1693479f Fixes #12000: Added EVENT_INIT to widget 2017-01-28 01:27:05 +03:00
767400da19 Fixes for #13457 as commented by @cebe 2017-01-28 01:22:48 +03:00
f20c0177af Fixes #7435: Added EVENT_BEFORE_RUN, EVENT_AFTER_RUN and corresponding methods to yii\base\Widget 2017-01-27 18:56:22 +03:00
4aa935e69e Fixes #12055: Changed boolean to bool and integer to int in phpdoc 2016-11-07 02:51:39 +03:00
32f4dc8997 Fixes #5385: links created from classes to corresponding guide articles (#12920) 2016-11-04 18:55:14 +03:00
93f6ddfbe9 document the fact that widgets use output buffering
so they may break ob stack when end() and begin() are called in
different views.

close #11687
2016-07-04 12:12:44 +02:00
5ab4f0f090 Better quotes usage in strings
- Use single quote where interpolation isn't necessary
- Use interpolation when it's better than concatenation
2015-10-10 00:23:52 +03:00
d34d890a32 PSR-2 if-else statement 2015-06-09 00:10:09 +03:00
38ca276e1f PSR-2 try-catch statement 2015-06-08 23:32:08 +03:00
b2e8bf2552 Update PHPDoc Comment 2015-05-26 15:47:11 +04:30
1fe171b328 only close output buffer if it is still open
Pjax did alredy close it before ExitException

fixes #8506
2015-05-21 14:22:53 +02:00
10d0ad70af close output buffer for widget on exception
while running bootstrap extension unit tests which were failing first
I found phpunit complaining about risky tests because output buffers
were not closed correctly. This change fixes this problem.

close #7844
2015-04-20 15:17:51 +02:00
3a1e0f3a5c property codestyle framework 2014-07-30 00:21:31 +02:00
0c14f47f9a Fixes #3793: Changed inline autocomplete hints style to get more IDEs support 2014-06-20 17:40:00 +04:00
d0ddb56639 Fixes #699: fixed wrong usage of self and static 2014-05-06 20:05:41 +04:00
91965fd391 phpdoc formatting issues 2014-04-23 02:55:17 +02:00
a4809bca1b Fixes #3091: Fixed inconsistent treatment of Widget::run() when a widget is used as a container and as a self-contained object 2014-04-14 20:07:16 -04:00
92bd71cd84 Fixes #2912: Relative view files will be looked for under the directory containing the view currently being rendered 2014-03-28 21:54:32 -04:00
bf3c75147d reverted breaking PHPdoc codestyle changes
issue #2852
2014-03-23 20:51:09 +01:00
b5f8a4dc22 Reformat code te be PSR-2 compatible 2014-03-16 10:46:21 +06:00
595f55c504 api doc improvements 2014-03-08 14:20:19 +01:00
1444e14853 Fixed Widget::widget 2014-01-26 23:02:59 +04:00
a2dca09e71 Modified phpdoc 2014-01-26 17:50:04 +04:00
db7e4a4401 Added echo output in case there's return 2014-01-26 17:44:19 +04:00
4023f4215a Allow writing widgets using return instead of echo in the run method to make it consistent with controller 2014-01-26 16:08:24 +04:00
0c38655217 psr-4 move 2014-01-10 21:41:43 -05:00
0d814fa523 Moved "framework" to "iii". 2013-05-09 12:00:15 -04:00