Inline edit not functioning in one of my custom zpt view

1 message Options
Embed this post
Permalink
sreenath167 () Inline edit not functioning in one of my custom zpt view
Reply Threaded More More options
Print post
Permalink
i have created a content type Task which sub classes ATEvent,

The following is the code snippet:

TaskSchema = schemata.ATContentTypeSchema.copy() + ATEventSchema.copy()  + atapi.Schema((

 atapi.BooleanField(
                'taskcomplete',
                storage=atapi.AnnotationStorage(),
                searchable=True,
                widget=atapi.BooleanWidget(
                        label=_(u"Task Complete"),
                        description=_(u"Please check if the task is complete"),
                ),
        ),

  .........
))



class Task(base.ATCTContent,ATEvent):
        """ to store the a task details such as startdate , end date, phone number etc. """
        implements(ITask)
        security = ClassSecurityInfo()
        portal_type = "Task"
        schema = TaskSchema

        title = atapi.ATFieldProperty('title')
        description = atapi.ATFieldProperty('description')

         taskcomplete = atapi.ATFieldProperty('taskcomplete')

        ......


I have created a view which displays the task information :

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
      xmlns:tal="http://xml.zope.org/namespaces/tal"
      xmlns:metal="http://xml.zope.org/namespaces/metal"
      xmlns:i18n="http://xml.zope.org/namespaces/i18n"
      lang="en"
      metal:use-macro="here/main_template/macros/master"
      i18n:domain="collective.projectprogress">
<body>
    <metal:block fill-slot="style_slot">
      <!-- Copied from ploneflashupload -->
      <link rel="stylesheet" href="projectprogressstyle.css"
            tal:attributes="href string:$portal_url/++resource++projectprogressstyle.css"
            />
    </metal:block>
    <metal:main fill-slot="main">
    <tal:main-macro metal:define-macro="main">
      ..................
   
    StartDate:  <metal:field use-macro="python:context.widget('startDate', mode='view')">
                                  Main text
                                </metal:field>
End Date: <metal:field use-macro="python:context.widget('endDate', mode='view')">
                                  Main text
                                </metal:field>
Task Complete : <metal:field use-macro="python:context.widget('taskcomplete', mode='view')">
          Main text
        </metal:field>
      ......................

    /tal:main-macro>
</metal:main>

</body>
</html>
 

When i open the above view and mouse over on fileds and click the ajax load symbol will come but never open filed as inline edit

if i remove the ATEvent subcalssing in Task in content definition
class Task(base.ATCTContent,ATEvent): replace with class Task(base.ATCTContent):
the inline edit works on the field but we will not get full functionalites of ATEvent example recurrence schemata etc.

Without removing subclassing how we can achieve  inline edit on task view ???

Thanks in advance..
Sreenath