phpLens
 home  products examples manual  faq support forum  contact news  login store

More Examples:   View Source:   searchInEditNew

Free Download

This demo allows you to enter complaint records for products you are supporting. You can perform a search in the both the EDIT/NEW record forms for the product the customer is complaining about. Hint: search on R in the "prodname" field below.

  PHPLens
E New Srch
(E) (e)id (e)prodname (e)custname (e)telephone (e)Complaint
1
70910
thebestthebest95104791741Have you got any qualifications? <a href=" https://www.wesearchtogether.org/about.php ">fluconazole mg</a> Multiple sources close to the matter have told Reuters BlackBerry is in talks with Cisco Systems Inc, Google Inc and Germany's SAP AG among ot
2
70942
TylerTyler78402933055Could you tell me the dialing code for ? <a href=" http://www.leerowingclub.com/club-location ">zyban 150 mg 60 tablet fiyat</a> Today, Lhota lives in a $3.5 million penthouse duplex in Brooklyn Heights and owns a $2.7 million home in Nantucket. Tha
3
70928
DominicDominic72824407805Accountant supermarket manager <a href=" http://demilovato.com/bio/ ">suffocate price xenical orlistat 120mg line totally</a> Could it be that Tony Stark doppelganger Elon Musk isn&rsquo;t just trying to be a jerk and take the wind out of California
4
70943
JadenJaden64025008955Looking for a job http://www.poly.ee/polygon/ purchase bimatoprost amex online without rx Hamas, an offshoot of the Muslim Brotherhood, has governed Gaza since 2007 and has an uneasy relationship with Egypt's new army-backed leadership, which topple
5
70920
NicoleNicole14336716542I like it a lot <a href=" http://weddingsbyparis.com/me/prici ">can you order diflucan online</a> The second quarter is typically one of the slowest periodsfor online shopping, falling after the winter holiday buyingbinge and before the back-to-scho
6
70931
ZoeZoe52802639526Will I get travelling expenses? <a href=" https://www.wesearchtogether.org/about.php ">diflucan no prescription needed</a> If A-Rod stays home then his 0-for-3 appearance Wednesday night at Yankee Stadium was his final game of the 2013 season, with
7
70923
LuisLuis69951491588What are the hours of work? <a href=" http://demilovato.com/bio/ ">maker buy generic orlistat uk quit</a> "Consumers will start to demand better customer experience,and both market places and branded websites will have to respondto differentiate fro
8
70926
JasonJason63341107254Could you ask her to call me? http://weimar.edu/professional-writing-services-dallas/ cv writing services london Did the government intentionally neglect this step in this case, or did it simply fail to follow its procedures? I am a bigger believer
9
70939
IsaiahIsaiah59251527048Could I have an application form? <a href=" http://santafyme.com/buysildalis/ ">buy sildalis</a> Rallying equity markets and $3.7 billion in new asset flowsdrove up overall client assets by 12.4 percent to $396.7billion. Assets in the brokerage's fe
(E) Edit Record     
(e)productid  
(e)prodname
(e)custname
(e)telephone
(e)address1
(e)address2
(e)Complaint
 
  PHPLens (Page 1)  
E New Srch

Notes

This feature is available since 3.1.

This demo show to create complaint records, retrieving the product id and product name using a search form built into the NEW/EDIT record form. This is particularly useful when we have a 100,000 product table and we don't want to pull every product record in a normal lookup, but allow the user to enter the first few characters of the product name, then we perform a search.

The key property is:

$lens->searchInEditNew = 
"PRODNAME^select concat(productname,' (',productid,')'),productname,productid,productid 
	from products where productname like '{#}%'^prodname^productid^>1";
		

There are two modes for searchInEditNew. The first is when no lookupLens is defined as in this example. The second is discussed in ex920.

The searchInEditNew generates the search field. The key to understanding this is the prodname^productid list above, which defines the fields that receive searched values.

Now look at the SQL SELECT statement. The {#} in the SQL is substituted with what the user entered in the input field.

The SQL statement retrieves 3 fields, the first being what we show the end-user in the popup.

The 2nd is what we store in the prodname, the first field of the list prodname^productid.

The 3rd field of the SQL is stored in productlist, the second field of the list prodname^productid.

Now if 3 items were defined in the above list, say prodname^productid^more3 then the SQL statement would have had 4 fields, the 4th field storing into more3.

The >1 in the property means the field requires at least 1 character before a search can occur.

Lastly, this example has the details being displayed below the grid, using $lens->showRecNo = 5;

email: contact#phplens.com (change # to @)     telephone (malaysia): 60-3-7947 2888     fax (malaysia): 60-3-7947 2800