This commit is contained in:
@@ -202,26 +202,38 @@ function extractTakesPlace(sheet) {
|
||||
if (!cell.isMerged) {
|
||||
return "";
|
||||
}
|
||||
let str = "";
|
||||
try {
|
||||
str = cell.master.value.trim();
|
||||
let str = cell.master?.value?.trim() || "";
|
||||
|
||||
let i = 5;
|
||||
while (true) {
|
||||
const nextCell = sheet.getCell(`B${i}`);
|
||||
|
||||
if (!nextCell.isMerged) {
|
||||
break;
|
||||
}
|
||||
let i = 5;
|
||||
while (true) {
|
||||
const nextCell = sheet.getCell(`B${i}`);
|
||||
|
||||
if (nextCell.isMerged) {
|
||||
const cell = nextCell.master
|
||||
|
||||
str += `\n${cell.value.trim()}`
|
||||
i++;
|
||||
continue;
|
||||
}
|
||||
} catch {}
|
||||
|
||||
return str;
|
||||
const tryCells = ["A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K"];
|
||||
const threshold = 20;
|
||||
|
||||
for (const cellTest of tryCells) {
|
||||
const cellTry = sheet.getCell(`${cellTest}${i}`)
|
||||
const cellValue = cellTry?.value?.trim() || "";
|
||||
|
||||
if (cellValue.length >= threshold) {
|
||||
str += `\n${cellValue}`;
|
||||
i++;
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
|
||||
return str.trim();
|
||||
}
|
||||
|
||||
function extractReservedRooms(sheet) {
|
||||
|
||||
Reference in New Issue
Block a user