kyy
3 天以前 c78e94462c0ba8b3c1ec6fbcddaa3eec9ffcb980
WebApi/Gs.Wom/WorkService/WorkProController.cs
@@ -49,15 +49,22 @@
            sbSql.Append("( ");
            sbSql.Append("select top 100000 ROW_NUMBER() over(order by " +
                         sortName + " " + model.sortOrder +
                         ") as rowIndex,cast(0 as bit) as chkInt,a.*,(a.processNo+':'+a.processName) as processNoAndName,(case  a.isStatus when 1 then '正常' when -1 then  '禁用'  else  cast(a.isStatus as nvarchar(4))  end) as isStatusTxt from WORK_PROCESS a  where 1=1" +
                         keyWhere);
                         ") as rowIndex,cast(0 as bit) as chkInt,a.*," +
                         "(a.processNo+':'+a.processName) as processNoAndName," +
                         "(case a.isStatus when 1 then '正常' when -1 then  '禁用'  else  cast(a.isStatus as nvarchar(4))  end) as isStatusTxt," +
                         "cj.USER_NAME as createByName," +
                         "isnull(gx.USER_NAME,a.lastUpdateBy) as lastupdateByName " +
                         "from WORK_PROCESS a " +
                         "left join SYS_USER cj on cj.ACCOUNT=a.createBy " +
                         "left join SYS_USER gx on gx.ACCOUNT=a.lastUpdateBy " +
                         "where 1=1" + keyWhere);
            sbSql.Append(") as T ");
            sbSql.Append(" where T.rowindex>(" + currentPage + "-1)*" +
                         everyPageSize + " and  T.rowindex<=" + currentPage + "*" +
                         everyPageSize);
            sbSql.Append(" order by rowindex asc ");
            sbSql.Append(
                " select count(1) as intTotal  from WORK_PROCESS a  where 1=1 " +
                " select count(1) as intTotal  from WORK_PROCESS a  left join SYS_USER cj on cj.ACCOUNT=a.createBy left join SYS_USER gx on gx.ACCOUNT=a.lastUpdateBy where 1=1 " +
                keyWhere);
            var dset = new DataSet();
            try