Entries:
Comments:
Posts:

Loading User Information from Channel 9

Something went wrong getting user information from Channel 9

Latest Achievement:

Loading User Information from MSDN

Something went wrong getting user information from MSDN

Visual Studio Achievements

Latest Achievement:

Loading Visual Studio Achievements

Something went wrong getting the Visual Studio Achievements

SocialGoal - ASP.NET MVC 5, EF 6 Code First, AutoMapper, Autofac, TDD and DDD Sample Site

Today's Web Wednesday project from Shiju Varghese and team is one that brings together a pretty darn big number of different technologies together into a pretty complete "Social" sample reference site.

Here's a list of just some of that tech;

  • ASP.NET MVC 5
  • EF 6 Code First
  • AutoMapper
  • Autofac
  • Twitter Bootstrap
  • NUnit
  • Moq

Releasing SocialGoal - Reference Web App for ASP.NET MVC 5, EF 6 Code First, AutoMapper, Autofac, TDD and DDD

My team at Marlabs, developed and released a sample reference web app for the Microsoft ASP.NET stack, named “SocialGoal” . SocialGoal is a social networking web app for socializing your goals and strategies with people. People can create goals and can be shared across the network of SocialGoal users. This app is built with ASP.NET MVC 5, EF 6 Code First, AutoMapper, Autofac, Twitter Bootstrap and following Test-Driven Development (TDD) and Domain Driven Design (DDD). The first drop of the application is available on github at https://github.com/MarlabsInc/SocialGoal. A release note is available in the docs folder of the project repository.

...

SocialGoal v1.0.0

SocialGoal is a social networking web app for socializing your goals and strategies with people. The primary objective of the SocialGoal app is to provide a learning app for building real-world web apps with ASP.NET MVC 5 and EF 6 Code First. The application architecture is inspired from EFMVC. SocialGoal is developed by Marlabs.

Technologies

  • ASP.NET MVC 5
  • EF 6 Code First
  • AutoMapper
  • Autofac
  • Twitter Bootstrap
  • NUnit
  • Moq

Patterns & Practices

  • Domain Driven Design (DDD)
  • Test-Driven Development (TDD)
  • Repository Pattern & Generic Repository
  • Unit of Work
  • Dependency Injection

Goals and Roadmap

Overall Project Goals
  • Web app for Social Networking for soclialize your goals and strategies.
  • A reference web app for ASP.NET MVC 5 and EF 6 Code First.
  • Improve developer productivity for building web apps on the Microsoft Web stack.
  • Reference app for building Test-Driven Development (TDD) and Domain-Driven Design (DDD).
  • Mobilize an existing app for solving the mobility challenges.
Roadmap Targets
  • Build a full-fledged social networking app with enhanced UI and new features.
  • Mobilize the existing app
    • Provide an API for Mobility, by using ASP.NET Web API 2.
    • Build cross platform, minimalist mobile apps by using HTML5/JavaScript platform.
    • Build Mobile Backend as a Service (MBaaS) solution on the Windows Azure for the mobile apps.

From the Doc's

How to build

1. Clone the source code from GitHub and open the solution in Visual Studio 2013.

2. Build the solution. It will automatically restore NuGet and will install NuGet packages.

Note: The source code is excluded NuGet packages in the source control.

Introduction

SocialGoal is a social networking web app for socializing your goals and strategies with people. People can create goals and can be shared across the network of SocialGoal users. Goals can have start date, end date, metrics and target. People can update their goals and others can see those updates and can comment on each updates. People can support any public goal.

Groups can be created within SocialGoal so that it is very easy to build goals for a team. Group goals can be assigned to any of the group members. Groups can have focus and group goal can be created with a particular focus also.

Features of SocialGoal

User should Register to start using SocialGoal application

Creating Goals –

User can set goals in two types

1) Individual goals

2) Goals for a group in which the user is a member.

Edit & Delete Functionality is provided for each goal.

Update Status-

Updates can be given for users own goal with or without status.

Comment on an Update-

Any user can comment on an update of a public goal created by any user.

Searching & Supporting a Goal-

User can search all the public goals in the search box provided and can support them. The user can follow a goal.

Creating Group & Inviting Users –

User can create a group and can invite others to join the group

Invitation can send in two ways-

