eDosWeb/safety/OverzichtLRM.aspx.cs
Luc Vandenbroucke ee9fa6be65 first
2018-12-13 09:09:17 +01:00

58 lines
No EOL
1.6 KiB
C#

using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
namespace safety
{
public partial class OverzichtLRM : System.Web.UI.Page
{
protected string bunkerStatus2(object bunkerColor)
{
string s = "led-red.gif";
if (bunkerColor is byte || bunkerColor is int ) switch (Convert.ToInt32(bunkerColor))
{
case 0: s = "led-black.gif"; break;
case 1: s = "led-green.gif"; break;
case 2: s = "led-yellow.gif"; break;
case 3: s = "led-red.gif"; break;
case 4: s = "led-blue.gif"; break;
case 5: s = "icon_radiation.gif"; break;
}
return "images/" + s;
}
protected string bunkerStatus(object daysleft)
{
string s = "led-red.gif";
try
{
int dl = (int)daysleft;
if (dl > 0)
if (dl < 7) s = "led-blink.gif";
else s = "led-green.gif";
}
catch
{
s = "led-black.gif";
}
return "images/" + s;
}
protected string gc(object o)
{
if (o is System.Boolean && ((System.Boolean)o) == true)
return "images/icon_radiation.gif";
else
return "images/separator.gif";
}
protected void Page_Load(object sender, EventArgs e)
{
}
}
}