add nombre de la lista al editar
This commit is contained in:
@@ -11,7 +11,7 @@
|
||||
lista.items?.length : '0' }}
|
||||
</q-badge>
|
||||
<div class="text-h5">{{ lista.nombre }}
|
||||
<q-icon name="edit" @click="changeNameList(lista.id)" class="cursor-pointer"
|
||||
<q-icon name="edit" @click="changeNameList(lista.id, lista.nombre)" class="cursor-pointer"
|
||||
v-if="store.user?.email === lista.email_owner" />
|
||||
</div>
|
||||
<div class="text-subtitle1">{{ lista.email_owner }}</div>
|
||||
@@ -86,14 +86,14 @@ const onLoad = (index, done) => {
|
||||
}, 1000)
|
||||
}
|
||||
|
||||
const changeNameList = async (id) => {
|
||||
const changeNameList = async (id, nombre) => {
|
||||
try {
|
||||
$q.dialog({
|
||||
title: 'Escriba',
|
||||
message: 'Nuevo nombre de la lista',
|
||||
html: true,
|
||||
prompt: {
|
||||
model: '',
|
||||
model: nombre,
|
||||
isValid: val => val.length > 4, // << here is the magic
|
||||
type: 'text'
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user