Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not all TUs available in Purchase Order Lines #128

Open
metas-rc opened this issue Feb 15, 2017 · 7 comments
Open

Not all TUs available in Purchase Order Lines #128

metas-rc opened this issue Feb 15, 2017 · 7 comments

Comments

@metas-rc
Copy link
Member

metas-rc commented Feb 15, 2017

Is this a bug or feature request?

  • Bug

What is the current behavior?

  • Not all TUs are available to choose from in a purchase order line

Which are the steps to reproduce?

  • The product Frisee Industrie had a CU-TU for G1 x 10 kg

  • I added a new one for G2 x 5

  • Create a purchase order (webui)

  • Add a line for the product Frisee Industrie
    ** G1 X 10 kg is selected as TU by default

  • Try to change this TU
    ** => NOK: THe only value you can set is "None"
    ** => NOK: After setting to NONE you cannot set to G1x10 any more

  • For the product Radiesli, there are also 2 TUs : G2x10 and IFCO6410x4

  • create a purchase order

  • Create a line for Radiesly
    ** => OK: G2x10 is selected by default

  • Try to change the TU
    ** => NOK: The only ones you can set are G2x10 and None

  • Notes:
    ** the purchase order lines work correctly in swing
    ** Also, in swing, the TUs must be in the mattribute price entries of the product. The 4 TUs I used are all in the pricelists so I was able to add them in purchase orders via swing.
    ** Note that the CU-TU configurations work well on Sales side.

What is the expected or desired behavior?

  • The purchase line creation and TU selection must be similar with the one in swing.
@metas-rc
Copy link
Member Author

Followup for #112

@teosarca teosarca added this to the 2017-08 milestone Feb 15, 2017
@metas-rc
Copy link
Member Author

metas-rc commented Feb 15, 2017

I verified once again ( after a frontend update) and this time it worked, for the TUs that I introduced in the database via swing and added in the pricelist.
But both TUs were imediately available in sales order, before update.
Please add more TUs in DB and test again before starting to fix.

@metas-rc
Copy link
Member Author

I found another product with TU problems.

@metas-rc
Copy link
Member Author

order line tu problem

@metas-mk metas-mk modified the milestones: 2017-09, 2017-08 Feb 28, 2017
@teosarca
Copy link
Member

teosarca commented Mar 3, 2017

debugged and the reason is: your product/packing material is not on price list or this is how the validation rule thinks.

The reason why you were able to add it when using quick input is because there, the price list is not checked.

Technically, on quick input, the packing material is set by de.metas.ui.web.quickinput.orderline.OrderLineQuickInputDescriptorFactory.onProductChangedCallout(ICalloutField).

IMHO, the solution would be to refactor the logic from validation rules and have one place where we are validating which packing materials are allowed for given context.

But that's a request for metasfresh project and not for webui.

@metas-mk
Copy link
Member

metas-mk commented Mar 3, 2017

OK, then. We have to fix that. It shall not be any difference between validation of line editing and quick entry of available products nor Packing material.

@metas-mk metas-mk modified the milestones: 2017-12, 2017-09 Mar 19, 2017
@metas-mk metas-mk removed their assignment Apr 9, 2017
@metas-mk metas-mk modified the milestones: 2017-16, 2017-12 Apr 9, 2017
@metas-mk metas-mk modified the milestones: 2017-23, 2017-16 May 31, 2017
@teosarca
Copy link
Member

I think the fix it's not so easy, and a big part of it (if not all) would be on metasfresh project.
It would be feasible to fix/implement it when we would refactor all pricing stuff and make sure ALL pricing checkings are using ONE SINGLE API.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants