多公司应用的电灯设计模式 [英] Lightswitch Design Pattern for Multi-Company Application

查看:76
本文介绍了多公司应用的电灯设计模式的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想知道是否有人可以提出一种设计方法来创建Lightswitch可以安装在多公司/数据库方案中的应用程序.例如, 您将其安装到企业中,并且可能需要培训数据库和生产数据库.最好不必为每个环境都安装两个单独的应用程序.最好,我想问一个用户(在表单登录时) 他们想要工作的公司.此后,所有应用程序查询和逻辑都将与特定的数据库一起使用–当然,所有数据库都具有相同的结构.

I was wondering if anyone can present a design approach for creating a Lightswitch application that can be installed in multi-company/database scenarios. For example, you install into an enterprise and you may want to have a training database and a production database. It would be optimal not to have to install two separate applications for each environment. Preferably, I would like ask a user (at form login time) what company they would like to work in. Following this, all application queries and logic would be working with a particular database – of course all database would be of equivalent structure.

推荐答案

您*可以*这样做在LS&之间的自定义RIA服务层外部数据库,但这并不是创建LS的那种情况,因此您无法立即获得像这样的功能.

You *could* do this with a custom RIA services layer between LS & an external database, but this is not really the kind of scenario that LS was created for, so you don't get functionality anything like this, out-of-the-box.

使用自定义的Silverlight控件& RIA服务几乎是可能的"任何事情,这仅仅是您准备编写多少代码的问题,&您希望LS为您做什么?

With custom Silverlight controls & RIA services, just about anything is "possible", its' simply a matter of how much you're prepared to code yourself, & how much you expect LS to do for you.


这篇关于多公司应用的电灯设计模式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