Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feature-03-migrate-functions-to-files #8

Merged
merged 6 commits into from
Nov 11, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions src/rate-plans/graphql/examples/createRatePlan.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Create a rate plan
mutation {
createRatePlan(
ratePlanObj:{
name: "IOPA-278",
description: "plan for groupal annual subscriptions, until ten peoples",
versionId: 7822111,
versionPlan: "2.4",
status: "Published",
typePlan: "Annually - Groupal Subscribers",
subscriptionCharge: 1.1,
numberOfTiers: 3,
}
) {
id
name
description
versionId
versionPlan
status
typePlan
subscriptionCharge
numberOfTiers
creationDate
updateDate
}
}
16 changes: 16 additions & 0 deletions src/rate-plans/graphql/examples/getAllRatePlans.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Get All Rate Plans
query {
getAllRatePlans(pageNro: 0, pageSize: 100, orderBy: "name", orderAt: "asc") {
id
name
description
versionId
versionPlan
status
typePlan
subscriptionCharge
numberOfTiers
creationDate
updateDate
}
}
16 changes: 16 additions & 0 deletions src/rate-plans/graphql/examples/getByIdRatePlans.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# get by id Rate Plan
query {
getByIdRatePlans(inputId: 2) {
id
name
description
versionId
versionPlan
status
typePlan
subscriptionCharge
numberOfTiers
creationDate
updateDate
}
}
25 changes: 25 additions & 0 deletions src/rate-plans/graphql/examples/updateRatePlan.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Update a Rate Plan
mutation {
updateRatePlan(
id : 2,
ratePlanObj:{
name: "IOPA-27822",
description: "plan for groupal annual subscriptions, until ten peoples",
versionId: 7822111,
versionPlan: "2.4",
status: "Published",
typePlan: "Annually - Groupal Subscribers",
subscriptionCharge: 1.1,
numberOfTiers: 3,
}
) {
name
description
versionId
versionPlan
status
typePlan
subscriptionCharge
numberOfTiers
}
}
56 changes: 0 additions & 56 deletions src/rate-plans/graphql/mutations.txt

This file was deleted.

44 changes: 0 additions & 44 deletions src/rate-plans/graphql/queries.txt

This file was deleted.

29 changes: 24 additions & 5 deletions src/rate-plans/rate-plans.module.ts
Original file line number Diff line number Diff line change
@@ -1,16 +1,35 @@
//External
import { Module } from '@nestjs/common';
//Service
import { RatePlansService } from './rate-plans.service';
//Resolvers
import { RatePlansResolver } from './rate-plans.resolver';
//Modules
import { DatabaseModule } from 'src/database/database.module';
//Providers
import { RatePlansProviders } from './rate-plans.providers';
import { CreateRatePlansService } from './services/create.service';
import { CreateRatePlansResolver } from './resolvers/create.resolver';
import { UpdateRatePlansService } from './services/update.service';
import { UpdateRatePlansResolver } from './resolvers/update.resolver';
import { GetAllRatePlansService } from './services/get-all.service';
import { GetAllRatePlansResolver } from './resolvers/get-all.resolver';
import { GetByIdRatePlansService } from './services/get-by-id.service';
import { GetByIdRatePlansResolver } from './resolvers/get-by-id.resolver';

@Module({
imports: [DatabaseModule],
providers: [...RatePlansProviders, RatePlansService, RatePlansResolver],
providers: [
//Providers
...RatePlansProviders,
//CreateRatePlan
CreateRatePlansService,
CreateRatePlansResolver,
//UpdateRatePlan
UpdateRatePlansService,
UpdateRatePlansResolver,
//GetAllRatePlan
GetAllRatePlansService,
GetAllRatePlansResolver,
//GetByIdRatePlan
GetByIdRatePlansService,
GetByIdRatePlansResolver,
],
})
export class RatePlansModule {}
139 changes: 0 additions & 139 deletions src/rate-plans/rate-plans.resolver.ts

This file was deleted.

Loading