Closed 8lbiasian closed 8 years ago
on the html builder you want the 'title' attribute.
public function html()
{
return $this->builder()
->columns([
[
"name" => "contractvalue",
"title" => "Contract Value",
"data" => "contractvalue"
],
@Skintillion i try this before but it give me this error
update:
thanks its work now i think there was some missing lines i didnt add to end >_<
thanks again
Guys FYI: https://github.com/yajra/laravel-datatables/issues/265 Major breaking change is coming next week.
public function html() { return $this->builder() ->columns($this->getColumns()) ->minifiedAjax() ->addAction(['width' => '120px', 'printable' => false]) ->parameters([ 'dom' => 'Bfrtip', 'stateSave' => true, 'order' => [[0, 'desc']], 'buttons' => [ ['extend' => 'export', 'className' => 'btn btn-default btn-sm no-corner',], ['extend' => 'print', 'className' => 'btn btn-default btn-sm no-corner',], ['extend' => 'reload', 'className' => 'btn btn-default btn-sm no-corner',], ], ]); }
protected function getColumns() { return [ 'id', 'name', 'section', 'contact', 'approved', 'cardno', 'issuedate', 'status' => 'Approval Status' ]; }
I got the above DataTables warning
@Fionajeremychik Use an array to set the attributes.
['data' => 'status', 'title' => 'Approval Status']
Thanks. I got it.
Hi Arjay,
Thank for your help.
[image: Screenshot 2020-07-07 at 9.08.52 PM.png]
On Mon, 6 Jul 2020 at 12:04, Arjay Angeles notifications@github.com wrote:
@Fionajeremychik https://github.com/Fionajeremychik Use an array to set the attributes.
['data' => 'status', 'title' => 'Approval Status']
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/yajra/laravel-datatables/issues/264#issuecomment-653977842, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAFHM4BRZSOBMFR5WLHO4GTR2EWJNANCNFSM4BVG3YIA .
Try to read the documentation a bit. You can't rely on us to answer every basic question without trying yourself.
On Tue, Jul 7, 2020, 4:16 AM Fionajeremychik, notifications@github.com wrote:
Hi Arjay,
Thank for your help.
[image: Screenshot 2020-07-07 at 9.08.52 PM.png]
- How to add placeholder inside the Search field
- How to add header title inside Excel How to disable to export pdf How to print
On Mon, 6 Jul 2020 at 12:04, Arjay Angeles notifications@github.com wrote:
@Fionajeremychik https://github.com/Fionajeremychik Use an array to set the attributes.
['data' => 'status', 'title' => 'Approval Status']
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub < https://github.com/yajra/laravel-datatables/issues/264#issuecomment-653977842 , or unsubscribe < https://github.com/notifications/unsubscribe-auth/AAFHM4BRZSOBMFR5WLHO4GTR2EWJNANCNFSM4BVG3YIA
.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/yajra/laravel-datatables/issues/264#issuecomment-654783072, or unsubscribe https://github.com/notifications/unsubscribe-auth/AALTOYQNV6VPAPWQEBP2AHDR2L7X5ANCNFSM4BVG3YIA .
Hi Arjay,
Can you tell me where I can find the document? Thanks
On Wed, 8 Jul 2020 at 01:56, Skintillion notifications@github.com wrote:
Try to read the documentation a bit. You can't rely on us to answer every basic question without trying yourself.
On Tue, Jul 7, 2020, 4:16 AM Fionajeremychik, notifications@github.com wrote:
Hi Arjay,
Thank for your help.
[image: Screenshot 2020-07-07 at 9.08.52 PM.png]
- How to add placeholder inside the Search field
- How to add header title inside Excel How to disable to export pdf How to print
On Mon, 6 Jul 2020 at 12:04, Arjay Angeles notifications@github.com wrote:
@Fionajeremychik https://github.com/Fionajeremychik Use an array to set the attributes.
['data' => 'status', 'title' => 'Approval Status']
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub <
https://github.com/yajra/laravel-datatables/issues/264#issuecomment-653977842
, or unsubscribe <
https://github.com/notifications/unsubscribe-auth/AAFHM4BRZSOBMFR5WLHO4GTR2EWJNANCNFSM4BVG3YIA
.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub < https://github.com/yajra/laravel-datatables/issues/264#issuecomment-654783072 , or unsubscribe < https://github.com/notifications/unsubscribe-auth/AALTOYQNV6VPAPWQEBP2AHDR2L7X5ANCNFSM4BVG3YIA
.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/yajra/laravel-datatables/issues/264#issuecomment-654959561, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAFHM4BP7MOY2A44FLS4JFDR2NATHANCNFSM4BVG3YIA .
how i can change the header title ?
i use the Datatables as service and i try the edit column but its affect the result of that column not the title of it
for example the id column i need to make it as # also from my database i have some spelling mistake so i was think it will be easy if there is way to edit the column name from the table it self rather than playing with db again =(