4c83bfe0b2
SVN-Revision: r476
76 lines
2.0 KiB
C#
76 lines
2.0 KiB
C#
using Lskj.Business;
|
|
using Lskj.Model;
|
|
using Lskj.Util;
|
|
using Newtonsoft.Json;
|
|
using Newtonsoft.Json.Linq;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.Data;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Windows.Forms;
|
|
|
|
namespace Lskj.PubArgoxPrint
|
|
{
|
|
/// <summary>
|
|
/// c#库被调用统一接口类
|
|
/// </summary>
|
|
public sealed class DllBaseClass : IForm
|
|
{
|
|
public DllBaseClass()
|
|
{
|
|
|
|
}
|
|
|
|
public DllBaseClass(string[] obj)
|
|
{
|
|
try
|
|
{
|
|
DynamicArgoxPrintModel dynamicArgoxPrintModel = new DynamicArgoxPrintModel(obj);
|
|
FrmMain main = new FrmMain();
|
|
main.Model = dynamicArgoxPrintModel;
|
|
this.SubForm = main;
|
|
}
|
|
catch (Exception ex)
|
|
{
|
|
LogUtil.WriteError("Lskj.PubArgoxPrint.dll--参数错误-->" + obj.ToString(), ex);
|
|
}
|
|
|
|
}
|
|
/// <summary>
|
|
/// 窗口
|
|
/// </summary>
|
|
public Form SubForm { get; set; }
|
|
}
|
|
/// <summary>
|
|
/// 入口模型
|
|
/// </summary>
|
|
public class DynamicArgoxPrintModel : DynamicModel
|
|
{
|
|
/// <summary>
|
|
/// 列起始X坐标
|
|
/// </summary>
|
|
public string LocationX = "";
|
|
/// <summary>
|
|
/// 打印列参数
|
|
/// </summary>
|
|
public string PrintArgs = "";
|
|
/// <summary>
|
|
/// 打印数据sql
|
|
/// </summary>
|
|
public string MainPrintSql = "";
|
|
/// <summary>
|
|
/// 执行后的语句
|
|
/// </summary>
|
|
public string AfterSql = "";
|
|
/// <summary>
|
|
/// 初始化默认参数(1.标题、2、用户ID、3.用户名、4.权限、5.模块编号、6.菜单ID)
|
|
/// </summary>
|
|
/// <param name="args">The arguments.</param>
|
|
public DynamicArgoxPrintModel(string[] args) : base(args)
|
|
{
|
|
if (args.Length > 5 && !string.IsNullOrWhiteSpace(args[5]))
|
|
{
|
|
LocationX = args[5];
|
|
}
|
|
if (args.Length > 6 & |