en:dev:pnlbhp

op.care.bhp.PnlBHP

This Panel is handling the BHPs for the daily access by the nursery staff. The user can apply, refuse, refuse (with discarding the medication), undo the several BHPs presented.

Internal module ID: nursingrecords.bhp

ACLeffect
PRINTprint the daily plan of all BHPs
UPDATEnecessary to generally modify the several BHPs. this should only be granted to trained personell.

Besides the ACLs there are further professional reasons to allow or prevent the access to the BHPs. To tell if a BHP may be changed, it is vital to consider the state of the BHPs and some other issues.

There is one method that has a very important role in the authorization chain: BHPTools.isChangeable(BHP bhp). This method is only useful for BHPs, that are not open anymore.

It returns true (hence empowering the user to change the BHP) when the following conditions are satisfied:

  • the time (in minutes) between confirming (apply) the BHP and now doesn't exceed SYSPropsTools.BHP_MAX_MINUTES_TO_WITHDRAW, which is currently hardcoded in the connected database table sysprops.
  • the underlying prescription is not closed
  • this BHP must not be open, and the user trying to change it now, is the same one who confirmed it in the first place.
  • the resident is active in the system and not currently absent
  • if there is medication involved, there must not be any trouble with it. meaning:
    • if the medication's stocks should be calculated, the there must be an accessable stock in use.
    • it is way to complex to undo withdrawals for more than one stock1). Therefore the user CANNOT undo them.

the user can apply, refuse or refuse (discard) a BHP if:

  • it is still open (of course)
  • the underlying prescription is not closed
  • the method BHPTools.isChangeable(BHP bhp) returns true.

a user can reset a BHP to the open state if:

  • it is NOT open
  • the underlying prescription is not closed
  • the method BHPTools.isChangeable(BHP bhp) returns true.

1)
which can happen if a stock is emptied during the cause of the confirming the BHP and a new stock is opened and used automatically
  • en/dev/pnlbhp.txt
  • Zuletzt geändert: vor 8 Jahren
  • von opdeadmin