Laravel 5 and Quickbooks - php

I'm trying to integrate the Quickbooks Online API into Laravel 5. I've got the code working outside of Laravel using the Consolibyte package. But its written in what I'll call a classic PHP style - meaning there are a number of REQUIRE_ONCE files etc. I'm sure I can crank through and integrate it all, but in the interest of saving time, I'm wondering if anyone else knows of a package for Laravel 5 which already does this?
Ultimately I need to be able to create Customers, Vendors and Invoices. Don't really need the rest of the functionality that the Consolibyte package uses (which is a great package by the way).

If you're using this code:
https://github.com/consolibyte/quickbooks-php
You only need to require one file. There's no real work required to get this working in Laravel. Just do this in your Laravel app:
require_once './QuickBooks.php';
And you're done.

For anyone else looking to solve this problem, this obscure blog post will save your life. It's a lot to post here, but he essentially uses the consolibyte/quickbooks-php, but wraps it up in creamy Laravel goodness so you can see the "under the hood" objects you need to set up so that you don't break the framework.
I followed the instructions, with some alterations for my app, and it authorized first try (Laravel 5.2).
It's not perfect, but it's as clean as you can get for Laravel right now.
Major props to both the article writer Pawan and the package author Keith Palmer Jr!

You can use this one instead its fully enabled to be installed by composer in Laravel or Yii2. I installed it in Yii2.
https://github.com/beanworks/quickbooks-online-v3-sdk install quickbooks from this url and then use the below url to implement oauth
https://github.com/IntuitDeveloper/oauth-php
You can easily make routes for oauth steps involved and there are samples in the later repo which can be used to learn how to post and query objects from quickbook.

Related

Adding auth to existing project with Laravel Alpine and Livewire

I have an existing laravel project with AlpineJS. I wanted to integrate authentication but not able to find a proper solution having in mind I DONT USE VUE. I have done this with Vue but just wanted to know if there's an updated guide for Laravel with Alpine JS. I tried to look into documentation but wasnt able to find something related.
composer require laravel/ui
php artisan ui:auth
Do I still need to do this? Any suggestions for best practices?
Alpine is just a lightweight framework for DOM manipulation, it's not going to provide any authentication functionality alone so you will need to add something to your project.
If you're wanting to add authentication to your application, you'll want to consider something like Laravel Fortify which is a headless front end agnostic authentication solution. There are starter kits such as Breeze or Jetstream, however, adding either of these boilerplate start kits to existing projects can have issues. Some people recommend starting a new project, installing one of them and them porting your existing functionality across (this will obviously depend on the scale of your project).

How to add OAuth2 Server on a CakePHP 3 plugin

I am working on a plugin in CakePHP3 and I need to create a simply Oauth 2.0 Server API that allows to do a simple CRUD on the users' table and create sessions when needed.
I have done some research here in StackOverflow and it seems that the best choice would be
https://github.com/uafrica/oauth-server
Now, I have tried to make it work according to the doc in the repository but since it will be a plugin, not the core of the application I do not understand how it is supposed to work and which file I need to update.
Would somebody be so kind to give me the list of steps I need to follow and the actual files that need to be updated?
Many Thanks in advance
The uafrica/oauth-server project is woefully out of date. It requires v4.1 of league/oauth2-server, which is now currently at v7.2. Version 5 of that project was completely rewritten and is not backwards compatible with v4.x.
I don't think there's an out-of-the-box CakePHP 3 plugin that works with the current version of league/oauth2-server.
You'll have to either build your own plugin from scratch, or try to hack the uafrica/oauth-server project to get it work with league/oauth2-server.

How to bootstrap/setup Angular2 in an existing Laravel project?

I am looking to implement Angular2 inside my current Laravel project. I've read about many setups including AngularClass's version with Webpack, but I feel like it's all over-complicated.
What I wish to make:
A simple single page app inside my Laravel app.
It needs to have something like Grunt/Gulp or even Webpack to compile upon changes.
Does not need NodeJs to run in production, no lite-server, just like AngularJS it can be injected and that's it.
I need to understand the implementation files to achieve this, so no starterpack or angular-cli, unless if you can supply good arguments.
Looking for a "how to"-like example on creating the above.
Thanks in advance.
EDIT: More information
As ANKH pointed out, i needed a more detailed and coursed question. So here we go:
- Looking for a example implementation of a Angular2 based SPA inside an existing PHP application (Laravel).
- I've tried many different tutorials, going from the heroes tour, to Sitepoint and AngularCLI based tutorials, but they all assume a SPA on it's own. Ergo, they are compiled and served through NodeJS, which I don't need.
Turns out that I've actually been looking at this entirely wrong. I've gone with using Angular-cli and found that I could generate the output files and include these inside my Laravel project. No need to integrate them further.

NEOS form handling

i just learned NEOS, usually i do project using laravel framework.
Now i try to use typo3 NEOS, because people said that typo3 is half MVC half CMS.
i just covered the basic frontend, and now i try to do the backend stuff.
My question is, how to handle the backend stuff in neos?
especially about form and database handling (like registration and login stuff).
thanks for your attention, i know this is a basic stuff. But i can't find any good tutorials out there.
i'm using typo3 NEOS 1.2.1
For forms there is a simple tutorial
What do you mean with database handling?
Frontend user registration? There are some problems right now with that but you may take a look at it here.
TYPO3 Neos is CMS build on TYPO3 Flow framework - take a look at Flow documentation - in Quickstart there is part how to create simple package in few minutes using ./flow kickstart:*. You can use pure Flow packages beside Neos (that requires putting this package routes above neos in main Routes.yaml) or transform Flow package into Neos plugin. I think it's worth to do some reading first..

Symfony project using CURL - building project with API

I have never used a PHP framework before and am considering using Symfony for my next one. However, I have already built an API which has all my main classes. I will therefore connect to this API using CURL. Can anyone advise on where to start with such a project. I am working through a Symfony tutorial but none of it seems to apply to what I need to do as I do not need to create database connections or classes as I will be building this project on my existing API.
If you don't need a lot of what you see in the Symfony tutorials you might be able to get away with Silex. Silex is a mini-framework with alot of the core aspects of Symfony, but without the extra stuff.
http://silex.sensiolabs.org/

Categories