feat: add shortcut add event in some subSections
gitea/salix-front/pipeline/pr-dev This commit looks good Details

This commit is contained in:
Javier Segarra 2024-09-18 13:30:51 +02:00
parent cba8647ac2
commit 37329a7391
7 changed files with 36 additions and 31 deletions

View File

@ -56,17 +56,18 @@ const customerContactsRef = ref(null);
</div> </div>
</VnRow> </VnRow>
<VnRow> <VnRow>
<QIcon <QBtn
@click="customerContactsRef.insert()" @click="customerContactsRef.insert()"
class="cursor-pointer" class="cursor-pointer"
color="primary" color="primary"
name="add" flat
size="sm" icon="add"
shortcut="+"
> >
<QTooltip> <QTooltip>
{{ t('Add contact') }} {{ t('Add contact') }}
</QTooltip> </QTooltip>
</QIcon> </QBtn>
</VnRow> </VnRow>
</QCard> </QCard>
</template> </template>

View File

@ -272,16 +272,17 @@ function handleLocation(data, location) {
</div> </div>
</VnRow> </VnRow>
<QIcon <QBtn
@click.stop="addNote()" @click.stop="addNote()"
class="cursor-pointer add-icon q-mt-md" class="cursor-pointer add-icon q-mt-md"
name="add" flat
size="sm" icon="add"
shortcut="+"
> >
<QTooltip> <QTooltip>
{{ t('Add note') }} {{ t('Add note') }}
</QTooltip> </QTooltip>
</QIcon> </QBtn>
</template> </template>
</FormModel> </FormModel>
</template> </template>

View File

@ -168,19 +168,20 @@ const insertTag = (rows) => {
</div> </div>
</VnRow> </VnRow>
<VnRow class="justify-center items-center"> <VnRow class="justify-center items-center">
<QIcon <QBtn
@click="insertTag(rows)" @click="insertTag(rows)"
class="cursor-pointer" class="cursor-pointer"
:disable="!validRow" :disable="!validRow"
color="primary" color="primary"
name="add" flat
size="sm" icon="add"
shortcut="+"
style="flex: 0" style="flex: 0"
> >
<QTooltip> <QTooltip>
{{ t('itemTags.addTag') }} {{ t('itemTags.addTag') }}
</QTooltip> </QTooltip>
</QIcon> </QBtn>
</VnRow> </VnRow>
</QCard> </QCard>
</template> </template>

View File

@ -65,9 +65,10 @@ const updateDefaultStop = (data) => {
</div> </div>
</QCardSection> </QCardSection>
<QCardSection> <QCardSection>
<QIcon <QBtn
name="add" flat
size="sm" icon="add"
shortcut="+"
class="cursor-pointer" class="cursor-pointer"
color="primary" color="primary"
@click="roadmapStopsCrudRef.insert()" @click="roadmapStopsCrudRef.insert()"
@ -75,7 +76,7 @@ const updateDefaultStop = (data) => {
<QTooltip> <QTooltip>
{{ t('Add stop') }} {{ t('Add stop') }}
</QTooltip> </QTooltip>
</QIcon> </QBtn>
</QCardSection> </QCardSection>
</QCard> </QCard>
</template> </template>

View File

@ -102,9 +102,7 @@ const setWireTransfer = async () => {
<VnInput :label="t('supplier.accounts.iban')" v-model="row.iban"> <VnInput :label="t('supplier.accounts.iban')" v-model="row.iban">
<template #append> <template #append>
<QIcon name="info" class="cursor-info"> <QIcon name="info" class="cursor-info">
<QTooltip>{{ <QTooltip>{{ t('components.iban_tooltip') }}</QTooltip>
t('components.iban_tooltip')
}}</QTooltip>
</QIcon> </QIcon>
</template> </template>
</VnInput> </VnInput>
@ -165,9 +163,10 @@ const setWireTransfer = async () => {
</div> </div>
</VnRow> </VnRow>
<VnRow> <VnRow>
<QIcon <QBtn
name="add" flat
size="sm" icon="add"
shortcut="+"
class="cursor-pointer" class="cursor-pointer"
color="primary" color="primary"
@click="supplierAccountRef.insert()" @click="supplierAccountRef.insert()"
@ -175,7 +174,7 @@ const setWireTransfer = async () => {
<QTooltip> <QTooltip>
{{ t('Add account') }} {{ t('Add account') }}
</QTooltip> </QTooltip>
</QIcon> </QBtn>
</VnRow> </VnRow>
</QCard> </QCard>
</template> </template>

View File

@ -84,9 +84,10 @@ const insertRow = () => {
</VnRow> </VnRow>
</QCardSection> </QCardSection>
<VnRow> <VnRow>
<QIcon <QBtn
name="add" flat
size="sm" icon="add"
shortcut="+"
class="cursor-pointer" class="cursor-pointer"
color="primary" color="primary"
@click="insertRow()" @click="insertRow()"
@ -94,7 +95,7 @@ const insertRow = () => {
<QTooltip> <QTooltip>
{{ t('Add contact') }} {{ t('Add contact') }}
</QTooltip> </QTooltip>
</QIcon> </QBtn>
</VnRow> </VnRow>
</QCard> </QCard>
</template> </template>

View File

@ -180,17 +180,18 @@ function handleEvent(type, event, node) {
{{ t('Remove') }} {{ t('Remove') }}
</QTooltip> </QTooltip>
</QIcon> </QIcon>
<QIcon <QBtn
name="add"
color="primary" color="primary"
size="sm" flat
icon="add"
shortcut="+"
class="cursor-pointer" class="cursor-pointer"
@click.stop="showCreateNodeForm(node.id)" @click.stop="showCreateNodeForm(node.id)"
> >
<QTooltip> <QTooltip>
{{ t('Create') }} {{ t('Create') }}
</QTooltip> </QTooltip>
</QIcon> </QBtn>
</div> </div>
</div> </div>
</template> </template>