Let's dive in and create a simple invoicing system, because hey, why not. It's useful if you're a freelancer, or work for one. It's also a good way to familiarize yourself with drupal concepts, such as content types and entities.
Here's a link to a super basic invoice database. You can make any of the columns sortable. In this case, all of the columns can be sorted by clicking on their headers. Here is that same database, sorted by payment status. When you click on a client, in any of these views, or from this rolodex, you can see their description, web site, contact email(s) and invoices. You can add new clients, and those clients will automatically appear in a drop-down menu as a client option when creating a new invoice. Pretty neat, right?
Here are the steps I followed. The type of the field chosen is in parenthesis.
- Create a content type for clients. Give it these fields: name (by changing the title label to name), website (link), email (email), and description (long text and format).
- Create a content type for invoices. Give it these fields: title, client (entity reference), invoice number (integer), description (long text and format), amount (decimal), and status (select list with only 1 value allowed). The client field, references the client content type, because every time the user adds a client, we want that client to be a new option when creating an invoice.
- Check to see the entity reference is working by creating a few clients, and making sure they show up as options when creating invoices.
- Create a few invoices; at least one for each client.
- Create a view by going to Structure > View > + Add view.
- Take a look at your page view. Mine is here. By appending /all to the URL of your view, you will be able to see all of the results, unsummarized. Here is my view, with all of the results.
In this case, I wanted to make the invoices for each client appear on their own content type pages. If you want to do this also, create another view, this time, filtering for invoices, adding a contextual filter that draws from URL values, and placing it in a block. Then, place the block on the client content types only.
- View a client content type to see that it is working. An example is here.
- Lastly, to create a rolodex of clients, create a page view and filter for the content type of client. Here's a simple example.
So, that's one way to create a basic invoicing system using drupal. It requires some configuration and a basic understanding of drupal, but no coding wizardry.