Search in sources :

Example 1 with IDeveloperModeBL

use of org.adempiere.ad.service.IDeveloperModeBL in project adempiere by adempiere.

the class AProcessModel method getDescription.

/**
	 * Gets description/tooltip to be used in Gear
	 * 
	 * @param process
	 * @return description/tooltip
	 */
public String getDescription(final I_AD_Process process) {
    final I_AD_Process processTrl = POWrapper.translate(process, I_AD_Process.class);
    String description = processTrl.getDescription();
    final IDeveloperModeBL developerModeBL = Services.get(IDeveloperModeBL.class);
    if (developerModeBL != null && developerModeBL.isEnabled()) {
        if (description == null) {
            description = "";
        } else {
            description += "\n - ";
        }
        description += "Classname:" + process.getClassname() + ", ID=" + process.getAD_Process_ID();
    }
    return description;
}
Also used : IDeveloperModeBL(org.adempiere.ad.service.IDeveloperModeBL) I_AD_Process(org.compiere.model.I_AD_Process)

Example 2 with IDeveloperModeBL

use of org.adempiere.ad.service.IDeveloperModeBL in project adempiere by adempiere.

the class AProcessModel method getDisplayName.

/**
	 * Gets display name to be used in Gear
	 * 
	 * @param process
	 * @return process display name
	 */
public String getDisplayName(final I_AD_Process process) {
    final I_AD_Process processTrl = POWrapper.translate(process, I_AD_Process.class);
    String name = processTrl.getName();
    final IDeveloperModeBL developerModeBL = Services.get(IDeveloperModeBL.class);
    if (developerModeBL != null && developerModeBL.isEnabled()) {
        name += "/" + process.getValue();
    }
    return name;
}
Also used : IDeveloperModeBL(org.adempiere.ad.service.IDeveloperModeBL) I_AD_Process(org.compiere.model.I_AD_Process)

Aggregations

IDeveloperModeBL (org.adempiere.ad.service.IDeveloperModeBL)2 I_AD_Process (org.compiere.model.I_AD_Process)2