insert into project.users_table (username,email,name_user,password_user) values
('andrejtodorovski5','andrejtodorovski5@gmail.com','Andrej Todorovski','andrejpassword'),
('stefanmileski4','stefanmileski4@gmail.com','Stefan Mileski','stefanpassword'),
('hristijansazdovski3','hristijansazdovski3@gmail.com','Hristijan Sazdovski','hristijanpassword'),
('client1','bojantrpeski2@gmail.com','Bojan Trpeski','bojanpassword'),
('client2','darkosasanski1@gmail.com','Darko Sasanski','darkopassword'),
('client3','denicakjorvezir@gmail.com','Denica Kjorvezir','denicapassword'),
('deliveryman1','deliveryman1@gmail.com','Petko Petkovski','petko123'),
('deliveryman2','deliveryman2@gmail.com','Marko Markovski','marko123'),
('deliveryman3','deliveryman3@gmail.com','Petar Petrovski','petar123'),
('warehouseman1','warehouseman1@gmail.com','Viktor Petrovski','viktor123'),
('warehouseman2','warehouseman2@gmail.com','Vlatko Petrovski','vlatko123'),
('warehouseman3','warehouseman3@gmail.com','Vido Petrovski','vido123'),
('client4','client4@gmail.com','Client Four','client4'),
('client5','client5@gmail.com','Client Five','client5'),
('client6','client6@gmail.com','Client Six','client6'),
('client7','client7@gmail.com','Client Seven','client7'),
('client8','client8@gmail.com','Client Eight','client8'),
('client9','client9@gmail.com','Client Nine','client9'),
('client10','client10@gmail.com','Client Ten','client10'),
('client11','client11@gmail.com','Client Eleven','client11'),
('client12','client12@gmail.com','Client Twelve','client12'),
('client13','client13@gmail.com','Client Thirteen','client13'),
('client14','client14@gmail.com','Client Fourteen','client14'),
('client15','client15@gmail.com','Client Fifteen','client15');

--insert into project.users_table (username,email,name_user,password_user,phone_number) values
--('stefanmileski5','stefanmileski5@gmail.com','Stefan Mileski','stefanklient','070 123 456');

insert into project.administrator (id_user,authorized_from, authorized_till) values (1,'2022-01-01','2024-01-01'),(2,'2022-01-01','2025-01-01'),(3,'2022-01-01','2026-01-01');

insert into project.client (id_user) values (4),(5),(6),(13),(14),(15),(16),(17),(18),(19),(20),(21),(22),(23),(24);

insert into project.delivery_man (id_user,employed_from) values (7,now()),(8,now()),(9,now());

insert into project.warehouse (warehouse_location) values ('Radishani'),('Kozle'),('Vizbegovo');

insert into project.warehouseman (id_user,employed_from,id_warehouse) values (10,now(),1),(11,now(),2),(12,now(),3);

insert into project.part_manufacturer (pm_name,pm_location) values
('Bosch','Germany'),
('Continental','Belgium'),
('Mahle','Netherlands'),
('Sachs','Germany'),
('Brembo','Italy');

insert into project.car_manufacturer (cm_name,cm_country) values
('Volkswagen','Germany'),
('Fiat','Italy'),
('Ford','USA'),
('Toyota','Japan'),
('Hyndai','Korea');

insert into project.repair_shop (rs_name,rs_location,rs_phone_number) values
('Volkswagen Service','Ilinenska','075 876 543'),
('Fiat Service','Vodnjanska','078 555 666'),
('Ford Service','Teodosij Gologanov','071 333 444'),
('Toyota Service','Partizanska','070 123 456'),
('Hyndai Service','Boris Trajkovski','075 500 000');

insert into project.car(in_production_since,in_production_till,car_type,id_car_manufacturer) values
(2001,2004,'Golf 4',1),
(2004,2006,'Golf 5',1),
(2001,2003,'Punto',2),
(2004,2008,'Punto Evo',2),
(2009,2012,'Grande Punto',2),
(2007,2014,'Doblo',2),
(2000,2008,'Fiesta',3),
(2005,2015,'Focus',3),
(2003,2006,'Aygo',4),
(2007,2015,'Yaris',4),
(2015,2022,'Corollaa',4),
(1995,2005,'Coupe',5);

insert into project.car_sample(vin,year_of_production, engine_power, displacement, fuel_type, km_driven, ID_user, ID_car) values
(4444,2003,65,1200,'Diesel',120000,4,1),
(5555,2005,80,1400,'Diesel',150000,5,2),
(6666,2002,65,1200,'Petrol/Gas',65000,6,3),
(1313,2006,140,2000,'Diesel',185000,13,4),
(1414,2006,120,1900,'Diesel',240000,14,5),
(1515,2006,95,1600,'Petrol',85000,15,6),
(1616,2006,80,1400,'Petrol/Gas',125000,16,7),
(1717,2006,69,1200,'Petrol',113000,17,8),
(1818,2006,65,1200,'Petrol/Gas',150000,18,9),
(1919,2006,140,1600,'Diesel',140000,19,10),
(2020,2017,200,2400,'Diesel',20000,20,11),
(2121,1996,200,2000,'Petrol/Gas',320000,21,12),
(2222,2004,120,1600,'Diesel',115000,22,3),
(2323,2003,140,2000,'Petrol/Gas',105000,23,3),
(2424,2000,120,1900,'Diesel',150000,24,1);

