merge upstream/v5-develop

This commit is contained in:
Benjamin Beganović 2021-03-13 14:55:13 +01:00
commit 0b9c6e782d
38 changed files with 95689 additions and 94746 deletions

View File

@ -25,7 +25,7 @@ DEMO_MODE=false
BROADCAST_DRIVER=log
LOG_CHANNEL=stack
CACHE_DRIVER=file
QUEUE_CONNECTION=database
QUEUE_CONNECTION=sync
SESSION_DRIVER=file
SESSION_LIFETIME=120
@ -51,7 +51,7 @@ TRUSTED_PROXIES=
NINJA_ENVIRONMENT=selfhost
PHANTOMJS_PDF_GENERATION=false
PHANTOMJS_PDF_GENERATION=true
PHANTOMJS_KEY='a-demo-key-with-low-quota-per-ip-address'
PHANTOMJS_SECRET=secret

View File

@ -1 +1 @@
5.1.18
5.1.24

View File

@ -157,21 +157,21 @@ class InvoiceSum
{
$this->total += $this->total_taxes;
if (is_numeric($this->invoice->custom_value1)) {
$this->total += $this->invoice->custom_value1;
}
// if (is_numeric($this->invoice->custom_value1)) {
// $this->total += $this->invoice->custom_value1;
// }
if (is_numeric($this->invoice->custom_value2)) {
$this->total += $this->invoice->custom_value2;
}
// if (is_numeric($this->invoice->custom_value2)) {
// $this->total += $this->invoice->custom_value2;
// }
if (is_numeric($this->invoice->custom_value3)) {
$this->total += $this->invoice->custom_value3;
}
// if (is_numeric($this->invoice->custom_value3)) {
// $this->total += $this->invoice->custom_value3;
// }
if (is_numeric($this->invoice->custom_value4)) {
$this->total += $this->invoice->custom_value4;
}
// if (is_numeric($this->invoice->custom_value4)) {
// $this->total += $this->invoice->custom_value4;
// }
return $this;
}

View File

@ -166,21 +166,21 @@ class InvoiceSumInclusive
{
//$this->total += $this->total_taxes;
if (is_numeric($this->invoice->custom_value1)) {
$this->total += $this->invoice->custom_value1;
}
// if (is_numeric($this->invoice->custom_value1)) {
// $this->total += $this->invoice->custom_value1;
// }
if (is_numeric($this->invoice->custom_value2)) {
$this->total += $this->invoice->custom_value2;
}
// if (is_numeric($this->invoice->custom_value2)) {
// $this->total += $this->invoice->custom_value2;
// }
if (is_numeric($this->invoice->custom_value3)) {
$this->total += $this->invoice->custom_value3;
}
// if (is_numeric($this->invoice->custom_value3)) {
// $this->total += $this->invoice->custom_value3;
// }
if (is_numeric($this->invoice->custom_value4)) {
$this->total += $this->invoice->custom_value4;
}
// if (is_numeric($this->invoice->custom_value4)) {
// $this->total += $this->invoice->custom_value4;
// }
return $this;
}

View File

@ -134,10 +134,9 @@ class ConnectedAccountController extends BaseController
auth()->user()->save();
//$ct = CompanyUser::whereUserId(auth()->user()->id);
$ct = CompanyUser::whereUserId(auth()->user()->id);
return $this->listResponse($ct);
// return $this->listResponse(auth()->user());
//return $this->listResponse($ct);
return $this->listResponse(auth()->user());
}
return response()

View File

@ -376,6 +376,8 @@ class CreditController extends BaseController
$credit = $this->credit_repository->save($request->all(), $credit);
$credit->service()->deletePdf();
event(new CreditWasUpdated($credit, $credit->company, Ninja::eventVars()));
return $this->itemResponse($credit);

View File

