def sdetail_render(): flag_ses, user_id = getSession() if not flag_ses: return redirect("login.html") list = MyDaoSdetail().myselect() return render_template('sdetail.html', list=list)
def sdetail_del_ajax(): survey_id = request.form["survey_id"] s_seq = request.form["s_seq"] cnt = MyDaoSdetail().mydelete(survey_id, s_seq) msg = "" if cnt == 1: msg = "ok" else: msg = "ng" return jsonify(msg = msg)
def sdetail_upd_ajax(): survey_id = request.form["survey_id"] s_seq = request.form["s_seq"] question = request.form["question"] a1 = request.form["a1"] a2 = request.form["a2"] a3 = request.form["a3"] a4 = request.form["a4"] in_date = request.form["in_date"] in_user_id = request.form["in_user_id"] up_date = request.form["up_date"] up_user_id = request.form["up_user_id"] cnt = MyDaoSdetail().myupdate(survey_id, s_seq, question, a1, a2, a3, a4, in_date, in_user_id, up_date, up_user_id) msg = "" if cnt == 1: msg = "ok" else: msg = "ng" return jsonify(msg = msg)