import env from "../index";
const dataOptions = `${env.API_PROBATION_URI}/data-options`;
const personal = `${env.API_PROBATION_URI}/personal`;
const calculate = `${env.API_PROBATION_URI}/calculate`;
const finish = `${env.API_PROBATION_URI}/assign`;
const evaluate = `${env.API_PROBATION_URI}`;


export default {
  competencyOptions: (personalId: string) =>
    `${dataOptions}/competency?personal_id=${personalId}`,
  competencyGroupOptions: (personalId: string) =>
    `${dataOptions}/competency-group?personal_id=${personalId}`,
  knowledgeOptions: (personalId: string) =>
    `${dataOptions}/knowledge?personal_id=${personalId}`,
  skillOptions: (personalId: string) =>
    `${dataOptions}/skill?personal_id=${personalId}`,
  lawOptions: (personalId: string) =>
    `${dataOptions}/law?personal_id=${personalId}`,
  probationPersonalList: () => `${personal}/list`,
  personal: (personalId: string) => `${personal}?personal_id=${personalId}`,
  newAssign: (personalId: string) =>
    `${dataOptions}/new-assign?personal_id=${personalId}`,
  calculateDate: () => `${calculate}/assign-finish`,
  saveFinish: (personalId: string) =>
    `${finish}/probation-assign?personal_id=${personalId}`,
  saveEditAssign: (personalId: string) =>
    `${finish}/probation-assign?id=${personalId}`,
  personalAdd: () => `${personal}/add`,
  probationGetAssignList: (personalId: string) =>
    `${finish}/probation-assign-list?personal_id=${personalId}`,
  probationsGetAssign: (assignId: string) => `${finish}/probation-assign?assign_id=${assignId}`,
  changestatusProbations: (personalId: string) => `${evaluate}/report/change-status?personal_id=${personalId}`,

  // probationGetAssignList: (personalId: string) =>
  //   `${finish}/probation-assign-list?personal_id=${personalId}`,
  // clearPosition: (personalId:string) => `${placement}/position/clear/${personalId}`

  // บันทึกผล
  formevaluate: (id: string) => `${evaluate}/evaluate-record?assign_id=${id}`,
  formevaluateround: (id: string, no: string) => `${evaluate}/evaluate-record?assign_id=${id}&evaluate_no=${no}`,
  formevaluateRecord: (id: string) => `${evaluate}/evaluate-record/create?assign_id=${id}`,
  createformevaluate: (id: string) => `${evaluate}/evaluate-record?assign_id=${id}`,
  editFormEvaluate: (id: string, evaluate_id: string) => `${evaluate}/evaluate-record?assign_id=${id}&evaluate_id=${evaluate_id}`,

  //แบบประเมินผล (ผู้บังคับบัญชา)
  evaluateCreate: (id: string) => `${evaluate}/evaluate/create?assign_id=${id}`,
  evaluatecommader: (id: string, no: string) => `${evaluate}/evaluate?assign_id=${id}&evaluate_no=${no}`,
  createformCommader: (id: string) => `${evaluate}/evaluate?assign_id=${id}`,
  editFormEvaluateCommader: (id: string, evaluate_id: string) => `${evaluate}/evaluate?assign_id=${id}&evaluate_id=${evaluate_id}`,

  //แบบประเมินผล (คณะกรรมการ)
  evaluateChairman: (id: string) => `${evaluate}/evaluate-chairman/create?assign_id=${id}`,
  evaluateRoundChairman: (id: string, no: string) => `${evaluate}/evaluate-chairman?assign_id=${id}&evaluate_no=${no}`,
  createformChairman: (id: string) => `${evaluate}/evaluate-chairman?assign_id=${id}`,
  editFormEvaluateChairman: (id: string, evaluate_id: string) => `${evaluate}/evaluate-chairman?assign_id=${id}&evaluate_id=${evaluate_id}`,

  //แบบรายงาน
  evaluateReportcreate: (id: string) => `${evaluate}/evaluate-result/create?assign_id=${id}`,
  evaluateReport: (id: string) => `${evaluate}/evaluate-result?assign_id=${id}`,
  createformReport: (id: string) => `${evaluate}/evaluate-result?assign_id=${id}`,



  summarySurveyDetail: (id: string) => `${evaluate}/survey?assign_id=${id}`,
  summaryReportDetail: (id: string) => `${evaluate}/report?assign_id=${id}`



};
