Skip to content

EdgarPsda/TestTask

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Welcome to TestTask

Creation of test task practice for CB.

Installation

  1. Project
    Open Terminal on ~/var/www/ folder and clone the project with the following command git clone [email protected]:inEdgar/TestTask.git

  2. Database
    Import the test_db.sql file to MySql.

Using Test Task

  1. Open a browser and go to localhost/TestTask will be show the Home page.
    Home

  2. To add a new interval, select the date range in the two inputs and enter the price of that range, then click on Add Interval button.
    Add Interval

  3. To add another interval, follow the same steps on #2 and the new interval will be added with some validations.
    Add Interval

Add Interval

  1. To Delete an interval, just click on the Delete link in the row of the interval.
    Add Interval

  2. To Update an interval, just click on the Update link in the row of the interval and will be show a form with the current range and price, update the data then click on the Update Interval button.
    Add Interval

Add Interval

Using Test Task API

  1. Using with Postman software, you can install it in the following link Postman.

  2. To Create a new interval enter the following url http://localhost/TestTask/API/interval/create.php and send some array like so

{
    "date_start" : "2019-04-25",
    "date_end" : "2019-04-26",
    "price" : "7"
}

Then click Send button.
Add Interval

  1. To Update an interval, enter the following url http://localhost/testTask/API/interval/update.php and send array with the new data like so
{
    "id" : "5",
    "date_start" : "2019-04-27",
    "date_end" : "2019-04-29",
    "price" : "7"
}

Add Interval

  1. To Delete an interval, just enter the following url http://localhost/testTask/API/interval/delete.php and send array with the interval's id to delete.
{
    "id" : "5"
}

Add Interval

Using Online

Also you can use Test Task online on the following url Test Task Online and API url's

To Create Interval https://psdadev.com/TestTask/API/interval/create.php
To Delete Interval https://psdadev.com/TestTask/API/interval/delete.php
To Update Interval https://psdadev.com/TestTask/API/interval/update.php

Thank you for following my work and I really appreciate any suggestion.

About

Creation of test task practice for CB.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages