0

I am trying to get Privatemsg and DrupalGap working together.

I have installed both modules, configured the privileges and everything is working fine in the drupal site.

But with phonegap I am getting trouble displaying the 'Send this user a private message' link in the view of each user. I have set 'visible' the 'private msg' field in the drupalgap display in: admin/config/people/accounts/display/drupalgap but it's not working.

I have noticed It's always displaying only the history field even if I set to 'hidden' all the fields in the view configuration page: admin/config/people/accounts/display/drupalgap

I have cleared all caches.

What am I missing? How can I have the 'Send this user a private message' link displayed?

1

DrupalGap's implementation of Private Message has not evolved enough to take into consideration any Private Message configuration set on a DrupalGap Manage Display page for User Entities.

That being said, I would recommend creating your own page to custom render a User Entity. With these docs, essentially replace the usage of node with user and that'll give you a custom page in which you can render your users.

Then in your page_callback function to render the users, you can add a widget to the content render array, which could display a button that when clicked will navigate the user to a custom DrupalGap form+page where you can build the input elements (recipient, subject, message, etc).

Then in your form's submit handler, you'll actually send the message to the user.

  • Thank you for your answer. Putting privatemsg issue aside....in the user_view_pageshow(uid) function in the drupalgap core there is a line: var view_mode = 'full'; It should be var view_mode = 'drupalgap'; right? – Alfonso_MA Aug 24 '17 at 19:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.