Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

4.0.3 release #2912

Merged
merged 572 commits into from
May 1, 2020
Merged
Changes from 1 commit
Commits
Show all changes
572 commits
Select commit Hold shift + click to select a range
387bc5a
Refactor get_filenames output
MGatner Mar 30, 2020
f8895e6
Update User Guide
MGatner Mar 30, 2020
e17895b
[ci skip] _remap method must have return
nyufeng Mar 30, 2020
b8d1149
Use realpath when available
MGatner Mar 30, 2020
1baa3e0
Merge pull request #2779 from Instrye/develop
lonnieezell Mar 30, 2020
f99fb14
Restore flat file return option
MGatner Mar 30, 2020
49b4359
#2780 - LIMIT.
nowackipawel Mar 30, 2020
e21ab94
Update BaseBuilder.php
nowackipawel Mar 30, 2020
214e611
make Model::paginate() use default perPage from Config\Pager->perPage…
samsonasik Mar 30, 2020
ab0f220
unit test use paginate from config pager changed
samsonasik Mar 30, 2020
9f38700
test Model::paginate() for passed per page parameter
samsonasik Mar 30, 2020
44cc945
rollback config("Pager")->perPage value after assertion test
samsonasik Mar 30, 2020
2a40c22
Merge pull request #2767 from musmanikram/2757-uncomment-tests
MGatner Mar 30, 2020
b67f186
Merge pull request #2773 from musmanikram/2762-fix-questionmark-bind
MGatner Mar 31, 2020
95165e4
add default to config(Pager)->perPage as well in Pager class
samsonasik Mar 31, 2020
07efb0e
add perPage to Pager::ensureGroup() to ensure perPage setted correctl…
samsonasik Mar 31, 2020
b0705ba
move the handle per page null check to Pager class, use pager->getPer…
samsonasik Mar 31, 2020
8dcf489
update Services::pager() to use pull Pager Config by config("Pager") …
samsonasik Mar 31, 2020
e9214b8
back to use shared pager instance in Model::paginate
samsonasik Mar 31, 2020
089231d
Merge pull request #2782 from samsonasik/model-paginate-default-perpage
MGatner Mar 31, 2020
a88c6de
Update Builder.php
nowackipawel Mar 31, 2020
9d8308a
Removed release candidate flag and renamed folder. [ci skip]
jreklund Mar 31, 2020
13b77c4
Fix #2776 add ability to paginate() query with group by
samsonasik Mar 30, 2020
6bc3ff1
add unit tests for count with group by
samsonasik Mar 30, 2020
064155f
add test for group+having and having only
samsonasik Mar 30, 2020
6e17cb9
add test for Model::pager->getDetails()[total] with on group by query
samsonasik Mar 31, 2020
b20d181
Merge pull request #2777 from samsonasik/fix-2776
lonnieezell Apr 1, 2020
d9d8226
test for Config\Services::email()
samsonasik Apr 1, 2020
88377e0
Merge pull request #2775 from jreklund/ug-tutorial
MGatner Apr 1, 2020
ca3ed2f
Merge pull request #2772 from jreklund/installation-git
MGatner Apr 1, 2020
c47ec15
test for IncomingRequest::getFileMultiple()
samsonasik Apr 3, 2020
b560240
add ability to replace {locale} to request->getLocale() in form_open(…
samsonasik Apr 3, 2020
a2f1d82
user guide for {locale} usage in form_open()
samsonasik Apr 3, 2020
566f2c4
test Autoloader::initialize() with composer path not found
samsonasik Apr 3, 2020
c0019ad
test for View\Cell::render() with class has initController() method
samsonasik Apr 3, 2020
7458688
test CLI::strlen(null)
samsonasik Apr 3, 2020
56a081b
Merge pull request #2785 from samsonasik/test-service-email
MGatner Apr 3, 2020
c1aa6f3
Merge pull request #2789 from samsonasik/test-incomingrequest-getfile…
MGatner Apr 3, 2020
89c7b17
Merge pull request #2791 from samsonasik/test-autoloader-composer-pat…
MGatner Apr 3, 2020
92699e1
Merge pull request #2792 from samsonasik/test-view-cell-init-controller
MGatner Apr 3, 2020
e1453a8
Merge pull request #2794 from samsonasik/test-cli-strlen-null
MGatner Apr 3, 2020
c101207
add MockEmail class
samsonasik Apr 2, 2020
099bce4
add test for MockEmail with autoClear parameter
samsonasik Apr 2, 2020
5479255
add archive property to archive properties data on send
samsonasik Apr 3, 2020
cd65126
test Logger::determineFile() for no stack trace
samsonasik Apr 3, 2020
34809ac
place archiving after clear() check
samsonasik Apr 4, 2020
6123d30
test for I18n\Time::toFormattedDateString
samsonasik Apr 4, 2020
dde9f6c
[ci skip] Fix download badge
samsonasik Apr 4, 2020
4463c23
Merge pull request #2797 from samsonasik/patch-1
lonnieezell Apr 4, 2020
f091665
add more test for Entity : 100% tested
samsonasik Apr 4, 2020
320acee
Update Routes.php
mostafakhudair Apr 5, 2020
f05ee25
fix from reset #2800
michalsn Apr 5, 2020
654b915
fix conflicts
michalsn Apr 5, 2020
a217bc6
add ext-mbstring to required in composer
samsonasik Apr 6, 2020
9e57362
update to use mb_ereg_replace
samsonasik Apr 6, 2020
ff8ee8a
unicode support
samsonasik Apr 6, 2020
4b3094e
test for some unicode char
samsonasik Apr 6, 2020
f0ad0b3
/u regex suffix
samsonasik Apr 6, 2020
07d583f
clean up a-zA-Z as already covered by \p{L}
samsonasik Apr 6, 2020
1750188
using realpath() for define $pathsPath in index.php
samsonasik Apr 6, 2020
df0915b
clean up buffer tweak in FeatureTestCaseTest
samsonasik Apr 6, 2020
2dce190
test Controller::validate() with string rules
samsonasik Apr 6, 2020
5921639
Check if dataset is empty before Model update.
vibbow Apr 6, 2020
3546cf9
make named constructor in Exception consistent: use return instead of…
samsonasik Apr 6, 2020
e838ee0
Merge pull request #2808 from vibbow/pr_model_update_empty_check
lonnieezell Apr 6, 2020
8c96a27
Merge pull request #2803 from samsonasik/fix-run-spark-on-mbstring-no…
lonnieezell Apr 6, 2020
e62b9cf
Merge pull request #2807 from samsonasik/test-controller-100
lonnieezell Apr 6, 2020
a13bbd2
Merge pull request #2805 from samsonasik/clean-up-feature-test-case-b…
lonnieezell Apr 6, 2020
dd8df55
Merge pull request #2804 from samsonasik/realpath-pathpaths
lonnieezell Apr 6, 2020
241a54e
Merge pull request #2809 from samsonasik/named-constructor-return
lonnieezell Apr 6, 2020
1092399
Merge pull request #2802 from michalsn/feature/qb_from_reset
lonnieezell Apr 6, 2020
52e9c03
Merge pull request #2801 from mostafakhudair/patch-2
lonnieezell Apr 6, 2020
25c58ad
Merge pull request #2798 from samsonasik/entity-100
lonnieezell Apr 6, 2020
2a2cd57
Merge pull request #2788 from samsonasik/mock-email
MGatner Apr 6, 2020
34f21ba
Merge pull request #2795 from samsonasik/test-logger-determine-file-n…
MGatner Apr 6, 2020
114147e
Merge pull request #2796 from samsonasik/test-time-toformatted-date-s…
MGatner Apr 6, 2020
cce16ad
Update params for true/false/null
MGatner Apr 6, 2020
331c284
Add optional hidden toggle
MGatner Apr 6, 2020
c3e545d
Merge pull request #2778 from MGatner/filenames
lonnieezell Apr 6, 2020
02fb82f
Ensure $_SERVER['SCRIPT_NAME'] ends with PHP
willnode Apr 7, 2020
f7dd47f
test for API\ResponseTrait::format() with format is not json or xml
samsonasik Apr 3, 2020
bd2282c
pull supportedResponseFormats from config(Format)
samsonasik Apr 7, 2020
edbd927
Update IncomingRequest.php
willnode Apr 7, 2020
7179fcc
Merge pull request #2810 from willnode/patch-1
lonnieezell Apr 7, 2020
a9ac0bb
Fix missing InvalidArgumentException in Database\BaseBuilder
samsonasik Apr 9, 2020
227f2d0
add test for invalid keys and values throw \InvalidArgumentException
samsonasik Apr 9, 2020
b836ce7
ignore coverage on !CI_DEBUG
samsonasik Apr 9, 2020
997782d
add respondUpdated() method into API\ResponseTrait
samsonasik Apr 9, 2020
3ededb0
Merge pull request #2814 from samsonasik/ignore-coverage-ci-debug
MGatner Apr 9, 2020
895f1e6
Merge pull request #2813 from samsonasik/fix-missing-invalidargumente…
MGatner Apr 9, 2020
70e7ed8
ignore coverage on exit and die
samsonasik Apr 11, 2020
47c17e9
Merge pull request #2816 from samsonasik/api-response-updated
lonnieezell Apr 15, 2020
c32b735
Merge pull request #2820 from samsonasik/ignore-coverage-exit
lonnieezell Apr 15, 2020
f67e12e
fix. URI setPath empty
nyufeng Apr 15, 2020
7845edc
Merge pull request #2671 from jreklund/sphinx
lonnieezell Apr 15, 2020
348b352
use ternary and del error
nyufeng Apr 15, 2020
6596559
Fixes typos and code examples in the documentation
pjio Mar 30, 2020
ecc4250
Fixes formating and whitespace in the documentation
pjio Mar 30, 2020
3490e53
Merge pull request #2790 from samsonasik/add-replace-locale-in-form-open
lonnieezell Apr 15, 2020
5f7906e
Merge pull request #2824 from Instrye/patch-setPath
lonnieezell Apr 15, 2020
611d3bb
Merge pull request #2793 from samsonasik/test-response-trait-negotiate
MGatner Apr 15, 2020
8b97001
Merge pull request #2827 from pjio/documentation-fixes
lonnieezell Apr 16, 2020
77b4f5b
Added Carbon ads
lonnieezell Apr 16, 2020
af0d333
Pagination: open page > pageCount get last page
samsonasik Apr 16, 2020
4cf13f4
Merge pull request #2834 from samsonasik/pass-more-than-page-count-ge…
lonnieezell Apr 17, 2020
965092a
add ability for nested language definition
samsonasik Apr 16, 2020
ac22f27
update documentation for nested definition language
samsonasik Apr 17, 2020
4c5ddca
more tests for Common functions
samsonasik Apr 17, 2020
5750929
Merge pull request #2837 from samsonasik/more-test-common-functions
lonnieezell Apr 17, 2020
bf135da
Merge pull request #2833 from samsonasik/add-ability-for-nested-language
lonnieezell Apr 17, 2020
8863792
Add English message for "string" validation rule
Apr 18, 2020
0707f54
Improve flash of unstyled content in userguide
jreklund Apr 18, 2020
8103879
Force citheme.css to be the default css in the userguide. [ci skip]
jreklund Apr 18, 2020
cc8b32e
add $segment option in pager call by Model.php
paul45 Apr 18, 2020
adc58c1
Fixed Issue #2840 on discovery of classes by FileLocator
paulbalandan Apr 18, 2020
5627dd2
Update Model.php
paul45 Apr 18, 2020
7f16a9a
Merge pull request #2844 from paulbalandan/correct-filelocator-namesp…
lonnieezell Apr 19, 2020
f913b58
Merge pull request #2842 from jreklund/ug-fouc
lonnieezell Apr 19, 2020
7115d64
Merge pull request #2841 from rmilecki/string-validation-message
lonnieezell Apr 19, 2020
b2152ed
Improve readability in the userguide with a fixed size [ci skip]
jreklund Apr 19, 2020
7bfd7fa
Change table white-space into pre, for better readability. [ci skip]
jreklund Apr 19, 2020
aa1b3cf
Normalize dir separator of Exceptions::cleanPath
paulbalandan Apr 19, 2020
8148ad8
Add tests for PR #2847
paulbalandan Apr 19, 2020
4a5fd8f
Add tests for PR #2847
paulbalandan Apr 19, 2020
51ab7f2
Merge branch 'normalize-exceptions-cleanpath' of https://github.com/p…
paulbalandan Apr 19, 2020
0c4725d
Merge pull request #2709 from Instrye/patch-1
lonnieezell Apr 20, 2020
34d6338
Merge pull request #2846 from jreklund/ug-fixed-width
lonnieezell Apr 20, 2020
b3aeba5
Merge pull request #2755 from Instrye/patch-2
lonnieezell Apr 20, 2020
c69ab50
Merge pull request #2781 from nowackipawel/patch-84
lonnieezell Apr 20, 2020
dba8ff4
Strip directory separators from auto-generated cell cache name. Fixes…
lonnieezell Apr 20, 2020
4cb62d1
Removed view paths on paths to clean
paulbalandan Apr 20, 2020
39a4867
Merge pull request #2851 from codeigniter4/cellcachename
lonnieezell Apr 20, 2020
3e6b851
Merge pull request #2847 from paulbalandan/normalize-exceptions-clean…
lonnieezell Apr 20, 2020
b9435d5
Enclose file paths in double quotes to capture spaces
paulbalandan Apr 20, 2020
a70fa50
[ci skip] typo fix Initial Configuration & Set Up
samsonasik Apr 20, 2020
0b838b8
fix. filters alias multiple
nyufeng Apr 21, 2020
e90126f
Merge pull request #2857 from Instrye/alias-filter-multiple
lonnieezell Apr 21, 2020
4216e19
Merge pull request #2856 from samsonasik/typo-fix-develop-development
lonnieezell Apr 21, 2020
0cf609e
Merge pull request #2853 from paulbalandan/bugfix/precommit-filepath-…
lonnieezell Apr 21, 2020
fa559ad
Merge branch 'colored-cli-in-table' of git://github.com/enix-app/Code…
lonnieezell Apr 21, 2020
549f3f7
Fix failing tests
lonnieezell Apr 21, 2020
05e1734
Merge branch 'enix-app-colored-cli-in-table' into develop
lonnieezell Apr 21, 2020
4f3f453
[ci skip]fix. getHeader return header object
nyufeng Apr 21, 2020
b9db954
fix. getGetPost and getPostGet can't work in index empty
nyufeng Apr 21, 2020
88e73cb
fix. saveData not work
nyufeng Apr 21, 2020
c54a7b1
add @param comment
paul45 Apr 21, 2020
a5c3c58
Merge pull request #2860 from Instrye/patch-1
lonnieezell Apr 21, 2020
40b77c2
Merge remote-tracking branch 'upstream/master' into user_guide
jlamim Apr 21, 2020
f26e637
Merge branch 'develop' into user_guide
jlamim Apr 21, 2020
96e72f6
Merge pull request #2859 from Instrye/getHeaderRst
lonnieezell Apr 21, 2020
30cd24d
Bug: '' Property in Seeder Class Never Initialize #2825
jlamim Apr 21, 2020
8f5f680
fix. Parser use tempData
nyufeng Apr 22, 2020
7f717ae
fix. saveData must true after false
nyufeng Apr 22, 2020
6006d09
Merge pull request #2864 from jlamim/forge_in_seeder
lonnieezell Apr 22, 2020
27dc596
Merge pull request #2861 from Instrye/develop
lonnieezell Apr 22, 2020
0eea4b2
Merge pull request #2843 from paul45/patch-1
lonnieezell Apr 22, 2020
e95a573
[ci skip] Updating user guide for extra pagination values.
lonnieezell Apr 22, 2020
65e5015
[ci skip] update translations version
nyufeng Apr 22, 2020
cbffcbd
Merge pull request #2867 from Instrye/patch-4
lonnieezell Apr 22, 2020
6f4424c
translate label in validation rules
michalsn Apr 22, 2020
4f044c1
localize custom error messages
michalsn Apr 22, 2020
b24aba1
more test for View::renderString() for null tempData
samsonasik Apr 22, 2020
599d7dc
[ci skip] update docs
michalsn Apr 22, 2020
8546166
[ci skip] update docs syntax
michalsn Apr 22, 2020
e3c6629
Merge pull request #2868 from michalsn/localized_label
lonnieezell Apr 22, 2020
dc733a9
Merge pull request #2869 from samsonasik/more-test-view
lonnieezell Apr 22, 2020
ab5c587
clean up use statements: remove unused and sort
samsonasik Apr 22, 2020
3636585
add more test CodeIgniter::forceSecureAccess() run force_https()
samsonasik Apr 23, 2020
7a56b33
move ignore coverage on before and after exit
samsonasik Apr 23, 2020
a37a56d
Fix session status check
samsonasik Apr 23, 2020
ee7624b
add test for force_https() null request and response will create on t…
samsonasik Apr 23, 2020
d4be3c3
ignore coverage for session regenerate test on force_https
samsonasik Apr 23, 2020
96f2308
test force https null request and response assertion
samsonasik Apr 23, 2020
10f1624
test assert header Location before and after force_https called
samsonasik Apr 23, 2020
4a881a9
clean up response var redefinition in test force secure
samsonasik Apr 23, 2020
529a4c8
using @runInSeparateProcess & @preserveGlobalState disabled for test…
samsonasik Apr 23, 2020
060226d
Better locale matching against broad groups. Fixes #2774
lonnieezell Apr 23, 2020
cf5bf7c
Added link for @see
lonnieezell Apr 23, 2020
b4bc1b4
Merge pull request #2872 from codeigniter4/localematching
lonnieezell Apr 23, 2020
6d462d2
Shifted basic URI Routing example down
nmolinos Apr 24, 2020
effb0f2
Merge pull request #2874 from nmolinos/patch-1
lonnieezell Apr 24, 2020
b3a43e3
Merge branch 'develop' into user_guide
jlamim Apr 24, 2020
b9a6417
[ci skip] Correction in the name of the variables that receive the ca…
jlamim Apr 24, 2020
e80cba7
[ci skip] Correction of the entity instantiation
jlamim Apr 24, 2020
098b7fe
Merge pull request #2878 from jlamim/user_guide
lonnieezell Apr 24, 2020
07c9d3c
Build Your First Application used url_title incorrectly
jreklund Apr 25, 2020
8f47a6e
Added more Common functions and improved rendering [ci skip]
jreklund Apr 25, 2020
7066153
[ci skip] fix warnings on compiling user guide
paulbalandan Apr 26, 2020
5b8f469
[ci skip] route placeholders 'id' to 'num'
nyufeng Apr 27, 2020
72b57e9
[ci skip] fix missing ']'
nyufeng Apr 27, 2020
2e2d3f2
Merge pull request #2891 from Instrye/develop
lonnieezell Apr 27, 2020
f310c91
Merge pull request #2886 from paulbalandan/fix-validation-user-guide
lonnieezell Apr 27, 2020
f6286ac
Merge pull request #2883 from jreklund/url_title
lonnieezell Apr 27, 2020
3cff921
Merge pull request #2884 from jreklund/general-topics
lonnieezell Apr 27, 2020
9753dcc
Merge pull request #2871 from samsonasik/add-more-test-codeigniter-te…
lonnieezell Apr 27, 2020
9355f03
Merge pull request #2870 from samsonasik/clean-up-use-statements
lonnieezell Apr 27, 2020
999c59f
Update of the pagination template to make the correct use of the info…
jlamim Apr 27, 2020
fe33aa7
[ci skip] Add `make.bat` for Windows users
paulbalandan Apr 27, 2020
243c583
Added ability to string primary key via Model::delete($id)
samsonasik Apr 27, 2020
040dfdf
Make validation placeholders always available
jreklund Apr 27, 2020
6f7d041
Merge pull request #2895 from paulbalandan/user-guide-make-bat
lonnieezell Apr 28, 2020
00d0a9d
Merge pull request #2894 from samsonasik/add-ability-to-delete-non-nu…
lonnieezell Apr 28, 2020
b8379d3
Merge pull request #2892 from jlamim/bug_pagination_locale
lonnieezell Apr 28, 2020
1177019
Fixed lang() example
nmolinos Apr 28, 2020
6363c0b
Merge pull request #2898 from nmolinos/patch-2
MGatner Apr 28, 2020
f43f3a5
New features for paging in order to give the user the possibility to …
jlamim Apr 28, 2020
32e511a
Forgot parenthesis in code example in userguide.
jreklund Apr 28, 2020
423a950
Unit Tests for the new features added to the pagination
jlamim Apr 28, 2020
e20b046
[ci skip] Added information about the new features of the Pagination …
jlamim Apr 28, 2020
9a51860
Merging latest develop
lonnieezell Apr 29, 2020
956bb5f
Added carbon ads to user guide
lonnieezell Apr 29, 2020
d49e6ac
Merge pull request #2902 from codeigniter4/carbonads
lonnieezell Apr 29, 2020
0746941
Added Codeigniter Foundation to the credits
lonnieezell Apr 29, 2020
f97426e
Removed git installation method since it is only for framework develo…
lonnieezell Apr 29, 2020
054bd1a
Add Playground to the list of repositories.
lonnieezell Apr 29, 2020
06cdc12
Small user guide tweaks for clarity or best practices'
lonnieezell Apr 29, 2020
06dd676
Merge pull request #2903 from codeigniter4/ugtweaks
lonnieezell Apr 29, 2020
c3f4065
Allow bypassing content negotiation during API responses.
lonnieezell Apr 29, 2020
2783a75
Fix typo
lonnieezell Apr 29, 2020
1e3e02e
Update - Unit Tests for new methods in Pagination Class
jlamim Apr 29, 2020
a5815ce
Merge pull request #2904 from codeigniter4/apiformat
lonnieezell Apr 29, 2020
1b099a7
Merge pull request #2899 from jlamim/pagination_new_features
lonnieezell Apr 29, 2020
08dd1a5
Prepping changelogs for 4.0.3
lonnieezell Apr 30, 2020
5a81997
Reverted deletion of validation placeholders in user guide. Fixed ren…
jreklund Apr 30, 2020
99f3de5
Improved subjects in Controller and Routing chapter [ci skip]
jreklund Apr 30, 2020
f8c7796
Message had missing function and typo on function names and parameter…
jreklund Apr 30, 2020
1a00d45
Fix Model::first() only use orderBy() when group by is not empty
samsonasik Apr 30, 2020
5a06e0e
handle soft delete enabeld first, force order by
samsonasik Apr 30, 2020
31ce7de
tests for withdeleted on group by
samsonasik Apr 30, 2020
4ac0e5a
use data provider for group by aggregate first
samsonasik Apr 30, 2020
0d272bb
test for aggregate on soft delete
samsonasik Apr 30, 2020
7d515e5
clean up testFirstAggregate
samsonasik Apr 30, 2020
d53b351
clean up test with soft deleted first
samsonasik Apr 30, 2020
8eadf5d
clean up test with soft deleted first
samsonasik Apr 30, 2020
9c43d76
soft delete fix first check
samsonasik Apr 30, 2020
d3de343
fix undefined class 'CodeIgniter'
Apr 30, 2020
a95f41e
url_title() used CI3 style in user guide [ci skip]
jreklund Apr 30, 2020
e78a89a
temporary fix
samsonasik May 1, 2020
7b2294e
enforce to group by primary key if no group in withDeleted()->first()
samsonasik May 1, 2020
b425aff
final touch
samsonasik May 1, 2020
52b7a08
add check force group by only when Model::useSoftDeletes is true on M…
samsonasik May 1, 2020
734edb4
Merge pull request #2907 from samsonasik/bug-fix-first-group-by
lonnieezell May 1, 2020
da32b4f
Merge pull request #2911 from jreklund/url-helper
lonnieezell May 1, 2020
a4b86a5
Merge pull request #2910 from PingZii/patch-2
lonnieezell May 1, 2020
b83f16c
Merge pull request #2908 from jreklund/controllers-and-routing
lonnieezell May 1, 2020
73d6ae6
Merge pull request #2897 from jreklund/validation-placeholders-again
lonnieezell May 1, 2020
7c8144e
Merge pull request #2901 from jlamim/user_guide
lonnieezell May 1, 2020
2a3e169
Prepping for 4.0.3 release
lonnieezell May 1, 2020
05219d8
Small tweak to user guide html title.
lonnieezell May 1, 2020
7edf31b
Added version to changelog
lonnieezell May 1, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
add perPage to Pager::ensureGroup() to ensure perPage setted correctl…
…y in group
samsonasik committed Mar 31, 2020

Verified

This commit was signed with the committer’s verified signature.
samsonasik Abdul Malik Ikhsan
commit 07efb0e74a1f8c95601bca3fe00187be02e3b008
9 changes: 5 additions & 4 deletions system/Pager/Pager.php
Original file line number Diff line number Diff line change
@@ -205,7 +205,7 @@ public function store(string $group, int $page, int $perPage = null, int $total,
{
$this->segment[$group] = $segment;

$this->ensureGroup($group);
$this->ensureGroup($group, $perPage);

$perPage = $perPage ?? $this->config->perPage;
$this->groups[$group]['currentPage'] = $page;
@@ -494,9 +494,10 @@ public function only(array $queries):Pager
/**
* Ensures that an array exists for the group specified.
*
* @param string $group
* @param string $group
* @param integer $perPage
*/
protected function ensureGroup(string $group)
protected function ensureGroup(string $group, int $perPage = null)
{
if (array_key_exists($group, $this->groups))
{
@@ -507,7 +508,7 @@ protected function ensureGroup(string $group)
'uri' => clone current_url(true),
'hasMore' => false,
'total' => null,
'perPage' => $this->config->perPage,
'perPage' => $perPage ?? $this->config->perPage,
'pageCount' => 1,
'pageSelector' => $group === 'default' ? 'page' : 'page_' . $group,
];