Class: UserMutateService
User mutate service
Extends
Implements
Constructors
new UserMutateService()
new UserMutateService(
repo
,userPasswordService
):UserMutateService
Constructor
Parameters
Parameter | Type | Description |
---|---|---|
repo | Repository <UserEntityInterface > | instance of the user repo |
userPasswordService | UserPasswordService | instance of a user password service |
Returns
Overrides
Defined in
.tmp/repos/rockets/packages/nestjs-user/src/services/user-mutate.service.ts:39 (opens in a new tab)
Properties
Property | Modifier | Type | Default value | Description | Overrides |
---|---|---|---|---|---|
createDto | protected | typeof UserCreateDto | UserCreateDto | - | MutateService .createDto |
updateDto | protected | typeof UserUpdateDto | UserUpdateDto | - | MutateService .updateDto |
userPasswordService | readonly | UserPasswordService | undefined | instance of a user password service | - |
Accessors
metadata
get
protected
metadata():EntityMetadata
Internal
Returns
EntityMetadata
Inherited from
Defined in
.tmp/repos/rockets/packages/typeorm-common/dist/services/base.service.d.ts:14
Methods
create()
create(
data
,queryOptions
?):Promise
<UserEntityInterface
>
Create one
Parameters
Parameter | Type | Description |
---|---|---|
data | UserCreatableInterface | the reference to create |
queryOptions ? | QueryOptionsInterface | - |
Returns
Promise
<UserEntityInterface
>
the created reference
Implementation of
UserMutateServiceInterface
.create
Inherited from
Defined in
.tmp/repos/rockets/packages/typeorm-common/dist/services/mutate.service.d.ts:9
find()
find(
options
,queryOptions
?):Promise
<Promise
<UserEntityInterface
[]>>
Find wrapper.
Parameters
Parameter | Type | Description |
---|---|---|
options | FindManyOptions <UserEntityInterface > | Find many options |
queryOptions ? | QueryOptionsInterface | Query options |
Returns
Promise
<Promise
<UserEntityInterface
[]>>
Inherited from
Defined in
.tmp/repos/rockets/packages/typeorm-common/dist/services/base.service.d.ts:10
findById()
protected
findById(id
,queryOptions
?):Promise
<UserEntityInterface
>
Internal
Parameters
Parameter | Type |
---|---|
id | string |
queryOptions ? | QueryOptionsInterface |
Returns
Promise
<UserEntityInterface
>
Inherited from
Defined in
.tmp/repos/rockets/packages/typeorm-common/dist/services/mutate.service.d.ts:17
findOne()
findOne(
options
,queryOptions
?):Promise
<null
|UserEntityInterface
>
Find One wrapper.
Parameters
Parameter | Type | Description |
---|---|---|
options | FindOneOptions <UserEntityInterface > | Find one options |
queryOptions ? | QueryOptionsInterface | Query options |
Returns
Promise
<null
| UserEntityInterface
>
Inherited from
Defined in
.tmp/repos/rockets/packages/typeorm-common/dist/services/base.service.d.ts:11
remove()
remove(
data
,queryOptions
?):Promise
<UserEntityInterface
>
Remove one
Parameters
Parameter | Type | Description |
---|---|---|
data | DeepPartial <UserEntityInterface > & ReferenceIdInterface <string > | the reference data to remove |
queryOptions ? | QueryOptionsInterface | query options |
Returns
Promise
<UserEntityInterface
>
the removed reference
Implementation of
UserMutateServiceInterface
.remove
Inherited from
Defined in
.tmp/repos/rockets/packages/typeorm-common/dist/services/mutate.service.d.ts:12
replace()
replace(
data
,queryOptions
?):Promise
<UserEntityInterface
>
Replace one
Parameters
Parameter | Type | Description |
---|---|---|
data | UserCreatableInterface & ReferenceIdInterface <string > | the reference data to replace |
queryOptions ? | QueryOptionsInterface | - |
Returns
Promise
<UserEntityInterface
>
the replaced reference
Implementation of
UserMutateServiceInterface
.replace
Inherited from
Defined in
.tmp/repos/rockets/packages/typeorm-common/dist/services/mutate.service.d.ts:11
repository()
repository(
queryOptions
?):Repository
<UserEntityInterface
>
Return the correct repository instance.
Parameters
Parameter | Type | Description |
---|---|---|
queryOptions ? | QueryOptionsInterface | Options |
Returns
Repository
<UserEntityInterface
>
Inherited from
Defined in
.tmp/repos/rockets/packages/typeorm-common/dist/services/base.service.d.ts:12
transaction()
transaction(
options
?):TransactionProxy
Return a transaction instance.
Parameters
Parameter | Type | Description |
---|---|---|
options ? | SafeTransactionOptionsInterface | Options |
Returns
Inherited from
Defined in
.tmp/repos/rockets/packages/typeorm-common/dist/services/base.service.d.ts:13
transform()
protected
transform<T
>(user
):Promise
<DeepPartial
<UserEntityInterface
>>
Internal
Type Parameters
Type Parameter |
---|
T extends DeepPartial <UserEntityInterface > |
Parameters
Parameter | Type |
---|---|
user | T | T & PasswordPlainInterface |
Returns
Promise
<DeepPartial
<UserEntityInterface
>>
Overrides
Defined in
.tmp/repos/rockets/packages/nestjs-user/src/services/user-mutate.service.ts:47 (opens in a new tab)
update()
update(
data
,queryOptions
?):Promise
<UserEntityInterface
>
Update one
Parameters
Parameter | Type | Description |
---|---|---|
data | UserUpdatableInterface & ReferenceIdInterface <string > | the reference data to update |
queryOptions ? | QueryOptionsInterface | - |
Returns
Promise
<UserEntityInterface
>
the updated reference
Implementation of
UserMutateServiceInterface
.update
Inherited from
Defined in
.tmp/repos/rockets/packages/typeorm-common/dist/services/mutate.service.d.ts:10
validate()
protected
validate<T
>(type
,data
):Promise
<T
>
Internal
Type Parameters
Type Parameter |
---|
T extends DeepPartial <UserEntityInterface > |
Parameters
Parameter | Type |
---|---|
type | Type <T > |
data | T |
Returns
Promise
<T
>
Inherited from
Defined in
.tmp/repos/rockets/packages/typeorm-common/dist/services/mutate.service.d.ts:15