Hot answers tagged

12

Yes, you can expand this range in Administer > Customize Data and Screens > Date Preferences. Change the start Offset of activityDateTime class to 30.


6

If you want 28 February 2019 {foreach from=$contributions item=contribution} {assign var="date" value=$contribution.receive_date|date_format:"%d %B %Y"} If you want 28 02 2019 {foreach from=$contributions item=contribution} {assign var="date" value=$contribution.receive_date|date_format:"%d %m %Y"} If you want it to look better (28/02/2019) you can ...


5

This was a bug in Core CiviCRM which is now fixed starting from version 4.7.14.


5

I recall we've experienced this for quite a number of fields in Advanced Search. Some of them are - Event Dates, Registration Dates and some date filters in Case section. I did a patch to fix this for us but missed to update core for some reason. If the above fields fail for you, can you try applying this patch and see if it works for you? Opened a JIRA ...


4

I think the date widget have its default value based on the format it is being set. Eg - For mm/dd/yyyy input format set in Administer -> Localization -> Date Formats. This works - function civitest_civicrm_buildForm($formName, &$form) { $defaults['register_date'] = date("m/d/Y"); $form->setDefaults($defaults); } This doesn't - $...


4

There was an issue due to some refactoring around the handling of date fields to try to standardise them. This lead to a problem most notably in birth date fields in 4.7.16 but i'm guessing can be found elsewhere. This issue was raised CRM-19982 I suspect the same fix will most likely work for you. If you have a test site or would like to give a test a ...


4

The template file is just to change how this one field is displayed. Create a view of civicrm activities. Add the Scheduled Activity Date field three times. First to display the date. Second to display the time in. Third to convert the start date/time to Unix (I had previously added Unix as a time format in Drupal). Then add Duration. Add a Math ...


4

Based on your description, I think the export format might be controlled by the "Complete Date and Time" and "Complete Date" settings at Administer > Localization > Date Formats. The default values for those fields are: Complete Date and Time - %B %E%f, %Y %l:%M %P Complete Date - %B %E%f, %Y The help text on that screen reads: Use this screen to ...


4

The choice of months is restricted because the date-picker does not allow future dates to be chosen for the birth date field. First select a year in the past. Then you will see all months available to choose.


4

Assuming you have a default layout, then there is a Date of Birth field on a contact's summary tab.


3

So I think I was jumping the gun with my excitement about this. I found the issue on Jira, which has been updated to say the custom filter creation has been bumped to 4.8. The work-in-progress code that Jon was working on is at https://github.com/civicrm/civicrm-core/pull/6307


3

Got it! In Drupal added the Unix Timestamp format: Administration/Regional and Language/Formats/Add Format. For the string I put in U. Added the Date Type Unix Timestamp In the View: Added the Start and End Date fields. Under Date Format selected the Unix Timestamp type I just created. Added a Math Expression field with the expression (([end_date]-[...


3

The creation date of an activity is not, by default, stored in CiviCRM. Depending on what you want to do, you can: Create a custom field like you suggested, and write an extension that fills in the value on creation. Create a custom field, then define a MySQL trigger to fill in the date. This is less portable, but higher-performance. You can enable binary ...


3

I'm not sure where to start as I can't answer the main question apart from quoting a colleague Jon Goldberg 29/Mar/15 5:19 AM for now, you can use the PHP overrides folder to maintain your own local copy of this file when 4.6 comes out. I do this frequently for issues like this where I expect the problem to go away in the next version. I may do a ...


3

You are on the right track with using now in field comparision. See my Question and Answer here. trigger: daily trigger for group members condition: field value comparison for a date, datetime or timestamp field, where you can use any string recognized by the php function strtotime. So you should be able to use now as explained in the PHP documentation. ...


3

I have a report for this on Github. I've heard it works on Civi 4.7, but not in FULL_GROUP_BY mode.


3

Found the answer. The civi field token must be captured to a Smarty variable first: {capture assign=arr}{contact.custom_105}{/capture}{$arr|date_format:"%A, %B %e, %Y"}


3

This is not currently available in CiviCRM to have time range custom field. The alternate solution would be to create two date time field To and From and using buildForm hook and PageRun hook and/or JS hide the date field on forms and view. HTH Pradeep


3

You can create a scheduled Activity with this contact. https://docs.civicrm.org/user/en/latest/organising-your-data/activities/ via the Actions button on the contacts Summary screen If you add the dashlet for activities to your dashboard, you will also be reminded of this whenever you log in until you mark the activity as completed.


3

Welcome to CiviCRM SE KLeeHK! I am not sure if you can suppress the translation of particular Smarty tags e.g. {$receive_date} or change the date format of only this occurence. The receipts can be edited under "System Workflow Message Template which you can find under "https://yoururl.com/civicrm/admin/messageTemplates?reset=1" However, you can globally ...


3

Certain ones can work by just adding option values, but I don't think everything. For example @andy-clark you can do prior 6 months as "ending_6.month" which is supported by the default clause here https://github.com/civicrm/civicrm-core/blob/5.20.2/CRM/Utils/Date.php#L1660 Take a look through that function to get an idea of what works, in particular the ...


2

There are actually (at least) two places where you can change the formats. One is where you described, the other one (that affects most of the displayed date formats e.g. in the contact tab) is available at >>Administer >>Localization >>Date formats. Below is a screenshot of settings we usually use for German language environments.


2

I think the answer may be that this is working in 4.7.7 - set your date range in the Custom Field - Edit screen [I want to go back 30 years]: Custom Date SE field: And this is indeed giving me a dropdown going back 30 years (I can select 1986):


2

Have you tried adjusting the settings at Administer > Customize Data and Screens > Date Preferences. to achieve what you want?


2

Adding the following CSS disables the date picker widget and allows users to simply type the date into the field:- #ui-datepicker-div, .ui-datepicker .ui-widget { display: none !important; }


2

Also posting my answer to How do I override the default date range of JQuery date widget? here - for those following this Question: I think the answer may be that this is working in 4.7.7 - set your date range in the Custom Field - Edit screen [I want to go back 30 years]: Custom Date SE field: And this is indeed giving me a dropdown going back 30 years (...


2

The short answer is 'No' there aren't any settings to allow this. Gift Aid declarations don't have to have an end date, when you sign up to Gift Aid to an organisation you can effectively sign up for ever (unless you specify an end date). Bearing this mind, I suggest that you change the end date of the previous declaration to avoid the overlap.


2

You don't say your version, but I'm guessing 4.7 from the description. The trick is to use ISO date format. So this should work: function civitest_civicrm_buildForm($formName, &$form) { $defaults['register_date'] = date("2017-04-15"); $form->setDefaults($defaults); } FWIW, this is still an issue for setting defaults via URL query string ...


2

I think you may find that, although the search results show the relative dates converted to fixed dates, when you create a smart group from the results it will save the relative date range. That is certainly what happens in my live v4.4. I have also checked this as best I can on a 4.7.10 site that has had no activity or changes on it since February this ...


2

I think it's unlikely you'll be able to perform this search within any of CiviCRM's existing searches. Fortunately, it's possible to create custom searches. The process requires some coding, but gives you a tremendous amount of power and flexibility.


Only top voted, non community-wiki answers of a minimum length are eligible