For example, when managing cross sells, I envision a text area where you can optionally enter product IDs or SKUs, but a link next to it titled "product selector". Clicking on the link would pop open a window with some kind of filter search and paginated product list. You'd check a check box next to the products you wanted and then hit the "add selected" button at the bottom of the page that would add the selected IDs or SKUs to the value of the text area. I don't love the idea of a text area although it has the benefits of allowing for manual entry and being simple - maybe another approach would be a multiple select with values being added based on either entries into a text box or on those selected using the pop-up.
I guess what I'm wondering is if anyone has seen a good example of a fairly slick such system that could be generalized and generated for the generic case where you need to use a pop up to select n-elements of an object and return titles and values to some kind of underlying page with a select box. I'm a complete JS n00b, so I'm really trying to find to find a slick sample that I could dissect, generalize and use as a custom data type to solve this class of display problems. The stuff I really don't get is how to handle things like passing the values from one window to another and I'm not absolutely sure about the visual interface either. Anyone seen a slick solution to this class of problem?