diff --git a/builder.sh b/builder.sh index 576e9ee8966a173871a11ef9f86f5d13a239e94e..2ab6252f37e9152077543859041aa780ea772fcf 100755 --- a/builder.sh +++ b/builder.sh @@ -12,7 +12,7 @@ function compile_coffee() { function package_war() { echo "******* Building maven *********" - mvn clean install + mvn clean install -DskipTests=true #rm -rfv /tomcat_wars/* echo "********* Copying war **********" cp /app/target/corporative_systems.war /tomcat_wars/ROOT.war diff --git a/docker-compose.test.yml b/docker-compose.test.yml index 37288f4932c8c19898ce1699faeb76913671621c..217394b505084065667ac7884319da2c229ece2b 100644 --- a/docker-compose.test.yml +++ b/docker-compose.test.yml @@ -1,15 +1,20 @@ version: '3.7' - +networks: + test_corporate_network: + name: 'tcn' services: test_builder: build: . container_name: 'test_corporate_builder' volumes: - .:/app/ + - .m2:/root/.m2 working_dir: '/app/' depends_on: - test_db - command: mvn clean test + command: mvn clean test -v + networks: + - test_corporate_network test_db: image: 'postgres:10-alpine' @@ -17,4 +22,8 @@ services: environment: POSTGRES_DB: cinema POSTGRES_USER: postgres - POSTGRES_PASSWORD: postgres \ No newline at end of file + POSTGRES_PASSWORD: postgres + networks: + test_corporate_network: + aliases: + - corporate_db \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml index 834b429dc26d5fadb8186eea4a1e5d8b1bd073d4..c9147b88cf0fc0ade585433792d7b7b0241c4296 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -34,6 +34,8 @@ services: POSTGRES_DB: cinema POSTGRES_USER: postgres POSTGRES_PASSWORD: postgres + ports: + - 9000:5432 volumes: - .db_data:/var/lib/postgresql/data diff --git a/pom.xml b/pom.xml index 100287c8a48843204c17c58209b998688446117f..010e2e4d35fda8bcd092cf3a4138d6a4c1951681 100644 --- a/pom.xml +++ b/pom.xml @@ -114,10 +114,28 @@ </dependency> <dependency> <groupId>org.junit.jupiter</groupId> - <artifactId>junit-jupiter</artifactId> + <artifactId>junit-jupiter-api</artifactId> <version>${junit-jupiter.version}</version> <scope>test</scope> </dependency> + <dependency> + <groupId>org.junit.jupiter</groupId> + <artifactId>junit-jupiter-params</artifactId> + <version>${junit-jupiter.version}</version> + <scope>test</scope> + </dependency> + <dependency> + <groupId>org.junit.jupiter</groupId> + <artifactId>junit-jupiter-engine</artifactId> + <version>${junit-jupiter.version}</version> + <scope>test</scope> + </dependency> + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + <version>2.6</version> + <scope>test</scope> + </dependency> <dependency> <groupId>org.mockito</groupId> <artifactId>mockito-core</artifactId> diff --git a/src/main/java/com/s3ai/controllers/StaticServlet.java b/src/main/java/com/s3ai/controllers/StaticServlet.java deleted file mode 100644 index 43c377c616f2c411340cce22c4a17668b945a152..0000000000000000000000000000000000000000 --- a/src/main/java/com/s3ai/controllers/StaticServlet.java +++ /dev/null @@ -1,24 +0,0 @@ -package com.s3ai.controllers; - -import com.s3ai.services.CinemaService; - -import javax.servlet.RequestDispatcher; -import javax.servlet.ServletException; -import javax.servlet.http.HttpServlet; -import javax.servlet.http.HttpServletRequest; -import javax.servlet.http.HttpServletResponse; -import java.io.IOException; - -public class StaticServlet extends HttpServlet { - protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { - - } - - protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { - System.out.println("doGet"); - RequestDispatcher dispatcher = request.getRequestDispatcher("pages/index.jsp"); - var cinemas = CinemaService.getInstance().getAllCinemas(); - request.getSession().setAttribute("cinemas", cinemas); - dispatcher.forward(request, response); - } -} \ No newline at end of file diff --git a/src/main/java/com/s3ai/controllers/cinemas/CinemaFill.java b/src/main/java/com/s3ai/controllers/cinemas/CinemaFill.java new file mode 100644 index 0000000000000000000000000000000000000000..587787ad5ec24283fa5f048be6a104ccebbb1b13 --- /dev/null +++ b/src/main/java/com/s3ai/controllers/cinemas/CinemaFill.java @@ -0,0 +1,35 @@ +package com.s3ai.controllers.cinemas; + +import com.s3ai.entities.Cinema; +import com.s3ai.services.CinemaService; + +import javax.servlet.ServletException; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; +import java.io.IOException; +import java.util.List; +import java.util.Random; +import java.util.stream.Collectors; + +public class CinemaFill extends HttpServlet { + CinemaService cinemaService = CinemaService.getInstance(); + + protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { + + } + + protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { + List<String> locations = cinemaService.getAllCinemas().stream().map(Cinema::getLocation).distinct().collect(Collectors.toList()); + System.out.println(locations); + var writer = response.getWriter(); + writer.println("FILLED Instances:"); + var random = new Random(); + for (int i = 0; i < 300; i++) { + var cinema = new Cinema(); + cinemaService.fillCinemaFields(cinema, "Test" + (i + 7), locations.get(random.nextInt(locations.size())), Math.abs(random.nextInt())); + cinemaService.saveCinema(cinema); + writer.println(cinema); + } + } +} diff --git a/src/main/java/com/s3ai/entities/Cinema.java b/src/main/java/com/s3ai/entities/Cinema.java index f3a6837031a1b123461a436ecd2fb2eded59c992..116988b7af221d625d69208e7f1fcbba21751113 100644 --- a/src/main/java/com/s3ai/entities/Cinema.java +++ b/src/main/java/com/s3ai/entities/Cinema.java @@ -21,4 +21,14 @@ class Cinema { private Integer seatsCount; @Column(name = "location") private String location; + + @Override + public String toString() { + return "Cinema{" + + "id=" + id + + ", name='" + name + '\'' + + ", seatsCount=" + seatsCount + + ", location='" + location + '\'' + + '}'; + } } diff --git a/src/main/webapp/WEB-INF/web.xml b/src/main/webapp/WEB-INF/web.xml index 3c145679965b5e176ffa38a548726661ef3eb87f..90e61c51169d5fec43edec0267c235f92b5df7d8 100644 --- a/src/main/webapp/WEB-INF/web.xml +++ b/src/main/webapp/WEB-INF/web.xml @@ -53,6 +53,16 @@ <url-pattern>/cinemas</url-pattern> </servlet-mapping> + <servlet> + <servlet-name>CinemaFillerServlet</servlet-name> + <servlet-class>com.s3ai.controllers.cinemas.CinemaFill</servlet-class> + <load-on-startup>1</load-on-startup> + </servlet> + <servlet-mapping> + <servlet-name>CinemaFillerServlet</servlet-name> + <url-pattern>/cinemas/fill</url-pattern> + </servlet-mapping> + <servlet> <servlet-name>CinemaEditServlet</servlet-name> <servlet-class>com.s3ai.controllers.cinemas.CinemaEdit</servlet-class> diff --git a/src/main/webapp/pages/cinemas/edit.jsp b/src/main/webapp/pages/cinemas/edit.jsp index e622489c7646bf9a6ad36deaf78847214410524d..b0d1ca4403cff865c7ad1bd0876befe1668415c9 100644 --- a/src/main/webapp/pages/cinemas/edit.jsp +++ b/src/main/webapp/pages/cinemas/edit.jsp @@ -25,7 +25,7 @@ <!-- Navigation --> <%@include file='../templates/header.jsp' %> -<div class="editing"> +<div class="editing themed-gradient"> <div class="container justify-content-center"> <form id="cinemaForm" class="d-flex justify-content-center" method="post" action="${pageContext.request.contextPath}/cinema/edit"> diff --git a/src/main/webapp/pages/cinemas/list.jsp b/src/main/webapp/pages/cinemas/list.jsp index 826a04c70b987cf0ffda3074943018bbd6fe69bb..2bcb334faf17565437fde11f493ab896eaf26184 100644 --- a/src/main/webapp/pages/cinemas/list.jsp +++ b/src/main/webapp/pages/cinemas/list.jsp @@ -16,25 +16,35 @@ <script src="${pageContext.request.contextPath}/static/js/cinemas.js"></script> </head> <body> -<table> - <tr> - <th>ID</th> - <th>Name</th> - <th>Location</th> - <th>Seats count</th> - </tr> - <tbody> - <% - List<Cinema> cinemas = (List<Cinema>) request.getSession().getAttribute("cinemas"); - for (Cinema cinema : cinemas) { - out.println("<tr id='" + cinema.getId().toString() + "'>"); - out.println("<td>" + (cinema.getName() == null ? "" : cinema.getName()) + "</td>"); - out.println("<td>" + (cinema.getLocation() == null ? "" : cinema.getLocation()) + "</td>"); - out.println("<td>" + (cinema.getSeatsCount() == null ? "" : cinema.getSeatsCount()) + "</td>"); - out.println("</tr>"); - } - %> - </tbody> -</table> +<%@include file='../templates/header.jsp' %> + +<div class="container-fluid themed-gradient"> + <div class="row table-padding justify-content-center"> + <table class="table col-6 table-striped table-dark"> + <thead> + <tr> + <th scope="col">#</th> + <th scope="col">Name</th> + <th scope="col">Location</th> + <th scope="col">Seats count</th> + </tr> + </thead> + <tbody> + <% + List<Cinema> cinemas = (List<Cinema>) request.getSession().getAttribute("cinemas"); + for (int i = 0; i < cinemas.size(); i++) { + Cinema cinema = cinemas.get(i); + out.println("<tr id='" + cinema.getId().toString() + "'>"); + out.println("<td scope=\"col\">" + (i + 1) + "</td>"); + out.println("<td>" + (cinema.getName() == null ? "" : cinema.getName()) + "</td>"); + out.println("<td>" + (cinema.getLocation() == null ? "" : cinema.getLocation()) + "</td>"); + out.println("<td>" + (cinema.getSeatsCount() == null ? "" : cinema.getSeatsCount()) + "</td>"); + out.println("</tr>"); + } + %> + </tbody> + </table> + </div> +</div> </body> </html> diff --git a/src/main/webapp/static/css/cinemas.css b/src/main/webapp/static/css/cinemas.css index b8db4f7cd7d39f62e6b89ca06088576ee41c75b3..f304d1dad9abb10ae436586960c3d0110014a81b 100644 --- a/src/main/webapp/static/css/cinemas.css +++ b/src/main/webapp/static/css/cinemas.css @@ -1 +1 @@ -.editing{background:#0f0c29;background:-webkit-linear-gradient(to right, #24243e, #302b63, #0f0c29);background:linear-gradient(to right, #24243e, #302b63, #0f0c29)}.editing .white{color:#fff}.editing .container{height:100%;display:flex;justify-content:center;align-items:center}/*# sourceMappingURL=cinemas.css.map */ +.editing .white{color:#fff}.editing .container{height:100%;display:flex;justify-content:center;align-items:center}.table-padding{padding-top:56px}/*# sourceMappingURL=cinemas.css.map */ diff --git a/src/main/webapp/static/css/cinemas.css.map b/src/main/webapp/static/css/cinemas.css.map index 586778a90605404c35f810867b256ada65994ea3..037218ecab05f8fd448dd6b9fd1f9de981d8ddf8 100644 --- a/src/main/webapp/static/css/cinemas.css.map +++ b/src/main/webapp/static/css/cinemas.css.map @@ -1 +1 @@ -{"version":3,"sourceRoot":"","sources":["../scss/cinemas.scss"],"names":[],"mappings":"AAAA,SACE,mBACA,wEACA,gEACA,gBACE,WAGF,oBACE,YACA,aACA,uBACA","file":"cinemas.css"} \ No newline at end of file +{"version":3,"sourceRoot":"","sources":["../scss/cinemas.scss"],"names":[],"mappings":"AACE,gBACE,WAGF,oBACE,YACA,aACA,uBACA,mBAIJ,eACE","file":"cinemas.css"} \ No newline at end of file diff --git a/src/main/webapp/static/css/project.css b/src/main/webapp/static/css/project.css index bab856f475d28c931207a15a613336bc22b4cbbe..335baee5f2737a6b156b7d705d091b51b2add952 100644 --- a/src/main/webapp/static/css/project.css +++ b/src/main/webapp/static/css/project.css @@ -1 +1 @@ -.mainNavigationHeader{background-color:#5a5a5a95}.mainNavigationHeader .navbar-brand{color:#fff}.mainNavigationHeader .navbar-brand:hover{text-decoration:underline;color:#fff}.mainNavigationHeader .nav-link{color:#fff !important}.mainNavigationHeader .nav-link:hover{text-decoration:underline;color:#fff}/*# sourceMappingURL=project.css.map */ +.mainNavigationHeader{background-color:#5a5a5a95}.mainNavigationHeader .navbar-brand{color:#fff}.mainNavigationHeader .navbar-brand:hover{text-decoration:underline;color:#fff}.mainNavigationHeader .nav-link{color:#fff !important}.mainNavigationHeader .nav-link:hover{text-decoration:underline;color:#fff}.themed-gradient{background:#c94b4b;background:-webkit-linear-gradient(to right, #4b134f, #c94b4b);background:linear-gradient(to right, #4b134f, #c94b4b)}/*# sourceMappingURL=project.css.map */ diff --git a/src/main/webapp/static/css/project.css.map b/src/main/webapp/static/css/project.css.map index ea4314ba3ecd676c0cbaf6e51f97246aa16f3e7b..9741ddb9488a8dff01c3ce9088168194fcf5925e 100644 --- a/src/main/webapp/static/css/project.css.map +++ b/src/main/webapp/static/css/project.css.map @@ -1 +1 @@ -{"version":3,"sourceRoot":"","sources":["../scss/project.scss"],"names":[],"mappings":"AAAA,sBACE,2BAEA,oCAKE,WAJA,0CACE,0BACA,WAKJ,gCAKE,sBAJA,sCACE,0BACA","file":"project.css"} \ No newline at end of file +{"version":3,"sourceRoot":"","sources":["../scss/project.scss"],"names":[],"mappings":"AAAA,sBACE,2BAEA,oCAME,WALA,0CACE,0BACA,WAMJ,gCAME,sBALA,sCACE,0BACA,WAON,iBACE,mBACA,+DACA","file":"project.css"} \ No newline at end of file diff --git a/src/main/webapp/static/scss/cinemas.scss b/src/main/webapp/static/scss/cinemas.scss index 05693048341eebd09ef708bc3ca58dd697545e57..606768c82b589b37328ae7ddce21bc242c9e8d3a 100644 --- a/src/main/webapp/static/scss/cinemas.scss +++ b/src/main/webapp/static/scss/cinemas.scss @@ -1,7 +1,4 @@ .editing { - background: #0f0c29; /* fallback for old browsers */ - background: -webkit-linear-gradient(to right, #24243e, #302b63, #0f0c29); /* Chrome 10-25, Safari 5.1-6 */ - background: linear-gradient(to right, #24243e, #302b63, #0f0c29); /* W3C, IE 10+/ Edge, Firefox 16+, Chrome 26+, Opera 12+, Safari 7+ */ .white { color: white; } @@ -12,4 +9,8 @@ justify-content: center; align-items: center; } +} + +.table-padding{ + padding-top: 56px; } \ No newline at end of file diff --git a/src/main/webapp/static/scss/project.scss b/src/main/webapp/static/scss/project.scss index dd824f5fdd0b9609476b784ec2d5cb8a6907b3e5..98f9288650bb9e907cebf7e4cc2617f12aab57cd 100644 --- a/src/main/webapp/static/scss/project.scss +++ b/src/main/webapp/static/scss/project.scss @@ -2,18 +2,26 @@ background-color: #5a5a5a95; .navbar-brand { - &:hover{ + &:hover { text-decoration: underline; color: white; } + color: white; } .nav-link { - &:hover{ + &:hover { text-decoration: underline; color: white; } + color: white !important; } +} + +.themed-gradient { + background: #c94b4b; /* fallback for old browsers */ + background: -webkit-linear-gradient(to right, #4b134f, #c94b4b); /* Chrome 10-25, Safari 5.1-6 */ + background: linear-gradient(to right, #4b134f, #c94b4b); /* W3C, IE 10+/ Edge, Firefox 16+, Chrome 26+, Opera 12+, Safari 7+ */ } \ No newline at end of file diff --git a/src/test/java/com/s3ai/CinemaTests.java b/src/test/java/com/s3ai/CinemaTests.java new file mode 100644 index 0000000000000000000000000000000000000000..59285a8234431fd8fe48c587ecdeda3ef9eeaa56 --- /dev/null +++ b/src/test/java/com/s3ai/CinemaTests.java @@ -0,0 +1,33 @@ +package com.s3ai; + +import com.s3ai.dao.HibernateSessionFactory; +import org.apache.commons.io.IOUtils; +import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Test; + +import java.io.IOException; +import java.nio.charset.StandardCharsets; + +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertNotNull; + +public class CinemaTests { + + @BeforeEach + public void preparation() throws IOException { +// var resourceStream = this.getClass().getResourceAsStream("/cinemasFill.sql"); +// assertNotNull(resourceStream); +// var insertQueries = IOUtils.toString(resourceStream, StandardCharsets.UTF_8); +// System.out.println(insertQueries); +// var session = HibernateSessionFactory.getSessionFactory().openSession(); +// session.createSQLQuery("TRUNCATE TABLE cinema").executeUpdate(); +// session.createSQLQuery("SELECT * FROM cinema"); + } + + @Test + public void simpleJUnit5Test() { + String result = "default"; + assertEquals("default", result); + } + +} diff --git a/src/test/java/com/s3ai/DefaultTests.java b/src/test/java/com/s3ai/DefaultTests.java deleted file mode 100644 index 5ec0fdcaadcbcc42a4231cee57518656b273efc7..0000000000000000000000000000000000000000 --- a/src/test/java/com/s3ai/DefaultTests.java +++ /dev/null @@ -1,14 +0,0 @@ -package com.s3ai; - -import org.junit.jupiter.api.Test; - -import static org.junit.jupiter.api.Assertions.assertEquals; - -public class DefaultTests { - @Test - public void simpleJUnit5Test() { - String result = "default"; - assertEquals("default", result); - } - -} diff --git a/src/test/resources/cinemasFill.sql b/src/test/resources/cinemasFill.sql new file mode 100644 index 0000000000000000000000000000000000000000..d630ea8d423896397204bbe16bfc4593c933135a --- /dev/null +++ b/src/test/resources/cinemasFill.sql @@ -0,0 +1,100 @@ +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('ae100be2-7167-49e1-a7a2-00874b69591a', 'Moscow', 'Test2', 543161332); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('cfbd9cff-e687-402d-80c9-c19979804389', 'Samara', 'Test1', 412344123); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('48c11291-b6cb-4be2-9595-2dbb6591b682', 'Saint Petersburg', 'Test3', 31244221); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('694f25cf-f1c7-42f1-bdaf-7d8e911210e3', 'Samara', 'Test4', 130419221); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('2c9a77c8-4f0b-45e5-84d0-77b8470a5571', 'Beslan', 'Test5', 423312344); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('3e0c900d-0eec-4e47-a66b-bd08800f12a0', 'Chekhov', 'Test6', 41423332); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('f7819571-c184-46db-b508-d3407ffdfe3a', 'Beslan', 'Test7', 73702752); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('b41e1f08-faef-4737-8792-10c091ec6a76', 'Chekhov', 'Test8', 64934697); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('692289c9-7927-4867-80d3-01c14cccb4b3', 'Beslan', 'Test9', 24956502); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('896710fd-62c1-422b-92db-66a65022d49e', 'Samara', 'Test10', 1144673378); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('13184200-5acc-452a-b454-6e6f09eec666', 'Saint Petersburg', 'Test11', 1019562055); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('b8eeee8c-2618-4534-84b2-481286ea8ebf', 'Chekhov', 'Test12', 783723401); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('adba7ac0-3a35-46b6-b22a-dc9604f79d7a', 'Beslan', 'Test13', 1750125481); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('1c9d2abc-fc86-48bf-bf89-ab4d4b8a2917', 'Moscow', 'Test14', 2008206890); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('26e0b9db-d607-4b03-aeca-ab4a9b3741e1', 'Chekhov', 'Test15', 1334662273); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('cf14cccf-4396-41d5-8589-b3820e0789c0', 'Chekhov', 'Test16', 136053227); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('9652d2c0-4615-4130-8d26-db3c19b7566a', 'Saint Petersburg', 'Test17', 1386044200); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('40ee29a6-e246-43b4-bf96-faac850fb2a5', 'Samara', 'Test18', 687463633); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('8e515303-facd-43db-af11-7b451b0bb40b', 'Moscow', 'Test19', 201466542); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('a82a6051-c6fa-4ee9-b0be-76290006ad02', 'Chekhov', 'Test20', 701110222); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('a14be188-ebbc-437d-be8a-3a880cebd499', 'Moscow', 'Test21', 1184199500); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('a36237a0-b80c-47d5-aa89-ca7b2e66a2ce', 'Beslan', 'Test22', 1746462345); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('868a1a50-858f-468c-9c16-e7108d4dda56', 'Samara', 'Test23', 424211844); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('a9bd2d38-25a2-4fac-b2a3-46530909dd06', 'Chekhov', 'Test24', 1132124707); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('16b0a980-3aee-4192-aa7c-7e64ee483e25', 'Chekhov', 'Test25', 738822578); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('1c5602e7-2f4e-4b29-9580-2a702ddad39f', 'Samara', 'Test26', 21686940); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('756a92dd-7247-49a2-b1bc-24e264a7cfc5', 'Moscow', 'Test27', 1350538212); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('f55e1bd2-aaf5-42a6-b33c-ee7576d49189', 'Chekhov', 'Test28', 1319999108); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('8fcb4b26-2f14-483e-a3cb-c26eeeeb3680', 'Saint Petersburg', 'Test29', 228091567); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('426f8410-59c6-4de7-818c-848ffa4a8c3c', 'Samara', 'Test30', 397978918); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('b01f194a-87cc-48ab-a721-38acefc1670c', 'Moscow', 'Test31', 392130620); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('8b9e2652-9c7f-4b85-9993-927242579045', 'Beslan', 'Test32', 739073583); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('499a80a5-93e1-4d5d-9e97-8ec889314724', 'Moscow', 'Test33', 601871440); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('d8322db2-ecdd-41da-a87e-cee8d2bdee3e', 'Samara', 'Test34', 2071668628); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('441fb537-7dae-4528-9882-94320eacb90e', 'Moscow', 'Test35', 639980168); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('bfa0c719-586a-43cb-a213-4578c6dc183d', 'Saint Petersburg', 'Test36', 1174134306); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('f5d6ca45-2201-46ea-9e3e-3c4b405c3749', 'Moscow', 'Test37', 972692006); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('15a5e607-304b-459c-a88f-9e987054f2b1', 'Saint Petersburg', 'Test38', 934486877); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('ca6e0c9b-dfb8-401f-bffc-38da0087844c', 'Samara', 'Test39', 1834203865); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('16d64628-7ea9-47f1-ad3b-b248ca7445ce', 'Chekhov', 'Test40', 1435882146); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('9f981fe7-4ab1-4517-8d00-62460894c431', 'Saint Petersburg', 'Test41', 1566659448); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('ca5320c4-daf9-429f-8d4e-c2b318944d37', 'Beslan', 'Test42', 1412996239); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('7613db4a-46a0-483e-82aa-64e72f4d35c2', 'Beslan', 'Test43', 654752709); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('8b95020d-2b99-4062-89d1-8dd54623af2d', 'Beslan', 'Test44', 945976482); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('ab3a3128-b4b5-4985-9689-67dc0da2fffd', 'Chekhov', 'Test45', 1613645080); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('26137875-5306-4c70-9895-37310d1b9aae', 'Saint Petersburg', 'Test46', 1806021920); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('8a96ce94-fa2e-4b72-ae16-e4f0a8cb11ab', 'Moscow', 'Test47', 678746468); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('4a2be48d-4f67-4a70-b47a-bfcf8551f58e', 'Saint Petersburg', 'Test48', 369958199); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('8a96b185-d380-412c-80c8-85a4d34fa573', 'Samara', 'Test49', 1141169650); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('4c02e254-714e-4a45-b965-44f3b678ef42', 'Saint Petersburg', 'Test50', 1357378202); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('f32b9082-5c54-4791-9d57-a711ee81de74', 'Saint Petersburg', 'Test51', 472436539); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('b5e2bbe5-3800-41ef-8d37-d5e72887dcad', 'Samara', 'Test52', 370386460); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('9d20afb4-39ea-44f3-8fe8-3da209b4d81d', 'Samara', 'Test53', 305364209); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('a2e746e1-197d-4861-aa25-f1e0bf960c62', 'Chekhov', 'Test54', 1030443873); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('6c74662d-01c5-49bb-b32c-2ae8b61681f7', 'Moscow', 'Test55', 1051776217); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('c6d7b3a2-9342-4bfa-ace8-d9e30d1fc8aa', 'Saint Petersburg', 'Test56', 1951376849); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('4623b145-1fbd-404c-853a-31993cec1730', 'Saint Petersburg', 'Test57', 242792476); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('cd82fdb6-ebad-4bc6-bfab-4bca22809f2c', 'Moscow', 'Test58', 1305508202); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('2ccaa7d3-9d4e-4b3a-b284-a094f4f81717', 'Beslan', 'Test59', 1555295920); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('47b83039-9cf2-4b14-b5ba-8801701161ae', 'Chekhov', 'Test60', 769750514); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('19092ba4-c555-4a9b-a9e5-cc84f9bc8199', 'Beslan', 'Test61', 591742418); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('307176aa-97f6-445c-953b-7936b7db1553', 'Samara', 'Test62', 325009996); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('e1d95b44-5685-420a-ab19-63c04be59a0a', 'Saint Petersburg', 'Test63', 1564321582); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('818ffd32-faf7-4586-90e4-7c7bbf8840bd', 'Chekhov', 'Test64', 196098059); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('11db7529-0b31-430c-860d-7e419901c317', 'Saint Petersburg', 'Test65', 1359131275); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('a0d1789c-4e98-424f-8fc0-faf2c5e6afec', 'Saint Petersburg', 'Test66', 561293779); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('7c46b4a3-c5ff-4dfb-9018-7eaf77a0fa90', 'Saint Petersburg', 'Test67', 1449797631); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('ff75b4fc-9df3-4366-b8d3-a94369545273', 'Beslan', 'Test68', 253329860); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('d34f4a26-b321-4bc2-b488-26082f295ef7', 'Chekhov', 'Test69', 551424552); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('cffd1f77-240c-4936-8f66-8109ba64d716', 'Chekhov', 'Test70', 1638421288); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('6d18e1e5-2ebe-44f4-8592-f5b8538d61e9', 'Saint Petersburg', 'Test71', 169871414); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('687278b3-04fe-41dc-b225-1d465b8c3fef', 'Moscow', 'Test72', 188352395); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('4845619d-1937-40dd-8f92-11e851ede795', 'Beslan', 'Test73', 1421261442); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('de786d96-40f5-4ccb-912a-ba439e3fe839', 'Chekhov', 'Test74', 1838243970); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('ad18b0a9-cc5f-4f24-b119-15b45fdbd9c9', 'Saint Petersburg', 'Test75', 783851665); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('c7cba617-56ec-44ea-9243-f4e504bd3eb5', 'Saint Petersburg', 'Test76', 2069884557); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('822946f2-5f7b-4194-a923-c37e8126cf4e', 'Saint Petersburg', 'Test77', 1681481016); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('b861067d-06d6-409b-a0da-a9985641b98f', 'Samara', 'Test78', 2063650508); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('346f7c30-039f-4d0b-8979-ecbc80856c15', 'Moscow', 'Test79', 276752940); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('7e625115-3d7d-4b8c-a1e3-bdeeed1a4bc3', 'Chekhov', 'Test80', 1662727246); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('a126879d-03c7-4847-bcfd-ebbb0cf4513f', 'Beslan', 'Test81', 1946359149); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('f8e4b6f4-6391-4cb6-82cf-d8065f4e7814', 'Chekhov', 'Test82', 1429543056); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('3ef42530-4195-427a-8dd8-e707a6a661fa', 'Chekhov', 'Test83', 2112428020); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('91df3bc1-2462-4ad7-b845-6d3684c33eaa', 'Moscow', 'Test84', 856742111); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('48699907-3be0-4086-9140-6616c8142ceb', 'Saint Petersburg', 'Test85', 796839465); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('f5677708-3986-4492-b37a-293ce944e232', 'Saint Petersburg', 'Test86', 387566960); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('b9ded0ee-dc2e-48d0-9eac-acf4750a1638', 'Moscow', 'Test87', 1000892466); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('2e0a646e-3ce3-40fb-b2ab-9eaa17a96c60', 'Saint Petersburg', 'Test88', 1669482943); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('62b290b8-0288-4b33-b994-847c1de78bbe', 'Samara', 'Test89', 1426470131); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('b2571bc1-40b6-4979-ab4c-71b4b47e08a5', 'Saint Petersburg', 'Test90', 303208877); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('f580ce77-efdd-47c7-84ab-993820708bbb', 'Moscow', 'Test91', 465192136); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('24179c62-370e-4bfd-8fe6-5f01b1b0d5c0', 'Samara', 'Test92', 268013358); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('9972b0b0-11b8-4deb-a50b-7376814e8f8a', 'Chekhov', 'Test93', 622130818); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('c0705b3d-c8e0-4df1-b676-fa679d3a376d', 'Moscow', 'Test94', 1028636067); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('56fe5dbf-f1c6-4a68-aaf8-6d7451124ef7', 'Saint Petersburg', 'Test95', 2100354444); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('3b0b0cbe-576c-49f3-a73a-2190d0b99845', 'Beslan', 'Test96', 458496309); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('cc86427c-b011-4c1a-88be-d42e07bb16c6', 'Chekhov', 'Test97', 1123174141); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('a2b4b9e5-4400-4e9f-bf25-f696e3a786f9', 'Beslan', 'Test98', 882248376); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('65a96c81-df09-4dae-acdd-85be995ec025', 'Samara', 'Test99', 2066049382); +INSERT INTO public.cinema (id, location, name, seats_count) VALUES ('fa0632fc-15a2-4e37-a118-d68971107a38', 'Saint Petersburg', 'Test306', 1835377229); \ No newline at end of file diff --git a/wad.sh b/wad.sh index 339e4985e49dbf2bf03ec682600cadc70218debe..5e26110b0f2c36bb06541b4b41edb2c1009c2545 100755 --- a/wad.sh +++ b/wad.sh @@ -1,5 +1,5 @@ #!/bin/bash chmod 777 ./builder.sh while true; do - find . -type f -name '*.java' -o -name '*xml' -o -name '*properties' | entr ./builder.sh + find . \( -name .idea -o -name .m2 -o -name target \) -prune -o -name "*.java" -o -name "*.xml" -o -name "*.scss" -o -name "*.coffee" -o -name "*.jsp" | entr ./builder.sh done