From faebb6396b9d1b213d81607c6e14794e7b891088 Mon Sep 17 00:00:00 2001 From: pankaj Date: Sun, 2 Feb 2025 12:32:57 +0530 Subject: [PATCH 1/3] todo app with (application.property)file added --- .classpath | 51 ++++++++ .factorypath | 71 +++++++++++ .project | 28 +++++ .settings/org.eclipse.core.resources.prefs | 5 + .settings/org.eclipse.jdt.apt.core.prefs | 4 + .settings/org.eclipse.jdt.core.prefs | 10 ++ .settings/org.eclipse.m2e.core.prefs | 4 + .../org.springframework.ide.eclipse.prefs | 2 + pom.xml | 58 +++++++++ src/main/java/com/todo/list/App.java | 19 +++ .../todo/list/controller/ToDoController.java | 75 ++++++++++++ src/main/java/com/todo/list/entity/ToDo.java | 25 ++++ .../todo/list/repository/ToDoRepository.java | 9 ++ src/main/resources/application.properties | 34 ++++++ src/main/resources/templates/index.html | 43 +++++++ src/main/resources/templates/logout.html | 43 +++++++ src/main/resources/templates/todos.html | 111 ++++++++++++++++++ src/test/java/com/todo/list/AppTest.java | 38 ++++++ target/classes/META-INF/MANIFEST.MF | 6 + .../maven/com.todo/list/pom.properties | 7 ++ .../META-INF/maven/com.todo/list/pom.xml | 58 +++++++++ target/classes/application.properties | 34 ++++++ target/classes/com/todo/list/App.class | Bin 0 -> 868 bytes .../todo/list/controller/ToDoController.class | Bin 0 -> 3032 bytes .../classes/com/todo/list/entity/ToDo.class | Bin 0 -> 2867 bytes .../todo/list/repository/ToDoRepository.class | Bin 0 -> 336 bytes target/classes/templates/index.html | 43 +++++++ target/classes/templates/logout.html | 43 +++++++ target/classes/templates/todos.html | 111 ++++++++++++++++++ .../test-classes/com/todo/list/AppTest.class | Bin 0 -> 643 bytes 30 files changed, 932 insertions(+) create mode 100644 .classpath create mode 100644 .factorypath create mode 100644 .project create mode 100644 .settings/org.eclipse.core.resources.prefs create mode 100644 .settings/org.eclipse.jdt.apt.core.prefs create mode 100644 .settings/org.eclipse.jdt.core.prefs create mode 100644 .settings/org.eclipse.m2e.core.prefs create mode 100644 .settings/org.springframework.ide.eclipse.prefs create mode 100644 pom.xml create mode 100644 src/main/java/com/todo/list/App.java create mode 100644 src/main/java/com/todo/list/controller/ToDoController.java create mode 100644 src/main/java/com/todo/list/entity/ToDo.java create mode 100644 src/main/java/com/todo/list/repository/ToDoRepository.java create mode 100644 src/main/resources/application.properties create mode 100644 src/main/resources/templates/index.html create mode 100644 src/main/resources/templates/logout.html create mode 100644 src/main/resources/templates/todos.html create mode 100644 src/test/java/com/todo/list/AppTest.java create mode 100644 target/classes/META-INF/MANIFEST.MF create mode 100644 target/classes/META-INF/maven/com.todo/list/pom.properties create mode 100644 target/classes/META-INF/maven/com.todo/list/pom.xml create mode 100644 target/classes/application.properties create mode 100644 target/classes/com/todo/list/App.class create mode 100644 target/classes/com/todo/list/controller/ToDoController.class create mode 100644 target/classes/com/todo/list/entity/ToDo.class create mode 100644 target/classes/com/todo/list/repository/ToDoRepository.class create mode 100644 target/classes/templates/index.html create mode 100644 target/classes/templates/logout.html create mode 100644 target/classes/templates/todos.html create mode 100644 target/test-classes/com/todo/list/AppTest.class diff --git a/.classpath b/.classpath new file mode 100644 index 00000000..6fe96f98 --- /dev/null +++ b/.classpath @@ -0,0 +1,51 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/.factorypath b/.factorypath new file mode 100644 index 00000000..efc4cd14 --- /dev/null +++ b/.factorypath @@ -0,0 +1,71 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/.project b/.project new file mode 100644 index 00000000..5514a0c2 --- /dev/null +++ b/.project @@ -0,0 +1,28 @@ + + + list + + + + + + org.eclipse.jdt.core.javabuilder + + + + + org.springframework.ide.eclipse.boot.validation.springbootbuilder + + + + + org.eclipse.m2e.core.maven2Builder + + + + + + org.eclipse.jdt.core.javanature + org.eclipse.m2e.core.maven2Nature + + diff --git a/.settings/org.eclipse.core.resources.prefs b/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 00000000..839d647e --- /dev/null +++ b/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,5 @@ +eclipse.preferences.version=1 +encoding//src/main/java=UTF-8 +encoding//src/main/resources=UTF-8 +encoding//src/test/java=UTF-8 +encoding/=UTF-8 diff --git a/.settings/org.eclipse.jdt.apt.core.prefs b/.settings/org.eclipse.jdt.apt.core.prefs new file mode 100644 index 00000000..dfa4f3ad --- /dev/null +++ b/.settings/org.eclipse.jdt.apt.core.prefs @@ -0,0 +1,4 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.apt.aptEnabled=true +org.eclipse.jdt.apt.genSrcDir=target/generated-sources/annotations +org.eclipse.jdt.apt.genTestSrcDir=target/generated-test-sources/test-annotations diff --git a/.settings/org.eclipse.jdt.core.prefs b/.settings/org.eclipse.jdt.core.prefs new file mode 100644 index 00000000..3cba0a0c --- /dev/null +++ b/.settings/org.eclipse.jdt.core.prefs @@ -0,0 +1,10 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.core.compiler.codegen.methodParameters=generate +org.eclipse.jdt.core.compiler.codegen.targetPlatform=17 +org.eclipse.jdt.core.compiler.compliance=17 +org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled +org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning +org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=ignore +org.eclipse.jdt.core.compiler.processAnnotations=enabled +org.eclipse.jdt.core.compiler.release=enabled +org.eclipse.jdt.core.compiler.source=17 diff --git a/.settings/org.eclipse.m2e.core.prefs b/.settings/org.eclipse.m2e.core.prefs new file mode 100644 index 00000000..f897a7f1 --- /dev/null +++ b/.settings/org.eclipse.m2e.core.prefs @@ -0,0 +1,4 @@ +activeProfiles= +eclipse.preferences.version=1 +resolveWorkspaceProjects=true +version=1 diff --git a/.settings/org.springframework.ide.eclipse.prefs b/.settings/org.springframework.ide.eclipse.prefs new file mode 100644 index 00000000..a12794d6 --- /dev/null +++ b/.settings/org.springframework.ide.eclipse.prefs @@ -0,0 +1,2 @@ +boot.validation.initialized=true +eclipse.preferences.version=1 diff --git a/pom.xml b/pom.xml new file mode 100644 index 00000000..2c50e616 --- /dev/null +++ b/pom.xml @@ -0,0 +1,58 @@ + + 4.0.0 + + org.springframework.boot + spring-boot-starter-parent + 3.4.2 + + + + com.todo + list + 0.0.1-SNAPSHOT + jar + + list + http://maven.apache.org + + + UTF-8 + + + + + + org.springframework.boot + spring-boot-starter-web + + + org.springframework.boot + spring-boot-devtools + + + org.springframework.boot + spring-boot-starter-thymeleaf + + + + com.h2database + h2 + runtime + + + org.springframework.boot + spring-boot-starter-data-jpa + + + org.projectlombok + lombok + + + junit + junit + test + + + + diff --git a/src/main/java/com/todo/list/App.java b/src/main/java/com/todo/list/App.java new file mode 100644 index 00000000..a6bcf4f8 --- /dev/null +++ b/src/main/java/com/todo/list/App.java @@ -0,0 +1,19 @@ +package com.todo.list; + +import org.springframework.boot.SpringApplication; +import org.springframework.boot.autoconfigure.SpringBootApplication; + +/** + * Hello world! + * + */ + +@SpringBootApplication +public class App +{ + public static void main( String[] args ) + { + SpringApplication.run(App.class, args); + System.out.println( "ToDO List Aplication is live" ); + } +} diff --git a/src/main/java/com/todo/list/controller/ToDoController.java b/src/main/java/com/todo/list/controller/ToDoController.java new file mode 100644 index 00000000..5879639c --- /dev/null +++ b/src/main/java/com/todo/list/controller/ToDoController.java @@ -0,0 +1,75 @@ +package com.todo.list.controller; + +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Controller; +import org.springframework.ui.Model; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.RequestParam; +import org.springframework.web.bind.annotation.RestController; + +import com.todo.list.entity.ToDo; +import com.todo.list.repository.ToDoRepository; + +//@RestController +@Controller +public class ToDoController { + + @Autowired + private ToDoRepository toDoRepository; + + @GetMapping("") + public String index() { + return "index"; + } + + @GetMapping("/logout") + public String logoutPage() { + return "logout"; + } + + + @GetMapping("/todos") + public String todos(Model model){ + model.addAttribute("todos", toDoRepository.findAll()); + return "todos"; + } + + + + @PostMapping("/todo") + public String add(@RequestParam String todoItem,@RequestParam String status,Model model) { + + ToDo toDo=new ToDo(); + toDo.setTodoItem(todoItem); + toDo.setCompleted(status); + toDoRepository.save(toDo); + model.addAttribute("todos", toDoRepository.findAll()); + return "redirect:/todos"; + + } + @PostMapping("/todoDelete/{id}") + public String delete(@PathVariable long id, Model model){ + toDoRepository.deleteById(id); + model.addAttribute("todos", toDoRepository.findAll()); + + return "redirect:/todos"; + } + + @PostMapping("/todoUpdate/{id}") + public String update(@PathVariable long id, Model model){ + ToDo toDo = toDoRepository.findById(id).get(); + if("Yes".equals(toDo.getCompleted())){ + toDo.setCompleted("No"); + } else { + toDo.setCompleted("Yes"); + } + toDoRepository.save(toDo); + model.addAttribute("todos", toDoRepository.findAll()); + return "redirect:/todos"; + } + + + +} diff --git a/src/main/java/com/todo/list/entity/ToDo.java b/src/main/java/com/todo/list/entity/ToDo.java new file mode 100644 index 00000000..52719e48 --- /dev/null +++ b/src/main/java/com/todo/list/entity/ToDo.java @@ -0,0 +1,25 @@ +package com.todo.list.entity; + +import jakarta.persistence.Entity; +import jakarta.persistence.GeneratedValue; +import jakarta.persistence.GenerationType; +import jakarta.persistence.Id; +import lombok.AllArgsConstructor; +import lombok.Data; +import lombok.NoArgsConstructor; + +@Entity +@Data +@NoArgsConstructor +@AllArgsConstructor +public class ToDo { + + @Id + @GeneratedValue(strategy = GenerationType.AUTO) + private long id; + private String todoItem; + private String completed; + + + +} diff --git a/src/main/java/com/todo/list/repository/ToDoRepository.java b/src/main/java/com/todo/list/repository/ToDoRepository.java new file mode 100644 index 00000000..40e63a64 --- /dev/null +++ b/src/main/java/com/todo/list/repository/ToDoRepository.java @@ -0,0 +1,9 @@ +package com.todo.list.repository; + +import org.springframework.data.jpa.repository.JpaRepository; + +import com.todo.list.entity.ToDo; + +public interface ToDoRepository extends JpaRepository { + +} diff --git a/src/main/resources/application.properties b/src/main/resources/application.properties new file mode 100644 index 00000000..e309d17e --- /dev/null +++ b/src/main/resources/application.properties @@ -0,0 +1,34 @@ +spring.application.name=ecommerce + + +spring.datasource.url=jdbc:h2:mem:todo_db +spring.datasource.driverClassName=org.h2.Driver +spring.datasource.username=sa +spring.datasource.password= +spring.jpa.database-platform=org.hibernate.dialect.H2Dialect + +# Enable H2 Console (for debugging) +spring.h2.console.enabled=true +spring.h2.console.path=/h2-console + +#logging.level.org.springframework.web=DEBUG +#logging.level.org.springframework.boot=DEBUG + +springdoc.api-docs.enabled=true +springdoc.swagger-ui.enabled=true + + +#spring.datasource.url=jdbc:mysql://localhost:3306/your_database +#spring.datasource.username=root +#spring.datasource.password=your_password +#spring.jpa.hibernate.ddl-auto=update +#spring.jpa.show-sql=true +#spring.jpa.properties.hibernate.format_sql=true + + +#spring.datasource.url=jdbc://mysql://localhost:3306/shop +# +#spring.datasource.username=root +#spring.datasource.password=1234 +#spring.jpa.hibernate.ddl-auto=update +#spring.jpa.show-sql=true diff --git a/src/main/resources/templates/index.html b/src/main/resources/templates/index.html new file mode 100644 index 00000000..3eef3df9 --- /dev/null +++ b/src/main/resources/templates/index.html @@ -0,0 +1,43 @@ + + + + + + + Index Page + + + + + +
+

