I plan to make a simple webpage with simple (big) table. The table must be editable in place and changes instantly propagated among all users looking at it (no username/login required). I already have a script in python that scans list of devices which will be used to show them in the table.
What is the best choice of stack for this mini project?
Thanks for any advices!
Related
I am somewhat of a beginner at Python and I am currently starting some brainstorming and planning for a project to simplify the tedious task of filling out a product order form for a friend's business. I am wanting to create a program with an interface that takes in input and writes to an already existing pdf form of the physical order form. I would also like to implement being able to then email that form to another coworker and having accessible information of previous orders from the current customer ordering.
I am most curious about how to write to an already existing pdf form and just fill in the blanks, potentially using a PDF Reader? Also, for product catalog data and customer order history, would using dictionaries suffice or would it be better to use some python database?
I know I could figure out how to individually do each of those tasks but I don't know how to tie it all together properly to distribute it, either making a WebApp or an executable file from the script and just use tkinter or another GUI library for the interface, or if there is a more obvious and convenient option?
If I were to do a WebApp, what would be my best option, I've seen options such as Anvil, Flask, Django, and I just don't know what would be best for what I'm trying to accomplish.
I know this is a longshot and vague but any advice or guidance in the right direction would be much appreciated!
I'd go with a web app here. Personally, I prefer Django, and I don't think that it would be too difficult to learn it well enough for your purposes!
Regarding saving product catalog data and customer order history: I would definitely recommend using a database for your backend, which Django helps you do! Database integration is almost ridiculously easy using Django.
Here's some resources for the specific things you asked about:
Django vs. Flask
Working with HTML forms (Django) (this will help with taking user input)
filling an existing PDF form in Python (this will help with using user input to fill out the pdfs)
How to send email attachments in Python? (this will help you email your coworker the filled out pdf)
If you need more help/guidance, definitely feel free to follow up!
for an academic project, I am currently using the python framework jam.py 5.4.83 to develop a back office for a new company.
I would like to use views instead of tables for reporting but I don't find how to do it, I can only import data from tables.
So if someone already used this framework, I would be very thankful.
Regards,
Yoan
The upper part of the Item Editor dialog have the Virtual table field.
Virtual table - if this checkbox is checked, no database table will be created. Use this options to create an item with in-memory dataset or to use its modules to write code. This checkbox must be set when creating an item and can not be changed later.
Virtual table option
the use of database views are not supported in Jam.py
However, you can import tables as read only if used for reporting.
Than you can build Reports as you would.
Good luck.
I just need pointers on where to begin. I have some experience with Python, but nothing to brag about.
My end goal is to create a website that will allow multiple users to access it from different computers to fill the table with simple data, very simillar to what Google Sheets alows, and then printing it on a single sheet of paper. Idealy I want my programm to intelegently determine the width of rows and columns so that the table would look decently and would fill the page accordingly.
Right now all I need is some pointers on where to begin. Like can I use SQL to create these tables and have online fuctionality for users to access and fill the spreadsheet, and how to go about printing it.
I know this is very noob question, but I can't seem to find anything relevant here on by just using google.
Thank you.
I don't think this is a very good StackOverflow question because it is very broad and not programming specific. You are asking how to start a new software project which in my opinion belongs more in the software engineering meta: https://softwareengineering.stackexchange.com/
Anyhow, how I would take on such a project:
First I would define my project scope. What is the functionality of the end-product? What must it be able to do and what not? Who are the end-users using the product and what do they expect? These are so called functional requirements.
In which way does the product deliver value? Is it fast, modifiable, distributed... These are so called non-functional requirements.
Develop a basic software architecture based on the previous requirements using patterns and tactics and identify the different subsystems. On the top of my hat I would divide it in a frontend component using a web application, backend component in your favourite language and a database component for persistence.
Research possible languages frameworks for each component, decide and start coding!
For the 4th step I suggest you have a look at Python Django which includes all of this stuff out-of-the-box.
I apologize if the question is a little vague but I'm trying to find the simplest way to do this.
I have a small group of people, for whom I have written a python script. Now this python script summarizes articles mined from a website (that are unique by an id number) when the user runs it with some parameters. Now each user might choose to "claim" one or more articles, which means that they will be working on it. Thus any future execution of the script should omit using a "claimed" article in its summary.
I need a way to have a globally accessible file, which my script accesses and checks its output against.
I also need to have a way for the user to add multiple id numbers to this global file.
I understand that a rudimentary database might be the best way to go, but is there a simpler way to read and edit files remotely over python? I can host this file on my personal webspace, but I'm not sure of what would be the simplest way to edit and read it since I'm relatively new to python.
The number of users is small and constant so it does not have to be very robust, just needs to work.
Language: Python
Thanks!
I am new to python and pyramid and I am trying to figure out a way to print out some object values that I am using in a view callable to get a better idea of how things are working. More specifically, I am wanting to see what is coming out of a sqlalchemy query.
DBSession.query(User).filter(User.name.like('%'+request.matchdict['search']+'%'))
I need to take that query and then look up what Office a user belongs to by the office_id attribute that is part of the User object. I was thinking of looping through the users that come up from that query and doing another query to look up the office information (in the offices table). I need to build a dictionary that includes some User information and some Office information then return it to the browser as json.
Is there a way that I can experiment with different attempts at this while viewing my output without having to rely on the browser. I am more of a front end developer so when I am writing javascript I just view my outputs using console.log(output).
console.log(output) is to JavaScript
as
????? is to Python (specifically pyramid view callable)
Hope the question is not dumb. Just trying to learn. Appreciate anyones help.
This is a good reason to experiment with pshell, Pyramid's interactive python interpreter. From within pshell you can tinker with things on the command-line and see what they will do before adding them to your application.
http://docs.pylonsproject.org/projects/pyramid/en/1.4-branch/narr/commandline.html#the-interactive-shell
Of course, you can always use "print" and things will show up in the console. SQLAlchemy also has the sqlalchemy.echo ini option that you can turn on to see all queries. And finally, it sounds like you just need to do a join but maybe aren't familiar with how to write complex database queries, so I'd suggest you look into that before resorting to writing separate queries. Likely a single query can return you what you need.