[Spce-user] REST patch customercontact does not work...

Walter Klomp walter at myrepublic.net
Fri Feb 24 01:36:15 EST 2017


If I don’t specify “reseller_id” as you can see, nothing should happen to it, or ?


> On 24 Feb 2017, at 12:39 PM, Rene Krenn <rkrenn at sipwise.com> wrote:
> 
> it is likely you tried to clear out the "reseller_id" field with the
> PATCH request. that field is mandatory for customercontacts.
> 
> users privileged to govern all resellers are allowed to change the
> reseller_id, thats what you observed.
> 
> while changing the reseller_id field is supposed to be supported,
> clearing out the field is to be prevented actually. a customer contract
> with empty reseller is a systemcontact; there's a separate api rail for
> that.
> 
> regards, rene
> 
> On Fri, 2017-02-24 at 12:14 +0800, Walter Klomp wrote:
>> Hi Alex,
>> 
>> 
>> I made the account used to call the PATCH command a “supervisor” and
>> the problem was fixed (even on mr4.5.1)…   I do find this a little
>> dangerous to be honest…
>> 
>> 
>> But… problem solved.
>> 
>> Walter
>> 
>> 
>> 
>>> On 24 Feb 2017, at 12:48 AM, Alex Lutay <alutay at sipwise.com> wrote:
>>> 
>>> Hi,
>>> 
>>> Is it reproducible with the latest mr4.5.3?
>>> 
>>> Does one customer affected only or all?
>>> (if one - probably DB issue, if all - we need to check the code
>>> then).
>>> 
>>> Can you please provide steps to reproduce it on _clean_ vagrant VM?
>>> You can find it here:
>>>> https://www.sipwise.org/doc/mr4.5.3/spce/ar01s03.html#_vagrant_box_for_virtualbox
>>> 
>>> It will speed up fix a lot here. Thank you!
>>> 
>>> P.S. I wasn't able to find any similar bugfixes internally.
>>> 
>>> On 02/23/2017 04:57 PM, Walter Klomp wrote:
>>>> We’re trying to get REST interface to work in our system.
>>>> (running mr4.5.1)
>>>> 
>>>> Why does this fail ?  Anything more we can do to debug?
>>> ...
>>>> Feb 23 14:33:46 sipwise ngcp-panel: ERROR: IP=xx.xx.xx.xx
>>>> CALLED=API[PATCH 200]/api/customercontacts/6567
>>>> TX=14A5CD28A1B708D0
>>>> USER=ossuser DATA={} MSG="" LOG="Caught exception in
>>>> NGCP::Panel::Controller::API::CustomerContactsItem->PATCH "Use of
>>>> uninitialized value in numeric ne (!=) at
>>>> /usr/share/perl5/NGCP/Panel/Role/API/CustomerContacts.pm line 102,
>>>> <$fh>
>>>> line 1.""
>>> 
>>> -- 
>>> Alex Lutay
>>> _______________________________________________
>>> Spce-user mailing list
>>> Spce-user at lists.sipwise.com
>>> https://lists.sipwise.com/listinfo/spce-user
>>> 
>> 
>> 
>> _______________________________________________
>> Spce-user mailing list
>> Spce-user at lists.sipwise.com
>> https://lists.sipwise.com/listinfo/spce-user
> 
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sipwise.com/mailman/private/spce-user_lists.sipwise.com/attachments/20170224/41eef8eb/attachment.html>


More information about the Spce-user mailing list