Servigistics InService 自訂 > 自訂系統整合 > 定價與供貨狀況系統整合
  
定價與供貨狀況系統整合
此小節詳細說明您可以對顯示或隱藏定價與可用性資訊及建議資訊進行的自訂。
* 
這些自訂需要熟悉 Windchill Shell 及傳播內容以及使用 xconfmanager 公用程式。如需這些主題的資訊,請參閱:
.
顯示定價與可用性資訊
欲顯示定價與可用性資訊,需要依如下所示建立自訂委派:
1. 建立實行 com.ptc.sc.services.plugins.PricingDelegate 介面的自訂 Java 類別。
2. 價格的顯示由自訂委派中的下列方法實行決定:public boolean isPricingAutomatic();
如果傳回 true,價格與供貨狀況將在使用者介面中擷取及顯示,而不需要使用者動作。如果傳回 false,則使用者必須按一下內容動作來取得價格與供貨狀況。定價與供貨狀況可透過關閉動作來隱藏。
3. 新增下列項目至指定自訂定價委派的 <WT_HOME>/site.xconf 檔案:
<Service context="default" name="com.ptc.sc.services.plugins.
PricingDelegate">
<Option serviceClass="<customDelegateClassName>"
requestor="null" cardinality="duplicate" />
</Service>
4. Windchill 指令行中,執行以下指令:xconfmanager -pF
5. 重新啟動 Servigistics InService 伺服器。
* 
如需詳細資訊,請參閱 PricingDelegate Javadoc。
隱藏定價與可用性資訊
欲在 UI 中隱藏定價與可用性資訊,請禁用自訂委派,如下所示:
1. 導覽至 <WT_Home>\SW\Applications\Windchill.ear\codebase.war\com\ptc\sc\xconf\ 目錄。開啟 sc.service.properties.xconf 檔案。
2. 搜尋「DemoPricingDelegate」並新增區段注解,如下所示。
<Service context="default" name="com.ptc.sc.services.plugins.
PricingDelegate">
<Option serviceClass="com.ptc.sc.services.plugins.DemoPricingDelegate"
requestor="null" cardinality="duplicate" />
</Service>
3. 儲存並關閉 sc.service.properties.xconf 檔案。
4. Windchill 指令行中,執行以下指令:xconfmanager -pF
5. 重新啟動 Servigistics InService 伺服器。
顯示建議資訊
欲顯示建議資訊,需要依如下所示建立自訂委派:
1. 建立目錄放置實行 com.ptc.sc.services.plugins.RecommendationDelegate 的自訂 Java 類別,這可在 <WT_Home>\SW\Applications\Windchill.ear\codebase.war\com\ptc\sc\services\plugins 目錄中找到。
2. 建立實行 com.ptc.sc.services.plugins.RecommendationDelegate 介面的自訂 Java 類別。
3. 將下列項目新增到指定自訂建議委派的 \InService\SW\Applications\Windchill.ear\site.xconf 檔案。
<Service context="default" name"com.ptc.sc.services.plugins.
RecommendationDelegate">
<Option serviceClass="<customDelegateClassName>"
requestor="null"
cardinality="duplicate" />
</Service>
4. 儲存並關閉 site.xconf 檔案。
5. Windchill 指令行中,執行以下指令:xconfmanager -pF
6. 重新啟動 Servigistics InService 伺服器。
隱藏建議資訊
欲隱藏 UI 的建議資訊,請禁用示範建議委派,如下所示:
1. 導覽至 <WT_Home>\SW\Applications\Windchill.ear\codebase.war\com\ptc\sc\xconf\ 目錄。開啟 sc.service.properties.xconf 檔案。
2. 搜尋「DemoRecommendationDelegate」並新增區段注解,如下所示︰
<Service context="default" name"com.ptc.sc.services.plugins.
RecommendationDelegate">
<Option serviceClass="<customDelegateClassName>"
requestor="null"
cardinality="duplicate" />
</Service>
3. 儲存並關閉 sc.service.properties.xconf 檔案。
4. Windchill 指令行中,執行以下指令:xconfmanager -pF
5. 重新啟動 Servigistics InService 伺服器。