开发者

Am I missing something with `raw_id_fields` in my Django Admin?

I am using raw_id_fields on a few foreign keys in my admin interface. When this is rendered, the magnifying-glass icon appears, but takes me to the admin list page for that model entitled "Select MODEL to change". I can then click on an item to edit i开发者_如何学JAVAt. I don't want edit the item, I want to select it and put the id in the form.

Is it possible for this to allow me to click on an item and select it? Am I missing something?


That's not supposed to happen. The page after clicking the magnifying glass should be a popup titled: "Select {modelname}".

Are you not getting a popup? I can reproduce that problem if I go directly to the page in the URL, but it should be triggering some JavaScript to produce a popup.

I'd check for any JavaScript warning errors / make sure admin media is being served correctly, specifically this file: RelatedObjectLookups.js (do you see it in the source?)

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