68 lines
2.1 KiB
C#
68 lines
2.1 KiB
C#
using QRWL.Common;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Web;
|
|
|
|
namespace SuperMap.RealEstate.HighWay.Handler
|
|
{
|
|
/// <summary>
|
|
/// ExpenseBill_1000 的摘要说明
|
|
/// </summary>
|
|
public class ExpenseBill_1000 : IHttpHandler
|
|
{
|
|
|
|
public void ProcessRequest(HttpContext context)
|
|
{
|
|
string action_type = HttpContext.Current.Request.Form["action_type"];
|
|
string reString = string.Empty;
|
|
switch (action_type)
|
|
{
|
|
case "DataColumn":
|
|
using (Running.Business.EXPENSEDETAIL _EXPENSEDETAIL = new Running.Business.EXPENSEDETAIL())
|
|
{
|
|
|
|
reString = JsonHelper.DataTableToJson((new Running.Business.EXPENSEDETAIL()).FillDataTable(
|
|
"where EXPENSEBILL_ID = " + 19), "Rows");
|
|
}
|
|
break;
|
|
case "DelAction":
|
|
string action_Data = HttpContext.Current.Request.Form["action_data"];
|
|
if (action_Data == null || action_Data == "")
|
|
{
|
|
reString = "无删除数据";
|
|
}
|
|
else
|
|
{
|
|
try
|
|
{
|
|
string[] ArrayID = action_Data.Split(',');
|
|
foreach (string id in ArrayID)
|
|
{
|
|
(new Running.Business.EXPENSEDETAIL()).Delete(int.Parse(id));
|
|
}
|
|
reString = "删除成功!";
|
|
}
|
|
catch (Exception ex)
|
|
{
|
|
reString = "删除失败:可能原因是:" + ex.Message;
|
|
}
|
|
}
|
|
break;
|
|
}
|
|
context.Response.ContentType = "text/plain";
|
|
context.Response.Write(reString);
|
|
|
|
|
|
|
|
}
|
|
|
|
public bool IsReusable
|
|
{
|
|
get
|
|
{
|
|
return false;
|
|
}
|
|
}
|
|
}
|
|
} |