Welcome to Todo Manager

+
+
+
+ +
+
+
+ +
+ + + + + \ No newline at end of file diff --git a/src/main/resources/templates/logout.html b/src/main/resources/templates/logout.html new file mode 100644 index 00000000..5e032991 --- /dev/null +++ b/src/main/resources/templates/logout.html @@ -0,0 +1,43 @@ + + + + + + + Index Page + + + + + +
+

You come again todo manager page

+
+
+
+ +
+
+
+ +
+ + + + + \ No newline at end of file diff --git a/src/main/resources/templates/todos.html b/src/main/resources/templates/todos.html new file mode 100644 index 00000000..e3d3e5e4 --- /dev/null +++ b/src/main/resources/templates/todos.html @@ -0,0 +1,111 @@ + + + + + + + Index Page + + + + + +
+
+
+
+ + + + + + + + + + + + + + + + + + + +
IdTodoStatusUpdateDelete
+
+
+ +
+
+
+
+
+ +
+
+
+ +
+
+
+ + + +
+ + + + + \ No newline at end of file diff --git a/src/test/java/com/todo/list/AppTest.java b/src/test/java/com/todo/list/AppTest.java new file mode 100644 index 00000000..e0e6f3e6 --- /dev/null +++ b/src/test/java/com/todo/list/AppTest.java @@ -0,0 +1,38 @@ +package com.todo.list; + +import junit.framework.Test; +import junit.framework.TestCase; +import junit.framework.TestSuite; + +/** + * Unit test for simple App. + */ +public class AppTest + extends TestCase +{ + /** + * Create the test case + * + * @param testName name of the test case + */ + public AppTest( String testName ) + { + super( testName ); + } + + /** + * @return the suite of tests being tested + */ + public static Test suite() + { + return new TestSuite( AppTest.class ); + } + + /** + * Rigourous Test :-) + */ + public void testApp() + { + assertTrue( true ); + } +} diff --git a/target/classes/META-INF/MANIFEST.MF b/target/classes/META-INF/MANIFEST.MF new file mode 100644 index 00000000..7c75ad69 --- /dev/null +++ b/target/classes/META-INF/MANIFEST.MF @@ -0,0 +1,6 @@ +Manifest-Version: 1.0 +Build-Jdk-Spec: 17 +Implementation-Title: list +Implementation-Version: 0.0.1-SNAPSHOT +Created-By: Maven Integration for Eclipse + diff --git a/target/classes/META-INF/maven/com.todo/list/pom.properties b/target/classes/META-INF/maven/com.todo/list/pom.properties new file mode 100644 index 00000000..9439e4fd --- /dev/null +++ b/target/classes/META-INF/maven/com.todo/list/pom.properties @@ -0,0 +1,7 @@ +#Generated by Maven Integration for Eclipse +#Sun Feb 02 11:39:13 IST 2025 +m2e.projectLocation=C\:\\Users\\admin\\OneDrive\\Documents\\Projetcs\\CustomerProductManagement\\list +m2e.projectName=list +groupId=com.todo +artifactId=list +version=0.0.1-SNAPSHOT diff --git a/target/classes/META-INF/maven/com.todo/list/pom.xml b/target/classes/META-INF/maven/com.todo/list/pom.xml new file mode 100644 index 00000000..2c50e616 --- /dev/null +++ b/target/classes/META-INF/maven/com.todo/list/pom.xml @@ -0,0 +1,58 @@ + + 4.0.0 + + org.springframework.boot + spring-boot-starter-parent + 3.4.2 + + + + com.todo + list + 0.0.1-SNAPSHOT + jar + + list + http://maven.apache.org + + + UTF-8 + + + + + + org.springframework.boot + spring-boot-starter-web + + + org.springframework.boot + spring-boot-devtools + + + org.springframework.boot + spring-boot-starter-thymeleaf + + + + com.h2database + h2 + runtime + + + org.springframework.boot + spring-boot-starter-data-jpa + + + org.projectlombok + lombok + + + junit + junit + test + + + + diff --git a/target/classes/application.properties b/target/classes/application.properties new file mode 100644 index 00000000..e309d17e --- /dev/null +++ b/target/classes/application.properties @@ -0,0 +1,34 @@ +spring.application.name=ecommerce + + +spring.datasource.url=jdbc:h2:mem:todo_db +spring.datasource.driverClassName=org.h2.Driver +spring.datasource.username=sa +spring.datasource.password= +spring.jpa.database-platform=org.hibernate.dialect.H2Dialect + +# Enable H2 Console (for debugging) +spring.h2.console.enabled=true +spring.h2.console.path=/h2-console + +#logging.level.org.springframework.web=DEBUG +#logging.level.org.springframework.boot=DEBUG + +springdoc.api-docs.enabled=true +springdoc.swagger-ui.enabled=true + + +#spring.datasource.url=jdbc:mysql://localhost:3306/your_database +#spring.datasource.username=root +#spring.datasource.password=your_password +#spring.jpa.hibernate.ddl-auto=update +#spring.jpa.show-sql=true +#spring.jpa.properties.hibernate.format_sql=true + + +#spring.datasource.url=jdbc://mysql://localhost:3306/shop +# +#spring.datasource.username=root +#spring.datasource.password=1234 +#spring.jpa.hibernate.ddl-auto=update +#spring.jpa.show-sql=true diff --git a/target/classes/com/todo/list/App.class b/target/classes/com/todo/list/App.class new file mode 100644 index 0000000000000000000000000000000000000000..c8fddb1de06e0fa2894ac3ba763e551518a6e022 GIT binary patch literal 868 zcmZva-%=AX6vn?m%eJ*bTP%vA7XP+&#yr3(Gf>B?RT#^Z3$M~`D8b#NvztYIEWJ?2 z3m?FTay*F)l(83^?8%?+obPw?`_Io`0AAu*fF*`zY*KE`#PCGrmhaAH0ZI&wQ*kDE zBJ`B+k56T68CG5>t?UlNaaQ0){qIdK&gdH8imvpvBNP*_7uqw|<<7RDLws z2R=5&@}XZO8;OdARYuow18pigD@b_Uozop8BG1D`nW9DVvC&q3vV36lv6>c{^E8)- zmfdz(#Z7DmxOIi$@N;fuTE}hNp;AmiINSd!QHCFo4NE4aNW%*5GHe~1SNola`qA0F z@X=9uCsAjF{64k=bO@nGbXA~^2YAR3I0`l)$L)E?7bJ$%gNorN5In?zv^0reo|dDHf& ze{(=XY=dCYTLqTrj~*F~0Y#il9V7iZv2(m-oCF z&}gy#4>XRxVxzV74fif}R(;Y2oo>>t)|_4gkMNi@p3qlj6u8Qs`mu{1&8~z#@E4K< B+e`oe literal 0 HcmV?d00001 diff --git a/target/classes/com/todo/list/controller/ToDoController.class b/target/classes/com/todo/list/controller/ToDoController.class new file mode 100644 index 0000000000000000000000000000000000000000..926a7db871ac29395a9a60dcec9723d1c02ea52d GIT binary patch literal 3032 zcma)8ZBr9h6n<_JNC*qkpw{?O6s-mj*ZKlVd_zzx4MHJewXd6G39FlI%x*xY(;w2A ze(%?Irh}!O>GWG?`kOkPKKE|eB(P9FWOwhq=brmK=RD`!{Qd85e*n0R%{U?g7m7|r z_neZW+m`F;MW^c39oshRdfu6JW`bcHF@b@X#=4=~MzyRj6keJ|PoUqU*^*gvT+4In zn*t-bPLK6qO?hmYW(CqqjjCr=%oWSE3br|2tva6JSx(gzxRG<}W!Q7M@9yuot?QaPt+*egcelH=xN%v-YvWH+IGL&TH2tZK=8BXBq~l553k*^?x= zd@YpIhFQ=H+}KX%k?GAFwVJ=JYu&ILM2Q4a0!iB`I}LBqD03>V`=bO-khlL$7&4)R zekBunV8hbq84^1i3bI?t!A;;~4+PF==t6fd&f>#3&h635zS-4q9v6sjmBglPn<3r_ zNyD>jJx8%+dohBsI7S6dhUIz(riP0c7toASY1(5b3k{FVXES>v+&1IulMD~?EHhS- zkr4Rc{|pD_O>fO9EgDjbo>^yjqeLXIaxjo)@(*?&nuzP6d&1PR=(z22Q3(_n?yRl= zc}JN|yz?PT=Ie&(Qg;kMHjW!C-_A-mSFTiGN&#c~`=?8>c3A^&q*mp9jh8vQDzmEP2NMD9XCk7#r5Z=E2Z^HgN;E-i}r!E zlBl8<2XowZxA{8I@EUcJqwEcvS_lopiv)Ohwu&(I!mhO)FDUxO-;<)j!PoP0Hi%Qal*`k^Q%CX}IkLc#fg zaJu+C@jE7;zs1d|SUNVgg{gGx;uh{mfa%yarXzSZz8CL<7T)7b7hV4Qd_5uZ*K zT*g&`k}16ApAz7oz$1LD(lmj`{E{J=P@JO5#~eN(70IqIN>k7XO_n*#hq8R4SoTEd zb%Dk{zcuoU@q1WO8Tu8A+gOR6Jo~_0Gi$zC+^}jMJzGxMDwZl^3WFVwu3C;&GkvSFY*yFjHD6!9Z`GDemM9+GvRPd=YqsngLd{>bS#$sF|6<9o z-3+zV%dQm;7yzo*;xax;RwgY-QA3aUsmJ#t5!`RB@hnobgn0mw+aG|7z3s>ZacO=8RWez zdCwV`!G{XDJvwE7lZ$S>R<^F#GPYep=+i<5P8gGDr{;7(e9me5lI!}yy^V0Pyd;*e z9LG)aaEDE{v+1r`#SoCN{wrqLcWYY$%q@j)TgR@U9Xh;bI+d#B4bHmmT76@z9g-Hw zF2jK4Er$(8-)RwT&ufdQ;bO|HRu^sG8taW=F@f6(ZwMwiyE37MPizmKteY*LP(!3i z$>GH`RW&`&^5VFwaIy`BPIblcxx%rRtFqA{2pAw&q8zIzB69O^7w2vtcL~0Q{z(hn zFeu>dKv6_41HKI&k$?P`sVq{i_}25kVE>PST897PPgD;E|A7Jy;V^f+#Bro)Og>O1 z#{EBW5y7jB$?Xot$M$A?f>lR?v`1ODR3FP9e~kS8A)x2!^(UZ+$ip@{-p ziovGKNNA8RJVyUsT?)1e4VS6F<;l)2kL}f^w5jQ`H*m?jG0aj$p#_cJEaZQHu01OJ z0rfrf=%d2#P;+e+FaLKki8@wG6cCeWKWhqqZm1}5I&&_r++m+>xTQJlvl z-s4KcO*Zp9S32&X9~ZcaVU+#{kc=n(Mo%0n^&AJ|i1L?E&v7_hb~Uj%M{G3tz%)8| zfib1!x_~07wvS^t6M8dMoe4^+jRw9Gpw0W9B4Ni1<|MRQNRN$c6N2fbqv^5Lfr0di zFTeWwo=8SUbrA_>iFDy15?TETCW0eE863r$M?{iGM?1qf$zTlC$SsOlypIogT&&7(AhGGhx= gh~RoK3u5>Y_c!WC!ArhJqn-VGu%V=U-0G{IRF3v literal 0 HcmV?d00001 diff --git a/target/classes/com/todo/list/repository/ToDoRepository.class b/target/classes/com/todo/list/repository/ToDoRepository.class new file mode 100644 index 0000000000000000000000000000000000000000..fc864a5a4b349386c27bc2eebbd20f498f0795a4 GIT binary patch literal 336 zcmbV|O>V+K3`W0!LI`XsaR_$xs;d-M6$=!pQsDw_n2sh*#?fQ|aWxhkfJ31Mkof7c z3)`|}eNWGa<8BXNj6sB!!YGrHf-Hp!TL<#GlG+CGTUyAwd|uZGPYTaDubB#VhCaS> zorMTpg;(*0>dISZzCD+EBmRe$9GLQo?-OSg-vSl-b6NRJPi>(UhL5l*|I(B6U*xy+(OJ7-!^JnbW2E9tGD#Xig?3Y&=4(I;(Yf~!pJ)FUIALob literal 0 HcmV?d00001 diff --git a/target/classes/templates/index.html b/target/classes/templates/index.html new file mode 100644 index 00000000..3eef3df9 --- /dev/null +++ b/target/classes/templates/index.html @@ -0,0 +1,43 @@ + + + + + + + Index Page + + + + + +
+

