[WIP] Изменил инпуты для даты и ограничил вводимые значения; при наведении на аватар клиента, появляется иконка загрузки

This commit is contained in:
megavrilinvv
2022-11-30 18:39:11 +03:00
parent a66081c14d
commit 766e1be22c
12 changed files with 31 additions and 46 deletions

View File

@@ -4,7 +4,6 @@
:is-open-form="isOpenForm",
:close-form="closeForm",
:open-form="openForm",
:current-year="currentYear",
@update-client="setUpdatedClients"
)
.flex.flex-auto
@@ -12,7 +11,6 @@
router-view(
:open-form="openForm",
:is-open-form="isOpenForm",
:current-year="currentYear",
:updated-clients="updatedClients",
@reset-updated-clients="resetUpdatedClients"
)
@@ -30,7 +28,6 @@ export default {
data() {
return {
isOpenForm: false,
currentYear: null,
updatedClients: false,
};
},
@@ -41,9 +38,6 @@ export default {
closeForm() {
this.isOpenForm = false;
},
printCurrentYear() {
return new Date().getFullYear();
},
setUpdatedClients() {
this.updatedClients = true;
},
@@ -51,8 +45,5 @@ export default {
this.updatedClients = false;
},
},
mounted: function () {
this.currentYear = this.printCurrentYear();
},
};
</script>

View File

@@ -3,7 +3,6 @@
base-client-form-create(
v-if="isOpenForm",
:close-form="closeForm",
:current-year="currentYear",
@update-client="transmitUpdateClient"
)
.flex.items-center.box-border.cursor-pointer.mr-auto
@@ -43,7 +42,6 @@ export default {
openForm: Function,
closeForm: Function,
isOpenForm: Boolean,
currentYear: Number,
},
data() {
return {

View File

@@ -12,7 +12,7 @@
v-for="img in image"
)
.icon-download.text-xl(v-if="img === defaultIcon")
.flex.w-10.h-10(v-else)
.wrapper-img.flex.w-10.h-10(v-else)
img.current-avatar(:src="img")
base-popup.right-5.top-7(v-if="showPopup", :width="230")
.flex.items-center.gap-x-2
@@ -56,13 +56,11 @@
:choose-option="chooseOptionNetworks"
:choose-priority="choosePriority"
:priority-list="priorityList"
:current-year="currentYear"
)
)
.flex(:style="{display :'none'}" ref="doc")
form-create-identity-documents(
:identity-document="infoClient.identity_document",
:save-client="saveClient",
:current-year="currentYear"
:save-client="saveClient"
)
.flex(:style="{display :'none'}" ref="address")
form-create-addresses(
@@ -106,7 +104,6 @@ export default {
},
props: {
closeForm: Function,
currentYear: Number,
},
data() {
return {
@@ -429,4 +426,12 @@ export default {
background-size: cover
background-repeat: no-repeat
background-position: center
&:hover
display: none
.wrapper-img
background-size: 20px
background-repeat: no-repeat
background-position: center
background-image: url(@/assets/icons/download.svg)
</style>

View File

@@ -1,14 +1,16 @@
<template lang="pug">
.input-wrapper.flex.gap-x-2.px-4.box-border(
class="py-2.5"
class="py-2.5",
:style="{ minWidth: widthInput + 'px' }"
)
input.input.w-full.outline-0.not-italic.date(
:value="value"
type="date"
@input="$emit('update:value', $event.target.value)"
:placeholder="placeholder"
:maxlength="maxLength"
:value="value",
type="date",
@input="$emit('update:value', $event.target.value)",
:placeholder="placeholder",
:maxlength="maxLength",
max="9999-12-31",
min="0000-01-01"
)
.slot(v-if="withIcon" :class="iconPosition")
slot.cursor-pointer