Skip to content

Commit a673a59

Browse files
committed
Merge branch 'dev' into rilis-2411.0.0
2 parents 464141d + 3e0a719 commit a673a59

3 files changed

Lines changed: 36 additions & 5 deletions

File tree

app/Http/Requests/ArtikelRequest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ public function rules()
5555
return [
5656
'judul' => 'required|string|max:191',
5757
'isi' => 'required',
58-
'kategori_id' => 'required',
58+
//'kategori_id' => 'required',
5959
'status' => 'required',
6060
'gambar' => 'nullable|image|mimes:jpg,jpeg,png|max:1024|valid_file',
6161
];
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
<?php
2+
3+
use App\Models\Kategori;
4+
use Illuminate\Database\Migrations\Migration;
5+
use Illuminate\Database\Schema\Blueprint;
6+
use Illuminate\Support\Facades\Schema;
7+
8+
return new class extends Migration
9+
{
10+
/**
11+
* Run the migrations.
12+
*
13+
* @return void
14+
*/
15+
public function up()
16+
{
17+
Schema::table('das_artikel', function (Blueprint $table) {
18+
$table->dropForeignIdFor(Kategori::class, 'kategori_id');
19+
});
20+
}
21+
22+
/**
23+
* Reverse the migrations.
24+
*
25+
* @return void
26+
*/
27+
public function down()
28+
{
29+
//
30+
}
31+
};

resources/views/informasi/artikel/_form.blade.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -50,16 +50,16 @@
5050
<span class="help-block" style="color:red">{{ $errors->first('id_kategori') }}</span>
5151
@endif
5252
</div>
53-
53+
<!--
5454
<div class="form-group">
5555
{!! Form::label('kategori_id', 'Kategori') !!}
5656
{!! Form::select('kategori_id', $kategori, null, ['class' => 'form-control', 'placeholder' => 'Pilih Kategori']) !!}
5757
5858
@if ($errors->has('kategori_id'))
59-
<span class="help-block" style="color:red">{{ $errors->first('kategori_id') }}</span>
60-
@endif
59+
<span class="help-block" style="color:red">{{ $errors->first('kategori_id') }}</span>
60+
@endif
6161
</div>
62-
62+
-->
6363
<div class="form-group">
6464
<label class="control-label" for="gambar">Status</label>
6565

0 commit comments

Comments
 (0)