using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace JinYuan.VirtualDataLibrary
{
public class MesConfig
{
///
/// 工厂代码
///
public string siteCode = "";
///
/// 产线编号
///
public string lineCode = "";
///
/// 设备编号
///
public string equipNum = "";
///
/// 客户料号
///
public string CustomerPartNum = "";
///
/// 容器编码
///
public string containerCode = "";
///
/// MES密码
///
public string mesPwd = "";
///
/// MES账户
///
public string mesUserName = "";
///
/// 电表编号
///
public List electricMeterNum = new List();
///
/// 风速仪个数
///
public int AntiDustAirSpeedCount = 0;
///
/// 风速仪编号
///
public List listAntiDustAirSpeedNum = new List();
///
/// 权限
///
public string userLevel = "";
///
/// mes返回权限
///
public string mesUserLevel = "";
///
/// 物料编码
///
public string MaterialCode = "";
///
/// 生产型号
///
public string ModelName = "";
private Dictionary modelMapping = new Dictionary()
{
{ "MB36", 1 },
{ "MB31", 2 },
{ "MB56", 3 }
};
///
/// 将电池型号转换成下发PLC的型号编号
///
///
///
public int GetModel(string modelName)
{
if (modelMapping.TryGetValue(modelName, out int result))
{
return result; // 键存在,返回对应值
}
// 键不存在,返回0
return 0;
}
///
/// 客户类型
///
public string customerType = "";
///
/// 是否上传MES
///
public bool isUpMes = false;
///
/// MES接口URL地址中的IP地址
///
public string MESURLAddressIP = "10.100.111.81";
///
/// MES接口URL地址中的端口号
///
public string MESURLAddressPort = "80";
///
/// 是否连接MES
///
public bool isConnected = false;
///
/// 是否刷卡?
///
public bool Isshuaka = false;
///
/// 是否登录成功?
///
public bool IsLoginOK = false;
///
/// 是否登录MES成功?
///
public bool IsLoginMesOK = false;
///
/// 获取MES参数
///
public bool IsMesParam = false;
///
/// MES超时
///
public long MesOutTime = 0;
///
/// 焊接点个数
///
public int weldNum = 0;
///
/// 是否2个电表(此功能仅适用于908-6负极焊接两台设备共用一台敢接机只有一个电表)
///
public bool IsTwoDianBiao = false;
///
/// 电表编号
///
public string ElectricMeterNum = "";
///
/// 除尘风速
///
public decimal antiDustAirSpeed = 0;
///
/// 电机旋转速度
///
public decimal dianjiXzSpeed = 0;
///
/// 设备状态上传时间
///
public int EquStatuasTime = 0;
///
/// 获取服务器数据
///
public bool IsGet_Server = true;
///
/// 生成假数据
///
public bool IsDebug = true;
///
/// 卡板托盘计数
///
public int CoreCount = 0;
///
/// 卡板托盘生成时间
///
public string CardTime = "";
///
/// 卡板码是否发送成功
///
public bool CardSuccess = false;
///
/// 原材料上料位置
///
public string materialLotCodeLocator = "";
///
/// 存储服务器IP地址
///
public string RotueServerIP = "192.168.2.108";
///
/// 员工权限校验
///
public string EmployeeAuthCheck = "http://10.100.111.81/core/api/public/equipment/base/user/permission/verify";
/////
///// 原材料投入信息
/////
//public string MaterialInputInfo = "http://10.100.111.81/core/api/public/raw/material/input/un/first/process";
///
/// 设备参数设定值请求
///
public string DeviceParamRequest = "http://10.100.111.81/core/api/public/param/setting/request";
///
/// 设备参数设定值变更
///
public string DeviceParamChange = "http://10.100.111.81/core/api/public/param/setting/change";
///
/// 箱唛信息获取
///
public string queryCartonUrl = "http://10.100.111.81/core/api/public/equip/auto/cartonquery";
///
/// 栈板信息获取
///
public string queryPalletUrl = "http://10.100.111.81/core/api/public/equip/auto/palletquery";
///
/// 客户标签与系统标签绑定
///
public string bindingUrl = "http://10.100.111.81/core/api/public/equip/auto/customer/bind";
///
/// 设备报警信息
///
public string DeviceAlarm = "http://10.100.111.81/core/api/public/equipment/alarm/currency";
///
/// 设备运行状态
///
public string DeviceStatus = "http://10.100.111.81/core/api/public/eve/pm/eqm/run/status/operation";
///
/// 能耗数据
///
public string EnergyConsumption = "http://10.100.111.81/core/api/public/eve/pm/energy/consumption/collection/submit";
///
/// 设备风速接口
///
public string Anemometer = "https://iot.eveportal.com:9470/eve_api/ems/iot/upload_device_collect_data";
/////
///// 进出站一体模式×
/////
//public string InAndOutStationMesUrl = "http://10.17.96.73/core/api/public/14j/out/station/process/turn-in-out";
///
/// appId
///
public string AppID = "e36ef900320d442f850913e2ebc1d7a1";
///
/// AppKey
///
public string AppKey = "8279ce76217245f48c0cc495c09124a3";
///
/// 获取TOKEN
///
public string GetTokenUrl = "https://esb.evebattery.com:13502/gateway/ewms-eu/openapi/oauth/token";
}
}