eHealthAfrica / data-models-deprecated

Validation for standard data models
Apache License 2.0
4 stars 8 forks source link

feat: add `ward` property to Person & Case #77

Closed rmehner closed 9 years ago

rmehner commented 9 years ago

Fixes #76

danse commented 9 years ago

looks good to me. note that there are means to share data models, but probably this is overkill for ward now :+1:

danse commented 9 years ago

assigning to call centre folks for a double check

rmehner commented 9 years ago

looks good to me. note that there are means to share data models, but probably this is overkill for ward now

Gotcha, would say that we rather share address as model, seems to make more sense to me.

tillre commented 9 years ago

@jo address as model :)

@rmehner The callcenter is saving it as a string of numbers with maxlength 3. Sorry if that got buried in the chat, but mentioned it there. We could generally settle for the type that makes the most sense with wards, since the callcenter models are about to change with @jo's work. I think i used a string because it makes it easy to check its 3 digits.

rmehner commented 9 years ago

@skoni that's what I do with minimum and maximum, right?

tillre commented 9 years ago

Ye, but its not an int in callcenter.

rmehner commented 9 years ago

Ye, but its not an int in callcenter.

Sure? Because this looks like it: https://github.com/eHealthAfrica/sl-ebola-call-admin/blob/fcd4c615154369765c695a6bf5eb6be9badc853e/app/views/call-detail/tab-patient.tpl.html#L243

rmehner commented 9 years ago

Just noticed that call centre also saves the ward on the contact (https://github.com/eHealthAfrica/sl-ebola-call-admin/blob/fcd4c615154369765c695a6bf5eb6be9badc853e/app/views/call-detail/tab-caller.tpl.html#L95), so I have to change that as well :)

rmehner commented 9 years ago

Just noticed that call centre also saves the ward on the contact (https://github.com/eHealthAfrica/sl-ebola-call-admin/blob/fcd4c615154369765c695a6bf5eb6be9badc853e/app/views/call-detail/tab-caller.tpl.html#L95), so I have to change that as well :)

Fixed in 1d55c46

tillre commented 9 years ago

Sure?

Yes, the input is of type text and only-digits does not convert to a number there.

tillre commented 9 years ago

But i dont see a problem if the ward property type differs in case and person for now. We can correct that with the next migration.

rmehner commented 9 years ago

But i dont see a problem if the ward property type differs in case and person for now. We can correct that with the next migration.

Okay, so for Case it would be string, maxlength 3, for Person it would be an integer between 0 and 999.

@danse, cool with that?

danse commented 9 years ago

:+1:

rmehner commented 9 years ago

Done in 6d3e010. @skoni @danse, can I merge & release?

tillre commented 9 years ago

:+1:

danse commented 9 years ago

:+1: :+1: :+1: