王 垚
2022-07-12 ddabe21abf229d23ccb248276e818c5e1101033d
WebAPI/Controllers/¹¤×ʹÜÀí/Pay_WorkTimesBillController.cs
@@ -328,8 +328,6 @@
                return objJsonResult;
            }
        }
        //
        /// <summary>
        /// é€šè¿‡ç­ç»„查询职员信息
        ///参数:string sql。
@@ -343,7 +341,7 @@
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "产品器具未选择";
                objJsonResult.Message = "班组未选择";
                objJsonResult.data = null;
                return objJsonResult;
            }
@@ -372,6 +370,31 @@
                return objJsonResult;
            }
        }
        [Route("Pay_WorkTimesBill/calcAvgMoney")]
        [HttpPost]
        public object GetEmployeeByHGroup([FromBody] JObject msg) {
            try
            {
                SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
                List<object> list = new List<object>();
                DataSet ds;
                string sql = string.Format($"exec h_p_CalcAvgMoney '{msg["msg"]}'");
                ds = oCN.RunProcReturn(sql, "h_p_CalcAvgMoney");
                objJsonResult.code = "1";
                objJsonResult.count = 1;
                objJsonResult.Message = "获取信息成功!";
                objJsonResult.data = ds.Tables[0];
                return objJsonResult;
            }
            catch (Exception ex)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "没有返回任何记录!" + ex.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
    }
}