![]() |
#1 |
Участник
|
mscrmblog: CRM 2011 – Show Time Field Only
Источник: http://mscrmblog.net/2014/05/06/crm-...me-field-only/
============== I had a requirement to Show only Time portion of the date field in CRM as we had to schedule classes and the dates weren’t relevant just the times. Here’s the function I’ve setup to hide the date portion of the field. unfortunately we’ve had to hide it using DOM manipulation as there is no way using the CRM SDK. function HideDateField(fieldName, showTimeOnly) { var dateField = document.getElementById(fieldName); if (dateField != null) { if (showTimeOnly == true) { dateField.childNodes[1].childNodes[0].childNodes[0].style.display = "none"; dateField.childNodes[1].childNodes[0].childNodes[1].style.display = "none"; dateField.childNodes[1].childNodes[0].childNodes[2].style.display = "none"; dateField.childNodes[1].childNodes[0].childNodes[3].style.display = "none"; } else { dateField.style.display = "none"; } }}It’s a bit of a hack but it works. Tested with UR16. ![]() Источник: http://mscrmblog.net/2014/05/06/crm-...me-field-only/
__________________
Расскажите о новых и интересных блогах по Microsoft Dynamics, напишите личное сообщение администратору. |
|
![]() |
#2 |
Moderator
|
Я бы использовал числовой тип данных с форматом "Длительность". Эффект будет тот же.
__________________
http://fixrm.wordpress.com, снятие/наведение порчи. Быстро, дорого, гарантия. ![]() ![]() |
|
|
|