透過建立 ItemType 的 Client Side Action,搭配 JavaScript Method 來實作另存新檔的功能。
- 以目標 ItemType 做為要複製的對象
- 更新ID和動作為[新增]
- 自訂想要複製的欄位
- 解鎖該項目
- 刷新主畫面
- 開啟編輯視窗
var innovator = this.getInnovator();
this.setNewID();
this.setAction("add");
this.setAttribute("isTemp", "1");
this.setProperty("state", "");
this.setProperty("item_number", "Copy of " + this.getProperty("item_number"));
this.unlockItem();
main.work.searchContainer.runSearch();
top.aras.uiShowItemEx(this.node, "tab view", true, false);

Leave a comment