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
71435
JustinJustin65106495489Could you send me an application form? <a href=" http://barcelonaconsensus.org/research-paper-format-turabian/ ">fake essay writer</a> (Reporting by Alexei Anishchuk in Sochi, Alexander Dziadosz and Dominic Evans in Beirut, Sui-Lee Wee in Beijing, M
2
71438
AubreyAubrey77889565004I want to report a <a href=" http://www.cornwallfoodanddrink.co.uk/uk-assignment-writing-service/ ">affections amy technical writing revolve too</a> Commemorated annually on the first Friday of September, the day is intended to remind employees and
3
71436
BrooklynBrooklyn30666373777I work here <a href=" http://ziplinegear.biz/cheap-essay-service/ ">pay someone to do homework for me</a> While Colombian cocaine usually heads to the streets of the world&rsquo;s No. 1 market, the United States, most of that from Peru and Bolivia i
4
71437
JaneJane34040530148What's the exchange rate for euros? <a href=" http://bikinginbarcelona.net/tfc-loan/#show ">military spouse loan</a> New details revealed by Windows Phone Central, not officially confirmed yet, include optical image stabilization (as seen on the fla
5
71411
LaylaLayla70688613804I'm doing a masters in law <a href=" http://weimar.edu/inexpensive-resume-writing-services/ ">writing service online</a> They can also mine the minutes of last month's meeting for clues on how strongly the Fed's policy-setting committee is leaning t
6
71399
MakaylaMakayla92491768739Are you a student? <a href=" http://www.xbrasil.net/wp/?tag=same-day-instant-loan#descended ">online no colatteral loans</a> &#8220;Championing the Zimmerman telemania puts me at variance with the critics of tabloid TV, who want the cable news netwo
7
71434
KevinKevin87127853944Have you got a current driving licence? <a href=" http://www.cafsowrag4development.org/i-cant-write-my-essay/#admission ">pay to take my online class</a> The Brotherhood&#8217;s description of the bloodshed, in which dozens people were killed, is st
8
71402
SophieSophie84733608778It's serious <a href=" http://ziplinegear.biz/customessayscouk/ ">background how to do my homework fast smallest</a> More than 5,000 police and other security officials were on hand in Aparecida, where young pilgrims, many draped in the flags of Bra
9
71439
freelovefreelove72930452991Could you ask her to call me? <a href=" http://buffalonavalpark.org/money-market-account-information/#cambridge ">fast and easy payday loans</a> The debate continues. The companies make their point while others rail against the idea that companies w
10
71432
IsaacIsaac96647836256I'd like to apply for this job <a href=" http://www.jacquelot.com/bad-credit-personal-loans-in-rhode-island ">real estate construction loans</a> Detroit’s two biggest stars, Verlander and Cabrera, teamed up Thursday night to s
(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