# QuickBooks Support Articles — Source Markdown

These four files are the version-controlled source for the QuickBooks
help-center articles. They were also INSERTed into
`kiosk_buykiosk.support_articles` on 2026-05-07 as drafts (ids 87–90).

| File | CMS row id | Slug | Title |
|------|-----------:|------|-------|
| `01-connect-and-configure.md` | 87 | `quickbooks-connect-and-configure` | QuickBooks: Connect & Configure |
| `02-daily-approval-workflow.md` | 88 | `quickbooks-daily-approval-workflow` | QuickBooks: Daily Approval Workflow |
| `03-reconciliation-and-audit.md` | 89 | `quickbooks-reconciliation-and-audit` | QuickBooks: Reconciliation & Audit |
| `04-account-mapping.md` | 90 | `quickbooks-account-mapping` | QuickBooks: Account Mapping |

All four are in the **Integrations** category (`category_id = 17`),
authored by user 28 (rvanvuren), `status = 'draft'`. The files cross-link
to each other via `/support/articles/<slug>` URLs.

## Source-of-truth policy

**The CMS row is the source of truth for the published content** — the
support portal renders directly from `support_articles.content_md` (or
`content_html`). These files are a backup / version-control snapshot
captured at the point of upload. If you edit the CMS row, this file
won't auto-update.

If you make substantial edits in the CMS that you want preserved in
git, dump the CMS row back here:

```bash
mysql -u<user> -p<pass> -h localhost kiosk_buykiosk \
  -e "SELECT content_md FROM support_articles WHERE slug = 'quickbooks-connect-and-configure'" \
  --skip-column-names --raw \
  > docs/support/quickbooks/01-connect-and-configure.md
```

## Re-upload these files to a fresh DB

If the CMS rows are ever lost (DB restore, fresh dev box, etc.), recreate
them with:

```bash
cd /Users/rvanvuren/Projects/buyerkiosk-web/docs/support/quickbooks
for f in 01-connect-and-configure 02-daily-approval-workflow \
         03-reconciliation-and-audit 04-account-mapping; do
  case "$f" in
    01-*) SLUG=quickbooks-connect-and-configure;   TITLE='QuickBooks: Connect & Configure' ;;
    02-*) SLUG=quickbooks-daily-approval-workflow; TITLE='QuickBooks: Daily Approval Workflow' ;;
    03-*) SLUG=quickbooks-reconciliation-and-audit;TITLE='QuickBooks: Reconciliation & Audit' ;;
    04-*) SLUG=quickbooks-account-mapping;         TITLE='QuickBooks: Account Mapping' ;;
  esac
  ABS="$(pwd)/$f.md"
  mysql -ukiosk_db -p... -h localhost kiosk_buykiosk -e "
    SET @c = LOAD_FILE('$ABS');
    INSERT INTO support_articles
      (category_id, title, slug, content_md, author_id, status, is_featured)
    VALUES (17, '$TITLE', '$SLUG', @c, 28, 'draft', 0);
  "
done
```

## Image references

The articles deliberately don't reference images. Add hero/contextual
screenshots through the CMS image uploader if/when desired — those write
to `public_html/images/support/articles/` with hashed filenames the CMS
generates. Edit the markdown via the CMS to add `![alt](/images/...)`
references.
