string deptid = "-1";
if (dsdept.Tables[0].Rows.Count > 0)
{
    for (int i = 0; i < dsdept.Tables[0].Rows.Count; i++)
     {
          deptid  = deptid +","+dsdept.Tables[0].Rows[i]["dt_id"].ToString();
     }
}
daoContentSubject.LoginDeptId = deptid;

 

string sql = (isAdmin()) ? " " : " and c.publishdeptid in (" + this.LoginDeptId + ") ";

posted on 2009-03-30 16:20  流星陨落  阅读(547)  评论(0编辑  收藏  举报