diff --git a/app/controllers/ProjectsController.php b/app/controllers/ProjectsController.php new file mode 100644 index 0000000..481dcf5 --- /dev/null +++ b/app/controllers/ProjectsController.php @@ -0,0 +1,103 @@ +save(); + + } + + + /** + * Display the specified resource. + * + * @param int $id + * @return Response + */ + public function show($id) + { + $project = Project::find($id); + + return View::make('projects.project')->with('project', $project); + } + + + /** + * Show the form for editing the specified resource. + * + * @param int $id + * @return Response + */ + public function edit($id) + { + $project = Project::find($id); + + return View::make('projects.edit')->with('project', $project); + } + + + /** + * Update the specified resource in storage. + * + * @param int $id + * @return Response + */ + public function update($id) + { + $project = Project::find($id); + + $data = \Input::all(); + + $project->title = \Input::get('title'); + + $project->save(); + + } + + + /** + * Remove the specified resource from storage. + * + * @param int $id + * @return Response + */ + public function destroy($id) + { + Project::delete($id); + } + + +} diff --git a/app/models/Project.php b/app/models/Project.php index e69de29..ff16362 100644 --- a/app/models/Project.php +++ b/app/models/Project.php @@ -0,0 +1,9 @@ + 'auth'), function() Route::get('users', array('as' => 'users', 'uses' => 'UserController@index')); Route::get('mentors', array('as' => 'mentors', 'uses' => 'UserController@mentors')); Route::get('mentees', array('as' => 'mentees', 'uses' => 'UserController@mentees')); + +}); + +Route::group(array('before' => 'auth'), function() +{ + Route::resource('projects', 'ProjectsController'); }); /** diff --git a/app/views/projects/home.blade.php b/app/views/projects/home.blade.php new file mode 100644 index 0000000..26f4d04 --- /dev/null +++ b/app/views/projects/home.blade.php @@ -0,0 +1,109 @@ + + + + + Mentconnect - Login + {{HTML::style('css/mentconnect.css')}} + + + +
+ +
+ +
+
+ +
+
+
+
+
+ {{ Form::open(array('url' => 'login', 'class' => 'form-horizontal'))}} + +
+

Please Sign In

+ + @if(Session::has('message')) +

{{ Session::get('message') }}

+ @endif + +
+ {{ Form::label('email', 'Email', array('class' => 'control-label')) }} +
+ {{ Form::text('email', \Input::old('email'), array('class' => 'form-control borderd input-large', 'span' => 'span6', 'placeholder' => 'awesome@awesome.com'))}}

{{ $errors->first('email') }}

+
+
+
+ {{ Form::label('password', 'Password', array('class' => 'control-label'))}} +
+ {{ Form::password('password', array('class' => 'form-control bordered input-large', 'placeholder' => 'Password', 'span' => 'span6'))}}

{{ $errors->first('password') }}

+
+
+
+
+ +
+
+
+
+       + {{HTML::link('password/remind', 'Forgot your password?')}} +
+
+
+ Don't have a Mentconnect account? {{HTML::link('users/create', 'Register now')}} +
+
+ {{Form::close()}} +
+
+
+ +
+


+ + + + \ No newline at end of file