I was thinking I could use the configurator to update a UD field within the quote screen, then run a bpm that checks for that being set during the quote.update, then updating the partplant etc.
erwin
erwin
--- In vantage@yahoogroups.com, "jckinneman" <jckinneman@...> wrote:
>
> I work with the product configurator all the time and determining when and where something happens presents some challenges.
>
> At the time the on-leave statement fires, the new part doesn't exist yet. You can use rules at the top level of your MOM to make changes to the part record. Unfortunately the partplant record doesn't isn't available as one of the choices. I haven't look at all the fields that you can update on the part record recently but several of them cascade down to lower level records when a part is created. The field you want to update 'may' be one of them.
>
> Otherwise to have the configurator update the partplant record we would need to figure out when the part record is created. It likely happens AFTER the rules fire which is too late to intercept it within the configurator. As another reply mentions you might be able to use a BPM to update the partplant record after the part is created.
>
> I'd turn on the trace log and see which Business Object are used to create the part.
>
> While using a BPM is probably the more elegant/recommended solution for some using embedded customization is easier to implement. You could use an embedded customization that runs after the call to the configurator. One trick is to trap the click on the "configuration" button. Since this is an Epicor provided control when you trap the click, your "click" code runs AFTER Epicor's code. In effect your click is an AfterClick event. If you take this approach there are 4 configuration buttons on the order entry, two on top of each other on the summary grid and two on top of each other on the detail tab.
>
> Hope this help, let me know if I can be of any further assistance.
>
> Jim Kinneman
> En>compass Solutions Inc.
> Tel 336.207.7166
> Fax 336.217.7983
> E-mail jimki@...
> www.encompass-inc.com
>
>
> --- In vantage@yahoogroups.com, "bonner.nathan" <bonner.n@> wrote:
> >
> > Erwin,
> >
> > I am not convinced that your 'Non-Stock' update table buffer is working either. I think what you are seeing is the default behavior of a new PartPlant record on this field.
> >
> > Are you sure that the Part and PartPlant records have already been created at the time your code is firing?
> >
> > I suggest that you add some info messages in your code to let you know if you are finding your target at the time the code is being called.
> >
> > First add the following to your "If available PartPlant then do:"
> >
> > {lib/PublishInfoMsg.i &InfoMsg = "'PartPlant record found.'"}.
> >
> > To test the alternative to "If available PartPlant then do:" I would add something like the following after your first info message;
> >
> > End. /*available PartPlant*/
> > If not available PartPlant then do:
> > {lib/PublishInfoMsg.i &InfoMsg = "'PartPlant record not available.'"}.
> > End. /*not available PartPlant*/
> >
> > I haven't used this info message lately so some fine tuning on the syntax may be required but this should give you some confirmation of whether you are finding your record or not.
> >
> > If you are not finding your record but are convinced that the record has been created at the time your code is being called, revisit your join:
> >
> > Find First QuoteDtl where QuoteDtl.Company = vCompany and Quotedtl.QuoteNum = vQuoteNum and Quotedtl.QuoteLine = vQuoteLine no-lock no-error.
> >
> > I think the "First" is not required here but is likely not the problem.
> >
> > Find First PartPlant where PartPlant.Company = vCompany and PartPlant.PartNum = Quotedtl.PartNum no-lock no-error.
> >
> > I suspect your problem is here.
> >
> > Try a joins similar to this as BAQ's until you are getting the records returned that you want your Configurator code to find. The join you end up with in the BAQ Query Phrase can be copied into your code and be slightly modified to reflect your temp table names.
> >
> > Let me know how this works out for you...
> >
> > Nathan Bonner
> > Business Systems Analyst
> > Total Plastics, Inc.
> > bonner.nathan@
> > totalplastics.com
> > 269-553-5838
> >
> >
> >
> >
> > --- In vantage@yahoogroups.com, "erwinjw" <erwinjw@> wrote:
> > >
> > > I am trying to set the Planner value in the PartPlant Tab of the part screen for a newly created configured part.
> > >
> > > I am using the code below in the page leave event of the final page of the configurator. The 'NonStock' flag is being set correctly but the 'PersonID' is remaining blank. The source part that we are using for the configurator has a planner set in this field, but the resultant part created through the configurator has a blank Planner value.
> > >
> > > any help would be appreciated.
> > >
> > > def var vQuoteNum as integer no-undo.
> > > def var vQuoteLine as integer no-undo.
> > > def var vCompany as character no-undo.
> > > vQuoteNum = GetCurrentQuoteNum().
> > > vQuoteLine = GetCurrentQuoteLine().
> > > vCompany = GetCurrentCompany().
> > > If vQuoteNum > 0 and vQuoteLine > 0 then do:
> > > Find First QuoteDtl where QuoteDtl.Company = vCompany and Quotedtl.QuoteNum = vQuoteNum and Quotedtl.QuoteLine = vQuoteLine no-lock no-error.
> > > If available QuoteDtl then do:
> > > Find First PartPlant where PartPlant.Company = vCompany and PartPlant.PartNum = Quotedtl.PartNum no-lock no-error.
> > > If available PartPlant then do:
> > > run lib\UpdateTableBuffer.p(input BUFFER PartPlant:HANDLE,'NonStock',"No").
> > > run lib\UpdateTableBuffer.p(input BUFFER PartPlant:HANDLE,'PersonID',"MStock").
> > > End. /* available PartPlant */
> > > End. /* available OrderDtl */
> > > End. /* OrderNum > 0 and OrderLine > 0 */
> > >
> > > any help would be appreciated
> > >
> > > erwin w
> > >
> >
>