企業管理 > 企業管理變更推進 > 執行企業管理變更推進指令行公用程式 > 匯入變更指令 > 對應企業管理變更屬性
  
對應企業管理變更屬性
在大多數情況下,您用來匯出管理變更的來源與目標系統都應該相同。不過,還可能存在一種情況,就是屬性無法在目標系統使用,或者在目標系統有不同的識別元。例如,使用者在目標系統所擁有的 UFID 就可能與來源系統不同。為了防止在匯入時出現衝突,可以使用 import 指令建立及參考對應檔。以下幾節包含樣本對應 XSL 檔案。
原則存取控制規則的對應
在此範例中,已針對建立了原則存取控制規則的前後關聯,與將原則規則套用至的使用者指定對應:
<?xml version="1.0" ?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
<xsl:template match="@* | node()" priority="-9">
<xsl:copy><xsl:apply-templates select="@* | node()"/></xsl:copy>
</xsl:template>
<xsl:template match="AccessControlRule">
<newInfo>
<xsl:apply-templates select="objectContainerPath"/>
<xsl:apply-templates select="WTPrincipalReference"/>
</newInfo>
</xsl:template>
<xsl:template match="objectContainerPath">
<objectContainerPath>
<xsl:value-of select='replace(., "testOrg","Demo Organization")'/>
</objectContainerPath>
</xsl:template>
<xsl:template match="ufid">
<ufid>
<xsl:value-of select='replace(., "testuser","demo")'/>
</ufid>
</xsl:template>
</xsl:stylesheet>
參與者的對應
在此範例中,已針對將設定檔套用至的參與者的名稱與識別元指定對應:
<?xml version="1.0" ?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
<xsl:template match="@* | node()" priority="-9">
<xsl:copy>
<xsl:apply-templates select="@* | node()"/>
</xsl:copy>
</xsl:template>
<xsl:template match="ExportedProfileInfo">
<newInfo>
<xsl:apply-templates select="profileMember"/>
</newInfo>
</xsl:template>
<xsl:template match="WTPrincipalReference/ufid">
<ufid>
<xsl:value-of select="replace(., "aa","demo")"/>
</ufid>
</xsl:template>
<xsl:template match="WTPrincipalReference/name">
<name>
<xsl:value-of select='replace(., "aa","demo")'/>
</name>
</xsl:template>
</xsl:stylesheet>
前後關聯的對應
在此範例中,已針對建立了設定檔的前後關聯指定對應:
<?xml version="1.0" ?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
<xsl:template match="@* | node()" priority="-9">
<xsl:copy>
<xsl:apply-templates select="@* | node()"/>
</xsl:copy>
</xsl:template>
<xsl:template match="ExportedProfileInfo">
<newInfo>
<xsl:apply-templates select="objectContainerPath"/>
</newInfo>
</xsl:template>
<xsl:template match="objectContainerPath">
<objectContainerPath>
<xsl:value-of select='replace(., "testOrg","Demo Organization")'/>
</objectContainerPath>
</xsl:template>
</xsl:stylesheet>