VirtualBox

Ignore:
Timestamp:
Mar 24, 2020 8:16:51 PM (5 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
136614
Message:

TestManager/Wui: Filter out change log parameters for edit and clone links.

Location:
trunk/src/VBox/ValidationKit/testmanager/webui
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/ValidationKit/testmanager/webui/wuibase.py

    r83395 r83397  
    9797    ## The name of the parameter indicate number of change log entries per page.
    9898    ksParamChangeLogEntriesPerPage  = 'ChangeLogEntriesPerPage';
     99    ## The change log related parameters.
     100    kasChangeLogParams = (ksParamChangeLogEnabled, ksParamChangeLogPageNo, ksParamChangeLogEntriesPerPage,);
    99101
    100102    ## @name Dispatcher debugging parameters.
  • trunk/src/VBox/ValidationKit/testmanager/webui/wuicontentbase.py

    r83396 r83397  
    663663        if self._sMode == self.ksMode_Show and self._fEditable:
    664664            # Remove _idGen and effective date since we're always editing the current data,
    665             # and make sure the primary ID is present.
     665            # and make sure the primary ID is present.  Also remove change log stuff.
    666666            dParams = self._oDisp.getParameters();
    667667            if hasattr(oData, 'ksIdGenAttr'):
     
    669669                if sIdGenParam in dParams:
    670670                    del dParams[sIdGenParam];
    671             if WuiDispatcherBase.ksParamEffectiveDate in dParams:
    672                 del dParams[WuiDispatcherBase.ksParamEffectiveDate];
     671            for sParam in [ WuiDispatcherBase.ksParamEffectiveDate, ] + list(WuiDispatcherBase.kasChangeLogParams):
     672                if sParam in dParams:
     673                    del dParams[sParam];
    673674            dParams[getattr(oData, 'ksParam_' + oData.ksIdAttr)] = getattr(oData, oData.ksIdAttr);
    674675
     
    676677            aoActions.append(WuiTmLink('Edit', '', dParams));
    677678
    678             # Add clone operation if available. This uses the same data selection as for showing details.
     679            # Add clone operation if available. This uses the same data selection as for showing details.  No change log.
    679680            if hasattr(self._oDisp, self._sActionBase + 'Clone'):
    680681                dParams = self._oDisp.getParameters();
     682                for sParam in WuiDispatcherBase.kasChangeLogParams:
     683                    if sParam in dParams:
     684                        del dParams[sParam];
    681685                dParams[WuiDispatcherBase.ksParamAction] = getattr(self._oDisp, self._sActionBase + 'Clone');
    682686                aoActions.append(WuiTmLink('Clone', '', dParams));
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette