hospitalrun-frontend icon indicating copy to clipboard operation
hospitalrun-frontend copied to clipboard

create `useCreatePatient` react-query hook and remove redux create patient code

Open jackcmeyer opened this issue 3 years ago • 9 comments

🚀 Feature Proposal

This feature is to create a useCreatePatient react-query mutation which will create a patient.

Motivation

  • removing redux

Technical Notes

  • this will follow a similar pattern to useRequestImaging
  • make sure to remove all redux code related to creating a patient

jackcmeyer avatar Sep 09 '20 04:09 jackcmeyer

is this issue somehow related to this? @jackcmeyer it happens in localhost and also in https://staging.hospitalrun.io/patients/new -> Create New Patient -> Save, only when opened using Firefox (normal in Chrome)

error: true
message: "unknown"
name: "indexed_db_went_bad"
reason: "A mutation operation was attempted on a database that did not allow mutations."
stack: ""
status: 500
Screen Shot 2020-09-10 at 11 16 32

djiwandou avatar Sep 10 '20 04:09 djiwandou

I don't think so! This code is to do a refactor of how the save of the patient works.

I wasn't aware of any any bugs related to saving a patient.

If this is a reproducible issue, could you open another bug please?

jackcmeyer avatar Sep 10 '20 04:09 jackcmeyer

yes, it could be reproduced in my case it's only in Firefox I will open new issue for this 🙏 cheers

djiwandou avatar Sep 10 '20 06:09 djiwandou

@djiwandou thanks for pointing this out! Would you like to give it a shot?

fox1t avatar Sep 10 '20 09:09 fox1t

wew I am still newbie, maybe not yet for this one hehe ✌️ @fox1t

djiwandou avatar Sep 11 '20 07:09 djiwandou

@djiwandou :)

fox1t avatar Sep 11 '20 09:09 fox1t

Hey! Can I take this issue?

ArtemGoldsmith avatar Sep 14 '20 23:09 ArtemGoldsmith

Sounds good @ArtemGoldsmith!

jackcmeyer avatar Sep 15 '20 04:09 jackcmeyer

I see this story was picked up long time ago. Can I take this one?

giulianovarriale avatar Oct 31 '20 08:10 giulianovarriale