def submit_homework_vedio(idHomework, sid, content, tag): """学生提交作业 视频""" sql = "insert into Homework (idHomework,cid,sid,content,tag,type) values " \ "('%s',(select cid from Student where idStudent='%s'),'%s','%s','%s','video')" \ % (clean(idHomework), clean(sid), clean(sid), cleanLink(content), clean(tag)) return db.execute(sql)
def submit_homework(idHomework, sid, content, tag): """学生提交作业 三视图""" sql = "insert into Homework " \ "(idHomework,cid,sid,content,tag) " \ "values " \ "('%s'," \ "(select cid from Student where idStudent='%s')," \ "'%s'," \ "'%s'," \ "'%s')" % (clean(idHomework), clean(sid), clean(sid), cleanLink(content), clean(tag)) return db.execute(sql)