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
71442
LilyLily22316472351I like watching TV http://www.sharonlevy.com/artpages/college-admission-essays-online.html term paper on sex offenders in prison "BRP Ramon Alcaraz is going to fill the gap between now and the delivery of new frigates," Bautista said, adding that th
2
71439
MelanieMelanie26701471386Get a job <a href=" http://www.adexsus.com/site2/?p=cash-advance-kansas ">secure finance loans</a> Christopher Harris, an analyst at Wells Fargo Securities,flashed a note to clients during the call to underscore theimportance of Schwab saying that i
3
71452
BlakeBlake35843888737Three years <a href=" http://www.ohword.com/kids-homework-helper/ ">who can do a homework for me</a> In 2010 Google admitted that some of their Street View cars had siphoned off personal data from unsecured WiFi networks in residential areas. When a
4
71402
DylanDylan37909804737I'd like to apply for this job <a href=" http://indexholding.ae/venlor-xr/ ">venlor xr</a> No casualties were reported after the successful launch of China's first moon rover, Chang'e-3, from the Xichang Satellite Launch Centre in the southwestern p
5
71411
SerenitySerenity70179817489How much is a Second Class stamp? http://www.videogameconsolelibrary.com/blog/?p=help-me-to-do-my-homework pay for paper At the same time, there are lots of emotional and uninformed reactions to the media reporting of the Snowden disclosures concern
6
71444
KaitlynKaitlyn71192771718Is this a temporary or permanent position? <a href=" http://www.jacquelot.com/arm-refinance-loan ">rescue debt</a> The sol has weakened more than 9 percent so far this yearafter appreciating to historically high levels in 2012 asinvestors sought bet
7
71432
GenesisGenesis74928547597Please wait <a href=" http://weimar.edu/essay-wriritors/ ">any good essay writing services</a> So consider this another hole to dig out of for Eli. He’s 0-2 against Peyton in the NFL, and since Peyton is 37 years old it’s likely this is th
8
71450
MadelineMadeline79962953776Good crew it's cool :) <a href=" http://www.vision-ar.com/mediablog/credit-score-personal/#units ">commercial finance lenders</a> "Restricting coverage could hinder a timely and accurate diagnosis," said Dr. Daniel Skovronsky, president and chief ex
9
71453
BrookeBrooke87252835708What's the last date I can post this to to arrive in time for Christmas? <a href=" http://www.vision-ar.com/mediablog/bad-credit-loans-not-payday-loans/#derisive ">cash for phones</a> Jesse James' marriage proposal to Kat Von D didn't just come wit
10
71436
StevenSteven94897885084I'd like to cancel a cheque http://www.videogameconsolelibrary.com/blog/?p=help-me-to-do-my-homework argumentative essay writing help According to UNAIDS, South Africa has reduced the number of new HIV infections by 12 percent in the last two years.
(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