netzfabrik
119
1
Tips

Database structure of templates

Posted 3 weeks ago by netzfabrik

Hi at all, i need help to design the database. So in the first step i want price templates for each account. So i've now a table for the templates with name, created_at, e.g. and another table with the values of the pricing templates.

Schema::create('pricing_templates', function (Blueprint $table) {
  $table->increments('id')->primary();
  $table->string('name');
});

Schema::create('pricing_template_values', function (Blueprint $table) {
  $table->increments('id')->primary();
  $table->int('pricing_templates_id')->unsigned();
  $table->string('name');
  $table->float('price');
});

But now i want to set custom values to the prices per user account. And at this step i dont know how it is the best solution. Can anyone help me?

Best, Giuliano

Please sign in or create an account to participate in this conversation.