Merge branch 'master' of http://47.104.102.122:3000/panhf/CNCEC_SUBQHSE_WUHUAN
This commit is contained in:
commit
d7a11fdce3
|
@ -10,7 +10,7 @@ namespace BLL
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class MonthPlanService
|
public class MonthPlanService
|
||||||
{
|
{
|
||||||
public static Model.SGGLDB db = Funs.DB;
|
//public static Model.SGGLDB db = Funs.DB;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 根据主键获取月度计划情况
|
/// 根据主键获取月度计划情况
|
||||||
|
|
|
@ -10,8 +10,6 @@ namespace BLL
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class WeekItemService
|
public class WeekItemService
|
||||||
{
|
{
|
||||||
public static Model.SGGLDB db = Funs.DB;
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 根据主键获取自定义周情况
|
/// 根据主键获取自定义周情况
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
@ -19,6 +17,7 @@ namespace BLL
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public static Model.JDGL_WeekItem GetWeekItemById(string WeekId)
|
public static Model.JDGL_WeekItem GetWeekItemById(string WeekId)
|
||||||
{
|
{
|
||||||
|
Model.SGGLDB db = Funs.DB;
|
||||||
return db.JDGL_WeekItem.FirstOrDefault(e => e.WeekId == WeekId);
|
return db.JDGL_WeekItem.FirstOrDefault(e => e.WeekId == WeekId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -30,6 +29,7 @@ namespace BLL
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public static Model.JDGL_WeekItem GetWeekItemByProjectIdAndWeekNo(string ProjectId, int WeekNo)
|
public static Model.JDGL_WeekItem GetWeekItemByProjectIdAndWeekNo(string ProjectId, int WeekNo)
|
||||||
{
|
{
|
||||||
|
Model.SGGLDB db = Funs.DB;
|
||||||
return db.JDGL_WeekItem.FirstOrDefault(e => e.ProjectId == ProjectId && e.WeekNo == WeekNo);
|
return db.JDGL_WeekItem.FirstOrDefault(e => e.ProjectId == ProjectId && e.WeekNo == WeekNo);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -40,6 +40,7 @@ namespace BLL
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public static Model.JDGL_WeekItem GetWeekItemByDateNow(string ProjectId)
|
public static Model.JDGL_WeekItem GetWeekItemByDateNow(string ProjectId)
|
||||||
{
|
{
|
||||||
|
Model.SGGLDB db = Funs.DB;
|
||||||
return db.JDGL_WeekItem.FirstOrDefault(e => e.ProjectId == ProjectId && e.StartDate < DateTime.Now && e.EndDate > DateTime.Now);
|
return db.JDGL_WeekItem.FirstOrDefault(e => e.ProjectId == ProjectId && e.StartDate < DateTime.Now && e.EndDate > DateTime.Now);
|
||||||
}
|
}
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
@ -48,6 +49,7 @@ namespace BLL
|
||||||
/// <param name="WeekItem"></param>
|
/// <param name="WeekItem"></param>
|
||||||
public static void AddWeekItem(Model.JDGL_WeekItem WeekItem)
|
public static void AddWeekItem(Model.JDGL_WeekItem WeekItem)
|
||||||
{
|
{
|
||||||
|
Model.SGGLDB db = Funs.DB;
|
||||||
Model.JDGL_WeekItem newWeekItem = new Model.JDGL_WeekItem
|
Model.JDGL_WeekItem newWeekItem = new Model.JDGL_WeekItem
|
||||||
{
|
{
|
||||||
WeekId = WeekItem.WeekId,
|
WeekId = WeekItem.WeekId,
|
||||||
|
@ -68,6 +70,7 @@ namespace BLL
|
||||||
/// <param name="WeekItem"></param>
|
/// <param name="WeekItem"></param>
|
||||||
public static void UpdateWeekItem(Model.JDGL_WeekItem WeekItem)
|
public static void UpdateWeekItem(Model.JDGL_WeekItem WeekItem)
|
||||||
{
|
{
|
||||||
|
Model.SGGLDB db = Funs.DB;
|
||||||
Model.JDGL_WeekItem newWeekItem = db.JDGL_WeekItem.FirstOrDefault(e => e.WeekId == WeekItem.WeekId);
|
Model.JDGL_WeekItem newWeekItem = db.JDGL_WeekItem.FirstOrDefault(e => e.WeekId == WeekItem.WeekId);
|
||||||
if (newWeekItem != null)
|
if (newWeekItem != null)
|
||||||
{
|
{
|
||||||
|
@ -86,6 +89,7 @@ namespace BLL
|
||||||
/// <param name="WeekId"></param>
|
/// <param name="WeekId"></param>
|
||||||
public static void DeleteWeekItemById(string WeekId)
|
public static void DeleteWeekItemById(string WeekId)
|
||||||
{
|
{
|
||||||
|
Model.SGGLDB db = Funs.DB;
|
||||||
var q = (from x in db.JDGL_WeekItem where x.WeekId == WeekId select x).FirstOrDefault();
|
var q = (from x in db.JDGL_WeekItem where x.WeekId == WeekId select x).FirstOrDefault();
|
||||||
if (q != null)
|
if (q != null)
|
||||||
{
|
{
|
||||||
|
@ -102,6 +106,7 @@ namespace BLL
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public static List<JDGL_WeekItem> GetWeekItemList(string ProjectId)
|
public static List<JDGL_WeekItem> GetWeekItemList(string ProjectId)
|
||||||
{
|
{
|
||||||
|
Model.SGGLDB db = Funs.DB;
|
||||||
return (from x in db.JDGL_WeekItem where x.ProjectId == ProjectId orderby x.WeekNo descending select x).ToList();
|
return (from x in db.JDGL_WeekItem where x.ProjectId == ProjectId orderby x.WeekNo descending select x).ToList();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -11,10 +11,8 @@ namespace BLL
|
||||||
public class CNCECHSSEGetWebService
|
public class CNCECHSSEGetWebService
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
#region 督查检查整改上报
|
#region 督查检查整改上报
|
||||||
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 督查检查整改上报
|
/// 督查检查整改上报
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
@ -23,6 +21,7 @@ namespace BLL
|
||||||
string code = "0";
|
string code = "0";
|
||||||
using (Model.SGGLDB db = new Model.SGGLDB(Funs.ConnString))
|
using (Model.SGGLDB db = new Model.SGGLDB(Funs.ConnString))
|
||||||
{
|
{
|
||||||
|
string filePath = Funs.SGGLUrl;
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
var upCheckReport = from x in db.View_DCGL_CheckRectifyListFromSUB
|
var upCheckReport = from x in db.View_DCGL_CheckRectifyListFromSUB
|
||||||
|
@ -50,7 +49,7 @@ namespace BLL
|
||||||
ToKeyId = x.ToKeyId2,
|
ToKeyId = x.ToKeyId2,
|
||||||
AttachSource = x.AttachSource2,
|
AttachSource = x.AttachSource2,
|
||||||
AttachUrl = x.AttachUrl2,
|
AttachUrl = x.AttachUrl2,
|
||||||
FilePath = Funs.SGGLUrl
|
FilePath = filePath
|
||||||
//////附件转为字节传送
|
//////附件转为字节传送
|
||||||
//FileContext = FileStructService.GetMoreFileStructByAttachUrl(x.AttachUrl2),
|
//FileContext = FileStructService.GetMoreFileStructByAttachUrl(x.AttachUrl2),
|
||||||
};
|
};
|
||||||
|
@ -62,9 +61,12 @@ namespace BLL
|
||||||
{ "token", ServerService.GetToken().Token }
|
{ "token", ServerService.GetToken().Token }
|
||||||
};
|
};
|
||||||
var pushContent = JsonConvert.SerializeObject(upCheckReport.ToList());
|
var pushContent = JsonConvert.SerializeObject(upCheckReport.ToList());
|
||||||
|
|
||||||
|
//ErrLogInfo.WriteLog($"【集团检查整改上报数据】:{pushContent}");
|
||||||
var strJosn = APIGetHttpService.Http(baseurl, "Post", contenttype, newToken, pushContent);
|
var strJosn = APIGetHttpService.Http(baseurl, "Post", contenttype, newToken, pushContent);
|
||||||
if (!string.IsNullOrEmpty(strJosn))
|
if (!string.IsNullOrEmpty(strJosn))
|
||||||
{
|
{
|
||||||
|
//ErrLogInfo.WriteLog($"【集团检查整改上报数据结果】:{strJosn}");
|
||||||
JObject obj = JObject.Parse(strJosn);
|
JObject obj = JObject.Parse(strJosn);
|
||||||
code = obj["code"].ToString();
|
code = obj["code"].ToString();
|
||||||
|
|
||||||
|
@ -78,8 +80,12 @@ namespace BLL
|
||||||
var newCheckRectify = db.DCGL_Check_CheckRectify.FirstOrDefault(e => e.CheckRectifyId == item);
|
var newCheckRectify = db.DCGL_Check_CheckRectify.FirstOrDefault(e => e.CheckRectifyId == item);
|
||||||
if (newCheckRectify != null)
|
if (newCheckRectify != null)
|
||||||
{
|
{
|
||||||
newCheckRectify.HandleState = BLL.Const.State_3; //已完成
|
var getNoUpdateItem = db.DCGL_Check_CheckRectifyItem.FirstOrDefault(x => x.CheckRectifyId == checkRectifyId && !x.RealEndDate.HasValue);
|
||||||
db.SubmitChanges();
|
if (getNoUpdateItem == null)
|
||||||
|
{//问题全部整改完成
|
||||||
|
newCheckRectify.HandleState = BLL.Const.State_3; //已完成
|
||||||
|
db.SubmitChanges();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -95,10 +101,7 @@ namespace BLL
|
||||||
return code;
|
return code;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -4125,20 +4125,31 @@ namespace FineUIPro.Web.CQMS.ManageReportNew
|
||||||
string Quantity2Sum = String.Empty;//累计检查合格点数/累计检查点数
|
string Quantity2Sum = String.Empty;//累计检查合格点数/累计检查点数
|
||||||
|
|
||||||
var inspectionUnits = units.Where(x => x.UnitType == BLL.Const.ProjectUnitType_2 || x.UnitType == BLL.Const.ProjectUnitType_1).ToList();
|
var inspectionUnits = units.Where(x => x.UnitType == BLL.Const.ProjectUnitType_2 || x.UnitType == BLL.Const.ProjectUnitType_1).ToList();
|
||||||
var cqmsDetail = from c in db.View_CQMS_InspectionManagementDetail
|
//var cqmsDetail = from c in db.View_CQMS_InspectionManagementDetail
|
||||||
join u in db.Base_Unit on c.UnitId equals u.UnitId into unitJoin
|
// join u in db.Base_Unit on c.UnitId equals u.UnitId into unitJoin
|
||||||
from u in unitJoin.DefaultIfEmpty()
|
// from u in unitJoin.DefaultIfEmpty()
|
||||||
select new
|
// select new
|
||||||
{
|
// {
|
||||||
c.InspectionDate,
|
// c.InspectionDate,
|
||||||
c.ProjectId,
|
// c.ProjectId,
|
||||||
u.UnitId,
|
// u.UnitId,
|
||||||
u.UnitName,
|
// u.UnitName,
|
||||||
c.IsOnceQualified
|
// c.IsOnceQualified
|
||||||
};
|
// };
|
||||||
|
var cqmsList = from c in db.ProcessControl_InspectionManagement
|
||||||
|
join u in db.Base_Unit on c.UnitId equals u.UnitId into unitJoin
|
||||||
|
from u in unitJoin.DefaultIfEmpty()
|
||||||
|
select new
|
||||||
|
{
|
||||||
|
c.InspectionDate,
|
||||||
|
c.ProjectId,
|
||||||
|
u.UnitId,
|
||||||
|
u.UnitName,
|
||||||
|
c.IsOnceQualified
|
||||||
|
};
|
||||||
foreach (var item in inspectionUnits)
|
foreach (var item in inspectionUnits)
|
||||||
{
|
{
|
||||||
var query = from x in cqmsDetail
|
var query = from x in cqmsList
|
||||||
where x.ProjectId == this.CurrUser.LoginProjectId && x.UnitId == item.UnitId
|
where x.ProjectId == this.CurrUser.LoginProjectId && x.UnitId == item.UnitId
|
||||||
select new
|
select new
|
||||||
{
|
{
|
||||||
|
|
|
@ -1562,20 +1562,31 @@ namespace FineUIPro.Web.CQMS.ManageReportNew
|
||||||
// orderby y.UnitCode
|
// orderby y.UnitCode
|
||||||
// select new { x.UnitId, y.UnitName };
|
// select new { x.UnitId, y.UnitName };
|
||||||
var unitLists = units.Where(x => x.UnitType == BLL.Const.ProjectUnitType_2 || x.UnitType == BLL.Const.ProjectUnitType_1).ToList();
|
var unitLists = units.Where(x => x.UnitType == BLL.Const.ProjectUnitType_2 || x.UnitType == BLL.Const.ProjectUnitType_1).ToList();
|
||||||
var cqmsDetail = from c in db.View_CQMS_InspectionManagementDetail
|
//var cqmsDetail = from c in db.View_CQMS_InspectionManagementDetail
|
||||||
join u in db.Base_Unit on c.UnitId equals u.UnitId into unitJoin
|
// join u in db.Base_Unit on c.UnitId equals u.UnitId into unitJoin
|
||||||
from u in unitJoin.DefaultIfEmpty()
|
// from u in unitJoin.DefaultIfEmpty()
|
||||||
select new
|
// select new
|
||||||
{
|
// {
|
||||||
c.CheckDate,
|
// c.CheckDate,
|
||||||
c.ProjectId,
|
// c.ProjectId,
|
||||||
u.UnitId,
|
// u.UnitId,
|
||||||
u.UnitName,
|
// u.UnitName,
|
||||||
c.IsOnceQualified
|
// c.IsOnceQualified
|
||||||
};
|
// };
|
||||||
|
var cqmsList = from c in db.ProcessControl_InspectionManagement
|
||||||
|
join u in db.Base_Unit on c.UnitId equals u.UnitId into unitJoin
|
||||||
|
from u in unitJoin.DefaultIfEmpty()
|
||||||
|
select new
|
||||||
|
{
|
||||||
|
c.CheckDate,
|
||||||
|
c.ProjectId,
|
||||||
|
u.UnitId,
|
||||||
|
u.UnitName,
|
||||||
|
c.IsOnceQualified
|
||||||
|
};
|
||||||
foreach (var item in unitLists)
|
foreach (var item in unitLists)
|
||||||
{
|
{
|
||||||
var query = from x in cqmsDetail
|
var query = from x in cqmsList
|
||||||
where x.ProjectId == this.CurrUser.LoginProjectId && x.UnitId == item.UnitId
|
where x.ProjectId == this.CurrUser.LoginProjectId && x.UnitId == item.UnitId
|
||||||
select new
|
select new
|
||||||
{
|
{
|
||||||
|
|
|
@ -95,6 +95,7 @@ namespace FineUIPro.Web.DCGL.ServerCheck
|
||||||
|
|
||||||
if (attachFile != null)
|
if (attachFile != null)
|
||||||
{
|
{
|
||||||
|
CNCECPath = !string.IsNullOrWhiteSpace(CNCECPath) ? CNCECPath : "https://qhse.cncecoa.com/QHSE/";
|
||||||
url = BLL.UploadAttachmentService.ShowImage(CNCECPath, attachFile.AttachUrl);
|
url = BLL.UploadAttachmentService.ShowImage(CNCECPath, attachFile.AttachUrl);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -165,7 +165,7 @@ namespace FineUIPro.Web.DataShow
|
||||||
if (projectId != null)
|
if (projectId != null)
|
||||||
{
|
{
|
||||||
var datetime1 = Funs.GetNewDateTime(this.txtStartTime.Text);
|
var datetime1 = Funs.GetNewDateTime(this.txtStartTime.Text);
|
||||||
var datetime2 = Funs.GetNewDateTime(this.txtStartTime.Text);
|
var datetime2 = Funs.GetNewDateTime(this.txtEndTime.Text);
|
||||||
var getT = Funs.DB.ProcessControl_InspectionManagement.Where(x => x.ProjectId == projectId.ToString());
|
var getT = Funs.DB.ProcessControl_InspectionManagement.Where(x => x.ProjectId == projectId.ToString());
|
||||||
if (datetime1.HasValue)
|
if (datetime1.HasValue)
|
||||||
{
|
{
|
||||||
|
@ -187,7 +187,7 @@ namespace FineUIPro.Web.DataShow
|
||||||
if (projectId != null)
|
if (projectId != null)
|
||||||
{
|
{
|
||||||
var datetime1 = Funs.GetNewDateTime(this.txtStartTime.Text);
|
var datetime1 = Funs.GetNewDateTime(this.txtStartTime.Text);
|
||||||
var datetime2 = Funs.GetNewDateTime(this.txtStartTime.Text);
|
var datetime2 = Funs.GetNewDateTime(this.txtEndTime.Text);
|
||||||
var getT = Funs.DB.ProcessControl_InspectionManagement.Where(x => x.ProjectId == projectId.ToString() && x.IsOnceQualified == true);
|
var getT = Funs.DB.ProcessControl_InspectionManagement.Where(x => x.ProjectId == projectId.ToString() && x.IsOnceQualified == true);
|
||||||
if (datetime1.HasValue)
|
if (datetime1.HasValue)
|
||||||
{
|
{
|
||||||
|
@ -209,7 +209,7 @@ namespace FineUIPro.Web.DataShow
|
||||||
if (projectId != null)
|
if (projectId != null)
|
||||||
{
|
{
|
||||||
var datetime1 = Funs.GetNewDateTime(this.txtStartTime.Text);
|
var datetime1 = Funs.GetNewDateTime(this.txtStartTime.Text);
|
||||||
var datetime2 = Funs.GetNewDateTime(this.txtStartTime.Text);
|
var datetime2 = Funs.GetNewDateTime(this.txtEndTime.Text);
|
||||||
var getALL = Funs.DB.ProcessControl_InspectionManagement.Where(x => x.ProjectId == projectId.ToString());
|
var getALL = Funs.DB.ProcessControl_InspectionManagement.Where(x => x.ProjectId == projectId.ToString());
|
||||||
|
|
||||||
if (datetime1.HasValue)
|
if (datetime1.HasValue)
|
||||||
|
|
|
@ -101,13 +101,8 @@
|
||||||
<f:Tab ID="Tab2" Title="下周计划" BodyPadding="5px" Layout="VBox" IconFont="Bookmark" TitleToolTip="下周计划"
|
<f:Tab ID="Tab2" Title="下周计划" BodyPadding="5px" Layout="VBox" IconFont="Bookmark" TitleToolTip="下周计划"
|
||||||
runat="server">
|
runat="server">
|
||||||
<Items>
|
<Items>
|
||||||
<f:Grid ID="Grid1" ShowBorder="true" EnableAjax="false" ShowHeader="false" Title="周进度计划" EnableCollapse="true"
|
<f:Grid ID="Grid1" IsFluid="true" CssClass="blockpanel" ShowBorder="true" ShowHeader="false" runat="server" EnableCollapse="false" Height="500px" PageSize="1000"
|
||||||
runat="server" BoxFlex="1" DataKeyNames="WeekPlanId" AllowCellEditing="true" ForceFit="true" Height="500px"
|
DataKeyNames="WeekPlanId" DataIDField="WeekPlanId" EnableColumnLines="true" ForceFit="true" AllowCellEditing="true" ClicksToEdit="1">
|
||||||
ClicksToEdit="1" DataIDField="WeekPlanId" AllowSorting="true" SortField="SortIndex"
|
|
||||||
SortDirection="ASC" EnableColumnLines="true"
|
|
||||||
PageSize="1000"
|
|
||||||
AllowFilters="true" EnableTextSelection="True">
|
|
||||||
|
|
||||||
<Columns>
|
<Columns>
|
||||||
<f:TemplateField ColumnID="tfPageIndex" Width="55px" HeaderText="序号" HeaderTextAlign="Center" TextAlign="Center"
|
<f:TemplateField ColumnID="tfPageIndex" Width="55px" HeaderText="序号" HeaderTextAlign="Center" TextAlign="Center"
|
||||||
EnableLock="true" Locked="False">
|
EnableLock="true" Locked="False">
|
||||||
|
|
Loading…
Reference in New Issue