+ [task#130245,doing,0.5h] check child date in task::batchCreate.

This commit is contained in:
liumengyi
2024-10-23 09:18:10 +08:00
committed by 刘刚
parent 019b079687
commit 4f5d062dbd
2 changed files with 19 additions and 1 deletions
+12
View File
@@ -162,3 +162,15 @@ $('#formSettingBtn').on('click', '.checkbox-primary [value=story]', function()
{
$('#formSettingBtn .checkbox-primary [value=preview], #formSettingBtn .checkbox-primary [value=copyStory]').prop('checked', $('#formSettingBtn .checkbox-primary [value=story]').prop('checked'));
})
function checkBatchEstStartedAndDeadline(event)
{
const $currentRow = $(event.target).closest('tr');
const field = $(event.target).closest('.form-batch-control').data('name');
const estStarted = $currentRow.find('[name^=estStarted]').val();
const deadline = $currentRow.find('[name^=deadline]').val();
if(field == 'estStarted' && estStarted.length > 0 && estStarted < parentEstStarted)
{
}
}
+7 -1
View File
@@ -15,6 +15,11 @@ include($this->app->getModuleRoot() . 'ai/ui/inputinject.html.php');
/* ====== Preparing and processing page data ====== */
jsVar('executionID', $execution->id);
jsVar('storyTasks', $storyTasks);
jsVar('parentEstStarted', isset($parentTask) ? $parentTask->estStarted : '');
jsVar('parentDeadline', isset($parentTask) ? $parentTask->deadline : '');
jsVar('ignoreLang', $lang->project->ignore);
jsVar('overParentEstStartedLang', isset($parentTask) ? sprintf($lang->task->overParentEsStarted, $parentTask->estStarted) : '');
jsVar('overParentDeadlineLang', isset($parentTask) ? sprintf($lang->task->overParentDeadline, $parentTask->deadline) : '');
/* zin: Set variables to define picker options for form. */
$storyItem = '';
@@ -257,7 +262,8 @@ formBatchPanel
on::change('input[name^=story]', 'setStoryRelated'),
on::click('[data-name=story] [data-type=ditto]', 'setStoryRelated'),
on::click('[data-name="copyStory"]', 'copyStoryTitle'),
on::change('[data-name="region"]', 'loadLanes')
on::change('[data-name="region"]', 'loadLanes'),
on::change('[data-name="estStarted"], [data-name="deadline"]', 'checkBatchEstStartedAndDeadline')
);
/* ====== Render page ====== */