1) Can invite an existing user by searching with a user name.

Those invitations will send to user’s my invitation list and from there user can accept the invitation

2) Can invite a new user by sending an email

That invitation will send to the inbox of the recipient’s mailid and from there can join to the social goal and accept the invitation

Following Group-

Once the User accepts the invitation to a group, then goals can be created for that group. He can invite other users and can create a focus for the group.

Creating Focus For a Group-

The group can have a focus and the creation of goals is completely dependent on that focus

Report for a Goal-

User can see the report of a goal based on update date and target date. Report will be generated for updates having status.

Notifications –

User can see the notifications of the goal & group which is public.

User Profile Creation-

User can create a profile and can edit the profile.

...

Grabbing the latest drop, I had the site up and running very quickly (well mostly, I had to remember to start my SQLExpress service, which I usually have stopped... Gee, no wonder the site couldn't talk to its database... :/ )

image

imageimage

Here's some snaps of it running on my system.

image

There's one initial account, User Name:Admin, Password:123456.

image

image

image

image

There's a few bugs and missing files, but the site runs and provides a great example of how to use all those different technologies...

Tags:

Follow the Discussion

  • I get a lot of JavaScript (jqplot related) errors after login as Admin:

    0x800a138f - JavaScript runtime error: Unable to set property 'BarRenderer' of undefined or null reference

    0x800a138f - JavaScript runtime error: Unable to set property 'DateAxisRenderer' of undefined or null reference

    0x800a138f - JavaScript runtime error: Unable to set property 'CategoryAxisRenderer' of undefined or null reference

  • Greg Duncangduncan411 It's amazing what a professional photographer can do...

    @niros: Actually I saw those too, but just continued through them, marking it up to the "sample" keyword.

    To have them addressed (or at least let the author know about this), the best bet would be to post a comment directly on the author's post,http://weblogs.asp.net/shijuvarghese/archive/2014/01/24/releasing-socialgoal-reference-web-app-for-asp-net-mvc-5-ef-6-code-first-automapper-autofac-tdd-and-ddd.aspx, or create an issue in the github project, https://github.com/MarlabsInc/SocialGoal/issues?page=1&state=open

  • @niros @gduncan411 - We did a minor update on the code base of SocialGoal, which might solve most of the problems. There was a problem with a predefined user "Admin" as we had changed the functionality recently, but did not removed some code. In the new code base, there is not any predefined user "Admin" as all users are public users who can create their own groups and goals. In our next drop, we will fix all issues if there is any problem in the application.  

  • Greg Duncangduncan411 It's amazing what a professional photographer can do...

    @shijuv: Thanks! :)

  • I think it's unfair to advertise this codebase as an example of TDD and DDD, although the test project shows some mocking technics.

    I can't say that I'm not guilty of implementing similar designs in my .NET applications, but nowadays I try to question such "default decisions":
    1. Do we really need 7 projects here?
    2. Where to put business logic, ASPNET MVC related code, how to grow it along with testing?
    3. Given the unit tests the way they are implemented in the test project, do we need services, what value do they bring?
    4. Do we need to put queries in services, then why do we need specialized repositories?
    5. Do we need repositories? Can we just mock IDbSet directly?

    Not easy questions, huh?

    Just to make it more interesting, check an alternative point of view on these questions: http://ayende.com/blog/search?q=Northwind+Starter+Kit+Review

  • cbrcodercbrcoder

    Sorry but it's un-necessarily complicated. This project is all theoretical. Projects following this is likely to be a mess.

  • Alexey ZimarevAlexey Zimarev

    Classical misuse of the repository pattern.

    Just look at GoalsReporitory.GetGoalsByPage

    var goals = this.GetMany(g => g.GoalType == false);

    where your generic GetMany does .ToList() and fires a database query, so it selects ALL from this table. And THEN you do filtering and only THEN you do Skip/Take.

    This is incredibly inefficient and this is what Martin Fowler means when he says about ORM and repository problems and this is exactly what Ayende is writing about in his anti+repository posts. And they both write. Being persistence ignorant quickly became "database ignorant", but the database does not like such approach. It will kick you hard when you need it least.

Remove this comment

Remove this thread

close

Comment on the Post

Already have a Channel 9 account? Please sign in