Why are parameters serialized on ShowViewModel<Type>? - xamarin.ios

Within Mvvmcross when you want to navigate to a different viewmodel you call
ShowViewModel<T>();
within a viewmodel that derives from MvxViewModel. All that is fine but I'm wondering why it serializes and deserializes when you do the likes of:
ShowViewModel<T>(new Person("firstname", "lastname"));
I'm fine that it does of course, and I can think of a few reasons why it does that but I'd like to have it spelled out here as it may also help others understand what's happening at a lower level within MvvmCross. Thanks in advance.

Because on Windows Phone and Android you can't just pass anything between Pages or Activities. On Windows Phone you have URL's that you can give a Page, which MvvmCross uses by adding your serialized parameters to it. On Android you have Intent's where you can put extra strings, bools etc. So it also serializes it and adds that as an extra thing in the intent.
Not sure how it works on iOS but that is basically the reason as to why. If you have a better way to do this, I suggest you make a pull request :)

Related

Fluid variables do not read the child values anymore. (TYPO3 9.5.*)

So i have a table which lists some appointments. These appointments belong to an event. The goal here is to list all the appointments and get the information of the event that they belong to.
So far everything works fine until i try to get the information of the event. I get an object which looks like this:
Now if i use something like this : {appointment.event.title} it will give back NULL.
That means that it doesnt access the properties. In TYPO3 v8 it works perfectly, but not in TYPO3 v9.
If i activate the <f:debug>{appointment}</f:debug> and get the whole object as debugged, then this {appointment.event.title} works! I can get the title.
The question now is what have changed since TYPO3 8 and can not access these properties anymore and how can i regain access?
In use: TYPO3 v9
Mode: Composer
Best regards,
I found the solution to my problem.
Thanks to #Claus Due i visited my Model to see if the getters und setters are there. They were there BUT before my getter, the #lazy parameter was present. After i removed, everything worked as it should.
Thank you!
Probably one of the following is true:
You forgot to add a getter method for the property you try to access and you are confusing the output of f:debug with what is actually gettable from the object. The debug ViewHelper outputs also protected properties.
You constructed the model object with __call or __get so you are affected by https://github.com/TYPO3/Fluid/pull/438 which is solved but not yet released (current Fluid version is 2.6.0, patch will be included in next version).
You don't say which TYPO3 version you use, nor if you are using composer, so it's hard to tell if your versions of Fluid are the same - they should be, since both TYPO3 v8 and TYPO3 v9 use the same external Fluid library.
The solution in either case is to add proper getter methods to your domain model object and always remember that the output of f:debug does not 100% correspond to what you can actually access: f:debug will for example not show virtual getter methods that don't have a property associated with it.

NetSuite 2015_2 PHP-SDK Two Factor Authentication

We currently have Two Factor Authentication working in the 2017_2 release of the NetSuite PHP Toolkit, but we have some code that has broken due to changes between 2015_2 and 2017_2. It seems that in 2017_2 it is also far easier to set up Two Factor Authentication.
Looking at the code, however I do see references to TokenPassport and TokenPassportSignature, which tells me that I should be able to get TBA working in 2015_2, which would give us time to figure out the rest of the issues.
My question is: How would I actually go about that? I have set $service->passport to the generated TokenPassport object. I know that my TokenPassport object works in 2017_2, and I assume it would be the same, but I don't know for sure, and I can't seem to find any information up on Elgoog.
ETA: I have seen examples of this working in 2015_2 in Ruby, but not in PHP. The backend is there, but I can't seem to be able to do this in PHP, and the Ruby examples were only snippets.
Okay, so I solved this for myself, but I may not have done it the "right" way. Here's what I did:
I took the makeSoapCall and setTokenGenerator methods from the new instance of NSPHPClient.php, and I added them to the OLD version. I had to modify the setTokenGenerator method to not require an instance of iTokenPassportGenerator, but I could have just as easily copied over that interface as well.
Basically, all that needs to happen is that we need to send the tokenPassport header, which the older version of the SDK can generate but doesn't have a method to actually send that I could find.

Is there any difference for XPages urls using action=openDocument and action=readDocument?

Most times I've seen urls written to open an XPage in read-mode using action=openDocument, but occasionally, I've see action=readDocument used. Just curious if there are pros/cons in using one vs. the other.
I don't know of a difference. Honestly I never use these URL's anymore myself. So it's really not a big deal very likely.
Keep in mind, you don't need to use these at all of you don't want. You can pass your own parameter in the URL and then via SSJS access any parameters with the param object. You can also get the parameters in Java easily enough.
Just a thought.

QMultilineElement not calling QEntryDidEndEditingElement: on delegate

I'm trying to use QuickDialog (github.com/escoz/QuickDialog) to make a tablew view showing some debug info, like the values of constants etc. Most of the values are long URLs so i can't use a QLabelElement. QMultilineElement seems to be perfect for this but i need to know when the user modify the text of the pushed text view and i can't figure out how to do it.
QMultilineElement has a delegate property but i can't get it to get called. Looking in the code it seems to me that that delegate only works with QLabelElement, is it true? what am i missing?
I believe I ended up implementing this one, no? Can you confirm?

Accessing YUI RichTextEditor node

I'm inserting images to editor with id param. after that i'm trying to access it with Dom.get('id'), but it returns null.
I understand that it returns null because it works under parent window's scope. Is there any standard way to access it?
For specialized YUI-related questions, and especially if you don't get the answer you're looking for on StackOverflow, you may want to post to http://yuilibrary.com/forum -- the YUI devs and many YUI specialists spend time there, and that's typically the best place to get YUI-related help.

Resources