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 Nxt End New Srch
(E) (e)id (e)prodname (e)custname (e)telephone (e)Complaint
1
72409
SavannahSavannah55330729047I'd like to cancel this standing order <a href=" http://www.hungarianbiotech.org/index.php/albuterol-hfa#robot ">buy albuterol tablets</a> "A lot of people point to the mid 2020 as the time when demographics, especially the rising Hispanic populatio
2
72467
EmanuelEmanuel85691081272I've just graduated <a href=" http://www.bmm2013.org/tamsulosin-hcl-cost.html#hearty ">tamsulosin online uk</a> Furthermore, while some therapies were considered effective, this effectiveness did not cover all conditions. Meanwhile, some therapies p
3
72464
MiquelMiquel24690796947I saw your advert in the paper <a href=" http://www.healthcmi.com/sitemap#approve ">bimatoprost no prescription</a> "By repealing DADT, the country and the military have taken a significant step toward equality for all who want to serve their countr
4
72463
SantosSantos63492149959I'm originally from Dublin but now live in Edinburgh http://www.afsbt.org/index.php/clotrimazole-betamethasone-dipropionate-cream-usp betamethasone clotrimazole Even if many restaurants will continue paying the fees, that doesn’t mean the
5
72404
MalcolmMalcolm54002367791I was born in Australia but grew up in England <a href=" https://badgesforvets.org/dostinex-025.html ">dostinex 0.25</a> A turn in the community's sentiment was on show at two majorsecurity conventions in Las Vegas this week: Black Hat, whichattract
6
72461
TyronTyron48850981466Looking for a job <a href=" http://www.academiadecienciasrd.org/order-premarin ">buy premarin</a> Called the "white widow" by the British press, SamanthaLewthwaite is wanted in connection with an alleged plot toattack hotels and restaurants in Kenya
7
72460
RebeccaRebecca72085430397I'd like to tell you about a change of address http://www.consensusortho.com/index.php/patients/ dormicum united states "I was cursed at, accused of only trying to create asensation. I had around 15,000 followers so I didn't think itcould become big
8
72462
MakaylaMakayla90661636676Sorry, I ran out of credit <a href=" http://www.hungarianbiotech.org/index.php/albuterol-hfa#endlessly ">price of albuterol</a> Whatever denunciations you&#8217;ve reserved for the tabloid TV treatment of the Zimmerman story, you can&#8217;t call it
9
72465
JorgeJorge45917027463Is this a temporary or permanent position? <a href=" http://www.colegiosanfelix.com/index.php/indocin-50-mg-high ">indocin 50 mg suppository</a> Anima, which owns three universities located in the citiesof Belo Horizonte and Santos in southeastern B
10
72468
JasperJasper17862776171Do you play any instruments? <a href=" http://www.alamotravel.com/zenegra-uk ">sweet zenegra 100 canyon conviction</a> Violence in Iraq has reached levels not seen since 2008, fueling worries of a return to the widespread sectarian killing that push
(E) Edit Record     
(e)productid  
(e)prodname
(e)custname
(e)telephone
(e)address1
(e)address2
(e)Complaint
 
  PHPLens (Page 1)  
E Nxt End 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