1
wtt
2024-10-12 b96af6124ac752f85a6bbf17eee2287e059d249d
WebAPI/Controllers/ÏîÄ¿¹ÜÀí/¹¤×÷ÈÎÎñ/PM_WorkTaskBillController.cs
@@ -4094,5 +4094,45 @@
            return response;
        }
        #endregion
        #region è‡ªåŠ¨åŠ è½½é¡µé¢è¡¨å¤´
        /// <summary>
        /// è¿”回项目阶段列表
        ///参数:string sql。
        ///返回值:object。
        /// </summary>
        [Route("Xt_DefineBillMainSet/getDefineBillMainSet")]
        [HttpGet]
        public object getDefineBillMainSet(string HModName, string user)
        {
            try
            {
                string sql = "select b.* from Xt_DefineBillMainSetMain as a inner join Xt_DefineBillMainSetSub as b on a.HInterID = b.HInterID  where a.HModName ='" + HModName + "' and a.HUser ='" + user + "' order by b.HArrangeOrder,b.HArrangeOrderSub";
                ds = oCN.RunProcReturn(sql, "Xt_DefineBillMainSet");
                if(ds!=null && ds.Tables[0].Rows.Count == 0)
                {
                    sql = "select b.* from Xt_DefineBillMainSetMain as a inner join Xt_DefineBillMainSetSub as b on a.HInterID = b.HInterID  where a.HModName ='" + HModName + "' and a.HUser ='admin' order by b.HArrangeOrder,b.HArrangeOrderSub";
                    ds = oCN.RunProcReturn(sql, "Xt_DefineBillMainSet");
                }
                objJsonResult.code = "1";
                objJsonResult.count = 1;
                objJsonResult.Message = "Sucess!";
                objJsonResult.data = ds.Tables[0];
                return objJsonResult;
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "Exception!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
    }
}