# Conflicts:
#	app/Http/Controllers/InvoiceController.php
#	resources/lang/en/texts.php
#	resources/views/invoices/edit.blade.php
This commit is contained in:
steenrabol 2016-01-11 20:39:18 +01:00
commit 6133c6ff07
169 changed files with 4613 additions and 303 deletions

View File

@ -2,6 +2,39 @@ module.exports = function(grunt) {
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
dump_dir: (function() {
var out = {};
grunt.file.expand({ filter: 'isDirectory'}, 'public/fonts/invoice-fonts/*').forEach(function(path) {
var fontName = /[^/]*$/.exec(path)[0],
files = {},
license='';
// Add license text
grunt.file.expand({ filter: 'isFile'}, path+'/*.txt').forEach(function(path) {
var licenseText = grunt.file.read(path);
// Fix anything that could escape from the comment
licenseText = licenseText.replace(/\*\//g,'*\\/');
license += "/*\n"+licenseText+"\n*/";
});
// Create files list
files['public/js/vfs_fonts/'+fontName+'.js'] = [path+'/*.ttf'];
out[fontName] = {
options: {
pre: license+'window.ninjaFontVfs=window.ninjaFontVfs||{};window.ninjaFontVfs.'+fontName+'=',
rootPath: path+'/'
},
files: files
};
});
// Return the computed object
return out;
}()),
concat: {
options: {
process: function(src, filepath) {
@ -145,7 +178,8 @@ module.exports = function(grunt) {
});
grunt.loadNpmTasks('grunt-contrib-concat');
grunt.loadNpmTasks('grunt-dump-dir');
grunt.registerTask('default', ['concat']);
grunt.registerTask('default', ['dump_dir', 'concat']);
};

View File

@ -62,32 +62,21 @@ class AccountApiController extends BaseAPIController
$account = Auth::user()->account;
$updatedAt = $request->updated_at ? date('Y-m-d H:i:s', $request->updated_at) : false;
if ($updatedAt) {
$account->load(['users' => function($query) use ($updatedAt) {
$query->where('updated_at', '>=', $updatedAt);
}])
->load(['clients' => function($query) use ($updatedAt) {
$query->where('updated_at', '>=', $updatedAt)->with('contacts');
}])
->load(['invoices' => function($query) use ($updatedAt) {
$query->where('updated_at', '>=', $updatedAt)->with('invoice_items', 'user', 'client');
}])
->load(['products' => function($query) use ($updatedAt) {
$query->where('updated_at', '>=', $updatedAt);
}])
->load(['tax_rates' => function($query) use ($updatedAt) {
$query->where('updated_at', '>=', $updatedAt);
$map = [
'users' => [],
'clients' => ['contacts'],
'invoices' => ['invoice_items', 'user', 'client', 'payments'],
'products' => [],
'tax_rates' => [],
];
foreach ($map as $key => $values) {
$account->load([$key => function($query) use ($values, $updatedAt) {
$query->withTrashed()->with($values);
if ($updatedAt) {
$query->where('updated_at', '>=', $updatedAt);
}
}]);
} else {
$account->load(
'users',
'clients.contacts',
'invoices.invoice_items',
'invoices.user',
'invoices.client',
'products',
'tax_rates'
);
}
$transformer = new AccountTransformer(null, $request->serializer);

View File

@ -361,14 +361,15 @@ class AccountController extends BaseController
$invoice->client = $client;
$invoice->invoice_items = [$invoiceItem];
$data['account'] = $account;
$data['invoice'] = $invoice;
$data['invoiceLabels'] = json_decode($account->invoice_labels) ?: [];
$data['title'] = trans('texts.invoice_design');
$data['invoiceDesigns'] = InvoiceDesign::getDesigns();
$data['invoiceFonts'] = Cache::get('fonts');
$data['section'] = $section;
$design = false;
foreach ($data['invoiceDesigns'] as $item) {
if ($item->id == $account->invoice_design_id) {
@ -705,10 +706,12 @@ class AccountController extends BaseController
$account = Auth::user()->account;
$account->hide_quantity = Input::get('hide_quantity') ? true : false;
$account->hide_paid_to_date = Input::get('hide_paid_to_date') ? true : false;
$account->header_font_id = Input::get('header_font_id');
$account->body_font_id = Input::get('body_font_id');
$account->primary_color = Input::get('primary_color');
$account->secondary_color = Input::get('secondary_color');
$account->invoice_design_id = Input::get('invoice_design_id');
if (Input::has('font_size')) {
$account->font_size = intval(Input::get('font_size'));
}

View File

@ -15,6 +15,8 @@ use App\Ninja\Repositories\InvoiceRepository;
use App\Ninja\Mailers\ContactMailer as Mailer;
use App\Http\Controllers\BaseAPIController;
use App\Ninja\Transformers\InvoiceTransformer;
use App\Http\Requests\CreateInvoiceRequest;
use App\Http\Requests\UpdateInvoiceRequest;
class InvoiceApiController extends BaseAPIController
{
@ -103,15 +105,11 @@ class InvoiceApiController extends BaseAPIController
* )
* )
*/
public function store()
public function store(CreateInvoiceRequest $request)
{
$data = Input::all();
$error = null;
if (isset($data['id']) || isset($data['public_id'])) {
die("We don't yet support updating invoices");
}
if (isset($data['email'])) {
$email = $data['email'];
$client = Client::scope()->whereHas('contacts', function($query) use ($email) {
@ -140,52 +138,30 @@ class InvoiceApiController extends BaseAPIController
$client = $this->clientRepo->save($clientData);
}
} else if (isset($data['client_id'])) {
$client = Client::scope($data['client_id'])->first();
$client = Client::scope($data['client_id'])->firstOrFail();
}
// check if the invoice number is set and unique
if (!isset($data['invoice_number']) && !isset($data['id'])) {
// do nothing... invoice number will be set automatically
} else if (isset($data['invoice_number'])) {
$invoice = Invoice::scope()->where('invoice_number', '=', $data['invoice_number'])->first();
if ($invoice) {
$error = trans('validation.unique', ['attribute' => 'texts.invoice_number']);
}
$data = self::prepareData($data, $client);
$data['client_id'] = $client->id;
$invoice = $this->invoiceRepo->save($data);
if (!isset($data['id'])) {
$invitation = Invitation::createNew();
$invitation->invoice_id = $invoice->id;
$invitation->contact_id = $client->contacts[0]->id;
$invitation->invitation_key = str_random(RANDOM_KEY_LENGTH);
$invitation->save();
}
if (!$error) {
if (!isset($data['client_id']) && !isset($data['email'])) {
$error = trans('validation.required_without', ['attribute' => 'client_id', 'values' => 'email']);
} else if (!$client) {
$error = trans('validation.not_in', ['attribute' => 'client_id']);
}
if (isset($data['email_invoice']) && $data['email_invoice']) {
$this->mailer->sendInvoice($invoice);
}
if ($error) {
return $error;
} else {
$data = self::prepareData($data, $client);
$data['client_id'] = $client->id;
$invoice = $this->invoiceRepo->save($data);
$invoice = Invoice::scope($invoice->public_id)->with('client', 'invoice_items', 'invitations')->first();
$transformer = new InvoiceTransformer(\Auth::user()->account, Input::get('serializer'));
$data = $this->createItem($invoice, $transformer, 'invoice');
if (!isset($data['id'])) {
$invitation = Invitation::createNew();
$invitation->invoice_id = $invoice->id;
$invitation->contact_id = $client->contacts[0]->id;
$invitation->invitation_key = str_random(RANDOM_KEY_LENGTH);
$invitation->save();
}
if (isset($data['email_invoice']) && $data['email_invoice']) {
$this->mailer->sendInvoice($invoice);
}
$invoice = Invoice::scope($invoice->public_id)->with('client', 'invoice_items', 'invitations')->first();
$transformer = new InvoiceTransformer(\Auth::user()->account, Input::get('serializer'));
$data = $this->createItem($invoice, $transformer, 'invoice');
return $this->response($data);
}
return $this->response($data);
}
private function prepareData($data, $client)
@ -304,4 +280,27 @@ class InvoiceApiController extends BaseAPIController
$headers = Utils::getApiHeaders();
return Response::make($response, $error ? 400 : 200, $headers);
}
public function update(UpdateInvoiceRequest $request, $publicId)
{
if ($request->action == ACTION_ARCHIVE) {
$invoice = Invoice::scope($publicId)->firstOrFail();
$this->invoiceRepo->archive($invoice);
$response = json_encode(RESULT_SUCCESS, JSON_PRETTY_PRINT);
$headers = Utils::getApiHeaders();
return Response::make($response, 200, $headers);
}
$data = $request->input();
$data['public_id'] = $publicId;
$this->invoiceRepo->save($data);
$invoice = Invoice::scope($publicId)->with('client', 'invoice_items', 'invitations')->firstOrFail();
$transformer = new InvoiceTransformer(\Auth::user()->account, Input::get('serializer'));
$data = $this->createItem($invoice, $transformer, 'invoice');
return $this->response($data);
}
}

View File

@ -28,7 +28,7 @@ use App\Events\InvoiceInvitationWasViewed;
use App\Events\QuoteInvitationWasViewed;
use App\Services\InvoiceService;
use App\Services\RecurringInvoiceService;
use App\Http\Requests\SaveInvoiceRequest;
use App\Http\Requests\SaveInvoiceWithClientRequest;
class InvoiceController extends BaseController
{
@ -104,6 +104,7 @@ class InvoiceController extends BaseController
'error' => trans('texts.invoice_not_found'),
'hideHeader' => true,
'clientViewCSS' => $account->clientViewCSS(),
'clientFontUrl' => $account->getFontsUrl(),
]);
}
@ -123,7 +124,12 @@ class InvoiceController extends BaseController
$invoice->invoice_date = Utils::fromSqlDate($invoice->invoice_date);
$invoice->due_date = Utils::fromSqlDate($invoice->due_date);
$invoice->is_pro = $account->isPro();
<<<<<<< HEAD
=======
$invoice->invoice_fonts = $account->getFontsData();
>>>>>>> cf24684adbce402f1c0e266672c4a2a5767dc754
if ($invoice->invoice_design_id == CUSTOM_DESIGN) {
$invoice->invoice_design->javascript = $account->custom_design;
} else {
@ -156,6 +162,7 @@ class InvoiceController extends BaseController
'hideLogo' => $account->isWhiteLabel(),
'hideHeader' => $account->isNinjaAccount(),
'clientViewCSS' => $account->clientViewCSS(),
'clientFontUrl' => $account->getFontsUrl(),
'invoice' => $invoice->hidePrivateFields(),
'invitation' => $invitation,
'invoiceLabels' => $account->getInvoiceLabels(),
@ -227,6 +234,7 @@ class InvoiceController extends BaseController
}
$invoice->invoice_date = Utils::fromSqlDate($invoice->invoice_date);
$invoice->recurring_due_date = $invoice->due_date;// Keep in SQL form
$invoice->due_date = Utils::fromSqlDate($invoice->due_date);
$invoice->start_date = Utils::fromSqlDate($invoice->start_date);
$invoice->end_date = Utils::fromSqlDate($invoice->end_date);
@ -356,7 +364,55 @@ class InvoiceController extends BaseController
$recurringHelp .= $line;
}
}
$recurringDueDateHelp = '';
foreach (preg_split("/((\r?\n)|(\r\n?))/", trans('texts.recurring_due_date_help')) as $line) {
$parts = explode("=>", $line);
if (count($parts) > 1) {
$line = $parts[0].' => '.Utils::processVariables($parts[0]);
$recurringDueDateHelp .= '<li>'.strip_tags($line).'</li>';
} else {
$recurringDueDateHelp .= $line;
}
}
// Create due date options
$recurringDueDates = array(
trans('texts.use_client_terms') => array('value' => '', 'class' => 'monthly weekly'),
);
$ends = array('th','st','nd','rd','th','th','th','th','th','th');
for($i = 1; $i < 31; $i++){
if ($i >= 11 && $i <= 13) $ordinal = $i. 'th';
else $ordinal = $i . $ends[$i % 10];
$dayStr = str_pad($i, 2, '0', STR_PAD_LEFT);
$str = trans('texts.day_of_month', array('ordinal'=>$ordinal));
$recurringDueDates[$str] = array('value' => "1998-01-$dayStr", 'data-num' => $i, 'class' => 'monthly');
}
$recurringDueDates[trans('texts.last_day_of_month')] = array('value' => "1998-01-31", 'data-num' => 31, 'class' => 'monthly');
$daysOfWeek = array(
trans('texts.sunday'),
trans('texts.monday'),
trans('texts.tuesday'),
trans('texts.wednesday'),
trans('texts.thursday'),
trans('texts.friday'),
trans('texts.saturday'),
);
foreach(array('1st','2nd','3rd','4th') as $i=>$ordinal){
foreach($daysOfWeek as $j=>$dayOfWeek){
$str = trans('texts.day_of_week_after', array('ordinal' => $ordinal, 'day' => $dayOfWeek));
$day = $i * 7 + $j + 1;
$dayStr = str_pad($day, 2, '0', STR_PAD_LEFT);
$recurringDueDates[$str] = array('value' => "1998-02-$dayStr", 'data-num' => $day, 'class' => 'weekly');
}
}
return [
'data' => Input::old('data'),
'account' => Auth::user()->account->load('country'),
@ -368,6 +424,7 @@ class InvoiceController extends BaseController
'paymentTerms' => Cache::get('paymentTerms'),
'industries' => Cache::get('industries'),
'invoiceDesigns' => InvoiceDesign::getDesigns(),
'invoiceFonts' => Cache::get('fonts'),
'frequencies' => array(
1 => 'Weekly',
2 => 'Two weeks',
@ -377,7 +434,9 @@ class InvoiceController extends BaseController
6 => 'Six months',
7 => 'Annually',
),
'recurringDueDates' => $recurringDueDates,
'recurringHelp' => $recurringHelp,
'recurringDueDateHelp' => $recurringDueDateHelp,
'invoiceLabels' => Auth::user()->account->getInvoiceLabels(),
'tasks' => Session::get('tasks') ? json_encode(Session::get('tasks')) : null,
'expenses' => Session::get('expenses') ? json_encode(Session::get('expenses')) : null,
@ -390,7 +449,7 @@ class InvoiceController extends BaseController
*
* @return Response
*/
public function store(SaveInvoiceRequest $request)
public function store(SaveInvoiceWithClientRequest $request)
{
$action = Input::get('action');
$entityType = Input::get('entityType');
@ -424,7 +483,7 @@ class InvoiceController extends BaseController
* @param int $id
* @return Response
*/
public function update(SaveInvoiceRequest $request)
public function update(SaveInvoiceWithClientRequest $request)
{
$action = Input::get('action');
$entityType = Input::get('entityType');
@ -589,6 +648,7 @@ class InvoiceController extends BaseController
'versionsJson' => json_encode($versionsJson),
'versionsSelect' => $versionsSelect,
'invoiceDesigns' => InvoiceDesign::getDesigns(),
'invoiceFonts' => Cache::get('fonts'),
];
return View::make('invoices.history', $data);

View File

@ -178,6 +178,7 @@ class PaymentController extends BaseController
'hideLogo' => $account->isWhiteLabel(),
'hideHeader' => $account->isNinjaAccount(),
'clientViewCSS' => $account->clientViewCSS(),
'clientFontUrl' => $account->getFontsUrl(),
'showAddress' => $accountGateway->show_address,
];

View File

@ -38,8 +38,9 @@ class PublicClientController extends BaseController
'client' => $client,
'hideLogo' => $account->isWhiteLabel(),
'clientViewCSS' => $account->clientViewCSS(),
'clientFontUrl' => $account->getFontsUrl(),
];
return response()->view('invited.dashboard', $data);
}
@ -83,6 +84,7 @@ class PublicClientController extends BaseController
'color' => $color,
'hideLogo' => $account->isWhiteLabel(),
'clientViewCSS' => $account->clientViewCSS(),
'clientFontUrl' => $account->getFontsUrl(),
'title' => trans('texts.invoices'),
'entityType' => ENTITY_INVOICE,
'columns' => Utils::trans(['invoice_number', 'invoice_date', 'invoice_total', 'balance_due', 'due_date']),
@ -113,6 +115,7 @@ class PublicClientController extends BaseController
'color' => $color,
'hideLogo' => $account->isWhiteLabel(),
'clientViewCSS' => $account->clientViewCSS(),
'clientFontUrl' => $account->getFontsUrl(),
'entityType' => ENTITY_PAYMENT,
'title' => trans('texts.payments'),
'columns' => Utils::trans(['invoice', 'transaction_reference', 'method', 'payment_amount', 'payment_date'])
@ -149,6 +152,7 @@ class PublicClientController extends BaseController
'color' => $color,
'hideLogo' => $account->isWhiteLabel(),
'clientViewCSS' => $account->clientViewCSS(),
'clientFontUrl' => $account->getFontsUrl(),
'title' => trans('texts.quotes'),
'entityType' => ENTITY_QUOTE,
'columns' => Utils::trans(['quote_number', 'quote_date', 'quote_total', 'due_date']),
@ -173,6 +177,7 @@ class PublicClientController extends BaseController
'error' => trans('texts.invoice_not_found'),
'hideHeader' => true,
'clientViewCSS' => $account->clientViewCSS(),
'clientFontUrl' => $account->getFontsUrl(),
]);
}

View File

@ -118,6 +118,7 @@ class QuoteController extends BaseController
'languages' => Cache::get('languages'),
'industries' => Cache::get('industries'),
'invoiceDesigns' => InvoiceDesign::getDesigns(),
'invoiceFonts' => Cache::get('fonts'),
'invoiceLabels' => Auth::user()->account->getInvoiceLabels(),
'isRecurring' => false,
];

View File

@ -156,7 +156,11 @@ class StartupCheck
if (Input::has('clear_cache') || !Cache::has($name)) {
if ($name == 'paymentTerms') {
$orderBy = 'num_days';
}
else if ($name == 'fonts') {
$orderBy = 'sort_order';
} elseif (in_array($name, ['currencies', 'industries', 'languages', 'countries'])) {
$orderBy = 'name';
} else {
$orderBy = 'id';

View File

@ -9,6 +9,7 @@ class VerifyCsrfToken extends BaseVerifier {
'signup/register',
'api/v1/login',
'api/v1/clients',
'api/v1/invoices/*',
'api/v1/invoices',
'api/v1/quotes',
'api/v1/payments',

View File

@ -38,7 +38,9 @@ class CreateClientRequest extends Request
}
return $factory->make(
$this->input(), $this->container->call([$this, 'rules']), $this->messages()
$this->input(),
$this->container->call([$this, 'rules']),
$this->messages()
);
}
}

View File

@ -0,0 +1,37 @@
<?php namespace app\Http\Requests;
use Auth;
use App\Http\Requests\Request;
use Illuminate\Validation\Factory;
use App\Models\Invoice;
class CreateInvoiceRequest extends Request
{
/**
* Determine if the user is authorized to make this request.
*
* @return bool
*/
public function authorize()
{
return true;
}
/**
* Get the validation rules that apply to the request.
*
* @return array
*/
public function rules()
{
$rules = [
'email' => 'required_without:client_id',
'client_id' => 'required_without:email',
'invoice_items' => 'valid_invoice_items',
'invoice_number' => 'unique:invoices,invoice_number,,id,account_id,'.Auth::user()->account_id,
'discount' => 'positive',
];
return $rules;
}
}

View File

@ -5,7 +5,7 @@ use App\Http\Requests\Request;
use Illuminate\Validation\Factory;
use App\Models\Invoice;
class SaveInvoiceRequest extends Request
class SaveInvoiceWithClientRequest extends Request
{
/**
* Determine if the user is authorized to make this request.

View File

@ -0,0 +1,42 @@
<?php namespace app\Http\Requests;
use Auth;
use App\Http\Requests\Request;
use Illuminate\Validation\Factory;
use App\Models\Invoice;
class UpdateInvoiceRequest extends Request
{
/**
* Determine if the user is authorized to make this request.
*
* @return bool
*/
public function authorize()
{
return true;
}
/**
* Get the validation rules that apply to the request.
*
* @return array
*/
public function rules()
{
if ($this->action == ACTION_ARCHIVE) {
return [];
}
$publicId = $this->route('invoices');
$invoiceId = Invoice::getPrivateId($publicId);
$rules = [
'invoice_items' => 'required|valid_invoice_items',
'invoice_number' => 'unique:invoices,invoice_number,'.$invoiceId.',id,account_id,'.Auth::user()->account_id,
'discount' => 'positive',
];
return $rules;
}
}

View File

@ -380,6 +380,8 @@ if (!defined('CONTACT_EMAIL')) {
define('MAX_LOGO_FILE_SIZE', 200); // KB
define('MAX_FAILED_LOGINS', 10);
define('DEFAULT_FONT_SIZE', 9);
define('DEFAULT_HEADER_FONT', 1);// Roboto
define('DEFAULT_BODY_FONT', 1);// Roboto
define('DEFAULT_SEND_RECURRING_HOUR', 8);
define('IMPORT_CSV', 'CSV');
@ -585,6 +587,7 @@ if (!defined('CONTACT_EMAIL')) {
'invoiceStatus' => 'App\Models\InvoiceStatus',
'frequencies' => 'App\Models\Frequency',
'gateways' => 'App\Models\Gateway',
'fonts' => 'App\Models\Font',
];
define('CACHED_TABLES', serialize($cachedTables));

View File

@ -377,7 +377,10 @@ class Utils
$format = Session::get(SESSION_DATE_FORMAT, DEFAULT_DATE_FORMAT);
$dateTime = DateTime::createFromFormat($format, $date);
return $formatResult ? $dateTime->format('Y-m-d') : $dateTime;
if(!$dateTime)
return $date;
else
return $formatResult ? $dateTime->format('Y-m-d') : $dateTime;
}
public static function fromSqlDate($date, $formatResult = true)

