ch
2022-07-29 098d529e0d74efd131ec2c70df59b84abb336da7
WebAPI/Controllers/²Ö´æ¹ÜÀí/ÁìÁÏ·¢»õ/Kf_MateOutBackBillController.cs
@@ -40,29 +40,30 @@
                if (sWhere == null || sWhere.Equals(""))
                {
                    ds = oCn.RunProcReturn("select * from h_v_IF_MateOutBackBillList order by æ—¥æœŸ desc", "h_v_IF_MateOutBackBillList");
                    ds = oCn.RunProcReturn("select * from h_v_IF_MateOutBackBillList order by hmainid desc", "h_v_IF_MateOutBackBillList");
                }
                else
                {
                    string sql = "select * from h_v_IF_MateOutBackBillList " + sWhere+ " order by æ—¥æœŸ desc";
                    string sql = "select * from h_v_IF_MateOutBackBillList " + sWhere+ " order by hmainid desc";
                    ds = oCn.RunProcReturn(sql, "h_v_IF_MateOutBackBillList");
                }
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "false!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    objJsonResult.code = "1";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "Sucess!";
                    objJsonResult.data = ds.Tables[0];
                    return objJsonResult;
                }
                //if (ds.Tables[0].Rows.Count != 0 || ds != null)
                //{
                objJsonResult.code = "1";
                objJsonResult.count = 1;
                objJsonResult.Message = "Sucess!";
                objJsonResult.data = ds.Tables[0];
                return objJsonResult;
                //}
                //else
                //{
                //objJsonResult.code = "0";
                //objJsonResult.count = 0;
                //objJsonResult.Message = "无数据";
                //objJsonResult.data = null;
                //return objJsonResult;
                //}
            }
            catch (Exception ex)
            {
@@ -86,7 +87,7 @@
        public object set_DeleteBill(string HInterID,string user)
        {
            //编辑权限
            if (!DBUtility.ClsPub.Security_Log_second("Kf_EntrustOutBill_Drop", 1, false, user))
            if (!DBUtility.ClsPub.Security_Log_second("Kf_MateOutBackBill_Drop", 1, false, user))
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
@@ -588,10 +589,10 @@
                    oItemSub.HEntryCloseDate = DBUtility.ClsPub.isDate(DateTime.Now);
                    oItemSub.HCloseType = false;   //关闭类型
                    //oItemSub.HRemark = "";         //备注
                    oItemSub.HSourceInterID = 0;     // æºå•主内码
                    oItemSub.HSourceEntryID = 0;   //源单子内码
                    //oItemSub.HSourceBillNo = "";  //源单单号
                    //oItemSub.HSourceBillType = ""; //源单类型
                    oItemSub.HSourceInterID = lsmain[0].HSourceInterID;     // æºå•主内码
                    oItemSub.HSourceEntryID = lsmain[0].HSourceEntryID;   //源单子内码
                    oItemSub.HSourceBillNo = lsmain[0].HSourceBillNo;  //源单单号
                    oItemSub.HSourceBillType = lsmain[0].HSourceBillType; //源单类型
                    //oItemSub.HRelationQty = 0;     //关联数量
                    //oItemSub.HRelationMoney = 0;   //关联金额 
                    //oItemSub.HRepairID = 0;       //维修项目