Implemented specific post data

main
Inga 🏳‍🌈 14 years ago
parent fa3dd2c456
commit 5a0d5f5d07
  1. 2
      Builder/IISMainHandler/build.txt
  2. 12
      Common/dataobjects/Post.cs
  3. 33
      templates/Full/elems/PostInfo.xslt

@ -187,8 +187,6 @@ namespace FLocal.Common.dataobjects {
new XElement("id", this.id),
new XElement("poster", this.poster.exportToXmlForViewing(context)),
new XElement("postDate", this.postDate.ToXml()),
new XElement("lastChangeDate", this.lastChangeDate.ToXml()),
new XElement("revision", this.revision.ToString()),
new XElement("layerId", this.layerId),
new XElement("layerName", this.layer.name),
new XElement("title", this.title),
@ -196,7 +194,15 @@ namespace FLocal.Common.dataobjects {
//this.XMLBody(context),
new XElement("bodyShort", this.bodyShort),
new XElement("threadId", this.threadId),
new XElement("isOwner", ((context.account != null) && (this.poster.id == context.account.user.id)).ToPlainString())
new XElement("isOwner", ((context.account != null) && (this.poster.id == context.account.user.id)).ToPlainString()),
new XElement(
"specific",
new XElement(
"changeInfo",
new XElement("lastChangeDate", this.lastChangeDate.ToXml()),
new XElement("revision", this.revision.ToString())
)
)
);
if(includeParentPost) {
if(this.parentPostId.HasValue) {

@ -123,22 +123,7 @@
</font>
</td>
</tr>
<xsl:if test="revision">
<xsl:if test="(revision != '') and (revision != '0')">
<tr>
<td>
<font size="-2">
<xsl:text>Ýòî ñîîáùåíèå áûëî îòðåäàêòèðîâàíî ïîëüçîâàòåëåì </xsl:text>
<xsl:value-of select="revision"/>
<xsl:text> ðàç, ïîñëåäíèé ðàç </xsl:text>
<xsl:apply-templates select="lastChangeDate/date" mode="dateTime"/>
<br/>
<br/>
</font>
</td>
</tr>
</xsl:if>
</xsl:if>
<xsl:apply-templates select="specific"/>
<xsl:if test="poster/user/signature != ''">
<tr>
<td>
@ -156,5 +141,21 @@
</tr>
</xsl:template>
<xsl:template match="specific/changeInfo">
<xsl:if test="(revision != '') and (revision != '0')">
<tr>
<td>
<font size="-2">
<xsl:text>Ýòî ñîîáùåíèå áûëî îòðåäàêòèðîâàíî ïîëüçîâàòåëåì </xsl:text>
<xsl:value-of select="revision"/>
<xsl:text> ðàç, ïîñëåäíèé ðàç </xsl:text>
<xsl:apply-templates select="lastChangeDate/date" mode="dateTime"/>
<br/>
<br/>
</font>
</td>
</tr>
</xsl:if>
</xsl:template>
</xsl:stylesheet>
Loading…
Cancel
Save