You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
|
|
using CommonFunc.Tools;
|
|
|
|
|
|
using System;
|
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
|
using System.Data;
|
|
|
|
|
|
using System.Linq;
|
|
|
|
|
|
using System.Text;
|
|
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
|
|
|
|
|
|
|
|
namespace XGL.Data.DBService
|
|
|
|
|
|
{
|
|
|
|
|
|
public class DringRoomService
|
|
|
|
|
|
{
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// 获取烘房列表
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
/// <param name="bdt"></param>
|
|
|
|
|
|
/// <param name="edt"></param>
|
|
|
|
|
|
/// <returns></returns>
|
|
|
|
|
|
public DataTable GetDringRoomInfo()
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
|
|
string sql = $@"select equipment_code as quipCode,equipment_name as quipName,equipment_type_code from base_equipment where equipment_type_code = 'equ_type_hf'";
|
|
|
|
|
|
|
|
|
|
|
|
DataSet dtset = Utils.netClientDBHelper.getDataSet(sql);
|
|
|
|
|
|
if (dtset != null && dtset.Tables.Count > 0 && dtset.Tables[0].Rows.Count > 0)
|
|
|
|
|
|
{
|
|
|
|
|
|
return dtset.Tables[0];
|
|
|
|
|
|
}
|
|
|
|
|
|
return null;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// 获取烘房内数据
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
/// <param name="bdt"></param>
|
|
|
|
|
|
/// <param name="edt"></param>
|
|
|
|
|
|
/// <returns></returns>
|
|
|
|
|
|
public DataTable GetDringRoomData(string devicecode)
|
|
|
|
|
|
{
|
|
|
|
|
|
//获取绑定中,且RFID没有出烘房(在烘房内)的数据
|
|
|
|
|
|
string sql = $@"SELECT rfid,workorder_code,product_name,product_code,isnull(car_num,0) as car_num,isnull([begin],'1900-01-01 08:00:00') as [begin],ord.status FROM [dbo].[mes_material_transfer_result] res
|
|
|
|
|
|
LEFT JOIN pro_order_workorder ord on res.OrderCode = ord.workorder_id
|
|
|
|
|
|
where rfid !=null and equipmentCode = '{devicecode}' and rfid_status = '1' and rfid not in(select rfid from mes_material_transfer_result where taskcode = '1' and rfid_status = '1')
|
|
|
|
|
|
";
|
|
|
|
|
|
|
|
|
|
|
|
DataSet dtset = Utils.netClientDBHelper.getDataSet(sql);
|
|
|
|
|
|
if (dtset != null && dtset.Tables.Count > 0 && dtset.Tables[0].Rows.Count > 0)
|
|
|
|
|
|
{
|
|
|
|
|
|
return dtset.Tables[0];
|
|
|
|
|
|
}
|
|
|
|
|
|
return null;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|