페이지별 학습시간(초)전달 : parent.getpagelearn(pageindex) 추가
This commit is contained in:
parent
6a3bb62f3e
commit
4df72e9888
|
|
@ -560,8 +560,15 @@ namespace NP.Base.Controllers
|
|||
}
|
||||
return JsonOK(0);
|
||||
}
|
||||
|
||||
|
||||
[HttpPost]
|
||||
public JsonResult PageLearningTotalTime(Int64 lectno, Int64 cmino, int cpno)
|
||||
{
|
||||
if (SUserInfo.UserNo > 0)
|
||||
{
|
||||
var totstudy = Dao.Get<int>("cr.lectinningpage.totstudy", new Hashtable() { { "lectno", lectno }, { "cmino", cmino }, { "cpno", cpno } }).First();
|
||||
return JsonOK(totstudy, true);
|
||||
}
|
||||
return JsonOK(0);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -1398,5 +1398,10 @@
|
|||
where a.typejob is not null and a.typejob <> ""
|
||||
group by a.typejob
|
||||
</select>
|
||||
<select id="cr.lectinningpage.totstudy" parameterClass="hashtable" resultClass="int">
|
||||
select ifnull(sum(totstudy),-1) totstudy
|
||||
from lectinningpage
|
||||
where lectno = #lectno# and cmino = #cmino# and cpno = #cpno#
|
||||
</select>
|
||||
</statements>
|
||||
</sqlMap>
|
||||
|
|
@ -610,4 +610,23 @@
|
|||
self.close();
|
||||
}
|
||||
}
|
||||
/* 페이지별 학습시간(초)전달 : parent.getpagelearn(pageindex) */
|
||||
function getpagelearn(pseq) {
|
||||
var result = -1;
|
||||
var cpno = getint(_cpnos[pseq - 1]);
|
||||
$.ajax({
|
||||
type: "post",
|
||||
url: "/focommon/pagelearningtotaltime",
|
||||
async: false,
|
||||
data: { lectno: @Model.lip.lectno, cmino: @Model.lip.cmino, cpno: cpno},
|
||||
success: function (data) {
|
||||
if (data.code == 1000) {
|
||||
result = parseInt(data.obj);
|
||||
} else {
|
||||
result = -1;
|
||||
}
|
||||
}
|
||||
});
|
||||
return result;
|
||||
}
|
||||
</script>
|
||||
Loading…
Reference in New Issue