Is producing a POS software in HTML/Javascript Viable? - javascript

My Family Owns a Restaurant and for various reasons, I want to make a POS software to replace the one they currently use. I am most comfortable making GUI in html/css so, if possible, I would like to take this path. I just have a few concerns.
Are There existing API's for dealing with printers, registers and credit card machines?
Can I make these applications run on Linux, and if so, how? (I Know Linux Can't Run .hta)
How would I go about connecting multiple terminals within the code?
I don't expect I walkthrough, but any information would be greatly appreciated.
Also, if using html/Javascript isn't viable, I would be open for suggestions. I am comfortable coding in C++ and Python, however I dont know of any easy ways to make GUI's with these languages.
Thanks!

In short, no. You could use HTML/JavaScript for the front-end, but if you have multiple terminals, and printers etc. you will need a back-end infrastructure of some description which will need to be a server-side language; preferably something like ASP.net, PHP etc.
You'd need to design an architecture, design a database schema, work out the interfaces between all parts of the solution and design a user-friendly UI... the right place to go to get this question answered is to enroll on a degree in computer science and get a few years experience in developing these systems!
Sorry to be snarky but this is a big undertaking; if it were me, I'd not commit to doing it for a family business as my first web application. There are huge risks around payment card information and customer personal information that, if you get wrong, could lead to serious business risks.
Edit: A very quick google search lead me to http://www.unicentaopos.co.uk/ one of many free, open source POS systems. the one linked seems specifically geared toward restaurants.

Yes, You can do it with this. But, it will depend upon your receipt printer, if you have a cash drawer. For example, the TSP100 Receipt printers connect to a cash drawer and when printing, you can open the drawer. It is independent of the application.
As for the backend, you obviously cannot do that with HTML/CSS. You have to know how to design databases.

Related

Getting formula from website calculator

So this is an issue I come across frequently... there are many medical website calculators online that health systems would like to use, but the formulas, equations and statistical models aren't readily available. I was wondering if it would be possible to use Developer Tools on chrome or something similar to find these in the javascript? I can find pages of calculations when I mine into the data but nothing that makes sense to me. (EX: http://riskcalculator.facs.org/RiskCalculator/PatientInfo.jsp)
Yes and no. If everything works on the client side you should be able to read the code if you really need it. There's an option to "prettify" the minified script in chrome dev tools (sources -> "{}" icon below the editor).
However, I'm not so sure if reusing it won't violate a law in some countries.
Also, I believe if this is some kind of expensive information, the website authors would rather send input to a server and send back a result. You could also do some reverse engineering by watching the I/O in numerous ways.
I'd suggest writing to them directly first and as if they are willing to share the algorithm with you.
Additionally just do a research on the topic you're interested in. Most of those calculators are using publicly accessible knowledge which is pretty easy to write as a script.

OSS License for "look but don't use it to compete with us"? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about programming within the scope defined in the help center.
Closed 7 years ago.
Improve this question
Is there a well known Open Source license that would allow me to open source some mission critical code in such a way that the community could read it, but that would simultaneously prevent competitors from using it to gain an advantage over us?
I'll give you a bit more context. We are developing quite a complex and serious business analytics tool for which we decided to create our own in house javascript MVC framework. As part of the project we also built a bunch of reusable controls that seamlessly integrate with the framework for things like switches, tables, autocomplete search boxes, navigation controls, etc. (think Cocoa controls or jQuery UI).
We'd like to release the framework itself and the controls to the community for better or worse under the Apache2 license, fairly standard stuff there. However, and this is really what I'm asking, we would also like to show the source of our SaaS analytics app (the one that powers our business and generates revenue) for the purpose of demonstrating how a complex enterprise app can be built on top of our framework, for it to be sort of like a rigorous proof-of-concept/case study/demo. But we don't want competitors to just clone the repo and deploy it on their servers with some rebranding and start stealing our customers. Is there a well known open source license that could facility this type of information sharing for the benefit of the community whilst simultaneously precluding competitors from gaining a competitive advantage from it? (I mean obviously our competitors might learn a thing or two and that's fine, but we want to have legal power in case they blatantly copy parts of our code and use it to compete against us; and the judgement of whether they are copying or not should be at our sole discretion).
I think you should look at the Microsoft Reference Source license..
Microsoft does pretty much what you outlined up there with the .NET library.
But as always with these license questions:
Don't take the word of a bunch of internet strangers - ask a lawyer familiar with the topic before you do anything you might regret.
Also, on a side-note: With all my love for OSS software - Regardless of what your competitors do, the second they have your source they can blatantly copy you (and they will if you are successful enough). And once that has happened you have to spend a pile of money on lawyers trying to get to your rights.
Especially when it's the heart of an operation, I'd label that as "competitive advantage" and not release it to the public. It's your IP, once you give it out to someone anyone can simply take your ideas and write his own app with it - no license in the world can prevent that (besides stupid patents you probably don't have).
So my advice here would be to just wait a bit and see how the MVC lib turns out.
Look at Ruby on Rails. It's been developed as part of Basecamp at 37 Signals, but the Basecamp source code never became public simply because there is no need for that. If the framework is any good people will use it and you'll get organically to sample applications.
Having real world examples is nice, but especially for JavaScript frameworks you should aim to be pretty backend-agnostic - so it shouldn't really matter if you run ASP.NET MVC or Rails or Node on the backend. The logical consequence is that the backend code is of no real interest to your library users.
They can see the library working on your site, that in itself should be enough to show useful usage patterns.
If you take some parts out of your app and show them to users you'll be fine without the risk of lawyering to get to your rights..
No. The purpose of any Open Source license is to give the code to the community to further develop, fork, or use for other purposes. The whole point of having a license is purely to prevent complete theft of code without attribution. If code that is claimed as original appears down the road can be proven to be based on your work, you have sufficient grounds for legal action.
The best way to demonstrate a proof of concept is to take discrete parts of your work as an overall demonstration of the value of the framework.
But, I'm no lawyer so I would suggest that you consult with one before doing anything that might jeopardize your business or your job.

Facebook game development, University project, Front end woes

I have been requested to make a port of an iOS game for Facebook.
The game itself is fairly simple, it is a puzzle game using a 2d array for a grid with XML passed from a server for loading objects onto the the grid, to create levels.
The game will ask questions at stages which will be passed to my server and stored for research purposes.
Some questions for those with experience.
What front-end options do I have with Facebook?
I have looked into both Flash and HTML5/js both of which i have little to no experience in (I'm experienced in Java/C#/Ruby + Rails).
Javascript seems like a nightmare from what I have read, even looking into javascript game engines, but at least it is free.
My backend will most likely be rails for handling server logic.
Summary(because I ramble too much)
-Is javascript for programming games really a problem for simple games on Facebook?
-Are js game engines worth using? Does anyone have any experience with them?
-Would prevention of cheating be possible with a js/rails game, do server side checks work?
-Are there any alternatives for a front end for someone with C#/Java/Ruby background?
I've never seen any Unity or Java apps on Facebook(I don't use it much) and I don't know if the licensing will be an issue for this research project.
Any input from those experienced would be greatly appreciated, I feel a bit lost with all the potential options.
Answers to the summary
-No, it is not a problem.
It brings with it certain challenges that will need to be understood, but it is a mature platform with loads of online documentation
-Definitely, but maybe not even necessary. It doesn't sound like your game is that complex, so you can probably feel comfortable trying any engine and seeing where it takes you. You may be more in need of data frameworks to deal with synchronization and management of state. I can't really recommend much without knowing more.
-Yep, preventing cheating is definitely possible. If banks can prevent arbitrary money exchange or invalid transactions, you can prevent cheating in a facebook game. You'll have to validate a lot on the server side, but that's par for the course.
-Besides flash, no. It's a javascript world out there. Flash has a lot of potential for serious games in the future, but if I were new to both I would probably bet more on JavaScript for the various other benefits it brings to the table (general web interaction, server side programming, etc)
If you are unconvinced of what JavaScript is capable of, head over to a site like chrome experiments to see what people are squeezing out of browsers nowadays.

Need help determining how to approach building my project

