tag:blogger.com,1999:blog-8643239839712475364.post29071136390089130..comments2024-02-15T21:18:33.934-08:00Comments on SFDC Stop: Salesforce Lightning Tutorial - Part 5 | Adding ValidationsRahul Malhotrahttp://www.blogger.com/profile/12391262239143475497noreply@blogger.comBlogger33125tag:blogger.com,1999:blog-8643239839712475364.post-13458583720463560002019-09-18T01:44:56.247-07:002019-09-18T01:44:56.247-07:00Hi,
It depends on how you're creating a looku...Hi,<br /><br />It depends on how you're creating a lookup, if you're using standard lightning inputfield, the standard validation rules will do the trick.Rahul Malhotrahttps://www.blogger.com/profile/12391262239143475497noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-32458407868247883282019-07-11T03:51:10.008-07:002019-07-11T03:51:10.008-07:00Hi Rahul,
Thanks for the articles which are very h...Hi Rahul,<br />Thanks for the articles which are very helpful. When trying to make "lookup" field it is not showing error messages. Is there a way to do it? TIA. Anonymoushttps://www.blogger.com/profile/09502380045153024539noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-67539505132034507682019-02-13T02:39:38.973-08:002019-02-13T02:39:38.973-08:00Hi Smruti, yes, the inputCmp will have a default p...Hi Smruti, yes, the inputCmp will have a default property validity which is an object and has a value for valid in it. If you can share your code or DM me then maybe I can help, here we're basically checking if all the fields are valid or not. However, salesforce has updated the syntax now and you can now do it like:- <br /><br />inputCmp.reportValidity();<br />return validSoFar && inputCmp.checkValidity();<br /><br />Also for a custom error message:- you can do it like:- inputCmp.setCustomValidity("Enter a valid value");<br />inputCmp.reportValidity();<br /><br />I'll need to add a new blog as an update to this. Thanks for pointing out and your error will resolve if you're getting the inputCmp properly, check if you've given the aura id and do:- console.log(inputCmp) to check if it's undefinedRahul Malhotrahttps://www.blogger.com/profile/12391262239143475497noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-84734686862738981902019-02-13T01:46:47.602-08:002019-02-13T01:46:47.602-08:00Hi Raj, this tutorial is in continuation of Salesf...Hi Raj, this tutorial is in continuation of Salesforce Lightning Tutorial Series, so if you 've followed the series you should have the helper code (also in part 4) and the styling css (also in part 2). Moreover I recommend you to have a look at the GitHub repository where you can find the whole code:- https://github.com/rahulmalhotra/SFDC-Lightning/tree/validate/src/aura/ContactListRahul Malhotrahttps://www.blogger.com/profile/12391262239143475497noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-57266183980703317432019-02-13T01:44:03.830-08:002019-02-13T01:44:03.830-08:00hi.. can u explain this line inputCmp.get("v....hi.. can u explain this line inputCmp.get("v.validity").valid<br />what exactly are these valid and validty.. are these predefined or u have defined if yes where<br /><br />I am actually getting this error Uncaught Action failed: c:EMT_BaseNewEventComponent$controller$saveRecord [Cannot read property 'valid' of undefined]<br />Smruti Ranjan Biswalhttps://www.blogger.com/profile/09051348216857093225noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-78010483315942767082019-01-20T22:50:37.132-08:002019-01-20T22:50:37.132-08:00Could you please provide the Helper() code and sty...Could you please provide the Helper() code and style code as wellrajhttps://www.blogger.com/profile/06399529528191247634noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-78115780578736570692018-12-28T20:44:45.510-08:002018-12-28T20:44:45.510-08:00Replied to you below :-)Replied to you below :-)Rahul Malhotrahttps://www.blogger.com/profile/12391262239143475497noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-38073097307078935402018-12-28T20:44:28.742-08:002018-12-28T20:44:28.742-08:00Hi Bhavin, this maybe because you have not made an...Hi Bhavin, this maybe because you have not made an apex controller for the lightning component with name "ContactListController" as this tutorial is a continuation in the series, I have already made an apex controller for this component before and using that in component. Make sure you've made the same.Rahul Malhotrahttps://www.blogger.com/profile/12391262239143475497noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-67469487699680948682018-12-28T11:58:52.586-08:002018-12-28T11:58:52.586-08:00Hi Rahul,
Please reply me back for below error sol...Hi Rahul,<br />Please reply me back for below error solution please...<br /><br />Failed to save ContactList.cmp: Invalid definition for null:ContactListController: null: Source<br />Bhavinhttps://www.blogger.com/profile/02500452282859124206noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-77439765899205581082018-12-28T11:56:24.434-08:002018-12-28T11:56:24.434-08:00i got below error:
Field_Integrity_Exceptions:
Fa...i got below error:<br /><br />Field_Integrity_Exceptions:<br />Failed to save ContactList.cmp: Invalid definition for null:ContactListController: null: Source<br />Bhavinhttps://www.blogger.com/profile/02500452282859124206noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-42429530738500815092018-10-29T02:18:47.609-07:002018-10-29T02:18:47.609-07:00Thank you. Do share it in your network too :-)Thank you. Do share it in your network too :-)Rahul Malhotrahttps://www.blogger.com/profile/12391262239143475497noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-35906106554950455052018-10-29T02:18:19.185-07:002018-10-29T02:18:19.185-07:00Hi, If you want to deal with a single record then ...Hi, If you want to deal with a single record then I'll suggest you to use LDS or lightning:recordForm, you can have a look at the documentation here:- https://developer.salesforce.com/docs/component-library/bundle/lightning:recordForm/documentation, I have another blog about LDS too. However, if you need to deal with multiple records, then you need to do it yourself by creating custom controller. Follow my lightning tutorial series starting from here:- https://sfdcstop.blogspot.com/2018/01/salesforce-lightning-basics.html and you'll be able to make it yourself.Rahul Malhotrahttps://www.blogger.com/profile/12391262239143475497noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-78380810217167730532018-10-29T00:27:53.221-07:002018-10-29T00:27:53.221-07:00Nice tutorialNice tutorialPriyahttps://www.blogger.com/profile/10902887351891111561noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-49388154621585103782018-10-28T05:04:21.847-07:002018-10-28T05:04:21.847-07:00Hi Rahul any help?Hi Rahul any help?Anonymoushttps://www.blogger.com/profile/07735638061412938237noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-87589108552558317752018-10-27T04:37:25.228-07:002018-10-27T04:37:25.228-07:00Hi Rahul,
How to write custom account page in lig...Hi Rahul,<br /><br />How to write custom account page in lightning to create and update existing records.I am new to lightning please help me how to do this.Anonymoushttps://www.blogger.com/profile/07735638061412938237noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-22523482434616670482018-08-24T00:24:51.411-07:002018-08-24T00:24:51.411-07:00Thanks. Do share it in your network too :-)Thanks. Do share it in your network too :-)Rahul Malhotrahttps://www.blogger.com/profile/12391262239143475497noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-38700633824614672018-08-21T18:43:53.486-07:002018-08-21T18:43:53.486-07:00great article. great article. Anonymoushttps://www.blogger.com/profile/01200910909972988690noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-85675545052901837462018-03-31T11:02:59.265-07:002018-03-31T11:02:59.265-07:00Thank you so much for your feedback :-)Thank you so much for your feedback :-)Rahul Malhotrahttps://www.blogger.com/profile/12391262239143475497noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-81134617565656174992018-03-31T09:26:19.755-07:002018-03-31T09:26:19.755-07:00Thank you Rahul. You have made Lightning easy with...Thank you Rahul. You have made Lightning easy with clear explanation. Well documented.Sohelhttps://www.blogger.com/profile/17795085923964707296noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-35023823818878294912018-03-31T08:38:16.210-07:002018-03-31T08:38:16.210-07:00This comment has been removed by the author.Sohelhttps://www.blogger.com/profile/17795085923964707296noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-69171898746487337242018-03-31T07:19:47.887-07:002018-03-31T07:19:47.887-07:00Please have some patience. I'll upload it asap...Please have some patience. I'll upload it asap.Rahul Malhotrahttps://www.blogger.com/profile/12391262239143475497noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-54492498693450835522018-03-31T06:40:41.109-07:002018-03-31T06:40:41.109-07:00Rahul Sir, Today or Tommarow You are going to uplo...Rahul Sir, Today or Tommarow You are going to upload the events tutorialAnonymoushttps://www.blogger.com/profile/11441988571876140967noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-36461944099757854232018-03-31T06:06:16.405-07:002018-03-31T06:06:16.405-07:00Hi Aman, if you want to implement search in a cust...Hi Aman, if you want to implement search in a custom lightning component, you have to use SOSL queries. Rest it depends on the scenario what I used in sObject Convertor is SOSL. However, you can try this and have a look at the code by testing sObject Convertor app once - http://sfdcstop.blogspot.com/2018/03/sobject-convertor-utility-application.html here is the step by step tutorial for the same. There are some issues on github repo too if you are interested to contribute in this applicationRahul Malhotrahttps://www.blogger.com/profile/12391262239143475497noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-2417107009981346322018-03-31T00:47:43.124-07:002018-03-31T00:47:43.124-07:00Hi Sir,
How to do the dynamic searching in lightni...Hi Sir,<br />How to do the dynamic searching in lightning<br /><br />Anonymoushttps://www.blogger.com/profile/11441988571876140967noreply@blogger.comtag:blogger.com,1999:blog-8643239839712475364.post-72229184462922834642018-03-29T01:09:20.279-07:002018-03-29T01:09:20.279-07:00Thank You So much In Advance :-)
Thank You So much In Advance :-)<br />Anonymoushttps://www.blogger.com/profile/11441988571876140967noreply@blogger.com