diff --git a/CampusAppWP8/CampusAppWP8/CampusAppWP8.csproj b/CampusAppWP8/CampusAppWP8/CampusAppWP8.csproj
index d7e97cf6..d3a8f03c 100644
--- a/CampusAppWP8/CampusAppWP8/CampusAppWP8.csproj
+++ b/CampusAppWP8/CampusAppWP8/CampusAppWP8.csproj
@@ -118,6 +118,8 @@
+
+
diff --git a/CampusAppWP8/CampusAppWP8/Model/Person/PersonFunctionModel.cs b/CampusAppWP8/CampusAppWP8/Model/Person/PersonFunctionModel.cs
new file mode 100644
index 00000000..79c19cb0
--- /dev/null
+++ b/CampusAppWP8/CampusAppWP8/Model/Person/PersonFunctionModel.cs
@@ -0,0 +1,97 @@
+using CampusAppWP8.Resources;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Text.RegularExpressions;
+using System.Xml.Serialization;
+
+namespace CampusAppWP8.Model.Person
+{
+ public class PersonFunctionModel
+ {
+ private string tel1;
+
+ private string tel2;
+
+ private string fax;
+
+ [XmlAttribute("telefon")]
+ public string Tel1
+ {
+ get
+ {
+ return this.tel1;
+ }
+ set
+ {
+ if (value != null && value != this.tel1)
+ {
+ this.tel1 = this.CreateUniTelefonNumber(value);
+ }
+ }
+ }
+
+ [XmlAttribute("telefon2")]
+ public string Tel2
+ {
+ get
+ {
+ return this.tel2;
+ }
+ set
+ {
+ if (value != null && value != this.tel2)
+ {
+ this.tel2 = this.CreateUniTelefonNumber(value);
+ }
+ }
+ }
+
+ [XmlAttribute("fax")]
+ public string Fax
+ {
+ get
+ {
+ return this.fax;
+ }
+ set
+ {
+ if (value != null && value != this.fax)
+ {
+ this.fax = this.CreateUniTelefonNumber(value);
+ }
+ }
+ }
+
+ [XmlAttribute("funktion")]
+ public string Function { get; set; }
+
+ [XmlAttribute("einrichtung")]
+ public string Appointment { get; set; }
+
+ [XmlAttribute("gebaeude")]
+ public string Building { get; set; }
+
+ [XmlAttribute("mail")]
+ public string Mail { get; set; }
+
+ private string CreateUniTelefonNumber (string input)
+ {
+ string result = null;
+ if (input.Length < 5)
+ {
+ result = Constants.UniCBTelPrefix + input.TrimStart('0');
+ }
+ else
+ {
+ result = input;
+ }
+
+ Regex regexObj = new Regex(@"[^\d]");
+ result = regexObj.Replace(this.tel1.TrimStart('0'), "");
+ result = Constants.DeTelPrefix + result;
+ return result;
+ }
+ }
+}
diff --git a/CampusAppWP8/CampusAppWP8/Model/Person/PersonModel.cs b/CampusAppWP8/CampusAppWP8/Model/Person/PersonModel.cs
new file mode 100644
index 00000000..e5cc4d8d
--- /dev/null
+++ b/CampusAppWP8/CampusAppWP8/Model/Person/PersonModel.cs
@@ -0,0 +1,28 @@
+using System;
+using System.Collections.Generic;
+using System.Collections.ObjectModel;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Xml.Serialization;
+
+namespace CampusAppWP8.Model.Person
+{
+ public class PersonModel
+ {
+ [XmlAttribute("id")]
+ public string ID {get; set;}
+
+ [XmlAttribute("akadgrad")]
+ public string Akadgrad { get; set; }
+
+ [XmlAttribute("nachname")]
+ public string SureName { get; set; }
+
+ [XmlAttribute("vorname")]
+ public string FirstName { get; set; }
+
+ [XmlElement("funktion")]
+ public ObservableCollection Function { get; set; }
+ }
+}
diff --git a/CampusAppWP8/CampusAppWP8/Resources/Constants.Designer.cs b/CampusAppWP8/CampusAppWP8/Resources/Constants.Designer.cs
index f6c8c704..d4c18d60 100644
--- a/CampusAppWP8/CampusAppWP8/Resources/Constants.Designer.cs
+++ b/CampusAppWP8/CampusAppWP8/Resources/Constants.Designer.cs
@@ -132,6 +132,15 @@ namespace CampusAppWP8.Resources {
}
}
+ ///
+ /// Sucht eine lokalisierte Zeichenfolge, die +49 ähnelt.
+ ///
+ public static string DeTelPrefix {
+ get {
+ return ResourceManager.GetString("DeTelPrefix", resourceCulture);
+ }
+ }
+
///
/// Sucht eine lokalisierte Zeichenfolge, die ExamsPage.LastPivotIndex ähnelt.
///
@@ -843,6 +852,15 @@ namespace CampusAppWP8.Resources {
}
}
+ ///
+ /// Sucht eine lokalisierte Zeichenfolge, die 035569 ähnelt.
+ ///
+ public static string UniCBTelPrefix {
+ get {
+ return ResourceManager.GetString("UniCBTelPrefix", resourceCulture);
+ }
+ }
+
///
/// Sucht eine lokalisierte Zeichenfolge, die http://www.tu-cottbus.de/campusapp-data/professorships.xml ähnelt.
///
diff --git a/CampusAppWP8/CampusAppWP8/Resources/Constants.resx b/CampusAppWP8/CampusAppWP8/Resources/Constants.resx
index 963649e2..ef787291 100644
--- a/CampusAppWP8/CampusAppWP8/Resources/Constants.resx
+++ b/CampusAppWP8/CampusAppWP8/Resources/Constants.resx
@@ -453,4 +453,10 @@
/Pages/Person/PersonPage.xaml
+
+ +49
+
+
+ 035569
+
\ No newline at end of file