View File

@ -1,7 +1,10 @@
<?php namespace app\Listeners;
use Utils;
use Auth;
use App\Events\InvoiceWasEmailed;
use App\Events\InvoiceWasUpdated;
use App\Events\InvoiceWasCreated;
use App\Events\PaymentWasCreated;
use App\Events\PaymentWasDeleted;
use App\Events\PaymentWasRestored;
@ -9,15 +12,19 @@ use App\Events\InvoiceInvitationWasViewed;
class InvoiceListener
{
public function createdPayment(PaymentWasCreated $event)
public function createdInvoice(InvoiceWasCreated $event)
{
$payment = $event->payment;
$invoice = $payment->invoice;
$adjustment = $payment->amount * -1;
$partial = max(0, $invoice->partial - $payment->amount);
if (Utils::isPro()) {
return;
}
$invoice->updateBalances($adjustment, $partial);
$invoice->updatePaidStatus();
$invoice = $event->invoice;
$account = Auth::user()->account;
if ($account->invoice_design_id != $invoice->invoice_design_id) {
$account->invoice_design_id = $invoice->invoice_design_id;
$account->save();
}
}
public function updatedInvoice(InvoiceWasUpdated $event)
@ -32,6 +39,17 @@ class InvoiceListener
$invitation->markViewed();
}
public function createdPayment(PaymentWasCreated $event)
{
$payment = $event->payment;
$invoice = $payment->invoice;
$adjustment = $payment->amount * -1;
$partial = max(0, $invoice->partial - $payment->amount);
$invoice->updateBalances($adjustment, $partial);
$invoice->updatePaidStatus();
}
public function deletedPayment(PaymentWasDeleted $event)
{
$payment = $event->payment;

View File

@ -36,8 +36,8 @@ class Account extends Eloquent
public static $advancedSettings = [
ACCOUNT_INVOICE_SETTINGS,
ACCOUNT_INVOICE_DESIGN,
ACCOUNT_CLIENT_PORTAL,
ACCOUNT_EMAIL_SETTINGS,
ACCOUNT_CLIENT_PORTAL,
ACCOUNT_TEMPLATES_AND_REMINDERS,
ACCOUNT_CHARTS_AND_REPORTS,
ACCOUNT_DATA_VISUALIZATIONS,
@ -746,9 +746,15 @@ class Account extends Eloquent
$entityType = ENTITY_INVOICE;
}
$template = "<div>\$client,</div><br>" .
"<div>" . trans("texts.{$entityType}_message", ['amount' => '$amount']) . "</div><br>" .
"<div>\$viewLink</div><br>";
$template = "<div>\$client,</div><br>";
if ($this->isPro() && $this->email_design_id != EMAIL_DESIGN_PLAIN) {
$template .= "<div>" . trans("texts.{$entityType}_message_button", ['amount' => '$amount']) . "</div><br>" .
"<div style=\"text-align: center;\">\$viewButton</div><br>";
} else {
$template .= "<div>" . trans("texts.{$entityType}_message", ['amount' => '$amount']) . "</div><br>" .
"<div>\$viewLink</div><br>";
}
if ($message) {
$template .= "$message<p/>\r\n\r\n";
@ -877,11 +883,100 @@ class Account extends Eloquent
}
public function clientViewCSS(){
if (($this->isNinjaAccount() && $this->isPro()) || $this->isWhiteLabel()) {
return $this->client_view_css;
$css = null;
if ($this->isPro()) {
$bodyFont = $this->getBodyFontCss();
$headerFont = $this->getHeaderFontCss();
$css = 'body{'.$bodyFont.'}';
if ($headerFont != $bodyFont) {
$css .= 'h1,h2,h3,h4,h5,h6,.h1,.h2,.h3,.h4,.h5,.h6{'.$headerFont.'}';
}
if ((Utils::isNinja() && $this->isPro()) || $this->isWhiteLabel()) {
// For self-hosted users, a white-label license is required for custom CSS
$css .= $this->client_view_css;
}
}
return null;
return $css;
}
public function hasLargeFont()
{
return stripos($this->getBodyFontName(), 'chinese') || stripos($this->getHeaderFontName(), 'chinese');
}
public function getFontsUrl($protocol = ''){
$bodyFont = $this->getHeaderFontId();
$headerFont = $this->getBodyFontId();
$bodyFontSettings = Utils::getFromCache($bodyFont, 'fonts');
$google_fonts = array($bodyFontSettings['google_font']);
if($headerFont != $bodyFont){
$headerFontSettings = Utils::getFromCache($headerFont, 'fonts');
$google_fonts[] = $headerFontSettings['google_font'];
}
return ($protocol?$protocol.':':'').'//fonts.googleapis.com/css?family='.implode('|',$google_fonts);
}
public function getHeaderFontId() {
return $this->isPro() ? $this->header_font_id : DEFAULT_HEADER_FONT;
}
public function getBodyFontId() {
return $this->isPro() ? $this->body_font_id : DEFAULT_BODY_FONT;
}
public function getHeaderFontName(){
return Utils::getFromCache($this->getHeaderFontId(), 'fonts')['name'];
}
public function getBodyFontName(){
return Utils::getFromCache($this->getBodyFontId(), 'fonts')['name'];
}
public function getHeaderFontCss($include_weight = true){
$font_data = Utils::getFromCache($this->getHeaderFontId(), 'fonts');
$css = 'font-family:'.$font_data['css_stack'].';';
if($include_weight){
$css .= 'font-weight:'.$font_data['css_weight'].';';
}
return $css;
}
public function getBodyFontCss($include_weight = true){
$font_data = Utils::getFromCache($this->getBodyFontId(), 'fonts');
$css = 'font-family:'.$font_data['css_stack'].';';
if($include_weight){
$css .= 'font-weight:'.$font_data['css_weight'].';';
}
return $css;
}
public function getFonts(){
return array_unique(array($this->getHeaderFontId(), $this->getBodyFontId()));
}
public function getFontsData(){
$data = array();
foreach($this->getFonts() as $font){
$data[] = Utils::getFromCache($font, 'fonts');
}
return $data;
}
public function getFontFolders(){
return array_map(function($item){return $item['folder'];}, $this->getFontsData());
}
}

8
app/Models/Font.php Normal file
View File

@ -0,0 +1,8 @@
<?php namespace App\Models;
use Eloquent;
class Font extends Eloquent
{
public $timestamps = false;
}

View File

@ -177,6 +177,11 @@ class Invoice extends EntityModel implements BalanceAffecting
return $this->belongsTo('App\Models\InvoiceDesign');
}
public function payments()
{
return $this->hasMany('App\Models\Payment', 'invoice_id', 'id');
}
public function recurring_invoice()
{
return $this->belongsTo('App\Models\Invoice');
@ -349,6 +354,7 @@ class Invoice extends EntityModel implements BalanceAffecting
'account',
'invoice_design',
'invoice_design_id',
'invoice_fonts',
'is_pro',
'is_quote',
'custom_value1',
@ -482,6 +488,93 @@ class Invoice extends EntityModel implements BalanceAffecting
return $schedule[1]->getStart();
}
public function getDueDate($invoice_date = null){
if(!$this->is_recurring) {
return $this->due_date ? $this->due_date : null;
}
else{
$now = time();
if($invoice_date) {
// If $invoice_date is specified, all calculations are based on that date
if(is_numeric($invoice_date)) {
$now = $invoice_date;
}
else if(is_string($invoice_date)) {
$now = strtotime($invoice_date);
}
elseif ($invoice_date instanceof \DateTime) {
$now = $invoice_date->getTimestamp();
}
}
if($this->due_date){
// This is a recurring invoice; we're using a custom format here.
// The year is always 1998; January is 1st, 2nd, last day of the month.
// February is 1st Sunday after, 1st Monday after, ..., through 4th Saturday after.
$dueDateVal = strtotime($this->due_date);
$monthVal = (int)date('n', $dueDateVal);
$dayVal = (int)date('j', $dueDateVal);
if($monthVal == 1) {// January; day of month
$currentDay = (int)date('j', $now);
$lastDayOfMonth = (int)date('t', $now);
$dueYear = (int)date('Y', $now);// This year
$dueMonth = (int)date('n', $now);// This month
$dueDay = $dayVal;// The day specified for the invoice
if($dueDay > $lastDayOfMonth) {
// No later than the end of the month
$dueDay = $lastDayOfMonth;
}
if($currentDay >= $dueDay) {
// Wait until next month
// We don't need to handle the December->January wraparaound, since PHP handles month 13 as January of next year
$dueMonth++;
// Reset the due day
$dueDay = $dayVal;
$lastDayOfMonth = (int)date('t', mktime(0, 0, 0, $dueMonth, 1, $dueYear));// The number of days in next month
// Check against the last day again
if($dueDay > $lastDayOfMonth){
// No later than the end of the month
$dueDay = $lastDayOfMonth;
}
}
$dueDate = mktime(0, 0, 0, $dueMonth, $dueDay, $dueYear);
}
else if($monthVal == 2) {// February; day of week
$ordinals = array('first', 'second', 'third', 'fourth');
$daysOfWeek = array('sunday', 'monday', 'tuesday', 'wednesday', 'thursday', 'friday', 'saturday');
$ordinalIndex = ceil($dayVal / 7) - 1;// 1-7 are "first"; 8-14 are "second", etc.
$dayOfWeekIndex = ($dayVal - 1) % 7;// 1,8,15,22 are Sunday, 2,9,16,23 are Monday, etc.
$dayStr = $ordinals[$ordinalIndex] . ' ' . $daysOfWeek[$dayOfWeekIndex];// "first sunday", "first monday", etc.
$dueDate = strtotime($dayStr, $now);
}
if($dueDate) {
return date('Y-m-d', $dueDate);// SQL format
}
}
else if ($this->client->payment_terms != 0) {
// No custom due date set for this invoice; use the client's payment terms
$days = $this->client->payment_terms;
if ($days == -1) {
$days = 0;
}
return date('Y-m-d', strtotime('+'.$days.' day', $now));
}
}
// Couldn't calculate one
return null;
}
public function getPrettySchedule($min = 1, $max = 10)
{
@ -493,7 +586,14 @@ class Invoice extends EntityModel implements BalanceAffecting
for ($i=$min; $i<min($max, count($schedule)); $i++) {
$date = $schedule[$i];
$date = $this->account->formatDate($date->getStart());
$dateStart = $date->getStart();
$date = $this->account->formatDate($dateStart);
$dueDate = $this->getDueDate($dateStart);
if($dueDate) {
$date .= ' <small>(' . trans('texts.due') . ' ' . $this->account->formatDate($dueDate) . ')</small>';
}
$dates[] = $date;
}

View File

@ -13,20 +13,20 @@ class ClientTransformer extends BaseTransformer
return new Item($data, function ($data) {
return [
'name' => $data->organization,
'work_phone' => $data->busphone,
'address1' => $data->street,
'address2' => $data->street2,
'city' => $data->city,
'state' => $data->province,
'postal_code' => $data->postalcode,
'private_notes' => $data->notes,
'name' => $this->getString($data, 'organization'),
'work_phone' => $this->getString($data, 'busphone'),
'address1' => $this->getString($data, 'street'),
'address2' => $this->getString($data, 'street2'),
'city' => $this->getString($data, 'city'),
'state' => $this->getString($data, 'province'),
'postal_code' => $this->getString($data, 'postalcode'),
'private_notes' => $this->getString($data, 'notes'),
'contacts' => [
[
'first_name' => $data->firstname,
'last_name' => $data->lastname,
'email' => $data->email,
'phone' => $data->mobphone ?: $data->homephone,
'first_name' => $this->getString($data, 'firstname'),
'last_name' => $this->getString($data, 'lastname'),
'email' => $this->getString($data, 'email'),
'phone' => $this->getString($data, 'mobphone') ?: $this->getString($data, 'homephone'),
],
],
'country_id' => $this->getCountryId($data->country),

View File

@ -20,14 +20,13 @@ class InvoiceTransformer extends BaseTransformer
'client_id' => $this->getClientId($data->organization),
'invoice_number' => $this->getInvoiceNumber($data->invoice_number),
'paid' => (float) $data->paid,
'po_number' => $data->po_number,
'terms' => $data->terms,
'public_notes' => $data->notes,
'po_number' => $this->getString($data, 'po_number'),
'terms' => $this->getString($data, 'terms'),
'invoice_date_sql' => $data->create_date,
'invoice_items' => [
[
'product_key' => '',
'notes' => $data->notes,
'notes' => $this->getString($data, 'notes'),
'cost' => (float) $data->amount,
'qty' => 1,
]

View File

@ -13,7 +13,7 @@ class ClientTransformer extends BaseTransformer
return new Item($data, function ($data) {
return [
'name' => $data->client_name,
'name' => $this->getString($data, 'client_name'),
];
});
}

View File

@ -14,10 +14,10 @@ class ContactTransformer extends BaseTransformer
return new Item($data, function ($data) {
return [
'client_id' => $this->getClientId($data->client),
'first_name' => $data->first_name,
'last_name' => $data->last_name,
'email' => $data->email,
'phone' => $data->office_phone ?: $data->mobile_phone,
'first_name' => $this->getString($data, 'first_name'),
'last_name' => $this->getString($data, 'last_name'),
'email' => $this->getString($data, 'email'),
'phone' => $this->getString($data, 'office_phone') ?: $this->getString($data, 'mobile_phone'),
];
});
}

View File

@ -20,12 +20,12 @@ class InvoiceTransformer extends BaseTransformer
'client_id' => $this->getClientId($data->client),
'invoice_number' => $this->getInvoiceNumber($data->id),
'paid' => (float) $data->paid_amount,
'po_number' => $data->po_number,
'po_number' => $this->getString($data, 'po_number'),
'invoice_date_sql' => $this->getDate($data->issue_date, 'm/d/Y'),
'invoice_items' => [
[
'product_key' => '',
'notes' => $data->subject,
'notes' => $this->getString($data, 'subject'),
'cost' => (float) $data->invoice_amount,
'qty' => 1,
]

View File

@ -13,21 +13,21 @@ class ClientTransformer extends BaseTransformer
return new Item($data, function ($data) {
return [
'name' => $data->name,
'name' => $this->getString($data, 'name'),
'contacts' => [
[
'first_name' => $this->getFirstName($data->primary_contact),
'last_name' => $this->getLastName($data->primary_contactk),
'email' => $data->business_email,
'email' => $this->getString($data, 'business_email'),
],
],
'address1' => $data->address_1,
'address2' => $data->address_2,
'city' => $data->city,
'state' => $data->state_name,
'postal_code' => $data->zip_code,
'work_phone' => $data->phone,
'website' => $data->website,
'address1' => $this->getString($data, 'address_1'),
'address2' => $this->getString($data, 'address_2'),
'city' => $this->getString($data, 'city'),
'state' => $this->getString($data, 'state_name'),
'postal_code' => $this->getString($data, 'zip_code'),
'work_phone' => $this->getString($data, 'phone'),
'website' => $this->getString($data, 'website'),
'country_id' => $this->getCountryId($data->country),
];
});

View File

@ -25,7 +25,7 @@ class InvoiceTransformer extends BaseTransformer
'invoice_items' => [
[
'product_key' => '',
'notes' => $data->summary,
'notes' => $this->getString($data, 'summary'),
'cost' => (float) $data->billed_total,
'qty' => 1,
]

View File

@ -13,19 +13,19 @@ class ClientTransformer extends BaseTransformer
return new Item($data, function ($data) {
return [
'name' => $data->client_name,
'work_phone' => $data->tel,
'website' => $data->website,
'address1' => $data->address,
'city' => $data->city,
'state' => $data->state,
'postal_code' => $data->postcode,
'name' => $this->getString($data, 'client_name'),
'work_phone' => $this->getString($data, 'tel'),
'website' => $this->getString($data, 'website'),
'address1' => $this->getString($data, 'address'),
'city' => $this->getString($data, 'city'),
'state' => $this->getString($data, 'state'),
'postal_code' => $this->getString($data, 'postcode'),
'country_id' => $this->getCountryIdBy2($data->country),
'private_notes' => $data->notes,
'private_notes' => $this->getString($data, 'notes'),
'contacts' => [
[
'email' => $data->email,
'phone' => $data->mobile,
'email' => $this->getString($data, 'email'),
'phone' => $this->getString($data, 'mobile'),
],
],
];

View File

@ -19,15 +19,15 @@ class InvoiceTransformer extends BaseTransformer
return [
'client_id' => $this->getClientId($data->client_name),
'invoice_number' => $this->getInvoiceNumber($data->ref),
'po_number' => $data->po_number,
'po_number' => $this->getString($data, 'po_number'),
'invoice_date_sql' => $data->date,
'due_date_sql' => $data->due_date,
'invoice_footer' => $data->footer,
'invoice_footer' => $this->getString($data, 'footer'),
'paid' => (float) $data->paid,
'invoice_items' => [
[
'product_key' => '',
'notes' => $data->description,
'notes' => $this->getString($data, 'description'),
'cost' => (float) $data->total,
'qty' => 1,
]

View File

@ -13,19 +13,19 @@ class ClientTransformer extends BaseTransformer
return new Item($data, function ($data) {
return [
'name' => $data->name,
'city' => isset($data->city) ? $data->city : '',
'state' => isset($data->city) ? $data->stateprovince : '',
'id_number' => isset($data->registration_number) ? $data->registration_number : '',
'postal_code' => isset($data->postalzip_code) ? $data->postalzip_code : '',
'private_notes' => isset($data->notes) ? $data->notes : '',
'work_phone' => isset($data->phone) ? $data->phone : '',
'name' => $this->getString($data, 'name'),
'city' => $this->getString($data, 'city'),
'state' => $this->getString($data, 'stateprovince'),
'id_number' => $this->getString($data, 'registration_number'),
'postal_code' => $this->getString($data, 'postalzip_code'),
'private_notes' => $this->getString($data, 'notes'),
'work_phone' => $this->getString($data, 'phone'),
'contacts' => [
[
'first_name' => isset($data->contact_name) ? $this->getFirstName($data->contact_name) : '',
'last_name' => isset($data->contact_name) ? $this->getLastName($data->contact_name) : '',
'email' => $data->email,
'phone' => isset($data->mobile) ? $data->mobile : '',
'email' => $this->getString($data, 'email'),
'phone' => $this->getString($data, 'mobile'),
],
],
'country_id' => isset($data->country) ? $this->getCountryId($data->country) : null,

View File

@ -20,15 +20,15 @@ class InvoiceTransformer extends BaseTransformer
'client_id' => $this->getClientId($data->client),
'invoice_number' => $this->getInvoiceNumber($data->document_no),
'paid' => (float) $data->paid_to_date,
'po_number' => $data->purchase_order,
'terms' => $data->terms,
'public_notes' => $data->notes,
'po_number' => $this->getString($data, 'purchase_order'),
'terms' => $this->getString($data, 'terms'),
'public_notes' => $this->getString($data, 'notes'),
'invoice_date_sql' => $this->getDate($data->date),
'due_date_sql' => $this->getDate($data->due_date),
'invoice_items' => [
[
'product_key' => '',
'notes' => $data->description,
'notes' => $this->getString($data, 'description'),
'cost' => (float) $data->total,
'qty' => 1,
]

View File

@ -13,13 +13,13 @@ class ClientTransformer extends BaseTransformer
return new Item($data, function ($data) {
return [
'name' => $data->company,
'work_phone' => $data->phone,
'name' => $this->getString($data, 'company'),
'work_phone' => $this->getString($data, 'phone'),
'contacts' => [
[
'first_name' => $this->getFirstName($data->name),
'last_name' => $this->getLastName($data->name),
'email' => $data->email,
'email' => $this->getString($data, 'email'),
],
],
];

View File

@ -20,13 +20,13 @@ class InvoiceTransformer extends BaseTransformer
'client_id' => $this->getClientId($data->client),
'invoice_number' => $this->getInvoiceNumber($data->number),
'paid' => (float) $data->total - (float) $data->balance,
'public_notes' => $data->subject,
'public_notes' => $this->getString($data, 'subject'),
'invoice_date_sql' => $data->date_sent,
'due_date_sql' => $data->date_due,
'invoice_items' => [
[
'product_key' => '',
'notes' => $data->line_item,
'notes' => $this->getString($data, 'line_item'),
'cost' => (float) $data->total,
'qty' => 1,
]

View File

@ -13,22 +13,22 @@ class ClientTransformer extends BaseTransformer
return new Item($data, function ($data) {
return [
'name' => $data->customer_name,
'id_number' => $data->account_number,
'work_phone' => $data->phone,
'website' => $data->website,
'address1' => $data->address_line_1,
'address2' => $data->address_line_2,
'city' => $data->city,
'state' => $data->provincestate,
'postal_code' => $data->postal_codezip_code,
'private_notes' => $data->delivery_instructions,
'name' => $this->getString($data, 'customer_name'),
'id_number' => $this->getString($data, 'account_number'),
'work_phone' => $this->getString($data, 'phone'),
'website' => $this->getString($data, 'website'),
'address1' => $this->getString($data, 'address_line_1'),
'address2' => $this->getString($data, 'address_line_2'),
'city' => $this->getString($data, 'city'),
'state' => $this->getString($data, 'provincestate'),
'postal_code' => $this->getString($data, 'postal_codezip_code'),
'private_notes' => $this->getString($data, 'delivery_instructions'),
'contacts' => [
[
'first_name' => $data->contact_first_name,
'last_name' => $data->contact_last_name,
'email' => $data->email,
'phone' => $data->mobile,
'first_name' => $this->getString($data, 'contact_first_name'),
'last_name' => $this->getString($data, 'contact_last_name'),
'email' => $this->getString($data, 'email'),
'phone' => $this->getString($data, 'mobile'),
],
],
'country_id' => $this->getCountryId($data->country),

View File

@ -19,14 +19,14 @@ class InvoiceTransformer extends BaseTransformer
return [
'client_id' => $this->getClientId($data->customer),
'invoice_number' => $this->getInvoiceNumber($data->invoice_num),
'po_number' => $data->po_so,
'po_number' => $this->getString($data, 'po_so'),
'invoice_date_sql' => $this->getDate($data->invoice_date),
'due_date_sql' => $this->getDate($data->due_date),
'paid' => 0,
'invoice_items' => [
[
'product_key' => $data->product,
'notes' => $data->description,
'product_key' => $this->getString($data, 'product'),
'notes' => $this->getString($data, 'description'),
'cost' => (float) $data->amount,
'qty' => (float) $data->quantity,
]

View File

@ -13,21 +13,21 @@ class ClientTransformer extends BaseTransformer
return new Item($data, function ($data) {
return [
'name' => $data->customer_name,
'id_number' => $data->customer_id,
'work_phone' => $data->phonek,
'address1' => $data->billing_address,
'city' => $data->billing_city,
'state' => $data->billing_state,
'postal_code' => $data->billing_code,
'private_notes' => $data->notes,
'website' => $data->website,
'name' => $this->getString($data, 'customer_name'),
'id_number' => $this->getString($data, 'customer_id'),
'work_phone' => $this->getString($data, 'phone'),
'address1' => $this->getString($data, 'billing_address'),
'city' => $this->getString($data, 'billing_city'),
'state' => $this->getString($data, 'billing_state'),
'postal_code' => $this->getString($data, 'billing_code'),
'private_notes' => $this->getString($data, 'notes'),
'website' => $this->getString($data, 'website'),
'contacts' => [
[
'first_name' => $data->first_name,
'last_name' => $data->last_name,
'email' => $data->emailid,
'phone' => $data->mobilephone,
'first_name' => $this->getString($data, 'first_name'),
'last_name' => $this->getString($data, 'last_name'),
'email' => $this->getString($data, 'emailid'),
'phone' => $this->getString($data, 'mobilephone'),
],
],
'country_id' => $this->getCountryId($data->billing_country),

View File

@ -20,13 +20,13 @@ class InvoiceTransformer extends BaseTransformer
'client_id' => $this->getClientId($data->customer_name),
'invoice_number' => $this->getInvoiceNumber($data->invoice_number),
'paid' => (float) $data->total - (float) $data->balance,
'po_number' => $data->purchaseorder,
'po_number' => $this->getString($data, 'purchaseorder'),
'due_date_sql' => $data->due_date,
'invoice_date_sql' => $data->invoice_date,
'invoice_items' => [
[
'product_key' => '',
'notes' => $data->item_desc,
'notes' => $this->getString($data, 'item_desc'),
'cost' => (float) $data->total,
'qty' => 1,
]

View File

@ -9,6 +9,12 @@ class Mailer
{
public function sendTo($toEmail, $fromEmail, $fromName, $subject, $view, $data = [])
{
// check the username is set
if ( ! env('POSTMARK_API_TOKEN') && ! env('MAIL_USERNAME')) {
return trans('texts.invalid_mail_config');
}
// don't send emails to dummy addresses
if (stristr($toEmail, '@example.com')) {
return true;
}

View File

@ -150,6 +150,7 @@ class InvoiceRepository extends BaseRepository
->where('invoices.is_deleted', '=', false)
->where('clients.deleted_at', '=', null)
->where('invoices.is_recurring', '=', false)
->where('invoices.invoice_status_id', '>=', INVOICE_STATUS_SENT)
->select(
DB::raw('COALESCE(clients.currency_id, accounts.currency_id) currency_id'),
DB::raw('COALESCE(clients.country_id, accounts.country_id) country_id'),
@ -221,7 +222,7 @@ class InvoiceRepository extends BaseRepository
$account->invoice_footer = trim($data['invoice_footer']);
}
$account->save();
}
}
if (isset($data['invoice_number']) && !$invoice->is_recurring) {
$invoice->invoice_number = trim($data['invoice_number']);
@ -236,7 +237,11 @@ class InvoiceRepository extends BaseRepository
if (isset($data['partial'])) {
$invoice->partial = round(Utils::parseFloat($data['partial']), 2);
}
$invoice->invoice_date = isset($data['invoice_date_sql']) ? $data['invoice_date_sql'] : Utils::toSqlDate($data['invoice_date']);
if (isset($data['invoice_date_sql'])) {
$invoice->invoice_date = $data['invoice_date_sql'];
} elseif (isset($data['invoice_date'])) {
$invoice->invoice_date = Utils::toSqlDate($data['invoice_date']);
}
if ($invoice->is_recurring) {
if ($invoice->start_date && $invoice->start_date != Utils::toSqlDate($data['start_date'])) {
@ -248,6 +253,9 @@ class InvoiceRepository extends BaseRepository
$invoice->end_date = Utils::toSqlDate($data['end_date']);
$invoice->due_date = null;
$invoice->auto_bill = isset($data['auto_bill']) && $data['auto_bill'] ? true : false;
if(isset($data['recurring_due_date'])){
$invoice->due_date = $data['recurring_due_date'];
}
} else {
if (isset($data['due_date']) || isset($data['due_date_sql'])) {
$invoice->due_date = isset($data['due_date_sql']) ? $data['due_date_sql'] : Utils::toSqlDate($data['due_date']);
@ -607,14 +615,7 @@ class InvoiceRepository extends BaseRepository
$invoice->custom_text_value1 = $recurInvoice->custom_text_value1;
$invoice->custom_text_value2 = $recurInvoice->custom_text_value2;
$invoice->is_amount_discount = $recurInvoice->is_amount_discount;
if ($invoice->client->payment_terms != 0) {
$days = $invoice->client->payment_terms;
if ($days == -1) {
$days = 0;
}
$invoice->due_date = date_create()->modify($days.' day')->format('Y-m-d');
}
$invoice->due_date = $recurInvoice->getDueDate();
$invoice->save();

View File

@ -20,7 +20,7 @@ class InvoiceItemTransformer extends EntityTransformer
'cost' => (float) $item->cost,
'qty' => (float) $item->qty,
'tax_name' => $item->tax_name,
'tax_rate' => $item->tax_rate
'tax_rate' => (float) $item->tax_rate
];
}
}

View File

@ -22,6 +22,7 @@ class InvoiceTransformer extends EntityTransformer
protected $defaultIncludes = [
'invoice_items',
'payments'
];
public function includeInvoiceItems(Invoice $invoice)
@ -30,6 +31,12 @@ class InvoiceTransformer extends EntityTransformer
return $this->includeCollection($invoice->invoice_items, $transformer, ENTITY_INVOICE_ITEMS);
}
public function includePayments(Invoice $invoice)
{
$transformer = new PaymentTransformer($this->account, $this->serializer);
return $this->includeCollection($invoice->payments, $transformer, ENTITY_PAYMENT);
}
public function transform(Invoice $invoice)
{
return [
@ -66,8 +73,8 @@ class InvoiceTransformer extends EntityTransformer
'auto_bill' => (bool) $invoice->auto_bill,
'account_key' => $this->account->account_key,
'user_id' => (int) $invoice->user->public_id + 1,
'custom_value1' => $invoice->custom_value1,
'custom_value2' => $invoice->custom_value2,
'custom_value1' => (float) $invoice->custom_value1,
'custom_value2' => (float) $invoice->custom_value2,
'custom_taxes1' => (bool) $invoice->custom_taxes1,
'custom_taxes2' => (bool) $invoice->custom_taxes2,
'has_expenses' => (bool) $invoice->has_expenses,

View File

@ -18,10 +18,7 @@ class PaymentTransformer extends EntityTransformer
* @SWG\Property(property="amount", type="float", example=10, readOnly=true)
* @SWG\Property(property="invoice_id", type="integer", example=1)
*/
protected $defaultIncludes = [
'invoice',
'client',
];
protected $defaultIncludes = [];
public function __construct(Account $account)
@ -50,6 +47,11 @@ class PaymentTransformer extends EntityTransformer
'account_key' => $this->account->account_key,
'user_id' => (int) $payment->user->public_id + 1,
'transaction_reference' => $payment->transaction_reference,
'payment_date' => $payment->payment_date,
'updated_at' => $this->getTimestamp($payment->updated_at),
'archived_at' => $this->getTimestamp($payment->deleted_at),
'is_deleted' => (bool) $payment->is_deleted,
'payment_type_id' => (int) $payment->payment_type_id,
];
}
}

View File

@ -31,6 +31,7 @@ class EventServiceProvider extends ServiceProvider {
'App\Events\InvoiceWasCreated' => [
'App\Listeners\ActivityListener@createdInvoice',
'App\Listeners\SubscriptionListener@createdInvoice',
'App\Listeners\InvoiceListener@createdInvoice',
],
'App\Events\InvoiceWasUpdated' => [
'App\Listeners\ActivityListener@updatedInvoice',

View File

@ -0,0 +1,70 @@
<?php
use Illuminate\Database\Migrations\Migration;
class AddInvoiceFontSupport extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::dropIfExists('fonts');
Schema::create('fonts', function ($t) {
$t->increments('id');
$t->string('name');
$t->string('folder');
$t->string('css_stack');
$t->smallInteger('css_weight')->default(400);
$t->string('google_font');
$t->string('normal');
$t->string('bold');
$t->string('italics');
$t->string('bolditalics');
$t->boolean('is_early_access');
$t->unsignedInteger('sort_order')->default(10000);
});
// Create fonts
$seeder = new FontsSeeder();
$seeder->run();
Schema::table('accounts', function ($table) {
$table->unsignedInteger('header_font_id')->default(1);
$table->unsignedInteger('body_font_id')->default(1);
});
Schema::table('accounts', function ($table) {
$table->foreign('header_font_id')->references('id')->on('fonts');
$table->foreign('body_font_id')->references('id')->on('fonts');
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
if (Schema::hasColumn('accounts', 'header_font_id')) {
Schema::table('accounts', function ($table) {
$table->dropForeign('accounts_header_font_id_foreign');
$table->dropColumn('header_font_id');
});
}
if (Schema::hasColumn('accounts', 'body_font_id')) {
Schema::table('accounts', function ($table) {
$table->dropForeign('accounts_body_font_id_foreign');
$table->dropColumn('body_font_id');
});
}
Schema::dropIfExists('fonts');
}
}

View File

@ -16,6 +16,7 @@ class DatabaseSeeder extends Seeder {
$this->call('ConstantsSeeder');
$this->call('CountriesSeeder');
$this->call('PaymentLibrariesSeeder');
$this->call('FontsSeeder');
}
}

View File

@ -0,0 +1,231 @@
<?php
use App\Models\Font;
class FontsSeeder extends Seeder
{
public function run()
{
Eloquent::unguard();
$this->createFonts();
}
private function createFonts()
{
$fonts = [
[
'folder' => 'roboto',
'name' => 'Roboto',
'css_stack' => "'Roboto', Arial, Helvetica, sans-serif",
'google_font' => 'Roboto:400,700,900,100',
'normal' => 'Roboto-Regular.ttf',
'bold' => 'Roboto-Medium.ttf',
'italics' => 'Roboto-Italic.ttf',
'bolditalics' => 'Roboto-Italic.ttf',
'sort_order' => 100,
],
[
'folder' => 'abril_fatface',
'name' => 'Abril Fatface',
'css_stack' => "'Abril Fatface', Georgia, serif",
'google_font' => 'Abril+Fatface',
'normal' => 'AbrilFatface-Regular.ttf',
'bold' => 'AbrilFatface-Regular.ttf',
'italics' => 'AbrilFatface-Regular.ttf',
'bolditalics' => 'AbrilFatface-Regular.ttf',
'sort_order' => 200
],
[
'folder' => 'arvo',
'name' => 'Arvo',
'css_stack' => "'Arvo', Georgia, serif",
'google_font' => 'Arvo:400,700',
'normal' => 'Arvo-Regular.ttf',
'bold' => 'Arvo-Bold.ttf',
'italics' => 'Arvo-Italic.ttf',
'bolditalics' => 'Arvo-Italic.ttf',
'sort_order' => 300
],
[
'folder' => 'josefin_sans',
'name' => 'Josefin Sans',
'css_stack' => "'Josefin Sans', Arial, Helvetica, sans-serif",
'google_font' => 'Josefin Sans:400,700,900,100',
'normal' => 'JosefinSans-Regular.ttf',
'bold' => 'JosefinSans-Bold.ttf',
'italics' => 'JosefinSans-Italic.ttf',
'bolditalics' => 'JosefinSans-Italic.ttf',
'sort_order' => 400
],
[
'folder' => 'josefin_sans_light',
'css_stack' => "'Josefin Sans', Arial, Helvetica, sans-serif",
'name' => 'Josefin Sans Light',
'css_weight' => 300,
'google_font' => 'Josefin+Sans:300,700,900,100',
'normal' => 'JosefinSans-Light.ttf',
'bold' => 'JosefinSans-SemiBold.ttf',
'italics' => 'JosefinSans-LightItalic.ttf',
'bolditalics' => 'JosefinSans-LightItalic.ttf',
'sort_order' => 600
],
[
'folder' => 'josefin_slab',
'name' => 'Josefin Slab',
'css_stack' => "'Josefin Slab', Arial, Helvetica, sans-serif",
'google_font' => 'Josefin Sans:400,700,900,100',
'normal' => 'JosefinSlab-Regular.ttf',
'bold' => 'JosefinSlab-Bold.ttf',
'italics' => 'JosefinSlab-Italic.ttf',
'bolditalics' => 'JosefinSlab-Italic.ttf',
'sort_order' => 700
],
[
'folder' => 'josefin_slab_light',
'name' => 'Josefin Slab Light',
'css_stack' => "'Josefin Slab', Georgia, serif",
'css_weight' => 300,
'google_font' => 'Josefin+Sans:400,700,900,100',
'normal' => 'JosefinSlab-Light.ttf',
'bold' => 'JosefinSlab-SemiBold.ttf',
'italics' => 'JosefinSlab-LightItalic.ttf',
'bolditalics' => 'JosefinSlab-LightItalic.ttf',
'sort_order' => 800
],
[
'folder' => 'open_sans',
'name' => 'Open Sans',
'css_stack' => "'Open Sans', Arial, Helvetica, sans-serif",
'google_font' => 'Open+Sans:400,700,900,100',
'normal' => 'OpenSans-Regular.ttf',
'bold' => 'OpenSans-Semibold.ttf',
'italics' => 'OpenSans-Italic.ttf',
'bolditalics' => 'OpenSans-Italic.ttf',
'sort_order' => 900
],
[
'folder' => 'open_sans_light',
'name' => 'Open Sans Light',
'css_stack' => "'Open Sans', Arial, Helvetica, sans-serif",
'css_weight' => 300,
'google_font' => 'Open+Sans:300,700,900,100',
'normal' => 'OpenSans-Light.ttf',
'bold' => 'OpenSans-Regular.ttf',
'italics' => 'OpenSans-LightItalic.ttf',
'bolditalics' => 'OpenSans-LightItalic.ttf',
'sort_order' => 1000,
],
[
'folder' => 'pt_sans',
'name' => 'PT Sans',
'css_stack' => "'PT Sans', Arial, Helvetica, sans-serif",
'google_font' => 'PT+Sans:400,700,900,100',
'normal' => 'PTSans-Regular.ttf',
'bold' => 'PTSans-Bold.ttf',
'italics' => 'PTSans-Italic.ttf',
'bolditalics' => 'PTSans-Italic.ttf',
'sort_order' => 1100,
],
[
'folder' => 'pt_serif',
'name' => 'PT Serif',
'css_stack' => "'PT Serif', Georgia, serif",
'google_font' => 'PT+Serif:400,700,900,100',
'normal' => 'PTSerif-Regular.ttf',
'bold' => 'PTSerif-Bold.ttf',
'italics' => 'PTSerif-Italic.ttf',
'bolditalics' => 'PTSerif-Italic.ttf',
'sort_order' => 1200
],
[
'folder' => 'raleway',
'name' => 'Raleway',
'css_stack' => "'Raleway', Arial, Helvetica, sans-serif",
'google_font' => 'Raleway:400,700,900,100',
'normal' => 'Raleway-Regular.ttf',
'bold' => 'Raleway-Medium.ttf',
'italics' => 'Raleway-Italic.ttf',
'bolditalics' => 'Raleway-Italic.ttf',
'sort_order' => 1300
],
[
'folder' => 'raleway_light',
'name' => 'Raleway Light',
'css_stack' => "'Raleway', Arial, Helvetica, sans-serif",
'css_weight' => 300,
'google_font' => 'Raleway:300,700,900,100',
'normal' => 'Raleway-Light.ttf',
'bold' => 'Raleway-Medium.ttf',
'italics' => 'Raleway-LightItalic.ttf',
'bolditalics' => 'Raleway-LightItalic.ttf',
'sort_order' => 1400
],
[
'folder' => 'titillium',
'name' => 'Titillium',
'css_stack' => "'Titillium Web', Arial, Helvetica, sans-serif",
'google_font' => 'Titillium+Web:400,700,900,100',
'normal' => 'TitilliumWeb-Regular.ttf',
'bold' => 'TitilliumWeb-Bold.ttf',
'italics' => 'TitilliumWeb-Italic.ttf',
'bolditalics' => 'TitilliumWeb-Italic.ttf',
'sort_order' => 1500
],
[
'folder' => 'titillium_light',
'name' => 'Titillium Light',
'css_stack' => "'Titillium Web', Arial, Helvetica, sans-serif",
'css_weight' => 300,
'google_font' => 'Titillium+Web:300,700,900,100',
'normal' => 'TitilliumWeb-Light.ttf',
'bold' => 'TitilliumWeb-SemiBold.ttf',
'italics' => 'TitilliumWeb-LightItalic.ttf',
'bolditalics' => 'TitilliumWeb-LightItalic.ttf',
'sort_order' => 1600,
],
[
'folder' => 'ubuntu',
'name' => 'Ubuntu',
'css_stack' => "'Ubuntu', Arial, Helvetica, sans-serif",
'google_font' => 'Ubuntu:400,700,900,100',
'normal' => 'Ubuntu-Regular.ttf',
'bold' => 'Ubuntu-Bold.ttf',
'italics' => 'Ubuntu-Italic.ttf',
'bolditalics' => 'Ubuntu-Italic.ttf',
'sort_order' => 1700,
],
[
'folder' => 'ubuntu_light',
'name' => 'Ubuntu Light',
'css_stack' => "'Ubuntu', Arial, Helvetica, sans-serif",
'css_weight' => 300,
'google_font' => 'Ubuntu:200,700,900,100',
'normal' => 'Ubuntu-Light.ttf',
'bold' => 'Ubuntu-Medium.ttf',
'italics' => 'Ubuntu-LightItalic.ttf',
'bolditalics' => 'Ubuntu-LightItalic.ttf',
'sort_order' => 1800,
],
[
'folder' => 'ukai',
'name' => 'UKai - Chinese',
'css_stack' => '',
'google_font' => '',
'normal' => 'UKai.ttf',
'bold' => 'UKai.ttf',
'italics' => 'UKai.ttf',
'bolditalics' => 'UKai.ttf',
'sort_order' => 1800,
],
];
foreach ($fonts as $font) {
if (!DB::table('fonts')->where('name', '=', $font['name'])->get()) {
Font::create($font);
}
}
}
}

View File

@ -122,6 +122,8 @@ class PaymentLibrariesSeeder extends Seeder
['name' => 'Netherlands Antillean Guilder', 'code' => 'ANG', 'symbol' => 'ANG ', 'precision' => '2', 'thousand_separator' => '.', 'decimal_separator' => ','],
['name' => 'Trinidad and Tobago Dollar', 'code' => 'TTD', 'symbol' => 'TT$', 'precision' => '2', 'thousand_separator' => ',', 'decimal_separator' => '.'],
['name' => 'East Caribbean Dollar', 'code' => 'XCD', 'symbol' => 'EC$', 'precision' => '2', 'thousand_separator' => ',', 'decimal_separator' => '.'],
['name' => 'Ghanaian Cedi', 'code' => 'GHS', 'symbol' => 'GHS ', 'precision' => '2', 'thousand_separator' => ',', 'decimal_separator' => '.'],
['name' => 'Bulgarian Lev', 'code' => 'BGN', 'symbol' => 'BGN ', 'precision' => '2', 'thousand_separator' => ' ', 'decimal_separator' => '.'],
];
foreach ($currencies as $currency) {

View File

@ -1,13 +1,14 @@
{
"private": true,
"devDependencies": {
"gulp": "^3.8.8",
"laravel-elixir": "*",
"grunt": "~0.4.4",
"grunt-contrib-concat": "~0.4.0",
"grunt-contrib-jshint": "~0.6.3",
"grunt-contrib-nodeunit": "~0.2.0",
"grunt-contrib-uglify": "~0.2.2",
"grunt-contrib-concat": "~0.4.0"
"grunt-dump-dir": "^0.1.2",
"gulp": "^3.8.8",
"laravel-elixir": "*"
},
"dependencies": {
"grunt-dump-dir": "^0.1.2"

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,93 @@
Copyright (c) 2011, TypeTogether (www.type-together.com),
with Reserved Font Names "Abril" and "Abril Fatface"
This Font Software is licensed under the SIL Open Font License, Version 1.1.
This license is copied below, and is also available with a FAQ at:
http://scripts.sil.org/OFL
-----------------------------------------------------------
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
-----------------------------------------------------------
PREAMBLE
The goals of the Open Font License (OFL) are to stimulate worldwide
development of collaborative font projects, to support the font creation
efforts of academic and linguistic communities, and to provide a free and
open framework in which fonts may be shared and improved in partnership
with others.
The OFL allows the licensed fonts to be used, studied, modified and
redistributed freely as long as they are not sold by themselves. The
fonts, including any derivative works, can be bundled, embedded,
redistributed and/or sold with any software provided that any reserved
names are not used by derivative works. The fonts and derivatives,
however, cannot be released under any other type of license. The
requirement for fonts to remain under this license does not apply
to any document created using the fonts or their derivatives.
DEFINITIONS
"Font Software" refers to the set of files released by the Copyright
Holder(s) under this license and clearly marked as such. This may
include source files, build scripts and documentation.
"Reserved Font Name" refers to any names specified as such after the
copyright statement(s).
"Original Version" refers to the collection of Font Software components as
distributed by the Copyright Holder(s).
"Modified Version" refers to any derivative made by adding to, deleting,
or substituting -- in part or in whole -- any of the components of the
Original Version, by changing formats or by porting the Font Software to a
new environment.
"Author" refers to any designer, engineer, programmer, technical
writer or other person who contributed to the Font Software.
PERMISSION & CONDITIONS
Permission is hereby granted, free of charge, to any person obtaining
a copy of the Font Software, to use, study, copy, merge, embed, modify,
redistribute, and sell modified and unmodified copies of the Font
Software, subject to the following conditions:
1) Neither the Font Software nor any of its individual components,
in Original or Modified Versions, may be sold by itself.
2) Original or Modified Versions of the Font Software may be bundled,
redistributed and/or sold with any software, provided that each copy
contains the above copyright notice and this license. These can be
included either as stand-alone text files, human-readable headers or
in the appropriate machine-readable metadata fields within text or
binary files as long as those fields can be easily viewed by the user.
3) No Modified Version of the Font Software may use the Reserved Font
Name(s) unless explicit written permission is granted by the corresponding
Copyright Holder. This restriction only applies to the primary font name as
presented to the users.
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
Software shall not be used to promote, endorse or advertise any
Modified Version, except to acknowledge the contribution(s) of the
Copyright Holder(s) and the Author(s) or with their explicit written
permission.
5) The Font Software, modified or unmodified, in part or in whole,
must be distributed entirely under this license, and must not be
distributed under any other license. The requirement for fonts to
remain under this license does not apply to any document created
using the Font Software.
TERMINATION
This license becomes null and void if any of the above conditions are
not met.
DISCLAIMER
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
OTHER DEALINGS IN THE FONT SOFTWARE.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -0,0 +1,41 @@
This Font Software is licensed under the SIL Open Font License, Version 1.1.
This license is copied below, and is also available with a FAQ at: http://scripts.sil.org/OFL
-----------------------------------------------------------
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
-----------------------------------------------------------
PREAMBLE
The goals of the Open Font License (OFL) are to stimulate worldwide development of collaborative font projects, to support the font creation efforts of academic and linguistic communities, and to provide a free and open framework in which fonts may be shared and improved in partnership with others.
The OFL allows the licensed fonts to be used, studied, modified and redistributed freely as long as they are not sold by themselves. The fonts, including any derivative works, can be bundled, embedded, redistributed and/or sold with any software provided that any reserved names are not used by derivative works. The fonts and derivatives, however, cannot be released under any other type of license. The requirement for fonts to remain under this license does not apply to any document created using the fonts or their derivatives.
DEFINITIONS
"Font Software" refers to the set of files released by the Copyright Holder(s) under this license and clearly marked as such. This may include source files, build scripts and documentation.
"Reserved Font Name" refers to any names specified as such after the copyright statement(s).
"Original Version" refers to the collection of Font Software components as distributed by the Copyright Holder(s).
"Modified Version" refers to any derivative made by adding to, deleting, or substituting -- in part or in whole -- any of the components of the Original Version, by changing formats or by porting the Font Software to a new environment.
"Author" refers to any designer, engineer, programmer, technical writer or other person who contributed to the Font Software.
PERMISSION & CONDITIONS
Permission is hereby granted, free of charge, to any person obtaining a copy of the Font Software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the Font Software, subject to the following conditions:
1) Neither the Font Software nor any of its individual components, in Original or Modified Versions, may be sold by itself.
2) Original or Modified Versions of the Font Software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user.
3) No Modified Version of the Font Software may use the Reserved Font Name(s) unless explicit written permission is granted by the corresponding Copyright Holder. This restriction only applies to the primary font name as presented to the users.
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font Software shall not be used to promote, endorse or advertise any Modified Version, except to acknowledge the contribution(s) of the Copyright Holder(s) and the Author(s) or with their explicit written permission.
5) The Font Software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software.
TERMINATION
This license becomes null and void if any of the above conditions are not met.
DISCLAIMER
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE.

Binary file not shown.

View File

@ -0,0 +1,43 @@
Copyright (c) 2010 by Typemade (hi@typemade.mx). All rights reserved.
This Font Software is licensed under the SIL Open Font License, Version 1.1.
This license is copied below, and is also available with a FAQ at: http://scripts.sil.org/OFL
-----------------------------------------------------------
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
-----------------------------------------------------------
PREAMBLE
The goals of the Open Font License (OFL) are to stimulate worldwide development of collaborative font projects, to support the font creation efforts of academic and linguistic communities, and to provide a free and open framework in which fonts may be shared and improved in partnership with others.
The OFL allows the licensed fonts to be used, studied, modified and redistributed freely as long as they are not sold by themselves. The fonts, including any derivative works, can be bundled, embedded, redistributed and/or sold with any software provided that any reserved names are not used by derivative works. The fonts and derivatives, however, cannot be released under any other type of license. The requirement for fonts to remain under this license does not apply to any document created using the fonts or their derivatives.
DEFINITIONS
"Font Software" refers to the set of files released by the Copyright Holder(s) under this license and clearly marked as such. This may include source files, build scripts and documentation.
"Reserved Font Name" refers to any names specified as such after the copyright statement(s).
"Original Version" refers to the collection of Font Software components as distributed by the Copyright Holder(s).
"Modified Version" refers to any derivative made by adding to, deleting, or substituting -- in part or in whole -- any of the components of the Original Version, by changing formats or by porting the Font Software to a new environment.
"Author" refers to any designer, engineer, programmer, technical writer or other person who contributed to the Font Software.
PERMISSION & CONDITIONS
Permission is hereby granted, free of charge, to any person obtaining a copy of the Font Software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the Font Software, subject to the following conditions:
1) Neither the Font Software nor any of its individual components, in Original or Modified Versions, may be sold by itself.
2) Original or Modified Versions of the Font Software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user.
3) No Modified Version of the Font Software may use the Reserved Font Name(s) unless explicit written permission is granted by the corresponding Copyright Holder. This restriction only applies to the primary font name as presented to the users.
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font Software shall not be used to promote, endorse or advertise any Modified Version, except to acknowledge the contribution(s) of the Copyright Holder(s) and the Author(s) or with their explicit written permission.
5) The Font Software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software.
TERMINATION
This license becomes null and void if any of the above conditions are not met.
DISCLAIMER
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE.

View File

@ -0,0 +1,43 @@
Copyright (c) 2010 by Typemade (hi@typemade.mx). All rights reserved.
This Font Software is licensed under the SIL Open Font License, Version 1.1.
This license is copied below, and is also available with a FAQ at: http://scripts.sil.org/OFL
-----------------------------------------------------------
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
-----------------------------------------------------------
PREAMBLE
The goals of the Open Font License (OFL) are to stimulate worldwide development of collaborative font projects, to support the font creation efforts of academic and linguistic communities, and to provide a free and open framework in which fonts may be shared and improved in partnership with others.
The OFL allows the licensed fonts to be used, studied, modified and redistributed freely as long as they are not sold by themselves. The fonts, including any derivative works, can be bundled, embedded, redistributed and/or sold with any software provided that any reserved names are not used by derivative works. The fonts and derivatives, however, cannot be released under any other type of license. The requirement for fonts to remain under this license does not apply to any document created using the fonts or their derivatives.
DEFINITIONS
"Font Software" refers to the set of files released by the Copyright Holder(s) under this license and clearly marked as such. This may include source files, build scripts and documentation.
"Reserved Font Name" refers to any names specified as such after the copyright statement(s).
"Original Version" refers to the collection of Font Software components as distributed by the Copyright Holder(s).
"Modified Version" refers to any derivative made by adding to, deleting, or substituting -- in part or in whole -- any of the components of the Original Version, by changing formats or by porting the Font Software to a new environment.
"Author" refers to any designer, engineer, programmer, technical writer or other person who contributed to the Font Software.
PERMISSION & CONDITIONS
Permission is hereby granted, free of charge, to any person obtaining a copy of the Font Software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the Font Software, subject to the following conditions:
1) Neither the Font Software nor any of its individual components, in Original or Modified Versions, may be sold by itself.
2) Original or Modified Versions of the Font Software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user.
3) No Modified Version of the Font Software may use the Reserved Font Name(s) unless explicit written permission is granted by the corresponding Copyright Holder. This restriction only applies to the primary font name as presented to the users.
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font Software shall not be used to promote, endorse or advertise any Modified Version, except to acknowledge the contribution(s) of the Copyright Holder(s) and the Author(s) or with their explicit written permission.
5) The Font Software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software.
TERMINATION
This license becomes null and void if any of the above conditions are not met.
DISCLAIMER
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE.

Binary file not shown.

View File

@ -0,0 +1,43 @@
Copyright (c) 2010 by Typemade (hi@typemade.mx). All rights reserved.
This Font Software is licensed under the SIL Open Font License, Version 1.1.
This license is copied below, and is also available with a FAQ at: http://scripts.sil.org/OFL
-----------------------------------------------------------
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
-----------------------------------------------------------
PREAMBLE
The goals of the Open Font License (OFL) are to stimulate worldwide development of collaborative font projects, to support the font creation efforts of academic and linguistic communities, and to provide a free and open framework in which fonts may be shared and improved in partnership with others.
The OFL allows the licensed fonts to be used, studied, modified and redistributed freely as long as they are not sold by themselves. The fonts, including any derivative works, can be bundled, embedded, redistributed and/or sold with any software provided that any reserved names are not used by derivative works. The fonts and derivatives, however, cannot be released under any other type of license. The requirement for fonts to remain under this license does not apply to any document created using the fonts or their derivatives.
DEFINITIONS
"Font Software" refers to the set of files released by the Copyright Holder(s) under this license and clearly marked as such. This may include source files, build scripts and documentation.
"Reserved Font Name" refers to any names specified as such after the copyright statement(s).
"Original Version" refers to the collection of Font Software components as distributed by the Copyright Holder(s).
"Modified Version" refers to any derivative made by adding to, deleting, or substituting -- in part or in whole -- any of the components of the Original Version, by changing formats or by porting the Font Software to a new environment.
"Author" refers to any designer, engineer, programmer, technical writer or other person who contributed to the Font Software.
PERMISSION & CONDITIONS
Permission is hereby granted, free of charge, to any person obtaining a copy of the Font Software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the Font Software, subject to the following conditions:
1) Neither the Font Software nor any of its individual components, in Original or Modified Versions, may be sold by itself.
2) Original or Modified Versions of the Font Software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user.
3) No Modified Version of the Font Software may use the Reserved Font Name(s) unless explicit written permission is granted by the corresponding Copyright Holder. This restriction only applies to the primary font name as presented to the users.
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font Software shall not be used to promote, endorse or advertise any Modified Version, except to acknowledge the contribution(s) of the Copyright Holder(s) and the Author(s) or with their explicit written permission.
5) The Font Software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software.
TERMINATION
This license becomes null and void if any of the above conditions are not met.
DISCLAIMER
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE.

View File

@ -0,0 +1,43 @@
Copyright (c) 2010 by Typemade (hi@typemade.mx). All rights reserved.
This Font Software is licensed under the SIL Open Font License, Version 1.1.
This license is copied below, and is also available with a FAQ at: http://scripts.sil.org/OFL
-----------------------------------------------------------
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
-----------------------------------------------------------
PREAMBLE
The goals of the Open Font License (OFL) are to stimulate worldwide development of collaborative font projects, to support the font creation efforts of academic and linguistic communities, and to provide a free and open framework in which fonts may be shared and improved in partnership with others.
The OFL allows the licensed fonts to be used, studied, modified and redistributed freely as long as they are not sold by themselves. The fonts, including any derivative works, can be bundled, embedded, redistributed and/or sold with any software provided that any reserved names are not used by derivative works. The fonts and derivatives, however, cannot be released under any other type of license. The requirement for fonts to remain under this license does not apply to any document created using the fonts or their derivatives.
DEFINITIONS
"Font Software" refers to the set of files released by the Copyright Holder(s) under this license and clearly marked as such. This may include source files, build scripts and documentation.
"Reserved Font Name" refers to any names specified as such after the copyright statement(s).
"Original Version" refers to the collection of Font Software components as distributed by the Copyright Holder(s).
"Modified Version" refers to any derivative made by adding to, deleting, or substituting -- in part or in whole -- any of the components of the Original Version, by changing formats or by porting the Font Software to a new environment.
"Author" refers to any designer, engineer, programmer, technical writer or other person who contributed to the Font Software.
PERMISSION & CONDITIONS
Permission is hereby granted, free of charge, to any person obtaining a copy of the Font Software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the Font Software, subject to the following conditions:
1) Neither the Font Software nor any of its individual components, in Original or Modified Versions, may be sold by itself.
2) Original or Modified Versions of the Font Software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user.
3) No Modified Version of the Font Software may use the Reserved Font Name(s) unless explicit written permission is granted by the corresponding Copyright Holder. This restriction only applies to the primary font name as presented to the users.
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font Software shall not be used to promote, endorse or advertise any Modified Version, except to acknowledge the contribution(s) of the Copyright Holder(s) and the Author(s) or with their explicit written permission.
5) The Font Software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software.
TERMINATION
This license becomes null and void if any of the above conditions are not met.
DISCLAIMER
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE.

View File

@ -0,0 +1,201 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -0,0 +1,201 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -0,0 +1,26 @@
Copyright © 2009 ParaType Ltd.
with Reserved Names &amp;quot;PT Sans&amp;quot; and &amp;quot;ParaType&amp;quot;.
FONT LICENSE
PERMISSION &amp;amp; CONDITIONS
Permission is hereby granted, free of charge, to any person obtaining a copy of the font software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the font software, subject to the following conditions:
1) Neither the font software nor any of its individual components, in original or modified versions, may be sold by itself.
2) Original or modified versions of the font software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user.
3) No modified version of the font software may use the Reserved Name(s) or combinations of Reserved Names with other words unless explicit written permission is granted by the ParaType. This restriction only applies to the primary font name as presented to the users.
4) The name of ParaType or the author(s) of the font software shall not be used to promote, endorse or advertise any modified version, except to acknowledge the contribution(s) of ParaType and the author(s) or with explicit written permission of ParaType.
5) The font software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software.
TERMINATION &amp;amp; TERRITORY
This license has no limits on time and territory, but it becomes null and void if any of the above conditions are not met.
DISCLAIMER
THE FONT SOFTWARE IS PROVIDED &amp;quot;AS IS&amp;quot;, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL PARATYPE BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE.
ParaType Ltd
http://www.paratype.ru

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -0,0 +1,26 @@
Copyright © 2009 ParaType Ltd.
with Reserved Names &amp;quot;PT Sans&amp;quot; and &amp;quot;ParaType&amp;quot;.
FONT LICENSE
PERMISSION &amp;amp; CONDITIONS
Permission is hereby granted, free of charge, to any person obtaining a copy of the font software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the font software, subject to the following conditions:
1) Neither the font software nor any of its individual components, in original or modified versions, may be sold by itself.
2) Original or modified versions of the font software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user.
3) No modified version of the font software may use the Reserved Name(s) or combinations of Reserved Names with other words unless explicit written permission is granted by the ParaType. This restriction only applies to the primary font name as presented to the users.
4) The name of ParaType or the author(s) of the font software shall not be used to promote, endorse or advertise any modified version, except to acknowledge the contribution(s) of ParaType and the author(s) or with explicit written permission of ParaType.
5) The font software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software.
TERMINATION &amp;amp; TERRITORY
This license has no limits on time and territory, but it becomes null and void if any of the above conditions are not met.
DISCLAIMER
THE FONT SOFTWARE IS PROVIDED &amp;quot;AS IS&amp;quot;, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL PARATYPE BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE.
ParaType Ltd
http://www.paratype.ru

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -0,0 +1,43 @@
Copyright (c) 2010 - 2012, Matt McInerney (matt@pixelspread.com), Pablo Impallari(impallari@gmail.com), Rodrigo Fuenzalida (hello@rfuenzalida.com) with Reserved Font Name "Raleway"
This Font Software is licensed under the SIL Open Font License, Version 1.1.
This license is copied below, and is also available with a FAQ at: http://scripts.sil.org/OFL
-----------------------------------------------------------
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
-----------------------------------------------------------
PREAMBLE
The goals of the Open Font License (OFL) are to stimulate worldwide development of collaborative font projects, to support the font creation efforts of academic and linguistic communities, and to provide a free and open framework in which fonts may be shared and improved in partnership with others.
The OFL allows the licensed fonts to be used, studied, modified and redistributed freely as long as they are not sold by themselves. The fonts, including any derivative works, can be bundled, embedded, redistributed and/or sold with any software provided that any reserved names are not used by derivative works. The fonts and derivatives, however, cannot be released under any other type of license. The requirement for fonts to remain under this license does not apply to any document created using the fonts or their derivatives.
DEFINITIONS
"Font Software" refers to the set of files released by the Copyright Holder(s) under this license and clearly marked as such. This may include source files, build scripts and documentation.
"Reserved Font Name" refers to any names specified as such after the copyright statement(s).
"Original Version" refers to the collection of Font Software components as distributed by the Copyright Holder(s).
"Modified Version" refers to any derivative made by adding to, deleting, or substituting -- in part or in whole -- any of the components of the Original Version, by changing formats or by porting the Font Software to a new environment.
"Author" refers to any designer, engineer, programmer, technical writer or other person who contributed to the Font Software.
PERMISSION & CONDITIONS
Permission is hereby granted, free of charge, to any person obtaining a copy of the Font Software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the Font Software, subject to the following conditions:
1) Neither the Font Software nor any of its individual components, in Original or Modified Versions, may be sold by itself.
2) Original or Modified Versions of the Font Software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user.
3) No Modified Version of the Font Software may use the Reserved Font Name(s) unless explicit written permission is granted by the corresponding Copyright Holder. This restriction only applies to the primary font name as presented to the users.
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font Software shall not be used to promote, endorse or advertise any Modified Version, except to acknowledge the contribution(s) of the Copyright Holder(s) and the Author(s) or with their explicit written permission.
5) The Font Software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software.
TERMINATION
This license becomes null and void if any of the above conditions are not met.
DISCLAIMER
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE.

