From 9be7fcd1439a8fe68eda8795297ec54b7867b606 Mon Sep 17 00:00:00 2001 From: zzh <1368735060@qq.com> Date: Fri, 30 Oct 2026 17:33:04 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E5=AE=A2=E6=88=B7=E5=85=AC=E5=BC=80?= =?UTF-8?q?=E6=B3=A8=E5=86=8C=E6=8E=A5=E5=8F=A3=E5=85=81=E8=AE=B8=E5=8C=BF?= =?UTF-8?q?=E5=90=8D=E8=AE=BF=E9=97=AE=EF=BC=8C=E9=81=BF=E5=85=8D=E6=B3=A8?= =?UTF-8?q?=E5=86=8C=E9=A1=B5=20401?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Cursor --- src/Oms.Application/Services/Customers/CustomerService.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Oms.Application/Services/Customers/CustomerService.cs b/src/Oms.Application/Services/Customers/CustomerService.cs index 19ab5ac..009bedc 100644 --- a/src/Oms.Application/Services/Customers/CustomerService.cs +++ b/src/Oms.Application/Services/Customers/CustomerService.cs @@ -6,6 +6,7 @@ using Fake.Rbac.Application.Services; using Fake.Rbac.Infrastructure; using Fake.Security.Claims; using Fake.EntityFrameworkCore; +using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Mvc; using Microsoft.EntityFrameworkCore; using Oms.Application.Dtos.Customers; @@ -228,10 +229,11 @@ public class CustomerService : ApplicationService } /// - /// 新增客户。 + /// 新增客户(公开注册页可匿名调用;管理端也可带 token 代开户)。 /// /// 入参:客户创建参数。 /// 无返回体,仅完成新增客户。 + [AllowAnonymous] [HttpPost("/customer/create")] public async Task CreateAsync(CreateCustomerInput input) {