<commit_before># Phase 2 Project Report

Welcome to the report of the TWEB Project phase 2. This is where you will find information about specification, what has been implemented during the second phase, known issues and what needs to be implemented in the last part of the project.

## Administrative information

### Team

Last name, first name | Github ID                                   |
----------------------|---------------------------------------------|
<NAME>  | [paranoodle](https://github.com/paranoodle) | 
<NAME>       | [gweezer7](https://github.com/gweezer7)     | 
<NAME>       | [yibnl](https://github.com/yibnl)           | 
<NAME>    | [paulnta](https://github.com/paulnta)       | 

### Links

* [Polliwog web application](http://polliwog-app.herokuapp.com).
* [Polliwog REST API](http://polliwog-app.herokuapp.com/api).
* [Polliwog REST API Documentation](https://github.com/paulnta/Teaching-HEIGVD-TWEB-2015-Project/tree/master/api).
* [Polliwog product page](http://paulnta.github.io/Teaching-HEIGVD-TWEB-2015-Project/).
* [Mockups user interface](https://invis.io/6Y59VQVK7) 

> The REST API Documentation link redirects to a basic markdown description of the API. However, both HTML and RAML version with more content can be found on the same location.

## Table of Contents
1. [Introduction](#Intro)
1. [Tools](#Tools)
1. [Specification](#Spec)
1. [Client](#Client)
	 1. [User Interfaces](#UI)
	 1. [Project Structure](#Structure) 
	 1. [State Pattern](#State)
1. [Server](#Server)
    1. [REST API](#API)
    1. [REST API Documentation](#APIDoc)
1. [Remaining Work](#Work)
1. [Known issues](#Issues)
1. [Conclusion](#Conclusion)

## <a name="Intro"></a> Introduction

The purpose of this report is to describe what has been implemented during the second phase of the project.

## <a name="Tools"></a> Tools

* [Angular Fullstack](https://github.com/angular-fullstack/generator-angular-fullstack), for project scaffolding.
* [Angular Material](https://material.angularjs.org), as material design.
* [InVision](http://www.invisionapp.com/), for ideas sharing.
* [RAML 8.0](http://raml.org/), for REST API documentation.

## <a name="Spec"></a> Specification

First, a short summary of the features we had planned to implement for part 2:

* User accounts (optional for listeners, required for speakers)
* Lectures, allowing for the sharing of resources, creating polls, and viewing the current mood of the audience
	* They can be public and only require a key to join
	* Or they can be private and require an account and an invitation
* Polls, consisting of one or more multiple-choice questions
	* Users can answer polls while they are active
	* Poll results can be displayed at the speaker's discretion
* Mood, a measure of the overall satisfaction of the audience

From the [original specifications](https://github.com/paulnta/Teaching-HEIGVD-TWEB-2015-Project/blob/master/specifications/specifications.md), we dropped the TweetQuestions feature from part 2 with the intent to implement it in part 3 instead.

Client-wise, we wanted an interface that was clean and simple to use, and that included at least the following functionalities:

* Logging in to an account as a speaker, and:
	* Creating, editing and deleting lectures, and setting them as active or non
	* Creating, editing and deleting polls (and by extension, questions and choices), setting them as active or non, and viewing their results
	* Accessing the audience's current mood, as a graph
	* Creating and deleting resources to share
* Accessing the site as a listener, with or without an account, and:
	* Accessing a lecture, both via key and invitation
	* Accessing the current lecture's resources
	* Responding to polls when available
	* Inputting a current mood

## <a name="Client"></a> Client
* Note: As we've kept working on this project from our last pull request you might notice few changes in our code.

### <a name="UI"></a> User Interfaces

We started our project by doing the user interface specification. We've sketched the ui and then designed it using Adobe Illustrator. 

We used Invision to share our ideas in order to implement the UI in HTML/CSS/JS with exactly the same idea in mind.

You can see our mockups made with illustrator and invision: [Mockups user interface](https://invis.io/6Y59VQVK7) 

Implementing the UI was one of the hardest part because our goal is to have an Adaptive UI. So we had to deal with many browser compabtibily issues and css media-queries to get a responsive design. We've tested the UI on Chrome for mobile and desktop, Mozilla Firefox for mobile and desktop, safari for mobile and desktop and the last version of Internet Explorer for Desktop.

At this phase of the projet, the UI doesn't look perfectly one every browser but we are quit confident for the last part of this project because we've solved the biggest issues. As the base layout and base styles are now implemented, adding content for the other page will be much more faster in the future.


In this second part of the project we choosed to implement the foundation of the user interface (the responsive layout).



<img src="../images/ui_process.png" style="width:600">


### <a name="Structure"></a> Project Structure

We've organised our client files and directories as follows:<commit_msg>Update phase 2 project report<commit_after># Phase 2 Project Report

Welcome to the report of the TWEB Project phase 2. This is where you will find information about specification, what has been implemented during the second phase, known issues and what needs to be implemented in the last part of the project.

## Administrative information

### Team

Last name, first name | Github ID                                   |
----------------------|---------------------------------------------|
d'Agostino, Eléonore  | [paranoodle](https://github.com/paranoodle) | 
<NAME>       | [gweezer7](https://github.com/gweezer7)     | 
<NAME>       | [yibnl](https://github.com/yibnl)           | 
<NAME>    | [paulnta](https://github.com/paulnta)       | 

### Links

* [Polliwog web application](http://polliwog-app.herokuapp.com).
* [Polliwog REST API](http://polliwog-app.herokuapp.com/api).
* [Polliwog REST API Documentation](https://github.com/paulnta/Teaching-HEIGVD-TWEB-2015-Project/tree/master/api).
* [Polliwog product page](http://paulnta.github.io/Teaching-HEIGVD-TWEB-2015-Project/).
* [Mockups user interface](https://invis.io/6Y59VQVK7).

> The REST API Documentation link redirects to a basic markdown description of the API. However, both HTML and RAML version with more content can be found on the same location.

## Table of Contents
1. [Introduction](#Intro)
1. [Tools](#Tools)
1. [Specification](#Spec)
1. [Client](#Client)
	 1. [User Interfaces](#UI)
	 1. [Project Structure](#Structure) 
	 1. [State Pattern](#State)
1. [Server](#Server)
    1. [REST API](#API)
    1. [REST API Documentation](#APIDoc)
1. [Remaining Work](#Work)
1. [Known issues](#Issues)
1. [Conclusion](#Conclusion)

## <a name="Intro"></a> Introduction

The purpose of this report is to describe what has been implemented during the second phase of the project.

## <a name="Tools"></a> Tools

* [Angular Fullstack](https://github.com/angular-fullstack/generator-angular-fullstack), for project scaffolding.
* [Angular Material](https://material.angularjs.org), as material design.
* [InVision](http://www.invisionapp.com/), for ideas sharing.
* [RAML 8.0](http://raml.org/), for REST API documentation.

## <a name="Spec"></a> Specification

First, a short summary of the features we had planned to implement for part 2:

* User accounts (optional for listeners, required for speakers)
* Lectures, allowing for the sharing of resources, creating polls, and viewing the current mood of the audience
	* They can be public and only require a key to join
	* Or they can be private and require an account and an invitation
* Polls, consisting of one or more multiple-choice questions
	* Users can answer polls while they are active
	* Poll results can be displayed at the speaker's discretion
* Mood, a measure of the overall satisfaction of the audience

From the [original specifications](https://github.com/paulnta/Teaching-HEIGVD-TWEB-2015-Project/blob/master/specifications/specifications.md), we dropped the TweetQuestions feature from part 2 with the intent to implement it in part 3 instead.

Client-wise, we wanted an interface that was clean and simple to use, and that included at least the following functionalities:

* Logging in to an account as a speaker, and:
	* Creating, editing and deleting lectures, and setting them as active or non
	* Creating, editing and deleting polls (and by extension, questions and choices), setting them as active or non, and viewing their results
	* Accessing the audience's current mood, as a graph
	* Creating and deleting resources to share
* Accessing the site as a listener, with or without an account, and:
	* Accessing a lecture, both via key and invitation
	* Accessing the current lecture's resources
	* Responding to polls when available
	* Inputting a current mood

## <a name="Client"></a> Client

>Note: As we've kept working on this project from our last pull request you might notice few changes in our code.

### <a name="UI"></a> User Interfaces

We started our project by doing the user interface specification. We've sketched the ui and then designed it using Adobe Illustrator. 

We used Invision to share our ideas in order to implement the UI in HTML/CSS/JS with exactly the same idea in mind.

You can see our mockups made with illustrator and invision: [Mockups user interface](https://invis.io/6Y59VQVK7) 

Implementing the UI was one of the hardest part because our goal is to have an Adaptive UI. So we had to deal with many browser compabtibily issues and css media-queries to get a responsive design. We've tested the UI on Chrome for mobile and desktop, Mozilla Firefox for mobile and desktop, safari for mobile and desktop and the last version of Internet Explorer for Desktop.

At this phase of the projet, the UI doesn't look perfectly one every browser but we are quit confident for the last part of this project because we've solved the biggest issues. As the base layout and base styles are now implemented, adding content for the other page will be much more faster in the future.


In this second part of the project we choosed to implement the foundation of the user interface (the responsive layout).



<img src="../images/ui_process.png" style="width:600">


### <a name="Structure"></a> Project Structure

We've organised our client files and directories as follows:
{'fraction_non_alphanumeric': 0.10078902874318993, 'fraction_numerical': 0.008547811384557581, 'mean_word_length': 3.975233644859813, 'pattern_counts': {'":': 0, '<': 36, '<?xml version=': 0, '>': 39, 'https://': 20, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2605744', 'n_tokens_mistral': 3065, 'n_tokens_neox': 2852, 'n_words': 1340}