Halleck’s Secret Menu

Excel Spine · Internal Hub
Dashboards and checklists — internal use only.
--:--:--
---
Dashboards
Checklists
Google Sheets Sync
Apps Script — paste into Extensions → Apps Script in your Google Sheet, then Deploy → New deployment → Web app → Anyone:
function doGet(e) {
  const p = e && e.parameter;
  const ss = SpreadsheetApp.getActiveSpreadsheet();
  const sheet = ss.getSheetByName('Data') || ss.insertSheet('Data');
  if (p && p.action === 'load') {
    return ContentService.createTextOutput(
      JSON.stringify({ data: sheet.getRange('A1').getValue() }))
      .setMimeType(ContentService.MimeType.JSON);
  }
  return ContentService.createTextOutput(JSON.stringify({ status: 'ok' }))
    .setMimeType(ContentService.MimeType.JSON);
}
function doPost(e) {
  const body = JSON.parse(e.postData.contents);
  const ss = SpreadsheetApp.getActiveSpreadsheet();
  const sheet = ss.getSheetByName('Data') || ss.insertSheet('Data');
  if (body.action === 'save') {
    const ex = sheet.getRange('A1').getValue();
    const exTs = sheet.getRange('B1').getValue();
    if (ex) {
      const lr = sheet.getLastRow();
      sheet.getRange('A' + (lr + 1)).setValue(ex);
      sheet.getRange('B' + (lr + 1)).setValue(exTs);
    }
    sheet.getRange('A1').setValue(body.data);
    sheet.getRange('B1').setValue(new Date().toISOString());
    // Human-readable tab
    if (body.rows && body.rows.length) {
      let vs = ss.getSheetByName('Hub');
      if (!vs) vs = ss.insertSheet('Hub');
      vs.clearContents();
      vs.getRange(1,1,body.rows.length,body.rows[0].length).setValues(body.rows);
      vs.getRange(1,1,1,body.rows[0].length).setFontWeight('bold');
      vs.setFrozenRows(1);
    }
  }
  return ContentService.createTextOutput(JSON.stringify({ status: 'ok' }))
    .setMimeType(ContentService.MimeType.JSON);
}