ASP.NET Core 中 Controller A Action 中如何返回 Controller B Action

请问在 ASP.NET Core 如何在一个 Controller 的 Action 中返回另外一个 Controller 的 Action?

回答

  • Controller 注册为service, 在A里面注入B 直接call method.
  • A里面new B 并给httpcontext赋值然后call method
以上是ASP.NET Core 中 Controller A Action 中如何返回 Controller B Action的全部内容。
THE END
分享
二维码
< <上一篇
下一篇>>