@ -213,13 +213,13 @@ class InvoiceController extends BaseController
$invoice = $this->invoice_repo->save($request->all(), InvoiceFactory::create(auth()->user()->company()->id, auth()->user()->id));
event(new InvoiceWasCreated($invoice, $invoice->company, Ninja::eventVars()));
$invoice = $invoice->service()
->fillDefaults()
->triggeredActions($request)
->save();
event(new InvoiceWasCreated($invoice, $invoice->company, Ninja::eventVars()));
return $this->itemResponse($invoice);
}

View File

@ -387,6 +387,8 @@ class QuoteController extends BaseController
$quote = $this->quote_repo->save($request->all(), $quote);
$quote->service()->deletePdf();
event(new QuoteWasUpdated($quote, $quote->company, Ninja::eventVars()));
return $this->itemResponse($quote);

View File

@ -374,6 +374,8 @@ class RecurringInvoiceController extends BaseController
$recurring_invoice = $this->recurring_invoice_repo->save($request->all(), $recurring_invoice);
$recurring_invoice->service()->deletePdf()->save();
return $this->itemResponse($recurring_invoice);
}

View File

@ -125,6 +125,15 @@ class SetupController extends Controller
'DB_CONNECTION' => 'db-ninja-01',
];
if(config('ninja.preconfigured_install')){
// Database connection was already configured. Don't let the user override it.
unset($env_values['DB_HOST1']);
unset($env_values['DB_PORT1']);
unset($env_values['DB_DATABASE1']);
unset($env_values['DB_USERNAME1']);
unset($env_values['DB_PASSWORD1']);
}
try {
foreach ($env_values as $property => $value) {
@ -136,12 +145,12 @@ class SetupController extends Controller
/* Make sure no stale connections are cached */
DB::purge('db-ninja-01');
/* Run migrations */
Artisan::call('optimize');
Artisan::call('migrate', ['--force' => true]);
Artisan::call('db:seed', ['--force' => true]);
Storage::disk('local')->delete('test.pdf');
/* Create the first account. */
@ -157,6 +166,7 @@ class SetupController extends Controller
} catch (Exception $e) {
nlog($e->getMessage());
info($e->getMessage());
return redirect()
->back()

View File

@ -83,10 +83,10 @@ class InvoiceController extends BaseController
$invoice = $this->invoice_repo->save($request->all(), InvoiceFactory::create($company->id, $company->owner()->id));
event(new InvoiceWasCreated($invoice, $company, Ninja::eventVars()));
$invoice = $invoice->service()->triggeredActions($request)->save();
event(new InvoiceWasCreated($invoice, $company, Ninja::eventVars()));
return $this->itemResponse($invoice);
}
}

View File

@ -33,11 +33,15 @@ class CheckDatabaseRequest extends Request
*/
public function rules()
{
return [
'db_host' => ['required'],
'db_port' => ['required'],
'db_database' => ['required'],
'db_username' => ['required'],
];
}
if ( config( 'ninja.preconfigured_install' ) ) {
return [];
}
return [
'db_host' => [ 'required' ],
'db_port' => [ 'required' ],
'db_database' => [ 'required' ],
'db_username' => [ 'required' ],
];
}
}

View File

