private void refreshData() { EbSite site = (EbSite) listCursor.getCurrentObject(); if (site == null) { // 新增页面 this.pageStatus = ZcSettingConstants.PAGE_STATUS_NEW; site = new EbSite(); setDefualtValue(site, ZcSettingConstants.PAGE_STATUS_NEW); List lst = new ArrayList(); lst.add(site); this.listCursor.setDataList(lst, -1); } else { site = ebayServiceDelegate.getebSiteByID(site.getSiteId(), requestMeta); } listCursor.setCurrentObject(site); this.setEditingObject(site); setOldObject(); updateFieldEditorsEditable(); setButtonStatus(); }
private void setOldObject() { oldSite = (EbSite) ObjectUtil.deepCopy(listCursor.getCurrentObject()); }
public boolean isDataChanged() { return !DigestUtil.digest(oldSite).equals(DigestUtil.digest(listCursor.getCurrentObject())); }