fix: refs #7187 fix div
gitea/salix-front/pipeline/pr-test This commit looks good Details

This commit is contained in:
Pablo Natek 2024-05-23 14:24:58 +02:00
parent d2d80645d0
commit 410012df55
2 changed files with 21 additions and 36 deletions

View File

@ -71,7 +71,7 @@ function reloadData() {
bordered bordered
:key="row.id" :key="row.id"
v-for="row of rows" v-for="row of rows"
class="card q-px-md q-mb-sm" class="card q-px-md q-mb-sm container"
> >
<VnRow> <VnRow>
<VnInput <VnInput
@ -94,26 +94,23 @@ function reloadData() {
:model-value="row?.simSerialNumber" :model-value="row?.simSerialNumber"
disable disable
/> />
<QBtn
<div class="icon"> flat
<QIcon icon="delete"
name="delete" color="primary"
size="sm" class="btn-delete"
color="primary" @click="
class="cursor-pointer" openConfirmationModal(
@click=" t(`Remove PDA`),
openConfirmationModal( t('Do you want to remove this PDA?'),
t(`Remove PDA`), () => deallocatePDA(row.deviceProductionFk)
t('Do you want to remove this PDA?'), )
() => deallocatePDA(row.deviceProductionFk) "
) >
" <QTooltip>
> {{ t('worker.pda.removePDA') }}
<QTooltip> </QTooltip>
{{ t('worker.pda.removePDA') }} </QBtn>
</QTooltip>
</QIcon>
</div>
</VnRow> </VnRow>
</QCard> </QCard>
</template> </template>
@ -171,12 +168,9 @@ function reloadData() {
</QPage> </QPage>
</template> </template>
<style lang="scss" scoped> <style lang="scss" scoped>
.icon { .btn-delete {
display: flex;
justify-content: center;
align-items: center;
margin-top: 2%;
max-width: 4%; max-width: 4%;
margin-top: 30px;
} }
</style> </style>
<i18n> <i18n>

View File

@ -14,17 +14,8 @@ describe('WorkerPda', () => {
cy.get('.q-notification__message').should('have.text', 'Data created'); cy.get('.q-notification__message').should('have.text', 'Data created');
}); });
it('assign more than 1 pda', () => {
cy.get('.q-page-sticky > div > .q-btn > .q-btn__content > .q-icon').click();
cy.get(deviceProductionField).type('{downArrow}{enter}');
cy.get('.vn-row > #simSerialNumber').type('123{enter}');
cy.get(
':nth-child(1) > .q-notification__wrapper > .q-notification__content > .q-notification__message'
).should('have.text', 'You can only have one PDA');
});
it('delete pda', () => { it('delete pda', () => {
cy.get('.icon > .q-icon').click(); cy.get('.btn-delete').click();
cy.get( cy.get(
'.q-card__actions > .q-btn--unelevated > .q-btn__content > .block' '.q-card__actions > .q-btn--unelevated > .q-btn__content > .block'
).click(); ).click();