I'd like to create something similar to a family tree online app (like geni.com). I'm unsure what languages I should use to build it with. My IT strong points aren't in programming and this project is going to require me to sit down and learn some languages. My problem right now is that I don't know what languages I should use.
So with the idea of a family tree online app in mind here are some of the specifications.
- I do not want to use flash.
- The app needs to be zoomable and scrollable (sort of like google maps)
- The app needs to be able to add content without reloading the page. Perhaps there's a little "+" sign and when I click it, I can add a tag/title/description/picture
- The app needs to be able to save your work for that user to retrieve later on.
- The layout that a user is able to create in is sort of widget based where the user can add a new bubble and then in that bubble they are able to add text or content.
I started programming this with HTML5 canvas and Javascript, but I'm stuck on creating a connection to the database that isn't directly from Javascript (because that seems very insecure to me). But I'm not just stumped on how to interact securely with the database (I don't even have a database picked out), but also I'm concerned that I won't be able to build out the app with just javascript and may need something else like ajax or something but I'm unfamiliar with what each language does nowadays.
If you are starting from scratch, then the best language to use is the one you are most comfortable with. Alternately, if you don't plan to be developing the whole thing yourself and you already have some other interested parties on board then the best language to use is the one that the majority of you are comfortable with. If it's just you and you do not yet have any favorites, then look around and play with a few - it's the only way to find out if you will actually like / be effective with them.
That being said, a few of the more likely candidates these days are:
JavaScript: Long gone are the days when this language was simply a way to put the D in DHTML. These days JavaScript is a viable client and server-side language. (Others here have already recommended Node.js -- I'd also recommend NPM (node package manager) to handle your dependencies). With a little bit of planning you can reuse most of your application code on both the client and the server side. On the downside, most of the server side technology is very new (only a few years old at most) and so you may find yourself implementing tools for use in your application rather than your application itself. Finding servers that support it will also be harder, again on account of it's age.
Perl: At the opposite end of the spectrum of age, we find Perl - the first commonly deployed language used to make web applications it still powers a great variety of useful websites out there (include new ones such as Pinboard.) The tools that are popular on CPAN have been vetted under fire. The good news is that it is not going anywhere anytime soon. The bad news is, you might have to search a little harder to find a module that supports [that newest, baddest thing that just came out yesterday].
PHP: The BASIC (or Perl, depending on who you ask) of the modern web, PHP was designed from the ground up to do one thing - make building dynamic web pages easier. Its popularity means that there is quite a lot of server support (PHP + Apache + MySQL is the Model T Ford of web servers -- everyone can afford one) and an enormous amount of pre-built code available for perusal. However, like BASIC, PHP's strength is also its greatest weakness. Almost anyone can write something that works in PHP ... how well it works depends on who wrote it. The caveat emptor that applies to all code snippets found on the web applies in spades to snippets of code written in PHP.
Python: The language that made programing fun again (at least for those who can see past the significant whitespace and lack of blocks / anonymous functions and overlook < 3.x's issues with non-ASCII out of the box.) It's a general-purpose, flexible and multi-paradigm language with quite a substantial standard library (but without .NET or Java's incredible bloat). In addition, quite a large amount of work has been done in it, so there is a good chance that what you need has been already developed by somebody else. Plus, it can make you fly.
Ruby (with or without Rails): The language that made the web fun, coupled, if you so desire, with the framework that made MVC cool. There is lots of documentation out there, and a great community, with many prebuilt tools (called gems) from which to pick and choose - free and cheap servers are not as common as their PHP counterparts, but they are likely to be of higher quality (when chosen at random).
All that being said, they are all great languages for web development. What matters is not what we think you should use ... but what you are most likely to be effective with. All of the languages listed above are mainstream (or will be in the next two years), easy-to-learn and easy-to-write languages. You cannot go wrong, no matter what you choose to start off with.
Alternately, if you want something a little more difficult, or less mainstream ... I am working with .NET applications at work, and with Lisp (SBCL)-based services in my spare time. I have heard great things about Lua and Java too ... there are at least two C++ web frameworks out there ... and I'm sure that there is somebody is having fun building a web service in COBOL with a FORTRAN backend. ;-)
As someone has already pointed out, you will need to work with a server side language as well. (Ruby, Python, PHP) You are exactly right there you should not be attempting a database connection via javascript in the browser.
You'll need to build out a server side application to handle the basic operations of your application.
I'd strongly recommend reading up on the MVC design pattern, and possibly looking into Ruby on Rails as your backend framework, it plays very nicely with ajax like features, and has a somewhat shorter learning curve, I believe, than some other frameworks / languages.
You will need server side scripts in a language like PHP or Ruby on Rails to interact with a database.
If you're already familiar with HTML5 and JavaScript, may I recommend using Node.JS? It's about the closest you'll get to what you already know with browser development. It can also hook in with database systems which are closer to the HTML5-suggested IndexedDB.
with that in mind...
If you're inexperienced with programming and programming languages, then the app you describe will involve a pretty big learning curve. While Flash and Flex have really nice interfaces to build apps with click-and-drag, the tools for HTML5 are much less mature.
That's not saying it's not possible with HTML5. Just that there's still some time to wait before people create tools to bring the app building process closer to what Adobe provides.

Web development with ESN Planet, how does it work?

I'm starting a new job soon, in web-app development. While I'm experienced with programming, my background is primarily in game development and desktop/server applications. I have very little experience from modern web app development. Anyway...
Our primary development tool is going to be something called ESN Planet, which I've not heard about before. Their website is not very specific about its features, and it seems unlikely for one to get a trial invitation ("We have been getting lots of applications, so please try to be as detailed as possible when applying for an invite below.").
Is anyone using this tool, and can explain what kinds of skills are involved in development of apps using this tool? Should I learn Python, JavaScript, CSS, or something else? All of the above? What is the workflow like for a developer? Will I need modern HTML skills?
I'd like to prepare for this job, but not sure what to expect and prepare for. My contact with the company is not a developer, so I figured I would ask here.
I saw a talk by the boss of the company that developed this stuff, at the Europython conference this year. It was ostensibly about the custom IDE that they created to develop in it, but also touched on the Planet system itself. It seems like a pretty run-of-the-mill MVC framework, as far as I can tell.
As far as what to learn, you will definitely need Python. Normally in web development you also need HTML, CSS and Javascript as well - but some frameworks abstract a lot of that away from you, to a greater or lesser extent. Impossible without knowing more about the framework to tell whether this is one that does. And it also depends on the way the company you're working for is set up - some have separate front-end teams that deal with that side of things, leaving the Python developers to just manage the server-side stuff.
For what it's worth, ESN Planet has been used to build Battlelog (http://battlelog.battlefield.com), the web platform for stats tracking and web launching of Battlefield 3.

Categories