Opened 7 years ago

Closed 4 years ago

#8893 closed (wontfix)

1.0 conversion guide doesn't mention url prefix change in attaching .js files to admin views

Reported by: syphoon Owned by: nobody
Component: Documentation Version: 1.0
Severity: Keywords: conversion guide
Cc: Triage Stage: Design decision needed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

In 0.96, if you wanted to attach a Javascript file to an admin view, you would do so by adding a "js" property to an inner Admin class on the model class. The corresponding behaviour with the new admin forms is to add an inner Media class to the right Admin object with a "js" property. The former would prefix the .js URL with ADMIN_MEDIA_PREFIX. The latter uses MEDIA_URL. Given we just got bitten by this while doing a 0.96->1.0 conversion it could probably stand to be added to the conversion guide.

Change History (2)

comment:1 Changed 7 years ago by kmtracey

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Triage Stage changed from Unreviewed to Design decision needed

#7129/[7873] is where this difference was noticed/documented. Looking at the guide, I'm not sure where note of this would go. The guide calls out only the most significant changes and points to the branch page for details. The branch page does call out the change in the discussion here:

http://code.djangoproject.com/wiki/NewformsAdminBranch#RefactoredinnerAdminjsoptiontomediadefinitions

Given someone's reported tripping over it, it might be worth trying to make the info more prominent, but I'll leave that decision to someone more closely involved with the guide.

comment:2 Changed 4 years ago by gabrielhurley

  • Resolution set to wontfix
  • Status changed from new to closed

This ticket is over two years old... even 1.0 is pretty thoroughly deprecated now, let alone 0.96.

There's no patch, no activity on the ticket, and no one else has chimed in as having been affected by it. I'm going to close this... If anyone objects, feel free to reopen it.

Note: See TracTickets for help on using tickets.
Back to Top