api lejer dan imbang duga
This commit is contained in:
@@ -0,0 +1,53 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Controllers;
|
||||
|
||||
use App\HargaEmas;
|
||||
use App\GlCode;
|
||||
use App\Cawangan;
|
||||
use Illuminate\Http\Request;
|
||||
|
||||
use Carbon\Carbon;
|
||||
|
||||
class GLCodeController extends Controller
|
||||
{
|
||||
|
||||
|
||||
|
||||
public function GetGlcode($kodcaw,Request $request) //create on 2021-02-12
|
||||
{
|
||||
|
||||
|
||||
$current = Carbon::now();
|
||||
$current = new Carbon();
|
||||
|
||||
$cawangan = Cawangan::on('mysql7')->where('kodcaw','=',$kodcaw)->first();
|
||||
|
||||
|
||||
|
||||
$gc=GlCode::on($cawangan['mysql'])->where('glcode','=',$request->glcode)->get();
|
||||
return response()->json($gc);
|
||||
|
||||
|
||||
}
|
||||
|
||||
public function GetGlcodeByActType($kodcaw,$acttype)
|
||||
{
|
||||
$current = Carbon::now();
|
||||
$current = new Carbon();
|
||||
|
||||
$cawangan = Cawangan::on('mysql7')->where('kodcaw','=',$kodcaw)->first();
|
||||
|
||||
$gc=GlCode::on($cawangan['mysql'])->where('acttype','=',$acttype)->get();
|
||||
|
||||
return response()->json($gc);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user