Results 1 to 6 of 6

Thread: Form field database lookup

  1. #1

    Question Form field database lookup

    Hi all,

    Im after a bit of general thought and any ideas for a project I am undertaking. Ive been asked to develop an ordering system which is to manage customers, products and the usual associated bits and pieces.

    One of the requirements is for a customer lookup feature when completing the order forms. Ive seen on some sites the feature where you start typing into a field and after about 3 characters it pops up a list of possible options, this is what Ive been asked to achieve but instead of just one field I need to populate the whole customer section of the form. Basically, if the customer is already in the database fetch the details otherwise save the new customer details.

    My initial thoughts are to do something with a combobox on the surname but I know there is probably a better solution, I just cant think what.

    All ideas and suggestions gratefully received.

    Thanks in advance

  2. #2
    Sencha User Condor's Avatar
    Join Date
    Mar 2007
    Location
    The Netherlands
    Posts
    24,245

    Default

    Correct, use a combobox like this one and update the form in the select or blur event of the combobox.

  3. #3

    Default

    Cheers mate! Once again you have just what I need, do you ever sleep?

    I'll give it a go and see what I get.

  4. #4

    Default

    I have played with the code and have it working. I was just wondering if it is possible to change the number of characters entered before firing off the search? At the moment it defaults to four and I haven't found anything to tell me where or if I can change it.

  5. #5
    Sencha User Condor's Avatar
    Join Date
    Mar 2007
    Location
    The Netherlands
    Posts
    24,245

    Default

    So you missed the 'minChars' config option?

  6. #6

    Default

    Eak! Yes. It was Friday afternoon. I'd had a long week. To busy thinking about that first beer. Waffle, waffle...

    Cheers mate.

Similar Threads

  1. Textfield / combobox with a 'lookup' button in a form
    By salvin18 in forum Ext GWT: Help & Discussion (1.x)
    Replies: 2
    Last Post: 30 Aug 2010, 4:10 AM
  2. Create a Form with a Lookup Field button?
    By ekhanh101 in forum Ext 2.x: Help & Discussion
    Replies: 2
    Last Post: 10 Feb 2009, 9:19 AM
  3. How to create a button of lookup to the side of the field textfield?
    By Rafael in forum Ext 2.x: Help & Discussion
    Replies: 5
    Last Post: 2 Dec 2008, 10:37 AM
  4. Form lookup fine in FF but messup in IE
    By hiral in forum Ext 2.x: Help & Discussion
    Replies: 0
    Last Post: 11 Jul 2008, 12:30 AM
  5. How to load a form with a record lookup
    By kstevens in forum Ext 2.x: Help & Discussion
    Replies: 0
    Last Post: 30 Apr 2008, 8:32 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •