diff --git a/AddOrChangeAssetPage.xaml.cs b/AddOrChangeAssetPage.xaml.cs index a00294a..176e611 100644 --- a/AddOrChangeAssetPage.xaml.cs +++ b/AddOrChangeAssetPage.xaml.cs @@ -112,9 +112,11 @@ private async void ButtonSubmit_Click(object sender, RoutedEventArgs e) a.StartDate = (this.DatePickerStart.Date.Date + this.TimePickerStart.Time).ToUniversalTime(); a.EndDate = (this.DatePickerEnd.Date.Date + this.TimePickerEnd.Time).ToUniversalTime(); a.Duration = this.TextBoxDuration.Text; - a.IsEnabled = this.ToggleSwitchEnable.IsOn ? "1" : "0"; - a.NoCache = this.ToggleSwitchDisableCache.IsOn ? "1" : "0"; + a.IsEnabled = this.ToggleSwitchEnable.IsOn ? 1 : 0; + a.NoCache = this.ToggleSwitchDisableCache.IsOn ? 1 : 0; a.Mimetype = this.ComboBoxAssetType.SelectedValue as string; + a.SkipAssetCheck = 1; + a.IsProcessing = 0; var dialog = new MessageDialog(this.Loader.GetString("ConfirmationAddAsset")); diff --git a/Asset.cs b/Asset.cs index 9ebd070..c4cde81 100644 --- a/Asset.cs +++ b/Asset.cs @@ -21,22 +21,28 @@ public class Asset public DateTime EndDate { get; set; } [Newtonsoft.Json.JsonProperty(PropertyName = "is_enabled")] - public string IsEnabled { get; set; } + public Int32 IsEnabled { get; set; } + + [Newtonsoft.Json.JsonProperty(PropertyName = "is_processing")] + public Int32? IsProcessing { get; set; } + + [Newtonsoft.Json.JsonProperty(PropertyName = "skip_asset_check")] + public Int32 SkipAssetCheck { get; set; } [Newtonsoft.Json.JsonIgnore] public bool IsEnabledSwitch { get { - return IsEnabled.Equals("1") ? true : false; + return IsEnabled.Equals(1) ? true : false; } } [Newtonsoft.Json.JsonProperty(PropertyName = "nocache")] - public string NoCache { get; set; } + public Int32 NoCache { get; set; } [Newtonsoft.Json.JsonProperty(PropertyName = "is_active")] - public Boolean IsActive { get; set; } + public Int32 IsActive { get; set; } private string _Uri; diff --git a/Device.cs b/Device.cs index 6972cef..46ca9c3 100644 --- a/Device.cs +++ b/Device.cs @@ -24,7 +24,7 @@ public ObservableCollection ActiveAssets { get { - return new ObservableCollection(this.Assets.FindAll(x => x.IsActive)); + return new ObservableCollection(this.Assets.FindAll(x => x.IsActive.Equals(1))); } } @@ -33,7 +33,7 @@ public ObservableCollection InactiveAssets { get { - return new ObservableCollection(this.Assets.FindAll(x => !x.IsActive)); + return new ObservableCollection(this.Assets.FindAll(x => x.IsActive.Equals(0))); } } diff --git a/MainPage.xaml.cs b/MainPage.xaml.cs index 8535d06..ae07a74 100644 --- a/MainPage.xaml.cs +++ b/MainPage.xaml.cs @@ -238,7 +238,7 @@ private async void ToggleSwitchEnable_Toggled(object sender, Windows.UI.Xaml.Rou { currentAsset.StartDate = currentAsset.StartDate.ToUniversalTime(); currentAsset.EndDate = currentAsset.EndDate.ToUniversalTime(); - currentAsset.IsEnabled = (sender as ToggleSwitch).IsOn ? "1" : "0"; + currentAsset.IsEnabled = (sender as ToggleSwitch).IsOn ? 1 : 0; await this.CurrentDevice.UpdateAssetAsync(currentAsset); this.RefreshAssetsForCurrentDeviceAsync(); } diff --git a/Package.appxmanifest b/Package.appxmanifest index 7e09d7e..44a68ec 100644 --- a/Package.appxmanifest +++ b/Package.appxmanifest @@ -1,6 +1,6 @@  - + ScreenlyManager diff --git a/ScreenlyManager.csproj b/ScreenlyManager.csproj index b0896b1..6683ae3 100644 --- a/ScreenlyManager.csproj +++ b/ScreenlyManager.csproj @@ -11,7 +11,7 @@ ScreenlyManager en-US UAP - 10.0.14393.0 + 10.0.17763.0 10.0.10240.0 14 512 @@ -22,6 +22,10 @@ Always x86|x64|arm 0B29CE2394A65C25639F4C5661053DEB3599C892 + win10-arm;win10-arm-aot;win10-x86;win10-x86-aot;win10-x64;win10-x64-aot + False + 1 + OnApplicationRun true @@ -94,7 +98,6 @@ - @@ -192,6 +195,14 @@ Designer + + + 5.2.2 + + + 9.0.1 + + 14.0 diff --git a/project.json b/project.json deleted file mode 100644 index 21494af..0000000 --- a/project.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "dependencies": { - "Microsoft.NETCore.UniversalWindowsPlatform": "5.2.2", - "Newtonsoft.Json": "9.0.1" - }, - "frameworks": { - "uap10.0": {} - }, - "runtimes": { - "win10-arm": {}, - "win10-arm-aot": {}, - "win10-x86": {}, - "win10-x86-aot": {}, - "win10-x64": {}, - "win10-x64-aot": {} - } -} \ No newline at end of file