AnsweredAssumed Answered

Filtering Value Lists / Conditional Value Lists - based on available stock

Question asked by CStovin on Apr 1, 2013
Latest reply on Apr 29, 2013 by CStovin


Filtering Value Lists / Conditional Value Lists - based on available stock


     As a newbie, My  Asset Management / BOM ?  solution I think is further along than my level of understanding thanks to the help I've been given from the forums here.  I feel pretty grateful that a community as such exists.  I still have not attempt to add on the BOM ( assembly / group KITS ) part to my Inventory as I feel I still need to work out some under the hood neccesities in the other tables.

     CONTACTS ----> ORDER -----> LINES <-------- INVENTORY

     LINES::items_out,  is an amount field in my LINES::Portal, which shows how many items of an INVENTORY item is being loaned  "out"  ( this is not a representation of the actual amount in stock )

     LINES::items_out, I also have displayed  on my INVENTORY item history layout in a portal....

     INVENTORY::amount_in_stock,  Is a value entered

     INVENTORY::subtotal_portal = SUM(LINES::items_out)

     INVENTORY::available = INVENTORY::subtotal_portal - INVENTORY::amount_in_stock


     When I return items in ORDER, the LINES::items_out  field clears,   which also updates the same field displayed in the INVENTORY layouts.  Although sometimes I am experiencing window flashing and not immediate updating in different layouts until a number of "clicks" happens in other fields.... Sorry I'm not sure what causes the slight lag... Doesn't always seem to happen that I'm aware of....

     ANyhoo... what I am after ::

     I have tried to create a Filtered field which would than be used in a value list - but did not work, got errors saying could not use this field as could not be indexed because was either related , or a calculation etc....

     In INVENTORY::available_choice  (calculation field)  =

     IF (

     available > "0" ; manufacturer_name & " " & product_name & " " & model_name )

I only want the items in Inventory that are available " have a greater value than 0 " to appear as a selection in my drop down   _kf_products_id  which is in my LINES:: portal.    THe above calculation did not work... said can not be indexed

     the graph is LINES::_kf_products_id   ------>>  INVENTORY::_kp_products_id   ( with allow creation of records checked in LINES, no check on the deletion )

     _kf_products_id  -->   value list:: products = (from field) INVENTORY::_kp_products_id  ( first field)    ,  INVENTORY::available_choice   (second  field)          -----> only show values from second field.

     soooooooooooooo.... this did not work for me, but when I got rid of the conditional calculation and just made INVENTORY::available_choice  =  manufacturer_name & " " & product_name & " " & model_name

     it worked..... but shows everything in INVENTORY.



     Can anyone see what I might have missed ?