gu-tum-gun-aeng / med4all-external-routing-agent

MIT License
0 stars 0 forks source link

[external-routing-agent] Implement wisible pipeline name logic #10

Open catflyflyfly opened 3 years ago

catflyflyfly commented 3 years ago

Task: Implement function pipeline in src/model/wisible/mapper/wisible.request.mapper.ts

Psuedocode: Source: @avafund

if(ageYear <= 15)
  pipelineName = "ยาเด็ก"
else{
  if(isPregnant || isDiseaseUncontrollDm || isDiseaseCirrhosis || isDiseaseCirrhosis2)
    pipelineName = "ยาคนท้อง โรคตับ เบาหวาน"
  else{
    if(weightKg > 90)
      pipelineName = "ยาแพคใหญ่ (นน>90 OR BMI>30)"
    else pipelineName = "ยาแพคเล็ก (นน<90)"
  }
}
callWisibleAPI();