<?php
require_once(__DIR__."/../includes/sysinit.php");
include("service.php");
$_service = new Service; //new class instance
$_service->hddnServiceId			= $_POST['hddnServiceId'];
//$_service->areaList			= json_decode($_POST['areaList'], true);
$_service->edtServiceName			= $_POST['edtServiceName'];
$_service->edtServiceDuration			= $_POST['edtServiceDuration'];
$_service->edtServicePrice			= $_POST['edtServicePrice'];
if ($_POST['action']=='0') $_service->addService();
if ($_POST['action']=='1') $_service->updateService();
if ($_POST['action']=='2') $_service->viewService();
if ($_POST['action']=='3') $_service->editService();
if ($_POST['action']=='4') $_service->deleteService();
if ($_POST['action']=='5') $_service->copyService();
unset($_service);
