on 05-18-2011 1:40 PM
Dear Experts,
We want to restrict our users from changing payment terms while adding A/R Invoice.
We use SAP B1 2007 b.
Thanking you
Pradnya
Hello,
Have you solved the issue and finding the solution ?
because first you define that which user can change your payment terms then your SP will work accordingly.
i have made for same sales order.
Thanks
Manvendra Singh Niranjan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Pradnya.....
Try this.....
If @object_type='13' and @transaction_type='A'
BEGIN
If Exists (Select * from [dbo].[OINV] T0 Inner Join INV1 T1 On T0.DocEntry=T1.DocEntry Left Join DLN1 T2 On T2.DocEntry=T1.BaseEntry Left Join ODLN
T3 On T2.DocEntry=T3.DocEntry
Where T0.DocEntry = @list_of_cols_val_tab_del and T0.GroupNum <>T3.GroupNum)
BEGIN
Select @error = -1,
@error_message = 'You can not change Payment terms'
End
End
Regards,
Rahul
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Rahul,
I have already tried something like this in test database on BP master.
But no results.
If @object_type='2' and @transaction_type='U'
BEGIN
If Exists (Select groupnum from ocrd Where T0.DocEntry = @list_of_cols_val_tab_del )
BEGIN
Select @error = -1,
@error_message = 'You can not change Payment terms'
End
End
Thanking you
Pradnya
Hi Rahul,
I have already tried something like this in test database on BP master.
But no results.
If @object_type='2' and @transaction_type='U'
BEGIN
If Exists (Select groupnum from ocrd Where T0.DocEntry = @list_of_cols_val_tab_del )
BEGIN
Select @error = -1,
@error_message = 'You can not change Payment terms'
End
End
Thanking you
Pradnya
Hi,
try below code in transaction notification procedure:
if (@object_type = '13') and (@transaction_type IN ('A', 'U'))
BEGIN
IF exists (select T0.DocEntry FROM OINV T0 Inner Join OCRD T1 on T0.CardCode=T1.CardCode Where T0.GroupNum !=T1.GroupNum and T0.DocEntry =@list_of_cols_val_tab_del)
Begin
SET @error = 30
SET @error_message =N'You are not authorized to change payment terms'
end
END
for how the transaction notification works or how to use :
Thanks,
Neetu
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Neetu,
Hi Rahul,
I have already tried something like this in test database on BP master.
But no results.
If @object_type='2' and @transaction_type='U'
BEGIN
If Exists (Select groupnum from ocrd Where T0.DocEntry = @list_of_cols_val_tab_del )
BEGIN
Select @error = -1,
@error_message = 'You can not change Payment terms'
End
End
link provided by you gave me an insight. It is very helpful indeed.
Thanking you
Pradnya
Hi Neetu,
have already tried something like this in test database on BP master.
But no results.
If @object_type='2' and @transaction_type='U'
BEGIN
If Exists (Select groupnum from ocrd Where T0.DocEntry = @list_of_cols_val_tab_del )
BEGIN
Select @error = -1,
@error_message = 'You can not change Payment terms'
End
End
link provided by you gave me an insight. It is very helpful indeed.
Thanking you
Pradnya
Hi Pradnya.......
You can use SP transnotification or better if you use Approval Procedure.
Regards,
Rahul
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
98 | |
11 | |
11 | |
6 | |
6 | |
4 | |
4 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.