sdi/views.py
branchanoop
changeset 157 6f7faa7af9d6
parent 156 cebb6ffb5f83
child 158 f39310ac2245
equal deleted inserted replaced
156:cebb6ffb5f83 157:6f7faa7af9d6
   179 
   179 
   180     if request.method == "POST" and form.is_valid():
   180     if request.method == "POST" and form.is_valid():
   181         selected_users = form.cleaned_data['selected_users']
   181         selected_users = form.cleaned_data['selected_users']
   182         for user in selected_users:
   182         for user in selected_users:
   183             user_info = user.registrantinfo_set.all()[0]
   183             user_info = user.registrantinfo_set.all()[0]
   184             user_info.status_of_attending_sagedays = "2"
   184             user_info.status_of_workshop = "2"
   185             user_info.save()
   185             user_info.save()
   186         
   186         
   187         return render_to_response("sent_sgd_confirm.html", {"selected_users":selected_users})
   187         return render_to_response("sent_sgd_confirm.html", {"selected_users":selected_users})
   188     else:
   188     else:
   189         return render_to_response("send_acco_cnf.html", {"rejected": rejected_ppl,
   189         return render_to_response("send_acco_cnf.html", {"rejected": rejected_ppl,