barname
This commit is contained in:
@@ -13,6 +13,8 @@ import { ParamDto } from "../../common/DTO/param.dto";
|
||||
import { BusinessInterceptor } from "../../core/interceptors/business.interceptor";
|
||||
import { Business } from "../businesses/entities/business.entity";
|
||||
import { UserDec } from "../../common/decorators/user.decorator";
|
||||
import { RoleEnum } from "../users/enums/role.enum";
|
||||
import { UpdateBarnameAsWatcherDto } from "./dto/update-barname-watcher.dto";
|
||||
|
||||
@Controller("barname")
|
||||
@UseInterceptors(BusinessInterceptor)
|
||||
@@ -42,8 +44,8 @@ export class BarnameController {
|
||||
|
||||
@ApiOperation({ summary: "Update Barname by watcher" })
|
||||
@Get(":id/watcher")
|
||||
update(@Param() dto: ParamDto, @BusinessDec("id") businessId: string) {
|
||||
return this.billsService.findOne(dto.id, businessId);
|
||||
update(@Param('id') id: string, @BusinessDec() business: Business, @Body() dto: UpdateBarnameAsWatcherDto, @UserDec("role") role: RoleEnum) {
|
||||
return this.billsService.updateBarnameAsWatcher(id, dto, business, role);
|
||||
}
|
||||
|
||||
@ApiOperation({ summary: "Remove a barname" })
|
||||
|
||||
Reference in New Issue
Block a user