import { Injectable } from '@angular/core';
import {HttpClient} from '@angular/common/http';
import { BaseService } from '../../base/base-service';

@Injectable({
    providedIn: 'root'
})
export class TestingCenterService extends BaseService {

    constructor(
        public http: HttpClient
    ) {
        super('/v1/setting/testing_centers', http);
    }

    getByBrandID(BrandID){
        return this.http.get(`${this.fullUrl}?branch_uid=${BrandID}`);
    }

    getByFiledID(FieldID){
        return this.http.get(`${this.fullUrl}?testing_field_uid=${FieldID}`);
    }

    getAvailableSeat(data){
        return this.http.get(`${this.prefix}/v1/setting/testing_center_chk_seat/${data.testing_center_uid}/${data.from_date}/${data.to_date}`);
    }
}
