My Products
Help
kashyap
PARTNER

Visma.net customerInvoice and customerCreditnote not able to add stock item in line

by kashyap

Hello,

1. We are using both APIs customerInvoice and customerCreditnote, in both APIs we are getting error like: You cannot add Stock Item XXXX on line

 

2.  In customerCreditnote we cannot send hold=true, and also not able to release the creditnote from UI its showing error on balance field where amount in negative

Note: We are not creating any order before creating invoice or creditnote for customer.

 

 

 

12 REPLIES 12
kashyap
PARTNER

by kashyap

Is there  anyway to set stock item to not consider the stocks  while creating salesorder or at inventory item level?

by Magnus Johnsen

Hi,

What is the workflow you are trying to fulfill?

A stock item is designed to use the warehouses, a non-stock item will not as it is not designed to be tracked in the warehouses as you don't carry it in your stock. Would this be sufficient for your use or is it anything else you need?

kashyap
PARTNER

by kashyap

One of client needs to create all product as stock item but don't want to manage stock as of now. 

They just want issue invoice to customer for now. They start managing stocks later. 

by Magnus Johnsen

Hi,

I suppose you could untick this box in the UI(ScreenId=SO101000):

2022-05-02 14_54_02-Settings.png

However as this is a question regarding how the ERP operates, we would recommend that you or your customer contact your partner service or the ERP support for the best way to handle this. 

kashyap
PARTNER

by kashyap

Is there any way to  allow all products to go in negative stock?

by Magnus Johnsen

Hi,

Currently the Customer Invoice functionality is split up in two parts:

1- Invoices and Memos & Customer Invoice :
ScreenID=AR301000 - ARInvoiceEntry managing nonstock invoices

2-Logistic Sales Invoices
ScreenID=SO303000 - SOInvoiceEntry managing stock and non-stock invoices

 

StockItems need to be invoiced via the salesOrder Invoice.

 

Regarding the balance on your creditNote, the amounts here should be entered as positive, when released it will create a journalTransaction that is reveresed:

2021-09-30 12_52_03-Journal transactions - Brave.png

kashyap
PARTNER

by kashyap (Updated ā€Ž30-09-2021 14:24 by kashyap PARTNER )

Answer to query1:
Do you mean I have to create salesOrder first >> then convert the salesOrder to invoice OR
If amount in negative then I have create salesOrder >>  make invoice >> create creditnote of an invoice?


Answer to query2: We are sending everything positive except the quantity field. Still we are not able release it via API using hold=false. Also not able to release from the user interface or backoffice.

 

by Magnus Johnsen

Hi,

1. You should create a salesOrder(ScreenId=SO301000) type "IN" for invoices and "CM" for credit notes.

As the action "prepare invoice" is not yet exposed via the API, you then need to either manually release them in the UI:

2021-10-01 10_35_02-Sales orders - Brave.png

Or create an automated schedule(ScreenId=SM205020):

2021-10-01 10_38_32-Automation schedules - Brave.png

If you need more help to setup an automated schedule, please contact your partner service or have your customer contact the ERP support.

 

2. All fields should be sent positive, the creditNote will when released create a reversed journalTransaction, no need to specify a negative amount as it is a "negative" document. 

kashyap
PARTNER

by kashyap

We have changed the code and  start using salesOrderV2 API.  Now we have faced another issue.

How can I convert non stock item to stock item? We are receiving below error while updating products.

{"message":"Error: Updating 'Stock item' record raised at least one error. Please review the errors.\r\nThe class you have selected cannot be assigned to a non-stock item, because the Stock item check box is selected for this class in the Item classes window. Select another item class which is designated to group non-stock items.\r\n"}

by Magnus Johnsen

Hi,

You can still enter non-stock items on a salesOrder.

As far as I know, you wont be able to change a non stock item to a stock item.

kashyap
PARTNER

by kashyap

In one of client we are receiving below error while saving sales order

Error: Inserting 'Sales order line' record raised at least one error. Please review the errors.
Error: 'Warehouse' cannot be empty.

Can you please help me in which case we need warehouse?

by Magnus Johnsen

Hi,

You would need to go over each line one by one, we recommend that you either enter the order in the UI or try to find what stock items are missing default warehouse via a generic inquiry.