コード例 #1
0
 public void ExecuteTags(ref string PageStr, normal_channel _Channel)
 {
     PageStr = PageStr.Replace("{$ChannelId}", _Channel.Id.ToString());
     PageStr = PageStr.Replace("{$ChannelName}", _Channel.Title);
     PageStr = PageStr.Replace("{$ChannelInfo}", _Channel.Info);
     PageStr = PageStr.Replace("{$ChannelType}", _Channel.Type);
     PageStr = PageStr.Replace("{$ChannelDir}", _Channel.Dir);
     PageStr = PageStr.Replace("{$ChannelItemName}", _Channel.ItemName);
     PageStr = PageStr.Replace("{$ChannelItemUnit}", _Channel.ItemUnit);
     PageStr = PageStr.Replace("{$ChannelLink}", "/Enterprise/web/" + _Channel.Type + "classList?ccid=" + _Channel.Id + "&sessionid={$Sessionid}");
 }
コード例 #2
0
 partial void Deletenormal_channel(normal_channel instance);
コード例 #3
0
 partial void Updatenormal_channel(normal_channel instance);
コード例 #4
0
 partial void Insertnormal_channel(normal_channel instance);
コード例 #5
0
		private void detach_normal_channel(normal_channel entity)
		{
			this.SendPropertyChanging();
			entity.employeeInfo = null;
		}
コード例 #6
0
 /// <summary>
 /// 修改频道信息
 /// </summary>
 /// <param name="channel"></param>
 /// <returns>受影响的行数</returns>
 public int UpdateChannel(normal_channel channel)
 {
     string sql = string.Format(@"update normal_channel set title='{0}',info='{1}',Itemname='{2}',itemunit='{3}',[Enabled]={4} where  id={5}", channel.Title, channel.Info, channel.ItemName, channel.ItemUnit, channel.Enabled, channel.Id);
     return SqlHelper.ExecuteNonQuery(System.Data.CommandType.Text, sql) ;
 }
コード例 #7
0
 /// <summary>
 /// 添加频道
 /// </summary>
 /// <param name="Channel"></param>
 /// <returns>返回添加后的ID</returns>
 public int InsertChannel(normal_channel Channel)
 {
     db.normal_channel.InsertOnSubmit(Channel);
     db.SubmitChanges();
     return Channel.Id;
 }