Ejemplo n.º 1
0
        /// <summary>
        /// 选择商品信息
        /// </summary>
        /// <param name="bsgridPage"></param>
        /// <returns></returns>
        public ActionResult SelectShangPinXinXi(BsgridPage bsgridPage)
        {
            var listOrderFormPact = from tbGoods in MyModels.B_GoodsList
                                    join tbb in MyModels.B_GoodsDetailList on tbGoods.GoodsID equals tbb.GoodsID
                                    join tbGoodsDetail in MyModels.B_GoodsDetailList on tbb.GoodsDetailID equals tbGoodsDetail.GoodsDetailID
                                    join tbPurchase in MyModels.B_PurchaseList on tbGoodsDetail.PurchaseID equals tbPurchase.PurchaseID
                                    join tbc in MyModels.S_PackInfoIDList on tbb.GoodsDetailID equals tbc.GoodsDetailID
                                    join tbPackInfo in MyModels.S_PackInfoIDList on tbc.PackInfoID equals tbPackInfo.PackInfoID
                                    orderby tbGoods.GoodsID
                                    where tbGoods.AuditingBit == true
                                    select new Vo.Goods
            {
                GoodsID          = tbGoods.GoodsID,
                GoodsName        = tbGoods.GoodsName,
                GoodsCode        = tbGoods.GoodsCode,
                GoodsTiaoMa      = tbGoods.GoodsTiaoMa,
                AdvanceCess      = tbGoods.AdvanceCess,                                                                       /*进项税率*/
                RetailMonovalent = tbGoodsDetail.RetailMonovalent,                                                            /*零售单价*/
                NoAdvanceBid     = tbPurchase.NoAdvanceBid,                                                                   /*不含税进价*/
                AdvanceBid       = tbPurchase.AdvanceBid,                                                                     /*含税进价*/
                PackContent      = tbPackInfo.PackContent,                                                                    /*包装含量*/
            };
            int          intTotalRow = listOrderFormPact.Count();                                                             //总行数
            List <Goods> listNotices = listOrderFormPact.Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList(); //分页

            Bsgrid <Goods> bsgrid = new Bsgrid <Goods>();

            bsgrid.success   = true;
            bsgrid.totalRows = intTotalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = listNotices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
Ejemplo n.º 2
0
        /// <summary>
        /// 未关联用户
        /// </summary>
        /// <param name="bsgridPage"></param>
        /// <returns></returns>
        public ActionResult SelectSpreadUserbygxID(BsgridPage bsgridPage)
        {
            var VarVip = from tbSpreadUser in myDYXTEntities.B_SpreadUserTable
                         join tbUser in myDYXTEntities.B_UserTable on tbSpreadUser.UserID equals tbUser.UserID
                         join tbSpreadType in myDYXTEntities.B_SpreadTypeTable on tbSpreadUser.SpreadTypeID equals tbSpreadType.SpreadTypeID
                         join tbStatus in myDYXTEntities.S_StatusTable on tbSpreadUser.StatusID equals tbStatus.StatusID
                         where tbSpreadUser.StatusID == 20
                         select new B_SpreadUserVo
            {
                SpreadUserID   = tbSpreadUser.SpreadUserID,
                UserName       = tbUser.UserName,
                PostBox        = tbUser.PostBox,
                Name           = tbSpreadType.Name,
                StatusName     = tbStatus.StatusName,
                ReleaseTimeStr = tbSpreadUser.RelevanceTime.ToString()
            };

            int totalRow = VarVip.Count();
            List <B_SpreadUserVo> notices = VarVip.OrderBy(p => p.SpreadUserID).
                                            Skip(bsgridPage.GetStartIndex()).
                                            Take(bsgridPage.pageSize).
                                            ToList();
            Bsgrid <B_SpreadUserVo> bsgrid = new Bsgrid <B_SpreadUserVo>();

            bsgrid.success   = true;
            bsgrid.totalRows = totalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = notices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
Ejemplo n.º 3
0
        public ActionResult SelectCollage(BsgridPage bsgridPage)//查询领料单据信息
        {
            var lingItem = (from tbCollage in myModels.PW_Collage
                            join tbReception in myModels.PW_Reception on tbCollage.ReceptionID equals tbReception.ReceptionID
                            select new CollageVo
            {
                CollageID = tbCollage.CollageID,                    //领料ID
                ReceptionID = tbReception.ReceptionID,
                CarNum = tbReception.CarNum.Trim(),                 //车牌
                Owner = tbReception.Owner.Trim(),                   //车主
                MaintenanceNum = tbReception.MaintenanceNum.Trim(), //结算单号
                CollageState = tbReception.CollageState.Trim() != "已退料" ? tbReception.CollageState.Trim() : "未领料",
                ForeMan = tbCollage.ForeMan.Trim(),                 //领料员
                Operator = tbCollage.Operator.Trim(),               //操作人
                Auditor = tbCollage.Auditor.Trim(),                 //审核人
                Amount = tbCollage.Amount,                          //总金额
                AuditDate = tbCollage.AuditDate.ToString(),         //审核时间
                CollageDate = tbCollage.CollageDate.ToString(),     //领料时间
                ToAudit = tbCollage.ToAudit,                        //审核否
                Remark = tbCollage.Remark.Trim(),                   //备注
            }).ToList();
            int count = lingItem.Count();
            List <CollageVo>   listCollage = lingItem.OrderBy(m => m.ToAudit).Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList();
            Bsgrid <CollageVo> bsgrid      = new Bsgrid <CollageVo>()
            {
                success   = true,
                totalRows = count,
                curPage   = bsgridPage.curPage,
                data      = listCollage
            };

            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
Ejemplo n.º 4
0
        public ActionResult SelectPersonalSpreadMessage(BsgridPage bsgridPage, string SpreadUserNameID)
        {
            var VarVip = from tbPersonalSpreadMessage in myDYXTEntities.B_PersonalSpreadMessage
                         join tbUser in myDYXTEntities.B_UserTable on tbPersonalSpreadMessage.SpreadUserID equals tbUser.UserID
                         select new B_PersonalSpreadMessageVo
            {
                PersonalSpreadID = tbPersonalSpreadMessage.PersonalSpreadID,
                SpreadUserName   = tbUser.UserName,
                SpreadUserID     = tbPersonalSpreadMessage.SpreadUserID,
                SpreadPeople     = tbPersonalSpreadMessage.SpreadPeople,
                InvestTime       = tbPersonalSpreadMessage.InvestTime,
                InvestAmount     = tbPersonalSpreadMessage.InvestAmount,
                InvestTiCheng    = tbPersonalSpreadMessage.InvestTiCheng,
                RepaymentTime    = tbPersonalSpreadMessage.RepaymentTime,
                RepaymentAmount  = tbPersonalSpreadMessage.RepaymentAmount,
                RepaymentTiCheng = tbPersonalSpreadMessage.RepaymentTiCheng
            };

            if (!string.IsNullOrEmpty(SpreadUserNameID))
            {
                VarVip = VarVip.Where(n => n.SpreadUserName.Contains(SpreadUserNameID));
            }
            int totalRow = VarVip.Count();
            List <B_PersonalSpreadMessageVo> notices = VarVip.OrderBy(p => p.PersonalSpreadID).
                                                       Skip(bsgridPage.GetStartIndex()).
                                                       Take(bsgridPage.pageSize).
                                                       ToList();
            Bsgrid <B_PersonalSpreadMessageVo> bsgrid = new Bsgrid <B_PersonalSpreadMessageVo>();

            bsgrid.success   = true;
            bsgrid.totalRows = totalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = notices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
Ejemplo n.º 5
0
        /// <summary>
        /// 资金设置查询
        /// </summary>
        /// <param name="bsgridPage"></param>
        /// <returns></returns>
        public ActionResult SelectSpreadType(BsgridPage bsgridPage)
        {
            var VarVip = from tbSpreadType in myDYXTEntities.B_SpreadTypeTable
                         join tbFundStatus in myDYXTEntities.S_FundStatustable on tbSpreadType.FundStatusID equals tbFundStatus.FundStatusID
                         select new B_SpreadTypeVo
            {
                SpreadTypeID       = tbSpreadType.SpreadTypeID,
                FundStatusID       = tbSpreadType.FundStatusID,
                Name               = tbSpreadType.Name,
                Title              = tbSpreadType.Title,
                IdentificationName = tbSpreadType.IdentificationName,
                FundStatusName     = tbFundStatus.FundStatusName,
                CapitalType        = tbSpreadType.CapitalType,
                Scale              = tbSpreadType.Scale
            };

            int totalRow = VarVip.Count();
            List <B_SpreadTypeVo> notices = VarVip.OrderBy(p => p.SpreadTypeID).
                                            Skip(bsgridPage.GetStartIndex()).
                                            Take(bsgridPage.pageSize).
                                            ToList();
            Bsgrid <B_SpreadTypeVo> bsgrid = new Bsgrid <B_SpreadTypeVo>();

            bsgrid.success   = true;
            bsgrid.totalRows = totalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = notices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
Ejemplo n.º 6
0
        /// <summary>
        /// 查询商品明细
        /// </summary>
        /// <param name="bsgridPage"></param>
        /// <returns></returns>
        public ActionResult ChaXunShangPingMingXi(BsgridPage bsgridPage)
        {
            var listGoodsDetail = (from tbGoodsDetail in MyModels.B_GoodsDetailList
                                   join tbGoods in MyModels.B_GoodsList on tbGoodsDetail.GoodsID equals tbGoods.GoodsID
                                   orderby tbGoodsDetail.GoodsDetailID
                                   select new Vo.Goods
            {
                GoodsDetailID = tbGoodsDetail.GoodsDetailID,
                GoodsID = tbGoods.GoodsID,
                GoodsCode = tbGoods.GoodsCode,
                GoodsName = tbGoods.GoodsName,
                RetailMonovalent = tbGoodsDetail.RetailMonovalent,
                //FactPrice = tbGoodsDetail.FactPrice,
                MemberPrice = tbGoodsDetail.MemberPrice,
            });
            int          intTotalRow = listGoodsDetail.Count();//总行数
            List <Goods> listNotices = listGoodsDetail.Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList();

            Bsgrid <Goods> bsgrid = new Bsgrid <Goods>();

            bsgrid.success   = true;
            bsgrid.totalRows = intTotalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = listNotices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
Ejemplo n.º 7
0
        /// <summary>
        /// 查询商品明细
        /// </summary>
        /// <param name="bsgridPage"></param>
        /// <returns></returns>
        public ActionResult ShangPinXinXiTianXie(BsgridPage bsgridPage)
        {
            var listGoodsDetail = (from tbGoodsDetail in MyModels.B_GoodsDetailList
                                   join tbGoods in MyModels.B_GoodsList on tbGoodsDetail.GoodsID equals tbGoods.GoodsID
                                   join tbPurchase in MyModels.B_PurchaseList on tbGoodsDetail.PurchaseID equals tbPurchase.PurchaseID
                                   orderby tbGoodsDetail.GoodsDetailID
                                   select new Vo.Goods
            {
                GoodsDetailID = tbGoodsDetail.GoodsDetailID,
                GoodsID = tbGoods.GoodsID,
                GoodsCode = tbGoods.GoodsCode,
                GoodsName = tbGoods.GoodsName,
                AdvanceCess = tbGoods.AdvanceCess,
                NoAdvanceBid = tbPurchase.NoAdvanceBid,
                AdvanceBid = tbPurchase.AdvanceBid,
            });
            int          intTotalRow = listGoodsDetail.Count();//总行数
            List <Goods> listNotices = listGoodsDetail.Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList();

            Bsgrid <Goods> bsgrid = new Bsgrid <Goods>();

            bsgrid.success   = true;
            bsgrid.totalRows = intTotalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = listNotices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
Ejemplo n.º 8
0
        public ActionResult SelectNoticeTypeDetailByNoticeTypeId(BsgridPage bsgridPage)
        {
            var listOrderFormPact = (from tbOrderFormPact in MyModels.B_GoodsList
                                     join tbAgreementType in MyModels.S_EstimateUnitList on tbOrderFormPact.EstimateUnitID equals tbAgreementType.EstimateUnitID



                                     orderby tbOrderFormPact.GoodsID
                                     select new Goods
            {
                GoodsID = tbOrderFormPact.GoodsID,

                SupplierID = tbOrderFormPact.SupplierID,
                GoodsName = tbOrderFormPact.GoodsName,
                EstimateUnitName = tbAgreementType.EstimateUnitName,
                ArtNo = tbOrderFormPact.ArtNo,

                SpecificationsModel = tbOrderFormPact.SpecificationsModel
            }
                                     );
            int          intTotalRow = listOrderFormPact.Count();                                                             //总行数
            List <Goods> listNotices = listOrderFormPact.Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList(); //分页

            Bsgrid <Goods> bsgrid = new Bsgrid <Goods>();

            bsgrid.success   = true;
            bsgrid.totalRows = intTotalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = listNotices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
Ejemplo n.º 9
0
        public ActionResult Selectaa(BsgridPage bsgridPage)
        {
            var listOrderFormPact = (from tbOrderFormPact in MyModels.B_GoodsList
                                     join tbAgreementType in MyModels.B_GoodsChopList on tbOrderFormPact.GoodsChopID equals tbAgreementType.GoodsChopID
                                     join tbGoodsClassify in MyModels.B_GoodsClassifyList on tbOrderFormPact.GoodsClassifyID equals tbGoodsClassify.GoodsClassifyID

                                     orderby tbOrderFormPact.GoodsID
                                     select new Goods
            {
                GoodsID = tbOrderFormPact.GoodsID,
                ReleaseTimeStr = tbOrderFormPact.RegisterTime.ToString(),
                GoodsName = tbOrderFormPact.GoodsName,
                GoodsChopID = tbOrderFormPact.GoodsChopID,
                GoodsChopName = tbAgreementType.GoodsChopName,
                ReleaseTimeStrr = tbOrderFormPact.Checktime.ToString(),
                GoodsClassifyID = tbOrderFormPact.GoodsClassifyID,
                GoodsClassifyName = tbGoodsClassify.GoodsClassifyName
            }
                                     );
            int          intTotalRow = listOrderFormPact.Count();                                                             //总行数
            List <Goods> listNotices = listOrderFormPact.Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList(); //分页

            Bsgrid <Goods> bsgrid = new Bsgrid <Goods>();

            bsgrid.success   = true;
            bsgrid.totalRows = intTotalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = listNotices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
Ejemplo n.º 10
0
        public ActionResult SelectPredate(BsgridPage bsgridPage, string ToAudit, string PredateNum)//查询预约单据信息
        {
            var lingItem = (from tbPredate in myModels.PW_Predate
                            join tbCarder in myModels.SYS_Carder on tbPredate.CarderID equals tbCarder.CarderID
                            join tbRepair in myModels.SYS_Repair on tbPredate.RepairID equals tbRepair.RepairID
                            select new PredateVo
            {
                PredateID = tbPredate.PredateID,                   //预约维修ID
                CarderID = tbCarder.CarderID,                      //接车人ID
                CarderName = tbCarder.CarderName.Trim(),           //接车人名称
                VehicleType = tbPredate.VehicleType.Trim(),        //车型
                CustomerNum = tbPredate.CustomerNum.Trim(),        //车型
                RepairID = tbRepair.RepairID,                      //修理类别ID
                RepairName = tbRepair.RepairName.Trim(),           //修理类别名称
                PredateNum = tbPredate.PredateNum.Trim(),          //预约单号
                OpenDates = tbPredate.OpenDate.ToString(),         //开单日期
                MaintenanceNum = tbPredate.MaintenanceNum.Trim(),  //维修单号
                MaintainDatas = tbPredate.MaintainData.ToString(), //维修日期
                CarNum = tbPredate.CarNum.Trim(),                  //车牌
                Owner = tbPredate.Owner.Trim(),                    //车主
                CarMasterPhone = tbPredate.CarMasterPhone,         //车主电话
                Contacts = tbPredate.Contacts.Trim(),              //联系人
                Telephone = tbPredate.Telephone.Trim(),            //联系电话
                Remark = tbPredate.Remark.Trim(),                  //备注
                ToAudit = tbPredate.ToAudit,                       //审核否
                Amount = tbPredate.Amount,                         //总金额
                Receivable = tbPredate.Receivable,                 //应收金额
                Describe = tbPredate.Describe.Trim(),              //描述
                ToTransferOrder = tbPredate.ToTransferOrder,       //转单否
            }).ToList();

            #region 拼接条件
            if (!string.IsNullOrEmpty(PredateNum))
            {
                lingItem = lingItem.Where(m => m.PredateNum.Contains(PredateNum)).ToList();
            }
            if (!string.IsNullOrEmpty(ToAudit))
            {
                if (ToAudit == "true")
                {
                    lingItem = lingItem.Where(m => m.ToAudit == true).ToList();
                }
                else
                {
                    lingItem = lingItem.Where(m => m.ToAudit == false).ToList();
                }
            }

            #endregion
            int count = lingItem.Count();
            List <PredateVo>   listPredate = lingItem.OrderBy(m => m.ToAudit).Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList();
            Bsgrid <PredateVo> bsgrid      = new Bsgrid <PredateVo>()
            {
                success   = true,
                totalRows = count,
                curPage   = bsgridPage.curPage,
                data      = listPredate,
            };
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
Ejemplo n.º 11
0
        /// <summary>
        /// 关联属性
        /// </summary>
        /// <returns></returns>

        public ActionResult SelectAgreementList(BsgridPage bsgridPage)
        {
            try
            {
                var AgreementList = (from tbAgreement in MyModels.B_AgreementList
                                     join tbAdjustAccountsFashionID in MyModels.S_AdjustAccountsFashionList on tbAgreement.AdjustAccountsFashionID equals tbAdjustAccountsFashionID.AdjustAccountsFashionID
                                     join tbAgreementStateID in MyModels.S_AgreementStateList on tbAgreement.AgreementStateID equals tbAgreementStateID.AgreementStateID
                                     select new AgreementVo
                {
                    AdjustAccountsFashionID = tbAgreement.AdjustAccountsFashionID,
                    AdjustAccountsFashion = tbAdjustAccountsFashionID.AdjustAccountsFashion,
                    StartTime = tbAgreement.AgreementBeginTime.ToString(),
                    AgreementCode = tbAgreement.AgreementCode,
                    AgreementID = tbAgreement.AgreementID,
                    EndTiem = tbAgreement.AgreementFinishTime.ToString(),
                    ReleaseTimeStr = tbAgreement.ConclusionTime.ToString(),
                    AgreementState = tbAgreementStateID.AgreementState,
                    GoodsID = tbAgreement.GoodsID
                }).OrderBy(m => m.AgreementCode).Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList();
                int totalRow = AgreementList.Count();
                Bsgrid <AgreementVo> bsgrid = new Bsgrid <AgreementVo>();
                bsgrid.success   = true;
                bsgrid.totalRows = totalRow;
                bsgrid.curPage   = bsgridPage.curPage;
                bsgrid.data      = AgreementList;
                return(Json(bsgrid, JsonRequestBehavior.AllowGet));
            }
            catch (Exception)
            {
                return(Json("failed", JsonRequestBehavior.AllowGet));
            }
        }
Ejemplo n.º 12
0
 /// <summary>
 /// 查询开启关闭申报系列表
 /// </summary>
 /// <param name="bsgridPage"></param>
 /// <returns></returns>
 public ActionResult SelectUnitDeclare(BsgridPage bsgridPage)
 {
     try
     {
         List <UnitDeclareVo> linqUnitDeclare = (from tbUnitDeclare in myModels.B_UnitDeclare
                                                 join tbDeclareSeries in myModels.S_DeclareSeries on tbUnitDeclare.DeclareSeriesID equals tbDeclareSeries.DeclareSeriesID
                                                 join tbDeclareGrade in myModels.S_DeclareGrade on tbUnitDeclare.DeclareGradeID equals tbDeclareGrade.DeclareGradeID
                                                 join tbDeclareYear in myModels.S_DeclareYear on tbUnitDeclare.DeclareYearID equals tbDeclareYear.DeclareYearID
                                                 select new UnitDeclareVo
         {
             UnitDeclareID = tbUnitDeclare.UnitDeclareID,
             DeclareSeries = tbDeclareSeries.DeclareSeries,
             DeclareGrade = tbDeclareGrade.DeclareGrade,
             Explain = tbUnitDeclare.Explain,
             DeclareYear = tbDeclareYear.DeclareYear,
             ToVoidNo = tbUnitDeclare.ToVoidNo
         }).ToList();
         int intTotalRow = linqUnitDeclare.Count();
         List <UnitDeclareVo>   listFile = linqUnitDeclare.Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList();//分页
         Bsgrid <UnitDeclareVo> bsgrid   = new Bsgrid <UnitDeclareVo>();
         bsgrid.success   = true;
         bsgrid.curPage   = bsgridPage.curPage;
         bsgrid.totalRows = intTotalRow;
         bsgrid.data      = linqUnitDeclare;
         return(Json(bsgrid, JsonRequestBehavior.AllowGet));
     }
     catch (Exception)
     {
         return(Json("failed", JsonRequestBehavior.AllowGet));
     }
 }
Ejemplo n.º 13
0
 /// <summary>
 /// 查询工作人员列表
 /// </summary>
 /// <param name="bsgridPage"></param>
 /// <returns></returns>
 public ActionResult SelectWorkPersonnel(BsgridPage bsgridPage)
 {
     try
     {
         List <WorkVo> linqWork = (from tbWork in myModels.B_WorkPersonnel
                                   join tbUserState in myModels.S_UserState on tbWork.UserStateID equals tbUserState.UserStateID
                                   join tbSex in myModels.S_Sex on tbWork.SexID equals tbSex.SexID
                                   select new WorkVo
         {
             WorkPersonnelID = tbWork.WorkPersonnelID,
             Workname = tbWork.Workname,
             WorkLoginName = tbWork.WorkLoginName,
             Sex = tbSex.Sex,
             Password = tbWork.Password,
             MaillSite = tbWork.MaillSite,
             PhoneCode = tbWork.PhoneCode,
             registerTimer = tbWork.RegisterTime.ToString(),
             finallyEnterTimer = tbWork.FinallyEnterTime.ToString(),
             UserState = tbUserState.UserState,
         }).ToList();
         int             intTotalRow = linqWork.Count();
         List <WorkVo>   listFile    = linqWork.Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList();//分页
         Bsgrid <WorkVo> bsgrid      = new Bsgrid <WorkVo>();
         bsgrid.success   = true;
         bsgrid.curPage   = bsgridPage.curPage;
         bsgrid.totalRows = intTotalRow;
         bsgrid.data      = linqWork;
         return(Json(bsgrid, JsonRequestBehavior.AllowGet));
     }
     catch (Exception)
     {
         return(Json("failed", JsonRequestBehavior.AllowGet));
     }
 }
Ejemplo n.º 14
0
 /// <summary>
 /// 查询角色列表
 /// </summary>
 /// <param name="bsgridPage"></param>
 /// <returns></returns>
 public ActionResult SelectRole(BsgridPage bsgridPage)
 {
     try
     {
         List <RoleVo> linqRole = (from tbRole in myModels.B_Role
                                   select new RoleVo
         {
             RoleID = tbRole.RoleID,
             RoleCode = tbRole.RoleCode,
             RoleName = tbRole.RoleName,
             RoleDescribe = tbRole.RoleDescribe,
         }).ToList();
         int             intTotalRow = linqRole.Count();
         List <RoleVo>   listFile    = linqRole.Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList();//分页
         Bsgrid <RoleVo> bsgrid      = new Bsgrid <RoleVo>();
         bsgrid.success   = true;
         bsgrid.curPage   = bsgridPage.curPage;
         bsgrid.totalRows = intTotalRow;
         bsgrid.data      = linqRole;
         return(Json(bsgrid, JsonRequestBehavior.AllowGet));
     }
     catch (Exception)
     {
         return(Json("failed", JsonRequestBehavior.AllowGet));
     }
 }
Ejemplo n.º 15
0
        //生产信息
        public ActionResult Selectzhengshu(BsgridPage bsgridPage)
        {
            var listOrderFormPact = (from tbOrderFormPact in MyModels.S_ContactCertificate
                                     join tbCompany in MyModels.B_SupplierList on tbOrderFormPact.SupplierID equals tbCompany.SupplierID
                                     orderby tbOrderFormPact.ContactCertificateID
                                     select new ContactCertificateVo
            {
                ContactCertificateID = tbOrderFormPact.ContactCertificateID,
                ReleaseTimeStr = tbOrderFormPact.ContactCertificateTime.ToString(),
                ContactCertificateName = tbOrderFormPact.ContactCertificateName,
                ContactCertificateHM = tbOrderFormPact.ContactCertificateHM,
                ReleaseTimeStrr = tbOrderFormPact.ContactCertificateTimeless.ToString(),
                SupplierID = tbOrderFormPact.SupplierID,
                SupplierName = tbCompany.SupplierName,
                SupplierCHName = tbCompany.SupplierCHName,
            }
                                     );
            int intTotalRow = listOrderFormPact.Count();                                                                                     //总行数
            List <ContactCertificateVo> listNotices = listOrderFormPact.Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList(); //分页

            Bsgrid <ContactCertificateVo> bsgrid = new Bsgrid <ContactCertificateVo>();

            bsgrid.success   = true;
            bsgrid.totalRows = intTotalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = listNotices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
        public ActionResult SelectUsertype(BsgridPage bsgridPage, string SeUserName, int SeUserNameID)
        {
            var varB_Module = from tbUser in myDYXTEntities.B_UserTable
                              join tbUserType in myDYXTEntities.S_UserTypeTable on tbUser.UserTypeID equals tbUserType.UserTypeID
                              where tbUserType.UserTypeID != 2 && tbUserType.UserTypeID != 3 && tbUserType.UserTypeID != 1
                              select new USerbankVo
            {
                UserID       = tbUser.UserID,
                UserName     = tbUser.UserName,
                TrueName     = tbUser.TrueName,
                UserTypeName = tbUserType.UserTypeName
            };

            if (!string.IsNullOrEmpty(SeUserName))
            {
                varB_Module = varB_Module.Where(n => n.UserName.Contains(SeUserName));
            }
            if (SeUserNameID > 0)
            {
                varB_Module = varB_Module.Where(p => p.UserID == SeUserNameID);
            }
            int totalRow = varB_Module.Count();
            List <USerbankVo> notices = varB_Module.OrderBy(p => p.UserID).
                                        Skip(bsgridPage.GetStartIndex()).
                                        Take(bsgridPage.pageSize).
                                        ToList();
            Bsgrid <USerbankVo> bsgrid = new Bsgrid <USerbankVo>();

            bsgrid.success   = true;
            bsgrid.totalRows = totalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = notices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
Ejemplo n.º 17
0
        public ActionResult SelectHeellingInfo(BsgridPage bsgridPage)//选择信息
        {
            var listGoods = (from tbSellingInfo in MyModels.S_SellingInfoList
                             orderby tbSellingInfo.SellingInfoID
                             select new SellingInfoVo
            {
                SellingInfoID = tbSellingInfo.SellingInfoID,
                Gtotal = tbSellingInfo.Gtotal,
                SingleFee = tbSellingInfo.SingleFee,
                FeeAmount = tbSellingInfo.FeeAmount,
                RAmount = tbSellingInfo.RAmount,
                XAmount = tbSellingInfo.XAmount,
                Summary = tbSellingInfo.Summary
            });
            int intTotalRow = listGoods.Count();                                                                              //总行数
            List <SellingInfoVo> listNotices = listGoods.Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList(); //分页

            Bsgrid <SellingInfoVo> bsgrid = new Bsgrid <SellingInfoVo>();

            bsgrid.success   = true;
            bsgrid.totalRows = intTotalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = listNotices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
        public ActionResult Selectmanager(BsgridPage bsgridPage)
        {
            var varB_Module = from tb_ManagerRecord in myDYXTEntities.B_ManagerRecord
                              join tb_user in myDYXTEntities.B_UserTable on tb_ManagerRecord.UserID equals tb_user.UserID
                              select new B_ManagerRecordVo
            {
                RecordID       = tb_ManagerRecord.RecordID,
                UserName       = tb_user.UserName,
                BearFruit      = tb_ManagerRecord.BearFruit,
                Content        = tb_ManagerRecord.Content,
                ReleaseTimeStr = tb_ManagerRecord.LoginTime.ToString(),
                LoginIP        = tb_ManagerRecord.LoginIP
            };
            int totalRow = varB_Module.Count();
            List <B_ManagerRecordVo> notices = varB_Module.OrderByDescending(p => p.RecordID).
                                               Skip(bsgridPage.GetStartIndex()).
                                               Take(bsgridPage.pageSize).
                                               ToList();
            Bsgrid <B_ManagerRecordVo> bsgrid = new Bsgrid <B_ManagerRecordVo>();

            bsgrid.success   = true;
            bsgrid.totalRows = totalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = notices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
Ejemplo n.º 19
0
        /// <summary>
        /// 选择合同
        /// </summary>
        /// <param name="bsgridPage"></param>
        /// <returns></returns>
        public ActionResult SelectOrderFormPactID(BsgridPage bsgridPage)
        {
            var listOrderFormPact = from tbOrderFormPact in MyModels.B_OrderFormPactList
                                    join tbSupplierL in MyModels.B_SupplierList on tbOrderFormPact.SupplierID equals tbSupplierL.SupplierID
                                    join tbMethodOfSettlingAccounts in MyModels.S_MethodOfSettlingAccountsList on tbOrderFormPact.MethodOfSettlingAccountsID equals tbMethodOfSettlingAccounts.MethodOfSettlingAccountsID
                                    orderby tbOrderFormPact.OrderFormPactID
                                    select new Vo.OrderFormPact
            {
                OrderFormPactID            = tbOrderFormPact.OrderFormPactID,
                HostContractNumber         = tbOrderFormPact.HostContractNumber,
                SupplierID                 = tbSupplierL.SupplierID,
                SupplierName               = tbSupplierL.SupplierName,
                MethodOfSettlingAccountsID = tbMethodOfSettlingAccounts.MethodOfSettlingAccountsID,
                MethodOfSettlingAccounts   = tbMethodOfSettlingAccounts.MethodOfSettlingAccounts,
            };
            int intTotalRow = listOrderFormPact.Count();                                                                              //总行数
            List <OrderFormPact> listNotices = listOrderFormPact.Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList(); //分页

            Bsgrid <OrderFormPact> bsgrid = new Bsgrid <OrderFormPact>();

            bsgrid.success   = true;
            bsgrid.totalRows = intTotalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = listNotices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
        //查询角色
        public ActionResult SelectUserTypeAll(BsgridPage bsgridPage)
        {
            try
            {
                var linqItem = from tbUserType in myDYXTEntities.S_UserTypeTable
                               where tbUserType.UserTypeID != 1//1:超级管理员
                               select new S_UserTypeTableVo
                {
                    UserTypeID   = tbUserType.UserTypeID,
                    UserTypeName = tbUserType.UserTypeName,
                    Describe     = tbUserType.Describe,
                    FoundTime    = tbUserType.FoundTime,
                    ToVoidNo     = tbUserType.ToVoidNo           //作废否
                };
                int totalRow = linqItem.Count();
                List <S_UserTypeTableVo> UserTypeVos = linqItem.OrderByDescending(p => p.UserTypeID).
                                                       Skip(bsgridPage.GetStartIndex()).
                                                       Take(bsgridPage.pageSize).
                                                       ToList();

                Bsgrid <S_UserTypeTableVo> bsgrid = new Bsgrid <S_UserTypeTableVo>();
                bsgrid.success   = true;
                bsgrid.totalRows = totalRow;
                bsgrid.curPage   = bsgridPage.curPage;
                bsgrid.data      = UserTypeVos;
                return(Json(bsgrid, JsonRequestBehavior.AllowGet));
            }
            catch
            {
                return(Json("shibai", JsonRequestBehavior.AllowGet));
            }
        }
Ejemplo n.º 21
0
        /// <summary>
        /// 查询采购价变价
        /// </summary>
        /// <param name="bsgridPage"></param>
        /// <returns></returns>
        public ActionResult ChaXunCaiJiaBianJia(BsgridPage bsgridPage)
        {
            var listGoodsDetail = (from tbGoodsBianJia in MyModels.B_GoodsBianJiaList
                                   //join tbGoodsDetail in MyModels.B_GoodsDetailList on tbGoodsBianJia.GoodsDetailID equals tbGoodsDetail.GoodsDetailID
                                   join tbChangeWhy in MyModels.S_ChangeWhyList on tbGoodsBianJia.ChangeWhyID equals tbChangeWhy.ChangeWhyID
                                   where tbGoodsBianJia.BeginChangeData != null
                                   orderby tbGoodsBianJia.GoodsBianJiaID
                                   select new Vo.Goods
            {
                GoodsBianJiaID = tbGoodsBianJia.GoodsBianJiaID,
                BianJiaBianHao = tbGoodsBianJia.BianJiaBianHao,
                ReleaseTimeStrf = tbGoodsBianJia.BeginChangeData.ToString(),
                ChangeWhyID = tbChangeWhy.ChangeWhyID,
                ChangeWhy = tbChangeWhy.ChangeWhy,
                //GoodsDetailID = tbGoodsDetail.GoodsDetailID,
                //NewAdvanceBid = tbGoodsBianJia.NewAdvanceBid,
                //NewNoAdvanceBid = tbGoodsBianJia.NewNoAdvanceBid,
                Registrant = tbGoodsBianJia.Registrant,
                ReleaseTimeStr = tbGoodsBianJia.RegisterTime.ToString(),
                Auditor = tbGoodsBianJia.Auditor,
                ReleaseTimeStrr = tbGoodsBianJia.Checktime.ToString(),
                //Executor = tbGoodsBianJia.Executor,
                ReleaseTimeStrrr = tbGoodsBianJia.ExecuteTime.ToString(),
            });
            int          intTotalRow = listGoodsDetail.Count();//总行数
            List <Goods> listNotices = listGoodsDetail.Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList();

            Bsgrid <Goods> bsgrid = new Bsgrid <Goods>();

            bsgrid.success   = true;
            bsgrid.totalRows = intTotalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = listNotices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
        /// <summary>
        /// 已安装模块
        /// </summary>
        /// <param name="bsgridPage"></param>
        /// <returns></returns>
        public ActionResult selectsyste(BsgridPage bsgridPage)
        {
            var varB_Module = from tb_Module in myDYXTEntities.B_ModuleTable
                              join tbuser in myDYXTEntities.B_UserTable on tb_Module.UserID equals tbuser.UserID
                              join tbmodue in myDYXTEntities.S_ModuleStatusTable on tb_Module.ModuleStatusID equals tbmodue.ModuleStatusID
                              select new B_ModuleVo
            {
                ModuleID           = tb_Module.ModuleID,
                UserName           = tbuser.UserName,
                identificationName = tb_Module.identificationName,
                Byname             = tb_Module.Byname,
                Name           = tb_Module.Name,
                Edition        = tb_Module.Edition,
                ReleaseTimeStr = tb_Module.UpdateTime.ToString(),
                Describe       = tb_Module.Describe,
                ModuleStatus   = tbmodue.ModuleStatus
            };
            int totalRow = varB_Module.Count();
            List <B_ModuleVo> notices = varB_Module.OrderBy(p => p.ModuleID).
                                        Skip(bsgridPage.GetStartIndex()).
                                        Take(bsgridPage.pageSize).
                                        ToList();
            Bsgrid <B_ModuleVo> bsgrid = new Bsgrid <B_ModuleVo>();

            bsgrid.success   = true;
            bsgrid.totalRows = totalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = notices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
Ejemplo n.º 23
0
        public ActionResult selectTuiGuangJiLu(BsgridPage bsgridPage, int SpreadUserID)
        {
            var varuserjilu = (from tbSpreadUser in myDYXTEntities.B_SpreadUserTable
                               join tbuser in myDYXTEntities.B_UserTable on tbSpreadUser.UserID equals tbuser.UserID
                               join tbSpreadRen in myDYXTEntities.B_UserTable on tbSpreadUser.SpreadRenID equals tbSpreadRen.UserID
                               join tbSpreadType in myDYXTEntities.B_SpreadTypeTable on tbSpreadUser.SpreadTypeID equals tbSpreadType.SpreadTypeID
                               where tbSpreadUser.SpreadRenID == SpreadUserID
                               select new B_SpreadUserVo
            {
                SpreadUserID = tbSpreadUser.SpreadUserID,
                UserName = tbuser.UserName,
                SpreadRenName = tbSpreadRen.UserName,
                Name = tbSpreadType.Name,
                ReleaseTimeStr = tbSpreadUser.RelevanceTime.ToString()
            }).ToList();
            int totalRow = varuserjilu.Count();
            List <B_SpreadUserVo> notices = varuserjilu.OrderBy(p => p.SpreadTypeID).
                                            Skip(bsgridPage.GetStartIndex()).
                                            Take(bsgridPage.pageSize).
                                            ToList();
            Bsgrid <B_SpreadUserVo> bsgrid = new Bsgrid <B_SpreadUserVo>();

            bsgrid.success   = true;
            bsgrid.totalRows = totalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = notices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
Ejemplo n.º 24
0
        public ActionResult SelectHeTheCard(BsgridPage bsgridPage)//选择信息
        {
            var listGoods = (from tbTheCards in MyModels.S_TheCardsList
                             orderby tbTheCards.TheCardsID
                             select new TheCardVo
            {
                TheCardsID = tbTheCards.TheCardsID,
                Ccustodian = tbTheCards.Ccustodian,
                Kahao = tbTheCards.Kahao,
                TheCardsNumber = tbTheCards.TheCardsNumber,
                CardPeriodOfValidity = tbTheCards.CardPeriodOfValidity,
                CardPersonalizationNumber = tbTheCards.CardPersonalizationNumber,
                Recordnumber = tbTheCards.Recordnumber
            });
            int intTotalRow = listGoods.Count();                                                                          //总行数
            List <TheCardVo> listNotices = listGoods.Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList(); //分页

            Bsgrid <TheCardVo> bsgrid = new Bsgrid <TheCardVo>();

            bsgrid.success   = true;
            bsgrid.totalRows = intTotalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = listNotices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
Ejemplo n.º 25
0
        public ActionResult SelectSpreadRecord(BsgridPage bsgridPage)
        {
            var VarVip = from tbSpreadRecord in myDYXTEntities.B_SpreadRecordTable
                         join tbUser in myDYXTEntities.B_UserTable on tbSpreadRecord.SpreadUserID equals tbUser.UserID
                         join tbSpreadCustomUser in myDYXTEntities.B_UserTable on tbSpreadRecord.SpreadCustomID equals tbSpreadCustomUser.UserID
                         join tbSpreadType in myDYXTEntities.B_SpreadTypeTable on tbSpreadRecord.SpreadTypeID equals tbSpreadType.SpreadTypeID
                         select new B_SpreadRecordVo
            {
                SpreadRecordID   = tbSpreadRecord.SpreadRecordID,
                SpreadUserName   = tbUser.UserName.Trim(),
                SpreadCustomName = tbSpreadCustomUser.UserName.Trim(),
                SpreadTypeName   = tbSpreadType.Name.Trim(),
                FundType         = tbSpreadRecord.FundType.Trim(),
                Scale            = tbSpreadType.Scale.Trim(),
                SpreadAmount     = tbSpreadRecord.SpreadAmount,
                ReleaseTimeStr   = tbSpreadRecord.SubmitTime.ToString().Trim(),
                Remark           = tbSpreadRecord.Remark.Trim()
            };

            int totalRow = VarVip.Count();
            List <B_SpreadRecordVo> notices = VarVip.OrderByDescending(p => p.SpreadRecordID).
                                              Skip(bsgridPage.GetStartIndex()).
                                              Take(bsgridPage.pageSize).
                                              ToList();
            Bsgrid <B_SpreadRecordVo> bsgrid = new Bsgrid <B_SpreadRecordVo>();

            bsgrid.success   = true;
            bsgrid.totalRows = totalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = notices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
Ejemplo n.º 26
0
        /// <summary>
        /// 查询属性信息
        /// </summary>
        /// <param name="bsgridPage"></param>
        /// <param name="GasisId"></param>
        /// <returns></returns>
        public ActionResult SelectProperties(BsgridPage bsgridPage, int GasisId)
        {
            var listGasis = from tbBaseDetail in MyModels.B_BaseDetailList
                            select new Vo.BaseDetai
            {
                BaseTypeID     = tbBaseDetail.BaseTypeID,
                BaseDetailID   = tbBaseDetail.BaseDetailID,
                BaseDetailName = tbBaseDetail.BaseDetailName,
                CancelBit      = tbBaseDetail.CancelBit,
            };

            if (GasisId > 0)
            {
                listGasis = listGasis.Where(p => p.BaseTypeID == GasisId);
            }

            int intTotalRow             = listGasis.Count();
            List <BaseDetai> listGasiss = listGasis.OrderByDescending(p => p.BaseTypeID).Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList();

            Bsgrid <BaseDetai> Bsgrid = new Bsgrid <BaseDetai>();

            Bsgrid.success   = true;
            Bsgrid.totalRows = intTotalRow;
            Bsgrid.curPage   = bsgridPage.curPage;
            Bsgrid.data      = listGasiss;
            return(Json(Bsgrid, JsonRequestBehavior.AllowGet));
        }
Ejemplo n.º 27
0
        public ActionResult DaoRuPeiJian(BsgridPage bsgridPage, int ReceptionID)//查询领料导入配件信息
        {
            var lingItem = (from tbRecProductDetail in myModels.SYS_RecProductDetail
                            join tbMaintainability in myModels.SYS_Maintainability on tbRecProductDetail.MaintainabilityID equals tbMaintainability.MaintainabilityID
                            where tbRecProductDetail.ReceptionID == ReceptionID
                            select new ProductVo
            {
                ReceptionID = tbRecProductDetail.ReceptionID,
                RecProductDetailID = tbRecProductDetail.RecProductDetailID,
                MaintainabilityID = tbRecProductDetail.MaintainabilityID,
                MaintainabilityName = tbMaintainability.MaintainabilityName,
                FittingsCode = tbRecProductDetail.FittingsCode.Trim(),
                FittingsName = tbRecProductDetail.FittingsName.Trim(),
                SystemUnit = tbRecProductDetail.SystemUnit.Trim(),
                Quantity = tbRecProductDetail.Quantity,
                UnitPrice = tbRecProductDetail.UnitPrice,
                FittingsSpec = tbRecProductDetail.FittingsSpec.Trim() != null? tbRecProductDetail.FittingsSpec.Trim():"",
                Amount = tbRecProductDetail.Amount,
                Remark = tbRecProductDetail.Remark.Trim(),
                VehicleType = tbRecProductDetail.VehicleType.Trim()
            }).ToList();
            int count = lingItem.Count();
            List <ProductVo>   listReception = lingItem.OrderBy(m => m.PreProductDetailID).Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList();
            Bsgrid <ProductVo> bsgrid        = new Bsgrid <ProductVo>()
            {
                success   = true,
                totalRows = count,
                curPage   = bsgridPage.curPage,
                data      = listReception
            };

            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
Ejemplo n.º 28
0
        public ActionResult selectData1(BsgridPage bsgridPage, string supplierNumber)
        {
            var listOrderFormPact = (from tbSupplierId in MyModels.B_SupplierList
                                     orderby tbSupplierId.SupplierID
                                     select new SupplierListVo
            {
                SupplierID = tbSupplierId.SupplierID,
                SupplierNumber = tbSupplierId.SupplierNumber,
                SupplierName = tbSupplierId.SupplierName,
            });

            if (!string.IsNullOrEmpty(supplierNumber))
            {
                listOrderFormPact = listOrderFormPact.Where(s => s.SupplierNumber.Contains(supplierNumber.Trim()));
            }
            int intTotalRow = listOrderFormPact.Count();                                                                               //总行数
            List <SupplierListVo> listNotices = listOrderFormPact.Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList(); //分页

            Bsgrid <SupplierListVo> bsgrid = new Bsgrid <SupplierListVo>();

            bsgrid.success   = true;
            bsgrid.totalRows = intTotalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = listNotices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
Ejemplo n.º 29
0
        public ActionResult SelectCXSummary(BsgridPage bsgridPage)//选择信息
        {
            var listGoods = (from tbCXSummary in MyModels.S_CXSummaryList
                             orderby tbCXSummary.CXSummaryID
                             select new CXSummaryVo
            {
                CXSummaryID = tbCXSummary.CXSummaryID,
                JiLuBianHao = tbCXSummary.JiLuBianHao,
                YuanKaHao = tbCXSummary.YuanKaHao,
                HuiYuanXinMing = tbCXSummary.HuiYuanXinMing,
                UXsable = tbCXSummary.UXsable,
                Amount = tbCXSummary.Amount,
                ZhaiYao = tbCXSummary.ZhaiYao,
            });
            int intTotalRow = listGoods.Count();                                                                            //总行数
            List <CXSummaryVo> listNotices = listGoods.Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList(); //分页

            Bsgrid <CXSummaryVo> bsgrid = new Bsgrid <CXSummaryVo>();

            bsgrid.success   = true;
            bsgrid.totalRows = intTotalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = listNotices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }
Ejemplo n.º 30
0
        /// <summary>
        /// 选择经销、代销合同
        /// </summary>
        /// <param name="bsgridPage"></param>
        /// <returns></returns>
        public ActionResult SelectOrderFormPact(BsgridPage bsgridPage)
        {
            var listOrderFormPact = from tbOrderFormPact in MyModels.B_OrderFormPactList
                                    join tbMethodOfSettlingAccounts in MyModels.S_MethodOfSettlingAccountsList on tbOrderFormPact.MethodOfSettlingAccountsID equals tbMethodOfSettlingAccounts.MethodOfSettlingAccountsID
                                    join tbAdjustAccountsFashion in MyModels.S_AdjustAccountsFashionList on tbOrderFormPact.AdjustAccountsFashionID equals tbAdjustAccountsFashion.AdjustAccountsFashionID
                                    join tbSupplier in MyModels.B_SupplierList on tbOrderFormPact.SupplierID equals tbSupplier.SupplierID
                                    orderby tbOrderFormPact.OrderFormPactID
                                    where tbOrderFormPact.AgreementTypeID != 3 && tbOrderFormPact.AgreementTypeID != 4
                                    select new Vo.OrderFormPact
            {
                OrderFormPactID            = tbOrderFormPact.OrderFormPactID,
                ContractNumber             = tbOrderFormPact.ContractNumber.Trim(),
                MethodOfSettlingAccountsID = tbMethodOfSettlingAccounts.MethodOfSettlingAccountsID,
                MethodOfSettlingAccounts   = tbMethodOfSettlingAccounts.MethodOfSettlingAccounts.Trim(),
                AdjustAccountsFashionID    = tbAdjustAccountsFashion.AdjustAccountsFashionID,
                AdjustAccountsFashion      = tbAdjustAccountsFashion.AdjustAccountsFashion.Trim(),
                SupplierID      = tbSupplier.SupplierID,
                SupplierName    = tbSupplier.SupplierName.Trim(),
                PurchasingAgent = tbOrderFormPact.PurchasingAgent.Trim(),
                ReleaseTimeStr  = tbOrderFormPact.ValidTip.ToString(),
                ReleaseTimeStrr = tbOrderFormPact.ValidBegin.ToString(),
            };
            int intTotalRow = listOrderFormPact.Count();                                                                              //总行数
            List <OrderFormPact> listNotices = listOrderFormPact.Skip(bsgridPage.GetStartIndex()).Take(bsgridPage.pageSize).ToList(); //分页

            Bsgrid <OrderFormPact> bsgrid = new Bsgrid <OrderFormPact>();

            bsgrid.success   = true;
            bsgrid.totalRows = intTotalRow;
            bsgrid.curPage   = bsgridPage.curPage;
            bsgrid.data      = listNotices;
            return(Json(bsgrid, JsonRequestBehavior.AllowGet));
        }