public static List <SelectVo> SetSelectJson(List <SelectVo> seletce) { List <SelectVo> list = new List <SelectVo>(); SelectVo selectVo = new SelectVo { id = 0, text = "---请选择---" }; list.Add(selectVo); list.AddRange(seletce); return(list); }
/// <summary> /// 商标级别 /// </summary> /// <returns></returns> public ActionResult SelectTrademarkRankID() { List <SelectVo> listTrademarkRank = new List <SelectVo>(); SelectVo selectVo = new SelectVo { id = 0, text = "---请选择---" }; listTrademarkRank.Add(selectVo); List <SelectVo> listTrademarkRankID = (from tbTrademarkRank in MyModels.S_TrademarkRankList select new SelectVo { id = tbTrademarkRank.TrademarkRankID, text = tbTrademarkRank.TrademarkRankName.Trim() }).ToList(); listTrademarkRank.AddRange(listTrademarkRankID); return(Json(listTrademarkRank, JsonRequestBehavior.AllowGet)); }
/// <summary> /// 查询公告类型 to 下拉框 /// </summary> /// <returns></returns> public ActionResult SelctNoticeType() { List <SelectVo> listnoticeType = new List <SelectVo>(); SelectVo listnoticetype = new SelectVo { id = 0, text = "全部" }; listnoticeType.Add(listnoticetype); List <SelectVo> noticeType = (from tbnotice in myDYXTEntities.B_NoticeTypeTable select new SelectVo { id = tbnotice.NoticeTypeID, text = tbnotice.NoticeTypeName }).ToList(); listnoticeType.AddRange(noticeType); return(Json(listnoticeType, JsonRequestBehavior.AllowGet)); }
/// <summary> /// 变价原因 /// </summary> /// <returns></returns> public ActionResult SelectChangeWhyID2() { List <SelectVo> listOrderFormType = new List <SelectVo>(); SelectVo selectVo = new SelectVo { id = 0, text = "---必选择----" }; listOrderFormType.Add(selectVo); List <SelectVo> listChangeWhyID = (from tbChangeWhy in MyModels.S_ChangeWhyList select new SelectVo { id = tbChangeWhy.ChangeWhyID, text = tbChangeWhy.ChangeWhy.Trim(), }).ToList(); listOrderFormType.AddRange(listChangeWhyID); return(Json(listOrderFormType, JsonRequestBehavior.AllowGet)); }
/// <summary> /// 选择进货部门 /// </summary> /// <returns></returns> public ActionResult SelectSpouseBRanch() { List <SelectVo> listStatusID = new List <SelectVo>(); SelectVo selectVo = new SelectVo { id = 0, text = "---请选择----" }; listStatusID.Add(selectVo); List <SelectVo> listStatusIDD = (from tbStatusID in MyModels.S_SpouseBRanchList select new SelectVo { id = tbStatusID.SpouseBRanchID, text = tbStatusID.SpouseBRanchName }).ToList(); listStatusID.AddRange(listStatusIDD); return(Json(listStatusID, JsonRequestBehavior.AllowGet)); }
/// <summary> /// 科室类型 /// </summary> /// <returns></returns> public ActionResult SelectDepartmenttypeID() { List <SelectVo> listUserrole = new List <SelectVo>(); SelectVo selectVo = new SelectVo { id = 0, text = "---请选择科室----" }; listUserrole.Add(selectVo); List <SelectVo> listPriceTypeID = (from tbUserrole in MyModels.S_DepartmenttypeList select new SelectVo { id = tbUserrole.DepartmenttypeID, text = tbUserrole.Departmenttype.Trim() }).ToList(); listUserrole.AddRange(listPriceTypeID); return(Json(listUserrole, JsonRequestBehavior.AllowGet)); }
/// <summary> /// 商标品牌 /// </summary> /// <returns></returns> public ActionResult ChaXunShangBiaoPinPai() { List <SelectVo> listPriceType = new List <SelectVo>(); SelectVo selectVo = new SelectVo { id = 0, text = "---请选择----" }; listPriceType.Add(selectVo); List <SelectVo> listPriceTypeID = (from tbGoodsBarCod in MyModels.B_GoodsChopList select new SelectVo { id = tbGoodsBarCod.GoodsChopID, text = tbGoodsBarCod.GoodsChopName.Trim() }).ToList(); listPriceType.AddRange(listPriceTypeID); return(Json(listPriceType, JsonRequestBehavior.AllowGet)); }
/// <summary> /// 商品定价状态 /// </summary> /// <returns></returns> public ActionResult SelectGoodsPurchasemoneyStatusID() { List <SelectVo> listPriceType = new List <SelectVo>(); SelectVo selectVo = new SelectVo { id = 0, text = "---请选择----" }; listPriceType.Add(selectVo); List <SelectVo> listPriceTypeID = (from tbGoodsBarCod in MyModels.S_GoodsPurchasemoneyStatusList select new SelectVo { id = tbGoodsBarCod.GoodsPurchasemoneyStatusID, text = tbGoodsBarCod.GoodsPurchasemoneyStatus.Trim() }).ToList(); listPriceType.AddRange(listPriceTypeID); return(Json(listPriceType, JsonRequestBehavior.AllowGet)); }
/// <summary> /// 订单类型 /// </summary> /// <returns></returns> public ActionResult SelectOrderFormTypeID() { List <SelectVo> listOrderFormType = new List <SelectVo>(); SelectVo selectVo = new SelectVo { id = 0, text = "---必填----" }; listOrderFormType.Add(selectVo); List <SelectVo> listOrderFormTypeID = (from tbOrderFormType in MyModels.S_OrderFormTypeList select new SelectVo { id = tbOrderFormType.OrderFormTypeID, text = tbOrderFormType.OrderFormTypeName.Trim(), }).ToList(); listOrderFormType.AddRange(listOrderFormTypeID); return(Json(listOrderFormType, JsonRequestBehavior.AllowGet)); }
/// <summary> /// 计量单位 /// </summary> /// <returns></returns> public ActionResult SelectEstimateUnitName() { List <SelectVo> listEstimateUnit = new List <SelectVo>(); SelectVo selectVo = new SelectVo { id = 0, text = "---请选择----" }; listEstimateUnit.Add(selectVo); List <SelectVo> listEstimateUnitID = (from tbEstimateUnit in MyModels.S_EstimateUnitList select new SelectVo { id = tbEstimateUnit.EstimateUnitID, text = tbEstimateUnit.EstimateUnitName.Trim() }).ToList(); listEstimateUnit.AddRange(listEstimateUnitID); return(Json(listEstimateUnit, JsonRequestBehavior.AllowGet)); }
/// <summary> /// 前后台 /// </summary> /// <returns></returns> public ActionResult SelectFrontandbackID() { List <SelectVo> listUserrole = new List <SelectVo>(); SelectVo selectVo = new SelectVo { id = 0, text = "---请选择前或后台----" }; listUserrole.Add(selectVo); List <SelectVo> listPriceTypeID = (from tbUserrole in MyModels.B_BaseDetailList where tbUserrole.BaseDetailID == 1 || tbUserrole.BaseDetailID == 2 select new SelectVo { id = tbUserrole.BaseDetailID, text = tbUserrole.BaseDetailName.Trim() }).ToList(); listUserrole.AddRange(listPriceTypeID); return(Json(listUserrole, JsonRequestBehavior.AllowGet)); }
/// <summary> /// 进货部门 /// </summary> /// <returns></returns> public ActionResult SelectSpouseBRanchIDD() { List <SelectVo> listOrderFormType = new List <SelectVo>(); SelectVo selectVo = new SelectVo { id = 0, text = "---必填----" }; listOrderFormType.Add(selectVo); List <SelectVo> listSpouseBRanchID = (from tbOrderFormType in MyModels.S_SpouseBRanchList where tbOrderFormType.SpouseBRanchID == 1 || tbOrderFormType.SpouseBRanchID == 2 select new SelectVo { id = tbOrderFormType.SpouseBRanchID, text = tbOrderFormType.SpouseBRanchName.Trim(), }).ToList(); listOrderFormType.AddRange(listSpouseBRanchID); return(Json(listOrderFormType, JsonRequestBehavior.AllowGet)); }