This commit is contained in:
parent
c727480569
commit
8d27ef5402
|
@ -107,8 +107,14 @@ watch(formUrl, async () => {
|
||||||
<QIcon name="warning" size="md" class="q-mr-md" />
|
<QIcon name="warning" size="md" class="q-mr-md" />
|
||||||
<span>{{ t('globals.changesToSave') }}</span>
|
<span>{{ t('globals.changesToSave') }}</span>
|
||||||
</QBanner>
|
</QBanner>
|
||||||
<QForm v-if="formData" @submit="save" @reset="reset" class="q-pa-md">
|
<QForm v-if="formData" @submit="save" @reset="reset" class="q-pa-md formModel">
|
||||||
<slot name="form" :data="formData" :validate="validate" :filter="filter"></slot>
|
<QCard class="q-pa-lg">
|
||||||
|
<slot
|
||||||
|
name="form"
|
||||||
|
:data="formData"
|
||||||
|
:validate="validate"
|
||||||
|
:filter="filter"
|
||||||
|
></slot>
|
||||||
<div class="q-mt-lg">
|
<div class="q-mt-lg">
|
||||||
<slot name="actions">
|
<slot name="actions">
|
||||||
<QBtn :label="t('globals.save')" type="submit" color="primary" />
|
<QBtn :label="t('globals.save')" type="submit" color="primary" />
|
||||||
|
@ -122,6 +128,7 @@ watch(formUrl, async () => {
|
||||||
/>
|
/>
|
||||||
</slot>
|
</slot>
|
||||||
</div>
|
</div>
|
||||||
|
</QCard>
|
||||||
</QForm>
|
</QForm>
|
||||||
<SkeletonForm v-if="!formData" />
|
<SkeletonForm v-if="!formData" />
|
||||||
<QInnerLoading
|
<QInnerLoading
|
||||||
|
@ -130,3 +137,16 @@ watch(formUrl, async () => {
|
||||||
color="primary"
|
color="primary"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
<style lang="scss">
|
||||||
|
@media screen and (max-width: 800px) {
|
||||||
|
.q-card > div {
|
||||||
|
flex-direction: column;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.formModel {
|
||||||
|
max-width: 800px;
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
|
@ -14,12 +14,6 @@ a {
|
||||||
color: $orange-4;
|
color: $orange-4;
|
||||||
}
|
}
|
||||||
|
|
||||||
@media screen and (max-width: $width-md) {
|
|
||||||
.q-form > div {
|
|
||||||
flex-direction: column;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Removes chrome autofill background
|
// Removes chrome autofill background
|
||||||
input:-webkit-autofill,
|
input:-webkit-autofill,
|
||||||
select:-webkit-autofill {
|
select:-webkit-autofill {
|
||||||
|
|
|
@ -48,12 +48,4 @@ $dark: #292929;
|
||||||
$layout-shadow-dark: 0 0 10px 2px rgba(0, 0, 0, 0.2), 0 0px 10px rgba(0, 0, 0, 0.24);
|
$layout-shadow-dark: 0 0 10px 2px rgba(0, 0, 0, 0.2), 0 0px 10px rgba(0, 0, 0, 0.24);
|
||||||
$spacing-md: 16px;
|
$spacing-md: 16px;
|
||||||
|
|
||||||
// Width from Salix variables.scss
|
|
||||||
|
|
||||||
$width-xs: 400px;
|
|
||||||
$width-sm: 544px;
|
|
||||||
$width-md: 800px;
|
|
||||||
$width-lg: 1280px;
|
|
||||||
$width-xl: 1600px;
|
|
||||||
|
|
||||||
$width-full: 100%;
|
$width-full: 100%;
|
||||||
|
|
|
@ -92,7 +92,6 @@ const statesFilter = {
|
||||||
<FetchData url="ClaimStates" @on-fetch="setClaimStates" auto-load />
|
<FetchData url="ClaimStates" @on-fetch="setClaimStates" auto-load />
|
||||||
|
|
||||||
<div class="column items-center">
|
<div class="column items-center">
|
||||||
<QCard>
|
|
||||||
<FormModel
|
<FormModel
|
||||||
:url="`Claims/${route.params.id}`"
|
:url="`Claims/${route.params.id}`"
|
||||||
:url-update="`Claims/updateClaim/${route.params.id}`"
|
:url-update="`Claims/updateClaim/${route.params.id}`"
|
||||||
|
@ -122,10 +121,7 @@ const statesFilter = {
|
||||||
transition-show="scale"
|
transition-show="scale"
|
||||||
transition-hide="scale"
|
transition-hide="scale"
|
||||||
>
|
>
|
||||||
<QDate
|
<QDate v-model="data.created" mask="YYYY-MM-DD">
|
||||||
v-model="data.created"
|
|
||||||
mask="YYYY-MM-DD"
|
|
||||||
>
|
|
||||||
<div class="row items-center justify-end">
|
<div class="row items-center justify-end">
|
||||||
<QBtn
|
<QBtn
|
||||||
v-close-popup
|
v-close-popup
|
||||||
|
@ -215,6 +211,5 @@ const statesFilter = {
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
</FormModel>
|
</FormModel>
|
||||||
</QCard>
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
|
@ -59,7 +59,6 @@ const filterOptions = {
|
||||||
auto-load
|
auto-load
|
||||||
/>
|
/>
|
||||||
<div class="column items-center">
|
<div class="column items-center">
|
||||||
<QCard>
|
|
||||||
<FormModel :url="`Clients/${route.params.id}`" model="customer">
|
<FormModel :url="`Clients/${route.params.id}`" model="customer">
|
||||||
<template #form="{ data, validate, filter }">
|
<template #form="{ data, validate, filter }">
|
||||||
<div class="row q-gutter-md q-mb-md">
|
<div class="row q-gutter-md q-mb-md">
|
||||||
|
@ -134,8 +133,7 @@ const filterOptions = {
|
||||||
map-options
|
map-options
|
||||||
use-input
|
use-input
|
||||||
@filter="
|
@filter="
|
||||||
(value, update) =>
|
(value, update) => filter(value, update, filterOptions)
|
||||||
filter(value, update, filterOptions)
|
|
||||||
"
|
"
|
||||||
:rules="validate('client.salesPersonFk')"
|
:rules="validate('client.salesPersonFk')"
|
||||||
:input-debounce="0"
|
:input-debounce="0"
|
||||||
|
@ -167,13 +165,5 @@ const filterOptions = {
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
</FormModel>
|
</FormModel>
|
||||||
</QCard>
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
|
||||||
.q-card {
|
|
||||||
width: $width-full;
|
|
||||||
max-width: $width-md;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
Loading…
Reference in New Issue