作业票
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
using System.Linq;
|
||||
using System;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Configuration;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Net.Http;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
@@ -37,7 +37,7 @@ namespace BLL
|
||||
ProjectId = projectId,
|
||||
UnitId = unitId,
|
||||
TeamGroupName = TeamGroupName,
|
||||
Remark = "导入"
|
||||
Remark = "分包数据同步导入"
|
||||
};
|
||||
TeamGroupService.AddTeamGroup(newTeamGroup);
|
||||
TeamGroupId = newTeamGroup.TeamGroupId;
|
||||
@@ -53,6 +53,49 @@ namespace BLL
|
||||
|
||||
#endregion
|
||||
|
||||
#region 作业票许可证类型
|
||||
|
||||
/// <summary>
|
||||
/// 获取作业票许可证类型Id
|
||||
/// </summary>
|
||||
/// <param name="LicenseTypeId"></param>
|
||||
/// <param name="LicenseTypeCode"></param>
|
||||
/// <param name="LicenseTypeName"></param>
|
||||
/// <returns></returns>
|
||||
public static string GetLicenseTypeId(string LicenseTypeId, string LicenseTypeCode, string LicenseTypeName)
|
||||
{
|
||||
string Id = null;
|
||||
if (!string.IsNullOrEmpty(LicenseTypeName))
|
||||
{
|
||||
var obj = Funs.DB.Base_LicenseType.Where(x => x.LicenseTypeName == LicenseTypeName).ToList();
|
||||
if (obj.Count == 0)
|
||||
{
|
||||
string newId = LicenseTypeId;
|
||||
var type = Funs.DB.Base_LicenseType.Where(x => x.LicenseTypeId == LicenseTypeId).FirstOrDefault();
|
||||
if (type == null)
|
||||
{
|
||||
newId = SQLHelper.GetNewID(typeof(Model.Base_LicenseType));
|
||||
}
|
||||
Model.Base_LicenseType newModel = new Model.Base_LicenseType
|
||||
{
|
||||
LicenseTypeId = newId,
|
||||
LicenseTypeCode = LicenseTypeCode,
|
||||
LicenseTypeName = LicenseTypeName,
|
||||
Remark = "分包数据同步导入"
|
||||
};
|
||||
LicenseTypeService.AddLicenseType(newModel);
|
||||
Id = newId;
|
||||
}
|
||||
else
|
||||
{
|
||||
Id = obj.FirstOrDefault().LicenseTypeId;
|
||||
}
|
||||
}
|
||||
return Id;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
|
||||
|
||||
#region 获取作业区域
|
||||
|
||||
Reference in New Issue
Block a user