Feature Request for our Business Case: Stock decrease when creating invoice or shipment, but not during both. Or a provision to select multiple warehouse when creating invoice

So to begin with, Dolibarr is a great software and I cannot imagine the work behind it. Glad to see such a software as an open source platform.
What I don’t understand is that the forum is really quite and I am not exactly sure why!

Anyway, focusing on two issues.
Issue A. Stocks module setup is okay. But one can either decrease the stock when creating invoice “And” when creating shipment. We want to use “Or” for each order.
So if we create a shipment, we want it to decrease stock, but then when we are invoicing the same order after shipment, we don’t want to decrease the stock again as you can imagine that is a repeated task.

Use cases:

  1. When the material in order is stored at two or more warehouses, then since we cannot select more than one warehouse during invoice validation, we want to create a shipment and then create a invoice.
  2. Material is being dispatched but not invoiced as the order is being dispatched partially. Then when complete order is dispatched, a invoice is to be created.

Issue B: Recently, all the text boxes would add a extra spaces and a small “x” at the end of the text box if it has content or else would just add it there.

If required, will add screenshots here as well.

Hello

in fact, you should only choose one option for stock decrease, I think this is the only good issue !!

On the Dolistore, there is a module named “Expedition to bill” that permit to join various shipments in a new invoice…https://www.dolistore.com/en/crm/381-Expedition-to-bill.html

for your last question the “x” symbol depends probably of your browser…

Good continuation

Dear pcbleu,

Thank you for the response.

I agree on selecting only one option for the stock decrease. Thus, we have selected only the option to decrease stock when making an invoice. But then when we ship the products, they are all still shown in physical stock, which is not correct as well.
But if we also select the option to decrease the stock when we create shipment, then it reduces stock twice - once when creating a shipment and once when we create an invoice.

This is bugging me as there is no way to decrease stock from two warehouses for a single order. And I have 120 (warehouses and sub-warehouses in total) which makes it very difficult to reduce stock during invoicing.
And we don’t always create a shipment, thus I cannot only use that option because in 60% orders, it doesn’t make sense to make a shipment. These are open and close orders which can be processed fast and easily using just an invoice.


For the “x” symbol, I think that is true. Others in my organization are not facing the same issue. They use Google Chrome and I use Safari for most of the time.
Will try it with Google Chrome and see, but in case there is something that can solve it for Safari, then there is nothing like that. So, any pointers would be helpful.

I am also posting another thread for being able to see virtual stock on products list page (This option somehow is related to the increase/decrease stock setup). If I enable the option to decrease stock when creating a shipment then I can see an option to add virtual stock on the products list page, or else I don’t see it there. Not sure why it is setup that way. But I am attaching screenshots for that here as well.

I actually resolved the virtual stock option just now.
While typing about it, I thought about it and tested a very very small change and boom it hit the right spot.

Just changing the following line on /product/list.php page (line 127 - version 11.04) works.

Change it to virtualdiffersfromphysical = ‘1’ before the IF Loops. That does the trick.

Using “or” is very strange. It means you will change stock twice. It seems for your case A that stock decrease in shipment is enough.
If you did not set stock decrease at shipment, it means the virtual stock will always be similar with real stock. So showing virtual stock is useless (according to code).
Do you have an example of what can make a virtual stock different than a real stock when stock decrease is not on shipment or reception ?

Dear Eldy,

First of all, you and the team have created an amazing product. I cannot appreciate the efforts enough. You guys are awesome!

Now the way our business model works is that we have customers who place and order through our online and offline sales channel and we also have customers who just walk in the store to collect the merchandise.

Case A – When the order is placed in advance, we create a sales order (this means stock quantity of the order should be booked for them and our sales people should be able to know that the quantity still available to sell - which is handled by virtual stock).
After the sales order is ready for dispatch, we create a shipment (and we want to reduce the physical stock then), but in the end we still create an invoice.

Case B – When the customer comes to directly purchase the material, we directly move on to invoicing step and skip the sales order module and we also skip the shipment module for that situation.

Now since the setup for stocks module is in such a way that we have a few options to decrease and increase stock as per the screenshot attached:

So for Case A, we need to reduce stock when creating a shipment because the physical stock actually reduces with the shipment.

And for Case B, we need to reduce stock when creating an invoice.

So our actual feature request is to allow reduction of stock when creating an invoice (unless for that sales order a shipment has been created - then in that case reduce stock during shipment and NOT again when creating an invoice).

Same for purchase orders.
We don’t always generate a purchase order (orders below a set value can skip the purchase order module and product reception module).
Similar logic there as well. Increase stock with vendor invoice unless a purchase order is created with products reception entry.

I hope this makes sense, let me know and I will give more details examples maybe.

Currently it is not possible to have a stock decrease rule that depends on the workflow that will be done later on order.
You must definitely choose between stock decrease on invoice validation (it means you don’t make shipment) or stock decrease on shipment (and only shipment will decrease your stock).

Dear @eldy,
Thank you for the response.
I will just let everyone know what we did so in case they need a similar solution, they might be able to use something like this as well.

  1. For orders that need processing, we now decrease stock on shipments only. So this way when we ship the orders or they are picked up from store - we make a shipment entry and then the invoice.
    (This also helps us track all our shipments in one place).

  2. For orders that are walk in store customers, we use POS module and we decrease stock on POS Invoices as well. (There is an option on POS Module Setup Page).

So now, my question is how to edit prices on POS page itself?
Sometimes our prices vary and they might not be adjustable with the default pricing. (We are trying to get more organized in this sector but in the meanwhile, is there a way to edit the prices directly on the POS Page? I have highlighted the same on the screenshot. It is greyed out and is un-editable unfortunately.

The SimplePOS module will probably abandonned because the TakePOS module available in v10, v11 an v12 is better now. A’nd with TakePOS, you should be able to edit price

Dear @eldy,

Thank you again for the response.
I took a look into the TakePOS module. I love the interface and the module.
The only problem I am trying to figure out right now is how to add a delayed payment option. If the payment would be received on a later date, how can we add a delayed payment due date while using the TakePOS module?
Screen Shot for payment options in TakePOS & SimplePOS attached.


I tried finding a few answers on google & forums but did not find any options there either.

Any help would be appreciated.

Dear @eldy,
I just realized, we could just create shipments directly for the all the orders and not worry about the POS at all.
Can you please guide me how to make a shipment directly without creating an order?
Screenshot attached for the error when we try to create shipments directly.

If payment is delayed, it means it is not paid. The goal of a POS is to record payment. If payment is delayed, you don’t need a POS system. Creating an invoice in the backoffice may be enough.

Dear @eldy,

As per this thread as you can see, we are struggling with stock decrease when creating shipment and invoice.
So, currently, I have our setup to decrease stock when making a shipment (Not when making an invoice). But there are times when we would like to decrease stock directly from an invoice so we decided to make those invoices through POS. But our payment terms are all processed later.

So now, I have either an option to make shipments directly without an order. Or I need an option to make delayed payments on TakePOS. Either way, I would be able to maintain real stock with accuracy. But both AREN’T default behaviors so I need help with either one.

Thank you again for your time and efforts.

With TakePOS, you should be able to make delayed payment. Did you try with 12.0.2 ?

Dear @eldy,

Thank you for the update.
I actually reached out to Andreu (from the TakePOS Team) directly through their website - http://www.takepos.com a few days ago.

We asked them for 3 customizations (Customizations for each of them are attached).

  1. They helped us with this delayed payment option customization. I am not sure how it is in the V12.0.2

  2. We also customized our TakePOS to be able to change warehouse from the POS Module itself (to reduce stock from different warehouses based on the product - but only one warehouse can be selected in one invoice as per dolibarr workflow).

  3. We also now see exclusive tax amounts for products and edit those directly from POS. Also an extra POS Returns module was added.


I am mentioning these changes here so that you can reach out to them for such changes. Some of them are easy to implement as well, I am sure you can figure some of them out. I think sharing the files would be un-ethical as TakePOS is already free and they charge a very nominal fee for customizations, so you might want to reach them out. He is a great guy.

1 Like