using System; using System.Collections.Generic; using System.Linq; using System.Text; using COMCMS.Common; namespace COMCMS.Core.Models { /// /// 附件配置 /// public class AttachConfigEntity { public AttachConfigEntity() { } #region Model private string _attachpatch = "userfiles"; private int _savetype = 0; private int _iscreatethum = 0; private int _thumqty = 80; private int _thummaxwidth = 200; private int _thummaxheight = 200; private int _iswatermark = 0; private int _watermarktype = 0; private int _watermarkminwidth = 400; private int _watermarkminheight = 400; private string _watermarkimg = ""; private string _watermarktext = string.Empty; private string _watermarktextcolor = "#0FF"; private int _watermarkplace = 9; private int _watermarkqty = 80; private int _watermarkdiaphaneity = 80; private int _siteid = 0; /// /// 网站ID /// public int SiteId { get { return _siteid; } set { _siteid = value; } } /// /// 附件目录,图片自动在这个目录后面加上images/、文件files/、flash:flash/、多媒体:media/ /// public string AttachPatch { set { _attachpatch = value; } get { return _attachpatch; } } /// /// 存放类型,0统一目录,1按月份(推荐),2按天 /// public int SaveType { set { _savetype = value; } get { return _savetype; } } /// /// 是否生成缩略图,0不生成,1生成不超过指定大小的缩略图,2生成固定大小的缩略图 缩略图存放在附件目录/_thumbs目录 /// public int IsCreateThum { set { _iscreatethum = value; } get { return _iscreatethum; } } /// /// 缩略图质量 100最高 /// public int ThumQty { set { _thumqty = value; } get { return _thumqty; } } /// /// 缩略图最大宽度 /// public int ThumMaxWidth { set { _thummaxwidth = value; } get { return _thummaxwidth; } } /// /// 缩略图最大高度 /// public int ThumMaxHeight { set { _thummaxheight = value; } get { return _thummaxheight; } } /// /// 是否开启图片加水印 /// public int IsWaterMark { set { _iswatermark = value; } get { return _iswatermark; } } /// /// 水印类型,0文字,1 GIF,2 JPG ,3 PNG /// public int WaterMarkType { set { _watermarktype = value; } get { return _watermarktype; } } /// /// 打水印最小宽度 /// public int WaterMarkMinWidth { set { _watermarkminwidth = value; } get { return _watermarkminwidth; } } /// /// 打水印最小高度 /// public int WaterMarkMinHeight { set { _watermarkminheight = value; } get { return _watermarkminheight; } } /// /// 水印图片 /// public string WaterMarkImg { set { _watermarkimg = value; } get { return _watermarkimg; } } /// /// 文字水印文字 /// public string WaterMarkText { set { _watermarktext = value; } get { return _watermarktext; } } /// /// 水印文字颜色 /// public string WaterMarkTextColor { set { _watermarktextcolor = value; } get { return _watermarktextcolor; } } /// /// 水印位置:0~9 /// public int WaterMarkPlace { set { _watermarkplace = value; } get { return _watermarkplace; } } /// /// 水印后图片质量 0-100 /// public int WaterMarkQty { set { _watermarkqty = value; } get { return _watermarkqty; } } /// /// 水印图片透明度 0-100 /// public int WaterMarkDiaphaneity { set { _watermarkdiaphaneity = value; } get { return _watermarkdiaphaneity; } } /// /// 是否随机命名上传文件名 /// public int IsRandomFileName { get; set; } = 0; /// /// 图片最大宽度 /// public int ImgMaxWidth { get; set; } = 1920; /// /// 图片最大高度 /// public int ImgMaxHeight { get; set; } = 2000; #endregion Model } }