FarmTrace/ashx/OrderSlaughterDetail.ashx.cs
(开头部分) 5KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using DataBaseLibrary.Utility;
using Model;
using Repository.impl;
using Repository.interfaces;
using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Web;
using System.Text;
using DataBaseLibrary.DBUtility;
namespace FarmTrace.ashx
{
/// <summary>
/// BaseExpress 的摘要说明
/// </summary>
public class OrderSlaughterDetail : IHttpHandler
{
#region 自定义变量
ICommonRepository CommBll = new CommonRepository();
OrderSlaughterDetailModel model = new OrderSlaughterDetailModel();
ConvertJson ConJson = new ConvertJson();
#endregion
#region 自定义方法
private void Add()
{
int OrderID = Common.GetQueryInt("OrderID");
string strSheepIDs = Common.GetQueryString("strSheepIDs");
if (OrderID > 0 && strSheepIDs != "")
{
StringBuilder strSQL = new StringBuilder();
strSQL.Append(" insert into OrderSlaughterDetail(SheepID , SlaughterID , CarcassWeight)");
strSQL.Append(string.Format(" select SheepID , {0} , 0 from BaseSheep", OrderID.ToString()));
strSQL.Append(string.Format(" where SheepID in ({0})", strSheepIDs));
strSQL.Append(" and SheepID not in");
strSQL.Append(string.Format(" (select SheepID from OrderSlaughterDetail where SlaughterID = {0} and SheepID in ({1}))", OrderID.ToString(), strSheepIDs));
DbHelperSQL.ExecuteSql(strSQL.ToString());
}
}
#region 获取信息
/// <summary>
/// 获取信息
/// </summary>
/// <returns></returns>
private string GetOrderSlaughterDetail()
{
string result = string.Empty;
int SlaughterID = Common.GetQueryInt("SlaughterID");
ViewOrderSlaughterDetailModel modelView = new ViewOrderSlaughterDetailModel();
DataTable dt = CommBll.GetList<ViewOrderSlaughterDetailModel>(modelView, "SlaughterID = " + SlaughterID.ToString());
if (dt != null)
{
result = ConJson.GetDataTableToDataGridJson(dt, dt.Rows.Count);
后面还有 83 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明
AI 解读
登录后可用,每次 10 积分,解读结果公开显示在下面。
还没有人解读过这个文件。
