Multi-shell application? - silverlight

I am new to Prism.
Imagin a scenario where you want to develop a multi-region application, but there should are many types of screens and I want those regions to be in one screen only, whereas, for instance in the HomePage which is the application map (like in QuickBooks, see image bellow), there should be no regions, and the whole layout should be different.
Also I want that the application should be available for registered users only; unregistered users are automatically forwarded to the LoginView, and they're not supposed to see the regions etc.
How are these two aspects achieved?

I think I am going to implement the entire application using View-Based Navigation.

Related

AngularJS: Triangular three way binding -- Project Structure

I am currently working out an admin interface with a Live Preview and I am still not 100% on how to structure it properly.
My page basically consists out of two parts. The Admin Interface and the Live Preview. Obviously, the Admin Interface fills some variables with data and the Live Preview displays this.
Therefore, the Admin Interface needs to bind variables, that the Live Preview will bind for reading.
Furthermore, the Live Preview in the end (if possible) should be re-used as the final product that displays a set of information. All it does is display a single JSON file that is received from the server (when in product mode) and in case of the Live Preview it will need to update the data Live as its edited.
One more note: Both, the Live Preview and the Admin Interface consist of elements like directives again and parts of the Admin Interface need to be loaded dynamically by having a user add a page with a certain type of content.
After researching how modules are handled I came up with the following:
Live Preview is a Module
Admin Interface is a Module
My page includes both modules
Both of them should be connected to something central that provides the ability of editing the data (bound variables?) and reading the data so its updated live.
Ideally, this would be a service, so later on when loading the "Live Preview" as an actual product, can just use the same kind of service which in this case provides the information from our Database instead of a variable in its scope.
Is this a good approach? Is there a way to have a service that on the one hand side can be edited lively like in a two way binding so that my live preview can also pick it up? Is there something I can use instead of the services, like a controller? How should I go on about this?
You are doing everything right. I don't think that it is relevant as to whether the preview and admin panel are their own modules or contained within one. You will find people using module seperation in a wide variety of ways within their Angular apps.
What I think you said that is important and correct is to connect the preview and admin panel via a Service. Other methods of connecting these two (i.e. $rootScope) are costly and bad practice.
If you will be re-using live preview in many locations of your application I would wrap it in a directive.
You should feel confident in your approach, it's a good one.

Is Page Object Pattern suitable for Windows Application

I have read that Page Object Pattern is suitable for the Web Application Automation and I have used the Page object pattern with Selenium for one of the Web Apps I have automated.
How ever I am curious to know is Page Object suitable to Windows/Desktop applications ?. Though there is a scope in Windows Apps as well to create different Top level Windows as Pages and expose the operations as methods.
Has any one tried this and want to know the experiences/Advantages/disadvantages
The key equivalence here is page <=> dialog.
In a web app you encapsulate each page in a page object, while in a desktop app you encapsulate each dialog in an object that you might call a "dialog object".
The point is the encapsulation.
Over at my blog I've written about DRY page objects for testing web apps, but if you substitute dialog for page, it will apply equally well to dialog objects for desktop apps:
-- Keep Your Page Objects Clean and DRY
yes we can automate the desktop based application with Page object. you can refer WinAppDriverPageObjectModel

changing winform properties for different clients

I have a winforms app and want to customize for differents clients, I need a simple mechanism to create a version for client1 with one commandline app for example. I only want to change the color of the window and of buttons and a smart logo. I dont want to change it manually every time I need a client1 version.
Maybe you can put in your app.config some configuration tags, some properties you need. And then let's say, through your setup process, you modify the configuration based on client desires( that's if I understood correctly.
I don't know what kind of app you have but I had an app that is accessible for 3 different types of users which are admin, receptionist and patient. I used password authentication and inside the forms, I used simple if/else clauses according to authentication types to arrange which user could use which parts of the app. But as far as I understand you need something like an interface in case any other client takes part in the app later.

Need help creating a skeleton for a client portal on DNN

Total DNN noob. I can code some WebForms and MVC, but having no luck finding anything concrete out there about doing what I want in DNN
How would I go about setting up a client portal in DNN? I want to have separate areas for the client, including a main dashboard that aggregates content for the client from the other areas. The other areas would include a matter area (with matter information - some auto generated for client, other information to be input by client), a documents area, an events area, a tasks area, a communications area (for chat, or forum style questions) and a profile area for the client (contact info, invoicing, etc.).
What I'd like is for a client to login and see only their items. An admin would log in and get the same "screens" or "areas", but with aggregated content for ALL users.
I know that's a lot, but I would imagine setting me up with a way to do the overall app and then how to create the areas to navigate to would get me going. I know there are modules for each of those things out there, but a) I wouldn't know how to integrate this into one client app and b) some are cost prohibitive.
Most of what I find focuses on setting up one module. Do I go that route and set up user controls within for the different areas? Or do I create separate little modules and tie them together? This is primarily where I am stuck. I can create something like this with standalone web forms or MVC. Hooking into DNN is where I get stuck.
I appreciate any guidance / samples.
There are a LOT of questions here and many ways that you can go about doing this. You could use third-party modules to handle this but you will need to figure out exactly which ones give you the functionality that you want.
If you are looking to do things custom, this is where it gets a lot easier. DNN for users can manage user identity and roles. Based on what you are saying it seems like you would have some custom modules that store all information based on UserId. By default you only display the information for the current user. However, if the user is in a specific role, say for example "Administrators" you would display all content.
This is pretty easy as with any DNN control that inherits from PortalModuleBase you have the UserId available to you as a property. Then you can use UserInfo.IsInRole("Administrators") to check for admins.

Navigation application - Forces a page at startup

I have a silverlight navigation application where I load and initialize a lot of things in the MainPage.aspx loading.
All the Pages (views) are dependent on the loading of that data.
But really often my users add an internet shortcut on their desktop for my application. but the link often points to a specific page like that :
http://myServer/MyApp/default.aspx#/TheView
I want to force the users to go to the "Default" view (and ignore the #/view parameter) when the application Starts up.
Whats the best way I can do that?
I don't think it's a good idea to 'avoid' links. You should construct the application in a way when it's not a problem.
For example you can send a message from your main logic when everything loaded, and until that message you can disable the appropriate UI (while waiting for data). Messenger (or EventAggregator in Prism) is a publisher-subscriber pattern to achive communication between components without reference to each other. If you don't know it yet, take a look at MVVMLight Messenger or Prism EventAggregator
But if the first option is not okay for you, you can play with the Frame control's JournalOwnership property:
http://msdn.microsoft.com/en-us/library/system.windows.controls.frame.journalownership(v=vs.95).aspx
http://msdn.microsoft.com/en-us/library/system.windows.navigation.journalownership(v=vs.95).aspx
OwnsJournal is your value, because it does not integrate with the browser journal and the url stays the original so your users can't bookmark a 'sub page'.
You can also implement your own journal mechanism.
Another :), but pretty ugly option would be if you track the first page load (in OnNavigatedTo Page events for example), and at the very first request you manually navigate to the main page. Or in the App.xaml.cs, when application starts up you forward the page request.
But I recommend the first one.

Resources