add: full multi-tenancy control
This commit is contained in:
84
storage/framework/views/3d8e4f86df8051984c4e94f974a9a8eb.php
Executable file
84
storage/framework/views/3d8e4f86df8051984c4e94f974a9a8eb.php
Executable file
@@ -0,0 +1,84 @@
|
||||
<v-date-picker <?php echo e($attributes); ?>>
|
||||
<?php echo e($slot); ?>
|
||||
|
||||
</v-date-picker>
|
||||
|
||||
<?php if (! $__env->hasRenderedOnce('2f92dd00-7a3c-4eb9-9eb8-0cf97ed4ddd9')): $__env->markAsRenderedOnce('2f92dd00-7a3c-4eb9-9eb8-0cf97ed4ddd9');
|
||||
$__env->startPush('scripts'); ?>
|
||||
<script
|
||||
type="text/x-template"
|
||||
id="v-date-picker-template"
|
||||
>
|
||||
<span class="relative inline-block w-full">
|
||||
<slot></slot>
|
||||
|
||||
<i class="icon-calendar pointer-events-none absolute top-1/2 -translate-y-1/2 text-2xl text-gray-400 ltr:right-2 rtl:left-2"></i>
|
||||
</span>
|
||||
</script>
|
||||
|
||||
<script type="module">
|
||||
app.component('v-date-picker', {
|
||||
template: '#v-date-picker-template',
|
||||
|
||||
props: {
|
||||
name: String,
|
||||
|
||||
value: String,
|
||||
|
||||
allowInput: {
|
||||
type: Boolean,
|
||||
default: true,
|
||||
},
|
||||
|
||||
disable: Array,
|
||||
|
||||
minDate: String,
|
||||
|
||||
maxDate: String,
|
||||
},
|
||||
|
||||
data: function() {
|
||||
return {
|
||||
datepicker: null
|
||||
};
|
||||
},
|
||||
|
||||
mounted: function() {
|
||||
let options = this.setOptions();
|
||||
|
||||
this.activate(options);
|
||||
},
|
||||
|
||||
methods: {
|
||||
setOptions: function() {
|
||||
let self = this;
|
||||
|
||||
return {
|
||||
allowInput: this.allowInput ?? true,
|
||||
disable: this.disable ?? [],
|
||||
minDate: this.minDate ?? '',
|
||||
maxDate: this.maxDate ?? '',
|
||||
altFormat: "Y-m-d",
|
||||
dateFormat: "Y-m-d",
|
||||
weekNumbers: true,
|
||||
|
||||
onChange: function(selectedDates, dateStr, instance) {
|
||||
self.$emit("onChange", dateStr);
|
||||
}
|
||||
};
|
||||
},
|
||||
|
||||
activate: function(options) {
|
||||
let element = this.$el.getElementsByTagName("input")[0];
|
||||
|
||||
this.datepicker = new Flatpickr(element, options);
|
||||
},
|
||||
|
||||
clear: function() {
|
||||
this.datepicker.clear();
|
||||
}
|
||||
}
|
||||
});
|
||||
</script>
|
||||
<?php $__env->stopPush(); endif; ?>
|
||||
<?php /**PATH /var/www/html/packages/Webkul/Admin/src/Providers/../Resources/views/components/flat-picker/date.blade.php ENDPATH**/ ?>
|
||||
Reference in New Issue
Block a user