Example #1
0
 /// <summary>
 /// 用于向 Posts EntitySet 添加新对象的方法,已弃用。请考虑改用关联的 ObjectSet&lt;T&gt; 属性的 .Add 方法。
 /// </summary>
 public void AddToPosts(Post post)
 {
     base.AddObject("Posts", post);
 }
Example #2
0
 /// <summary>
 /// 创建新的 Post 对象。
 /// </summary>
 /// <param name="id">ID 属性的初始值。</param>
 /// <param name="postName">PostName 属性的初始值。</param>
 /// <param name="departmentID">DepartmentID 属性的初始值。</param>
 /// <param name="isValid">IsValid 属性的初始值。</param>
 /// <param name="jobname">Jobname 属性的初始值。</param>
 /// <param name="positionID">PositionID 属性的初始值。</param>
 /// <param name="organizationID">OrganizationID 属性的初始值。</param>
 public static Post CreatePost(global::System.Int32 id, global::System.String postName, global::System.Int32 departmentID, global::System.Boolean isValid, global::System.String jobname, global::System.Int32 positionID, global::System.Int32 organizationID)
 {
     Post post = new Post();
     post.ID = id;
     post.PostName = postName;
     post.DepartmentID = departmentID;
     post.IsValid = isValid;
     post.Jobname = jobname;
     post.PositionID = positionID;
     post.OrganizationID = organizationID;
     return post;
 }