def _do_update_record(profile, request, object):
 if profile.has_permission(object, mode='x'):
  if request.POST:
   record = UpdateRecord()
   record.object = object
   record.record_type = 'manual'
   form = UpdateRecordForm(request.POST, instance=record)
   if form.is_valid():
    record = form.save()
    record.set_user_from_request(request)
    record.save()
    record.about.add(object)
    object.set_last_updated()
  else:
   form = UpdateRecordForm()
 else:
  form = None
 return form

def _do_update_record ( profile , request , object ) : if profile . has_permission ( object , mode = 'x' ) : if request . POST : record = UpdateRecord ( ) record . object = object record . record_type = 'manual' form = UpdateRecordForm ( request . POST , instance = record ) if form . is_valid ( ) : record = form . save ( ) record . set_user_from_request ( request ) record . save ( ) record . about . add ( object ) object . set_last_updated ( ) else : form = UpdateRecordForm ( ) else : form = None return form
get the update record form .