Welcome to Todo Manager

+
+
+
+ +
+
+
+ +
+ + + + + \ No newline at end of file diff --git a/target/classes/templates/logout.html b/target/classes/templates/logout.html new file mode 100644 index 00000000..5e032991 --- /dev/null +++ b/target/classes/templates/logout.html @@ -0,0 +1,43 @@ + + + + + + + Index Page + + + + + +
+

You come again todo manager page

+
+
+
+ +
+
+
+ +
+ + + + + \ No newline at end of file diff --git a/target/classes/templates/todos.html b/target/classes/templates/todos.html new file mode 100644 index 00000000..e3d3e5e4 --- /dev/null +++ b/target/classes/templates/todos.html @@ -0,0 +1,111 @@ + + + + + + + Index Page + + + + + +
+
+
+
+ + + + + + + + + + + + + + + + + + + +
IdTodoStatusUpdateDelete
+
+
+ +
+
+
+
+
+ +
+
+
+ +
+
+
+ + + +
+ + + + + \ No newline at end of file diff --git a/target/test-classes/com/todo/list/AppTest.class b/target/test-classes/com/todo/list/AppTest.class new file mode 100644 index 0000000000000000000000000000000000000000..7ff9a2da96ab6c5739b2aa85f65b2814be08a68d GIT binary patch literal 643 zcmZuuO;5r=5Pb`!)mlXn@cS##1T?V+k0^;D@l=foghX#Etgu?B*>3f3=}DuBKfoVl zoP{2Ya@pOPdGqGI*{|>SPXH&_c93Bxb)tcd-!$V8N+JVKee3uNR_HPv* zh^I*1`=-+1v0$)|C6(&bUJ35_Blkl-?Due5egGCsfDZrw literal 0 HcmV?d00001 From 5d81b07736d7a1bb4f460f652986f8f07ea4bc97 Mon Sep 17 00:00:00 2001 From: pankaj Date: Sun, 2 Feb 2025 13:23:20 +0530 Subject: [PATCH 2/3] added application.property file --- src/main/resources/application.properties | 21 +-------------------- target/classes/application.properties | 21 +-------------------- 2 files changed, 2 insertions(+), 40 deletions(-) diff --git a/src/main/resources/application.properties b/src/main/resources/application.properties index e309d17e..8ad565ef 100644 --- a/src/main/resources/application.properties +++ b/src/main/resources/application.properties @@ -1,4 +1,4 @@ -spring.application.name=ecommerce +spring.application.name=todo spring.datasource.url=jdbc:h2:mem:todo_db @@ -13,22 +13,3 @@ spring.h2.console.path=/h2-console #logging.level.org.springframework.web=DEBUG #logging.level.org.springframework.boot=DEBUG - -springdoc.api-docs.enabled=true -springdoc.swagger-ui.enabled=true - - -#spring.datasource.url=jdbc:mysql://localhost:3306/your_database -#spring.datasource.username=root -#spring.datasource.password=your_password -#spring.jpa.hibernate.ddl-auto=update -#spring.jpa.show-sql=true -#spring.jpa.properties.hibernate.format_sql=true - - -#spring.datasource.url=jdbc://mysql://localhost:3306/shop -# -#spring.datasource.username=root -#spring.datasource.password=1234 -#spring.jpa.hibernate.ddl-auto=update -#spring.jpa.show-sql=true diff --git a/target/classes/application.properties b/target/classes/application.properties index e309d17e..8ad565ef 100644 --- a/target/classes/application.properties +++ b/target/classes/application.properties @@ -1,4 +1,4 @@ -spring.application.name=ecommerce +spring.application.name=todo spring.datasource.url=jdbc:h2:mem:todo_db @@ -13,22 +13,3 @@ spring.h2.console.path=/h2-console #logging.level.org.springframework.web=DEBUG #logging.level.org.springframework.boot=DEBUG - -springdoc.api-docs.enabled=true -springdoc.swagger-ui.enabled=true - - -#spring.datasource.url=jdbc:mysql://localhost:3306/your_database -#spring.datasource.username=root -#spring.datasource.password=your_password -#spring.jpa.hibernate.ddl-auto=update -#spring.jpa.show-sql=true -#spring.jpa.properties.hibernate.format_sql=true - - -#spring.datasource.url=jdbc://mysql://localhost:3306/shop -# -#spring.datasource.username=root -#spring.datasource.password=1234 -#spring.jpa.hibernate.ddl-auto=update -#spring.jpa.show-sql=true From 7064139e7dc8d63c33ee0648455828b056f048de Mon Sep 17 00:00:00 2001 From: pankaj Date: Sun, 2 Feb 2025 13:29:42 +0530 Subject: [PATCH 3/3] updated application.property file --- src/main/resources/application.properties | 3 --- target/classes/application.properties | 3 --- 2 files changed, 6 deletions(-) diff --git a/src/main/resources/application.properties b/src/main/resources/application.properties index 8ad565ef..e2b41c44 100644 --- a/src/main/resources/application.properties +++ b/src/main/resources/application.properties @@ -10,6 +10,3 @@ spring.jpa.database-platform=org.hibernate.dialect.H2Dialect # Enable H2 Console (for debugging) spring.h2.console.enabled=true spring.h2.console.path=/h2-console - -#logging.level.org.springframework.web=DEBUG -#logging.level.org.springframework.boot=DEBUG diff --git a/target/classes/application.properties b/target/classes/application.properties index 8ad565ef..e2b41c44 100644 --- a/target/classes/application.properties +++ b/target/classes/application.properties @@ -10,6 +10,3 @@ spring.jpa.database-platform=org.hibernate.dialect.H2Dialect # Enable H2 Console (for debugging) spring.h2.console.enabled=true spring.h2.console.path=/h2-console - -#logging.level.org.springframework.web=DEBUG -#logging.level.org.springframework.boot=DEBUG