AKB
This commit is contained in:
@@ -62,4 +62,3 @@ If you discover a security vulnerability within Laravel, please send an e-mail t
|
|||||||
## License
|
## License
|
||||||
|
|
||||||
The Laravel framework is open-sourced software licensed under the [MIT license](https://opensource.org/licenses/MIT).
|
The Laravel framework is open-sourced software licensed under the [MIT license](https://opensource.org/licenses/MIT).
|
||||||
>>>>>>> 149fecc55468d8a3bdcff628c2c339b19436829b
|
|
||||||
|
|||||||
@@ -141,12 +141,12 @@ class ItemSearchController extends Controller
|
|||||||
$jenis = $request->jenis;
|
$jenis = $request->jenis;
|
||||||
|
|
||||||
if (getRole()=="skpd"){
|
if (getRole()=="skpd"){
|
||||||
$sps = DB::select(DB::raw("SELECT x.ID_REKENING as ID,x.KODE_REKENING||' | '||z.NAMA_REKENING as name
|
$sps = DB::select(DB::raw("SELECT x.KODE_REKENING as IDX,x.KODE_REKENING||' | '||z.NAMA_REKENING as name
|
||||||
FROM SAMASA.MAPPING_DBH_SKPD x
|
FROM SAMASA.MAPPING_DBH_SKPD x
|
||||||
LEFT JOIN SAMASA.VW_REKENING_PENDAPATAN z ON x.ID_REKENING = z.ID
|
LEFT JOIN SAMASA.VW_REKENING_PENDAPATAN z ON x.ID_REKENING = z.ID
|
||||||
WHERE x.kode_skpd='".Auth::user()->nrk."'"));
|
WHERE x.kode_skpd='".Auth::user()->nrk."'"));
|
||||||
}else{
|
}else{
|
||||||
$select = DB::raw("ID,KODE_REKENING||' | '||NAMA_REKENING as name");
|
$select = DB::raw("KODE_REKENING AS IDX,KODE_REKENING||' | '||NAMA_REKENING as name");
|
||||||
$sps = VwRekeningPendapatan::select($select);
|
$sps = VwRekeningPendapatan::select($select);
|
||||||
|
|
||||||
if (!empty($search)){
|
if (!empty($search)){
|
||||||
|
|||||||
@@ -38,7 +38,7 @@ class JadwalSalurdanaController extends Controller
|
|||||||
$sqlstr = Sps_pendapatan::queryJadwalSalurDana($ta);
|
$sqlstr = Sps_pendapatan::queryJadwalSalurDana($ta);
|
||||||
|
|
||||||
if (!empty($idSPS)){
|
if (!empty($idSPS)){
|
||||||
$sqlstr.=" AND x.ID=$idSPS";
|
$sqlstr.=" AND x.KODE_REKENING='$idSPS'";
|
||||||
}
|
}
|
||||||
|
|
||||||
$dataTotal = count(DB::select(DB::raw($sqlstr)));
|
$dataTotal = count(DB::select(DB::raw($sqlstr)));
|
||||||
@@ -75,7 +75,7 @@ class JadwalSalurdanaController extends Controller
|
|||||||
{
|
{
|
||||||
if ($request->id_sps > 0)
|
if ($request->id_sps > 0)
|
||||||
{
|
{
|
||||||
$filter.=" AND x.id_sps=".$request->id_sps;
|
$filter.=" AND x.kode_rekening='".$request->id_sps."'";
|
||||||
$idSPS = $request->id_sps;
|
$idSPS = $request->id_sps;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -20,6 +20,7 @@ use App\Models\VwDpaRsk;
|
|||||||
use App\Models\VwBelanjaRealisasi;
|
use App\Models\VwBelanjaRealisasi;
|
||||||
use App\Models\UnitSatuan;
|
use App\Models\UnitSatuan;
|
||||||
use App\Models\Sp2d;
|
use App\Models\Sp2d;
|
||||||
|
use App\Models\Trbas;
|
||||||
use App\Models\Sps_pendapatan;
|
use App\Models\Sps_pendapatan;
|
||||||
use App\Imports\RealisasiBelanjaImport;
|
use App\Imports\RealisasiBelanjaImport;
|
||||||
use App\Imports\RealisasiBelanjaImportDak;
|
use App\Imports\RealisasiBelanjaImportDak;
|
||||||
@@ -126,16 +127,17 @@ class RealisasiBelanjaController extends Controller
|
|||||||
"jml_rencana_kontrak"=>isset($req["jml_rencana_kontrak"])?$req["jml_rencana_kontrak"]:0,
|
"jml_rencana_kontrak"=>isset($req["jml_rencana_kontrak"])?$req["jml_rencana_kontrak"]:0,
|
||||||
"jenis_dana"=>$req["jenis_dana"],
|
"jenis_dana"=>$req["jenis_dana"],
|
||||||
"sub_jenis_dana"=>$req["sub_jenis_dana"],
|
"sub_jenis_dana"=>$req["sub_jenis_dana"],
|
||||||
"id_sps"=>isset($req["id_sps"])?$req["id_sps"]:0,
|
// "id_sps"=>isset($req["id_sps"])?$req["id_sps"]:0,
|
||||||
"created_by"=>Auth::user()->id
|
"created_by"=>Auth::user()->id
|
||||||
];
|
];
|
||||||
|
|
||||||
if (isset($req["id_sps"]))
|
if (isset($req["id_sps"]))
|
||||||
{
|
{
|
||||||
$sps = Sps_pendapatan::where("ID", $req["id_sps"])->firstorNew();
|
$sps = Trbas::where("C_AKUN", $req["id_sps"])->firstorNew();
|
||||||
|
|
||||||
if ($sps){
|
if ($sps){
|
||||||
$input["kode_rekening"] = $sps["kode_rekening"];
|
$input["kode_rekening"] = $sps["c_akun"];
|
||||||
$input["nama_rekening"] = $sps["nama_rekening"];
|
$input["nama_rekening"] = $sps["n_akun"];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -325,7 +327,7 @@ class RealisasiBelanjaController extends Controller
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!empty($idSPS)){
|
if (!empty($idSPS)){
|
||||||
$filter.= " AND id_sps = ".$idSPS;
|
$filter.= " AND KODE_REKENING = '".$idSPS."'";
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!empty($fReview)){
|
if (!empty($fReview)){
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ use Illuminate\Support\Facades\Auth;
|
|||||||
use Maatwebsite\Excel\Facades\Excel;
|
use Maatwebsite\Excel\Facades\Excel;
|
||||||
use App\Models\PendapatanRealisasi;
|
use App\Models\PendapatanRealisasi;
|
||||||
use App\Models\Sps_pendapatan;
|
use App\Models\Sps_pendapatan;
|
||||||
|
use App\Models\VwJadwalSalur;
|
||||||
use App\Models\User;
|
use App\Models\User;
|
||||||
use PhpOffice\PhpSpreadsheet\Spreadsheet;
|
use PhpOffice\PhpSpreadsheet\Spreadsheet;
|
||||||
use PhpOffice\PhpSpreadsheet\Writer\Xlsx;
|
use PhpOffice\PhpSpreadsheet\Writer\Xlsx;
|
||||||
@@ -41,7 +42,7 @@ class RealisasiPendapatanController extends Controller
|
|||||||
protected function dataPendapatan($req= [])
|
protected function dataPendapatan($req= [])
|
||||||
{
|
{
|
||||||
$data["tahun"] = $req["txt_ta"];
|
$data["tahun"] = $req["txt_ta"];
|
||||||
$data["id_sps"] = $req["txt_id_sps"];
|
// $data["id_sps"] = $req["txt_id_sps"];
|
||||||
$txt_rek_sps = explode("|",$req["txt_rek_sps"]);
|
$txt_rek_sps = explode("|",$req["txt_rek_sps"]);
|
||||||
$data["kode_rekening_sps"] = $txt_rek_sps[0];
|
$data["kode_rekening_sps"] = $txt_rek_sps[0];
|
||||||
$data["nama_rekening_sps"] = $txt_rek_sps[1];
|
$data["nama_rekening_sps"] = $txt_rek_sps[1];
|
||||||
@@ -66,7 +67,7 @@ class RealisasiPendapatanController extends Controller
|
|||||||
$req = $request->all();
|
$req = $request->all();
|
||||||
$data = $this->dataPendapatan($req);
|
$data = $this->dataPendapatan($req);
|
||||||
$data["created_by"] = Auth::user()->id;
|
$data["created_by"] = Auth::user()->id;
|
||||||
|
// var_dump($data); exit;
|
||||||
$PendapatanRealisasi = PendapatanRealisasi::create($data);
|
$PendapatanRealisasi = PendapatanRealisasi::create($data);
|
||||||
|
|
||||||
// SEND NOTIF
|
// SEND NOTIF
|
||||||
@@ -115,7 +116,7 @@ class RealisasiPendapatanController extends Controller
|
|||||||
{
|
{
|
||||||
$idSPS = $request->idSPS;
|
$idSPS = $request->idSPS;
|
||||||
$select = DB::raw("spsbulan1,spsbulan2,spsbulan3,spsbulan4,spsbulan5,spsbulan6,spsbulan7,spsbulan8,spsbulan9,spsbulan10,spsbulan11,spsbulan12");
|
$select = DB::raw("spsbulan1,spsbulan2,spsbulan3,spsbulan4,spsbulan5,spsbulan6,spsbulan7,spsbulan8,spsbulan9,spsbulan10,spsbulan11,spsbulan12");
|
||||||
$sps = Sps_pendapatan::select($select)->where("ID",$idSPS)->firstOrNew();
|
$sps = VwJadwalSalur::select($select)->where("TAHUN",getTA())->where("KODE_REKENING",$idSPS)->firstOrNew();
|
||||||
|
|
||||||
return response()->json($sps);
|
return response()->json($sps);
|
||||||
}
|
}
|
||||||
@@ -133,7 +134,7 @@ class RealisasiPendapatanController extends Controller
|
|||||||
$data = PendapatanRealisasi::where("tahun",$ta)->orderBy("created_at","ASC");
|
$data = PendapatanRealisasi::where("tahun",$ta)->orderBy("created_at","ASC");
|
||||||
if (!empty($sps))
|
if (!empty($sps))
|
||||||
{
|
{
|
||||||
$data->where("id_sps",$sps);
|
$data->where("kode_rekening_sps",$sps);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!empty($src))
|
if (!empty($src))
|
||||||
|
|||||||
@@ -73,8 +73,8 @@ class BelanjaRealisasi extends Eloquent
|
|||||||
THEN NVL(d.jml_spd, 0) ELSE NVL(c.jml_spd, 0) END AS jml_spd
|
THEN NVL(d.jml_spd, 0) ELSE NVL(c.jml_spd, 0) END AS jml_spd
|
||||||
FROM VW_BELANJA_REALISASI a
|
FROM VW_BELANJA_REALISASI a
|
||||||
LEFT JOIN (
|
LEFT JOIN (
|
||||||
SELECT I_IDRSK,SUM(REALISASI_1) AS jml
|
SELECT I_IDRSK,SUM(REALISASI) AS jml
|
||||||
FROM MV_REALISASI_BELANJA_PERBULAN
|
FROM MV_ANGGARAN_REALISASI_RSK
|
||||||
WHERE C_ANGG_TAHUN = $ta
|
WHERE C_ANGG_TAHUN = $ta
|
||||||
GROUP BY I_IDRSK
|
GROUP BY I_IDRSK
|
||||||
) b ON a.kode_rsk = b.I_IDRSK
|
) b ON a.kode_rsk = b.I_IDRSK
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ class Sps_pendapatan extends Eloquent
|
|||||||
$sqlstr = 'SELECT * FROM VW_JADWAL_SALUR x ';
|
$sqlstr = 'SELECT * FROM VW_JADWAL_SALUR x ';
|
||||||
|
|
||||||
if (getRole()=="skpd"){
|
if (getRole()=="skpd"){
|
||||||
$sqlstr .= ' WHERE x.id IN (SELECT id_sps FROM SAMASA.MAPPING_DBH_SKPD WHERE KODE_SKPD=\''.Auth::user()->nrk.'\') ';
|
$sqlstr .= ' WHERE x.kode_rekening IN (SELECT kode_rekening FROM SAMASA.MAPPING_DBH_SKPD WHERE KODE_SKPD=\''.Auth::user()->nrk.'\') ';
|
||||||
}else{
|
}else{
|
||||||
$sqlstr .= " WHERE 1=1 ";
|
$sqlstr .= " WHERE 1=1 ";
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,14 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace App\Models;
|
||||||
|
|
||||||
|
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||||
|
use Illuminate\Database\Eloquent\Model;
|
||||||
|
use Yajra\Oci8\Eloquent\OracleEloquent as Eloquent;
|
||||||
|
|
||||||
|
class VwJadwalSalur extends Eloquent
|
||||||
|
{
|
||||||
|
use HasFactory;
|
||||||
|
protected $connection = 'Samasa';
|
||||||
|
protected $table = 'Samasa.VW_JADWAL_SALUR';
|
||||||
|
}
|
||||||
Vendored
+1
-1
@@ -375,7 +375,7 @@ $('.sps_search').select2({
|
|||||||
results: $.map(data, function (item) {
|
results: $.map(data, function (item) {
|
||||||
return {
|
return {
|
||||||
text: item.name,
|
text: item.name,
|
||||||
id: item.id
|
id: item.idx
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -133,7 +133,7 @@
|
|||||||
results: $.map(data, function (item) {
|
results: $.map(data, function (item) {
|
||||||
return {
|
return {
|
||||||
text: item.name,
|
text: item.name,
|
||||||
id: item.id
|
id: item.idx
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -238,7 +238,7 @@
|
|||||||
$('#txt_id_sps').append($('<option>',{value:"",text:""}));
|
$('#txt_id_sps').append($('<option>',{value:"",text:""}));
|
||||||
$.map(data, function (item) {
|
$.map(data, function (item) {
|
||||||
$('#txt_id_sps').append($('<option>', {
|
$('#txt_id_sps').append($('<option>', {
|
||||||
value: item.id,
|
value: item.idx,
|
||||||
text : item.name
|
text : item.name
|
||||||
}));
|
}));
|
||||||
})
|
})
|
||||||
@@ -247,7 +247,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
optionDAK();
|
optionDAK();
|
||||||
$('#txt_id_sps').val({{ $idSPS }});
|
$('#txt_id_sps').val("{{ $idSPS }}");
|
||||||
|
|
||||||
$("#src").keyup(function(e){
|
$("#src").keyup(function(e){
|
||||||
if (e.keyCode == 13){
|
if (e.keyCode == 13){
|
||||||
|
|||||||
@@ -41,9 +41,9 @@
|
|||||||
$("select[name=sub_jenis_dana]").append($newOptionSubJenisDana).trigger('change');
|
$("select[name=sub_jenis_dana]").append($newOptionSubJenisDana).trigger('change');
|
||||||
cekInputKontrak("{{ $realisasi_belanja->nama_subjenis_dana }}");
|
cekInputKontrak("{{ $realisasi_belanja->nama_subjenis_dana }}");
|
||||||
|
|
||||||
<?php if (!empty($realisasi_belanja->id_sps)) { ?>
|
<?php if (!empty($realisasi_belanja->kode_rekening)) { ?>
|
||||||
let $newOptionSps = $("<option selected='selected'></option>").val("{{ $realisasi_belanja->id_sps }}").text("{{ $sps->name }}")
|
let $newOptionSps = $("<option selected='selected'></option>").val("{{ $realisasi_belanja->kode_rekening }}").text("{{ $realisasi_belanja->nama_rekening }}")
|
||||||
$("select[name=id_sps]").val("{{ $realisasi_belanja->id_sps }}");
|
$("select[name=id_sps]").val("{{ $realisasi_belanja->kode_rekening }}");
|
||||||
$("select[name=id_sps]").append($newOptionSps).trigger('change');
|
$("select[name=id_sps]").append($newOptionSps).trigger('change');
|
||||||
<?php } ?>
|
<?php } ?>
|
||||||
|
|
||||||
|
|||||||
@@ -70,9 +70,9 @@
|
|||||||
|
|
||||||
cekInputKontrak("{{ $BelanjaRealisasi->nama_subjenis_dana }}");
|
cekInputKontrak("{{ $BelanjaRealisasi->nama_subjenis_dana }}");
|
||||||
|
|
||||||
<?php if (!empty($BelanjaRealisasi->id_sps)) { ?>
|
<?php if (!empty($BelanjaRealisasi->kode_rekening)) { ?>
|
||||||
let $newOptionSps = $("<option selected='selected'></option>").val("{{ $BelanjaRealisasi->id_sps }}").text("{{ $sps->name }}")
|
let $newOptionSps = $("<option selected='selected'></option>").val("{{ $BelanjaRealisasi->kode_rekening }}").text("{{ $BelanjaRealisasi->nama_rekening }}")
|
||||||
$("select[name=id_sps]").val("{{ $BelanjaRealisasi->id_sps }}");
|
$("select[name=id_sps]").val("{{ $BelanjaRealisasi->kode_rekening }}");
|
||||||
$("select[name=id_sps]").append($newOptionSps).trigger('change');
|
$("select[name=id_sps]").append($newOptionSps).trigger('change');
|
||||||
$("select[name=id_sps]").attr("disabled", true);
|
$("select[name=id_sps]").attr("disabled", true);
|
||||||
<?php } ?>
|
<?php } ?>
|
||||||
|
|||||||
@@ -171,7 +171,7 @@
|
|||||||
results: $.map(data, function (item) {
|
results: $.map(data, function (item) {
|
||||||
return {
|
return {
|
||||||
text: item.name,
|
text: item.name,
|
||||||
id: item.id
|
id: item.idx
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -105,7 +105,7 @@
|
|||||||
results: $.map(data, function (item) {
|
results: $.map(data, function (item) {
|
||||||
return {
|
return {
|
||||||
text: item.name,
|
text: item.name,
|
||||||
id: item.id
|
id: item.idx
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user