insert into project.part(part_name, id_part_manufacturer) values
('Engine G4GF',1),
('Wheel 20CM',2),
('Shift 6GEARS',3),
('Radio with AUX',1),
('Rear Bumper FOR VW GOLF 4',2),
('Headlight FOR PUNTO',3),
('Air Conditioning',4),
('Hand Brake',5),
('Siren',4),
('Electrical window buttons',5),
('Sport filter',4),
('Air filter',5),
('Fuel filter',4),
('Oil filter',5);

insert into project.category(category_name) values ('Brakes'),('Cooling System'),('Electrical'),('Engine components'),('Exterior'),('Filters'),('Interior'),('Shift');

insert into project.order_table(order_status,order_date,id_user) values 
('created',now()-interval'12months',4),
('created',now()-interval'6months',4),
('created',now()-interval'7months',4),
('created',now()-interval'1month',4),
('created',now()-interval'11months',5),
('created',now()-interval'10months',6),
('created',now()-interval'2months',6),
('created',now()-interval'9months',13),
('created',now()-interval'8months',14),
('created',now()-interval'7months',15),
('created',now()-interval'6months',16),
('created',now()-interval'9months',17),
('created',now()-interval'5months',17),
('created',now()-interval'4months',18),
('created',now()-interval'3months',19),
('created',now()-interval'2months',20),
('created',now()-interval'1month',21),
('created',now()-interval'12months',22),
('created',now(),23),
('created',now()-interval'3months',24),
('created',now(),24);


insert into project.service_book (vin) values (4444),(5555),(6666),(1313),(1414),(1515),(1616),(1717),(1818),(1919),(2020),(2121),(2222),(2323),(2424);

insert into project.delivery (delivery_status, delivery_address,id_user,id_order) values 
('finished', 'Radisani',7,5),
('finished','Dracevo',8,6),
('in progress','Gjorce',9,7),
('finished','Lisice',8,9),
('finished', 'Butel',7,10),
('finished','Pintija',8,11),
('finished','Kisela Voda',9,12),
('finished','Radisani',7,13),
('finished','Nerezi',8,14),
('finished', 'Aerodrom',7,15),
('finished', 'Aerodrom',9,16),
('in progress', 'Novo Lisice',9,17),
('finished', 'Butel',7,18),
('in progress', 'Kozle',8,19),
('finished', 'Aerodrom',9,20),
('in progress', 'Gjorce',8,21);



insert into project.price (amount, price_from, id_part) values 
(3000,now(),1),
(1000,now(),2),
(2000,now(),3),
(1500,now(),4),
(3500,now(),5),
(300,now(),6),
(4300,now(),7),
(900,now(),8),
(500,now(),9),
(1300,now(),10),
(3500,now(),11),
(3600,now(),12),
(4500,now(),13),
(4100,now(),14);


-- namesto vin da bide order
insert into project.repair (ID_order, id_repair_shop, id_service_book) values 
(1,1,1),
(2,1,1),
(3,1,1),
(4,1,1),
(8,2,13);


insert into project.part_is_from_category (id_part, id_category) values (1,4),(2,7),(3,8),(4,3),(5,5),(6,5),(7,2),(8,1),(9,3),(10,3),(11,6),(12,6),(13,6),(14,6);

insert into project.repair_shop_is_authorized_for_car_make (id_repair_shop, id_car_manufacturer) values (1,1),(2,2),(3,3),(4,4),(5,5);


insert into project.review (review_rating, id_repair, id_user) values (10,1,4),(6,2,4),(7,3,4),
(8,4,4),(9,5,22);


insert into project.part_is_in_stock_in_warehouse (id_part,id_warehouse,quantity_warehouse) values (1,2,100), (2,1,150), (3,1,50), (4,3,75),(5,1,30),(6,2,70),
(7,3,10),(8,2,20),(9,3,50),(10,3,25),(11,1,16),(12,2,24),(13,1,20),(14,2,70);


insert into project.part_is_appropriate_for_car (id_part, id_car) values 
(1,1),(1,2),(2,3),(2,4),(2,5),(2,6),(3,8),(3,11),(3,12),(4,1),(4,2),(4,3),(4,4),(4,5),(4,6),(4,7),(4,8),(5,1),(6,3),(6,4),(7,9),(7,10),
(7,11),(8,12),(9,1),(9,2),(9,7),(9,8),(10,1),(10,2),(10,12),(11,3),(11,4),(11,5),(12,7),(12,8),(13,6),(14,1),(14,2);



insert into project.order_contains_part (id_order, id_part, quantity_order) values 
(1,1,2),(1,4,1),(2,14,1),(3,10,2),(3,5,2),(4,4,3),(4,1,1),(5,1,2),(5,4,1),(5,14,1),(6,11,2),(7,2,2),(7,6,1),(7,11,1),
(8,2,1),(9,11,2),(10,13,1),(11,9,1),(11,12,1),(12,3,1),(12,4,1),(13,9,2),(14,7,1),(15,7,1),(16,7,1),(17,10,1),(17,8,1),
(18,2,1),(19,4,1),(19,6,2),(19,11,2),(20,1,2),(21,9,1);




