Skip to content
This repository has been archived by the owner on Nov 29, 2021. It is now read-only.

Commit

Permalink
feat: update sms
Browse files Browse the repository at this point in the history
  • Loading branch information
YanceyOfficial committed Apr 11, 2020
1 parent 7e8c26c commit 335ab57
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 20 deletions.
9 changes: 0 additions & 9 deletions schema.gql
Original file line number Diff line number Diff line change
Expand Up @@ -338,7 +338,6 @@ type Query {
login(input: LoginInput!): UserModel!
getAnnouncements: [AnnouncementModel!]!
getAnnouncementById(id: ID!): AnnouncementModel!
getAllSMS: [SMSModel!]!
getOpenSources: [OpenSourceModel!]!
getOpenSourceById(id: ID!): OpenSourceModel!
getBanwagonServiceInfo: ServiceInfoModel!
Expand Down Expand Up @@ -427,14 +426,6 @@ type ServiceInfoModel {
veid: Float!
}

type SMSModel {
_id: String!
phoneNumber: String!
verificationCode: String!
createdAt: DateTime!
updatedAt: DateTime!
}

type TOTPModel {
qrcode: String!
key: String!
Expand Down
6 changes: 0 additions & 6 deletions src/sms/sms.resolver.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,6 @@ export class SMSResolver {
this.smsService = smsService
}

@Query(() => [SMSModel])
@UseGuards(GqlAuthGuard)
public getAllSMS(): Promise<SMSModel[]> {
return this.smsService.getAll()
}

@Mutation(() => SendSMSRes)
@UseGuards(GqlAuthGuard)
public sendSMS(@Args('input') input: SendSMSInput): Promise<SendSMSRes> {
Expand Down
5 changes: 0 additions & 5 deletions src/sms/sms.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,11 +51,6 @@ export class SMSService {
}
}

public async getAll() {
const res = await this.SMSModel.find({})
return res
}

public async sendSMS(input: SendSMSInput) {
const { phoneNumber } = input

Expand Down

0 comments on commit 335ab57

Please sign in to comment.