mardi 25 juillet 2017

How to display count(*) in laravel 5.2

I got a response as follows. I need to the print the "count(*)" field along with some other data like "Duke (2)" where 2 is the count. How can I print the value in the laravel template.

{
  parts_model_id: 8,
  parts_id: 29,
  parts_title: "duke multiple model",
  model_id: 1,
  model_name: "OPAH2",
  created_at: "2017-07-18 17:02:10",
  updated_at: "2017-07-18 17:02:10",
  count(*): 2
}

Thank you



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire