保存可以不上传资料,但提交审核验证资料是否上传

djz_new
ZR20090193-陈敬勇 2 years ago
parent ca64b42e94
commit b4fbeac2fd

@ -91,6 +91,7 @@
setFieldsValue({ customername: unref(user.companyName) });
setFieldsValue({ corpid: unref(user.companyId) });
setFieldsValue({ userName: unref(user.userName) });
setFieldsValue({ files: unref([]) });
}
setModalProps({ loading: false });
});

@ -26,12 +26,12 @@ public class CompanyInput:OP_YARD_COMPANY
/// <summary>
/// 法人身份证 上传文件列表
/// </summary>
public fileinfo[] cardfiles { get; set; }
public fileinfo[]? cardfiles { get; set; }
/// <summary>
/// 营业执照 上传文件列表
/// </summary>
public fileinfo[] licensefiles { get; set; }
public fileinfo[]? licensefiles { get; set; }
}

@ -72,7 +72,7 @@ public class OP_YARD_BOOKInput
/// <summary>
/// 上传文件列表
/// </summary>
public fileinfo[] Files { get; set; }
public fileinfo[]? Files { get; set; }
/// <summary>
/// 修改人

@ -75,7 +75,7 @@ public class UserInput
/// <summary>
/// 实名认证 上传文件列表
/// </summary>
public fileinfo[] Files { get; set; }
public fileinfo[]? Files { get; set; }
}

@ -264,6 +264,10 @@ public class CompanyService : ICompanyService
{
return DataResult.Failed("审核通过或待审批状态不能提交!");
}
if (model.cardfiles.Length == 0 || model.licensefiles.Length == 0)
{
return DataResult.Failed("相关认证资料未上传不能提交!");
}
//更新状态为待审批
exitCompany.AuditStatus = 0;
db.Updateable(exitCompany).ExecuteCommand();

@ -221,10 +221,10 @@ public class UserService : IUserService
/// <returns></returns>
public DataResult EditUser(UserInput model)
{
if (model.Files.Length == 0)
{
return DataResult.Failed("实名身份证资料不能为空!");
}
// if (model.Files.Length == 0)
// {
// return DataResult.Failed("实名身份证资料不能为空!");
// }
if (model.Gid.ToString().IsNullOrEmpty())
{
return ADD(model);
@ -252,6 +252,7 @@ public class UserService : IUserService
//开启事务
db.Ado.BeginTran();
var user = model.MapTo<UserInput, tb_User>();
user.Gid =Guid.NewGuid();
db.Insertable(user).ExecuteCommand();
var gid = user.Gid;
@ -353,7 +354,11 @@ public class UserService : IUserService
{
return DataResult.Failed("审核通过或待审批状态不能提交!");
}
var exitCount = db.Queryable<tb_User>().Where(x => x.CompanyId == exitUser.CompanyId).Count();
if (model.Files.Length == 0)
{
return DataResult.Failed("实名认证资料未上传不能审核!");
}
var exitCount = db.Queryable<tb_User>().Where(x => x.CompanyId == exitUser.CompanyId && x.Status == 1).Count();
if (exitCount>4)
{

@ -1179,3 +1179,21 @@
2022-10-19 17:38:57.5041 Info NLog, Version=5.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c. File version: 5.0.1.1159. Product version: 5.0.1+a3718b8417284a90b0f73b2cbba47bc4067f6a3a. GlobalAssemblyCache: False
2022-10-19 17:42:27.6704 Info AppDomain Shutting down. LogFactory closing...
2022-10-19 17:42:27.6963 Info LogFactory has been closed.
2022-10-19 17:57:47.3405 Info Message Template Auto Format enabled
2022-10-19 17:57:47.3675 Info Loading assembly: NLog.Web.AspNetCore
2022-10-19 17:57:47.6016 Info Adding target FileTarget(Name=allfile)
2022-10-19 17:57:47.6081 Info Adding target FileTarget(Name=ownFile-web)
2022-10-19 17:57:47.6523 Info Validating config: TargetNames=allfile, ownFile-web, ConfigItems=47, FilePath=D:\Code\DS\YardBookSolution\yardbookapi-service\DS.WMS.WebApi\bin\Debug\net6.0\NLog.config
2022-10-19 17:57:47.6863 Info Configuration initialized.
2022-10-19 17:57:47.7011 Info NLog, Version=5.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c. File version: 5.0.1.1159. Product version: 5.0.1+a3718b8417284a90b0f73b2cbba47bc4067f6a3a. GlobalAssemblyCache: False
2022-10-19 18:07:00.3769 Info AppDomain Shutting down. LogFactory closing...
2022-10-19 18:07:00.3981 Info LogFactory has been closed.
2022-10-19 18:08:11.5695 Info Message Template Auto Format enabled
2022-10-19 18:08:11.5811 Info Loading assembly: NLog.Web.AspNetCore
2022-10-19 18:08:11.8167 Info Adding target FileTarget(Name=allfile)
2022-10-19 18:08:11.8167 Info Adding target FileTarget(Name=ownFile-web)
2022-10-19 18:08:11.9111 Info Validating config: TargetNames=allfile, ownFile-web, ConfigItems=47, FilePath=D:\Code\DS\YardBookSolution\yardbookapi-service\DS.WMS.WebApi\bin\Debug\net6.0\NLog.config
2022-10-19 18:08:11.9603 Info Configuration initialized.
2022-10-19 18:08:11.9749 Info NLog, Version=5.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c. File version: 5.0.1.1159. Product version: 5.0.1+a3718b8417284a90b0f73b2cbba47bc4067f6a3a. GlobalAssemblyCache: False
2022-10-19 18:29:14.4277 Info AppDomain Shutting down. LogFactory closing...
2022-10-19 18:29:14.4593 Info LogFactory has been closed.

Loading…
Cancel
Save