serialnumber is a model name and i have a is_sold column with value 0 …if condition is true it should update and its value should be 1 - development

serialnumber is a model name and i have a is_sold column with value 0 …if condition is true it should update and its value should be 1

serialnumber is a model name and i have a is_sold column with value 0 …if condition is true it should update and its value should be 1

if ($serial == 'serialnumber' and 'Is_Sold' == 0)
  {

    serialNumber::update('Is_Sold' == 1);

    return show::create($request->all());
  }



from Laravel Questions and Answers https://laravelquestions.com/php/serialnumber-is-a-model-name-and-i-have-a-is_sold-column-with-value-0-if-condition-is-true-it-should-update-and-its-value-should-be-1/
via Lzo Media

Comments

Popular posts from this blog

ng-show doesn’t work correct with value boolean

ng-include of inline SVG does not display gradient except in Chrome