m3 Security Fixes
This commit is contained in:
@@ -35,15 +35,15 @@ class M3DeliveryController extends Controller
|
||||
//
|
||||
public static function saveM3DeliveryAdd(Request $request) {
|
||||
|
||||
$icm664m=DB::connection(config('m3.connection', 'pgsql'))->select("select count(*) as COUNT1 from ICM664M
|
||||
$icm664m=DB::connection(config('m3.connection', 'pgsql'))->select("select count(*) as COUNT1 from ICM664M
|
||||
where AVCO='$request->AVCO' and AVWHS='$request->AVWHS' and AVPLANT='$request->AVPLANT' and AVDELMETH='$request->AVDELMETH'");
|
||||
if($icm664m[0]->COUNT1=="1") {
|
||||
return "exists";
|
||||
} else {
|
||||
|
||||
DB::connection(config('m3.connection', 'pgsql'))->insert("insert into ICM664M
|
||||
(AVCO, AVPLANT, AVWHS, AVDELMETH, AVSHPVIA, AVSHSRT, AVSHORCL)
|
||||
values ('$request->AVCO', '$request->AVPLANT', '$request->AVWHS', '$request->AVDELMETH',
|
||||
DB::connection(config('m3.connection', 'pgsql'))->insert("insert into ICM664M
|
||||
(AVCO, AVPLANT, AVWHS, AVDELMETH, AVSHPVIA, AVSHSRT, AVSHORCL)
|
||||
values ('$request->AVCO', '$request->AVPLANT', '$request->AVWHS', '$request->AVDELMETH',
|
||||
'$request->AVSHPVIA', '$request->AVSHSRT', '$request->AVSHORCL')");
|
||||
return "success";
|
||||
|
||||
@@ -56,11 +56,11 @@ class M3DeliveryController extends Controller
|
||||
public static function saveM3DeliveryEdit(Request $request) {
|
||||
#dd($request);
|
||||
// Update record to ICM664M
|
||||
|
||||
DB::connection(config('m3.connection', 'pgsql'))->update("update ICM664M
|
||||
|
||||
DB::connection(config('m3.connection', 'pgsql'))->update("update ICM664M
|
||||
set AVSHPVIA='$request->AVSHPVIA', AVSHSRT='$request->AVSHSRT', AVSHORCL='$request->AVSHORCL'
|
||||
where AVCO='$request->AVCO' and AVPLANT='$request->AVPLANT' and AVWHS='$request->AVWHS' and AVDELMETH='$request->AVDELMETH'");
|
||||
|
||||
|
||||
return "success";
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user