Binary file not shown.

Binary file not shown.

View File

@ -0,0 +1,43 @@
Copyright (c) 2010 - 2012, Matt McInerney (matt@pixelspread.com), Pablo Impallari(impallari@gmail.com), Rodrigo Fuenzalida (hello@rfuenzalida.com) with Reserved Font Name "Raleway"
This Font Software is licensed under the SIL Open Font License, Version 1.1.
This license is copied below, and is also available with a FAQ at: http://scripts.sil.org/OFL
-----------------------------------------------------------
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
-----------------------------------------------------------
PREAMBLE
The goals of the Open Font License (OFL) are to stimulate worldwide development of collaborative font projects, to support the font creation efforts of academic and linguistic communities, and to provide a free and open framework in which fonts may be shared and improved in partnership with others.
The OFL allows the licensed fonts to be used, studied, modified and redistributed freely as long as they are not sold by themselves. The fonts, including any derivative works, can be bundled, embedded, redistributed and/or sold with any software provided that any reserved names are not used by derivative works. The fonts and derivatives, however, cannot be released under any other type of license. The requirement for fonts to remain under this license does not apply to any document created using the fonts or their derivatives.
DEFINITIONS
"Font Software" refers to the set of files released by the Copyright Holder(s) under this license and clearly marked as such. This may include source files, build scripts and documentation.
"Reserved Font Name" refers to any names specified as such after the copyright statement(s).
"Original Version" refers to the collection of Font Software components as distributed by the Copyright Holder(s).
"Modified Version" refers to any derivative made by adding to, deleting, or substituting -- in part or in whole -- any of the components of the Original Version, by changing formats or by porting the Font Software to a new environment.
"Author" refers to any designer, engineer, programmer, technical writer or other person who contributed to the Font Software.
PERMISSION & CONDITIONS
Permission is hereby granted, free of charge, to any person obtaining a copy of the Font Software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the Font Software, subject to the following conditions:
1) Neither the Font Software nor any of its individual components, in Original or Modified Versions, may be sold by itself.
2) Original or Modified Versions of the Font Software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user.
3) No Modified Version of the Font Software may use the Reserved Font Name(s) unless explicit written permission is granted by the corresponding Copyright Holder. This restriction only applies to the primary font name as presented to the users.
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font Software shall not be used to promote, endorse or advertise any Modified Version, except to acknowledge the contribution(s) of the Copyright Holder(s) and the Author(s) or with their explicit written permission.
5) The Font Software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software.
TERMINATION
This license becomes null and void if any of the above conditions are not met.
DISCLAIMER
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE.

View File

@ -0,0 +1,202 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Some files were not shown because too many files have changed in this diff Show More