I am writing an iOS app that requires several pieces of information to be entered. I am trying to do this is the most iOS idiomatic way.
The user must:
Select faulty PC from list
Select fault type from list
Enter fault detail text
Enter shipping details
AC Adapter? - boolean
Shipping address - text view
Contact No - text box
Cost Centre - text box
My gut instinct was for a wizard with each major item on a separate view, with the shipping details as a form on a single view. However, I don't see any wizard data entry like that in Apple Apps.
What do people consider best? Multiple views as described, or a single table view with disclosure buttons for each major item to navigate to selection/entry screens. In that scenario, should the shipping details be a single table cell on the main page or multiple elements?
A good "wizard data entry" example from Apple is the one you have to use every time iOs is updated. However it is inconvenient to fill any kind of a form this way, using a table view instead is a good way to show relatively simple forms.
If the order of filling in the form doesn't matter, use Calendar app Add event style, if it is important, add/remove sections as user enters/removes the data (similar to Settings > Wi-Fi).
Related
I am making a user form in Delphi for documents tracking application. I am interested in functionalities input new entry (record) and view list by... (date, name of document, ID,...).
My problem is that I don't know how to implement these functionalities for more than one user. Currently, I have 5 users. Each user has a unique input data (record) fields (columns) and view fields (columns) of each user are also unique. There could be more users.
So, how to implement these functionalities for this form? How to assign different data (fields) for each separate user for input and view? That is what I don't understand. Is that distributed functionality of an application? If yes, how to achieve it?
Note that I don't want static assigning of a user in application's code, e.g:
if(username='user1') then {
input();
view();
}
else if (username='user2') then {...}
...
because, than, every time there is a new user, developer must go back to the application's code and hard-code it. That is not efficient and is a bad implementation. Rather, I want that to be dynamic (if that is the right term). How to achieve this?
Note: I am using dbExpress tool with MySQL DBMS with RAD Studio XE7 Architect.
If I'm correctly understanding what you are asking, it seems as if you are unfamiliar with the idea of tables/datasets which operate in a so-called Master-Detail relationship. These are very easy to set up in Delphi.
Once you get familar with M->D relationships, I think you'll realise that what you should have been asking about is how to set one up in your app, rather than the problem of hard-coding of individual users into your form.
In your case, what you are missing at the moment is a table of users' details. Let's call that the Users table. Usually this would contain their name, obviously, and some kind of unique identifier (best is a "Primary key" in the Users database table), but NOT, please, their password to access the db, especially not in plain text.
Once your Users table is created, you can create a display grid (TDBGrid) and input/editing form for it.
Then, if you don't have it already, you could set up a grid and editing form for users' documents (which I'm going to refer to as the Documents table).
Once that's done, the main thing left to do is to set up in your Delphi project a Master-Detail relationship between your Users table (the master) and your Documents table (the detail).
If you prefer you can have a single form with two grids, the Users grid and the Documents grid on it, and as you scroll through the Users grid, you'll see that the Documents grid shows only their document records.
The details of how to set up a Master-Detail vary somewhat according to the type of table/dataset you're using so you'll need to search online for the details of how to do it. Broadly, it's a matter of connecting a TDataSource to your Users table and setting the DataSource (or MasterSource) property of your Documents table to point at the Users TDataSource, and then setting a couple of other, table-type-dependent properties of the Documents table.
Every edition of Delphi since well before D7 has come with a demo app, "MastApp" which illustrates how you use Master-Detail relationship amongst a number of tables. I suggest you take a look at the MastApp for your Delphi version and then look into how to set up M->D relationships for the type of Delphi dataset you are actually using.
I'm new in Rails, I have a Meal model which has many Products. Meals are assign to User (maybe this is important for a concept). In meals/new.html.erb I want to create new Meal as follow:
Click the button "Display Products"
On the same page (meals/new.html.erb) open modal (pop-up) with all products assigned to current user ( I have help method for current-user). It should be displayad like a list or grid with checboxes for example.
Then user can check few products and click "Confirm".
After that in meals/new.html should be appeared list of chosen products with additional input to fill their quantity.
So I have two problem here.
How should I display modal? Is needed any Ajax (I'm not so familiar with this technology)
How can I pass products between view and modal?
Could you help me a little to achieve these goals?
Regarding your first problem, displaying the modal is fairly straight forward. Essentially you will create a div with the proper bootstrap classes to be hidden when the page is loaded, and then create a button that makes it visible. I would recommend either reading over the W3Schools entry on modals, or from the appropriate part of the bootstrap javascript documentation.
Regarding your second question, this depends on exactly what you mean. The modal is part of the view, so if you're only trying to put information that is currently on the modal back onto the "page" behind it, you can do so fairly simply with javascript (copying content out of one element into another, or updating states of inputs). If, on the other hand, you're trying to use the modal to retrieve information from the server (for instance if you wanted to show a list of possible options, and then display detailed information about the selected items from the database) that would require Ajax.
If you have any snippets of code that aren't functioning as you expect, feel free to add your View to the question. In cases like this, usually the best way for us to provide help is for you to take an early crack at this, post the relevant code, and then seek answers for the things that behave unexpectedly.
I hope that helps.
I am building an app where I am fetching some data (e.g. persons, documents ...) from a server. I am building the app for iOS and Android. On Android i got it pretty decent looking ;), but on iOS I am not really sure how to properly design it(because I don't want to get it rejected by Apple). All of the apps, which I saw, that are fetching some data from a server just need one paameter and they are good to go. In my case I have a lot of parameters which can be used (for a person there is the name, email, postal address, phone, person type ...) and in the end you get a list (so I need a table view). Now I am not sure how to present that to the user. So far I have built a slide menu on the left (there is a navigation button which opens and closes it) and there I have placed all of the additional search parameters.
The main search criteria would be by name and I thought to use it with the search bar and the search display controller(so you dont have to open the slider for a search over the names). The problem is that I am also using sliding cells (e.g. to call, send sms, send email to persons), and when searching with the search controller I always get a blank table (it seems that the search contoller can't handle custom cells). Then I switched to using the search bar (without the controller), but there is the problem that I am mssing the scope bar und the whole animation thing (I assume that I will have to create all of it manually)
Has anyone built some app like that ? What are the best practices for doing so (I am comming from the android world, so I am not sure what the average iOS user expects) ? For reloading the table I use just the pull-down mechanism ? Is that enough or do i need some additional bar buttons ?
It would be great if someone has a working example (in the appstore would also be fine), or a link to some explanation on this matter.
Kind regards
I'm new to Xcode but have been able to overcome every hurdle so far. Now I'm at a fork in the road and not sure which direction to go. My iPad app takes user input and then it generates reports based on the input. I want the reports to have as many columns as my entities have attributes, and for each attribute to be a column header and to be sortable, just like a spreadsheet. UITableview seems to let me display a dynamic number of rows, and then if I have a custom cell with several manually created labels mapped to attributes I could sort of simulate columns by having a bunch of buttons on a navigation bar that change how the table is sorted. Problem here is that if I change my data schema i need to redesign the cell view and write new code for for the sort columns. HTML also seems like an option, but it feels and looks very different for the user. There's also 3rd party, but stubbornly, I want to build it myself. Could you guys provide some guidance on the pros and cons of each option for my use case? If I go for the first one, is it possible (feasible) to write something that could auto generate the storyboard layout in the case of adding a new attribute to an entity? Platform: iPad, Language: swift, data set is not enormous (sub 100k rows, worst case), using core data, need flexibility on the reporting side - would love an interface that lets users generate their own reports (don't want my life to become custom reporting)
Are you familiar with the UICollectionView class?
Take a look at this example over at github:
https://github.com/darrarski/DRCollectionViewTableLayout-iOS
This is an excellent way to organize cells as in a spreadsheet.
There is a nice swift tutorial over here:
https://github.com/darrarski/DRCollectionViewTableLayout-iOS
I am working on a Grails project, its an accounting project. We have multiple clients and they can have multiple types of accounts. I have to create the 'create' page for client, there should be a way to add multiple types of account to the client.
So I was thinking of making a drop-down list with account types and few text boxes to enter account name and other info about account. Also, as a client can have multiple accounts, so I want to create a 'add' button, when clicked it would display a new row to add a new client. I have done this kind of UI before using javascript but in this case, as there is a drop-down list and other components, I think it would be very hard and may not work.
I was thinking of creating a partial view which would render each time user clicked the 'add' button with additional row, problem with this would be during validation errors, edit page and i would also have to pass all values each time user clicks 'add' button.
Is there any other for doing this?
For the template approach you must use ajax if you don't want to carry on the params that the user has already set.
It is possible to make new drop-down lists appear (or any group of elements inside a <div>) when a user clicks a button, since Grails already comes with jQuery you might want to take a look at the .clone() method.
The problem with the two listed approeaches is that it will be possible to have duplicates.
Now, another option is to use checkboxes, so you can check just the type of account you want.
But to be honest it does seems a bit odd or even inapropiate to let the user choose the type of account he wants with such freedom.