/// <summary> /// insert or update channel /// </summary> public void Save() { string n = this.ChannelName; string r = this.ChannelRemark; if (IsAdd()) { ChannelDBI.AddChannel(n, r, GetStationIDs()); } else { // edit // ChannelDBI.EditChannel(this.ChannelID, n, r, GetStationIDs()); } // save station color // foreach (StationClass station in StationCollection) { if (station.Color != System.Drawing.Color.White) { StationDBI.UpdateColor(station.StationID, station.Color); } } }
/// <summary> /// insert or update channel /// </summary> public void Save() { string n = this.ChannelName; string r = this.ChannelRemark; if (IsAdd()) { ChannelDBI.AddChannel(n, r, GetStationIDs()); } else { // edit // ChannelDBI.EditChannel(this.ChannelID, n, r, GetStationIDs()); } }