Skip to content

Instantly share code, notes, and snippets.

@SinTeZWh1te
Last active October 23, 2019 18:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save SinTeZWh1te/3d0b460bee645b6f511955e857d31c16 to your computer and use it in GitHub Desktop.
Save SinTeZWh1te/3d0b460bee645b6f511955e857d31c16 to your computer and use it in GitHub Desktop.
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import ru.bitel.bgbilling.common.BGException;
import ru.bitel.mybgbilling.kernel.common.AbstractBean;
import ru.bitel.mybgbilling.kernel.common.inject.BGInject;
import ru.bitel.mybgbilling.kernel.common.inject.BGInjection;
import ru.bitel.bgbilling.modules.npay.api.common.service.NpayService;
import javax.faces.bean.ViewScoped;
import javax.inject.Named;
import java.io.Serializable;
import java.math.BigDecimal;
@Named
@ViewScoped
@BGInjection
public class MyNPayBean extends AbstractBean implements Serializable {
private static final Logger logger = LoggerFactory.getLogger(MyNPayBean.class);
@BGInject
private NpayService npayService;
@Override
protected void init() throws BGException {
populate();
}
public void populate() throws BGException {
}
public BigDecimal getAmountForUnlock() throws BGException {
return this.npayService.getAmountForUnlock(this.getContractId(),<MODULE_ID>);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment