Drupal Commerce : How to handle Line Item


I use the Drupal Commerce module to manage all the orders and products of my shop. But now I need to improve it and I have some requirements.

1. The cart view can be used with two products type (but each product is dedicated to a role type – so it’s only possible to buy one product type). But I need to add a specific field for one product type which doesn’t exist for the other one. I can’t do that as the cart view is used in all case.

2. I would add custom field in the Line Item (once again only for a product type) which is actually an insurance fee based on the product price. So it must be editable (as the price can change) and update the line item total price.

3. I need to theme the Line Item. The optional field must be placed under the line item and display as checkbox.

My solution could be to programmatically edit the Line Item by adding a field depending the product type and by handling the field value but I don’t find a way to do that.

Does someone already face this issue?

Thanks in advance,

Drupal version: 

Source: https://www.drupal.org/taxonomy/term/22/feed