fix uid calculation
This commit is contained in:
parent
84353dd356
commit
17e859b9ba
1 changed files with 1 additions and 1 deletions
|
@ -46,7 +46,7 @@ class ItemController extends Controller
|
||||||
public function create($event, Request $request)
|
public function create($event, Request $request)
|
||||||
{
|
{
|
||||||
$eid = Event::where('slug','=',$event)->first()->eid;
|
$eid = Event::where('slug','=',$event)->first()->eid;
|
||||||
$uid = Item::where('eid',$eid)->max('item_uid') + 1;
|
$uid = Item::withTrashed()->where('eid',$eid)->max('item_uid') + 1;
|
||||||
$newitem = $request->except(['dataImage']);
|
$newitem = $request->except(['dataImage']);
|
||||||
$newitem['eid'] = "".$eid;
|
$newitem['eid'] = "".$eid;
|
||||||
$newitem['item_uid'] = $uid;
|
$newitem['item_uid'] = $uid;
|
||||||
|
|
Loading…
Reference in a new issue