Skip to content

Commit

Permalink
Updated Readme
Browse files Browse the repository at this point in the history
  • Loading branch information
Sithira committed Jun 30, 2018
1 parent 2e9da7c commit a8781b6
Show file tree
Hide file tree
Showing 6 changed files with 48 additions and 5 deletions.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,4 +39,7 @@ adonis serve --dev
adonis test
```

### Angular 6 Client
[Client for APMS-BackEnd](https://github.com/Sithira/APMS-Client)

_AAF Assesment 2018 SHU - Sithira Munasinghe (27045236)_
1 change: 1 addition & 0 deletions app/Controllers/Http/ProjectController.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ class ProjectController
/**
* Get all the projects
*
*
* @param request
* @param response
* @returns {Promise<*|{limit, strict, types}|Promise<any>>}
Expand Down
20 changes: 19 additions & 1 deletion app/Models/User.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,25 @@ const Hash = use('Hash'),
Model = use('Model'),
Team = use('App/Models/Team');


/**
* @swagger
* definitions:
* User:
* type: object
* properties:
* id:
* type: uint
* username:
* type: string
* email:
* type: string
* password:
* type: string
* required:
* - username
* - email
* - password
*/
class User extends Model
{

Expand Down
6 changes: 3 additions & 3 deletions config/swagger.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ module.exports = {
// security definition config
securityDefinitions: {
ApiKey: {
description: 'ApiKey description',
name: 'Authorization'
description: 'JWT Token',
name: 'Bearer '
},

// OAuth2 configuration
Expand Down Expand Up @@ -49,6 +49,6 @@ module.exports = {
],

definitions: [
'docs/models/*.yml'

]
};
2 changes: 1 addition & 1 deletion docs/controllers/Project.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,4 @@
200:
description: users
schema:
$ref: '#/definitions/Project'
$ref: '#/definition/Project.yml'
21 changes: 21 additions & 0 deletions docs/controllers/User.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
/**
* @swagger
* /users:
* post:
* description: Creates a user
* produces:
* - application/json
* parameters:
* - name: user
* description: User object
* in: body
* required: true
* type: string
* schema:
* $ref: '#/definitions/NewUser'
* responses:
* 200:
* description: users
* schema:
* $ref: '#/definitions/User'
*/

0 comments on commit a8781b6

Please sign in to comment.