I made a BrowserView with a custom template for ‘view’ of a content type, but it is being ignored as if it doesn’t see it.
I have a content type, MyEventType that implements IEvent for marker purposes. It also is assigned in my.product.myeventtype.xml the IEventBasic behavior.
from plone.app.contenttypes.interfaces import IEvent
from Products.Five import BrowserView
from plone.directives import form
"""Interface for IMyEventType"""
def __init__(self, context, request):
self.context = context
self.request = request
In my view template:
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
<div tal:replace="structure provider:plone.abovecontenttitle" />
<div tal:replace="structure provider:plone.belowcontentbody" />
When I try viewing the template, it uses the default one. I tried a print statement in the call and render functions, as well as init, but none of the print statements were called. I event tried appending /view in the url to see if that worked and it did not.
I’m sorry that similar questions were asked, but I had something like this working before and I can’t figure out what’s wrong. I got this method of assigning the template to View before with other content types I’ve created. What am I doing wrong?
I am using Plone 4.3.
Edit: I thought I found the solution, but I didn’t. I accidentally assigned the view template to the edit form. So I still don’t understand what is causing the problem.