Browse Source

Change payment view files and project link

pull/1/head
Nafies Luthfi 8 years ago
parent
commit
bbd87258d6
  1. 2
      app/Entities/Projects/Project.php
  2. 6
      resources/views/payments/create.blade.php
  3. 7
      resources/views/payments/pdf.blade.php
  4. 4
      tests/Unit/Models/ProjectTest.php

2
app/Entities/Projects/Project.php

@ -21,7 +21,7 @@ class Project extends Model {
public function nameLink() public function nameLink()
{ {
return link_to_route('projects.show', $this->name, [$this->id], ['target' => '_blank']);
return link_to_route('projects.show', $this->name, [$this->id]);
} }
public function features() public function features()

6
resources/views/payments/create.blade.php

@ -3,6 +3,10 @@
@section('title', trans('payment.create')) @section('title', trans('payment.create'))
@section('content') @section('content')
<ul class="breadcrumb hidden-print">
<li>{{ link_to_route('payments.index', trans('payment.payments')) }}</li>
<li class="active">{{ trans('payment.create') }}</li>
</ul>
<div class="row"> <div class="row">
<div class="col-md-6"> <div class="col-md-6">
@ -39,7 +43,7 @@
<div class="panel-footer"> <div class="panel-footer">
{!! Form::submit(trans('payment.create'), ['class'=>'btn btn-primary']) !!} {!! Form::submit(trans('payment.create'), ['class'=>'btn btn-primary']) !!}
{!! link_to_route('payments.index', trans('app.cancel'), [], ['class'=>'btn btn-default']) !!}
{{ link_to_route('payments.index', trans('app.cancel'), [], ['class'=>'btn btn-default']) }}
</div> </div>
</div> </div>
{!! Form::close() !!} {!! Form::close() !!}

7
resources/views/payments/pdf.blade.php

@ -67,11 +67,14 @@
</td> </td>
</tr> </tr>
<tr> <tr>
<td style="font-size: 20px; font-weight: bold; text-align: center;height: 80px;vertical-align: bottom;">Terbilang</td>
<td style="font-size: 20px; font-weight: bold; text-align: center;height: 100px;vertical-align: bottom;">Terbilang</td>
<td style="font-size: 20px; font-weight: bold; vertical-align: bottom;"> <td style="font-size: 20px; font-weight: bold; vertical-align: bottom;">
{{ formatRp($payment->amount) }},- {{ formatRp($payment->amount) }},-
</td> </td>
<td style="text-align: center;vertical-align: bottom; font-weight: bold;">JasaWebsiteBanjarmasin.com</td>
<td style="text-align: center;vertical-align: bottom;">
<strong>{{ auth()->user()->name }}, S. Kom.</strong> <br>
JasaWebsiteBanjarmasin.com
</td>
</tr> </tr>
</tbody> </tbody>
</table> </table>

4
tests/Unit/Models/ProjectTest.php

@ -136,8 +136,6 @@ class ProjectTest extends TestCase
public function it_has_name_link_method() public function it_has_name_link_method()
{ {
$project = factory(Project::class)->make(); $project = factory(Project::class)->make();
$this->assertEquals(link_to_route('projects.show', $project->name, [$project->id], [
'target' => '_blank'
]), $project->nameLink());
$this->assertEquals(link_to_route('projects.show', $project->name, [$project->id]), $project->nameLink());
} }
} }
Loading…
Cancel
Save