WIP Начала делать выборку года
This commit is contained in:
@@ -69,7 +69,7 @@
|
||||
|
||||
<script>
|
||||
import BaseInput from "@/components/base/BaseInput";
|
||||
import BaseCalendar from "@/components/base/BaseCalendar";
|
||||
import BaseCalendar from "@/components/base/Calendar/BaseCalendar.vue";
|
||||
import { mapState, mapActions } from "vuex";
|
||||
import { v_model } from "@/shared/mixins/v-model";
|
||||
export default {
|
||||
@@ -119,23 +119,21 @@ export default {
|
||||
}),
|
||||
saveNewDate() {
|
||||
this.calendarVisibility = false;
|
||||
if (
|
||||
!this.date?.from.isSame(this.selectedDates?.from) &&
|
||||
!this.date?.to.isSame(this.selectedDates?.to)
|
||||
)
|
||||
this.changeSelectedDates(this.date);
|
||||
},
|
||||
cancelDateChanges() {
|
||||
this.calendarVisibility = false;
|
||||
},
|
||||
},
|
||||
watch: {
|
||||
calendarVisibility(val) {
|
||||
if (val === false)
|
||||
this.date = {
|
||||
from: this.selectedDates.from.clone(),
|
||||
to: this.selectedDates.to.clone(),
|
||||
};
|
||||
date: {
|
||||
deep: true,
|
||||
handler(val) {
|
||||
if (
|
||||
!this.val?.from.isSame(this.selectedDates?.from) &&
|
||||
!this.val?.to.isSame(this.selectedDates?.to)
|
||||
)
|
||||
this.changeSelectedDates(val);
|
||||
},
|
||||
},
|
||||
},
|
||||
mounted() {
|
||||
|
||||
Reference in New Issue
Block a user