Files
ningbo/动易的标签库/标签库/百科类/互动百科_用户编辑词条列表.config
T
2026-08-31 16:22:00 +08:00

111 lines
3.8 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<root>
<LabelType>百科类</LabelType>
<LabelIntro>
</LabelIntro>
<OutType>sin</OutType>
<LabelDataType>static</LabelDataType>
<EnabelAjax>False</EnabelAjax>
<Version officialVersion="" modifiedVersions="4711" compatibleVersion="" />
<attributes>
<name>titleLength</name>
<datatype>int</datatype>
<default>20</default>
<intro>标题长度</intro>
</attributes>
<attributes>
<name>linkOpenType</name>
<datatype>string</datatype>
<default>_blank</default>
<intro>链接打开方式</intro>
</attributes>
<attributes>
<name>outputQty</name>
<datatype>supersql</datatype>
<default>20</default>
<intro>输出记录数</intro>
</attributes>
<attributes>
<name>bindStyle</name>
<datatype>string</datatype>
<default>普通式</default>
<intro>样式标签名称</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" xmlns:pe="labelproc" exclude-result-prefixes="pe">
<!--要使用上一步定义的自定义参数,要作为XSLT参数使用,务必要在这里声明。如:<xsl:param name="myPara" />.引用该参数:$myPara -->
<xsl:param name="isLeaf" />
<xsl:param name="cid" />
<xsl:output method="xml" />
<xsl:template match="/">
<root>
<sql>
<xsl:choose>
<xsl:when test="$isLeaf = 1">
SELECT * FROM PE_EN_Entry WHERE CatalogId IN(@cid)
</xsl:when>
<xsl:otherwise>
SELECT ParentId = @cid
</xsl:otherwise>
</xsl:choose>
</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="titleLength" />
<xsl:param name="outputQty" />
<xsl:param name="bindStyle" />
<xsl:param name="editor"/>
<xsl:template name="_constraint">
<xsl:param name="_doubleApos"/>
<xsl:choose>
<xsl:when test="pe:GetLoginedUserInfo('UserName') = $editor">
E.Status >= 0
</xsl:when>
<xsl:otherwise>
E.Status > 0
</xsl:otherwise>
</xsl:choose>
<xsl:choose>
<xsl:when test="$_doubleApos = 'true'">
AND ED.Editor = ''<xsl:value-of select="$editor" />''
</xsl:when>
<xsl:otherwise>
AND ED.Editor = '<xsl:value-of select="$editor" />'
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<xsl:output method="html" />
<xsl:template match="/">
{PE.Label id="互动百科_用户编辑词条列表_<xsl:value-of select="$bindStyle" />" page="true" pageid="@RequestInt_page" pagesize="<xsl:value-of select="$outputQty" />" linkOpenType="<xsl:value-of select="$linkOpenType"/>" titleLength="<xsl:value-of select="$titleLength"/>"
sqlString="EXEC [dbo].[PR_Common_PagingLarge] 'PE_EN_Entry_Edition ED INNER JOIN PE_EN_Entry E ON E.EntryId = ED.EntryId','ED.EntryId','ED.EntryId,E.EntryName,E.Inputer,E.Tag,E.Hits,E.EditTimes,E.Summary,MAX(ED.EditTime) EditTime',<xsl:value-of select="$outputQty" />,@startrow ,'<xsl:call-template name="_constraint">
<xsl:with-param name="_doubleApos" select="'true'"/>
</xsl:call-template>','ED.EntryId,E.EntryName,E.Inputer,E.Tag,E.Hits,E.EditTimes,E.Summary','ED.EntryId DESC'"
sqlCount="select count(distinct ED.EntryId) from PE_EN_Entry_Edition ED INNER JOIN PE_EN_Entry E ON E.EntryId = ED.EntryId WHERE <xsl:call-template name="_constraint">
<xsl:with-param name="_doubleApos" select="'false'"/>
</xsl:call-template>" /}
</xsl:template>
</xsl:stylesheet>]]></LabelTemplate>
<attributes>
<name>editor</name>
<datatype>supersql</datatype>
<default>
</default>
<intro>查询条件-编辑者</intro>
</attributes>
</root>