reactioncommerce/reaction-admin

Unable to invite members on beta 8 admin-ui

manueldelreal opened this issue · 2 comments

Issue Description

Invite to members of any of the defined groups fails in current 3.0.0 beta-8.

Steps to Reproduce

  1. Login to the admin UI with an admin user
  2. Go to the accounts section
  3. Click on Invite staff member button
  4. Enter a valid email, select group, save changes

Actual results
A couple of errors are shown coming from the API and the member can't be invited
Error1: Field groupId of required type ID! was not provided
Error2: Field "groupIds" is not defined by type InviteShopMemberInput. Did you mean groupId or shopId?

Possible Solution

It seems that we have a typo on how we are constructing the mutation and passing groupIds instead of groupId which is what the API expects.

GroupIds is the correct parameter to use, see https://github.com/reactioncommerce/api-plugin-accounts/blob/bc8307a1295f808a1641c9cfbdf88f74b1a877d5/src/resolvers/Mutation/inviteShopMember.js. The error above indicates that the API is not running the latest api-accounts plugin.

confirmed not seeing this one after updating to api-plugins-accounts v1.4.4