Angularjs, storage data and scaffolding - angularjs

Some one can help me with some angularjs world doubts ?
Is there a scaffolding tool for angularjs? What is a good tool to storage data? Firebird?

For AngularJS scaffolding you can use Telosys Tools a simple code generator
using an existing database to generate CRUD screens.
See the tutorial for Angular JS : https://sites.google.com/site/telosystutorial/angularjs
and the tool web site : http://www.telosys.org/
You can store your data in any kind of database and expose a REST API to serve the front-end. You can also generate the service layer with REST services ( Spring MVC or Jax-RS )

Related

Steps to connect Angular4 to a Database (Oracle)

Actually I've to connect my Angular project to a database to access some data. But I don't know how.
Should I write a REST API to do it? If yes, how can I connect my REST API to my project?
Which steps should I follow?
Thanks
The angular application will be your "front" application. To store and fetch data
from a database you'll need a "back" application that will provide URLS for your angular App to call.
A simple back can be done using Laravel and OCI 8 connector in order to query ORACLE database. The backend would be in PHP which is a common solution but might not fit your needs.
Set up your laravel project : https://laravel.com/docs/5.4
Install OCI8 module to connect to your oracle database : https://github.com/yajra/laravel-oci8
Then follow laravel's guidelines to set up URLs that will be callable by your front application in Angular4.

How to use API as backend in ionic mobile app development?

I am having a web application built using JAVA spring which has API feature to read and write into database.
Now i have to develop an ionic mobile app for the same application. How to read and write data into database.
I know Firebase and other alternatives can do the job.
But i need my own API code(written for web app) to be used. Is there any way to achieve that?
I guess calling the respective API when the web application is live is achievable.
But how can i achieve that while developing(When the web app is under construction)
Well depending on how you set up the API this could become quite difficult.
You're saying/guessing that you can call the API when the webapplication is live. This makes me assume you've created a REST API? Or did you create a Spring MVC application?
If the webapplication is directly linked to your Spring application (f.e. going to localhost:8080/my-profile shows a page (not JSON) of your profile) then I'm not sure if you can achieve the above mentioned target.
If you get a JSON response, or are somehow able to retrieve it from the webpage, you can just simply call (in typescript:)
this.http.get('http://localhost:8080/my-profile').map(response => console.log(response.json() );
Else, you probably will have to create a basic REST API (check out Spring boot for a 5 minute setup) and provide it, either with hardcoded data or connect it with your database.

Angular JS and Web API Architecture

I have to prepare an architecture with following technologies:
Angular JS 1.5
MVC 5.0/Web API.
EF 6.0
Is it a good option to have a single web project which has angular JS and Web API.
We need to expose web api's to other third party vendors. So, we are thinking to create a separate web api project as a separate project. Need your inputs.
Thanks,
Dhannajay
You can have a lot of options to define the architecture, but to answer your questions, I think is better have separate projects in this case for the following reasons:
You can change the front-end without touch any in the api system (web api) and viceversa
You can scale both sites or only one, maybe, the front-end goes well, but you need more power in the web api, go ahead and scale only the api.
you can do this (like here)
API: your api front end
Core: business logic/EF
MVC: html/mvc/angularjs
DTO: classes/models

Caching for the frontend application

I am working on a web application that uses Spring MVC framework and hibernate for the backend and using DAO classes and DTOs for persistence. After entity fetch the dto is being sent as a JSON to the frontend that uses angularJS for the front end.
I am asked to add caching to the frontend application.The dB call is to be avoided if the the request is hit again within some time frame. Please suggest me how i can implement this. Also please tell me some different ways how caching can be implemented to make frontend perform better.
Thanks,
You should use EhCache here some tutorials
http://www.mkyong.com/spring/spring-caching-and-ehcache-example/
or
https://amitstechblog.wordpress.com/2011/11/08/configuring-ehcache-with-jpa-hibernate-spring/

AngularJS app - with Lumen or Laravel?

I am about to build web application consisting of three parts:
Public data-oriented websites for unauthenticated users with geolocation search, ...
Member area (with authentication) for managing the data
Mobile app/apps with the same functionalities
The airbnb.com is a good example of the structure.
Basicaly the thing is to create a server side API which will be shared accross clients.
I definitelly want to use AngularJS for the client side, but I am not sure which of those solutions is better:
Create the API with microframework Lumen and add sessions / authentication / html serving / other services to the Lumen
Create the API with full stack framework Laravel and serve html to AngularJS
Thank you for your suggestions.
You will need a solid api, lumen has all we need to build an api. You can go ahead with option 1 as you can later on migrate to full stack laravel framework, if needed.

Resources