first commit
This commit is contained in:
@@ -0,0 +1,121 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<LabelType>博客类</LabelType>
|
||||
<LabelIntro>
|
||||
</LabelIntro>
|
||||
<OutType>sin</OutType>
|
||||
<LabelDataType>sql_sysquery</LabelDataType>
|
||||
<EnabelAjax>False</EnabelAjax>
|
||||
<Version officialVersion="" modifiedVersions="2919" compatibleVersion="" />
|
||||
<attributes>
|
||||
<name>linkOpenType</name>
|
||||
<datatype>string</datatype>
|
||||
<default>_blank</default>
|
||||
<intro>打开方式:默认为新窗口打开</intro>
|
||||
</attributes>
|
||||
<attributes>
|
||||
<name>listOrderType</name>
|
||||
<datatype>int</datatype>
|
||||
<default>1</default>
|
||||
<intro>排序方式:1按推荐级降序、2按博客ID升序、3按博客ID降序、4按创建时间升序、5按创建时间降序</intro>
|
||||
</attributes>
|
||||
<IsXsltSql>true</IsXsltSql>
|
||||
<IsXsltCountSql>false</IsXsltCountSql>
|
||||
<LabelSqlString><![CDATA[<?xml version="1.0" encoding="utf-8"?>
|
||||
<xsl:transform version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
|
||||
<xsl:param name="listOrderType" />
|
||||
<xsl:output method="xml" />
|
||||
<xsl:template match="/">
|
||||
<root>
|
||||
<xsl:variable name="order"><xsl:choose>
|
||||
<xsl:when test="$listOrderType!=''">
|
||||
<xsl:if test="$listOrderType=1">EliteLevel DESC,BlogID DESC</xsl:if>
|
||||
<xsl:if test="$listOrderType=2">BlogID ASC</xsl:if>
|
||||
<xsl:if test="$listOrderType=3">BlogID DESC</xsl:if>
|
||||
<xsl:if test="$listOrderType=4">CreateTime ASC</xsl:if>
|
||||
<xsl:if test="$listOrderType=5">CreateTime DESC</xsl:if></xsl:when>
|
||||
<xsl:otherwise>BlogID DESC</xsl:otherwise></xsl:choose></xsl:variable>
|
||||
<sql>
|
||||
EXEC [dbo].[PR_Common_PagingLarge] 'PE_BG_Blog','BlogID','*',@pagesize,@startrow ,'State = 1','','<xsl:value-of select="$order"/>'
|
||||
</sql>
|
||||
<sqlpage>
|
||||
</sqlpage>
|
||||
<countsql>
|
||||
</countsql>
|
||||
</root>
|
||||
</xsl:template>
|
||||
</xsl:transform>]]></LabelSqlString>
|
||||
<LabelTemplate>
|
||||
<![CDATA[<?xml version="1.0" encoding="utf-8"?>
|
||||
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:pe="labelproc" exclude-result-prefixes="pe">
|
||||
<xsl:param name="linkOpenType" />
|
||||
<xsl:param name="blogNameLength" />
|
||||
<xsl:param name="nickNameLength" />
|
||||
<xsl:param name="introLength" />
|
||||
<xsl:param name="imageWidth" />
|
||||
<xsl:param name="imageHeight" />
|
||||
<xsl:variable name="countnum" select="count(/NewDataSet/Table)"/>
|
||||
<xsl:output method="html" />
|
||||
<xsl:template match="/">
|
||||
<xsl:choose><xsl:when test="$countnum = 0">暂时没有信息!</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:for-each select="/NewDataSet/Table">
|
||||
<li>
|
||||
<xsl:if test="(position() = $countnum)and(position() mod 3 !=0)">
|
||||
<xsl:attribute name="class">lastOne</xsl:attribute>
|
||||
</xsl:if>
|
||||
<a href="{pe:InstallDir()}Blog/UserIndex.aspx?id={BlogID}" target="{$linkOpenType}" title="{BlogName}" class="pic">
|
||||
<img alt="{BlogName}" title="{BlogName}" width="{$imageWidth}" height="{$imageHeight}" target="{$linkOpenType}">
|
||||
<xsl:attribute name="src">
|
||||
<xsl:choose>
|
||||
<xsl:when test="Face!=''">
|
||||
<xsl:value-of select="pe:ConvertToAbsolutePath(Face)"/>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:value-of select="pe:SkinDir()"/>Blog/images/nopic.png
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:attribute>
|
||||
</img></a>
|
||||
<a href="{pe:InstallDir()}Blog/UserIndex.aspx?id={BlogID}" target="{$linkOpenType}" title="{BlogName}"><h4><xsl:value-of select="pe:CutText(Nickname,$nickNameLength,'')"/></h4></a>
|
||||
<p><xsl:value-of select="pe:CutText(Intro,$introLength,'')"/></p>
|
||||
</li>
|
||||
</xsl:for-each>
|
||||
</xsl:otherwise></xsl:choose>
|
||||
</xsl:template>
|
||||
</xsl:stylesheet>]]></LabelTemplate>
|
||||
<attributes>
|
||||
<name>blogNameLength</name>
|
||||
<datatype>int</datatype>
|
||||
<default>10</default>
|
||||
<intro>博客名称长度</intro>
|
||||
</attributes>
|
||||
<attributes>
|
||||
<name>nickNameLength</name>
|
||||
<datatype>string</datatype>
|
||||
<default>18</default>
|
||||
<intro>昵称名称长度</intro>
|
||||
</attributes>
|
||||
<attributes>
|
||||
<name>imageWidth</name>
|
||||
<datatype>int</datatype>
|
||||
<default>54</default>
|
||||
<intro>图片宽度</intro>
|
||||
</attributes>
|
||||
<attributes>
|
||||
<name>imageHeight</name>
|
||||
<datatype>int</datatype>
|
||||
<default>54</default>
|
||||
<intro>图片高度</intro>
|
||||
</attributes>
|
||||
<UsePage>True</UsePage>
|
||||
<LabelSqlCount>SELECT COUNT(BlogID) FROM PE_BG_Blog WHERE State = 1</LabelSqlCount>
|
||||
<LabelSqlPage>
|
||||
</LabelSqlPage>
|
||||
<attributes>
|
||||
<name>introLength</name>
|
||||
<datatype>int</datatype>
|
||||
<default>60</default>
|
||||
<intro>自我介绍长度</intro>
|
||||
</attributes>
|
||||
</root>
|
||||
Reference in New Issue
Block a user