mirror of
https://github.com/google/nomulus.git
synced 2025-06-26 22:34:55 +02:00
Add EAP fees to domain create flow
------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=126411200
This commit is contained in:
parent
d6bd2d56cd
commit
273fc0014d
7 changed files with 118 additions and 18 deletions
|
@ -33,7 +33,6 @@ import google.registry.model.domain.DomainApplication;
|
|||
import google.registry.model.domain.DomainApplication.Builder;
|
||||
import google.registry.model.domain.DomainResource;
|
||||
import google.registry.model.domain.Period;
|
||||
import google.registry.model.domain.fee.Fee;
|
||||
import google.registry.model.domain.fee.FeeCreateExtension;
|
||||
import google.registry.model.domain.fee.FeeCreateResponseExtension;
|
||||
import google.registry.model.domain.launch.ApplicationStatus;
|
||||
|
@ -143,7 +142,8 @@ public class DomainApplicationCreateFlow extends BaseDomainCreateFlow<DomainAppl
|
|||
|
||||
@Override
|
||||
protected void verifyDomainCreateIsAllowed() throws EppException {
|
||||
validateFeeChallenge(targetId, getTld(), now, feeCreate, createCost);
|
||||
validateFeeChallenge(
|
||||
targetId, getTld(), now, feeCreate, commandOperations.getTotalCost());
|
||||
if (tldState == TldState.LANDRUSH && !isSuperuser) {
|
||||
// Prohibit creating a landrush application in LANDRUSH (but not in SUNRUSH) if there is
|
||||
// exactly one sunrise application for the same name.
|
||||
|
@ -214,8 +214,8 @@ public class DomainApplicationCreateFlow extends BaseDomainCreateFlow<DomainAppl
|
|||
.build());
|
||||
if (feeCreate != null) {
|
||||
responseExtensionsBuilder.add(new FeeCreateResponseExtension.Builder()
|
||||
.setCurrency(createCost.getCurrencyUnit())
|
||||
.setFee(ImmutableList.of(Fee.create(createCost.getAmount(), "create")))
|
||||
.setCurrency(commandOperations.getCurrency())
|
||||
.setFee(commandOperations.getFees())
|
||||
.build());
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue