* [refac bug #62306] Adjust checkBatchEstStartedAndDeadline for child.

This commit is contained in:
wangyidong
2025-05-19 10:26:26 +08:00
committed by 刘刚
parent b1c8431b22
commit 74a7c386d3
+16 -2
View File
@@ -196,7 +196,14 @@ function checkBatchEstStartedAndDeadline(event)
$estStartedTd.find('.date-tip').remove();
const $childrenEstStarted = $(event.target).closest('tbody').find('tr[data-parent="' + taskID + '"]').find('[name^=estStarted]');
$childrenEstStarted.each(function(){$(this).zui('datePicker').render({disabled: estStarted.length == 0});});
$childrenEstStarted.each(function()
{
let $childDatePicker = $(this).zui('datePicker');
$childDatePicker.render({disabled: estStarted.length == 0});
if(estStarted.length == 0) $childDatePicker.$.setValue('');
checkBatchEstStartedAndDeadline({target: this});
});
if(estStarted.length > 0)
{
let $datetip = $('<div class="date-tip"></div>');
@@ -223,7 +230,14 @@ function checkBatchEstStartedAndDeadline(event)
$deadlineTd.find('.date-tip').remove();
const $childrenDeadline = $(event.target).closest('tbody').find('tr[data-parent="' + taskID + '"]').find('[name^=deadline]');
$childrenDeadline.each(function(){$(this).zui('datePicker').render({disabled: deadline.length == 0});});
$childrenDeadline.each(function()
{
let $childDatePicker = $(this).zui('datePicker');
$childDatePicker.render({disabled: deadline.length == 0});
if(deadline.length == 0) $childDatePicker.$.setValue('');
checkBatchEstStartedAndDeadline({target: this});
});
if(deadline.length > 0)
{
let $datetip = $('<div class="date-tip"></div>');