remove datepicker
parent
49becff008
commit
7cb56577fb
|
|
@ -304,14 +304,14 @@ class CarController extends Controller
|
|||
|
||||
public function store(Request $request)
|
||||
{
|
||||
$request->validate($this->getValidationRules());
|
||||
|
||||
$request->merge([
|
||||
'initial_date' => Carbon::parse($request->get('initial_date'))->format('Y-m-d'),
|
||||
'last_check_date' => Carbon::parse($request->get('last_check_date'))->format('Y-m-d'),
|
||||
]);
|
||||
|
||||
$car = Car::create(
|
||||
$request->validate($this->getValidationRules())
|
||||
);
|
||||
$car = Car::create($request->all());
|
||||
|
||||
session()->flash('flash.banner', 'Auto erstellt.');
|
||||
return Redirect::route('cars.show', $car);
|
||||
|
|
@ -319,15 +319,21 @@ class CarController extends Controller
|
|||
|
||||
public function storeForContract(Request $request)
|
||||
{
|
||||
$car = Car::create(
|
||||
$request->validate($this->getValidationRules())
|
||||
);
|
||||
$request->validate($this->getValidationRules());
|
||||
|
||||
$request->merge([
|
||||
'initial_date' => Carbon::parse($request->get('initial_date'))->format('Y-m-d'),
|
||||
'last_check_date' => Carbon::parse($request->get('last_check_date'))->format('Y-m-d'),
|
||||
]);
|
||||
|
||||
$car = Car::create($request->all());
|
||||
|
||||
return response()->json([
|
||||
'id' => $car->id,
|
||||
'stammnummer' => $car->stammnummer,
|
||||
'vin' => $car->vin,
|
||||
'name' => $car->name,
|
||||
'label' => $car->name . ' (' . $car->stammnummer . ')',
|
||||
'colour' => $car->colour,
|
||||
'last_check_date' => $car->last_check_date_formatted,
|
||||
'kilometers' => $car->kilometers,
|
||||
|
|
@ -340,8 +346,8 @@ class CarController extends Controller
|
|||
return [
|
||||
'stammnummer' => ['required', 'unique:cars', 'string', 'size:11', 'regex:/[0-9]{3}[.][0-9]{3}[.][0-9]{3}/i'],
|
||||
'vin' => ['required', 'unique:cars', 'string', 'size:17'],
|
||||
'initial_date' => ['required', 'date'],
|
||||
'last_check_date' => ['required', 'date'],
|
||||
'initial_date' => ['required', 'date_format:"d.m.Y"'],
|
||||
'last_check_date' => ['required', 'date_format:"d.m.Y"'],
|
||||
'colour' => ['nullable', 'max:75'],
|
||||
'car_model_id' => ['required', 'exists:App\Models\CarModel,id'],
|
||||
'kilometers' => ['required', 'max:75'],
|
||||
|
|
@ -417,24 +423,24 @@ class CarController extends Controller
|
|||
|
||||
public function update(Request $request, Car $car)
|
||||
{
|
||||
$request->validate([
|
||||
'stammnummer' => ['required', 'unique:cars,stammnummer,' . $car->id, 'string', 'size:11', 'regex:/[0-9]{3}[.][0-9]{3}[.][0-9]{3}/i'],
|
||||
'vin' => ['required', 'unique:cars,vin,' . $car->id, 'string', 'size:17'],
|
||||
'initial_date' => ['required', 'date_format:"d.m.Y"'],
|
||||
'last_check_date' => ['required', 'date_format:"d.m.Y"'],
|
||||
'colour' => ['nullable', 'max:75'],
|
||||
'car_model_id' => ['required', 'exists:App\Models\CarModel,id'],
|
||||
'kilometers' => ['required', 'max:75'],
|
||||
'known_damage' => ['nullable'],
|
||||
'notes' => ['nullable'],
|
||||
]);
|
||||
|
||||
$request->merge([
|
||||
'initial_date' => Carbon::parse($request->get('initial_date'))->format('Y-m-d'),
|
||||
'last_check_date' => Carbon::parse($request->get('last_check_date'))->format('Y-m-d'),
|
||||
]);
|
||||
|
||||
$car->update(
|
||||
$request->validate([
|
||||
'stammnummer' => ['required', 'unique:cars,stammnummer,' . $car->id, 'string', 'size:11', 'regex:/[0-9]{3}[.][0-9]{3}[.][0-9]{3}/i'],
|
||||
'vin' => ['required', 'unique:cars,vin,' . $car->id, 'string', 'size:17'],
|
||||
'initial_date' => ['required', 'date'],
|
||||
'last_check_date' => ['required', 'date'],
|
||||
'colour' => ['nullable', 'max:75'],
|
||||
'car_model_id' => ['required', 'exists:App\Models\CarModel,id'],
|
||||
'kilometers' => ['required', 'max:75'],
|
||||
'known_damage' => ['nullable'],
|
||||
'notes' => ['nullable'],
|
||||
])
|
||||
);
|
||||
$car->update($request->all());
|
||||
|
||||
session()->flash('flash.banner', 'Auto geändert.');
|
||||
return Redirect::route('cars.show', $car);
|
||||
|
|
|
|||
|
|
@ -86,6 +86,7 @@ class ContractController extends Controller
|
|||
if (!$car) {
|
||||
return [
|
||||
'name' => null,
|
||||
'label' => null,
|
||||
'id' => null,
|
||||
'stammnummer' => null,
|
||||
'vin' => null,
|
||||
|
|
@ -96,6 +97,7 @@ class ContractController extends Controller
|
|||
}
|
||||
return [
|
||||
'name' => $car->name,
|
||||
'label' => $car->name . ' (' . $car->stammnummer . ')',
|
||||
'id' => $car->id,
|
||||
'stammnummer' => $car->stammnummer,
|
||||
'vin' => $car->vin,
|
||||
|
|
@ -144,22 +146,25 @@ class ContractController extends Controller
|
|||
'type' => (string)$request->get('type'),
|
||||
'payment_type' => (string)$request->get('payment_type'),
|
||||
'insurance_type' => (string)$request->get('insurance_type'),
|
||||
]);
|
||||
|
||||
$request->validate([
|
||||
'type' => ['required', 'string', Rule::in(ContractType::getValues())],
|
||||
'date' => ['required', 'date_format:"d.m.Y"'],
|
||||
'delivery_date' => ['required', 'date_format:"d.m.Y"'],
|
||||
'price' => ['required', 'integer'],
|
||||
'car_id' => ['required', 'exists:App\Models\Car,id'],
|
||||
'contact_id' => ['required', 'exists:App\Models\Contact,id'],
|
||||
'insurance_type' => ['nullable', 'string', Rule::in(InsuranceType::getValues())],
|
||||
'notes' => ['nullable'],
|
||||
]);
|
||||
|
||||
$request->merge([
|
||||
'date' => Carbon::parse($request->get('date'))->format('Y-m-d'),
|
||||
'delivery_date' => Carbon::parse($request->get('delivery_date'))->format('Y-m-d'),
|
||||
]);
|
||||
|
||||
$contract = Contract::create(
|
||||
$request->validate([
|
||||
'type' => ['required', 'string', Rule::in(ContractType::getValues())],
|
||||
'date' => ['required', 'date'],
|
||||
'delivery_date' => ['required', 'date'],
|
||||
'price' => ['required', 'integer'],
|
||||
'car_id' => ['required', 'exists:App\Models\Car,id'],
|
||||
'contact_id' => ['required', 'exists:App\Models\Contact,id'],
|
||||
'insurance_type' => ['nullable', 'string', Rule::in(InsuranceType::getValues())],
|
||||
'notes' => ['nullable'],
|
||||
])
|
||||
);
|
||||
$contract = Contract::create($request->all());
|
||||
|
||||
$request->merge([
|
||||
'type' => (string)$request->get('payment_type'),
|
||||
|
|
@ -209,19 +214,22 @@ class ContractController extends Controller
|
|||
{
|
||||
$request->merge([
|
||||
'insurance_type' => (string)$request->get('insurance_type'),
|
||||
]);
|
||||
|
||||
$request->validate([
|
||||
'date' => ['required', 'date_format:"d.m.Y"'],
|
||||
'delivery_date' => ['required', 'date_format:"d.m.Y"'],
|
||||
'price' => ['required', 'integer'],
|
||||
'insurance_type' => ['nullable', 'string', Rule::in(InsuranceType::getValues())],
|
||||
'notes' => ['nullable'],
|
||||
]);
|
||||
|
||||
$request->merge([
|
||||
'date' => Carbon::parse($request->get('date'))->format('Y-m-d'),
|
||||
'delivery_date' => Carbon::parse($request->get('delivery_date'))->format('Y-m-d'),
|
||||
]);
|
||||
|
||||
$contract->update(
|
||||
$request->validate([
|
||||
'date' => ['required', 'date'],
|
||||
'delivery_date' => ['required', 'date'],
|
||||
'price' => ['required', 'integer'],
|
||||
'insurance_type' => ['nullable', 'string', Rule::in(InsuranceType::getValues())],
|
||||
'notes' => ['nullable'],
|
||||
])
|
||||
);
|
||||
$contract->update($request->all());
|
||||
|
||||
session()->flash('flash.banner', 'Vertrag geändert.');
|
||||
return Redirect::route('contracts.show', $contract);
|
||||
|
|
|
|||
|
|
@ -22,17 +22,20 @@ class PaymentController extends Controller
|
|||
{
|
||||
$request->merge([
|
||||
'type' => (string)$request->get('type'),
|
||||
]);
|
||||
|
||||
$request->validate([
|
||||
'date' => ['required', 'date_format:"d.m.Y"'],
|
||||
'amount' => ['required', 'integer'],
|
||||
'type' => ['required', 'string', Rule::in(PaymentType::getValues())],
|
||||
'contract_id' => ['required', 'exists:App\Models\Contract,id'],
|
||||
]);
|
||||
|
||||
$request->merge([
|
||||
'date' => Carbon::parse($request->get('date'))->format('Y-m-d'),
|
||||
]);
|
||||
|
||||
$payment = Payment::create(
|
||||
$request->validate([
|
||||
'date' => ['required', 'date'],
|
||||
'amount' => ['required', 'integer'],
|
||||
'type' => ['required', 'string', Rule::in(PaymentType::getValues())],
|
||||
'contract_id' => ['required', 'exists:App\Models\Contract,id'],
|
||||
])
|
||||
);
|
||||
$payment = Payment::create($request->all());
|
||||
|
||||
session()->flash('flash.banner', 'Einzahlung gespeichert.');
|
||||
return Redirect::route('contracts.show', $payment->contract);
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@
|
|||
"vue-currency-input": "^2.0.0",
|
||||
"vue-multiselect": "^3.0.0-alpha.2",
|
||||
"vue-unicons": "^3.2.1",
|
||||
"vue3-datepicker": "^0.2.4",
|
||||
"vuex": "^4.0.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
|
|
@ -4379,19 +4378,6 @@
|
|||
"resolved": "https://registry.npmjs.org/csstype/-/csstype-2.6.17.tgz",
|
||||
"integrity": "sha512-u1wmTI1jJGzCJzWndZo8mk4wnPTZd1eOIYTYvuEyOQGfmDl3TrabCCfKnOC86FZwW/9djqTl933UF/cS425i9A=="
|
||||
},
|
||||
"node_modules/date-fns": {
|
||||
"version": "2.22.1",
|
||||
"resolved": "https://registry.npmjs.org/date-fns/-/date-fns-2.22.1.tgz",
|
||||
"integrity": "sha512-yUFPQjrxEmIsMqlHhAhmxkuH769baF21Kk+nZwZGyrMoyLA+LugaQtC0+Tqf9CBUUULWwUJt6Q5ySI3LJDDCGg==",
|
||||
"peer": true,
|
||||
"engines": {
|
||||
"node": ">=0.11"
|
||||
},
|
||||
"funding": {
|
||||
"type": "opencollective",
|
||||
"url": "https://opencollective.com/date-fns"
|
||||
}
|
||||
},
|
||||
"node_modules/debug": {
|
||||
"version": "4.3.1",
|
||||
"resolved": "https://registry.npmjs.org/debug/-/debug-4.3.1.tgz",
|
||||
|
|
@ -11305,21 +11291,6 @@
|
|||
"resolved": "https://registry.npmjs.org/vue/-/vue-2.6.14.tgz",
|
||||
"integrity": "sha512-x2284lgYvjOMj3Za7kqzRcUSxBboHqtgRE2zlos1qWaOye5yUmHn42LB1250NJBLRwEcdrB0JRwyPTEPhfQjiQ=="
|
||||
},
|
||||
"node_modules/vue3-datepicker": {
|
||||
"version": "0.2.4",
|
||||
"resolved": "https://registry.npmjs.org/vue3-datepicker/-/vue3-datepicker-0.2.4.tgz",
|
||||
"integrity": "sha512-KV+GnP3+pWyWk9YUWC1BkYaiXhDS4C4jIekTrLAGQsuUARMzUYq0WlRAnzHfv5n2Vgt1j/X2hkPkl+xKwKZRUw==",
|
||||
"dependencies": {
|
||||
"date-fns": "^2.16.1"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=10.16.0"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"date-fns": "^2.16.1",
|
||||
"vue": "^3.0.0"
|
||||
}
|
||||
},
|
||||
"node_modules/vuex": {
|
||||
"version": "4.0.2",
|
||||
"resolved": "https://registry.npmjs.org/vuex/-/vuex-4.0.2.tgz",
|
||||
|
|
@ -15235,12 +15206,6 @@
|
|||
"resolved": "https://registry.npmjs.org/csstype/-/csstype-2.6.17.tgz",
|
||||
"integrity": "sha512-u1wmTI1jJGzCJzWndZo8mk4wnPTZd1eOIYTYvuEyOQGfmDl3TrabCCfKnOC86FZwW/9djqTl933UF/cS425i9A=="
|
||||
},
|
||||
"date-fns": {
|
||||
"version": "2.22.1",
|
||||
"resolved": "https://registry.npmjs.org/date-fns/-/date-fns-2.22.1.tgz",
|
||||
"integrity": "sha512-yUFPQjrxEmIsMqlHhAhmxkuH769baF21Kk+nZwZGyrMoyLA+LugaQtC0+Tqf9CBUUULWwUJt6Q5ySI3LJDDCGg==",
|
||||
"peer": true
|
||||
},
|
||||
"debug": {
|
||||
"version": "4.3.1",
|
||||
"resolved": "https://registry.npmjs.org/debug/-/debug-4.3.1.tgz",
|
||||
|
|
@ -20563,12 +20528,6 @@
|
|||
}
|
||||
}
|
||||
},
|
||||
"vue3-datepicker": {
|
||||
"version": "0.2.4",
|
||||
"resolved": "https://registry.npmjs.org/vue3-datepicker/-/vue3-datepicker-0.2.4.tgz",
|
||||
"integrity": "sha512-KV+GnP3+pWyWk9YUWC1BkYaiXhDS4C4jIekTrLAGQsuUARMzUYq0WlRAnzHfv5n2Vgt1j/X2hkPkl+xKwKZRUw==",
|
||||
"requires": {}
|
||||
},
|
||||
"vuex": {
|
||||
"version": "4.0.2",
|
||||
"resolved": "https://registry.npmjs.org/vuex/-/vuex-4.0.2.tgz",
|
||||
|
|
|
|||
|
|
@ -33,7 +33,6 @@
|
|||
"vue-currency-input": "^2.0.0",
|
||||
"vue-multiselect": "^3.0.0-alpha.2",
|
||||
"vue-unicons": "^3.2.1",
|
||||
"vue3-datepicker": "^0.2.4",
|
||||
"vuex": "^4.0.0"
|
||||
}
|
||||
}
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -13,7 +13,7 @@
|
|||
<div class="col-span-6">
|
||||
<jet-label for="car" value="Auto auswählen" />
|
||||
<div class="grid grid-cols-12 gap-3 gap-y-6 mt-1">
|
||||
<multiselect :allow-empty="false" @select="onCarChange" :disabled="createCar" v-model="car" label="name" track-by="id" :options="carsChoice" class="2xl:col-span-4 sm:col-span-6 col-span-12" placeholder="Auto auswählen" />
|
||||
<multiselect :allow-empty="false" @select="onCarChange" :disabled="createCar" v-model="car" label="label" track-by="id" :options="carsChoice" class="2xl:col-span-4 sm:col-span-6 col-span-12" placeholder="Auto auswählen" />
|
||||
<div v-if="!createCar" class="sm:col-span-6 col-span-12">
|
||||
<span class="mr-2">oder</span>
|
||||
<button @click="openCarForm" class="bg-indigo-800 hover:bg-indigo-700 active:bg-indigo-900 focus:border-indigo-900 focus:ring-indigo-300 justify-center inline-flex items-center px-4 py-2 border border-transparent rounded-md font-semibold text-xs text-white uppercase tracking-widest focus:outline-none focus:ring disabled:opacity-25 transition">
|
||||
|
|
@ -22,8 +22,8 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div v-if="car.id" class="col-span-6">
|
||||
<car-card class="mt-3 xl:col-span-3 md:col-span-4 col-span-6" :car="car" hideEmpty="true" />
|
||||
<div v-if="car.id" class="xl:col-span-3 md:col-span-4 col-span-6">
|
||||
<car-card :car="car" hideEmpty="true" />
|
||||
</div>
|
||||
<div v-if="createCar" class="col-span-6">
|
||||
<p class="w-full mb-1 font-bold">Neues Auto erfassen:</p>
|
||||
|
|
@ -72,6 +72,7 @@ export default {
|
|||
car: {
|
||||
id: this.existing_car?.id ?? null,
|
||||
name: this.existing_car?.name ?? null,
|
||||
label: this.existing_car?.label ?? null,
|
||||
stammnummer: this.existing_car?.stammnummer ?? null,
|
||||
vin: this.existing_car?.vin ?? null,
|
||||
colour: this.existing_car?.colour ?? null,
|
||||
|
|
|
|||
|
|
@ -22,8 +22,8 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div v-if="contact.id" class="col-span-6">
|
||||
<contact-card class="mt-3 xl:col-span-3 md:col-span-4 col-span-6" :contact="contact" hideEmpty="true" />
|
||||
<div v-if="contact.id" class="xl:col-span-3 md:col-span-4 col-span-6">
|
||||
<contact-card :contact="contact" hideEmpty="true" />
|
||||
</div>
|
||||
<div v-if="createContact" class="col-span-6">
|
||||
<p class="w-full mb-1 font-bold">Neuen Kontakt erfassen:</p>
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
<template>
|
||||
<span v-if="!isFailed" class="col-span-2 grid grid-flow-rows relative cursor-pointer auto-rows-max py-3 inline-flex items-center px-4 bg-gray-100 border-dashed border-4 font-semibold justify-center text-md text-gray-500 uppercase tracking-widest hover:bg-gray-200 focus:outline-none focus:border-gray-500 focus:ring focus:ring-gray-300 disabled:opacity-25 transition" >
|
||||
<span v-if="!isFailed" class="col-span-2 grid grid-flow-rows relative cursor-pointer auto-rows-max md:py-3 py-2 inline-flex items-center md:px-4 px-2 bg-gray-100 border-dashed border-4 font-semibold justify-center text-md text-gray-500 uppercase tracking-widest hover:bg-gray-200 focus:outline-none focus:border-gray-500 focus:ring focus:ring-gray-300 disabled:opacity-25 transition" >
|
||||
<input type="file" :name="uploadFieldName" :disabled="isSaving" @change="filesChange($event.target.name, $event.target.files);" class="opacity-0 absolute top-0 left-0 w-full h-full cursor-pointer">
|
||||
<unicon fill="currentColor" class="p-2 my-5 mx-auto" height="45%" width="45%" name="file-upload-alt"></unicon>
|
||||
<unicon fill="currentColor" class="md:p-2 p-1 md:my-5 my-1 mx-auto" height="45%" width="45%" name="file-upload-alt"></unicon>
|
||||
<span v-if="isInitial" class="text-center">Dokument hochladen</span>
|
||||
<span v-if="isSaving">Lade Dokument hoch...</span> </span>
|
||||
<span v-else class="col-span-2">
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@
|
|||
<div class="grid grid-cols-6 gap-6">
|
||||
<div class="col-span-6 sm:col-span-4">
|
||||
<jet-label for="date" value="Datum" />
|
||||
<datepicker id="date" ref="date" v-model="form.date" inputFormat="dd.MM.yyyy" class="border-gray-300 rounded-md shadow-sm mt-1 block w-full" />
|
||||
<jet-input id="date" ref="date" type="text" class="mt-1 block w-full" v-model="form.date" />
|
||||
<jet-input-error :message="form.errors.date" class="mt-2" />
|
||||
</div>
|
||||
|
||||
|
|
@ -41,9 +41,8 @@
|
|||
import JetButton from '@/Jetstream/Button';
|
||||
import JetLabel from '@/Jetstream/Label.vue';
|
||||
import JetInputError from '@/Jetstream/InputError';
|
||||
import Datepicker from 'vue3-datepicker';
|
||||
import JetInput from '@/Jetstream/Input';
|
||||
import { useForm } from '@inertiajs/inertia-vue3';
|
||||
import { ref } from 'vue';
|
||||
import DialogModal from '@/Jetstream/DialogModal.vue';
|
||||
import CurrencyInput from '@/Components/CurrencyInput';
|
||||
|
||||
|
|
@ -53,8 +52,8 @@ export default {
|
|||
JetLabel,
|
||||
JetInputError,
|
||||
DialogModal,
|
||||
Datepicker,
|
||||
CurrencyInput,
|
||||
JetInput,
|
||||
},
|
||||
props: {
|
||||
id: Number,
|
||||
|
|
@ -65,7 +64,7 @@ export default {
|
|||
return {
|
||||
form: useForm('CreatePayment', {
|
||||
id: null,
|
||||
date: ref(new Date()),
|
||||
date: new Date().toJSON().slice(0,10).split('-').reverse().join('.'),
|
||||
amount: this.left_to_pay,
|
||||
type: '1',
|
||||
contract_id: this.id,
|
||||
|
|
|
|||
|
|
@ -1,17 +1,17 @@
|
|||
<template>
|
||||
<div>
|
||||
<span v-if="title" class="flex justify-between items-end mb-4">
|
||||
<span v-if="title" class="flex justify-between items-end md:mb-4 mb-2">
|
||||
<p v-if="title" class="font-semibold md:text-2xl sm:text-xl text-base font-medium text-indigo-900 leading-tight">{{ title }}</p>
|
||||
<slot name="actions" class=""></slot>
|
||||
</span>
|
||||
<div v-if="form || print" class="my-4 flex justify-between items-center">
|
||||
<div v-if="form" class="flex items-center w-full max-w-md mr-4">
|
||||
<div v-if="form || print" class="md:my-4 my-2 flex justify-between items-center">
|
||||
<div v-if="form" class="flex items-center w-full max-w-md md:mr-4 mr-2">
|
||||
<div class="flex w-full bg-white shadow rounded">
|
||||
<input type="text" ref="search" v-model="form.search" autofocus="true" name="search" placeholder="Suchen..." class="relative border-gray-200 w-full px-6 py-3 focus:border-indigo-300 focus:ring focus:ring-indigo-200 focus:ring-opacity-50 rounded" autocomplete="off">
|
||||
<input type="text" ref="search" v-model="form.search" autofocus="true" name="search" placeholder="Suchen..." class="relative border-gray-200 w-full sm:px-6 px-3 py-3 focus:border-indigo-300 focus:ring focus:ring-indigo-200 focus:ring-opacity-50 rounded" autocomplete="off">
|
||||
</div>
|
||||
<button @click="reset" type="button" class="ml-3 text-sm text-gray-500 hover:text-gray-700 focus:text-blue-200">Reset</button>
|
||||
</div>
|
||||
<a v-if="print" :href="route(currentRoute + '.print', { search: form.search, sortBy: sort.by, direction: sort.direction })" class="justify-center inline-flex items-center px-4 py-2 border border-transparent rounded-md font-semibold text-xs text-white uppercase tracking-widest focus:outline-none focus:ring disabled:opacity-25 transition bg-green-800 hover:bg-green-700 active:bg-green-900 focus:border-green-900 focus:ring-green-300 py-3">
|
||||
<a v-if="print" :href="route(currentRoute + '.print', { search: form.search, sortBy: sort.by, direction: sort.direction })" class="justify-center inline-flex items-center sm:px-4 sm:py-2 px-2 py-1 border border-transparent rounded-md font-semibold text-xs text-white uppercase tracking-widest focus:outline-none focus:ring disabled:opacity-25 transition bg-green-800 hover:bg-green-700 active:bg-green-900 focus:border-green-900 focus:ring-green-300 py-3">
|
||||
<unicon fill="white" class="mr-2" height="24" width="24" name="chart"></unicon>
|
||||
Excel-Export
|
||||
</a>
|
||||
|
|
@ -43,7 +43,7 @@
|
|||
</span>
|
||||
</td>
|
||||
<td v-if="row.link && !hideArrow" class="border-t w-px">
|
||||
<inertia-link class="xl:py-4 py-2 flex items-center" :href="row.link" tabindex="-1">
|
||||
<inertia-link class="xl:pr-4 pr-2 xl:py-4 py-2 flex items-center" :href="row.link" tabindex="-1">
|
||||
<unicon height="22" width="22" name="angle-right"></unicon>
|
||||
</inertia-link>
|
||||
</td>
|
||||
|
|
|
|||
|
|
@ -41,13 +41,13 @@
|
|||
<div class="grid grid-cols-12 gap-6">
|
||||
<div class="col-span-6 sm:col-span-6">
|
||||
<jet-label for="initial_date" value="Inverkehrssetzung" />
|
||||
<datepicker id="initial_date" ref="initial_date" v-model="form.initial_date" inputFormat="dd.MM.yyyy" class="border-gray-300 rounded-md shadow-sm mt-1 block w-full" />
|
||||
<jet-input id="initial_date" ref="initial_date" type="text" class="mt-1 block w-full" v-model="form.initial_date" />
|
||||
<jet-input-error :message="form.errors.initial_date" class="mt-2" />
|
||||
</div>
|
||||
|
||||
<div class="col-span-6 sm:col-span-6">
|
||||
<jet-label for="last_check_date" value="Letzte Prüfung" />
|
||||
<datepicker id="last_check_date" ref="last_check_date" v-model="form.last_check_date" inputFormat="dd.MM.yyyy" class="border-gray-300 rounded-md shadow-sm mt-1 block w-full" />
|
||||
<jet-input id="last_check_date" ref="last_check_date" type="text" class="mt-1 block w-full" v-model="form.last_check_date" />
|
||||
<jet-input-error :message="form.errors.last_check_date" class="mt-2" />
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -86,7 +86,6 @@ import JetInput from '@/Jetstream/Input.vue';
|
|||
import JetActionMessage from '@/Jetstream/ActionMessage';
|
||||
import JetInputError from '@/Jetstream/InputError';
|
||||
import Multiselect from 'vue-multiselect';
|
||||
import Datepicker from 'vue3-datepicker';
|
||||
import CurrencyInput from '@/Components/CurrencyInput';
|
||||
|
||||
export default {
|
||||
|
|
@ -96,7 +95,6 @@ export default {
|
|||
JetInputError,
|
||||
JetActionMessage,
|
||||
Multiselect,
|
||||
Datepicker,
|
||||
CurrencyInput,
|
||||
},
|
||||
props: {
|
||||
|
|
|
|||
|
|
@ -19,7 +19,6 @@
|
|||
<script>
|
||||
import Layout from '@/Layouts/Layout';
|
||||
import BreadCrumb from '@/Components/BreadCrumb.vue';
|
||||
import { ref } from 'vue';
|
||||
import CarForm from './Components/CarForm.vue';
|
||||
|
||||
export default {
|
||||
|
|
@ -46,8 +45,8 @@ export default {
|
|||
vin: null,
|
||||
colour: null,
|
||||
car_model_id: null,
|
||||
initial_date: ref(new Date()),
|
||||
last_check_date: ref(new Date()),
|
||||
initial_date: new Date().toJSON().slice(0,10).split('-').reverse().join('.'),
|
||||
last_check_date: new Date().toJSON().slice(0,10).split('-').reverse().join('.'),
|
||||
kilometers: null,
|
||||
known_damage: null,
|
||||
notes: null,
|
||||
|
|
|
|||
|
|
@ -21,7 +21,6 @@
|
|||
<script>
|
||||
import Layout from '@/Layouts/Layout';
|
||||
import BreadCrumb from '@/Components/BreadCrumb.vue';
|
||||
import { ref } from 'vue';
|
||||
import CarForm from './Components/CarForm.vue';
|
||||
|
||||
export default {
|
||||
|
|
@ -62,11 +61,11 @@ export default {
|
|||
id: this.car.id,
|
||||
stammnummer: this.car.stammnummer,
|
||||
vin: this.car.vin,
|
||||
initial_date: ref(new Date(this.car.initial_date)),
|
||||
initial_date: new Date(this.car.initial_date).toJSON().slice(0,10).split('-').reverse().join('.'),
|
||||
colour: this.car.colour,
|
||||
notes: this.car.notes,
|
||||
car_model_id: this.car.car_model.id,
|
||||
last_check_date: ref(new Date(this.car.last_check_date)),
|
||||
last_check_date: new Date(this.car.last_check_date).toJSON().slice(0,10).split('-').reverse().join('.'),
|
||||
kilometers: this.car.kilometers,
|
||||
known_damage: this.car.known_damage,
|
||||
notes: this.car.notes,
|
||||
|
|
|
|||
|
|
@ -12,12 +12,12 @@
|
|||
<div class="xl:col-span-2 md:col-span-3 sm:col-span-4 col-span-6 grid grid-cols-6 gap-3">
|
||||
<div class="col-span-6">
|
||||
<jet-label for="date" value="Datum" />
|
||||
<datepicker id="date" ref="date" v-model="form.date" inputFormat="dd.MM.yyyy" class="border-gray-300 rounded-md shadow-sm mt-1 block w-full" />
|
||||
<jet-input id="date" ref="date" type="text" class="mt-1 block w-full" v-model="form.date" />
|
||||
<jet-input-error :message="form.errors.date" class="mt-2" />
|
||||
</div>
|
||||
<div class="col-span-6">
|
||||
<jet-label for="delivery_date" value="Lieferdatum" />
|
||||
<datepicker id="delivery_date" ref="delivery_date" v-model="form.delivery_date" inputFormat="dd.MM.yyyy" class="border-gray-300 rounded-md shadow-sm mt-1 block w-full" />
|
||||
<jet-input id="delivery_date" ref="delivery_date" type="text" class="mt-1 block w-full" v-model="form.delivery_date" />
|
||||
<jet-input-error :message="form.errors.delivery_date" class="mt-2" />
|
||||
</div>
|
||||
|
||||
|
|
@ -76,8 +76,8 @@ import JetButton from '@/Jetstream/Button';
|
|||
import JetLabel from '@/Jetstream/Label.vue';
|
||||
import JetActionMessage from '@/Jetstream/ActionMessage';
|
||||
import JetInputError from '@/Jetstream/InputError';
|
||||
import JetInput from '@/Jetstream/Input';
|
||||
import JetFormSection from '@/Jetstream/FormSection';
|
||||
import Datepicker from 'vue3-datepicker';
|
||||
import { useForm } from '@inertiajs/inertia-vue3';
|
||||
import CurrencyInput from '@/Components/CurrencyInput';
|
||||
|
||||
|
|
@ -88,7 +88,7 @@ export default {
|
|||
JetLabel,
|
||||
JetInputError,
|
||||
JetActionMessage,
|
||||
Datepicker,
|
||||
JetInput,
|
||||
CurrencyInput,
|
||||
},
|
||||
props: {
|
||||
|
|
|
|||
|
|
@ -28,7 +28,6 @@ import Layout from '@/Layouts/Layout';
|
|||
import BreadCrumb from '@/Components/BreadCrumb.vue';
|
||||
import ContactCreateOrSelect from '@/Components/Contacts/CreateOrSelect.vue';
|
||||
import CarCreateOrSelect from '@/Components/Cars/CreateOrSelect.vue';
|
||||
import { ref } from 'vue';
|
||||
import ContractForm from './Components/ContractForm.vue';
|
||||
|
||||
export default {
|
||||
|
|
@ -59,8 +58,8 @@ export default {
|
|||
},
|
||||
data: {
|
||||
id: null,
|
||||
date: ref(new Date()),
|
||||
delivery_date: ref(new Date()),
|
||||
date: new Date().toJSON().slice(0,10).split('-').reverse().join('.'),
|
||||
delivery_date: new Date().toJSON().slice(0,10).split('-').reverse().join('.'),
|
||||
price: null,
|
||||
notes: null,
|
||||
type: this.type,
|
||||
|
|
|
|||
|
|
@ -22,7 +22,6 @@
|
|||
<script>
|
||||
import Layout from '@/Layouts/Layout';
|
||||
import BreadCrumb from '@/Components/BreadCrumb.vue';
|
||||
import { ref } from 'vue';
|
||||
import ContractForm from './Components/ContractForm.vue';
|
||||
|
||||
export default {
|
||||
|
|
@ -46,8 +45,8 @@ export default {
|
|||
on_success: 'Änderungen gespeichert',
|
||||
},
|
||||
data: {
|
||||
date: ref(new Date(this.contract.date)),
|
||||
delivery_date: ref(new Date(this.contract.delivery_date)),
|
||||
date: new Date(this.contract.date).toJSON().slice(0,10).split('-').reverse().join('.'),
|
||||
delivery_date: new Date(this.contract.delivery_date).toJSON().slice(0,10).split('-').reverse().join('.'),
|
||||
price: this.contract.price,
|
||||
notes: this.contract.notes,
|
||||
insurance_type: this.contract.insurance_type,
|
||||
|
|
|
|||
Loading…
Reference in New Issue