cancel
Showing results for 
Search instead for 
Did you mean: 

Authorization

Former Member
0 Kudos

I have a situation where I have two Purchase Manager and they want to make that they only can post to their Warehouse and not the other which another manager manages? Or they just will have their own items but I don't think you can set authorization on only seeing certain items or Warehouses?? Version 2007A

Thanks

Accepted Solutions (0)

Answers (5)

Answers (5)

Former Member
0 Kudos

Hi!

Create a UDO.

ADD UDF's to tht saying UserCode,WhsCode,Vaild (Y/N)

Add Users and Warehouses on the UDO setting Valid option.

Use Stored Procedure to Control the Access.

Ths is a sample SP wrote for Purchase Order.

--ADD YOUR CODE 
if (@object_type = '22' and @transaction_type = 'A')
BEGIN
if not exists (select P0.Docentry from OPOR P0,POR1 P1,[dbo].[@UWHS] UW1 
where P0.Docentry=P1.Docentry and
p1.Docentry =@list_of_cols_val_tab_del and
uw1.u_ucode = (select max(u1.user_code) from OUSR U1 where U1.userid=p0.usersign) and
p1.whscode = uw1.u_whscode and uw1.u_valid='Y')

BEGIN
select @error = 22
select @error_message = N'You are not allowed to select this location'
END
END
--END OF CODE

former_member209707
Participant
0 Kudos

Dear Rosi,

In the window were you create New User, Create user defaults in the default template that you create here assign a specific warehouse, to that user.

Now when he tries to create a specific document he will get his default warehouse.

You can then hide or deactivate the warehouse row in the document.

Now refuse authorization for form setting to that user.

(The only catch here is that he cannot use more tah 1 warehouse).

If you want the suer to use more that 1 warehouse pls reply we can think of some more solution/s.

Former Member
0 Kudos

they will be using the same items but can't touch the other warehouse

Thanks

Former Member
0 Kudos

Hi Rosi,

Are purchase manager specifically dealing with perticular warehouses? I mean to say if there are two items and two warehouse for ex. A & B are Items and 01 & 02 are warehouses then is purchase manager1 dealing with only A & 01not with B & 02 and purchase manager2 is dealing with B & 02 not with A & 01?

If it is like that then i can suggest some solution...............

Regards................

Former Member
0 Kudos

For blocking the posting to any Warehouses, SP_TransactionNotification could be used. For item level authorization, only SDK or Add-on could used to reach your goal.

Thanks,

Gordon