Merge branch 'master' of ssh://float.beyondsoft.de/git/beyondSoft/BeWo

This commit is contained in:
staccatomamba
2016-10-21 12:10:01 +02:00
3 changed files with 16 additions and 9 deletions

View File

@@ -1005,8 +1005,10 @@ namespace BeWo.View
Packet a = new Packet();
var guid = Guid.NewGuid();
byte[] outStream = a.GetDataStream(BeWoApp.LoggedOnUser.Employee.PersonOid, 0,
BeWoApp.LoggedOnUser.LoginName, abc, identi, BeWoApp.Tenant, false);
BeWoApp.LoggedOnUser.LoginName, abc, identi, BeWoApp.Tenant, false, true, guid.ToString());
serverStream.Write(outStream, 0, outStream.Length);
serverStream.Flush();
@@ -1228,15 +1230,17 @@ namespace BeWo.View
Packet a = new Packet();
var guid = Guid.NewGuid();
byte[] outStream;
if (type == ChatType.Team)
{
outStream = a.GetDataStream(BeWoApp.LoggedOnUser.Employee.PersonOid, empfängeroid, BeWoApp.LoggedOnUser.LoginName, msg, DataIdentifier.Team, BeWoApp.Tenant, false);
outStream = a.GetDataStream(BeWoApp.LoggedOnUser.Employee.PersonOid, empfängeroid, BeWoApp.LoggedOnUser.LoginName, msg, DataIdentifier.Team, BeWoApp.Tenant, false,true,guid.ToString());
}
else
{
outStream = a.GetDataStream(BeWoApp.LoggedOnUser.Employee.PersonOid, empfängeroid, BeWoApp.LoggedOnUser.LoginName, msg, 0, BeWoApp.Tenant, false);
outStream = a.GetDataStream(BeWoApp.LoggedOnUser.Employee.PersonOid, empfängeroid, BeWoApp.LoggedOnUser.LoginName, msg, 0, BeWoApp.Tenant, false, true, guid.ToString());
}
@@ -2261,13 +2265,15 @@ namespace BeWo.View
byte[] outStream;
var guid = Guid.NewGuid();
if (type == ChatType.Team)
{
outStream = a.GetDataStream(BeWoApp.LoggedOnUser.Employee.PersonOid, empfängeroid, BeWoApp.LoggedOnUser.LoginName, filename, DataIdentifier.Team, BeWoApp.Tenant, false/*,sound,doku,bild*/); // 3 werte
outStream = a.GetDataStream(BeWoApp.LoggedOnUser.Employee.PersonOid, empfängeroid, BeWoApp.LoggedOnUser.LoginName, filename, DataIdentifier.Team, BeWoApp.Tenant, false, true, guid.ToString()/*,sound,doku,bild*/); // 3 werte
}
else
{
outStream = a.GetDataStream(BeWoApp.LoggedOnUser.Employee.PersonOid, empfängeroid, BeWoApp.LoggedOnUser.LoginName, filename,0, BeWoApp.Tenant, false/*,sound,doku,bild*/ );
outStream = a.GetDataStream(BeWoApp.LoggedOnUser.Employee.PersonOid, empfängeroid, BeWoApp.LoggedOnUser.LoginName, filename, 0, BeWoApp.Tenant, false, true, guid.ToString()/*,sound,doku,bild*/ );
}

View File

@@ -1359,7 +1359,7 @@ namespace BeWo.View
{
try
{
var ipAdresse = "192.168.1.103"; //3 |9 || 192.168.1.103"app4.bewoplaner.de"
var ipAdresse = "192.168.1.107"; //3 |9 || 192.168.1.103"app4.bewoplaner.de"
var port = 5000;
var uri = BeWoApp.SiteOfOrigin;
@@ -1444,7 +1444,8 @@ namespace BeWo.View
var a = new Packet();
var outStream = a.GetDataStream(BeWoApp.LoggedOnUser.Employee.PersonOid, 0, BeWoApp.LoggedOnUser.LoginName, formattedMacAddress, DataIdentifier.Login, BeWoApp.Tenant, false);
var guid = Guid.NewGuid();
var outStream = a.GetDataStream(BeWoApp.LoggedOnUser.Employee.PersonOid, 0, BeWoApp.LoggedOnUser.LoginName, formattedMacAddress, DataIdentifier.Login, BeWoApp.Tenant, false, true, guid.ToString());
serverStream.Write(outStream, 0, outStream.Length);
serverStream.Flush();

View File

@@ -120,12 +120,12 @@ namespace BS.Shared
}
public byte[] GetDataStream(long senderPersonOid, long empfaengerPersonoid, string clientName, string message, DataIdentifier dataIdentifier, string tenant, bool isDelivered)
public byte[] GetDataStream(long senderPersonOid, long empfaengerPersonoid, string clientName, string message, DataIdentifier dataIdentifier, string tenant, bool isDelivered, bool IsEmploye, string Messageid)
{
//Bewo-Client spezialisiert
var result = "";
result += senderPersonOid + ";" + empfaengerPersonoid + ";" + clientName.Length + ";" + message.Length + ";" + (int)dataIdentifier + ";" + 0 + ";" + 0 + ";" + tenant + ";" + clientName + message + DateTime.Now.ToString("dd.MM.yyyy HH:mm:ss") + "" + (isDelivered ? 1 : 0);
result += senderPersonOid + ";" + empfaengerPersonoid + ";" + clientName.Length + ";" + message.Length + ";" + (int)dataIdentifier + ";" + 0 + ";" + 0 + ";" + tenant + ";" + (IsEmploye ? 1 : 0) + ";" + Messageid + ";" + clientName + message + DateTime.Now.ToString("dd.MM.yyyy HH:mm:ss") + "" + (isDelivered ? 1 : 0);
return Encoding.UTF8.GetBytes(result);
}