Company drop
Video outline
A company drop is a collection of data that exists in the Silverfin database. It contains specific information about each client file.
Company drop is one of the two main (root) drops that exists in Silverfin. These two drops, which are company drop and period drop, serve as a basis for all other information collections available within Silverfin.
Data that is stored in the company drop can be added to the company settings via the EDIT CLIENT section in Silverfin. Some of the examples of the information that can be added/you can find there there would be: company name, company form, company address, etc. Once the information is saved, it can be used in liquid.
Examples
At this point you may be asking yourself, how can we get company related information from the drop and display it in our templates? Let’s have a look.
Company drop can be seen as a category that contains attributes (or what is called method in liquid language). For example, ‘company’ can retrieve the name of the current client of Silverfin, but we need to specify that method in liquid. This can be done, by combining two parts, the name of the drop and the name of the method.
{{ company.name }}
By printing company.name variable in the template, you will be able to display the company name of the current client. Some of the other popular combinations that are used are:
{{ company.street }}
{{ company.currency }}
{{ company.company_form }}
More examples of the methods that can be used in combination with the company drop can be found here .
One of the main advantages of using a company drop is that you will have a general code that can be applied to different client files and that will change depending on which client file you are working in.
Potential pitfalls
Keep an eye on the spelling. If the name of the drop or the method is spelled incorrectly, the information will not be displayed.
Conclusion
- Company drop is a collection of data that contains company specific information
- It is one of the basic drops in Silverfin
- Company drop should be used with a combination of method
- General code that will change per client file.
Updated about 3 years ago