Skip to content

Commit

Permalink
Penyesuaian slug tidak berubah ketika di edit pada kategori komplain (#…
Browse files Browse the repository at this point in the history
…722)

* Penyesuaian slug tidak berubah ketika di edit pada kategori komplain

* Fix styling

* [ci skip] memutahirkan catatan rilis

---------

Co-authored-by: yogiperdana <[email protected]>
Co-authored-by: vickyrolanda <[email protected]>
  • Loading branch information
3 people authored Jun 29, 2023
1 parent aa18ec7 commit f2618ef
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,6 @@ public function store(Request $request)

try {
$kategori = new KategoriKomplain($request->all());
$kategori->slug = str_slug($kategori->nama);
$kategori->save();
} catch (\Exception $e) {
report($e);
Expand Down
17 changes: 17 additions & 0 deletions app/Models/KategoriKomplain.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,30 @@

namespace App\Models;

use Cviebrock\EloquentSluggable\Sluggable;
use Illuminate\Database\Eloquent\Model;

class KategoriKomplain extends Model
{
use Sluggable;

protected $table = 'das_kategori_komplain';

protected $fillable = [
'nama'
];

/**
* Return the sluggable configuration array for this model.
*
* @return array
*/
public function sluggable(): array
{
return [
'slug' => [
'source' => 'nama',
],
];
}
}
1 change: 1 addition & 0 deletions catatan_rilis.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ Di rilis v2306.0.0 berisi perbaikan yang diminta Komunitas OpenDK.
2. [#503](https://github.com/OpenSID/OpenDK/issues/503) Perbaikan fitur keluhan web dan admin.
3. [#714](https://github.com/OpenSID/OpenDK/issues/714) Perbaikan gambar image not found tidak muncul ketika tidak ada gambar pada modul potensi.
4. [#708](https://github.com/OpenSID/OpenDK/issues/708) Perbaikan validasi client-side pada form dokumen.
5. [#710](https://github.com/OpenSID/OpenDK/issues/710) Perbaikan slug tidak berubah ketika di edit pada kategori komplain.

#### Teknis

Expand Down

0 comments on commit f2618ef

Please sign in to comment.