mirror of
https://github.com/0xJacky/nginx-ui.git
synced 2025-05-11 02:15:48 +02:00
enhance(cosy): permanently delete
This commit is contained in:
parent
6d5f34751d
commit
5a19133254
2 changed files with 3 additions and 4 deletions
|
@ -6,9 +6,9 @@ import (
|
||||||
"net/http"
|
"net/http"
|
||||||
)
|
)
|
||||||
|
|
||||||
func (c *Ctx[T]) PermanentlyDelete() *Ctx[T] {
|
func (c *Ctx[T]) PermanentlyDelete() {
|
||||||
c.permanentlyDelete = true
|
c.permanentlyDelete = true
|
||||||
return c
|
c.Destroy()
|
||||||
}
|
}
|
||||||
|
|
||||||
func (c *Ctx[T]) Destroy() {
|
func (c *Ctx[T]) Destroy() {
|
||||||
|
|
|
@ -31,8 +31,7 @@ func GetList(c *gin.Context) {
|
||||||
|
|
||||||
func Destroy(c *gin.Context) {
|
func Destroy(c *gin.Context) {
|
||||||
cosy.Core[model.Notification](c).
|
cosy.Core[model.Notification](c).
|
||||||
PermanentlyDelete().
|
PermanentlyDelete()
|
||||||
Destroy()
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func DestroyAll(c *gin.Context) {
|
func DestroyAll(c *gin.Context) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue