首页大屏幕
This commit is contained in:
parent
20de71f91a
commit
5baefadb6b
|
@ -257,7 +257,7 @@
|
||||||
* 连接 服务器地址
|
* 连接 服务器地址
|
||||||
* 并绑定 websock 四个事件方法
|
* 并绑定 websock 四个事件方法
|
||||||
*/
|
*/
|
||||||
websock = new WebSocket('ws://localhost:1000');
|
websock = new WebSocket('ws://sgglapi.chengda.com:1000');
|
||||||
// 接收服务器返回的数据
|
// 接收服务器返回的数据
|
||||||
websock.onmessage = this.websocketonmessage;
|
websock.onmessage = this.websocketonmessage;
|
||||||
// 连接建立时触发
|
// 连接建立时触发
|
||||||
|
|
|
@ -54,7 +54,7 @@ namespace FineUIPro.Web.HSSE.KqShowScreen
|
||||||
int total = 0;
|
int total = 0;
|
||||||
HashSet<string> ids = new HashSet<string>();
|
HashSet<string> ids = new HashSet<string>();
|
||||||
HashSet<string> idsIn = new HashSet<string>();
|
HashSet<string> idsIn = new HashSet<string>();
|
||||||
Dictionary<string,DateTime> inperson = new Dictionary<string, DateTime>();
|
Dictionary<string, DateTime> inperson = new Dictionary<string, DateTime>();
|
||||||
Dictionary<string, DateTime> outPerson = new Dictionary<string, DateTime>();
|
Dictionary<string, DateTime> outPerson = new Dictionary<string, DateTime>();
|
||||||
DateTime dateTime = DateTime.Now.AddDays(-1);
|
DateTime dateTime = DateTime.Now.AddDays(-1);
|
||||||
var inout = Funs.DB.SitePerson_PersonInOut.Where(x => x.ProjectId == projectId && x.ChangeTime > dateTime).OrderByDescending(x => x.ChangeTime);
|
var inout = Funs.DB.SitePerson_PersonInOut.Where(x => x.ProjectId == projectId && x.ChangeTime > dateTime).OrderByDescending(x => x.ChangeTime);
|
||||||
|
@ -155,15 +155,24 @@ namespace FineUIPro.Web.HSSE.KqShowScreen
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
var personInOut = inout.FirstOrDefault();
|
var personInOut = inout.FirstOrDefault();
|
||||||
var person = Funs.DB.SitePerson_Person.FirstOrDefault(x => x.PersonId == personInOut.PersonId);
|
|
||||||
string teamGroupName = "";
|
string teamGroupName = "";
|
||||||
string inOut = "出场";
|
string inOut = "出场";
|
||||||
string PhotoUrl = "";
|
string PhotoUrl = "";
|
||||||
PhotoUrl = "../../"+person.PhotoUrl;
|
string PersonName = "";
|
||||||
if (personInOut.IsIn ==true)
|
string UnitName = "";
|
||||||
|
string WorkPostName = "";
|
||||||
|
string ChangeTime = "";
|
||||||
|
if (personInOut != null)
|
||||||
|
{
|
||||||
|
var person = Funs.DB.SitePerson_Person.FirstOrDefault(x => x.PersonId == personInOut.PersonId);
|
||||||
|
PersonName = personInOut.PersonName;
|
||||||
|
UnitName = personInOut.UnitName;
|
||||||
|
WorkPostName = personInOut.WorkPostName;
|
||||||
|
ChangeTime = personInOut.ChangeTime.Value.ToString("yyyy-MM-dd HH:mm");
|
||||||
|
PhotoUrl = "../../" + person.PhotoUrl;
|
||||||
|
if (personInOut.IsIn == true)
|
||||||
{
|
{
|
||||||
inOut = "入场";
|
inOut = "入场";
|
||||||
|
|
||||||
}
|
}
|
||||||
if (!string.IsNullOrEmpty(person.TeamGroupId))
|
if (!string.IsNullOrEmpty(person.TeamGroupId))
|
||||||
{
|
{
|
||||||
|
@ -173,10 +182,11 @@ namespace FineUIPro.Web.HSSE.KqShowScreen
|
||||||
teamGroupName = teamGroup.TeamGroupName;
|
teamGroupName = teamGroup.TeamGroupName;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
List<object> comStatic = new List<object>();
|
List<object> comStatic = new List<object>();
|
||||||
foreach (var key in company.Keys)
|
foreach (var key in company.Keys)
|
||||||
{
|
{
|
||||||
comStatic.Add(new { name =key, value=company[key] });
|
comStatic.Add(new { name = key, value = company[key] });
|
||||||
}
|
}
|
||||||
List<string> workPostName = new List<string>();
|
List<string> workPostName = new List<string>();
|
||||||
List<int> workPostValue = new List<int>();
|
List<int> workPostValue = new List<int>();
|
||||||
|
@ -185,9 +195,9 @@ namespace FineUIPro.Web.HSSE.KqShowScreen
|
||||||
workPostName.Add(key);
|
workPostName.Add(key);
|
||||||
workPostValue.Add(workPost[key]);
|
workPostValue.Add(workPost[key]);
|
||||||
}
|
}
|
||||||
|
return new { company = comStatic, total, workPost = new { name = workPostName, value = workPostValue }, person = new { PersonName, UnitName, WorkPostName, inOut, PhotoUrl, teamGroupName, ChangeTime } };
|
||||||
|
|
||||||
return new { company = comStatic, total, workPost = new { name = workPostName, value = workPostValue }, person = new{ personInOut.PersonName,personInOut.UnitName, personInOut.WorkPostName , inOut, PhotoUrl , teamGroupName, ChangeTime = personInOut.ChangeTime.Value.ToString("yyyy-MM-dd HH:mm")} };
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -314,94 +314,122 @@
|
||||||
|
|
||||||
function initCircle() {
|
function initCircle() {
|
||||||
// 一个环形
|
// 一个环形
|
||||||
var circleOneOption = {
|
//var circleOneOption = {
|
||||||
drawing_elem: 'circleId',
|
// drawing_elem: 'circleId',
|
||||||
bordercolor: '#12cda2',
|
// bordercolor: '#12cda2',
|
||||||
borderwidth: 1,
|
// borderwidth: 1,
|
||||||
percentfontsize: 22,
|
// percentfontsize: 22,
|
||||||
unitfontsize: 18,
|
// unitfontsize: 18,
|
||||||
lineWidth: 16,
|
// lineWidth: 16,
|
||||||
addLeft: 4,
|
// addLeft: 4,
|
||||||
percentfontcolor: "#12cda2",
|
// percentfontcolor: "#12cda2",
|
||||||
unitfontcolor: '#12cda2',
|
// unitfontcolor: '#12cda2',
|
||||||
forecolor: '#12cda2',
|
// forecolor: '#12cda2',
|
||||||
unitadd: 1,
|
// unitadd: 1,
|
||||||
title: '在岗率',
|
// title: '在岗率',
|
||||||
titlefontcolor: '#12cda2',
|
// titlefontcolor: '#12cda2',
|
||||||
titlefontsize: 9,
|
// titlefontsize: 9,
|
||||||
}
|
//}
|
||||||
var $itemPW = $('.sd-section .sd-user-calc');
|
//var $itemPW = $('.sd-section .sd-user-calc');
|
||||||
var itemPW = $itemPW.width()
|
//var itemPW = $itemPW.width()
|
||||||
var $itemPPW = $('.sd-section .sd-user-calc .sd-user-calc-left');
|
//var $itemPPW = $('.sd-section .sd-user-calc .sd-user-calc-left');
|
||||||
var itemPPW = $itemPPW.width()
|
//var itemPPW = $itemPPW.width()
|
||||||
var itemPPWPadding = ($itemPPW.innerWidth() - itemPPW) / 2
|
//var itemPPWPadding = ($itemPPW.innerWidth() - itemPPW) / 2
|
||||||
var itemPPWW = $('.sd-section .sd-user-calc .sd-user-calc-left .sd-user-calc-item').eq(0).innerWidth()
|
//var itemPPWW = $('.sd-section .sd-user-calc .sd-user-calc-left .sd-user-calc-item').eq(0).innerWidth()
|
||||||
// 通过改变差值来决定圈的宽度,itemWMin为最新值
|
//// 通过改变差值来决定圈的宽度,itemWMin为最新值
|
||||||
var itemW = (itemPW - itemPPWPadding - itemPPWW) / 3 * 2;
|
//var itemW = (itemPW - itemPPWPadding - itemPPWW) / 3 * 2;
|
||||||
var itemWMin = 120
|
//var itemWMin = 120
|
||||||
if (itemW > itemWMin) {
|
//if (itemW > itemWMin) {
|
||||||
$('#circleId').attr('width', itemW).attr('height', itemW);
|
// $('#circleId').attr('width', itemW).attr('height', itemW);
|
||||||
circleOneOption.percentfontsize = (itemW * 22 / itemWMin).toFixed() - 0
|
// circleOneOption.percentfontsize = (itemW * 22 / itemWMin).toFixed() - 0
|
||||||
circleOneOption.unitfontsize = (itemW * 18 / itemWMin).toFixed() - 0
|
// circleOneOption.unitfontsize = (itemW * 18 / itemWMin).toFixed() - 0
|
||||||
circleOneOption.titlefontsize = 16
|
// circleOneOption.titlefontsize = 16
|
||||||
}
|
//}
|
||||||
console.log(itemPW, itemW, circleOneOption)
|
//console.log(itemPW, itemW, circleOneOption)
|
||||||
drawCircle(circleOneOption);
|
//drawCircle(circleOneOption);
|
||||||
// 两个环形
|
//// 两个环形
|
||||||
var circleTwoOption = {
|
//var circleTwoOption = {
|
||||||
|
// drawing_elem: 'circleId1',
|
||||||
|
// percentfontsize: 22,
|
||||||
|
// unitfontsize: 18,
|
||||||
|
// lineWidth: 10,
|
||||||
|
// addLeft: 4,
|
||||||
|
// percentfontcolor: "#ffb260",
|
||||||
|
// bgcolor: '#0F2164',
|
||||||
|
// forecolor: '#ffb260',
|
||||||
|
// unitfontcolor: '#1ab1ff',
|
||||||
|
// lineGap: 'round',
|
||||||
|
// unitadd: -1,
|
||||||
|
//}
|
||||||
|
|
||||||
|
//var $itemInner = $('.sd-section5-inner')
|
||||||
|
//var $itemInnerTop = $('.sd-section5-inner .sd-quality')
|
||||||
|
//var heightTemp = $itemInner.height() - $itemInnerTop.height()
|
||||||
|
//var $itemTW = $('.sd-quality-circles');
|
||||||
|
//var itemTW = ($itemTW.width() / 2 / 3 * 2).toFixed() - 20
|
||||||
|
//var itemTH = $itemTW.height()
|
||||||
|
//console.log(itemTW, heightTemp)
|
||||||
|
//if (itemTW > heightTemp) {
|
||||||
|
// itemTW = heightTemp
|
||||||
|
//}
|
||||||
|
//// 通过改变差值来决定圈的宽度
|
||||||
|
//var itemW = itemTW
|
||||||
|
//var itemWMin = 100
|
||||||
|
//if (itemW > itemWMin) {
|
||||||
|
// $('#circleId1').attr('width', itemW).attr('height', itemW);
|
||||||
|
// circleTwoOption.percentfontsize = (itemW * 22 / itemWMin).toFixed() - 0
|
||||||
|
// circleTwoOption.unitfontsize = (itemW * 18 / itemWMin).toFixed() - 0
|
||||||
|
//}
|
||||||
|
//var circleThreeOption = {
|
||||||
|
// drawing_elem: 'circleId2',
|
||||||
|
// percentfontsize: 22,
|
||||||
|
// unitfontsize: 18,
|
||||||
|
// lineWidth: 10,
|
||||||
|
// addLeft: 4,
|
||||||
|
// percentfontcolor: "#12cda2",
|
||||||
|
// bgcolor: '#0F2164',
|
||||||
|
// forecolor: '#12cda2',
|
||||||
|
// unitfontcolor: '#1ab1ff',
|
||||||
|
// lineGap: 'round',
|
||||||
|
// unitadd: -1,
|
||||||
|
//}
|
||||||
|
//if (itemW > itemWMin) {
|
||||||
|
// $('#circleId2').attr('width', itemW).attr('height', itemW);
|
||||||
|
// circleThreeOption.percentfontsize = (itemW * 22 / itemWMin).toFixed() - 0
|
||||||
|
// circleThreeOption.unitfontsize = (itemW * 18 / itemWMin).toFixed() - 0
|
||||||
|
//}
|
||||||
|
//console.log(itemTW, itemTH, itemW, circleThreeOption)
|
||||||
|
|
||||||
|
//drawCircle(circleTwoOption);
|
||||||
|
//drawCircle(circleThreeOption);
|
||||||
|
drawCircle({
|
||||||
drawing_elem: 'circleId1',
|
drawing_elem: 'circleId1',
|
||||||
percentfontsize: 22,
|
percentfontcolor: "#ce8306",
|
||||||
unitfontsize: 18,
|
unitfontcolor: "#ce8306",
|
||||||
lineWidth: 10,
|
unitfontsize: 11,
|
||||||
addLeft: 4,
|
|
||||||
percentfontcolor: "#ffb260",
|
|
||||||
bgcolor: '#0F2164',
|
|
||||||
forecolor: '#ffb260',
|
|
||||||
unitfontcolor: '#1ab1ff',
|
|
||||||
lineGap: 'round',
|
lineGap: 'round',
|
||||||
unitadd: -1,
|
bgcolor: [{ step: 0, color: "#03344C" }, { step: 1, color: "#03344C" }],
|
||||||
}
|
forecolor: [{ step: 0, color: "#ce8306" }, { step: 0.4, color: "#ce8306" }, { step: 1, color: "rgba(255,166,0,0.05)" }],
|
||||||
|
rad: Math.PI * 2 * (3 / 4) / 100,
|
||||||
var $itemInner = $('.sd-section5-inner')
|
radStart: Math.PI * (3 / 4),
|
||||||
var $itemInnerTop = $('.sd-section5-inner .sd-quality')
|
radEnd: Math.PI * (2 + (1 / 4)),
|
||||||
var heightTemp = $itemInner.height() - $itemInnerTop.height()
|
radDrawStart: Math.PI * (3 / 4),
|
||||||
var $itemTW = $('.sd-quality-circles');
|
unitadd: 1,
|
||||||
var itemTW = ($itemTW.width() / 2 / 3 * 2).toFixed() - 20
|
});
|
||||||
var itemTH = $itemTW.height()
|
drawCircle({
|
||||||
console.log(itemTW, heightTemp)
|
|
||||||
if (itemTW > heightTemp) {
|
|
||||||
itemTW = heightTemp
|
|
||||||
}
|
|
||||||
// 通过改变差值来决定圈的宽度
|
|
||||||
var itemW = itemTW
|
|
||||||
var itemWMin = 100
|
|
||||||
if (itemW > itemWMin) {
|
|
||||||
$('#circleId1').attr('width', itemW).attr('height', itemW);
|
|
||||||
circleTwoOption.percentfontsize = (itemW * 22 / itemWMin).toFixed() - 0
|
|
||||||
circleTwoOption.unitfontsize = (itemW * 18 / itemWMin).toFixed() - 0
|
|
||||||
}
|
|
||||||
var circleThreeOption = {
|
|
||||||
drawing_elem: 'circleId2',
|
drawing_elem: 'circleId2',
|
||||||
percentfontsize: 22,
|
|
||||||
unitfontsize: 18,
|
|
||||||
lineWidth: 10,
|
|
||||||
addLeft: 4,
|
|
||||||
percentfontcolor: "#12cda2",
|
percentfontcolor: "#12cda2",
|
||||||
bgcolor: '#0F2164',
|
unitfontcolor: "#12cda2",
|
||||||
forecolor: '#12cda2',
|
unitfontsize: 11,
|
||||||
unitfontcolor: '#1ab1ff',
|
|
||||||
lineGap: 'round',
|
lineGap: 'round',
|
||||||
unitadd: -1,
|
bgcolor: [{ step: 0, color: "#03344C" }, { step: 1, color: "rgba(3,52,76,0.5)" }],
|
||||||
}
|
forecolor: [{ step: 0, color: "#12cda2" }, { step: 0.4, color: "#12cda2" }, { step: 1, color: "rgba(21,237,187,0.05)" }],
|
||||||
if (itemW > itemWMin) {
|
rad: Math.PI * 2 * (3 / 4) / 100,
|
||||||
$('#circleId2').attr('width', itemW).attr('height', itemW);
|
radStart: Math.PI * (3 / 4),
|
||||||
circleThreeOption.percentfontsize = (itemW * 22 / itemWMin).toFixed() - 0
|
radEnd: Math.PI * (2 + (1 / 4)),
|
||||||
circleThreeOption.unitfontsize = (itemW * 18 / itemWMin).toFixed() - 0
|
radDrawStart: Math.PI * (3 / 4),
|
||||||
}
|
unitadd: 1,
|
||||||
console.log(itemTW, itemTH, itemW, circleThreeOption)
|
});
|
||||||
|
|
||||||
drawCircle(circleTwoOption);
|
|
||||||
drawCircle(circleThreeOption);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 地图点
|
// 地图点
|
||||||
|
|
|
@ -166,17 +166,42 @@ namespace FineUIPro.Web.common
|
||||||
this.divSafeWorkTime.InnerHtml = "0000000000";
|
this.divSafeWorkTime.InnerHtml = "0000000000";
|
||||||
}
|
}
|
||||||
///整改单
|
///整改单
|
||||||
var getRectify =from x in Funs.DB.Check_RectifyNotices
|
//var getRectify =from x in Funs.DB.Check_RectifyNotices
|
||||||
where x.States !=Const.State_0 && x.States != null && x.ProjectId != null
|
// where x.States !=Const.State_0 && x.States != null && x.ProjectId != null
|
||||||
select x;
|
// select x;
|
||||||
int allcout = getRectify.Count();
|
//int allcout = getRectify.Count();
|
||||||
if (allcout > 0)
|
//if (allcout > 0)
|
||||||
|
//{
|
||||||
|
// this.divAllRectify.InnerHtml = allcout.ToString();
|
||||||
|
// int ccount = getRectify.Where(x => x.States == "5").Count();
|
||||||
|
// this.divRectifyRate.InnerHtml = Math.Round(ccount * 1.0 / allcout * 100, 1).ToString();
|
||||||
|
//}
|
||||||
|
|
||||||
|
|
||||||
|
var getRectify = from x in Funs.DB.View_Hazard_HazardRegister
|
||||||
|
where x.States != Const.State_0 && x.States != Const.State_R && x.States != null
|
||||||
|
group x by x.States into g
|
||||||
|
select new { g.Key, Count = g.Count() };
|
||||||
|
var allcout = getRectify.ToList();
|
||||||
|
if (allcout.Count > 0)
|
||||||
{
|
{
|
||||||
this.divAllRectify.InnerHtml = allcout.ToString();
|
int total = 0;
|
||||||
int ccount = getRectify.Where(x => x.States == "5").Count();
|
int finish = 0;
|
||||||
this.divRectifyRate.InnerHtml = Math.Round(ccount * 1.0 / allcout * 100, 1).ToString();
|
foreach (var item in allcout)
|
||||||
|
{
|
||||||
|
total += item.Count;
|
||||||
|
if (item.Key.ToString() == "3")
|
||||||
|
{
|
||||||
|
finish += item.Count;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
this.divAllRectify.InnerHtml = total.ToString();
|
||||||
|
//this.divUCRectify.InnerHtml = (total - finish).ToString();
|
||||||
|
this.divRectifyRate.InnerHtml = Math.Round(finish * 1.0 / total * 100, 1).ToString() ;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
#region 获取合同
|
#region 获取合同
|
||||||
|
@ -229,6 +254,9 @@ namespace FineUIPro.Web.common
|
||||||
///问题总数
|
///问题总数
|
||||||
int AllCount = getJointCheckDetail.Count() + getCheckControl.Count();
|
int AllCount = getJointCheckDetail.Count() + getCheckControl.Count();
|
||||||
this.divCQMSAllNum.InnerHtml = AllCount.ToString();
|
this.divCQMSAllNum.InnerHtml = AllCount.ToString();
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
if (AllCount > 0)
|
if (AllCount > 0)
|
||||||
{
|
{
|
||||||
///问题完成数
|
///问题完成数
|
||||||
|
@ -240,20 +268,28 @@ namespace FineUIPro.Web.common
|
||||||
CRectificationRate = Math.Round(CCount * 1.0 / AllCount * 100, 1);
|
CRectificationRate = Math.Round(CCount * 1.0 / AllCount * 100, 1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
var inspectionManagements = from x in Funs.DB.View_CQMS_InspectionManagementDetail select x;
|
||||||
var getSpotCheckDetail = from x in Funs.DB.Check_SpotCheckDetail
|
if (inspectionManagements.Count() > 0)
|
||||||
join y in Funs.DB.WBS_ControlItemAndCycle on x.ControlItemAndCycleId equals y.ControlItemAndCycleId
|
|
||||||
where y.ControlPoint != "C" && y.ControlPoint != "CR" && x.IsOK != null
|
|
||||||
select x;
|
|
||||||
int AllSpotCount = getSpotCheckDetail.Count();
|
|
||||||
if (AllSpotCount > 0)
|
|
||||||
{
|
{
|
||||||
int okSpotCount = getSpotCheckDetail.Where(x => x.IsOK == true).Count();
|
int okInspectionManagements = inspectionManagements.Where(x => x.IsOnceQualified == true).Count();
|
||||||
if (okSpotCount > 0)
|
if (okInspectionManagements > 0)
|
||||||
{
|
{
|
||||||
CQualifiedRate = Math.Round(okSpotCount * 1.0 / AllSpotCount * 100, 1);
|
CQualifiedRate = Math.Round(okInspectionManagements * 1.0 / inspectionManagements.Count() * 100, 1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
//var getSpotCheckDetail = from x in Funs.DB.Check_SpotCheckDetail
|
||||||
|
// join y in Funs.DB.WBS_ControlItemAndCycle on x.ControlItemAndCycleId equals y.ControlItemAndCycleId
|
||||||
|
// where y.ControlPoint != "C" && y.ControlPoint != "CR" && x.IsOK != null
|
||||||
|
// select x;
|
||||||
|
//int AllSpotCount = getSpotCheckDetail.Count();
|
||||||
|
//if (AllSpotCount > 0)
|
||||||
|
//{
|
||||||
|
// int okSpotCount = getSpotCheckDetail.Where(x => x.IsOK == true).Count();
|
||||||
|
// if (okSpotCount > 0)
|
||||||
|
// {
|
||||||
|
// CQualifiedRate = Math.Round(okSpotCount * 1.0 / AllSpotCount * 100, 1);
|
||||||
|
// }
|
||||||
|
//}
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
|
|
@ -1,134 +1,167 @@
|
||||||
*{
|
* {
|
||||||
padding: 0;
|
padding: 0;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
font-size: .175rem;
|
font-size: .175rem;
|
||||||
color: #1ab1ff;
|
color: #1ab1ff;
|
||||||
}
|
}
|
||||||
*::-webkit-scrollbar{
|
|
||||||
|
*::-webkit-scrollbar {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
html,body{
|
|
||||||
|
html, body {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
overflow: hidden;
|
||||||
|
background-color: #010a2c;
|
||||||
}
|
}
|
||||||
|
|
||||||
.context{
|
.context {
|
||||||
height: 100%;
|
height: calc(100% - 1rem);
|
||||||
width: 100%;
|
width: 100%;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
padding: .25rem;
|
padding: .25rem;
|
||||||
background-color: #010a2c;
|
background-color: #010a2c;
|
||||||
}
|
}
|
||||||
.site{
|
|
||||||
|
.site {
|
||||||
flex: 1;
|
flex: 1;
|
||||||
padding: .125rem;
|
padding: .125rem;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
}
|
}
|
||||||
.block{
|
|
||||||
|
.block {
|
||||||
height: calc((100% - .5rem) / 3);
|
height: calc((100% - .5rem) / 3);
|
||||||
width: 100%;
|
width: 100%;
|
||||||
border: 2px solid #112A67;
|
border: 2px solid #112A67;
|
||||||
border-radius: .125rem;
|
border-radius: .125rem;
|
||||||
|
|
||||||
}
|
}
|
||||||
.block1>.title,
|
|
||||||
.block>.title{
|
.block1 > .title,
|
||||||
|
.block > .title {
|
||||||
|
padding: .125rem 0;
|
||||||
color: #00ffff;
|
color: #00ffff;
|
||||||
font-weight: 700;
|
font-weight: 700;
|
||||||
font-size: .175rem;
|
font-size: .25rem;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
line-height: .35rem;
|
line-height: .35rem;
|
||||||
}
|
}
|
||||||
.block>.main{
|
|
||||||
|
.block > .main {
|
||||||
height: calc(100% - .35rem);
|
height: calc(100% - .35rem);
|
||||||
width: 100%;
|
width: 100%;
|
||||||
padding: .25rem;
|
padding: .25rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.context > .right {
|
||||||
|
/* padding-top: .25rem; */
|
||||||
}
|
}
|
||||||
.context>.right{
|
|
||||||
padding-top: .25rem;
|
.block1 {
|
||||||
}
|
|
||||||
.block1{
|
|
||||||
height: calc((100% - .5rem) / 3 * 2 + .25rem);
|
height: calc((100% - .5rem) / 3 * 2 + .25rem);
|
||||||
background-color: #010E35;
|
background-color: #010E35;
|
||||||
border: 2px solid #112A67;
|
border: 2px solid #112A67;
|
||||||
border-radius: .125rem;
|
border-radius: .125rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.xc{
|
.xc {
|
||||||
background-image: url(../image/y01.png);
|
background-image: url(../image/y01.png);
|
||||||
background-position: center;
|
background-position: center;
|
||||||
background-repeat: no-repeat;
|
background-repeat: no-repeat;
|
||||||
background-size: 60% 90%;
|
background-size: 60% 90%;
|
||||||
/* background-size: ; */
|
/* background-size: ; */
|
||||||
}
|
}
|
||||||
.xc>.number{
|
|
||||||
|
.xc > .number {
|
||||||
text-align: center;
|
text-align: center;
|
||||||
color: #1ab1ff;
|
color: #1ab1ff;
|
||||||
margin-top: .375rem;
|
margin-top: .375rem;
|
||||||
font-size: .375rem;
|
font-size: .625rem;
|
||||||
font-weight: 700;
|
font-weight: 700;
|
||||||
}
|
}
|
||||||
.gsxc{
|
|
||||||
|
.gsxc {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
ul{
|
|
||||||
|
ul {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
padding: 0 .375rem;
|
padding: 0 .375rem;
|
||||||
}
|
}
|
||||||
ul>li{
|
|
||||||
|
ul > li {
|
||||||
padding: .1rem 0;
|
padding: .1rem 0;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
list-style: none;
|
list-style: none;
|
||||||
display: flex;
|
display: flex;
|
||||||
}
|
}
|
||||||
ul>li>span{
|
|
||||||
|
ul > li > span {
|
||||||
flex: 1;
|
flex: 1;
|
||||||
font-size: .2rem;
|
font-size: .325rem;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
|
}
|
||||||
|
|
||||||
|
.info > ul > li > span:nth-child(2) {
|
||||||
|
flex: 2.5;
|
||||||
}
|
}
|
||||||
.gsxc ul>li>span:nth-child(2){
|
|
||||||
|
.gsxc ul > li > span:nth-child(2) {
|
||||||
color: #00ffff;
|
color: #00ffff;
|
||||||
font-size: .25rem;
|
font-size: .35rem;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
}
|
}
|
||||||
|
|
||||||
.context .right{
|
.context .right {
|
||||||
flex: 2;
|
flex: 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
.context>.right>.block1>.top{
|
.context > .right > .block1 > .top {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.context>.right>.block1>.top>.info{
|
.context > .right > .block1 > .top > .info {
|
||||||
width: 58%;
|
width: 58%;
|
||||||
padding: .75rem .5rem .25rem;
|
padding: .75rem .5rem .25rem;
|
||||||
}
|
}
|
||||||
.context>.right>.block1>.top>.photo{
|
|
||||||
|
.context > .right > .block1 > .top > .photo {
|
||||||
width: 42%;
|
width: 42%;
|
||||||
padding: .25rem .875rem 1rem .875rem;
|
padding: .25rem 1.5rem 1rem 1.875rem;
|
||||||
}
|
}
|
||||||
.context>.right>.block1>.top>.photo>img{
|
|
||||||
|
.context > .right > .block1 > .top > .photo > img {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
}
|
}
|
||||||
img{
|
|
||||||
|
img {
|
||||||
user-drag: none;
|
user-drag: none;
|
||||||
user-select: none;
|
user-select: none;
|
||||||
-moz-user-select: none;
|
-moz-user-select: none;
|
||||||
-webkit-user-drag: none;
|
-webkit-user-drag: none;
|
||||||
-webkit-user-select: none;
|
-webkit-user-select: none;
|
||||||
-ms-user-select: none;
|
-ms-user-select: none;
|
||||||
}
|
}
|
||||||
#gwnum{
|
|
||||||
|
#gwnum {
|
||||||
padding: .125rem;
|
padding: .125rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.header {
|
||||||
|
height: 1rem;
|
||||||
|
background-image: url(../image/header-bg.png);
|
||||||
|
background-position: center;
|
||||||
|
background-size: 100% 100%;
|
||||||
|
background-repeat: no-repeat;
|
||||||
|
font-size: .5rem;
|
||||||
|
line-height: 1rem;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
|
@ -5,6 +5,7 @@ using StackExchange.Redis;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
|
using System.Security.Cryptography.X509Certificates;
|
||||||
using System.Web;
|
using System.Web;
|
||||||
|
|
||||||
namespace WebAPI.Common
|
namespace WebAPI.Common
|
||||||
|
@ -16,7 +17,9 @@ namespace WebAPI.Common
|
||||||
public static void init(int port)
|
public static void init(int port)
|
||||||
{
|
{
|
||||||
allSockets = new Dictionary<string, IWebSocketConnection>();
|
allSockets = new Dictionary<string, IWebSocketConnection>();
|
||||||
webSocketServer = new WebSocketServer("ws://0.0.0.0:" + port);
|
webSocketServer = new WebSocketServer("wss://0.0.0.0:" + port);
|
||||||
|
//webSocketServer.Certificate = new X509Certificate2("MyCert.pfx","");
|
||||||
|
|
||||||
webSocketServer.Start(socket =>
|
webSocketServer.Start(socket =>
|
||||||
{
|
{
|
||||||
socket.OnOpen = () =>
|
socket.OnOpen = () =>
|
||||||
|
|
|
@ -657,6 +657,49 @@ namespace WebAPI.Controllers
|
||||||
}
|
}
|
||||||
return responeData;
|
return responeData;
|
||||||
}
|
}
|
||||||
|
public Model.ResponeData getAllPersonDataExchange(string projectId)
|
||||||
|
{
|
||||||
|
var responeData = new Model.ResponeData();
|
||||||
|
try
|
||||||
|
{
|
||||||
|
responeData.data = from x in Funs.DB.SitePerson_Person
|
||||||
|
join y in Funs.DB.Base_Unit on x.UnitId equals y.UnitId
|
||||||
|
where x.ProjectId == projectId
|
||||||
|
&& !x.ExchangeTime.HasValue
|
||||||
|
&& x.InTime.HasValue && x.InTime < DateTime.Now
|
||||||
|
&& x.PhotoUrl != null
|
||||||
|
select new
|
||||||
|
{
|
||||||
|
x.PersonId,
|
||||||
|
x.PersonName,
|
||||||
|
x.CardNo,
|
||||||
|
x.IdentityCard,
|
||||||
|
x.UnitId,
|
||||||
|
y.UnitCode,
|
||||||
|
y.UnitName,
|
||||||
|
y.ShortUnitName,
|
||||||
|
Funs.DB.ProjectData_TeamGroup.First(z => z.TeamGroupId == x.TeamGroupId).TeamGroupName,
|
||||||
|
x.Sex,
|
||||||
|
Funs.DB.Base_WorkPost.First(z => z.WorkPostId == x.WorkPostId).WorkPostName,
|
||||||
|
x.Telephone,
|
||||||
|
x.Address,
|
||||||
|
x.InTime,
|
||||||
|
x.AuditorDate,
|
||||||
|
x.ExchangeTime,
|
||||||
|
x.ExchangeTime2,
|
||||||
|
x.PhotoUrl,
|
||||||
|
IsUsed = x.IsUsed.HasValue && x.IsUsed.Value==1? 1 : 0
|
||||||
|
};
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
responeData.code = 0;
|
||||||
|
responeData.message = ex.Message;
|
||||||
|
ErrLogInfo.WriteLog(ex, "WX接口-获取人员下发门禁", "PersonController.getPersonDataExchange");
|
||||||
|
}
|
||||||
|
return responeData;
|
||||||
|
}
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
#region 获取离场人员
|
#region 获取离场人员
|
||||||
|
|
Loading…
Reference in New Issue