Skip to content
This repository has been archived by the owner on Jun 12, 2024. It is now read-only.

How to show continuous serial number in naygest grid #466

Open
arivu1995 opened this issue Mar 24, 2020 · 0 comments
Open

How to show continuous serial number in naygest grid #466

arivu1995 opened this issue Mar 24, 2020 · 0 comments

Comments

@arivu1995
Copy link

my current code
` $grid4 = new Grid(
(new GridConfig)
->setDataProvider(
new EloquentDataProvider($query)
)
->setName('work_grid')
->setPageSize(10)
->setColumns([

                (new FieldConfig)
                ->setName('id')
                ->setLabel('S.No.')
                ->setSortable(true)
                ->setCallback(function ($val, ObjectDataRow $dr) {
                    
                    static $val = 0;
                    return ++$val;
                    
                 })
                  
                ->setSortable(true)
                ->addFilter(
                    (new FilterConfig)
                        ->setOperator(FilterConfig::OPERATOR_LIKE)
                )
            , `

Thanks in advance..

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant