'Send PM' link implemented on user info page

main
Inga 🏳‍🌈 15 years ago
parent 35111961a9
commit 0875cdc583
  1. 2
      Builder/IISMainHandler/build.txt
  2. 2
      Builder/IISUploadHandler/build.txt
  3. 6
      IISMainHandler/handlers/response/PMSendHandler.cs
  4. 10
      templates/Full/PMSend.xslt
  5. 3
      templates/Full/UserInfo.xslt

@ -19,6 +19,12 @@ namespace FLocal.IISHandler.handlers.response {
} }
override protected XElement[] getSpecificData(WebContext context) { override protected XElement[] getSpecificData(WebContext context) {
if(context.requestParts.Length > 1) {
Account account = Account.LoadById(int.Parse(context.requestParts[1]));
return new XElement[] {
new XElement("receiver", account.exportToXml(context)),
};
}
return new XElement[0]; return new XElement[0];
} }
} }

@ -24,7 +24,17 @@
<xsl:value-of select="session/user/name"/> <xsl:value-of select="session/user/name"/>
<br/> <br/>
<xsl:text>Ïîëó÷àòåëü: </xsl:text> <xsl:text>Ïîëó÷àòåëü: </xsl:text>
<xsl:choose>
<xsl:when test="receiver">
<input type="hidden" name="receiverId">
<xsl:attribute name="value"><xsl:value-of select="receiver/account/id"/></xsl:attribute>
</input>
<xsl:value-of select="receiver/account/user/name"/>
</xsl:when>
<xsl:otherwise>
<input type="text" name="receiverName" class="formboxes" size="15"/> <input type="text" name="receiverName" class="formboxes" size="15"/>
</xsl:otherwise>
</xsl:choose>
<br/> <br/>
<br/> <br/>
<xsl:text>Òåìà: </xsl:text> <xsl:text>Òåìà: </xsl:text>

@ -181,6 +181,9 @@
<tr> <tr>
<td valign="top" colspan="3" align="center" class="darktable"> <td valign="top" colspan="3" align="center" class="darktable">
<a> <a>
<xsl:if test="accountId">
<xsl:attribute name="href">/PMSend/<xsl:value-of select="accountId"/>/</xsl:attribute>
</xsl:if>
<img src="/static/images/sendprivate.gif" border="0" style="vertical-align: text-bottom" /> <img src="/static/images/sendprivate.gif" border="0" style="vertical-align: text-bottom" />
<xsl:text> Ïîñëàòü ëè÷íîå ñîîáùåíèå</xsl:text> <xsl:text> Ïîñëàòü ëè÷íîå ñîîáùåíèå</xsl:text>
</a> </a>

Loading…
Cancel
Save