Skip to content

Commit

Permalink
Merge pull request #107 from huiz1990/TRNTYUI-1207
Browse files Browse the repository at this point in the history
TRNTYUI-1207
  • Loading branch information
ChripIX authored Apr 25, 2024
2 parents 7ac685c + 89a2d16 commit 99380fe
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/Domainrobot.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

const ContactService = require("./services/ContactService")
const CertificateService = require("./services/CertificateService")
const Customer = require("./services/Customer")
const DomainStudio = require("./services/DomainStudio")
const DomainService = require("./services/DomainService")
const SslContactService = require("./services/SslContactService")
Expand Down Expand Up @@ -38,6 +39,10 @@ class DomainRobot {
return new CertificateService(this.domainRobotConfig)
}

customer() {
return new Customer(this.domainRobotConfig)
}

domain() {
return new DomainService(this.domainRobotConfig)
}
Expand Down
23 changes: 23 additions & 0 deletions src/services/Customer.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
let DomainRobotService = require("./DomainRobotService");

class Customer extends DomainRobotService {

constructor(domainRobotConfig) {
super(domainRobotConfig);
}

/**
* Basic Customer Update (120002)
*
* @param {*} model DomainRobotModels.BasicCustomer
* @returns Promise<DomainRobotResult<JsonResponseDataBasicCustomer, number>>
*/
async update(model) {
return await this.sendPutRequest(
this.domainRobotConfig.url + "/customer/" + model.client + "/" + model.number,
model
);
}
}

module.exports = Customer;

0 comments on commit 99380fe

Please sign in to comment.