MCPcopy Create free account
hub / github.com/DHTMLX/scheduler / _fill_lightbox_select

Function _fill_lightbox_select

codebase/sources/dhtmlxscheduler.js:6641–6662  ·  view source on GitHub ↗
(s2, i2, d)

Source from the content-addressed store, hash-verified

6639 }
6640 }
6641 function _fill_lightbox_select(s2, i2, d) {
6642 var time_values = config._time_values;
6643 var direct_value = d.getHours() * 60 + d.getMinutes();
6644 var fixed_value = direct_value;
6645 var value_found = false;
6646 for (var k = 0; k < time_values.length; k++) {
6647 var t_v = time_values[k];
6648 if (t_v === direct_value) {
6649 value_found = true;
6650 break;
6651 }
6652 if (t_v < direct_value)
6653 fixed_value = t_v;
6654 }
6655 s2[i2 + map[0]].value = value_found ? direct_value : fixed_value;
6656 if (!(value_found || fixed_value)) {
6657 s2[i2 + map[0]].selectedIndex = -1;
6658 }
6659 s2[i2 + map[1]].value = d.getDate();
6660 s2[i2 + map[2]].value = d.getMonth();
6661 s2[i2 + map[3]].value = d.getFullYear();
6662 }
6663 _fill_lightbox_select(s, 0, ev.start_date);
6664 _fill_lightbox_select(s, 4, ev.end_date);
6665 }, get_value: function(node, ev, config) {

Callers 2

extend$6Function · 0.70
_update_lightbox_selectFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected