Clean up SettingsController to not check for Null's as empty strings will not be null when returned.

class variables for _settingsSaved, _settingsFailed to easily change all error messages when saving
This commit is contained in:
markus101 2011-02-14 17:20:17 -08:00
parent b2524cf697
commit ff44d05a72
6 changed files with 69 additions and 318 deletions

View file

@ -11,8 +11,8 @@ namespace NzbDrone.Web.Models
public class SettingsModel
{
#region General Settings
[DataType(DataType.Text)]
[Required(ErrorMessage = "Please enter a valid TV path")]
[DisplayName("TV Folder")]
public String TvFolder
{
@ -27,159 +27,5 @@ namespace NzbDrone.Web.Models
get;
set;
}
#endregion
//#region Indexer Settings
//[DataType(DataType.Text)]
//[DisplayName("NZBMatrix Username")]
//public String NzbMatrixUsername
//{
// get;
// set;
//}
//[DataType(DataType.Text)]
//[DisplayName("NZBMatrix API Key")]
//public String NzbMatrixApiKey
//{
// get;
// set;
//}
//[DataType(DataType.Text)]
//[DisplayName("NZBs.Org UID")]
//public String NzbsOrgUId
//{
// get;
// set;
//}
//[DataType(DataType.Text)]
//[DisplayName("NZBs.Org Hash")]
//public String NzbsOrgHash
//{
// get;
// set;
//}
//[DataType(DataType.Text)]
//[DisplayName("NZBsRus UID")]
//public String NzbsrusUId
//{
// get;
// set;
//}
//[DataType(DataType.Text)]
//[DisplayName("NZBsRus Hash")]
//public String NzbsrusHash
//{
// get;
// set;
//}
//public List<Indexer> Indexers
//{
// get;
// set;
//}
//#endregion
//#region Download Settings
////Sync Frequency
////Download Propers?
////Retention
////SAB Host/IP
////SAB Port
////SAB APIKey
////SAB Username
////SAB Password
////SAB Category
////SAB Priority
//[DataType(DataType.Text)]
//[DisplayName("Sync Frequency")]
//public int SyncFrequency
//{
// get;
// set;
//}
//[DisplayName("Download Propers")]
//public bool DownloadPropers
//{
// get;
// set;
//}
//[DataType(DataType.Text)]
//[DisplayName("Retention")]
//public int Retention
//{
// get;
// set;
//}
//[DataType(DataType.Text)]
//[DisplayName("SABnzbd Host")]
//public String SabHost
//{
// get;
// set;
//}
//[DataType(DataType.Text)]
//[DisplayName("SABnzbd Port")]
//public int SabPort
//{
// get;
// set;
//}
//[DataType(DataType.Text)]
//[DisplayName("SABnzbd API Key")]
//public String SabApiKey
//{
// get;
// set;
//}
//[DataType(DataType.Text)]
//[DisplayName("SABnzbd Username")]
//public String SabUsername
//{
// get;
// set;
//}
//[DataType(DataType.Text)]
//[DisplayName("SABnzbd Password")]
//public String SabPassword
//{
// get;
// set;
//}
//[DataType(DataType.Text)]
//[DisplayName("SABnzbd Category")]
//public String SabCategory
//{
// get;
// set;
//}
//[DataType(DataType.Text)]
//[DisplayName("SABnzbd Priority")]
//public SabnzbdPriorityType SabPriority
//{
// get;
// set;
//}
//#endregion
}
}