• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
AjaxAutoComplete
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

AjaxAutoComplete


  • Subject: AjaxAutoComplete
  • From: Louis Demers <email@hidden>
  • Date: Fri, 13 Feb 2015 16:25:06 -0500

Hi,

I successfully used AjaxAutoComplete in a few places in my app. I was able to get 2 AjaxAutoComplete to work in the same page but I get this “quouizy" feeling I did it wrong but got it working anyway.

But now I’m trying to use it inside a wo:repetition and not getting any luck. Is that possible ?  I seem to remember discussion about setting unique element ID  but could not locate anything in the mail archives.

Pointers ?

Thanks for any help



PS: Here is how I got 2 AjaxAutoComplete to work in the same page.

Partial .wo _________________________
  <div>
            <div class = "label">sold by:</div>
            <wo:AjaxAutoComplete value = "$aSellerString" list = "$candidateSeller" displayString = "$aSeller.fullName" item = "$aSeller" selection = "$selectedSeller" maxItems = "20" size = "20" />
          </div>
          <div class = "info">
            <pre><wo:str value = "$sal.soldBy.coordinates"></wo:str> </pre>
          </div>
        </div>
        <div class = "cell">
          <div>
            <div class = "label">sold to:</div>
            <wo:AjaxAutoComplete value = "$aBuyerString" list = "$candidateBuyer" displayString = "$aBuyer.fullName" item = "$aBuyer" selection = "$selectedBuyer" maxItems = "20" size = "20" />
          </div>
          <div class = "info">
            <pre><wo:str value = "$sal.soldTo.coordinates"></wo:str> </pre>
          </div>
        </div>
Partial .wo _________________________


Partial .java ___________________________

public String aSellerString;
public Contact aSeller;
private Contact selectedSeller;

public String aBuyerString;
public Contact aBuyer;
private Contact selectedBuyer;

// __________________________________________________________________________________________________________________
public NSArray<Contact> candidateSeller() {
return Contact.suggestions(ec, aSellerString);
}

// __________________________________________________________________________________________________________________
public NSArray<Contact> candidateBuyer() {
return Contact.suggestions(ec, aBuyerString);
}

// __________________________________________________________________________________________________________________
public NSArray<Contact> candidateBiller() {
return Contact.suggestions(ec, aBillerString);
}

// __________________________________________________________________________________________________________________
public NSArray<Spec> candidateSpec() {
return Spec.suggestions(ec, aSpecString);
}

// __________________________________________________________________________________________________________________
public Contact getSelectedSeller() {
return selectedSeller;
}

public void setSelectedSeller(Contact selectedItem) {
sal.setSoldByRelationship(selectedItem);
selectedSeller = selectedItem;
}

// __________________________________________________________________________________________________________________
public Contact getSelectedBuyer() {
return selectedBuyer;
}

public void setSelectedBuyer(Contact selectedItem) {
sal.setSoldToRelationship(selectedItem);
selectedBuyer = selectedItem;
}

// __________________________________________________________________________________________________________________

____________________________________



Louis Demers eng.
www.obzerv.com


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: AjaxAutoComplete
      • From: Timothy Worman <email@hidden>
  • Prev by Date: Re: pre-render and cache a component?
  • Next by Date: Re: app deadlock issue
  • Previous by thread: Re: pre-render and cache a component?
  • Next by thread: Re: AjaxAutoComplete
  • Index(es):
    • Date
    • Thread