Implement Order Screen - android

This is not a pure programming question; rather it has to do with implementation details. It is required to implement an order processing screen where a customer makes an order consisting of multiple items. It is a two step operation whereby the user has to enter the name of the customer (or pick a name off of a list) and enter the order details (detail block in db terminology) and likewise enter the items or pick them off of a list. How is this transaction best carried out on an Android device?
(Please note that I am not asking about the programming of db operations rather about what objects are needed on the layout in order to implement such a transaction.)

About the implementation (no code), I am trying to give the most simple yet an efficient way to do this.
Give the user a choice (maybe buttons) to either enter name of customer or choose from a list.
If the option is to enter the name, some TextViews and Buttons would do the trick.
For choosing from a list, try a ListView.
On clicking any of the ListView terms, an Activity with TextViews and Buttons to take the order details.
For choosing the items, provide a Dialog Window with check boxes beside each item names.
Hope this helps. Get back to me if you need any help with the code.

Related

Suitable components for Person List. Android Studio

I'm quite new to android studio so be easy please.
For now I'm doing my best to implement MVVM pattern using Kotlin.
I want an app which is shows Persons in a list (For now I'm using Recycle View with a Text View inside). I want user to be able to tap on a Person and after tap Person card would pop up. The questions are:
Which component should I use instead of Text View to observe user's tap?
Which components should I use for Person card? Person(Name, Last name, Age, Avatar(jpg img))
You can just use the text view. Just set an onClickListener to know when someone taps it.
Depends on the exact UI you want. A dialog might fit, with whatever you want inside it.

Search box needs to be able to search individual words from search box

I am using MIT App Inventor 2 and I am trying to make my search box more useful.
Right now a have a bunch of lists and it only works if the words in the "search" textbox match the word in the list exactly. I want it to be more dynamic. For example
If someone puts oj container in the search box I want it to search the lists for oj container and if that does not come up with anything then search the lists for both oj and container separately. And if it finds one of these words in the list to follow on to the next action, which is to open up the appropriate page.
So far my code looks like this:
Tell me if this code make sense. Thanks.
Here are some more code screenshots
No, it does not make sense. The split at spaces block returns a list and using the is in list? block you can't search for a list of things, only for a "thing" (a single word in your case). Therefore you will have to search for each single word in your list using a for each item in list loop.
Also there is some redundancy in your blocks. If searching for oj container is successful, the search for oj also is successful, which means, you can remove the blocks to search for the complete sentence...
See my solution for the first part of your screenshot.

ListView, storage 2 columns [android]

I need an advice about ListView.
A give you an example:
Assume that i have a map. If i'll touch some place on it i'll get an information about that place and then, on screen, a dialog fragment will appear. In this dialog i can write a name of place, which i touched. The names should be saved into ListView but if i'll click on some of them i want to get information.
Can some of you tell me how i should do this? Is it possible to save that information in Shared Preferences?
Maybe you would get it work with SharedPref. but it isn't a nice way to that. I think the best way is to create an Android SQL-DataBase. Like in every other Database you could use one column for the name, one for the information text, one for coordinates and so on (that's just an example). The data will stay, also if your app is closed (like SharedPref).

Suggestions for data entry form in android

I am working on app which have data entry form which have
Some fields with 3 drop down associated to it.
More then 25 input fields (input box, radio button, drop downs etc)
All input fields are grouped into 3 categories
My question are:
How to display field with 3 drop downs associated with it ? Because of a small screen size it cannot be displayed horizontally.
What is the best way to represent 25+ fields ? I tried scroll view and tabs but don't find it so pleasing.
For example if you consider date then it may have three drop downs for date , month and year. (Its just example I have fields different than date)
What is the good way to have fields in a category together with appealing UI.
PS: My app is related to Hospital so it has to be pleasant .Which also means I cannot use glossy background or image.
You might want to check this site for general Android UI design ideas. Here are some for your particular cases:
re-design your UI to only show what is needed. It's unlikely that all 25 fields are used all of the time. Consider separate screens for different use cases, and/or some sort of wizard-like UI (fill in the basics, press next, fill in details, etc.)
if you really need to display all of this, consider using a tablet, not a phone to run the app (assuming this is to be used in the field, and you have some control over devices).
instead of tabs, you might want to try something like ViewPager. It doesn't take as much space as tabs, and the number of views is practically unlimited.
Maybe like this...
You can use the library QuickAction which allows to create some kind of context menu.
To keep a simple screen view, you can only display the current values. Several on the same lines for the same category.
Then, if the user click on a value or category, you trigger a QuickAction with the actions available for the category or values: Edit, clear, ...
For each action, you can also show a dialog to update/fill the field which has triggered the action...

Alphanumeric View in Android

I am developing an Android App which gives users an option 'Browse Alphanumerically'. Using this option let users view the list of items starting with a particular letter or number. Problem is that I cannot decide how to implement screen for this, which can work properly on any screen size. Please suggest me the best solution.
Thanks.
What I got from your question is that you want to show all alphabets and numbers to the user so they can jump directly to a entries start with the selected alphabet or number. If this is so, then one solution to your problem is use the Button or ImageButton any make a key pad of all alphabet and numbers. Don't forget to make them flexible enough for different screen sizes. Cheers.
Use a list activity. There are lots of tutorials on Google's developer site. When you want to narrow the list, just assign the smaller list to the ListView. Just filter your master list, sort it, and assign it to your list adapter.
Hope this was helpful.

Categories

Resources