Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
Meteor doesn't have a built in validation smart package yet. What validation libraries should I consider? What are other people using?
We decided to use simpleSchema with Collection2 and autoform for validation. It's a very sophisticated solution. We save a lot of time using this approach rather than trying to roll each form by hand.
Simply by defining a scheme with validation rules (validation rules are provided automatically for data type and isRequired settings) then creating a form with autoForm (a single line of code) and you get all this for free
An autogenerated form that uses bootstrap3 classes.
Appropriate HTML5 fields for all keys in your collection schema.
A submit button that gathers the entered values and inserts them into your collection.
Form validation based on the schema attached to your collection. By default the form is validated when the user submits. If anything is invalid, the form is continually re-validated on keyup (throttled) as the user fixes the issues.
Default validation error messages that appear under the fields, and can be customized and translated.
meteor-simple-schema
A simple, reactive schema validation smart package for Meteor.
https://github.com/aldeed/meteor-simple-schema
meteor-collection2
A smart package for Meteor that extends Meteor.Collection to provide support for specifying a schema and then validating against that schema when inserting and updating. Also adds support for virtual fields.
https://github.com/aldeed/meteor-collection2
meteor-autoform
A smart package for Meteor that adds UI components and helpers to easily create basic forms with automatic insert and update events, and automatic reactive validation.
https://github.com/aldeed/meteor-autoform
If you want to use meteorite, you can just search through the atmosphere packages to see what's popular. I'm currently using jqBootstrapValidation. In the past I have used validate.js, but right now I prefer to have something with bootstrap integration. I hear parsley.js is popular with the cool kids, though as of this writing there isn't a smart package for it - but that's easy enough to solve.
You already have Tracker as part of Meteor, so I put a little tutorial and JSfiddle together on how to use it to implement a typical form validation scenario.
http://bit.ly/meteor-form-validation-video
http://bit.ly/meteor-form-validation-fiddle
Related
Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 10 years ago.
Improve this question
We have an ASP.NET web-application which has become difficult to maintain, and I'm looking for ideas on how to redesign it. It's an employee administration system which can be highly customized for each of our customers. Let me explain how it works now:
On the default page we have a menu where a user can select a task, such as Create Employee or View Timesheet. I'll use Create Employee as an example.
When a user selects Create Employee from the menu, an ASPX page is loaded which contains a dynamically loaded usercontrol for the selected menuitem, e.g. for Create Employee this would be AddEmployee.ascx
If the user clicks Save on the control, it navigates to the default page.
Some menuitems involve multiple steps, so if the user clicks Next on a multi-step flow then it will navigate to the next page in the flow, and so on until it reaches the final step, where clicking Save navigates to the default page.
Some customers may require an extra step in the Create Employee flow (e.g. SecurityClearance.ascx) but others may not.
Different customers may use the same ASCX usercontrol, so in the AddEmployee.OnInit we can customize the fields for that customer, i.e. making certain fields hidden or readonly or mandatory.
The following things are customizable per customer:
Menu items
Steps in each flow (ascx control names)
Hidden fields in each ascx
Mandatory fields in each ascx
Rules relating to each ascx, which allows certain logic to be used in the code for that customer
The customizations are held in a huge XML file per customer, which could be 7500 lines long.
Is there any framework or rules-engine that we could use to customize our application in this way? How do other applications manage customizations per customer?
If your regular data is held in a database I'm not entirely sure why you'd want to have all of that customer specific information in an xml file. Move it into the database.
Next, there are many different kinds of rules engines out there. Considering you're using asp.net you might want to look at Windows Workflow for at least some of this. You might read the following: http://karlreinsch.com/2010/02/05/microsoft-rule-engines/
A long time ago I used a product called Haley Rules to drive a c# web app. It controlled everything from the screens that were available right down to the fields that appeared and whether they were required or not. It took awhile to get the team on board with how it worked, but once that happened bringing on a new client was extremely simple. Haley was since gobbled up by Oracle, but was probably the absolute best one out there.
Others you might be interested in are NxBRE and even nCalc. NxBRE is an actual rules engine which is a port of one built for java. nCalc on the other hand isn't a rules engine per se. However, if you can express your logic in simple boolean statements then it is extremely fast. I'm currently using this to drive page flow in one of our applications.
Some commercial ones include: FlexRule, iLog
Your existing rule engine tool supports your web application, which means it meets your needs already. You can use other "Rule Engine" like MS work flow, but IMO it can also end with a hard to maitain situation.
Let's say there is registration portal. It collects general user infomation and save them into database. Simple. we build one protal for one client with several ASCXs and Rules.Then for another client,we add more rules and more controls to these ASCXs. Working in this way, sooner or later we will reach the final straw client. At that time the code base is hard to maitain and devs lost themselves in lots of rules. It is what happened to me.
So to me, it is not about which Rule engine to use.
Then How?
I have raised a question, and one of the answer makes sense to me( thought not a picked answer). In this answer, the guy mentioned what kind of company you are. In your question it is more like which department you are or do you want to seperate your dev teams.
If you are in a archetect teams, build a framework with a rule engine. Create a basic registraion portal as a sample portal.Make DAO,BO decoupled with UI (Seperate layers).
If you are in a customise teams, create customised user control (dont reuse these user control in basic version). What you will recreate is just UI, you can still use DAO,BO as they are not defined in user control, they are at other layers. In this way you get the freedom to define your client specified rules without worring about contaminating other clients rules or introducing new bugs to other client's registrations.
Just realise it is not like an answer to your question. Anyway it is my thoughts after limited xp of working on a engine rule based ,multi-clients web application.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
I'm relatively new to Drupal, but not CMS's in general. I'm creating a site for a client. The most important part is creating a fairly complex form in which users input various types of data to be stored in the database. I had assumed the best method for doing this was to create a custom module. Is this the case, and if so can someone direct me to documentation or a tutorial on the best way to create a module of this nature? If not, I'm open to suggestion for the best way to create this kind of form even if it is hardcoding the content.
Drupal.org contains detailed tutorials on how to create modules, see for example this one.
The Drupal Form API will be your friend to handle easy data capture: How to use the Form API.
Depending on your data capture needs, the Webform module may already do what you want.
In drupal there is a Form API to do this, a very good working example is used in the documentation at drupal community, here are the links for that:
Drupal 7 Form API introduction
Form API reference for Drupal 7
And one more thing Never go for hard coding things try taking the advantage of all available API's.
You haven't detailed who the users are that will be inputting data into the form, the complexity of the form or what you will do with the data so I'd like to present you with some other options.
Custom Content Type
You can create a custom Content Type and assign appropriate permissions so that users can fill in the content creation form and it can be saved in the database as a Node entity. The Node is a core Drupal entity and therefore already has many built in capabilities for sorting and displaying using the Views module and permissioning, etc.
But the users filling in the "forms" (ie. creating Nodes) have to be registered Drupal users.
Webforms Module
Drupal has a Webforms module which will allow you to create a form without having to do any custom coding. The module looks after creating database tables and already has a lot of built-in functionality.
Refer to the other answers if you find that it's still most appropriate to create your own module.
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 2 years ago.
Improve this question
I believe that one needs to buy a license(?) to use devexpress. I'm currently implementing a gridview and want the sorting arrows to appear in column headers. I know that devexpress grids have that feature and I believe many more? Could anyone point out any specific reason why someone would pay for using a devexpress grid, or I guess the devexpress suite comes with a lot more than just grids?
Could anyone point out any specific reason why someone would pay for using a devexpress grid, or I guess the devexpress suite comes with a
lot more than just grids?
Here is your reason of paying for the third party controls, In Short features give preference to use these rather than the standard controls.
it’s unlikely for the client to have a specific request about some user interface component that can’t be satisfied with either default controls or 3rd party controls. Many of the convenience aspects like detailed view, sorting, auto completion, filtering, and changing perspective have already been solved by the 3rd party companies over the several versions of the controls.
When in need for some UI functionality, it’s better to search the companies’ websites for something suitable, instead of trying to develop from scratch. It will also certainly be cheaper than going over the document, develop, debug, test, and deploy cycle countless times.
By using 3rd party controls it’s easier to keep focus on the actual business functionality for your project, to spend time developing visible features for the application, than to work on solving the many background technical difficulties associated with developing every functional request.
On the other hand, if you reach the conclusion that the control would require some serious modifications in order to suit your needs, it’s probably better to do the entire development in house, eventually based on the simple default controls that come with the .NET Framework.
For example, I do use devexpress controls, on which project i am
working they specially require a developer with knowledge of
DevExpress control, because that will reduce the development time(
Project completion Time also) rather than using the standard control.
The Specific requirement make them to pay for the controls as those
guys commented in this SO thread.
Check these for feature comparison - Standard GridView vs DevExpress GridView. I like it's client side functionality..
Here's a reason. Because they want sorting arrows in column headers. Also, any of hundreds of other features these products provide that the default grid does not.
The point is, the extra features ARE the specific reason.
Not only does it take care of operations such as sorting and search. It is actually very useful in helping you populate data from your database easily by quickly mapping your fields to IQueryables (If you are using C# and not DevExtreme). If you're using the grid on many pages in your platform, you can easily configure all these grids from one single point (Themes, Functionality, Configuration, etc...). It also provides additional security measures to prevent certain injection attacks. Finally, it is always updated with new features and improvements with constant releases. One really important thing too is that the DevExpress help center and forums are very rich and you will find an answer for almost any question or issue you come across. So using the DevExpress component will bring scalability and increase reliability with time for your platform.
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 6 years ago.
Improve this question
I just finished an intro to web dev course in my CS program and came away wondering something simple. When should you use JavaScript (client-side) instead of server-side (we used PHP but anything applies) code? Vice-versa as well.
There is no recipe for deciding that. A few notes:
security and validation should always be present at the server side (sometimes duplicated in the client).
the client-side should contain only UI-logic. No business logic.
logically, everything that accesses a database should be on the server.
Of course, if your application is a RIA (rich internet app), then you can have logic on the client. So it all depends.
Javascript should be only used to manipulate the UI of the page. You can also do certain validations using it, however, there must be corresponding validation on the server-side. For doing any data manipulation, applying business logic, etc you should always use server side code.
Here are some cases where you will use client-side code:
Changing the look (UI) of the page e.g. dynamically show/hide some
elements
Validate user inputs (this should also be done on server side)
Cases where to use server-side code:
Validation of user inputs (should always be done on server side irrespective of whether done on client side or not.)
User authentication
Business logic (deciding what to show to which users, calculations)
Database access
Imho i would say, use server-side if you can. All client-side code can be manipulated. Or maybe will not run cause the browser dont support it.
Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 11 years ago.
Improve this question
I am building a web site for baby names. Users can submit a name, meaning and some tags, and moderators can edit/approve it. Very small amount of data is used for each entry/post.
Looking for some kind of framework that supports the following features or I can easily extend it,
Unicode support
I have large number of names, I should be able to import them into my website by code.
User roles and permision
Some kind of report options. For example, Display list of names that starts with some alphabet or list of names for a #tag
Full text search
oAuth/OpenID
Are there any frameworks like Orchard, Umbraco I can leverage or would I be better off writing a new ASP.NET MVC application?
If I were you I'd surely stick to some available CMS platforms (Orchard or Umbraco) instead of writing from scratch and reinventing the wheel.
From my experience with Orchard I can say that setting up a website as you described would be pretty easy and painless with this platform.
Features like those you mention are already available in Orchard, but I guess (as with just about every CMS) this will surely need a little customization to suit your particular need. All the custom functionality could be easily wrapped in a single, custom content part. How to do that is very well described in the Orchard documentation.
Of course.
Without a problem. You have three options: import directly into Orchard DB (into the corresponding tables), import using Orchard Import/Export functionality (which would involve exporting the data to XML recipe format first) or just use the current data source without the need of importing. There was a question on SO a while ago of getting data from a custom WebService. The solution provided perfectly fits here, so please take a look.
Out of the box - described here and here.
I don't know if you meant the backend (admin) view or in the frontend? Tagging and displaying tagged items is available oob. More complex, custom reporting would involve some custom coding (writing a custom content part).
Available and described here.
Sure! It's available via very nice OAuth Module, written by Nick Mayne. It allows you to bind Orchard accounts with OAuth providers.
I don't have much experience with Umbraco though, so I can't give you any direct help, but I guess it'd be nearly as easy to built your website using it.
Personally, I prefer Orchard for its flexibility, extensibility and code freshness. But the choice is a matter of your personal feeling and preferences. From what I've seen they have very similar functionality, although differ much under-the-hood.