add get name with email as one string from new user model to prevent double code

This commit is contained in:
Dario 2020-06-29 14:23:19 +02:00
parent 07ff9be91e
commit b35cab768c

View File

@ -52,6 +52,7 @@ namespace model {
inline const std::string& getEmail() const { return mEmail; }
inline const std::string& getFirstName() const { return mFirstName; }
inline const std::string& getLastName() const { return mLastName; }
inline std::string getNameWithEmailHtml() const { return mFirstName + " " + mLastName + " <" + mEmail + ">"; }
inline const Poco::UInt64& getPasswordHashed() const { return mPasswordHashed; }
inline RoleType getRole() const { if (mRole.isNull()) return ROLE_NONE; return static_cast<RoleType>(mRole.value()); }
inline const unsigned char* getPublicKey() const { if (mPublicKey.isNull()) return nullptr; return mPublicKey.value().content().data(); }