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.
53 lines
1.5 KiB
53 lines
1.5 KiB
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using QMAPP.BLL;
|
|
using QMAPP.FJC.Entity.Operation;
|
|
using QMAPP.Entity;
|
|
using QMAPP.FJC.DAL.Operation;
|
|
using QMFrameWork.Data;
|
|
|
|
namespace QMAPP.FJC.BLL.Operation
|
|
{
|
|
public class MaterialCodeBLL:BaseBLL
|
|
{
|
|
/// <summary>
|
|
/// 获取物料号信息
|
|
/// </summary>
|
|
/// <param name="protype">属性</param>
|
|
/// <returns></returns>
|
|
public DataResult<string> GetMaterialCode(string protype)
|
|
{
|
|
DataResult<string> materialcode = new DataResult<string>();
|
|
MaterialCodeDAL MaterialCodeDal = new MaterialCodeDAL();
|
|
using (IDataSession session = AppDataFactory.CreateMainSession())
|
|
{
|
|
try
|
|
{
|
|
session.OpenTs();
|
|
MaterialCodeDal.BaseSession = session;
|
|
materialcode.Result = MaterialCodeDal.GetMaterialCode(new MaterialCode {PRODUCT_TYPES = protype});
|
|
session.CommitTs();
|
|
}
|
|
catch (Exception e)
|
|
{
|
|
session.RollbackTs();
|
|
throw e;
|
|
}
|
|
}
|
|
return materialcode;
|
|
}
|
|
public string GetMaterialType(string proCode)
|
|
{
|
|
try
|
|
{
|
|
return new MaterialCodeDAL().GetMaterialType(proCode);
|
|
}
|
|
catch (Exception ex)
|
|
{
|
|
throw;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|