mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/exchange.git
synced 2026-08-23 14:24:17 +00:00
hide rate id from model
fixed DB not found in rate controller
This commit is contained in:
@@ -35,7 +35,7 @@ class RateController extends Controller
|
||||
|
||||
public function show()
|
||||
{
|
||||
$rate = DB::table('rates')->latest()->first();
|
||||
$rate = Rate::latest()->first();
|
||||
|
||||
return response()->json($rate, 200);
|
||||
}
|
||||
|
||||
@@ -7,4 +7,5 @@ use Illuminate\Database\Eloquent\Model;
|
||||
class Rate extends Model
|
||||
{
|
||||
protected $fillable = ['x1_cash','x1_cheque','x1_ba','x2_cash','x2_cheque','x2_ba'];
|
||||
protected $hidden = ['id'];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user