Exemple #1
0
        public JsonResult Getloanlist(string[] param)
        {
            string QUERYKEY    = param[0];
            string MessageType = param[1];
            var    UserID      = this.UserValidator.UserID;

            Organization.Unit u        = OThinker.H3.Controllers.AppUtility.Engine.Organization.GetUnit(UserID);
            string            UserCode = ((OThinker.Organization.User)u).Appellation;

            string sql = string.Empty;

            if (MessageType == "1")
            {
                #region 贷款申请状态
                sql = string.Format(@" select distinct UNIT_NO CLBH , CX ,  CJHXZ, CJH,
                           TO_CHAR(DKJE ,'FM999,999,999,999,990.00') DKJE,
                           case when V.LOAN_STATUS ='05' or V.LOAN_STATUS ='10' then '处理中'
                                when V.LOAN_STATUS = '40' and V.PAID_AMT>0 then '已放款'
                                when V.LOAN_STATUS = '40' and V.PAID_AMT<=0 then '处理中'
                                when V.LOAN_STATUS = '50' or V.LOAN_STATUS ='30' then '已拒绝'  
                                when V.LOAN_STATUS = '60'  then '已售出'  end  SQZT
                            from I_CLXX C join IN_WFS.V_LOAN_STOCK_LIST@To_Auth_Wfs v on trim(c.CJH) = trim(v.VIN_NO) where DKBH='{0}'", QUERYKEY);
                #endregion
            }
            else if (MessageType == "3")
            {
                #region 临时车架号提醒
//                sql = string.Format(@"select   UNIT_NO CLBH ,ASSET_DESC CX,VIN_NO CJH from  IN_WFS.V_LOAN_STOCK_LIST v
//                    where   ORDER_NO = 'Y' and VIN_UPDATE = 'N' and  V.LOAN_STATUS = '40' and V.PAID_AMT>0
//                           and STOCK_DATE <(to_date('{0}','yyyy-MM-dd') - 5)  and v.dealer_code='{1}'",
//                           DateTime.Now.ToShortDateString(), UserCode);

                sql = string.Format(@"select distinct UNIT_NO CLBH ,MODEL CX,VIN_NO CJH  from  
IN_WFS.V_STOCK_DC_HIS v where   ORDER_NO = 'Y' and VIN_UPDATE = 'N' 
                        and LOAN_GIVEN_DATE <=(to_date('{0}','yyyy-MM-dd') - 5)
                         and v.dealer_code='{1}'", DateTime.Now.ToShortDateString(), QUERYKEY);

                #endregion
            }
            else if (MessageType == "4")
            {
                #region 车架号修改
                sql = string.Format(@"select  BATCH, VEHICLENUMBER CLBH, CARMODEL CX , TEMPORARYFRAMENUMBER LSCJH,  PERMANENTFRAMENUMBER YJCJH  from  I_FrameNumberMiddleTable where BATCH='{0}'", QUERYKEY);

                #endregion
            }
            DataTable             dt = new DataTable();
            DistributorController DC = new DistributorController();
            if (MessageType == "4" || MessageType == "1")
            {
                dt = OThinker.H3.Controllers.AppUtility.Engine.EngineConfig.CommandFactory.CreateCommand().ExecuteDataTable(sql);
            }
            else
            {
                dt = DC.ExecuteDataTableSql("Wholesale", sql);
            }

            return(Json(new { RowData = DistributorController.ToJson(dt) }, JsonRequestBehavior.AllowGet));
        }
Exemple #2
0
        public JsonResult GetOPRWorkItemList(PagerInfo pagerInfo, string distributorName, string startDate, string endDate)
        {
            int       total      = 0;
            DataTable dtWorkitem = QueryOPRWorkItemListData(pagerInfo, distributorName, startDate, endDate, ref total);


            return(Json(new { RowCount = total, RowData = DistributorController.ToJson(dtWorkitem) }, JsonRequestBehavior.AllowGet));
        }
Exemple #3
0
        public JsonResult GetMessageList(PagerInfo pagerInfo, string State)
        {
            DataSet ds = MessageList(pagerInfo, State);

            DistributorController dc = new DistributorController();

            DistributorController.ToJson(ds.Tables[0]);
            int _RowCount = ds.Tables[0].Rows.Count;

            return(Json(new { RowCount = _RowCount, RowData = DistributorController.ToJson(ds.Tables[1]), _Count = ds.Tables[2].Rows.Count }, JsonRequestBehavior.AllowGet));
        }
Exemple #4
0
        public JsonResult GetWORKITEMID(string QUERYKEY)
        {
            var UserID = this.UserValidator.UserID;

            #region 清算异常
            string sql = string.Format(@" select objectid WORKITEMID from  Ot_Workitemfinished where instanceid='{0}' and PARTICIPANT='{1}'", QUERYKEY, UserID);

            #endregion
            DataTable dt = OThinker.H3.Controllers.AppUtility.Engine.EngineConfig.CommandFactory.CreateCommand().ExecuteDataTable(sql);
            return(Json(new { RowData = DistributorController.ToJson(dt) }, JsonRequestBehavior.AllowGet));
        }
        /// <summary>
        /// 查询
        /// </summary>
        public JsonResult GetLoanApprovalInfo(PagerInfo pagerInfo, string JXS, string StartTime, string EndTime)
        {
            DataSet ds = LoanApproval(pagerInfo, JXS, StartTime, EndTime);

            DistributorController dc = new DistributorController();

            DistributorController.ToJson(ds.Tables[0]);
            int _RowCount = ds.Tables[0].Rows.Count;

            return(Json(new { RowCount = _RowCount, RowData = DistributorController.ToJson(ds.Tables[1]) }, JsonRequestBehavior.AllowGet));
        }
Exemple #6
0
        public JsonResult JXSHKInfo(PagerInfo pagerInfo, string JXS, string JXSCODE)
        {
            DataSet ds = GETJXSHKInfo(pagerInfo, JXS, JXSCODE);

            DistributorController dc = new DistributorController();

            DistributorController.ToJson(ds.Tables[0]);
            int _RowCount = ds.Tables[0].Rows.Count;

            return(Json(new { RowCount = _RowCount, RowData = DistributorController.ToJson(ds.Tables[1]) }, JsonRequestBehavior.AllowGet));
        }