@ -27,31 +27,38 @@ class StoreSetupRequest extends Request
public function rules()
{
return [
/*System*/
'url' => 'required',
/*Database*/
'db_host' => 'required',
'db_database' => 'required',
'db_username' => 'required',
'db_password' => '',
/*Mail driver*/
'mail_driver' => 'required',
'encryption' => 'required_unless:mail_driver,log',
'mail_host' => 'required_unless:mail_driver,log',
'mail_username' => 'required_unless:mail_driver,log',
'mail_name' => 'required_unless:mail_driver,log',
'mail_address' => 'required_unless:mail_driver,log',
'mail_password' => 'required_unless:mail_driver,log',
/*user registration*/
'privacy_policy' => 'required',
'terms_of_service' => 'required',
'first_name' => 'required',
'last_name' => 'required',
'email' => 'required|email:rfc,dns',
'password' => 'required',
];
}
$rules = [
/*System*/
'url' => 'required',
/*Mail driver*/
'mail_driver' => 'required',
'encryption' => 'required_unless:mail_driver,log',
'mail_host' => 'required_unless:mail_driver,log',
'mail_username' => 'required_unless:mail_driver,log',
'mail_name' => 'required_unless:mail_driver,log',
'mail_address' => 'required_unless:mail_driver,log',
'mail_password' => 'required_unless:mail_driver,log',
/*user registration*/
'privacy_policy' => 'required',
'terms_of_service' => 'required',
'first_name' => 'required',
'last_name' => 'required',
'email' => 'required|email:rfc,dns',
'password' => 'required',
];
if ( ! config( 'ninja.preconfigured_install' ) ) {
$rules = array_merge( $rules, [
/*Database*/
'db_host' => 'required',
'db_database' => 'required',
'db_username' => 'required',
'db_password' => '',
] );
}
return $rules;
}
protected function prepareForValidation()
{

View File

@ -60,7 +60,10 @@ class CreateAccount
private function create()
{
$sp794f3f = Account::create($this->request);
Account::reguard();
$sp794f3f = new Account();
$sp794f3f->fill($this->request);
$sp794f3f->referral_code = Str::random(32);
if (! $sp794f3f->key) {
@ -96,22 +99,6 @@ class CreateAccount
//todo implement SLACK notifications
//$sp035a66->notification(new NewAccountCreated($spaa9f78, $sp035a66))->ninja();
// $nmo = new NinjaMailerObject;
// $nmo->mailable = new NinjaMailer((new AccountCreatedObject($spaa9f78, $sp035a66))->build());
// $nmo->company = $sp035a66;
// $nmo->to_user = $spaa9f78;
// $nmo->settings = $sp035a66->settings;
// $nmo = new NinjaMailerObject;
// $nmo->mailable = new NinjaMailer((new VerifyUserObject($spaa9f78, $sp035a66))->build());
// $nmo->company = $sp035a66;
// $nmo->to_user = $spaa9f78;
// $nmo->settings = $sp035a66->settings;
// NinjaMailerJob::dispatch($nmo);
// NinjaMailerJob::dispatchNow($nmo);
VersionCheck::dispatchNow();
LightLogs::create(new AnalyticsAccountCreated())

View File

@ -58,6 +58,7 @@ class CreateCompany
$company->db = config('database.default');
$company->enabled_modules = config('ninja.enabled_modules');
$company->subdomain = isset($this->request['subdomain']) ? $this->request['subdomain'] : '';
$company->custom_fields = new \stdClass;
$company->save();
return $company;

View File

@ -88,6 +88,8 @@ class CreditService
{
$this->credit = (new ApplyPayment($this->credit, $invoice, $amount, $payment))->run();
$this->deletePdf();
return $this;
}

View File

@ -44,6 +44,7 @@ class MarkSent
->setStatus(Credit::STATUS_SENT)
->applyNumber()
->adjustBalance($this->credit->amount)
->deletePdf()
->save();

View File

@ -137,6 +137,10 @@ class Design extends BaseDesign
$elements[] = ['element' => 'p', 'content' => $variable, 'show_empty' => false, 'properties' => ['data-ref' => 'company_details-' . substr($variable, 1)]];
}
foreach (['company1', 'company2', 'company3', 'company4'] as $field) {
$elements[] = ['element' => 'p', 'content' => $this->getCustomFieldValue($field), 'show_empty' => false, 'properties' => ['data-ref' => 'company_details-' . $field]];
}
return $elements;
}

View File

@ -12,9 +12,7 @@
namespace App\Services\PdfMaker\Designs\Utilities;
use App\Models\Task;
use App\Utils\Traits\MakesHash;
use Carbon\Carbon;
use DOMDocument;
use DOMXPath;
use Exception;
@ -273,4 +271,35 @@ trait DesignHelpers
array_splice($this->context['pdf_variables']["{$type}_columns"], $key + 1, 0, $custom_columns);
}
}
public function getCustomFieldValue(string $field): string
{
// In custom_fields column we store fields like: company1-4,
// while in settings, they're stored in custom_value1-4 format.
// That's why we need this mapping.
$fields = [
'company1' => 'custom_value1',
'company2' => 'custom_value2',
'company3' => 'custom_value3',
'company4' => 'custom_value4',
];
if (!array_key_exists($field, $fields)) {
return '';
}
if ($this->client->company->custom_fields && !property_exists($this->client->company->custom_fields, $field)) {
return '';
}
$value = $this->client->company->getSetting($fields[$field]);
return (new \App\Utils\Helpers)->formatCustomFieldValue(
$this->client->company->custom_fields,
$field,
$value,
$this->client
);
}
}

