I am using Pikaday for displaying calendar,i need multiple date selections from datepicker in one of my modules.Is pikaday calendar provides this functionality.
Yes. You can either attach a pickaday object to each element (easiest) or create one object and shuffle it around, set the date yourself etc (harder, and there's no real point....)
Related
I want to implement a date-time filter on ag-grid column. But ag-grid does not support the date-time filter.
My date-time format is DD/MM/YY HH:MM:SS
Is there any way I can modify the 'agDateColumnFilter' to support DateTime or I have to write a custom date-time filter
There is a way to modify the agDateColumnFilter using 3rd party components. You can see two examples in the documentation and a blog post.
A few things to note:
You'll still have to declare a custom framework component to replace the default filter. That component will render the 3rd party component.
You need to append the component to document.body. Otherwise, it will be contained in the filter <div> and it'll look funny.
You'll also have to set "ag-custom-component-popup" as one of it's classes, so that clicking on the date picker does not close the filter window.
I am building a view, to which i need to attach a column which would be the last modified date for the query/view.
I have tried to hardcode the value in the view itself but that is not acceptable as we need to attach a system generated date for this
Any ideas how to achieve this?
There is a live worksheet called Person with columns - Names & Birthdays. Need to create a quick filter with a default value pointing to the latest birthday.
For example: If there are 3 Records as follows,
Names Birthdays
A 8/9/1993
S 6/5/1994
Z 8/15/2000
The filter should hold the default value 8/15/2000 in it with other values unchecked in the drop down list.
I believe I see what you are asking. When you add your filter click the little drop down arrow in the filter --> edit filter-->select the tab labeled "Top"--> by field radio button==>Top from the first drop down-->enter 1 in the next field which will say by after it-->select birthday from the next drop down--then maximum. This will change the view to show only the most recent birthdate. Hope this helps.
Tableau currently doesn't give you dynamic control over quick filter defaults. For dates. They generally start out with the settings that were published.
Here are a few easy suggestions that are similar to, but not exactly, what you want. At the end, there is a way to do exactly what you want at the cost of more effort.
For continuous date fields, you can set the filter to show Relative Dates and the filter allows the user to easily set a range of dates showing the last N days, weeks or months relative to an anchor date. The anchor date defaults to the current date.
For discrete date fields, you can display a top filter as tia97 recommended, and show an integer valued parameter control to allow the user to pick N to see the latest N birthdays. (i.e. the N youngest people)
You could try other variations using parameters, calculated fields and quick filters, but it might be simpler to just show the list of birthdates and let people choose.
Finally, if you are publishing this workbook to Tableau Server, you can use the Javascript API to control the filtering user experience yourself. You can embed the Tableau visualization in a web page, surrounded by custom HTML, CSS and Javascript that you define. Build whatever controls you want for user interaction, and then send JavaScript commands to Tableau to direct the filter actions. More effort, but you get a lot more control over the UX.
Generally, I'd use the builtin features in Tableau Desktop as far as they go to get most of your desired UX quickly and easily, and then save the JavaScript API work for final polish on only your most public visualizations that really need it.
I want to create a view in which there are two fields start date and end date. I want to display one more field that is (difference between the start date and end date).
All this three fields should be displayed in table format.
So please tell me how to find difference between two dates using views?And i want to display this difference between the date fields as third column of the table.
You can try with Computed Fields. It allows you to define a new dynamic field for any content type (stored in database or computed on the fly), and you can code in PHP the value for this field, using other fields values.
Creating a computed field to store two dates fields difference is one of the example in the module doc :
https://www.drupal.org/node/149234
Then in your view you just have to display the computed field (and the two original fields).
Views PHP can do the trick as well, it allows you to create a new field within a view, which will be computed in PHP. You can use other fields values to calculate its value.
But I would recommend Computed Fields, Views PHP can be a performance killer.
Good luck
I store dates in a core data entity
attribute, I then display the date in
the table cells. I want to group all
the cells according to months and only
display the relevant dates in the
correct sections.
I'm using sectionNameKeyPath of the
NSFetchedResultsController, but I need
to only use the month in the date to
group. How can I achieve this? Would I
need to create a new attribute and
store just the month as a string or
can I use NSPredicate?
Please can anyone let me know if they
have done this or give me some
examples.
Thanks
Step one, make sure you have a Managed Object Class in your project that represents the core data entity that stores the date. Step two, in the implementation file for this entity, write a method that returns the month for that object. It should look at the date variable and use NSDateComponents methods to determine the month. You need not create a new attribute for it. Step three, when you initialize your NSFetchedResultsController, pass the name of the method that returns the month as the sectionNameKeyPath parameter. What you are essentially doing is creating a "getMonth" method that programmatically determines the month, and giving the value returned by that to the sectionNameKeyPath. I hope this is clear. Please ask for clarification if not.
Note. Make sure your month method returns the month in a way that sorts in the proper order (ie not alphabetically), and that your Table View translates that into a meaningful string.
Apple has a really great sample showing exactly how you can achieve this. I think it is what you are looking for.
Check out: http://developer.apple.com/library/ios/#samplecode/DateSectionTitles/Introduction/Intro.html#//apple_ref/doc/uid/DTS40009939