Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • Nov 21 19:10
    mfeifer labeled #32
  • Nov 21 19:10
    mfeifer unlabeled #32
  • Nov 21 19:10
    mfeifer labeled #32
  • Nov 08 22:05

    Fryguy on master

    Optionally symlink spec/managei… Merge pull request #84 from agr… (compare)

  • Nov 08 22:05
    Fryguy closed #84
  • Nov 08 22:05
    Fryguy labeled #84
  • Nov 08 22:05
    Fryguy milestoned #84
  • Nov 08 22:05
    Fryguy assigned #84
  • Nov 08 13:51
    miq-bot commented #84
  • Nov 08 13:50
    agrare synchronize #84
  • Nov 08 13:39
    agrare edited #84
  • Nov 08 13:37
  • Nov 08 13:28
    agrare opened #84
  • Nov 06 17:47
    simaishi assigned #83
  • Nov 06 17:47
    simaishi milestoned #83
  • Nov 06 17:47
    simaishi labeled #83
  • Nov 06 17:47

    simaishi on ivanchuk

    Test ruby 2.5.5, see: https://g… Merge pull request #83 from d-m… (compare)

  • Nov 06 17:47
    simaishi closed #83
  • Nov 06 16:54
    miq-bot commented #83
  • Nov 06 16:43
    miq-bot edited #83
Martin Hradil
@himdel
yay! :) Cc @abellotti ^^ (i'm not sure how API docs are generated, or from where)
Martin Hradil
@himdel
( => addressed in ManageIQ/manageiq_docs#1187 )
@himdel thanks
Martin Hradil
@himdel
thank you :)
Joe VLcek
@jvlcek
I tested with "action" : “edit"
Martin Hradil
@himdel
aah
Joe VLcek
@jvlcek
Testing now with "action" : "set_current_group”,
But it’s not working :(
JVue
@JVue
did “action” : “edit” work?
Joe VLcek
@jvlcek
yes
@JVue this example works:
JVue
@JVue
ok thanks @jvlcek
Joe VLcek
@jvlcek
@himdel can you please point me to where the SUI does this?
Joe VLcek
@jvlcek
@himdel thank you
JVue
@JVue
@jvlcek I tried the edit method and it returned:
{
    "error": {
        "kind": "bad_request",
        "message": "Cannot update attributes other than password, email, settings for the authenticated user",
        "klass": "Api::BadRequestError"
    }
}
my id is currently set to a group that has very restricted permissions …(not sure if this matters… it shouldn’t imo)
Joe VLcek
@jvlcek
I think that is your issue with that one.
JVue
@JVue
I changed my ID to admin role and it worked now
Joe VLcek
@jvlcek
:thumbsup:
JVue
@JVue
the set_current_group doesn’t appear to have this limitation tho
(the intent was to be able to change the user group regardless of which group is currently selected for them)
Joe VLcek
@jvlcek
@JVue I will investigate
JVue
@JVue
awesome.. thanks @jvlcek
Alberto Bellotti
@abellotti
@himdel re: doc, nothing fancy or automated unfortunately. Manual process of going through PRs in a release and creating one monster PR in docs.
Joe VLcek
@jvlcek
@JVue set_current_group can only be used to set the current group to a group the user already belongs to and set_current_group can only be used by the authenticated user
So you can not use admin to set_current_group for my_happy_user_42
And my_happy_user_42 needs to already belong the group being set at the current group.
JVue
@JVue
yep… got all that.
Joe VLcek
@jvlcek
But href, id and description can each be used to specify the current group for both edit and set_current_group
I put together 6 examples
JVue
@JVue
ok
I hope those help.
JVue
@JVue
yeah - basically we’re having users hit a gateway api that reaches out to miq’s api to do certain functions (using their creds/auth_token)… however this breaks (permission issue) when their current selected group is not set to the proper one. the work around is for them to manually login to miq’s portal and change their current group there, then go back to the api… which isn’t ideal. Hence getting this api to change current group would help tremendously.
i think i have most things working with the resolution earlier… I’ll go thru your examples above as well.
Thanks @jvlcek . much appreciated!!
Joe VLcek
@jvlcek
@JVue If the user’s Groups list contains the group the want to use the API should be usable to set_current_group to the one the user wants.
JVue
@JVue
^yes, all users already have a list of groups that they go between… so the change would just be within those set groups.
Alexander Braverman Masis
@abraverm
tlv
Miha Pleško
@miha-plesko
hi, is it possible to have REST API return additional fields on model's GET?
like GET /api/something/:id currently returns all models attributes, but I want to render additional one
Martin Hradil
@himdel
@miha-plesko ?expand=resources