Compare commits

..

No commits in common. "fdc95aeee08409ff2b89ccdaa8c0b0bd22013215" and "c603146566d4cd399af3e9da073fa2c8176e4b00" have entirely different histories.

2 changed files with 5 additions and 6 deletions

View File

@ -74,9 +74,8 @@ function findSingleTodayReport(prefix: string) {
return found[0];
}
function getAllExecutorNames(sourceSheet: GoogleAppsScript.Spreadsheet.Sheet): any[] {
if (!sourceSheet) return [];
function getAllExecutorNames(): any[] {
const sourceSheet = getSourceSheet();
const dataRange = sourceSheet.getDataRange();
const sourceSheetHeader = sourceSheet.getRange(1, 1, 1, dataRange.getNumColumns()).getValues()[0];
const executorColumnIndex = sourceSheetHeader.indexOf('Исполнитель');
@ -126,7 +125,7 @@ function loadCompletedTasks(afterDate: Date) {
throw new Error('На листе выгрузки завершенных задач не найдены колонки: ' + missingColumns.join(', '));
}
const performerNames = getAllExecutorNames(sheet).map(name => String(name ?? '').trim()).filter(Boolean);
const performerNames = getAllExecutorNames().map(name => String(name ?? '').trim()).filter(Boolean);
const result = new Map<string, any[]>();
performerNames.forEach(name => result.set(name, []));

View File

@ -58,7 +58,7 @@ export function pullExecutorAnswers(): void {
taskAnswers[taskId] = {
comment: row[col['Текущая причина переноса']],
deadline: row[col['Новый крайний срок от исполнителя']],
deadline: row[col['Новый крайний срок от менеджера']],
secondComment: row[col['Комментарий Исполнителя: условия, которые гарантируют выполнение задачи в запрашиваемый новый крайний срок']],
executorName,
executorSheetRow: r + 1
@ -102,7 +102,7 @@ export function pullExecutorAnswers(): void {
reportSheet.getRange(i + 1, reportCol['Текущая причина переноса'] + 1).setValue(answer.comment);
}
reportSheet.getRange(i + 1, reportCol['Новый крайний срок от исполнителя'] + 1).setValue(answer.deadline);
reportSheet.getRange(i + 1, reportCol['Новый крайний срок от менеджера'] + 1).setValue(answer.deadline);
reportSheet
.getRange(
i + 1,