Skip to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Discounts in different Product Categories

Featured Replies

Hi,

I’ve been looking for ages and don’t seem to find any info on this relation.

I need to be able to give individual customers discounts on different Product categories. When the Product is selected, the Line item should get that Discount from that specific customer. How do I get those categories to display on the Customers Contact so I can apply a discount on each of the categories? How do I relate this Info?

Am I dumb or is this really that hard?

Looking forward to your reply! Thanks

Ron

Hopefully do you have a relational structure similar to the attached image, what I use is that the category an item belongs to is used to get the right discount value in the other end of the chain of TO's, I've according to the nature of being a historic snapshot used autoenter fields to get the price as well as the discount ... so if you later raise or lower the price or discount-rate won't it affect the previously issued invoices.

I autoenter the discount by using this calc:

GetNthRecord ( Discounts::Discount ; Items::Category )

This way could each customer have his/her own say 10 discount rates, the category in the chosen item redirect to right one of the 10.

--sd

Billede_1.jpg

Edited by Guest

I believe the core structure should be more like this:

rg.png

Doesn't it allow several discounts for each category/customer associations??? Do you mean that quantity also makes the selection??

--sd

Even if quantity is not a factor, the relationship between Customers and Categories is still many-to-many:

Customer 1:

• Products in Category A - 10%

• Products in Category B - 7%

Customer 2:

• Products in Category A - 5%

• Products in Category B - 3%

So put RG'ish instead of ERD'ish do you mean this?

--sd

Billede_1.jpg

Probably - haven't tried implementing it myself, but it seems about right.

  • Author

Thanks for that. It's working as required.

I've got a Portal for the Discounts and a Dropdown for the User to select a Category in it. Is there a way to get FM to filter already selected Categories? Otherwise the User could use the same category multiple times, resulting a conflict.

Regards and once more thank you!

Ron

Is there a way to get FM to filter already selected Categories?

Yes, pretty easy actually!

http://www.databasepros.com/FMPro?-DB=resources.fp5&-lay=cgi&-format=list.html&-FIND=+&resource_id=DBPros000735

Just remember that the keyfields on both sides are bound to be of the same field type! Due to use of List( must both sides be text.

--sd

  • Author

Thanks! Works great.

Regards

Ron

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.