app/Http/Controllers/API/VentasController.php
/**
     * Store a newly created resource in storage.
     *
     * @param  \Illuminate\Http\Request  $request
     * @return \Illuminate\Http\Response
     */
Store a newly created resource in storage.
Store a newly created resource in storage .
public function store(Request $request)
    {
        $venta = Ventas::create($request->all());
        return new VentasResource($venta);
    }
public function store ( Request $ request ) { $ venta = Ventas :: create ( $ request -> all ( ) ) ; return new VentasResource ( $ venta ) ; }
Store a newly created resource in storage.
Store a newly created resource in storage .