pada Feature Registrasi, menambahkan inputan Catatan Opsional saat tindakan Yes
This commit is contained in:
@@ -167,6 +167,8 @@
|
|||||||
$dataku['jenis_penilaian_id'] =$request->jenis_penilaian;
|
$dataku['jenis_penilaian_id'] =$request->jenis_penilaian;
|
||||||
$dataku['region_id'] =$request->region;
|
$dataku['region_id'] =$request->region;
|
||||||
$dataku['status'] = 'registered';
|
$dataku['status'] = 'registered';
|
||||||
|
if($request->catatan2)
|
||||||
|
$dataku['registrasi_catatan'] =$request->catatan2;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -81,6 +81,15 @@
|
|||||||
<option></option>
|
<option></option>
|
||||||
</select>
|
</select>
|
||||||
<em id="{{$route[0]}}_region_msg" class="alert text-danger text-sm"></em>
|
<em id="{{$route[0]}}_region_msg" class="alert text-danger text-sm"></em>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div id="{{ $route[0] }}_div_catatan2" class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||||
|
<label class="form-label max-w-56">
|
||||||
|
Catatan
|
||||||
|
</label>
|
||||||
|
<div class="flex flex-wrap items-baseline w-full">
|
||||||
|
<textarea class="inputku textarea" name="{{$route[0]}}_catatan2" id="{{$route[0]}}_catatan2" placeholder="Catatan..." rows="6"></textarea>
|
||||||
|
<em id="{{$route[0]}}_catatan2_msg" class="alert text-danger text-sm"></em>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="flex justify-end">
|
<div class="flex justify-end">
|
||||||
|
|||||||
@@ -13,6 +13,7 @@
|
|||||||
$("#{{ $route[0] }}_div_jenis_pilihan").show();
|
$("#{{ $route[0] }}_div_jenis_pilihan").show();
|
||||||
$("#{{ $route[0] }}_div_catatan").hide();
|
$("#{{ $route[0] }}_div_catatan").hide();
|
||||||
$("#{{ $route[0] }}_div_region").hide();
|
$("#{{ $route[0] }}_div_region").hide();
|
||||||
|
$("#{{ $route[0] }}_div_catatan2").show();
|
||||||
// prepare data
|
// prepare data
|
||||||
setData();
|
setData();
|
||||||
}
|
}
|
||||||
@@ -94,12 +95,14 @@
|
|||||||
$("#{{ $route[0] }}_div_jenis_pilihan").show();
|
$("#{{ $route[0] }}_div_jenis_pilihan").show();
|
||||||
$("#{{ $route[0] }}_catatan").val('');
|
$("#{{ $route[0] }}_catatan").val('');
|
||||||
$("#{{ $route[0] }}_div_catatan").hide();
|
$("#{{ $route[0] }}_div_catatan").hide();
|
||||||
|
$("#{{ $route[0] }}_div_catatan2").show();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
$("#{{$route[0]}}_jenis_penilaian option[value=0]").prop('selected', true);
|
$("#{{$route[0]}}_jenis_penilaian option[value=0]").prop('selected', true);
|
||||||
$("#{{ $route[0] }}_div_jenis_pilihan").hide();
|
$("#{{ $route[0] }}_div_jenis_pilihan").hide();
|
||||||
$("#{{ $route[0] }}_div_catatan").show();
|
$("#{{ $route[0] }}_div_catatan").show();
|
||||||
|
$("#{{ $route[0] }}_div_catatan2").hide();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -115,6 +118,7 @@
|
|||||||
let jenis_penilaian = $("#{{$route[0]}}_jenis_penilaian").val();
|
let jenis_penilaian = $("#{{$route[0]}}_jenis_penilaian").val();
|
||||||
let region = $("#{{$route[0]}}_region").val();
|
let region = $("#{{$route[0]}}_region").val();
|
||||||
let catatan = $("#{{$route[0]}}_catatan").val();
|
let catatan = $("#{{$route[0]}}_catatan").val();
|
||||||
|
let catatan2 = $("#{{$route[0]}}_catatan2").val();
|
||||||
|
|
||||||
if(jenis_penilaian==0)
|
if(jenis_penilaian==0)
|
||||||
jenis_penilaian='';
|
jenis_penilaian='';
|
||||||
@@ -129,6 +133,7 @@
|
|||||||
input_data.jenis_penilaian= jenis_penilaian;
|
input_data.jenis_penilaian= jenis_penilaian;
|
||||||
input_data.region= region;
|
input_data.region= region;
|
||||||
input_data.catatan = catatan;
|
input_data.catatan = catatan;
|
||||||
|
input_data.catatan2 = catatan2;
|
||||||
|
|
||||||
let useURL= '{{ route($route[0].'.update', $id) }}';
|
let useURL= '{{ route($route[0].'.update', $id) }}';
|
||||||
$.ajax({
|
$.ajax({
|
||||||
|
|||||||
@@ -199,7 +199,7 @@
|
|||||||
<em id="{{$route[0]}}_catatan_msg" class="alert text-danger text-sm"></em>
|
<em id="{{$route[0]}}_catatan_msg" class="alert text-danger text-sm"></em>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div id="{{ $route[0] }}_div_region" class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5 mt-5">
|
<div id="{{ $route[0] }}_div_region" class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||||
<label class="form-label max-w-56">
|
<label class="form-label max-w-56">
|
||||||
Region
|
Region
|
||||||
</label>
|
</label>
|
||||||
@@ -208,6 +208,15 @@
|
|||||||
<option></option>
|
<option></option>
|
||||||
</select>
|
</select>
|
||||||
<em id="{{$route[0]}}_region_msg" class="alert text-danger text-sm"></em>
|
<em id="{{$route[0]}}_region_msg" class="alert text-danger text-sm"></em>
|
||||||
|
</div>
|
||||||
|
</div><br />
|
||||||
|
<div id="{{ $route[0] }}_div_catatan2" class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||||
|
<label class="form-label max-w-56">
|
||||||
|
Catatan
|
||||||
|
</label>
|
||||||
|
<div class="flex flex-wrap items-baseline w-full">
|
||||||
|
<textarea class="inputku textarea" name="{{$route[0]}}_catatan2" id="{{$route[0]}}_catatan2" placeholder="Catatan..." rows="6"></textarea>
|
||||||
|
<em id="{{$route[0]}}_catatan2_msg" class="alert text-danger text-sm"></em>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="flex justify-end mt-5">
|
<div class="flex justify-end mt-5">
|
||||||
|
|||||||
Reference in New Issue
Block a user