| | |
| | | using System.Linq; |
| | | using System.Web; |
| | | |
| | | namespace LFServer.Models |
| | | namespace ExportMap.Models |
| | | { |
| | | /// <summary> |
| | | /// 出图参数 |
| | |
| | | public class ExportArgs |
| | | { |
| | | public ExportArgs() { } |
| | | |
| | | public String token { set; get; } |
| | | |
| | | /// <summary> |
| | | /// 标题 |
| | |
| | | /// <summary> |
| | | /// 纸张大小 |
| | | /// </summary> |
| | | public string pageSize { set; get; } |
| | | public String pageSize { set; get; } |
| | | |
| | | /// <summary> |
| | | /// 省份 |
| | |
| | | /// </summary> |
| | | public int dpi { set; get; } |
| | | |
| | | /// <summary> |
| | | /// 模板文件 |
| | | /// </summary> |
| | | public String qpt { set; get; } |
| | | |
| | | /// <summary> |
| | | /// 设置默认值 |
| | | /// </summary> |
| | | public void SetDefault() |
| | | { |
| | | if (string.IsNullOrWhiteSpace(title)) title = "管道基础大数据平台"; |
| | |
| | | if (string.IsNullOrWhiteSpace(date)) date = DateTime.Now.ToString("yyyy.MM.dd"); |
| | | |
| | | this.dpi = GetDpi(this.pageSize); |
| | | imgPath = ""; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 获取DPI |
| | | /// </summary> |
| | | /// <param name="page">页面大小</param> |
| | | /// <returns>DPI</returns> |
| | | public int GetDpi(string page) |
| | | { |
| | | if (string.IsNullOrWhiteSpace(page)) return 300; |