<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://sugarclub.sugarcrm.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Process Definition - How to check for an empty datetime field</title><link>https://sugarclub.sugarcrm.com/explore/help-forums/enterprise-professional/f/enterprise-professional-questions/2792/process-definition---how-to-check-for-an-empty-datetime-field</link><description>I want my Process Definition to check if, when creating a new record or editing an existing record, a user has filled in a datetime field. If they have, the Process will leave the entered date. If they have not, the Process will put in a calculated date</description><dc:language>en-US</dc:language><generator>Telligent Community 12</generator><item><title>RE: Process Definition - How to check for an empty datetime field</title><link>https://sugarclub.sugarcrm.com/thread/10564?ContentTypeID=1</link><pubDate>Fri, 12 Apr 2019 19:30:21 GMT</pubDate><guid isPermaLink="false">5c521d64-519d-47a6-9065-134618b211bf:5efae683-0bc2-4347-8fb8-550b3b8025dd</guid><dc:creator>Bj&amp;#246;rn Canales Pfisterer</dc:creator><description>&lt;p&gt;Yeah! Go ahead and mark the thread as solved :-)&lt;/p&gt;&lt;p&gt;Have a nice evening!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Definition - How to check for an empty datetime field</title><link>https://sugarclub.sugarcrm.com/thread/10563?ContentTypeID=1</link><pubDate>Fri, 12 Apr 2019 19:20:40 GMT</pubDate><guid isPermaLink="false">5c521d64-519d-47a6-9065-134618b211bf:0d5598c4-5172-4c4c-9deb-7ee300c388de</guid><dc:creator>Steve Jaspar</dc:creator><description>&lt;p&gt;That did it! Thanks so much!&lt;/p&gt;&lt;p&gt;I&amp;#39;m actually ticking the checkbox if the date field is populated, then the Process only calculates if the checkbox is false - so no need to modify the checkbox in the Process.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Definition - How to check for an empty datetime field</title><link>https://sugarclub.sugarcrm.com/thread/10562?ContentTypeID=1</link><pubDate>Fri, 12 Apr 2019 18:04:09 GMT</pubDate><guid isPermaLink="false">5c521d64-519d-47a6-9065-134618b211bf:83b7d13d-f2a4-445d-b05f-251cc5dc4cfc</guid><dc:creator>Bj&amp;#246;rn Canales Pfisterer</dc:creator><description>&lt;p&gt;What about adding a checkbox and use the formula from Andres Lopez to tick the checkbox in case of the date_time field is empty.&lt;/p&gt;&lt;p&gt;Now use this checkbox in process auth... err now its called &amp;quot;SugarBMP&amp;quot; to set the calculated date in case of the checkbox is ticked.&lt;/p&gt;&lt;p&gt;(Depending on the scenario you have you may also untick the checkbox afterwards with the same process to avoid the date will be set again on the next record save event)&lt;/p&gt;&lt;p&gt;Cheers&lt;/p&gt;&lt;p&gt;Bj&amp;ouml;rn Canales Pfisterer&lt;/p&gt;&lt;p&gt;Technical Support Manager&lt;/p&gt;&lt;p&gt;provalida GmbH&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Definition - How to check for an empty datetime field</title><link>https://sugarclub.sugarcrm.com/thread/10561?ContentTypeID=1</link><pubDate>Fri, 12 Apr 2019 17:36:57 GMT</pubDate><guid isPermaLink="false">5c521d64-519d-47a6-9065-134618b211bf:6bb0b4d6-e253-4e32-80a6-4de835aaba71</guid><dc:creator>Steve Jaspar</dc:creator><description>&lt;p&gt;Thanks for the info, but we&amp;#39;re a new Sugar installation and don&amp;#39;t yet have any developers up to speed. That&amp;#39;s why I was working on this requirement in the Process Definition.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Definition - How to check for an empty datetime field</title><link>https://sugarclub.sugarcrm.com/thread/10560?ContentTypeID=1</link><pubDate>Fri, 12 Apr 2019 03:14:02 GMT</pubDate><guid isPermaLink="false">5c521d64-519d-47a6-9065-134618b211bf:4719fe41-7cf6-42d2-b780-db9e9514c026</guid><dc:creator>Hatim Alam</dc:creator><description>&lt;p&gt;Hi &lt;a href="https://sugarclub.sugarcrm.com/members/stevejaspar"&gt;Steve Jaspar&lt;/a&gt;,&lt;/p&gt;&lt;p&gt;You can do that through code customization in vardefs.&lt;/p&gt;&lt;p&gt;If you are familiar with the sugar development, you can set the field &amp;quot;enforced&amp;quot; property to false and it would become editable for the end-users.&lt;/p&gt;&lt;p&gt;For eg:&lt;/p&gt;&lt;p&gt;Navigate to field vardefs file, create it if doesn&amp;#39;t exist.&lt;/p&gt;&lt;p&gt;&amp;lt;root_directory&amp;gt;/custom/Extension/modules/&amp;lt;module_name&amp;gt;/Ext/Vardefs/sugarfield_&amp;lt;field_name&amp;gt;.php&lt;/p&gt;&lt;p&gt;//set enforced to false&lt;/p&gt;&lt;p&gt;$dictionary['&amp;lt;module_class_name']['fields']['&amp;lt;field_name']['enforced'] = false; //where &amp;lt;module_class_name&amp;gt; is&amp;nbsp;generally singular for standard modules i.e. &amp;quot;Account&amp;quot; for &amp;quot;Accounts&amp;quot; but for custom module, it is the same as module name.&lt;/p&gt;&lt;p&gt;Perform Quick Repair &amp;amp; Rebuild from the Admin -&amp;gt; Repair section.&lt;/p&gt;&lt;p&gt;Let us know if this helps.&lt;/p&gt;&lt;p&gt;Regards&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Definition - How to check for an empty datetime field</title><link>https://sugarclub.sugarcrm.com/thread/10559?ContentTypeID=1</link><pubDate>Fri, 12 Apr 2019 02:43:00 GMT</pubDate><guid isPermaLink="false">5c521d64-519d-47a6-9065-134618b211bf:a0779e2c-b9bb-411a-b708-3577f09d60b4</guid><dc:creator>Steve Jaspar</dc:creator><description>&lt;p&gt;That works to calculate the field, but if it&amp;#39;s a calculated field then the user can&amp;#39;t enter a value.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Definition - How to check for an empty datetime field</title><link>https://sugarclub.sugarcrm.com/thread/10558?ContentTypeID=1</link><pubDate>Thu, 11 Apr 2019 22:47:32 GMT</pubDate><guid isPermaLink="false">5c521d64-519d-47a6-9065-134618b211bf:6c81f800-7b33-45be-a9f1-edf9f746b39f</guid><dc:creator>Andr&amp;#233; Lopes</dc:creator><description>&lt;p&gt;It is better to accomplish that through sugarLogic formula&amp;nbsp;on Studio:&lt;/p&gt;&lt;blockquote class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;p&gt;ifElse(&lt;/p&gt;&lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;equal($date_field, &amp;quot;&amp;quot;),&lt;/p&gt;&lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;// calculate it,&lt;/p&gt;&lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;$date_field&lt;/p&gt;&lt;p&gt;)&lt;/p&gt;&lt;/blockquote&gt;&lt;p&gt;Regards&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>