build_app
This commit is contained in:
parent
d903e72f4a
commit
f780eac5bf
@ -69,6 +69,9 @@ public class BuilderService {
|
|||||||
executeDump(true);
|
executeDump(true);
|
||||||
|
|
||||||
// ADD OTHER SERVICE
|
// ADD OTHER SERVICE
|
||||||
|
addCustomMenu( "Note","Note", "Transcations");
|
||||||
|
|
||||||
|
|
||||||
addCustomMenu( "Notesappwireframe","Notesappwireframe", "Transcations");
|
addCustomMenu( "Notesappwireframe","Notesappwireframe", "Transcations");
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -20,6 +20,8 @@ import com.realnet.app-b.Services.NoteService ;
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@RequestMapping(value = "/Note")
|
@RequestMapping(value = "/Note")
|
||||||
@CrossOrigin("*")
|
@CrossOrigin("*")
|
||||||
@RestController
|
@RestController
|
||||||
@ -34,12 +36,16 @@ public class NoteController {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@PostMapping("/Note")
|
@PostMapping("/Note")
|
||||||
public Note Savedata(@RequestBody Note data) {
|
public Note Savedata(@RequestBody Note data) {
|
||||||
Note save = Service.Savedata(data) ;
|
Note save = Service.Savedata(data) ;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
System.out.println("data saved..." + save);
|
System.out.println("data saved..." + save);
|
||||||
|
|
||||||
return save;
|
return save;
|
||||||
@ -88,4 +94,6 @@ public class NoteController {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -20,6 +20,8 @@ import com.realnet.app-b.Services.NoteService ;
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@RequestMapping(value = "/token/Note")
|
@RequestMapping(value = "/token/Note")
|
||||||
@CrossOrigin("*")
|
@CrossOrigin("*")
|
||||||
@RestController
|
@RestController
|
||||||
@ -34,12 +36,16 @@ public class tokenFree_NoteController {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@PostMapping("/Note")
|
@PostMapping("/Note")
|
||||||
public Note Savedata(@RequestBody Note data) {
|
public Note Savedata(@RequestBody Note data) {
|
||||||
Note save = Service.Savedata(data) ;
|
Note save = Service.Savedata(data) ;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
System.out.println("data saved..." + save);
|
System.out.println("data saved..." + save);
|
||||||
|
|
||||||
return save;
|
return save;
|
||||||
@ -88,4 +94,6 @@ public class tokenFree_NoteController {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -8,6 +8,8 @@ import com.realnet.WhoColumn.Entity.Extension;
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Data
|
@Data
|
||||||
public class Note extends Extension {
|
public class Note extends Extension {
|
||||||
@ -24,5 +26,7 @@ private String title;
|
|||||||
|
|
||||||
private String content;
|
private String content;
|
||||||
|
|
||||||
|
private String createdat;
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -15,6 +15,8 @@ import java.util.*;
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
import com.realnet.app-b.Entity.Note;
|
import com.realnet.app-b.Entity.Note;
|
||||||
|
|
||||||
@Repository
|
@Repository
|
||||||
|
|||||||
@ -16,6 +16,8 @@ import com.realnet.users.entity1.AppUser;
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
@Service
|
@Service
|
||||||
@ -29,11 +31,15 @@ private NoteRepository Repository;
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public Note Savedata(Note data) {
|
public Note Savedata(Note data) {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
data.setUpdatedBy(getUser().getUserId());
|
data.setUpdatedBy(getUser().getUserId());
|
||||||
data.setCreatedBy(getUser().getUserId());
|
data.setCreatedBy(getUser().getUserId());
|
||||||
data.setAccountId(getUser().getAccount().getAccount_id());
|
data.setAccountId(getUser().getAccount().getAccount_id());
|
||||||
@ -69,6 +75,8 @@ old.setTitle(data.getTitle());
|
|||||||
|
|
||||||
old.setContent(data.getContent());
|
old.setContent(data.getContent());
|
||||||
|
|
||||||
|
old.setCreatedat(data.getCreatedat());
|
||||||
|
|
||||||
final Note test = Repository.save(old);
|
final Note test = Repository.save(old);
|
||||||
data.setUpdatedBy(getUser().getUserId());
|
data.setUpdatedBy(getUser().getUserId());
|
||||||
return test;}
|
return test;}
|
||||||
@ -76,6 +84,8 @@ final Note test = Repository.save(old);
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public AppUser getUser() {
|
public AppUser getUser() {
|
||||||
AppUser user = userService.getLoggedInUser();
|
AppUser user = userService.getLoggedInUser();
|
||||||
return user;
|
return user;
|
||||||
|
|||||||
@ -1,4 +1,2 @@
|
|||||||
CREATE TABLE app-d.Note(id BIGINT NOT NULL AUTO_INCREMENT, title VARCHAR(400), content VARCHAR(400), PRIMARY KEY (id));
|
CREATE TABLE app-d.Note(id BIGINT NOT NULL AUTO_INCREMENT, content VARCHAR(400), createdat Date, title VARCHAR(400), PRIMARY KEY (id));
|
||||||
|
|
||||||
CREATE TABLE app-d.Notesappwireframe(id BIGINT NOT NULL AUTO_INCREMENT, createdat Date, notecontent VARCHAR(400), notetitle VARCHAR(400), PRIMARY KEY (id));
|
|
||||||
|
|
||||||
|
|||||||
@ -23,11 +23,15 @@
|
|||||||
<div *ngIf="error;else loadingSpinner">{{error}}</div>
|
<div *ngIf="error;else loadingSpinner">{{error}}</div>
|
||||||
</clr-dg-placeholder>
|
</clr-dg-placeholder>
|
||||||
|
|
||||||
<clr-dg-column [clrDgField]="'title'"> <ng-container *clrDgHideableColumn="{hidden: false}"> title
|
<clr-dg-column [clrDgField]="'title'"> <ng-container *clrDgHideableColumn="{hidden: false}"> Title
|
||||||
</ng-container></clr-dg-column>
|
</ng-container></clr-dg-column>
|
||||||
|
|
||||||
|
|
||||||
<clr-dg-column [clrDgField]="'content'"> <ng-container *clrDgHideableColumn="{hidden: false}"> content
|
<clr-dg-column [clrDgField]="'content'"> <ng-container *clrDgHideableColumn="{hidden: false}"> Content
|
||||||
|
</ng-container></clr-dg-column>
|
||||||
|
|
||||||
|
|
||||||
|
<clr-dg-column [clrDgField]="'createdat'"> <ng-container *clrDgHideableColumn="{hidden: false}"> CreatedAt
|
||||||
</ng-container></clr-dg-column>
|
</ng-container></clr-dg-column>
|
||||||
|
|
||||||
|
|
||||||
@ -45,6 +49,9 @@
|
|||||||
<clr-dg-cell>{{user.content }}</clr-dg-cell>
|
<clr-dg-cell>{{user.content }}</clr-dg-cell>
|
||||||
|
|
||||||
|
|
||||||
|
<clr-dg-cell>{{user.createdat }}</clr-dg-cell>
|
||||||
|
|
||||||
|
|
||||||
<!-- who column -->
|
<!-- who column -->
|
||||||
<clr-dg-cell>
|
<clr-dg-cell>
|
||||||
<clr-signpost>
|
<clr-signpost>
|
||||||
@ -200,6 +207,8 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- // EDIT DATA......... -->
|
<!-- // EDIT DATA......... -->
|
||||||
<clr-modal [(clrModalOpen)]="modalEdit" [clrModalSize]="'lg'" [clrModalStaticBackdrop]="true">
|
<clr-modal [(clrModalOpen)]="modalEdit" [clrModalSize]="'lg'" [clrModalStaticBackdrop]="true">
|
||||||
<h3 class="modal-title">Update Note
|
<h3 class="modal-title">Update Note
|
||||||
@ -207,6 +216,8 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</h3>
|
</h3>
|
||||||
<div class="modal-body" *ngIf="rowSelected.id">
|
<div class="modal-body" *ngIf="rowSelected.id">
|
||||||
<h2 class="heading">{{rowSelected.id}}</h2>
|
<h2 class="heading">{{rowSelected.id}}</h2>
|
||||||
@ -214,17 +225,24 @@
|
|||||||
<form >
|
<form >
|
||||||
<div class="clr-row">
|
<div class="clr-row">
|
||||||
<div class="clr-col-sm-12">
|
<div class="clr-col-sm-12">
|
||||||
<label>title</label>
|
<label>Title</label>
|
||||||
<input class="clr-input" type="text" [(ngModel)]="rowSelected.title" name="title" />
|
<input class="clr-input" type="text" [(ngModel)]="rowSelected.title" name="title" />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="clr-col-sm-12">
|
<div class="clr-col-sm-12">
|
||||||
<label>content</label>
|
<label>Content</label>
|
||||||
<input class="clr-input" type="text" [(ngModel)]="rowSelected.content" name="content" />
|
<input class="clr-input" type="text" [(ngModel)]="rowSelected.content" name="content" />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="clr-col-sm-12">
|
||||||
|
<label>CreatedAt</label>
|
||||||
|
<input id="name" class="clr-input" type="date" [(ngModel)]="rowSelected.createdat" name="createdat" />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -276,6 +294,8 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- aeroplane icon -->
|
<!-- aeroplane icon -->
|
||||||
|
|
||||||
<a *ngIf="userrole?.includes('ADMIN')" style="float: right;" href="javascript:void(0)" role="tooltip" aria-haspopup="true"
|
<a *ngIf="userrole?.includes('ADMIN')" style="float: right;" href="javascript:void(0)" role="tooltip" aria-haspopup="true"
|
||||||
@ -290,15 +310,20 @@
|
|||||||
<div class="clr-row" style="height: fit-content;">
|
<div class="clr-row" style="height: fit-content;">
|
||||||
|
|
||||||
<div class="clr-col-sm-12">
|
<div class="clr-col-sm-12">
|
||||||
<label> title</label>
|
<label> Title</label>
|
||||||
<input class="clr-input" type="text" formControlName="title" />
|
<input class="clr-input" type="text" formControlName="title" />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="clr-col-sm-12">
|
<div class="clr-col-sm-12">
|
||||||
<label> content</label>
|
<label> Content</label>
|
||||||
<input class="clr-input" type="text" formControlName="content" />
|
<input class="clr-input" type="text" formControlName="content" />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="clr-col-sm-12">
|
||||||
|
<label> CreatedAt</label>
|
||||||
|
<input class="clr-input" type="date" formControlName="createdat" />
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@ -307,6 +332,8 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- form code start -->
|
<!-- form code start -->
|
||||||
<div *ngIf="checkFormCode">
|
<div *ngIf="checkFormCode">
|
||||||
<h4 style="font-weight: 300;display: inline;">Extension</h4>
|
<h4 style="font-weight: 300;display: inline;">Extension</h4>
|
||||||
@ -341,4 +368,6 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- htmlpopup -->
|
<!-- htmlpopup -->
|
||||||
|
|||||||
@ -68,6 +68,10 @@ title : [null],
|
|||||||
|
|
||||||
content : [null],
|
content : [null],
|
||||||
|
|
||||||
|
createdat : [null],
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -100,6 +104,8 @@ content : [null],
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
ngOnDestroy(): void {
|
ngOnDestroy(): void {
|
||||||
if (this.editInterval) {
|
if (this.editInterval) {
|
||||||
@ -109,6 +115,8 @@ content : [null],
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
error;
|
error;
|
||||||
getData() {
|
getData() {
|
||||||
this.mainService.getAll().subscribe((data) => {
|
this.mainService.getAll().subscribe((data) => {
|
||||||
@ -131,6 +139,8 @@ this.product = [...this.product].reverse(); if(this.product.length==0){
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
this.modalEdit = true;
|
this.modalEdit = true;
|
||||||
}
|
}
|
||||||
onDelete(row) {
|
onDelete(row) {
|
||||||
@ -154,6 +164,8 @@ this.product = [...this.product].reverse(); if(this.product.length==0){
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//console.log("in update");
|
//console.log("in update");
|
||||||
console.log("id " + id);
|
console.log("id " + id);
|
||||||
console.log(this.rowSelected);
|
console.log(this.rowSelected);
|
||||||
@ -171,6 +183,8 @@ setTimeout(() => {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}, (error) => {
|
}, (error) => {
|
||||||
console.log(error);
|
console.log(error);
|
||||||
if (error.status >= 200 && error.status <= 299) {
|
if (error.status >= 200 && error.status <= 299) {
|
||||||
@ -193,6 +207,8 @@ onCreate() {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
this.mainService.create(this.entryForm.value).subscribe(
|
this.mainService.create(this.entryForm.value).subscribe(
|
||||||
(data) => {
|
(data) => {
|
||||||
console.log(data);
|
console.log(data);
|
||||||
@ -206,6 +222,8 @@ setTimeout(() => {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}, (error) => {
|
}, (error) => {
|
||||||
console.log(error);
|
console.log(error);
|
||||||
if (error.status >= 200 && error.status <= 299) {
|
if (error.status >= 200 && error.status <= 299) {
|
||||||
@ -228,6 +246,8 @@ this.modalAdd = true; this.submitted = false;
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
submitted = false;
|
submitted = false;
|
||||||
onSubmit() {
|
onSubmit() {
|
||||||
@ -242,8 +262,12 @@ onSubmit() {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// updateaction
|
// updateaction
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -33,5 +33,7 @@ export class Noteservice{
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// updateaction
|
// updateaction
|
||||||
}
|
}
|
||||||
@ -1,3 +1,4 @@
|
|||||||
|
|
||||||
import { NotesappwireframeComponent } from './BuilderComponents/app-b/Notesappwireframe/Notesappwireframe.component';
|
import { NotesappwireframeComponent } from './BuilderComponents/app-b/Notesappwireframe/Notesappwireframe.component';
|
||||||
|
|
||||||
|
|
||||||
@ -296,6 +297,8 @@ const routes: Routes = [
|
|||||||
|
|
||||||
|
|
||||||
// buildercomponents
|
// buildercomponents
|
||||||
|
|
||||||
|
|
||||||
{path:'Notesappwireframe',component:NotesappwireframeComponent},
|
{path:'Notesappwireframe',component:NotesappwireframeComponent},
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -1,3 +1,4 @@
|
|||||||
|
|
||||||
import { NotesappwireframeComponent } from './BuilderComponents/app-b/Notesappwireframe/Notesappwireframe.component';
|
import { NotesappwireframeComponent } from './BuilderComponents/app-b/Notesappwireframe/Notesappwireframe.component';
|
||||||
|
|
||||||
|
|
||||||
@ -169,6 +170,8 @@ import { MyworkspaceComponent } from './admin/myworkspace/myworkspace.component'
|
|||||||
|
|
||||||
|
|
||||||
// buildercomponents
|
// buildercomponents
|
||||||
|
|
||||||
|
|
||||||
NotesappwireframeComponent,
|
NotesappwireframeComponent,
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -226,11 +226,8 @@
|
|||||||
"MENU_ACTION_LINK": "Menu Action Link",
|
"MENU_ACTION_LINK": "Menu Action Link",
|
||||||
"STATUS": "Status",
|
"STATUS": "Status",
|
||||||
"SUB_MENU": "Sub Menu",
|
"SUB_MENU": "Sub Menu",
|
||||||
|
"Content": "Content",
|
||||||
"Note": "Note",
|
"Note": "Note",
|
||||||
"CreatedAt": "CreatedAt",
|
"CreatedAt": "CreatedAt",
|
||||||
"NoteContent": "NoteContent",
|
"Title": "Title"
|
||||||
"title": "title",
|
|
||||||
"content": "content",
|
|
||||||
"Notesappwireframe": "Notesappwireframe",
|
|
||||||
"NoteTitle": "NoteTitle"
|
|
||||||
}
|
}
|
||||||
Loading…
x
Reference in New Issue
Block a user