Skip to content

Commit

Permalink
approval changes
Browse files Browse the repository at this point in the history
  • Loading branch information
petrsvihlik committed Oct 26, 2020
1 parent a40f8e6 commit 070d7dd
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 6 deletions.
2 changes: 1 addition & 1 deletion kontent-sample-app-razorpages/.config/dotnet-tools.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"isRoot": true,
"tools": {
"kentico.kontent.modelgenerator": {
"version": "5.0.0-beta2",
"version": "6.0.0",
"commands": [
"KontentModelGenerator"
]
Expand Down
4 changes: 1 addition & 3 deletions kontent-sample-app-razorpages/Models/Article.Generated.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@

using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using Kentico.Kontent.Delivery.Abstractions;

namespace kontent_sample_app_razorpages.Models
Expand Down Expand Up @@ -36,7 +35,7 @@ public partial class Article
public const string TitleCodename = "title";
public const string UrlPatternCodename = "url_pattern";

public string BodyCopy { get; set; }
public IRichTextContent BodyCopy { get; set; }
public string MetadataMetaDescription { get; set; }
public string MetadataMetaTitle { get; set; }
public string MetadataOgDescription { get; set; }
Expand All @@ -50,7 +49,6 @@ public partial class Article
public string MetaDescription { get; set; }
public string MetaKeywords { get; set; }
public IEnumerable<ITaxonomyTerm> Personas { get; set; }
[DisplayFormat(DataFormatString = "{0:MMM. dd, yyyy}")]
public DateTime? PostDate { get; set; }
public IEnumerable<object> RelatedArticles { get; set; }
public IEnumerable<ITaxonomyTerm> Sitemap { get; set; }
Expand Down
3 changes: 3 additions & 0 deletions kontent-sample-app-razorpages/Models/Article.cs
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
using System;
using System.Collections.Generic;
using Kentico.Kontent.Delivery.Abstractions;
using Newtonsoft.Json;

namespace kontent_sample_app_razorpages.Models
{
public partial class Article
{
[JsonProperty("body_copy")]
public string BodyCopyString { get; set; }
}
}
2 changes: 1 addition & 1 deletion kontent-sample-app-razorpages/Pages/Articles/Detail.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
</div>
<div class="row">
<div class="article-detail-content">
@Html.Raw(Model.Article.BodyCopy)
@Html.Raw(Model.Article.BodyCopyString)
</div>
</div>
</article>
Expand Down
2 changes: 1 addition & 1 deletion kontent-sample-app-razorpages/Tools/GenerateModels.ps1
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
dotnet tool restore
$OUTPUT_PATH = Join-Path $PSScriptRoot "..\Models"
dotnet tool run KontentModelGenerator -p "975bf280-fd91-488c-994c-2f04416e5ee3" -o $OUTPUT_PATH -n "kontent_sample_app_razorpages.Models" -g=false -s=true
dotnet tool run KontentModelGenerator -p "975bf280-fd91-488c-994c-2f04416e5ee3" -o $OUTPUT_PATH -n "kontent_sample_app_razorpages.Models" -s=true
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
<AspNetCoreHostingModel>InProcess</AspNetCoreHostingModel>
<RootNamespace>kontent_sample_app_razorpages</RootNamespace>
<AssemblyName>kontent-sample-app-razorpages</AssemblyName>
<UserSecretsId>fdbd2a40-72c9-4f17-9a13-bffb343ae2ea</UserSecretsId>
</PropertyGroup>


Expand Down

0 comments on commit 070d7dd

Please sign in to comment.