intermediat commit
This commit is contained in:
@@ -277,6 +277,7 @@
|
||||
<shell:ApplicationBarMenuItem Text="Setting4" Click="ApplicationBarMenuItem4_Click"/>
|
||||
<shell:ApplicationBarMenuItem Text="Setting4" Click="ApplicationBarMenuItem5_Click"/>
|
||||
<shell:ApplicationBarMenuItem Text="Setting5" Click="ApplicationBarMenuItem_Click_1"/>
|
||||
<shell:ApplicationBarMenuItem Text="NFC" Click="ApplicationBarMenuItem_Click_2"/>
|
||||
</shell:ApplicationBar.MenuItems>
|
||||
</shell:ApplicationBar>
|
||||
</phone:PhoneApplicationPage.ApplicationBar>
|
||||
|
||||
@@ -419,6 +419,8 @@ namespace CampusAppWP8.Pages
|
||||
}
|
||||
else
|
||||
{
|
||||
this.GoToAppointment(nfcContent);
|
||||
/* removed for testing
|
||||
if (AppSettings.BTUTagDefaultHandler.CampusMap == Settings.AppSetting.TagDefaultHandler)
|
||||
{
|
||||
// search for placeId
|
||||
@@ -435,6 +437,7 @@ namespace CampusAppWP8.Pages
|
||||
this.ShowBtuTagMessageBox();
|
||||
}
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
this.ndefId = this.device.SubscribeForMessage(Constants.NCFMessageType_NDEF, this.NDEFHandler);
|
||||
@@ -446,9 +449,27 @@ namespace CampusAppWP8.Pages
|
||||
private void GoToCampusMappage(string tagContent)
|
||||
{
|
||||
string pid = Wp8StringManager.FilterPlaceIdinNFCResultString(tagContent);
|
||||
string urlString = Constants.PathCampusmap_Campusmap;
|
||||
urlString += "?" + Constants.ParamModelMap_SearchTermAlias + "=" + pid;
|
||||
Uri url = new Uri(urlString as string, UriKind.Relative);
|
||||
string urlString = Constants.PathCampusmap_Campusmap + "?" + Constants.ParamModelMap_SearchTermAlias + "=" + pid;
|
||||
Uri url = new Uri(urlString, UriKind.Relative);
|
||||
|
||||
if (this.Dispatcher != null)
|
||||
{
|
||||
this.Dispatcher.BeginInvoke(new Action(() => NavigationService.Navigate(url)));
|
||||
}
|
||||
else
|
||||
{
|
||||
NavigationService.Navigate(url);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary> Go to appointment. </summary>
|
||||
/// <remarks> Fiedler, 15.11.2013. </remarks>
|
||||
/// <param name="tagContent"> The tag content. </param>
|
||||
private void GoToAppointment(string tagContent)
|
||||
{
|
||||
string pid = Wp8StringManager.FilterPlaceIdinNFCResultString(tagContent);
|
||||
string urlStr = Constants.PathTimeTable_AppointmentEdit + "?" + Constants.ParamPID + "=" + pid;
|
||||
Uri url = new Uri(urlStr, UriKind.Relative);
|
||||
|
||||
if (this.Dispatcher != null)
|
||||
{
|
||||
@@ -483,5 +504,11 @@ namespace CampusAppWP8.Pages
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private void ApplicationBarMenuItem_Click_2(object sender, EventArgs e)
|
||||
{
|
||||
Uri url = new Uri("/Pages/Dev/NFC.xaml", UriKind.Relative);
|
||||
NavigationService.Navigate(url);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -24,6 +24,8 @@ namespace CampusAppWP8.Pages.TimeTable
|
||||
|
||||
public partial class AppointmentEdit : PortraitLandscapePage
|
||||
{
|
||||
//private Place
|
||||
|
||||
private readonly string[] DurationListText = new string[] { "15 Minuten", "30 Minuten", "1 Stunde", "90 Minuten", "2 Stunden", "Ganztägig", "Benutzerdefiniert" };
|
||||
private readonly string[] RepeatListText = new string[] { "Einmal", "Täglich", "Jeden Mo-Fr", "Wöchentlich", "Monatlich", "Jährlich" };
|
||||
private readonly string[] AccessClassListText = new string[] { "Öffentlich", "Privat", "Vertraulich" };
|
||||
@@ -61,8 +63,10 @@ namespace CampusAppWP8.Pages.TimeTable
|
||||
base.OnNavigatedTo(e);
|
||||
|
||||
string appointmentIndexStr = string.Empty;
|
||||
string pid = string.Empty;
|
||||
|
||||
// Navigate to the selected pivotitem
|
||||
|
||||
if (NavigationContext.QueryString.TryGetValue(Constants.Param_Appointment_Index, out appointmentIndexStr))
|
||||
{
|
||||
this.appointmentIndex = int.Parse(appointmentIndexStr);
|
||||
@@ -89,6 +93,11 @@ namespace CampusAppWP8.Pages.TimeTable
|
||||
MessageBox.Show("ERROR: appointment index out of range!!! (" + o + ")");
|
||||
}
|
||||
}
|
||||
else if(NavigationContext.QueryString.TryGetValue(Constants.ParamPID, out pid))
|
||||
{
|
||||
this.HeadLine.Text = AppResources.Creating;
|
||||
this.InLocation.Text = pid;
|
||||
}
|
||||
else
|
||||
{
|
||||
this.HeadLine.Text = AppResources.Creating;
|
||||
|
||||
@@ -597,4 +597,7 @@
|
||||
<data name="FileAppointments_Name" xml:space="preserve">
|
||||
<value>Appointments.xaml</value>
|
||||
</data>
|
||||
<data name="ParamPID" xml:space="preserve">
|
||||
<value>pid</value>
|
||||
</data>
|
||||
</root>
|
||||
@@ -717,6 +717,15 @@ namespace CampusAppWP8.Resources {
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die pid ähnelt.
|
||||
/// </summary>
|
||||
public static string ParamPID {
|
||||
get {
|
||||
return ResourceManager.GetString("ParamPID", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die pivotindex ähnelt.
|
||||
/// </summary>
|
||||
|
||||
Reference in New Issue
Block a user