View File

@ -43,6 +43,7 @@ class MarkSent
->service()
->setStatus(Quote::STATUS_SENT)
->applyNumber()
->deletePdf()
->save();
return $this->quote;

View File

@ -39,21 +39,6 @@ class QuoteService
return $this;
}
// public function markApproved()
// {
// $mark_approved = new MarkApproved($this->quote->client);
// $this->quote = $mark_approved->run($this->quote);
// if ($this->quote->client->getSetting('auto_convert_quote') == true) {
// $this->convert();
// }
// $this->markSent()
// ->createInvitations();
// return $this;
// }
public function convert() :self
{
if ($this->quote->invoice_id) {
@ -127,6 +112,7 @@ class QuoteService
->service()
->markSent()
->createInvitations()
->deletePdf()
->save();
}

View File

@ -150,7 +150,7 @@ class SystemHealth
{
$result = ['success' => false];
if ($request) {
if ($request && !config('ninja.preconfigured_install')) {
config(['database.connections.db-ninja-01.host' => $request->input('db_host')]);
config(['database.connections.db-ninja-01.port' => $request->input('db_port')]);
config(['database.connections.db-ninja-01.database' => $request->input('db_database')]);

View File

@ -99,10 +99,13 @@ trait MakesDates
public function translateDate($date, $format, $locale)
{
Carbon::setLocale($locale);
return Carbon::parse($date)->translatedFormat($format);
try {
return Carbon::parse($date)->translatedFormat($format);
} catch(\Exception $e) {
return 'Invalid date!';
}
}
}
}

View File

@ -33,7 +33,7 @@ trait Uploadable
if ($file) {
$path = UploadAvatar::dispatchNow($file, $company->company_key);
$path = str_replace(config("ninja.app_url"), "", $path);
//$path = str_replace(config("ninja.app_url"), "", $path);
info("the path {$path}");

View File

@ -66,7 +66,7 @@
"sentry/sentry-laravel": "^2",
"stripe/stripe-php": "^7.50",
"symfony/http-client": "^5.2",
"turbo124/beacon": "^1",
"turbo124/beacon": "^1.0",
"webpatser/laravel-countries": "dev-master#75992ad",
"wildbit/swiftmailer-postmark": "^3.3"
},

14
composer.lock generated
View File

@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically"
],
"content-hash": "f051c9703768368f9a74e9b2c57f2b80",
"content-hash": "750f06b1412d6b779f433886a4770d21",
"packages": [
{
"name": "authorizenet/authorizenet",
@ -9502,16 +9502,16 @@
},
{
"name": "turbo124/beacon",
"version": "1.0.4",
"version": "1.0.6",
"source": {
"type": "git",
"url": "https://github.com/turbo124/beacon.git",
"reference": "ae328ad12364186dd07d893d35f6991880b97f18"
"reference": "2f38612c1bb4c292d154c8fba478bdf8c019fcd9"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/turbo124/beacon/zipball/ae328ad12364186dd07d893d35f6991880b97f18",
"reference": "ae328ad12364186dd07d893d35f6991880b97f18",
"url": "https://api.github.com/repos/turbo124/beacon/zipball/2f38612c1bb4c292d154c8fba478bdf8c019fcd9",
"reference": "2f38612c1bb4c292d154c8fba478bdf8c019fcd9",
"shasum": ""
},
"require": {
@ -9559,9 +9559,9 @@
"turbo124"
],
"support": {
"source": "https://github.com/turbo124/beacon/tree/1.0.4"
"source": "https://github.com/turbo124/beacon/tree/1.0.6"
},
"time": "2020-12-15T20:56:25+00:00"
"time": "2021-03-09T09:25:50+00:00"
},
{
"name": "vlucas/phpdotenv",

View File

@ -13,7 +13,7 @@ return [
'require_https' => env('REQUIRE_HTTPS', true),
'app_url' => rtrim(env('APP_URL', ''), '/'),
'app_domain' => env('APP_DOMAIN', ''),
'app_version' => '5.1.18',
'app_version' => '5.1.24',
'minimum_client_version' => '5.0.16',
'terms_version' => '1.0.1',
'api_secret' => env('API_SECRET', false),
@ -36,6 +36,7 @@ return [
'is_docker' => env('IS_DOCKER', false),
'sentry_dsn' => env('SENTRY_LARAVEL_DSN', 'https://9b4e15e575214354a7d666489783904a@sentry.invoicing.co/6'),
'environment' => env('NINJA_ENVIRONMENT', 'selfhost'), // 'hosted', 'development', 'selfhost', 'reseller'
'preconfigured_install' => env('PRECONFIGURED_INSTALL',false),
// Settings used by invoiceninja.com

920
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -14281,6 +14281,66 @@ platform_detect
See the License for the specific language governing permissions and
limitations under the License.
--------------------------------------------------------------------------------
qr
Copyright 2014, the Dart QR project authors. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above
copyright notice, this list of conditions and the following
disclaimer in the documentation and/or other materials provided
with the distribution.
* Neither the name of Google Inc. nor the names of its
contributors may be used to endorse or promote products derived
from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
--------------------------------------------------------------------------------
qr_flutter
QR.Flutter
Copyright (c) 2019 the QR.Flutter authors.
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
* Neither the name of the flutter QR authors, nor the
names of its contributors may be used to endorse or promote products
derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER BE LIABLE FOR ANY
DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
--------------------------------------------------------------------------------
rapidjson

View File

@ -7,7 +7,7 @@ const RESOURCES = {
"manifest.json": "77215c1737c7639764e64a192be2f7b8",
"icons/Icon-192.png": "bb1cf5f6982006952211c7c8404ffbed",
"icons/Icon-512.png": "0f9aff01367f0a0c69773d25ca16ef35",
"assets/NOTICES": "a5e9ede1dfb62a7ca46881980b5a0798",
"assets/NOTICES": "e80e999afd09f0f14597c78d582d9c7c",
"assets/assets/images/logo.png": "090f69e23311a4b6d851b3880ae52541",
"assets/assets/images/payment_types/discover.png": "6c0a386a00307f87db7bea366cca35f5",
"assets/assets/images/payment_types/carteblanche.png": "d936e11fa3884b8c9f1bd5c914be8629",
@ -30,7 +30,7 @@ const RESOURCES = {
"assets/packages/material_design_icons_flutter/lib/fonts/materialdesignicons-webfont.ttf": "3e722fd57a6db80ee119f0e2c230ccff",
"assets/FontManifest.json": "cf3c681641169319e61b61bd0277378f",
"/": "23224b5e03519aaa87594403d54412cf",
"main.dart.js": "e8bf48c946bec2ef549453166318a7be",
"main.dart.js": "c11c4d2efa9e671a88eb792d18c2296e",
"version.json": "b7c8971e1ab5b627fd2a4317c52b843e",
"favicon.png": "dca91c54388f52eded692718d5a98b8b"
};

File diff suppressed because one or more lines are too long

189134
public/main.dart.js vendored

File diff suppressed because one or more lines are too long

View File

@ -16,6 +16,6 @@
"/js/clients/quotes/approve.js": "/js/clients/quotes/approve.js?id=85bcae0a646882e56b12",
"/js/clients/shared/multiple-downloads.js": "/js/clients/shared/multiple-downloads.js?id=5c35d28cf0a3286e7c45",
"/js/clients/shared/pdf.js": "/js/clients/shared/pdf.js?id=fc3055d6a099f523ea98",
"/js/setup/setup.js": "/js/setup/setup.js?id=8c46629d6d43a29fce69",
"/js/setup/setup.js": "/js/setup/setup.js?id=8d454e7090f119552a6c",
"/css/card-js.min.css": "/css/card-js.min.css?id=62afeb675235451543ad"
}

View File

@ -23,18 +23,21 @@ class Setup {
}
handleDatabaseCheck() {
let url = document.querySelector('meta[name=setup-db-check]').content;
let url = document.querySelector('meta[name=setup-db-check]').content,
data = {};
let data = {
db_host: document.querySelector('input[name="db_host"]').value,
db_port: document.querySelector('input[name="db_port"]').value,
db_database: document.querySelector('input[name="db_database"]')
.value,
db_username: document.querySelector('input[name="db_username"]')
.value,
db_password: document.querySelector('input[name="db_password"]')
.value,
};
if (document.querySelector('input[name="db_host"]')) {
data = {
db_host: document.querySelector('input[name="db_host"]').value,
db_port: document.querySelector('input[name="db_port"]').value,
db_database: document.querySelector('input[name="db_database"]')
.value,
db_username: document.querySelector('input[name="db_username"]')
.value,
db_password: document.querySelector('input[name="db_password"]')
.value,
};
}
this.checkDbButton.disabled = true;
@ -93,8 +96,8 @@ class Setup {
Axios.post(url, {})
.then((response) => {
try {
let win = window.open(response.data.url, '_blank');
win.focus();
//let win = window.open(response.data.url, '_blank');
//win.focus();
return this.handleSuccess(
this.checkPdfAlert,
@ -102,7 +105,7 @@ class Setup {
);
} catch (error) {
this.handleSuccess(this.checkPdfAlert, 'database-wrapper');
this.checkPdfAlert.textContent = `Success! You can preview test PDF here: ${response.data.url}`;
this.checkPdfAlert.textContent = `Success! PDF was generated succesfully.`;
}
})
.catch((error) => {

View File

@ -154,8 +154,7 @@
<div id="body">
<div class="header-wrapper">
<p>$company.name</p>
<div id="company-details"></div>
<div id="company-address"></div>
<div>

View File

@ -8,6 +8,7 @@
</div>
<div>
<dl>
@if (! config('ninja.preconfigured_install'))
<div class="bg-gray-50 px-4 py-5 sm:grid sm:grid-cols-3 sm:gap-4 sm:px-6 sm:flex sm:items-center">
<dt class="text-sm leading-5 font-medium text-gray-500">
You can use following commands to create user & database.
@ -73,6 +74,7 @@ FLUSH PRIVILEGES;
<input type="password" class="input w-full" name="db_password" value="{{ old('db_password') ?: 'ninja' }}">
</dd>
</div>
@endif
<div class="bg-white px-4 py-5 sm:grid sm:grid-cols-3 sm:gap-4 sm:px-6 sm:flex sm:items-center">
<dt class="text-sm leading-5 font-medium text-gray-500">
<button type="button" class="button button-primary bg-blue-600 py-2 px-3 text-xs" id="test-db-connection">

View File

@ -45,7 +45,7 @@ class BillingSubscriptionApiTest extends TestCase
Model::reguard();
}
public function testExpenseGet()
public function testBillingSubscriptionsGet()
{
$product = Product::factory()->create([
'company_id' => $this->company->id,