122 lines
5.1 KiB
PHP
122 lines
5.1 KiB
PHP
<?php
|
|
require('fpdf/fpdf.php');
|
|
|
|
class PDF extends FPDF
|
|
{
|
|
private $maxWidth = 190;
|
|
private $nama;
|
|
private $alamat;
|
|
private $telepon;
|
|
private $logo;
|
|
|
|
public function setHeaderData($nama, $alamat, $telepon, $logo='')
|
|
{
|
|
$this->nama = $nama;
|
|
$this->alamat = $alamat;
|
|
$this->telepon = $telepon;
|
|
$this->logo = $logo;
|
|
}
|
|
|
|
function Header()
|
|
{
|
|
// Logo
|
|
$this->Image('/www/wwwroot/bilspro/img/user/'.$this->logo, 10, 8, 22, 22);
|
|
$this->SetXY(35, 11);
|
|
$this->SetFont('Arial', 'B', 14);
|
|
$this->Cell(0, 6, $this->nama, 0, 1, 'L');
|
|
$this->SetFont('Arial', 'I', 11);
|
|
$this->SetXY(35, 17);
|
|
$this->Cell(0, 6, $this->alamat, 0, 1, 'L');
|
|
$this->SetXY(35, 23);
|
|
$this->Cell(0, 6, 'Phone: '.$this->telepon, 0, 1, 'L');
|
|
$this->Ln(8);
|
|
|
|
// Garis Horizontal
|
|
$this->SetLineWidth(0.8);
|
|
$this->Line(10, 33, 200, 33);
|
|
$this->SetLineWidth(0.4);
|
|
$this->Line(10, 34, 200, 34);
|
|
|
|
// Judul Dokumen
|
|
$this->SetFont('Times', 'B', 14);
|
|
$this->Cell(0, 8, 'BERITA ACARA PENGAMBILAN ALAT', 0, 1, 'C');
|
|
$this->Ln(6);
|
|
}
|
|
|
|
function Footer() {
|
|
// Menempatkan nomor halaman di footer
|
|
$this->SetY(-15);
|
|
$this->SetFont('Times', 'I', 8);
|
|
$this->Cell(0, 10, 'Halaman ' . $this->PageNo(), 0, 0, 'C');
|
|
}
|
|
|
|
function AddBeritaAcara($nomor_pelanggan, $nomor_telepon, $nama_pelanggan, $alamat_pelanggan) {
|
|
$this->SetFont('Times', '', 11);
|
|
$this->Cell(0, 8, 'I. IDENTITAS PELANGGAN', 0, 1);
|
|
$this->Cell(35, 7, 'Nomor Pelanggan', 0, 0);
|
|
$this->Cell(4, 7, ':', 0, 0);
|
|
$this->Cell(55, 7, $nomor_pelanggan, 1, 0);
|
|
$this->Cell(8, 2, '', 0, 0);
|
|
$this->Cell(27, 7, 'Nomor Telepon', 0, 0);
|
|
$this->Cell(4, 7, ':', 0, 0);
|
|
$this->Cell(0, 7, $nomor_telepon, 1, 1);
|
|
$this->Cell(0, 2, '', 0, 1);
|
|
$this->Cell(35, 7, 'Nama Pelanggan', 0, 0);
|
|
$this->Cell(4, 7, ':', 0, 0);
|
|
$this->Cell(0, 7, $nama_pelanggan, 1, 1);
|
|
$this->Cell(0, 2, '', 0, 1);
|
|
$this->Cell(35, 7, 'Alamat', 0, 0);
|
|
$this->Cell(4, 7, ':', 0, 0);
|
|
$this->Cell(0, 7, $alamat_pelanggan, 1, 1);
|
|
$this->Cell(0, 2, '', 0, 1);
|
|
$this->Ln(5);
|
|
$this->Cell(0, 8, 'II. DATA ALAT YANG DIAMBIL', 0, 1);
|
|
$this->Cell(35, 7, 'Jenis Alat', 0, 0);
|
|
$this->Cell(4, 7, ':', 0, 0);
|
|
$this->Cell(55, 7, '', 1, 0);
|
|
$this->Cell(8, 2, '', 0, 0);
|
|
$this->Cell(21, 7, 'Merek Alat', 0, 0);
|
|
$this->Cell(4, 7, ':', 0, 0);
|
|
$this->Cell(0, 7, '', 1, 1);
|
|
$this->Cell(0, 2, '', 0, 1);
|
|
$this->Cell(35, 7, 'Type', 0, 0);
|
|
$this->Cell(4, 7, ':', 0, 0);
|
|
$this->Cell(40, 7, '', 1, 0);
|
|
$this->Cell(8, 2, '', 0, 0);
|
|
$this->Cell(25, 7, 'Serial Number', 0, 0);
|
|
$this->Cell(4, 7, ':', 0, 0);
|
|
$this->Cell(0, 7, '', 1, 1);
|
|
$this->Cell(0, 2, '', 0, 1);
|
|
$this->Cell(35, 8, 'Kondisi Alat', 0, 0);
|
|
$this->Cell(4, 7, ':', 0, 0);
|
|
$this->Cell(0, 8, '.........................................................................................................................................................', 0, 1);
|
|
$this->Cell(35, 8, '', 0, 0);
|
|
$this->Cell(4, 7, ':', 0, 0);
|
|
$this->Cell(0, 8, '.........................................................................................................................................................', 0, 1);
|
|
$this->Ln(5);
|
|
$this->Cell(0, 8, 'III. ALASAN PENGAMBILAN', 0, 1);
|
|
$this->MultiCell(0, 10, '......................................................................................................................................................................................................................................................................................................................................', 0, 1);
|
|
$this->Cell(0, 8, 'IV. PROSES PENGAMBILAN', 0, 1);
|
|
$this->MultiCell(0, 8, "Pada tanggal ........,......................20........ petugas melakukan pengambilan modem di alamat pelanggan. Proses pengambilan dilakukan oleh:", 0, 1);
|
|
$this->Cell(35, 7, 'Nama Petugas', 0, 0);
|
|
$this->Cell(4, 7, ':', 0, 0);
|
|
$this->Cell(65, 7, '', 1, 0);
|
|
$this->Cell(8, 2, '', 0, 0);
|
|
$this->Cell(15, 7, 'Jabatan', 0, 0);
|
|
$this->Cell(4, 7, ':', 0, 0);
|
|
$this->Cell(0, 7, '', 1, 1);
|
|
$this->Ln(5);
|
|
$this->Cell(0, 8, 'V. TANDA TANGAN', 0, 1);
|
|
$this->MultiCell(0, 8, 'Dengan ini, pelanggan menyatakan telah menerima pengambilan alat modem dan memahami seluruh proses yang telah dilakukan.', 0, 1);
|
|
$this->Ln(10);
|
|
$this->Cell(90, 7, 'Pelanggan:', 0, 0, 'C');
|
|
$this->Cell(90, 7, 'Petugas:', 0, 1, 'C');
|
|
$this->Ln(10);
|
|
$this->Cell(90, 7, '________________________', 0, 0, 'C');
|
|
$this->Cell(90, 7, '________________________', 0, 1, 'C');
|
|
$this->Cell(90, 7, $nama_pelanggan, 0, 0, 'C');
|
|
$this->Cell(90, 7, '', 0, 1, 'C');
|
|
}
|
|
}
|
|
?>
|