Fixed multiple bugs in linking patient notes to documents.
Modifications made to enable 'Pre Pay' Option in Self Payment
Signed-off-by: BASIL <basil@zhservices.com>