package com.iqser.red.service.persistence.service.v1.api.internal.resources;

import java.util.List;

import org.springframework.http.MediaType;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

import com.iqser.red.service.persistence.service.v1.api.shared.model.dossiertemplate.ReportTemplate;

public interface ReportTemplateResource {

    String REPORT_TEMPLATE_UPLOAD_PATH = "/templateUpload";

    String DOSSIER_TEMPLATE_ID = "dossierTemplateId";
    String DOSSIER_TEMPLATE_ID_PATH_VARIABLE = "/{" + DOSSIER_TEMPLATE_ID + "}";

    String TEMPLATE_ID = "templateId";
    String TEMPLATE_ID_PATH_VARIABLE = "/{" + TEMPLATE_ID + "}";


    @GetMapping(value = InternalApi.BASE_PATH + REPORT_TEMPLATE_UPLOAD_PATH + DOSSIER_TEMPLATE_ID_PATH_VARIABLE, produces = MediaType.APPLICATION_JSON_VALUE)
    List<ReportTemplate> getAvailableReportTemplates(@PathVariable(DOSSIER_TEMPLATE_ID) String dossierTemplateId);


    @GetMapping(value = InternalApi.BASE_PATH + REPORT_TEMPLATE_UPLOAD_PATH + DOSSIER_TEMPLATE_ID_PATH_VARIABLE + TEMPLATE_ID_PATH_VARIABLE, produces = MediaType.APPLICATION_JSON_VALUE)
    ReportTemplate getReportTemplate(@PathVariable(DOSSIER_TEMPLATE_ID) String dossierTemplateId, @PathVariable(TEMPLATE_ID) String templateId);

}
