1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-10 21:22:58 +01:00
invoiceninja/resources/views/accounts/product.blade.php

53 lines
1.4 KiB
PHP
Raw Normal View History

2015-10-14 16:15:39 +02:00
@extends('header')
2015-03-16 22:45:25 +01:00
@section('content')
@parent
2015-10-14 16:15:39 +02:00
@include('accounts.nav', ['selected' => ACCOUNT_PRODUCTS])
2015-04-06 13:46:02 +02:00
{!! Former::open($url)->method($method)
2015-06-14 10:55:02 +02:00
->rules(['product_key' => 'required|max:255'])
2015-10-14 16:15:39 +02:00
->addClass('warn-on-exit') !!}
2015-03-16 22:45:25 +01:00
2015-04-20 16:34:23 +02:00
<div class="panel panel-default">
2015-04-22 21:21:04 +02:00
<div class="panel-heading">
<h3 class="panel-title">{!! $title !!}</h3>
</div>
2015-10-14 19:18:19 +02:00
<div class="panel-body form-padding-right">
2015-04-20 16:34:23 +02:00
2015-03-16 22:45:25 +01:00
@if ($product)
{{ Former::populate($product) }}
{{ Former::populateField('cost', number_format($product->cost, 2, '.', '')) }}
@endif
2015-04-06 13:46:02 +02:00
{!! Former::text('product_key')->label('texts.product') !!}
2015-08-30 14:08:15 +02:00
{!! Former::textarea('notes') !!}
2015-04-06 13:46:02 +02:00
{!! Former::text('cost') !!}
2015-03-16 22:45:25 +01:00
2015-10-21 13:11:08 +02:00
@if ($account->invoice_item_taxes)
{!! Former::select('default_tax_rate_id')
->addOption('', '')
->label(trans('texts.tax_rate'))
->fromQuery($taxRates, function($model) { return $model->name . ' ' . $model->rate . '%'; }, 'id') !!}
@endif
2015-04-20 16:34:23 +02:00
</div>
</div>
2015-04-06 13:46:02 +02:00
{!! Former::actions(
2015-10-14 16:15:39 +02:00
Button::normal(trans('texts.cancel'))->large()->asLinkTo(URL::to('/settings/products'))->appendIcon(Icon::create('remove-circle')),
2015-06-04 22:53:58 +02:00
Button::success(trans('texts.save'))->submit()->large()->appendIcon(Icon::create('floppy-disk'))
2015-04-06 13:46:02 +02:00
) !!}
2015-03-16 22:45:25 +01:00
2015-04-06 13:46:02 +02:00
{!! Former::close() !!}
2015-03-16 22:45:25 +01:00
<script type="text/javascript">
2015-05-09 20:25:16 +02:00
$(function() {
$('#product_key').focus();
});
2015-03-16 22:45:25 +01:00
</script>
@stop