request.ts 565 B

12345678910111213141516171819
  1. import { Post } from "../../../lib/request/method"
  2. import { transformHealthIndex2Chart } from "./health-index";
  3. const careId=wx.getStorageSync('careId')
  4. export function healthIndexReportMethod() {
  5. if(careId)
  6. {
  7. return Post(`/patientCrManage/getPcrProcessById/${careId}`, {}, {
  8. transform({ data }: any) {
  9. return transformHealthIndex2Chart(<any[]>data.patientQuotaGroups)
  10. }
  11. })
  12. }else{
  13. return Post(`/patientQuota/getQuovalRecord`, {}, {
  14. transform({ data }) { return transformHealthIndex2Chart(<any[]>data) }
  15. })
  16. }
  17. }