I'm new to django and am working with the Calendarium package, i needed to edit it most places to make it fit my need and this is the last problem i cant get round. I have never seen anything like the way this package is set up and cant figure it out i have tried many ways to try to get these widgets working but none have worked so far
i tried:
lass EventMixin(object):
"""Mixin to handle event-related functions."""
model = Event
fields = '__all__'
@method_decorator(permission_required('calendarium.add_event'))
def dispatch(self, request, *args, **kwargs):
retu super(EventMixin, self).dispatch(request, *args, **kwargs)
class EventUpdateView(EventMixin, UpdateView):
"""View to update information of an event."""
pass
class EventCreateView(EventMixin, CreateView):
model = Event
form_class = modelform_factory(Event,
widgets={"start": AdminDateWidget })
template_name = 'event_update.html'
success_url = '/'
this among others, I don't know how far i should go in terms of adding code to this post, if you need any please ask. I would love to get this sorted ASAP
