Setting up Breezejs with Entity Framework 6 - angularjs

I hope that someone can help me out here. I have just started working with angularjs and breezejs. I am coming from a more traditional MVC 5 and Entity Framework 6 background with this.
I have been working through the Breezejs documentation, in particular how to get the meta data configuration working, but I have to say this is where the documentation is vague. The grammar used refer to 'we', and this is where I (English is my 3rd language), struggle. Do they mean, we the developer working with it in the end, or we the breezejs team. Confusion sets in when I simply cannot find a working example of this either.
So far I have created an empty web application, and installed the nuget packages for breezejs ef, angularjs and hot towel. I also created a separate efmodel project and created code from database. This is now where I get stuck.
Can someone please point me to an example, or help me out how to get it wired up so that my breezejs uses my ef6 model meta data.
Much appreciated.

To answer your question in regards to the words that they use - they are referring to the author of the document and the read together as 'we' meaning that when they say we need to add a metadata endpoint on the WebAPI controller or something that you need to do it and follow along with how they are suggesting.
As far as samples of using Angular with EntityFramework 6 and Breeze just go to their samples site which has a plethora of sample solutions that should point you in the right direction.
http://www.breezejs.com/samples
Good luck!

Related

Where do you generate the datasource for the solution in a winforms MVC solution?

I am creating a Winforms MVC project called Cookies.
Following guidelines from various searches, I have a solution with 4 separate projects: Cookies-Controller; Cookies-Model; Cookies-View and
UseCookiesApplication (used as the starting stub with the program.cs file).
I got it all working with a "dummy" view with a simple listview control with hard-coded list items.
However, I then wanted a "proper" view showing data from a SQL Database.
My problem is ... under which project should I generate the datasource to ensure that it is appropriately visible?
If I do so under the Cookies-Controller project then it is not visible when I go to a view in design mode.
If I generate under Cookies-View then I get the error "...could not get type information for 'CookiesView.CookiesDataSet'".
I have successfully built Web-based MVC solutions, and standard winforms, but this has got me a tad confused.
Any help or pointers to other sites would be massively appreciated.
James
UPDATE:
I have looked more deeply at MVP and can see it as viable alternative to Winforms MVC for what I need right now. So thanks again to #VirtualValentin and also #Jimi.
However, my original question still stands and, from a purely educational point of view, I would be grateful if someone who has developed a Winforms MVC Database application could enlighten me.
James

How can you build React on top of Drupal?

I've never used Drupal, but have been looking up tutorials online. My client would really like the adaptability of React and to have more flexibility in terms of design. I could make my own database and React app, but I have not studied security (I'm a team of one, so no one for security on my end, either). Security and access to a content management system was the main reason we decided to go with Drupal. However, I would still like to be able to code in React/something I'm familiar with to produce a site I am proud to say I made.
I've been Googling and Youtubing tutorials and help, but not having anyone to ask specific questions is making this difficult.
If anyone knows of a relatively easy way to build a React app on Drupal, I would really appreciate the advice. Or if there is a better way I should go about beginning a project as I've briefly mentioned above, I would also be open to that. Thank you in advance and sorry for the long message!
What you are asking is quite broad in concept and not easy to answer in just one answer post. Try to look for Headless / Decoupled Drupal.
https://www.acquia.com/drupal/decoupled-drupal
What this essentially means is that all the services and the content management are handled by Drupal while the core user experience or the way the site is displayed in a browser is controlled via a JavaScript framework such as React.js or backbone.js. This is achieved via Drupal’s RESTful API service.
Hope this helps.

Generating menus in client side via abp.nav.menus.MainMenu

I am working with ASPNet Boilerplate. In the documentation I was going through the NavigationProvider. What I wanted to do was to define how the menus should appear without having to hard code them at client-end.
However as the documentation points out, I couldn't find how it's being used in the downloaded template (Asp.net core with AngularJS - version 3.6.0) since there are no references made to NavigationProvider in any of the classes.
The sample Task application seems to be for an older version of Abp.
I would highly appreciate if anyone can point me to a documentation/sample for this.

Specific suggestions on how to prepare for AngularJS 2.0?

I have an AngularJS 1.3 application that will I suppose eventually move to AngularJS 2.0. I've watched the videos from ng-europe and I understand there are many changes. As I expect development to continue with our AngularJS 1.3 code for the next 12 I would like to hear if anyone has any specific suggestions on preparing for 2.0.
My application is simple in that it creates no directives. In particular I would like to hear any tips on how I should go about creating controllers to get ready for them being very different in 2.0. Should I eliminate all references to scope in my controllers. Should I move everything to services?
I hope for some useful suggestions but of course specific ones so this question does not get closed.
Thanks
I think that so little has specifically been announced yet, and there's so much potential for it to change that it's a hard question to answer, e.g. check out this issue for an example of something quite fundamental that's likely to change since the ng-europe announcement.
Within my team we're trying to take the following approach:
Try not to use $scope (controller-as syntax).
Keep your controllers as light as possible by using directives to encapsulate UI functionality and services to deal with data models / API calls.
Use the new syntax for one-way binding where you don't need two-way binding. One-way binding will be the default for Angular 2.0.
Write some unit tests! It'll be much easier to do some significant refactoring if you have some confidence that your code will still work :).
Not only should that help with the move to 2.0 if / when that happens, but it should help your 1.3 apps too!

AngularJS with Durandal?

Is it possible to run AngularJS in a Durandal project? We are using Durandal now but want to move to AngularJS while still keep the site operational. Is it even a good idea to attempt this?
Any suggestion would be greatly appreciated.
You could run them side-by-side, but then you would just have two separate SPAs hosted on the same site. The doesn't seem like a good upgrade strategy to me. I think you would be better off to fully develop the new version and then replace the site altogether.
I would also advise that you wait for the release of AngularJS 2.0 (if possible). Rob Eisenberg has announced that he is currently working with the AngularJS team to provide core changes and plugins that will make Angular 2.0 more familiar to developers with Durandal experience, as well as to provide a migration path from Durandal to Angular 2.0.
The other answer isn't exactly correct. I have an example that proves it wrong.
Durandal is a module loader that can load any view / view model pair. If you choose to load an angular application and leave out the router portion it works just fine. It really isn't that difficult to get it set up.
Wrap your Angular.js application initialization code in an AMD module (view model) with a matching view and it just works.

Resources