| | |
| | | return String.Format("{0:0.##}{1}", dblSByte, Suffix[i]); |
| | | } |
| | | |
| | | public static string GetUploadFolder() |
| | | { |
| | | return GetFolder("uploadFolder"); |
| | | } |
| | | |
| | | public static string GetStyleFolder() |
| | | { |
| | | return GetFolder("styleFolder"); |
| | | } |
| | | |
| | | public static string GetDownloadFolder() |
| | | { |
| | | return GetFolder("downloadFolder"); |
| | | } |
| | | |
| | | public static string GetSGFolder() |
| | | { |
| | | return GetFolder("SGFolder"); |
| | | } |
| | | |
| | | public static string GetPublishFolder() |
| | | { |
| | | return GetFolder("publishFolder"); |
| | | } |
| | | |
| | | public static string GetFolder(string key) |
| | | { |
| | | string folder = ConfigurationManager.AppSettings[key]; |
| | | |
| | | string path = folder.IndexOf(":\\") > -1 ? folder : Path.Combine(BaseDir, folder); |
| | | if (!Directory.Exists(path)) |
| | | { |
| | | Directory.CreateDirectory(path); |
| | | } |
| | | |
| | | return path; |
| | | } |
| | | |
| | | public static string GetSetting(string key) |
| | | { |
| | | return ConfigurationManager.AppSettings[key]; |
| | |
| | | return list; |
| | | } |
| | | |
| | | #region * 暂时不用 * |
| | | public static void CreateDirectory(string dir) |
| | | { |
| | | WindowsIdentity wi = WindowsIdentity.GetCurrent(); |
| | |
| | | return (T)formatter.Deserialize(stream); |
| | | } |
| | | } |
| | | #endregion |
| | | } |
| | | } |