{fzw:search table="sl_kecheng" sqlvalue="classid=37 and kechengjie in (select laiyuanbianhao from sl_jie where id in (select laiyuanbianhao from sl_history where yonghuming='{fzw:cookie:name="user_name"}' and leixing='视频学习'))" number="2" order="dtime" orderby="desc" id="p1"}
{fzw:for:sql="select *,(select top 1 biaoti from sl_jie as j,sl_history as h where j.laiyuanbianhao={fzw:p1:kechengjie/} and j.id=h.laiyuanbianhao order by h.dtime desc) as jiebiaoti,(select count(id) from sl_jie as j where j.laiyuanbianhao={fzw:p1:kechengjie/}) as zongshu,(select count(id) from sl_jie as j where j.id<=(select top 1 h.laiyuanbianhao from sl_history as h where h.yonghuming='{fzw:cookie:name="user_name"/}' and h.leixing='视频学习' order by dtime desc) and j.laiyuanbianhao={fzw:p1:kechengjie/}) as xuexishu,(select count(id) from sl_biji where laiyuanbianhao={fzw:p1:id/}) as bijishu,(select count(id) from sl_wenda where laiyuanbianhao={fzw:p1:id/} and leixing='提问' and fasongren='{fzw:cookie:name="user_name"/}') as tiwenshu,(select count(id) from sl_pinglun where laiyuanbianhao={fzw:p1:id/} and leixing='视频' and yonghuming='{fzw:cookie:name="user_name"}') as pinglunshu from sl_kecheng as kc where kc.id={fzw:p1:id/}" id="p2"}
{fzw:p2:dtime datetime="yyyy/MM/dd"/}
{fzw:p1:biaoti/}
用时{fzw:for:sql="select count(id) as count_id from sl_time where yonghuming='{fzw:cookie:name="user_name"/}' and leixing='课程视频' and laiyuanbianhao={fzw:p1:id/}" id="p3"}{fzw:p3:count_id/}{/fzw:for:sql}分 学习至{fzw:p2:jiebiaoti/} 笔记({fzw:p2:bijishu/})提问({fzw:p2:tiwenshu/})评论({fzw:p2:pinglunshu/})