自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(7)
  • 收藏
  • 关注

转载 bootstrap fileinput+MVC 上传多文件,保存

新增用户资料,需要用户上传多笔附件,所以就尝试用了fileinput控件,显示效果如图:首先,先在model中定义数据模型:public partial class create{ [Required] [Display(Name = "附件")] public HttpPostedFileBase[] attach {...

2017-12-04 13:52:00 427

转载 SQL 表定时同步

1.创建存储过程 create proc [dbo].[sync_calendar]astruncate table dbo.CalendarEventsinsert into CalendarEvents (title,startdate,enddate,type,year,createdate,updatedate ) select title,sta...

2017-10-11 15:30:00 242

转载 MVC 下拉框获取值和赋值(多选)

1.视图<div class="form-group"> @Html.LabelFor(m => m.Positions, new { @class = "col-sm-2 control-label" }) <div class="col-sm-10"> @Html.ListBoxFor(m...

2017-06-27 15:41:00 1124

转载 MVC 下拉框联动效果(单选)

下拉框联动效果,我们以部门--职位为例,选择部门时,关联到该部门的职位.下拉框的写法就不多说了,详细请参照前文.视图:其中,dept是部门的属性,deptlist是部门下拉框的属性,job是职位的属性,joblist是职位下拉框的属性,下拉框绑定请参照前文@using (Html.BeginForm("aaai003sch", "aaa", FormMethod.Post...

2017-06-27 14:35:00 201

转载 MVC5 下拉框(多选)

1.Model[Display(Name = "职位")] [Required] public int[] job { get; set; } //职位属性 public IEnumerable<Item> joblist { get; set; } //多选框属性2.cotroller[Description("职位绑定")]...

2017-06-27 13:52:00 245

转载 MVC5 下拉框绑定(单选)

1.Model[Display(Name = "学历")] public ICollection<System.Web.Mvc.SelectListItem> asdflist{ get; set; } //下拉框的类型[Display(Name = "学历")][Required]public int asdf { get; set; } ...

2017-06-27 11:40:00 133

转载 MVC5 model常见的写法

1.数据库表中为ID的字段 [Key] //关键字 [Required] //不为空 [Display(Name = "ID")] public int id { get; set; }2.日期型字段[Display(Name = "出发日期")][Required][DisplayForma...

2017-06-27 11:00:00 249

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除