Create purchase pricelists for a vendor which is not the current vendor

Description

currently when creating a pricelist only the current vendor can be used to create pricelist entries. But if the same product may be bought by different vendors they normally have different prices. To generate such a pricelist it must be possible to add prices from m_product_po which are not marked as current vendor.

I'm going to extend M_DiscountSchemaLine to have a 'IsIgnoreIsCurrentVendor' yes/no-field which is shown only when a businesspartner is selected and positioned near the businesspartner. The field set to no as default to be upward compatible. If set to no even m_product_po entries are taken into account which are not marked as current vendor. Additionally I'll add a field 'VendorCategory' (next to Group1 / Group2) to be able to add / subtract on categories which are vendor specific.

Environment

None

Activity

Martin Schönbeck 
October 20, 2020 at 9:59 PM

Hi and ,

is it possible to get this change into 8.1?

Martin Schönbeck 
September 22, 2020 at 7:13 AM

Hi ,

I although thought evaluating IsCurrentVendor is superfluous when C_BPartner_ID is set. But theoretically someone could use this to create pricelists which contain only entries where the bpartner is the current vendor. So I decided to stay compatible.

The VendorCategory is necessary for vendors where the purchase price is calculated by deducting a category specific amount off the list price. There might be solutions with the current available fields but they are not easy to use for the normal user.

For the last question: if C_BPartner_ID is null, IsIgnoreCurrentVendor is not evaluated at all. At least when I did it right. Therefore it’s hidden when C_BPartner_ID is empty.

Regards,
Martin

Heng Sin Low 
September 22, 2020 at 2:46 AM

It did sounds to me the current behaviour is just incorrect when C_BPartner_ID is set for discount schema line - I think the right things to do is to ignore the IsCurrentVendor flag when C_BPartner_ID is set.

I’m not sure VendorCategory is necessary when we already have > 1 way to group vendor.

Finally, I don’t quite understand what’s the proposed behaviour here for dsl.C_BPartner_ID IS NULL and dsl.IsIgnoreIsCurrentVendor=Y - if there’s more than one m_product_po entries, which one will be used ?

Martin Schönbeck 
September 21, 2020 at 8:52 PM

I prepared a pull request with the solution described above.

Martin Schönbeck 
September 14, 2020 at 9:52 AM

,

any additional ideas on that? I’ld prefer to have it in core.

Fixed

Details

Assignee

Reporter

Fix versions

Affects versions

Priority

Created September 14, 2020 at 9:51 AM
Updated December 1, 2020 at 5:25 PM
Resolved October 30, 2020 at 12:53 PM