-
Notifications
You must be signed in to change notification settings - Fork 220
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make BuildFile work without a controller context #88
base: master
Are you sure you want to change the base?
Conversation
Update demo to MVC 5
Like it, thanks |
Great work. A few indenting issues or maybe thats just Github doing that on it's preview of the diffs. Hopefully this gets merged soon as its been sat around a while. |
Never mind those references are broken before your commits. I think I may try cherry picking your changes onto latest stable. |
Did this ever actually work for you? I have built a new version with your patches ontop of current master branch of this repo. I havn't pushed the code yet due to login logistics on the machine I need to figureout. I got a custom DLL compiled for dotnet framework 4.5 and it all works besides when it goes to call I get a framework error as it gets further down the stack:
|
@2E0PGS It did work for me years ago when I used this. I haven't used this since mid-2015, so I'm not sure about its current state. Sorry. |
Yeah I don't this patch would even work after the amount of debugging I did.
I even tried these changes ontop of latest base and it didn't work. Same deeper issues with razer render framework not rotativa. This is probably why rotativa doesn't support Api type base controllers anyway.
In the end I made a new class for doing controller context spoofing which allows me to call Rotativa from an ApiController and have it find the correct views when building a PDF from a Html view.
I can share the class if anyone needs it.
Cheers,
Peter Stevenson (2E0PGS)
http://www.m3pgs.co.uk
…On 10 Aug 2018, 16:43, at 16:43, Justin Maier ***@***.***> wrote:
@2E0PGS It did work for me years ago when I used this. I haven't used
this since mid-2015, so I'm not sure about its current state. Sorry.
--
You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub:
#88 (comment)
|
@2E0PGS Could you please share the class? |
https://gist.github.com/2E0PGS/7ef85843464f29aba8335ae204fa56cd
Sent from BlueMail
…On 11 Apr 2019, 10:57, at 10:57, Johannes Binder ***@***.***> wrote:
@2E0PGS Could you please share the class?
--
You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub:
#88 (comment)
|
I've been using this project for a few years now and more than once I've had to modify it to remove the dependency on
ControllerContext
so that I could create PDFs in WebAPI and outside of a normal MVC Controller.ControllerContext
in most cases was replaceable byHttpContext.Current
.To perform the tests I had to update the demo and the unit tests to MVC 5. After the update all of the tests passed successfully.