| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546 |
- using System;
- using System.Collections;
- using System.Collections.Generic;
- using System.ComponentModel;
- using System.Data;
- using System.Drawing;
- using System.Linq;
- using System.Text;
- using System.Windows.Forms;
- using CoreFS.CA06;
- using Pur.Entity;
- namespace Pur.Entity
- {
- public partial class FrmPmsBase : FrmBase
- {
- public FrmPmsBase()
- {
- InitializeComponent();
- }
- private void FrmPmsBase_Load(object sender, EventArgs e)
- {
- }
- public T execute<T>(string className, string methodName, object[] param)
- {
- T t = GetJsonService().execute<T>(className, methodName, param);
- if (typeof(T).FullName == "System.Data.DataTable" && t == null)
- {
- DataTable dt = new DataTable();
- return (T)Convert.ChangeType(dt, typeof(T));
- }
- if (typeof(T).FullName.IndexOf( "System.Collections.Generic.List")>-1 && t == null)
- {
- T t1 = System.Activator.CreateInstance<T>();
- return t1;
- }
- return t;
- }
- public void execute(string className, string methodName, object[] param)
- {
- GetJsonService().execute(className, methodName, param);
- }
- }
- }
|