feat: add consumer accounts and business activities management

- Implemented AccountsService for managing consumer accounts including create, update, delete, and find operations.
- Created DTOs for account creation and updates.
- Developed BusinessActivitiesController and BusinessActivitiesService for handling business activities related to consumers.
- Added complexes management with ComplexesController and ComplexesService.
- Introduced POS management with ComplexPosesController and ComplexPosesService.
- Created necessary DTOs for business activities and POS.
- Established Licenses management with LicensesController and LicensesService.
- Integrated consumer management with PartnerConsumersController and PartnerConsumersService.
- Added Prisma module imports and service connections across modules.
This commit is contained in:
2026-04-23 20:59:39 +03:30
parent f9e1ad69dc
commit a350ec7990
104 changed files with 13233 additions and 4105 deletions
@@ -0,0 +1,38 @@
import { Body, Controller, Get, Param, Patch, Post } from '@nestjs/common'
import { ApiTags } from '@nestjs/swagger'
import { AccountsService } from './accounts.service'
import { CreateConsumerAccountDto, UpdateAccountDto } from './dto/account.dto'
@ApiTags('PartnerConsumerAccounts')
@Controller('partner/consumers/:consumerId/accounts')
export class AccountsController {
constructor(private readonly accountsService: AccountsService) {}
@Get()
async findAll(@Param('consumerId') consumerId: string) {
return this.accountsService.findAll(consumerId)
}
@Get(':id')
async findOne(@Param('id') id: string) {
return this.accountsService.findOne(id)
}
@Post()
async create(
@Param('consumerId') consumerId: string,
@Body() data: CreateConsumerAccountDto,
) {
return this.accountsService.create(consumerId, data)
}
@Patch(':id')
async update(@Param('id') id: string, @Body() data: UpdateAccountDto) {
return this.accountsService.update(id, data)
}
// @Delete(':id')
// async delete(@Param('id') id: string) {
// return this.accountsService.delete(id)
// }
}