You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
101 lines
4.3 KiB
101 lines
4.3 KiB
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Net;
|
|
using System.Net.Http;
|
|
using System.Web.Http;
|
|
using Warehouse.DAL.MultipleTest;
|
|
using Warehouse.WebApi;
|
|
using Warehouse.WebApi.Model;
|
|
|
|
namespace JHReport.WebApi.Report
|
|
{ //多次测试数据
|
|
[RoutePrefix("api/MultipleTestDetail")]
|
|
public class MultipleTestDetailController : BaseController
|
|
{
|
|
MultipleTest multipletest = new MultipleTest();
|
|
[Route("QueryData")]
|
|
[HttpPost]
|
|
public IHttpActionResult QueryData(dynamic para)
|
|
{
|
|
var res = multipletest.QueryStockInfoByPallet(para);
|
|
|
|
//res peopleList = new People(peopleArray);
|
|
//foreach (Person p in peopleList)
|
|
// Console.WriteLine(p.firstName + " " + p.lastName);! foreach (var i in res)
|
|
|
|
|
|
//var sa = Convert.ToInt32(res.Select(a => a.count)) / Convert.ToInt32(ress.Select(a => a.planqty));
|
|
//var resss =(res.Select(a=>a.count)/ress.Select(a=>a.plan_qyt));
|
|
|
|
//return Json(res.Select(a => new { a.plan_qty}).Concat(res));
|
|
return Json(res);
|
|
|
|
}
|
|
|
|
|
|
[Route("QueryDataNew")]
|
|
[HttpPost]
|
|
public IHttpActionResult QueryDataNew(MultipleTestDetailReportSeerchModel model)
|
|
{
|
|
//得到数据
|
|
var res = multipletest.QueryStockInfoByPalletNew(model);
|
|
var list = new List<dynamic>();
|
|
res.ForEach(x => {
|
|
list.Add(new
|
|
{
|
|
wks_visit_date = x.wks_visit_date.ToString() ?? "-",
|
|
serial_nbr = x.serial_nbr.ToString() ?? "-",
|
|
wks_id = x.wks_id.ToString() ?? "-",
|
|
workorder = x.workorder.ToString() ?? "-",
|
|
cell_uop = x.cell_uop.ToString() ?? "-",
|
|
cell_eff = x.cell_eff.ToString() ?? "-",
|
|
pmax = x.pmax.ToString() ?? "-", //.ToString("yyyy-MM-dd HH:mm:ss")
|
|
isc = x.isc.ToString() ?? "-",
|
|
voc = x.voc.ToString() ?? "-",
|
|
ipm = x.ipm.ToString() ?? "-",
|
|
vpm = x.vpm.ToString() ?? "-",
|
|
ff = x.ff.ToString() ?? "-",
|
|
rs = x.rs.ToString() ?? "-",
|
|
rsh = x.rsh ?? "-",
|
|
eff = x.eff ?? "-",
|
|
env_temp = x.env_temp ?? "-",
|
|
surf_temp = x.surf_temp ?? "-",
|
|
temp = x.temp ?? "-",
|
|
ivfile_path = x.ivfile_path ?? "-",
|
|
product_code = x.product_code ?? "-",
|
|
cell_part_nbr = x.cell_part_nbr ?? "-",
|
|
cell_lot_nbr = x.cell_lot_nbr ?? "-",
|
|
cell_supplier_code = x.cell_supplier_code ?? "-",
|
|
glass_part_nbr = x.glass_part_nbr ?? "-",
|
|
glass_supplier_code = x.glass_supplier_code.ToString() ?? "-",
|
|
eva_part_nbr = x.eva_part_nbr.ToString() ?? "-",
|
|
eva_supplier_code = x.eva_supplier_code.ToString() ?? "-",
|
|
eva_lot_nbr = x.eva_lot_nbr.ToString() ?? "-",
|
|
bks_part_nbr = x.bks_part_nbr.ToString() ?? "-",
|
|
bks_supplier_code = x.bks_supplier_code.ToString() ?? "-",
|
|
bks_lot_nbr = x.bks_lot_nbr.ToString() ?? "-",
|
|
frame_part_nbr = x.frame_part_nbr.ToString() ?? "-",
|
|
frame_supplier_code = x.frame_supplier_code.ToString() ?? "-",
|
|
frame_lot_nbr = x.frame_lot_nbr.ToString() ?? "-",
|
|
jbox_part_nbr = x.jbox_part_nbr.ToString() ?? "-",
|
|
jbox_supplier_code = x.jbox_supplier_code.ToString() ?? "-",
|
|
jbox_lot_nbr = x.jbox_lot_nbr.ToString() ?? "-",
|
|
huiliu_part_nbr = x.huiliu_part_nbr.ToString() ?? "-",
|
|
huiliu_supplier_code = x.huiliu_supplier_code.ToString() ?? "-",
|
|
huiliu_lot_nbr = x.huiliu_lot_nbr.ToString() ?? "-",
|
|
hulian_part_nbr = x.hulian_part_nbr.ToString() ?? "-",
|
|
hulian_supplier_code = x.hulian_supplier_code.ToString() ?? "-",
|
|
});
|
|
});
|
|
|
|
//返回数据
|
|
return Success(new
|
|
{
|
|
data = list
|
|
});
|
|
|
|
}
|
|
|
|
}
|
|
}
|
|
|