| Age | Commit message (Collapse) | Author |
|
STYLES restructured from a single geometry: string per style to a
full args: array, since this fix needs -gravity and -extent
alongside -resize, which one geometry string can't express.
|
|
Sized generously (1600x1600>) rather than against today's cramped
490px content column specifically -- shrinking an oversized source
to fit a narrow container is free and looks fine; a source too
small for a future, wider redesign has no fix short of re-uploading
every image. Purely additive: nothing reads :large yet, and
generate_variants already loops over the whole STYLES hash
generically, so no other code needed to change for new uploads to
start getting it. Test suite's own hardcoded style lists updated in
the same commit so they don't quietly drift out of sync with what
the app actually defines.
|
|
Both had already lost their reason to exist as production API:
wipe_draft!'s one remaining callsite (nodes#show) was removed two
sessions ago, and find_or_create_draft had zero production callers
left at all -- confirmed by a fresh grep, not assumed -- every one of
its ~65 call sites was test setup, unrelated to what those tests
actually cover.
wipe_draft! is deleted outright, along with its two tests -- the
lock/draft/autosave cleanup it silently performed already has
explicit, always-visible manual equivalents (Unlock, Discard
Autosave, Destroy Draft), so nothing real is lost.
find_or_create_draft moves to test_helper.rb as a plain method on
ActiveSupport::TestCase, alongside the create_node_with_draft/
create_node_with_published_page helpers already living there --
extending the framework's own designated test-extension point
rather than reopening the Node model from test code. Its three
tests of real dispatch behavior (idempotency on repeat calls, and
raising when a second user contends for the lock) are kept, since
~65 other tests depend on this helper actually working correctly;
only the call syntax changed, from node.find_or_create_draft(user)
to find_or_create_draft(node, user).
|
|
Every promotion (autosave creation, draft creation, draft save) ran
every locale's translation through delete-all-then-recreate
unconditionally, giving every locale a fresh created_at/updated_at
regardless of whether its content actually changed. Confirmed via
Node.find(546).draft.translations -- both DE and EN shared one
identical timestamp despite only EN having been edited.
This silently defeated Page.find_with_outdated_translations' whole
staleness comparison: every save reset every locale back into
lockstep, so timestamps could never actually drift apart the way
the feature depends on. The existing test for it only ever passed
by manually backdating a timestamp with record_timestamps = false,
bypassing normal save flow entirely -- not something that happens
through ordinary editing.
Now updates a matching locale's translation only when its own
attributes actually differ, creates one genuinely new, and removes
one genuinely gone from the source -- same end state, but real
per-locale timestamps survive an unrelated save. search_vector is
excluded from both the comparison and the copied attributes: it's
DB-trigger-maintained from title/abstract, not real content, and
comparing a precomputed tsvector risked a false 'changed' from
representation noise alone.
Also reloads the source's translations association, not just
self's -- clone_attributes_from previously only guaranteed a fresh
self, leaving any caller holding a page reference across an earlier
mutation vulnerable to reading a stale cached association.
|
|
Replaces the old locale-switch-and-edit-the-same-screen workflow,
which conflated presentation locale with content locale and let an
editor silently drift into editing the wrong language with no
persistent signal that anything had changed. Non-default-locale
content now has its own explicit routes and screens, never sharing
a route param with the ambient chrome locale.
- PageTranslationsController: index/show/edit/update/destroy,
scoped to Page.non_default_locales; update handles first-time
creation too, so there's no separate new/create step.
- Reads go through the actual PageTranslation row
(Page#translation_summary), never through the Globalize
fallback-bearing accessor -- fallback is correct for public
rendering but wrong for editing, where a missing translation
needs to look empty, not borrowed from another locale.
- Translations ride on the page's own draft/head cycle; no
independent publish state.
- nodes#show gains a Translations section (per-locale Lock+Edit /
Create+Lock, Destroy, a link into the read-only Compare view) and
a locale indicator on its own default-locale content; nodes#edit,
nodes#update, and nodes#autosave are pinned to the default locale
via Globalize.with_locale regardless of the ambient route locale.
- nodes#show no longer double-loads the node or calls wipe_draft!
on every view (see previous commit for why that's now safe).
- .preview_link_row is renamed .aligned_action_row now that it has
a second real consumer.
|
|
Its other two branches both require a day's inactivity before
touching anything; this one didn't, so a lock acquired seconds ago
with nothing drafted yet looked identical to one abandoned for a
week -- confirmed with a throwaway script showing a lock cleared
inside a single method call. Guarded on autosave.nil? specifically,
since the method's first line already guarantees any autosave
reaching this branch is a day old by construction.
|
|
Node#autosave! only copied assets forward onto a newly created
autosave, not translations. Invisible for single-locale nodes, but a
node with an existing multi-locale head/draft that gets locked and
edited in one locale would silently drop every other locale's
translation from the new autosave -- and from there into the draft
and eventually head, since save_draft! faithfully clones whatever
the autosave actually holds.
Fixed by using clone_attributes_from, which already does a complete
clone (translations, assets, tags, template, published_at) -- the
same method save_draft! already relies on two branches later, so no
new mechanism, just closing the one place still doing a partial,
hand-rolled version of it.
|
|
Replaces nodes#edit's old Images section -- a hidden panel dumping
every image asset in the system unfiltered (#image_browser) plus a
raw drag-and-drop box (#image_box) -- with a small search-and-click
picker built on the endpoint from the last two commits. Attaching
posts immediately and appends the new thumbnail via a cloned
<template> -- icons only render correctly through the Rails helper
server-side, so the template holds real, pre-rendered markup for JS
to clone rather than duplicating raw SVG in a JS string. Reordering is
jQuery UI sortable on the small attached list only, with a dedicated
drag handle rather than the whole thumbnail.
Two bugs caught while click-testing, fixed here rather than shipped
and patched after: the search panel never closed after attaching an
image, since the success handler re-triggered focus to keep it open
for attaching several in a row -- which meant it just re-populated
itself forever instead of signaling "done." Fixed to close explicitly;
a click-outside-closes handler was added alongside it, matching the
affordance the top-bar search already has.
A real, independent, pre-existing data bug surfaced during the same
testing: Node#autosave!'s first-time-creation branch never carried
related assets forward from whatever page was previously current --
attach an image, let autosave fire once, and it silently landed on a
fresh, assetless Page row. Long-dormant, not introduced by this work,
just finally exercised by something that made it visible. Fixed inside
the `unless self.autosave` guard specifically -- running this on every
call, not just creation, would overwrite anything attached directly to
an existing autosave in between, a worse bug than the one being fixed.
nodes#show gains a read-only Images section, rendered only when a page
actually has attached images, so an attachment can be confirmed
present without entering the edit/lock cycle -- useful on its own, and
specifically useful the next time an asset bug needs investigating.
Its thumbnail CSS is shared with the edit view's picker via a class
(.thumbnail_list) rather than duplicated under a second name.
|
|
Backend for the asset-picker rebuild -- replaces the plan to dump
every image asset in the system into a hidden, unfiltered browse
panel on every node edit (the actual current behavior, confirmed by
reading nodes/edit.html.erb directly) with a small, name-scoped search
endpoint plus create/destroy/update for attach, detach, and reorder.
No schema change needed -- RelatedAsset already had everything this
requires (asset_id, page_id, an acts_as_list position). search excludes
assets already attached to the page, keeping results meaningfully small
given hundreds of assets total but only a handful per node in practice.
create is find_or_create_by! rather than a bare create!, guarding
against the same asset being attached twice from two separate search
results. update leans on acts_as_list's own insert_at rather than
custom position-shifting logic.
Node#editable_page (autosave || draft || head) is extracted since this
is now its third call site with identical logic -- deliberately not
touching nodes#show, which resolves draft || head without autosave on
purpose, a different and correct semantic for "current committed
state" versus "what's actively being edited."
|
|
Replaces the old admin#index wizard -- accreted over years, never
designed as a whole -- with the dashboard settled on this session:
a three-icon nav (dashboard/search/log out, no locale selector), a
nodes-first search bar, four task signposts, and two symmetric
widgets (drafts/autosaves, recent changes) with a quiet housekeeping
row beneath them.
Node.recently_changed now filters and orders by the head page's own
updated_at instead of the node's blanket timestamp, so a lock/unlock
cycle with no actual publish no longer surfaces here, and the
original publisher is no longer misattributed to someone else's
housekeeping action. This also restores the "published" qualifier on
each entry, which the query previously couldn't guarantee was true.
@mynodes and its dedicated "My Work" table are retired along with the
old wizard -- "Continue my work" is a link to the existing, already-
correct NodesController#mine instead of a second, duplicate query.
Its one dedicated test (dedup across multiple revisions by the same
user) is ported to nodes_controller_test.rb, since mine already
carries the same .distinct protection the old query did; it just had
no test of its own until now.
|
|
Node.drafts_and_autosaves and Node.recently_changed replace inline
query logic in NodesController#drafts/#recent -- pure refactor, no
behavior change for either action. The real reason: the dashboard's
upcoming abridged widgets need the exact same queries the full pages
already use, just limited and (for drafts) sorted with the current
user's own locked nodes first. Better to share one method than let a
widget and a full page quietly drift onto two versions of "what counts
as a current draft."
current_user_id: is an explicit, optional argument rather than a
separate method -- ordering by lock ownership only applies when a user
is given; omitted entirely, it's pure recency, exactly today's
behavior. Needed Arel.sql wrapping a sanitized CASE expression before
.order would accept it -- sanitize_sql_array only vouches for the
values inside the string, a separate Rails safety check still refuses
any string shaped like more than a plain column reference unless it's
explicitly marked as already-vetted.
|
|
Four NodesController actions -- drafts, recent, mine, chapters --
each building its own base scope, sharing one private method
(index_matching) for search narrowing and pagination. Wizard rewrite
to link into these instead of rendering its own tables is a separate,
later step.
Node.editor_search backs the shared "q" narrowing: an ILIKE substring
match against title/abstract on whichever of head or draft is
present, splitting the term on whitespace and requiring every word to
match somewhere independently, not as one phrase, since real words can
end up separated by markup in the underlying HTML. Deliberately
separate from Node.search, the public content search, which stays
tsvector-based and head-only.
chapters generalizes into /admin/nodes/tags/:tags for an arbitrary
tag list (OR'd, not AND'd), sharing the controller action but
rendering its own template rather than branching inside one view.
|
|
search_vector is populated by a raw Postgres trigger created via
execute() in a migration -- invisible to schema.rb, which only
represents structure Rails understands. Any database rebuilt from
schema.rb rather than replayed migrations (test, a fresh db:setup,
disaster recovery) silently lost full-text search entirely, with no
error -- NULL @@ anything is never true in Postgres.
Page.ensure_search_vector_trigger!, called from an after_initialize
initializer, reinstalls the trigger via CREATE OR REPLACE on every
boot, in every environment. Idempotent and cheap.
|
|
publish_draft! called move_to_child_of before validating the new
parent at all. Staging a node under one of its own descendants
created a real, if transient, cycle in parent_id the instant that
save landed -- and update_unique_names_of_children's after_save
callback, which recurses down through parent_id with no cycle check
and no depth limit, bounced between the two nodes forever, crashing
the whole process with a SystemStackError rather than just producing
bad data.
Now rejected up front with a normal ActiveRecord::RecordInvalid.
|
|
|
|
Node#resolve_page_reference and #available_layer_pairs let
Page#diff_against compare named layers (head/draft/autosave), not
just numbered revisions -- autosave was never part of Node#pages, so
this was the missing piece.
Wired into nodes#show's Status section, nodes#edit right after an
autosave gets resurrected ("What changed?"), and the admin wizard's
current-drafts table, which now also lists autosave-only nodes it
previously never showed.
revisions#diff hides the numbered-revision picker when comparing
named layers (it can't represent them), shows a plain label instead,
and offers buttons to switch between whichever other pairs make
sense for the node's current state. Destroying the topmost layer is
available directly from the diff view, reusing the existing revert!
path.
"Discard changes" is renamed "Discard Autosave" everywhere it
appears, to match "Destroy Draft".
|
|
Revisions#diff now computes an inline or side-by-side word diff
server-side (Page#diff_against, lib/html_word_diff.rb) instead of
shipping raw/escaped content to the browser for a 2008-era vendored
JS differ to mangle. View mode is picked via a `view` param, settable
either on the diff page itself or directly from the revisions#index
sticky bar next to "Diff revisions".
Also fixes a pre-existing bug in RevisionsController#diff's single-
revision branch, which set params[:start]/params[:end] instead of
params[:start_revision]/params[:end_revision].
|
|
Editors' TinyMCE output can contain unclosed void elements like <br>,
which is valid HTML5 but invalid XML -- three different places assumed
the stricter rule and broke or silently misbehaved on the looser one.
The Atom feed's <content type="xhtml"> block required real, well-formed
XML structure but was handed a raw, unescaped body string; switched to
type="html" with CGI.escapeHTML, matching how title/summary already
handle the same content. rewrite_links_in_body used libxml's strict XML
parser to rewrite internal links to be locale-prefixed, which raised on
exactly this class of malformed markup -- silently, since the whole
method was wrapped in rescue; nil, meaning the link rewrite (not the
save) quietly failed with no error anywhere. Replaced with Nokogiri's
lenient HTML parser, which repairs malformed void elements rather than
rejecting them; also drops the bare rescue now that the actual failure
mode it was guarding against shouldn't occur, and fixes two adjacent
bugs found while in this method: a typo'd /sytem/uploads/ regex that
could never match, and a missing https:// exclusion alongside the
existing http:// one.
Also addresses stale flash messaging surfaced while testing the above:
update's save confirmation was being clobbered by edit's own "locked
and ready" notice on the very next request, since nothing distinguished
a fresh lock acquisition from a redirect back after saving. The save
confirmation now names the next step (publish from Status) and flags a
stale translation if one exists, using Page#outdated_translations?,
already present but previously unused by any controller.
|
|
A blank title failed presence and length validation simultaneously,
showing two redundant messages for one problem; length now skips
whenever slug is already blank, matching presence's own skip
condition. Separately, create's failure path never computed
@selected_kind/@parent_id/@parent_name the way new does, so
re-rendering after a validation error silently lost which kind and
parent had been chosen -- for the auto-tagging/auto-templating kinds,
that meant a corrected resubmission could silently produce a plain
generic node instead. required on the title field closes the common
case without a round trip; the server-side fix remains the actual
guarantee, since required is trivially bypassed.
|
|
Two real bugs surfaced by the full test suite, not by the new tests
written for this feature -- both were latent the moment lock_for_editing!
and save_draft! replaced find_or_create_draft, and only visible once an
existing test exercised the exact path each one lived in.
lock_for_editing! never stamped user/editor onto a draft that already
existed when the lock was acquired. find_or_create_draft used to do this
as part of acquiring the lock; splitting lock acquisition from draft
creation dropped it entirely, since it looked like draft-creation logic
rather than locking logic. Restored as an explicit step: claim authorship
only if none is set yet, editorship unconditionally, matching the old
behavior exactly.
save_draft!'s "no draft yet" branch set user/editor before calling
clone_attributes_from, whose first line is an unconditional self.reload
-- silently discarding both, since neither had been persisted yet.
clone_attributes_from also always copies published_at from its source
without the ||= guard used for template_name, and the source here is
always the autosave, whose published_at is never anything but nil --
meaning every single promotion, not just the first, was quietly
resetting a published page's published_at, which publish_draft!'s own
||= Time.now would then treat as never-published and re-stamp. Fixed by
running clone_attributes_from first on both branches, then applying
user/editor/published_at afterward, exactly as the existing-draft branch
already happened to do by accident.
Four controller tests updated to insert a real put :update between
get :edit and assertions that used to be true immediately after
visiting edit -- deferred draft creation means edit alone no longer
produces one, which is the intended consequence of this whole
redesign, not something these tests were meant to catch.
|
|
Introduces autosave_id as a third, unversioned layer above draft/head,
with lock_for_editing!, autosave!, and save_draft! as the new entry
points. Also fixes a real bug in wipe_draft!: its "no draft" branch
unconditionally released the lock, which was safe when "no draft" only
ever meant "nothing is happening" — no longer true now that a lock can
exist with only an autosave beneath it. lock_for_editing! deliberately
does not call wipe_draft! at all, for the same reason: an intruder
calling it while a lock was genuinely held would otherwise silently
steal it via wipe_draft!'s own unlock side effect, caught by the new
two-user lock test.
|
|
|
|
Root-caused this session: appending a child to any node never widened
that parent's own rgt boundary, on the pinned revision (Gemfile tracked
main directly, chasing a too-conservative gemspec constraint - not, as
first assumed, a deliberate pin to avoid a known bug). Reproduced
cleanly on a single ordinary create with no concurrency and no bulk
operation involved, confirmed via the gem's own SetValidator, then
confirmed as the root cause of nodes_controller_test.rb's 3 long-standing
"pre-existing" failures - not three separate mysteries, one bug.
admin_controller's sitemap needed its own real conversion, not just a
drop-in: awesome_nested_set's lft column implicitly provided correct
depth-first tree order for free, which the old code combined with a
separate class-level each_with_level iterator. Both replaced by one
method, self_and_descendants_ordered_with_level, computing an ordered
[node, level] list in a single query-then-walk pass - checked against
the actual view template first (admin/index.html.erb) rather than
assumed, since it relies on list order alone to render correct visual
nesting.
lft/rgt/depth columns intentionally left in schema, unused - dropping
them is a separate, deliberately deferred migration once this is proven
running for a while, not bundled with the behavior change.
|
|
New :children option ("direct" or "all") on the [aggregate] shortcode,
composable with the existing :tags filter - both apply as independent
successive .where clauses, ANDing together automatically, no special
casing needed. content_helper.rb passes the current @page.node through
as :node whenever :children is requested, since Page.aggregate has no
way to resolve "which node" from the shortcode's bare option strings on
its own. Guarded so nothing changes for any existing [aggregate]
shortcode that never uses children= - :node stays nil, the new branch
never fires.
"all" resolves via node.descendants.pluck(:id) rather than embedding the
descendants relation directly as a subquery. Not proven strictly
necessary - extensive debugging this session initially pointed at a
subquery/table-alias collision, but every actual failure traced instead
to accumulated test-node debris left in the dev DB by earlier
interrupted runs, confirmed by re-running against a cleaned database.
Kept anyway as a one-round-trip-cheaper, more defensive default
regardless.
|
|
staged_slug existed to protect a live public URL from changing until
an editor explicitly publishes - correct once a node has a head, but
nodes_controller#update wrote to it unconditionally, so a brand-new
node being renamed before its first-ever publish showed a stale slug
in previews (e.g. nodes#new's resulting-path preview) that silently
diverged from what would actually go live.
Node#staged_slug= now applies directly to slug when head is blank -
nothing is live yet, so there's nothing to protect. Once head is
present, defers to staged_slug exactly as before. Verified both paths
directly: a never-published node's slug now updates immediately, and
an already-published node's rename still stays deferred until the
next publish, unchanged from existing behavior.
|
|
New column + unique index, plus ensure_preview_token!/revoke_preview_token!
on Page. Generated lazily (only when explicitly requested) rather than
via has_secure_token's default auto-generate-on-create, so a live,
shareable secret isn't silently minted for every page ever created.
|
|
lib/ccc_conventions.rb: NODE_KINDS registry replaces the kind-specific
branches previously scattered across nodes_controller#create (tags),
unique_path-position check). Each kind declares its parent lookup
(a Proc - Update's "update"/"press_release" continue to genuinely
find-or-create their year-folder via Update.find_or_create_parent;
erfa/chaostreff use a plain find_by_unique_name!, since their parent
nodes are fixed and a missing one should fail loudly, not be silently
created), its tags, and (new) its default template.
Node gains a default_template_name column (migration, with backfill
for existing update-tree nodes via node.update? - reusing that method
rather than re-deriving its unique_path check in raw SQL). Page#set_template
now inherits from node.default_template_name, falling back to the old
update?-based check only when the column is blank, and only fills in
template_name when nothing's already been explicitly chosen - a
deliberate change from the previous behavior, which unconditionally
overwrote template_name on every save regardless of manual selection.
Node#update? itself is unchanged and still used as-is by
admin_controller's sitemap filtering - a genuinely different, still
valid use of that check.
"generic" stays special-cased in the controller, parametrized by
params[:parent_id] at request time - doesn't fit "kind implies a fixed
lookup" and isn't in the registry.
nodes#new's four hardcoded radio buttons and nodes_controller's
kind-specific case/when branches are both replaced by iterating/looking
up this one registry - adding a new kind now means one new hash entry,
not four scattered edits.
|
|
RruleHumanizer gains WEEKDAY_NAMES_ABBR (Mo/Di/Mi/...) alongside the
existing WEEKDAY_NAMES and WEEKDAY_NAMES_ADVERBIAL hashes, plus a
self.wday_abbr(time, locale) utility mapping a Time's wday to its
RFC5545 code and looking up the abbreviation - keeping RFC5545
vocabulary in one place rather than teaching ContentHelper about day
codes directly.
ContentHelper#weekday_abbr is a thin wrapper passing I18n.locale
through. The partial now renders "Fr 19:00" instead of just "19:00",
joined with a non-breaking space so the pair can't split across a
line wrap.
Takes an explicit Time rather than reading Date.today, matching this
file's existing style of passing state in rather than reading it
ambiently - and staying correct if the currently-unused
calendar/_front_page_calendar partial (spanning six weeks, not just
today) is ever revived and reuses this helper.
|
|
- Event#occurrences is now dependent: :destroy, so destroying an Event
(directly, or via Node's cascade) removes its Occurrence rows instead
of orphaning them.
- Renamed generate_occurences -> generate_occurrences (typo fix);
callback and method updated together.
- Occurrence.generate returns early when event.start_time is nil, so a
chapter with no sourced time produces zero occurrences instead of a
guessed one.
- seed_chapter no longer falls back to 19:00 when start_time is absent;
base_time/end_time are nil in that case.
Database-level foreign key cascade on occurrences.event_id is still
pending.
|
|
- Occurrence.generate_dates: use ChaosCalendar::occurrences_for_timezone
with Time.zone.tzinfo.identifier — occurrences now keep wall-clock
time across DST boundaries (19:00 stays 19:00 in summer and winter);
requires chaoscalendar gem with occurrences_for_timezone support
(Gemfile.lock bumped accordingly)
- Occurrence.find_in_range: joins(:event) inner join excludes occurrences
whose event no longer exists (107k orphaned rows from the pre-revival
calendar era were purged from the test DB); includes(:node) retained
for eager loading; column references qualified with table name
|
|
- Event: acts_as_taggable_on :tags — uses existing polymorphic
taggings table, no migration needed
- events/edit and events/new: tag_list field added, tag_list
permitted in events_controller strong params
- locales: add open_days (Offene Tage / Open days),
upcoming_events (Weitere Termine / Upcoming events),
event_schedule_time, event_schedule_unrecognized,
event_schedule_none keys
|
|
- app/models/concerns/rrule_humanizer.rb: new concern included into
Event, renders recurring schedule as natural-language German or
English from RRULE string; handles WEEKLY/MONTHLY, biweekly
(INTERVAL=2), ordinal weekday positions (1TU, -1TH, -2WE),
BYMONTH single-month exclusions (December pause convention);
gracefully returns nil for COUNT/UNTIL/unrecognized shapes
- test/models/concerns/rrule_humanizer_test.rb: 15 tests covering
all distinct RRULE shapes found in production data
- app/helpers/nodes_helper.rb: add event_schedule_text helper
combining humanize_rrule with start_time formatting
- app/views/nodes/show.html.erb: add events row, conditionally
rendered when node has associated events
- config/locales/de.yml, en.yml: add event_schedule_time,
event_schedule_unrecognized, event_schedule_none keys
|
|
- event_params now permits title, description, is_primary
- event_information helper lists all node.events, not just the first
- Occurrence.generate handles nil node (standalone events)
- Page.aggregate order_by title uses correlated subquery to avoid
GROUP BY conflict with tag-filter path; order_direction whitelisted
to ASC/DESC to prevent SQL injection
- Events link added to admin menu bar
- events/index shows title, is_primary; drops latitude/longitude columns
|
|
- _chapter.html.erb: new partial for erfa/chaostreff aggregated lists;
renders title, location, external_url, sanitized body
- content_helper: fix aggregate attr regex to allow hyphens in values
(erfa-detail tag was silently dropped); add debug logging (remove)
- page.rb: suppress libxml stderr noise in rewrite_links_in_body
- db/seeds/chapters.rb: one-shot seed script for erfa and chaostreff
chapter nodes under parent nodes 548/549; creates bilingual pages,
external_url, primary events with RRULEs where known
Note: run Node.rebuild!(false) after execution to fix lft/rgt values
|
|
- Migration: node_id nullable on events and occurrences, add
title/description/is_primary to events, external_url to nodes
- Existing events marked is_primary: true (were all 1:1 with nodes)
- Node: has_one :event -> has_many :events
- Event: belongs_to :node optional, validates title presence for
standalone events, is_primary uniqueness scoped to node_id,
display_title helper falling back through node title
- Occurrence: belongs_to :node optional, summary falls back to
event.display_title
- nodes_helper: event_information uses events.first (interim; will
be replaced in Phase 3 event UI)
- Tests: fix node.event -> node.events.first in event_test
|
|
- nodes_controller: permit staged_slug and staged_parent_id in node
params; these were silently dropped since strong parameters migration,
breaking the two-phase slug/parent change workflow
- file_attachment: add SVG support; vector files are copied to all style
directories without rasterisation, preserving scalability in the browser
- assets index/show: constrain image display with max-width/max-height
via admin.css td img rule; fixes oversized SVG thumbnails while leaving
raster variants unaffected
|
|
- aggregate: switch to shortcode syntax [aggregate ...]; fix paragraph
wrapping by excising the shortcode and its surrounding <p> before
sanitize, concatenating collection output outside sanitized content
- page.rb: remove aggregate XML unwrapping from rewrite_links_in_body
(no longer needed with shortcode approach)
- rss builders: explicit CGI.escapeHTML on title/abstract; Builder 3.3.0
does not escape when target buffer is html_safe (ActionView default)
- tinymce: disable menubar and promotion nag; add code plugin, remove
paste plugin (built into TinyMCE 8 core); configure via admin_interface.js
directly (config/tinymce.yml affects tinymce() helper only, not tinymce.init)
|
|
- Bump Rails to 8.1.3 (Ruby unchanged at 3.2.11, new gemset rails8-upgrade)
- config.load_defaults 8.1; merge app:update diffs for all environment files
- Remove routing-filter 0.7.0; replace with native scope '(:locale)' in
routes.rb and default_url_options in ApplicationController
- Delete config/initializers/routing_filter_rails71_patch.rb
- Replace vendored TinyMCE 3.x (~200 files) with tinymce-rails ~> 8.3;
migrate admin_interface.js from jQuery .tinymce()/advanced theme to
tinymce.init(); add config/tinymce.yml; note: TinyMCE 7+ is GPL
- rails-i18n ~> 8.0 added explicitly (previously indirect dependency)
- awesome_nested_set, acts-as-taggable-on pinned to git main/master
(gemspec activerecord < 8.1 ceiling; no functional incompatibility;
repin to version once upstream releases updated gemspecs)
- globalize ~> 7.0, libxml-ruby ~> 5.0, nokogiri ~> 1.18, pg ~> 1.5
- sass-rails, coffee-rails, uglifier moved from :assets group to main
(Sprockets 4 convention; :assets group no longer meaningful)
- Node: head, draft, lock_owner marked belongs_to optional: true
- Page: node, user, editor marked belongs_to optional: true
- Static assets in public/images/ and public/javascripts/ referenced via
plain HTML tags; Rails 8 load_defaults raises on pipeline helpers for
undeclared assets
- sessions_controller_test.rb: remove stale require and dead rescue_action
- users_controller_test.rb: assert button[type=submit] not input[type=submit]
(Rails 8 button_to renders <button> not <input>)
- test_helper.rb: node.reload after children.create! (awesome_nested_set
3.9.0 does not refresh parent in memory after callback)
- 129 runs, 339 assertions, 3 failures, 0 errors — identical baseline to 7.2
|
|
- file_attachment.rb: delete old upload directory before writing replacement
files; fixes orphaned variants when filename or mime type changes
- assets/edit.html.erb: add file upload field and current file display;
the form was previously empty and non-functional
- admin.css: fix button_to hover styling; buttons now show orange hover
to signal interactivity
- test/controllers/users_controller_test.rb: assert input[type=submit]
not anchor tag for destroy action (button_to change)
- test/test_helper.rb: add I18n.locale reset in setup block
- doc/rc.d_cccms: fix cccms_chdir, add start_precmd for log/pid dirs,
PATH export for bash wrapper, user/pid/tcp_nopush unicorn fixes
- doc/INSTALL.md: new installation guide covering all non-obvious steps
- Remove parked search migration from doc/ (now in db/migrate/)
|
|
- Fix Page.find(self.head) → self.head in node.rb wipe_draft!
- Migration to delete 407 spurious 'root' locale records from
page_translations (Globalize artefact, all had nil titles and
duplicate de/en translations existed for all affected pages)
|
|
- Restore search vector migration (was parked in doc/ pending PostgreSQL upgrade)
- Restore Node.search using plainto_tsquery with simple dictionary
- Cross-locale keyword search, no stemming, works for both de and en content
|
|
|
|
- Remove safe_path helper and content_path shim from link_helper.rb
- Update all safe_path call sites in views to use named route helpers directly
- Fix Globalize fallbacks via config.i18n.fallbacks in application.rb, remove i18n initializer
- Stub Node.search returning none (search disabled pending PostgreSQL upgrade)
- Replace to_s(:db) with to_fs(:db) in node.rb, nodes_helper.rb, link_helper.rb, admin view
- Move LockedByAnotherUser to app/models/locked_by_another_user.rb for Zeitwerk autoloading
- Fix config/environments/test.rb: config.assets removed, cache_classes → enable_reloading,
test_order removed, minitest pinned to ~> 5.25
- Fix config/environments/development.rb: cache_classes → enable_reloading
- Park search vector migration in doc/ pending PostgreSQL and plpgsql availability
|
|
- Bump Rails to 7.2.3, Ruby to 3.2.11 (new gemset rails7-upgrade)
- pg pinned to 1.4.6 (bridge: Ruby 3.2 compatible, PostgreSQL 9.6 tolerant)
- acts-as-taggable-on → 12.x (Rails 7.2 + Ruby 3.2 support)
- awesome_nested_set → 3.7.0 (Rails 7.2 support, avoids 3.9.0 lft/rgt bug)
- globalize → 7.0 (Rails 7.x required)
- libxml-ruby → 5.x (Ruby 3.2 required)
- unicorn → 6.x; fix unicorn.rb: RAILS_ROOT→Rails.root, RAILS_ENV→ENV,
File.exists?→File.exist?
- Add puma for development server
- Remove dead initializers: assets.rb, ruby2.rb, backtrace_silencers.rb,
new_rails_defaults.rb
- Fix File.exists? → File.exist? in page.rb and authors_importer.rb
- Add routing_filter_rails71_patch.rb (restores params[:locale] on Rails 7.1+)
|
|
- routing-filter 0.6.3 -> 0.7.0 (Rails 6.1 compatibility)
- RSS named routes rss_xml/rss_rdf added
- RouteWithParams workarounds: will_paginate_patch, content_path shim, safe_path helper
- Paperclip removed, replaced with FileAttachment concern (preserves URL scheme)
- Assets resource moved to /admin/assets (Sprockets middleware conflict)
- ApplicationRecord base class added, all models migrated
- Strong parameters added to Assets, Occurrences, Events, MenuItems controllers
- update_attributes -> update throughout
- render :nothing -> head :ok/:not_found throughout
- language_selector rewritten (removes :overwrite_params)
- Environment files updated for Rails 6.1 (eager_load, public_file_server, ActionMailer)
- Arel::Visitors::DepthFirst and Integer/Float duration patches removed from test_helper
- AssetsController tests added (10 tests covering upload, variants, destroy, auth)
- ImageMagick geometry: 460x250! for headline crop (not # which is invalid in IM6)
129 runs, 311 assertions, 5 failures (all pre-existing), 0 errors
|
|
- Rename before_filter → before_action across all controllers
- Fix string conditions in validators to lambda syntax (node.rb)
- Fix publish_draft!: move staged slug/parent logic outside draft guard,
use move_to_child_of for parent changes, add nil guard for no-op calls
- Fix update_unique_names_of_children: use parent_id traversal instead
of lft/rgt descendants (awesome_nested_set 3.x lft/rgt update bug)
- Fix unique_path to return Array instead of String
- Fix Occurrence.delete_all syntax for Rails 5
- Fix Page.find_with_outdated_translations: use includes instead of all
- Fix outdated_translations?: use find instead of splat array
|
|
- Wrap all scopes in lambdas (required in Rails 4)
- Move scopes after associations in page.rb (evaluated at load time in Rails 4)
- Convert association :order options to lambda syntax
- Remove attr_accessible from page.rb and user.rb
- Add Strong Parameters: user_params in UsersController, node_params/page_params in NodesController
- Fix clone_attributes_from: exclude id/page_id/timestamps when cloning translations
- Fix redirect_to :back → request.referer fallback in nodes_controller
- Fix node_path/publish and unlock actions: pass @node argument
|
|
- Replace tagged_with calls in Page.aggregate, TagsController, RssController
with direct SQL joins (acts-as-taggable-on 3.5 broken on Rails 3.2)
- Fix Paperclip :path/:url to use plain :id format matching existing uploads
- Add proper regression tests for aggregator, tags, and rss controllers
- Fix assert_select assertions to target div.body div.article_partial
|
|
- Converted plugins to gems (Gemfile)
- Updated config structure (application.rb, boot.rb, environment.rb)
- Converted routes to Rails 3 DSL
- Converted named_scope to scope throughout models
- Converted find(:all, :conditions) to where() chains
- Fixed has_many :order to use ordering scope
- Updated session store and secret token configuration
- Fixed exception_notification middleware configuration
- Patched Ruby 2.4 / Rails 3.2 incompatibilities:
- Integer/Float duration arithmetic (ActiveSupport)
- Arel visit_Integer for PostgreSQL adapter
- create_database String/Integer coercion
- ActionController consider_all_requests_local
- Migrated taggings schema for acts-as-taggable-on
- Replaced dynamic_form gem with custom form_error_messages helper
- Fixed Rails 3 block helper syntax (form_for, form_tag, fields_for)
- Fixed admin layout yield
- Updated test suite for Rails 3 APIs
|
|
|