I am not an expert so I really appreciate all the knowledge transfer. Even though I have finished IU and have been working in Igniition for a while, some of these things are still very new to me, like the Flex. I have looked into that and I can see where that would be preferable to what I created.
I am hoping I am not wasting anyone's time but I am still a little unclear.
I am going to start from the first view and hope I can explain well enough.
I first created a view "ASRS Pallet Location". (pic1)
The bindings do not really affect anything other than the BinLocation which takes all the Aisle, Depth, Level, RackField, RackPlace, and RackSide and put them in order for the warehouse Bin. All 6 of these are manually entered later in the main view.
I then took the view/template "ASRS Pallet Location" and embedded it into the main view multiple times, I think there are 200+ of these embedded into the "ASRS_Cooler_T" view.
Next pic shows a selection of 3 of these embedded into the "ASRS_Cooler_T view".
Each ASRS Pallet Location that is embedded has its own unique BinLocation.
I also created a POPUP table "ASRS Pallet Lookup1".
The table refernces a named query "CFG Queries/asrs_pallet_lookup1" with a parameter in it looking for the BinLocation from the embedded view. I can type in a bin location and it works fine. I just cannot figure out the part of pass the variable binlocation from all the embedded view.
SELECT CONCAT(CAST(b.pos_a as CHAR),' ', CAST(b.pos_r as CHAR),' ',CAST(b.pos_xf as CHAR),' ',CAST(b.pos_xp as CHAR),' ',CAST(b.pos_y as CHAR),' ',CAST(b.pos_z as CHAR)) as "BinLoc",
a.lpn as "LPN", a.sku as "SKU" , a.quantity as "QTY" , a.received_inducted_ts as "Timestamp" ,a.sub_status as "Status", a.dest as "Destination", a.lot_number as "Lot Number", a.Reason_Code_Last as "Reason Code", b.row_locked as "Locked Status", a.qc_status as "QC Status"
FROM pallets a
INNER JOIN dambach_xref b
ON a.dambach_xref_id = b.id
WHERE a.dambach_xref_id > 10000 and a.dambach_xref_id < 13000 and b.area = 2
UNION
SELECT CONCAT(CAST(b.pos_a as CHAR),' ', CAST(b.pos_r as CHAR),' ',CAST(b.pos_xf as CHAR),' ',CAST(b.pos_xp as CHAR),' ',CAST(b.pos_y as CHAR),' ',CAST(b.pos_z as CHAR)) as "BinLoc",
a.lpn as "LPN", a.sku as "SKU" , a.quantity as "QTY" , a.received_inducted_ts as "Timestamp" ,a.sub_status as "Status", a.dest as "Destination", a.lot_number as "Lot Number", a.Reason_Code_Last as "Reason Code", b.row_locked as "Locked Status", a.qc_status as "QC Status"
FROM pallets a
INNER JOIN dambach_xref b
ON a.dambach_xref_id2 = b.id
WHERE a.dambach_xref_id > 10000 and a.dambach_xref_id < 13000 and b.area = 2
AND location = :lookLoc
I am thinking that I can create a new script on each embedded view to open the popup and then have the popup execute the query above using the BinLocation from embedded view that was clicked to open.
Here is my poor attempt at the query to open the popup, which works, it just does not run the query.
I am sure it is not coded correctly...
system.perspective.openPopup("Pallet Info", "Popups/MHS Converted/ASRS Pallet Lookup1", params={"view": self.getSibling.__getattribute__('BinLocation')})