Update Banner dan Report
This commit is contained in:
@@ -284,9 +284,10 @@ class ReportController extends Controller
|
||||
'periksa.dlp',
|
||||
'periksa.nm_spesimen',
|
||||
'periksa.kd_spesimen',
|
||||
DB::raw("CONCAT('http://10.10.123.218/hasil/', nofoto) as urlhasil"))
|
||||
DB::raw("CONCAT('<a href=\"http://10.10.123.218/hasil/', nofoto, '\" target=\"_blank\">Lihat Hasil</a>') as urlhasil"))
|
||||
->leftJoin('periksa', 'db_komponenjawaban.accnumber', 'periksa.nofoto')
|
||||
->whereIn('db_komponenjawaban.komponen', ['id_bakteri01', 'id_bakteri02', 'bakteri'])
|
||||
->where('db_komponenjawaban.isidata', '!=', '')
|
||||
->where('periksa.daftar', 'LIKE', $tahun.'-%')->orderBy('periksa.id', 'DESC')->get();
|
||||
} else {
|
||||
$lists = DB::table('db_komponenjawaban')
|
||||
@@ -299,9 +300,10 @@ class ReportController extends Controller
|
||||
'periksa.dlp',
|
||||
'periksa.nm_spesimen',
|
||||
'periksa.kd_spesimen',
|
||||
DB::raw("CONCAT('http://10.10.123.218/hasil/', nofoto) as urlhasil"))
|
||||
DB::raw("CONCAT('<a href=\"http://10.10.123.218/hasil/', nofoto, '\" target=\"_blank\">Lihat Hasil</a>') as urlhasil"))
|
||||
->leftJoin('periksa', 'db_komponenjawaban.accnumber', 'periksa.nofoto')
|
||||
->whereIn('db_komponenjawaban.komponen', ['id_bakteri01', 'id_bakteri02', 'bakteri'])
|
||||
->where('db_komponenjawaban.isidata', '!=', '')
|
||||
->where('periksa.daftar', 'LIKE', $tahun.'-'.$bulan.'-%')->orderBy('periksa.id', 'DESC')->get();
|
||||
}
|
||||
echo json_encode($lists);
|
||||
|
||||
@@ -10,6 +10,7 @@ use App\Subjawaban;
|
||||
use App\SiraB;
|
||||
use App\Organisms;
|
||||
use App\Periksa;
|
||||
use App\KomponenJawaban;
|
||||
use Validator;
|
||||
use Picqer\Barcode\BarcodeGeneratorPNG;
|
||||
use Session;
|
||||
@@ -343,6 +344,30 @@ class TemplateController extends Controller
|
||||
return response()->json(['icon' => 'error', 'warna' => '#bf441d', 'status' => 'Failed', 'message' => 'Unkown Error']);
|
||||
return back();
|
||||
}
|
||||
} else if ($tabel == 'BioRepository'){
|
||||
$kategorisimpan = $request->kategorisimpan;
|
||||
$shelfnomor = $request->shelfnomor;
|
||||
$raknomor = $request->raknomor;
|
||||
$slotnomor = $request->slotnomor;
|
||||
$boxnomor = $request->boxnomor;
|
||||
$tubenomor = $request->tubenomor;
|
||||
$nomor = $kategorisimpan.''.$shelfnomor.''.$raknomor.''.$slotnomor.''.$boxnomor.'-'.$tubenomor;
|
||||
$data = KomponenJawaban::where('id', $id)->update([
|
||||
'isidata' => $request->nmbakteri,
|
||||
'nobiorepository' => $nomor,
|
||||
'strain' => $request->strain,
|
||||
'atcc' => $request->atcc,
|
||||
'sample' => $request->nmbakteri,
|
||||
'tglpenyimpanan' => $request->tglpenyimpanan,
|
||||
'created_by' => $request->created_by
|
||||
]);
|
||||
if ($data){
|
||||
return response()->json(['icon' => 'success', 'warna' => '#5ba035', 'status' => 'Success', 'message' => 'Saved']);
|
||||
return back();
|
||||
} else {
|
||||
return response()->json(['icon' => 'error', 'warna' => '#bf441d', 'status' => 'Failed', 'message' => 'Unkown Error']);
|
||||
return back();
|
||||
}
|
||||
} else {
|
||||
if ($id == 'new'){
|
||||
$data = new SiraB;
|
||||
|
||||
Reference in New Issue
Block a user