New Package: Laravel Invoices – Generate PDF Flexibly

New Package: Laravel Invoices – Generate PDF Flexibly

https://www.youtube.com/watch?v=h9iuXm23Xe0

Presenting to you our totally new package. While working with invoices on client projects, we didn’t find convenient way to generate PDFs.

programming

via Laravel News Links https://ift.tt/2dvygAJ

December 5, 2019 at 08:48AM

New ‘Home Defense Act’ Would Reclassify SBRs as Semi-Autos

New ‘Home Defense Act’ Would Reclassify SBRs as Semi-Autos

https://ift.tt/2DQGNeE

Congressman Roger Marshall, M.D. (R-Kan.) introduced a potentially important piece of legislation in Washington Tuesday. The Home Defense and Competitive Shooting Act would streamline bureaucratic regulations, reduce ATF processing times and remove unconstitutional finger print requirements and fees for certain rifles.

Dianna Muller spoked before House Judiciary Committee.

RELATED STORY

WATCH: Dianna Muller Tells House Judiciary Committee ‘I Will Not Comply’

Home Defense and Competitive Shooting Act

“Opponents of the Second Amendment want to use bureaucracy and regulations to obstruct citizens attempting to exercise their God-given right to keep and bear arms,” Marshall said in a statement. “The firearms addressed in this bill are commonly used for hunting, personal defense, and competitive shooting. Since I came to Congress, I have fought tooth and nail to stop attempts that would strip our Constitutional right to keep and bear arms. This bill will eliminate regulations designed not to protect Americans, but to deny them their Constitutional rights.”

The proposed bill specifically addresses short-barreled rifles, regulated by the NFA since 1934. Should this bill pass, SBRs would reclassify as simply semiautomatic rifles. It would also remove any form or tax stamp from the rifle.

“The introduction of this bill is yet another landmark towards restoring the constitutionally-recognized right to keep and bear arms without infringement by federal regulations and whimsical rulemaking by anti-gun D.C. bureaucrats,” said Aidan Johnston, Director of Federal Affairs for Gun Owners of America. “Gun Owners of America urges every member of the House of Representatives to cosponsor this bill.”

“On behalf of the NRA’s five million members, I thank Dr. Marshall for introducing necessary legislation that will restore Constitutional rights to law-abiding Americans to choose which firearms best suit their needs,” said Jason Ouimet, executive director, National Rifle Associations’s Institute for Legislative Action. “It’s time Congress eliminates costly and unnecessary government regulations on short-barreled rifles, which are used in sport shooting, hunting and are especially popular with women gun owners for self-defense.”

Road Ahead

Any proposed legislation such as this makes the 2A crowd happy. But a Democratic-controlled House of Representatives makes passage of the bill highly unlikely. Had this bill come to the floor prior to the mid-term election, it could have fared much better. But one can hope.

For more information, visit marshall.house.gov.

The post New ‘Home Defense Act’ Would Reclassify SBRs as Semi-Autos appeared first on Personal Defense World.

guns

via Personal Defense World https://ift.tt/2Arq2GB

December 5, 2019 at 10:03AM

New Zealand Data Breach Reveals Extent of Gun ‘Buyback’ Non-Compliance

New Zealand Data Breach Reveals Extent of Gun ‘Buyback’ Non-Compliance

https://ift.tt/2P9TUMY

I’ve been following the New Zealand firearm “buyback” with some amusement as I ran estimates on the compliance rate based on NZ Police turn-in reports and NZ government guesstimates of the number of affected firearms. (It’s a measly 16.5% as of November 24.)

News of the “buyback” privacy breach has added extra humor value. Sorry, Kiwi gun owners who were complying; I’m sure you weren’t laughing.

But privacy issues aside, I am. And not merely at the gross incompetence displayed. I’m encouraged by the additional proof of non-compliance.

Government estimates of the number of newly banned firearms range from an early 173,000 to, finally, 240,000. I’ve been rolling with the final 240K figure.

At the end of November, 21,655 people had been paid for 36,045 firearms. That works out to an average 1.66 firearms per person.

Reports have it that people turning their firearms had to pre-register online through the breached web site. A total of 38,000 people registered and now have their personal and financial data endangered.

There are only 17 days left in the amnesty period, so you’d expect that pretty much everyone who had any intention of complying would have registered by now.

Only 38,000. Let’s assume that the 1:1.66 ratio holds true. That would account for 63,080 firearms or 26.3% compliance.

I had been projecting 19.8% assuming no sudden, last-minute rush, and turn-in rates holding steady. But I also figured some folks would get cold feet in the final weeks and decide to turn in their property, especially registered Cat-E “military-style semiautomatic” owners since the government does know who they are (but 60% of even those aren’t complying yet).

I had speculated that the New Zealand government would stop reporting turn-in numbers out of sheer embarrassment. Then they’d dust off early lowball estimates and simply declare the amnesty a success.

Now this breach fiasco just gives them a better opportunity to do so.

guns

via The Truth About Guns https://ift.tt/1TozHfp

December 5, 2019 at 11:01AM

Satisfying Plank Collapse

Satisfying Plank Collapse

https://ift.tt/2rgIOhr

Satisfying Plank Collapse

Link

Hobbyist Crouzier Benjamin loves to build complex structures using thousands of Kapla wooden planks. For this build, he took about 2 weeks assembling 20,000 of the beams, then watched it all fall in about 30 seconds. Check out his YouTube playlist for lots of other fun architectural collapses.

fun

via The Awesomer https://theawesomer.com

December 5, 2019 at 11:08AM

Coca-Cola’s Glowing Lightsaber Bottles Are the First Flexible OLED Tech I’m Willing to Pay For

Coca-Cola’s Glowing Lightsaber Bottles Are the First Flexible OLED Tech I’m Willing to Pay For

https://ift.tt/2qsDirG

I’m one hundred percent in support of a future where screens are flexible and foldable instead of fragile and easily shatterable. I’m just not willing to spend $2,000 on a folding phone or $10,000+ on a rollable TV. I will, however, happily drop $2 or $3 on a plastic bottle with a glowing lightsaber on the label.

As the marketing machine for Star Wars: The Rise of Skywalker slowly but surely kicks into hyperdrive ahead of the film’s mid-December release, every section of every store is slowly being taken over by Star Wars-branded merchandise—in addition to a monsoon of toys. But it seems like Singapore is the place to be if you want to snag one of the most interesting pieces of The Rise of Skywalker merchandising: Coca-Cola has wrapped its bottles in a thin flexible OLED panel and electronics, including a battery, allowing images of Rey’s and Kylo Ren’s lightsabers to actually glow.

Flexible OLEDs are currently just a little too expensive when used in consumer products that actually take advantage of their ability to, you know, flex. But this might be the perfect application for the technology at this point in time. OLED is self-illuminating, so no backlight is needed, allowing the ultra-thin panels to be tucked behind a plastic bottle’s label without looking like a bunch of electronics have been poorly hidden. And no matter how much those bottles get tossed around and banged up during shipping, at least most of the panels should survive and continue to work just fine, creating a rather neat effect that will undoubtedly help Coca-Cola sell a lot of fizzy water this month.

There’s a catch, however. These bottles are only being made available in Singapore, just 8,000 of them are being produced for Coca-Cola’s “No Sugar” drinks, and they’re being randomly distributed to 45 secret locations across the country. It’s a strategy that presumably helps deter long lineups full of obsessive fans or professional eBayers, but it’s annoying for legitimate collectors who will potentially have to scour an entire country to score one of these at a reasonable price.

Also, if you do manage to get your hands on one of these bottles, you’ll want to make sure you don’t get too lightsaber happy. The battery life for the OLED is rated for about 40 minutes in total, letting you illuminate the saber roughly 500 times as long as you keep your lightsaber battle shorter than five seconds.

geeky,Tech

via Gizmodo https://gizmodo.com

December 5, 2019 at 11:48AM

Craigslist Finally Gets an Official App

Craigslist Finally Gets an Official App

https://ift.tt/33OVn0H

Craigslist has long been a staple of the internet since it first launched in 1995—but surprisingly, it hasn’t had an official app in the decade or so since the smartphone era began. Well, that’s all changed. You can now find the official, free app for iOS.

Like the website, the mobile app is extremely simple—no frills, bells, or whistles. The app’s overall design mimics the website as well, meaning its mostly just text and a clean interface. As you’d imagine, that makes the app extremely fast and easy to load. There’s also a post tab that streamlines posting straight from your phone. Not that making a Craigslist post was ever hard, but the app does make the process a lot smoother.

Even the app’s description is the bare minimum. One could say it reads like a haiku or at least some sort of Hemingway-esque musing on internet life.

craigslist – The original online classifieds. Established 1995.

Find jobs. Hire employees. Post your resume. Offer your skills/services.

Buy & sell cars, trucks, boats, RVs, motorcycles, trailers, auto parts.

Offer your services, locate contractors, find short term gigs and odd jobs.

Buy & sell furniture, household items, electronics, computers, clothing, bikes, art, any and all kinds of used items.

Activity partners, artists & musicians, pets for rehoming, local events.

Save your favorite postings for later, save searches, set search alerts.

Post, edit, renew your own ads.

Right now, the app ranks No. 14 in the App Store’s shopping category and has an overall 4.6 out of 5 star rating from 63 reviews. Not too shabby considering version 1.0 dropped just yesterday. It’s only mildly surprising that the launch has been so quiet. The site stealthily launched beta testing for the official app on its website an indeterminate time ago, though it’s not that easy to find the link on the main site. Although a search in the Google Play Store only turns up third-party apps at the moment, you can find a link to the Android beta test here.

[9to5 Mac]

geeky,Tech

via Gizmodo https://gizmodo.com

December 4, 2019 at 12:33PM

Detailed Analysis of New York State Rifle & Pistol Assn. Supreme Court Arguments

Detailed Analysis of New York State Rifle & Pistol Assn. Supreme Court Arguments

https://ift.tt/360bI4c

By LKB

As previously reported, I had a ringside seat for yesterday’s SCOTUS arguments, and Dan posted some of my quick observations from the argument. Now that I have had a bit more time to digest things (as well as some food and sleep), I want to go into a bit more detail on how I perceived how the argument went down.

Mootness

As has been widely reported, most of the time spent during oral argument involved addressing whether New York City’s last-minute maneuver (i.e., after the Supreme Court granted cert, the City and the State changed the law in a transparent and brazen attempt to evade appellate review) rendered the case at bar moot.

Mootness is a legal doctrine that provides that when there is no longer any actual dispute between the parties for the court to decide, an appellate court should dismiss the case rather than enter advisory or hypothetical opinions. However, it is a complicated area of law that has many exceptions, many of which were discussed yesterday.

Courtesy LKB

Contrary to how the media (and unfortunately some Chicken Littles in the firearms commentariat) have tried to spin the amount of time at argument that was spent discussing mootness, that fact doesn’t really mean anything. In appellate advocacy, you go into oral argument with an outline of points you would like to make…usually a very small subset of the arguments made in your briefs.

However, you are not in control of things, and your argument goes where the most active questioners on the Court want to take it. This is especially true at the Supreme Court, where the van Moltke maxim that “no battle plan survives first contact” is typically the case.

In NYSR&PA, the anti-2A wing of the Court (Ginsburg, Breyer, Kagen and Sotomayor) are all known as active questioners at oral argument, as opposed to Thomas, who almost never asks anything at all, and Roberts and Kavanaugh, who tend to ask very few.

As a result, the liberal wing of the Court dominated the time at oral argument with their questioning. However, just because they asked the most questions (and thus made the attorneys spend most of their argument answering them), that simply does not signify anything.

Supreme Court NYSRPA v City of New York

LKB for TTAG

So, how will the Court decide the mootness issue? As I expected, Ginsburg and Sotomayor were more than willing to swallow NYC’s brazen tactical maneuver. While I thought that Kagen and Breyer might have some shred of integrity on this procedural issue (blessing this kind of post-cert gamesmanship would set a horrid precedent for all sorts of cases – especially many that those two justices typically care about), that possibility evaporated at oral argument. Both of those justices were clearly on board with letting the City get away with it in order to avoid a potential expansion of Heller.

On the other hand, both Alito and Gorsuch did not mince words about how they felt about NYC’s chicanery. Gorsuch acidly remarked on NYC’s “Herculean efforts” to evade Supreme Court review after cert was granted. Thomas and Kavanaugh asked no questions, but their positions in past cases leave me with little doubt that they are not going to vote to hold the case moot.

That leaves the deciding vote on the mootness issue with Roberts. Early media reports were crowing that Roberts’ questions indicated that he was leaning toward finding the case moot. From what I saw (and confirmed in the transcript), I simply did not see that.

The Chief Justice asked only two questions, one of which was a bit of a trap that adduced a concession from NYC’s counsel that dismissing the case as moot would prejudice the plaintiffs’ ability to seek damages for violations of their rights.  If anything, I think Roberts’ questions cut the other way on which way he may be leaning.

supreme court scotus second amendment protest demonstration

Courtesy Kevin Hulbert

Additionally, if Roberts was going to wimp out on the mootness issue, I suspect he would have already done so. The Court had several earlier opportunities to dismiss the case as moot, and if he was so inclined, Roberts could have voted with the liberals and done so. He did not.

Of course, as the Obamacare decision illustrated, Roberts can certainly be a squish, and thus he could well sell us out on this issue. However, nothing I saw at oral argument supported the spin the media put on it.

Indeed, I suspect the media is pushing the “it’s going to be dismissed as moot” narrative for its own purposes (e.g., to be able to decry a Roberts “change of position” on mootness as evidence that the court is broken and needs to be packed, etc.)

LKB prediction: 5-4 denial of the motion to dismiss the case as moot. However, if we see a cert grant in the next few weeks on another 2A case — there are several being held due to the grant of cert in NYSR&PA — then all bets are off.

The Merits of the Case

Because of the near-monopolization of the oral argument by the liberal wing of the Court on the mootness issue, very little time was spent on the merits (absolutely none on the Commerce Clause or Right to Travel issues). However, there were a few interesting moments.

The highlight of the arguments on the merits was a spectacular trap that Justice Alito sprang on the attorney for the City. Questioning him on NYC’s change of its laws, he asked, “Are people in New York less safe now as a result of the new city and state laws than they were before?”

Clearly surprised at this seemingly out-of-the-blue question, counsel responded that they were not less safe. Alito then pressed him to concede that there was thus no actual basis for the City to claim that the transportation ban was essential to public safety.

Counsel attempted to tap dance away from that, claiming the restriction accorded with the history of acceptable regulations under the Second Amendment.

Alito then pressed counsel on whether a total ban on transportation by premises license holders could possibly be constitutional. The City’s position – and Second Circuit law – “cabin” Heller to possession of a weapon in the home.

I expected him to respond “yes” and then just take the heat. Instead, he admitted that such a complete ban would violate the Second Amendment.

Justice Alito then pounced: “If that’s what it means, you’re conceding that the Second Amendment protects the possession of a firearm outside the home under at least some circumstances?” Counsel again tried to tap dance away, but again conceded that was a “fair way to look at it.“

So much for the City’s argument that Heller applies only to possession inside the home.

Counsel for both NYSR&PA and the Solicitor General pushed application of the “Text, History, and Tradition” test as the applicable standard, rather than strict scrutiny. In what I took as a transparent shot at Justice Kavanaugh, Justice Sotomayor remarked that she viewed the “Text, History, and Tradition” test as a “made-up standard.”

Supreme Court New York Second Amendment Protest

Courtesy Matt Laur

Needless to say, the fact that standards for decision – or even new constitutional rights – might have been “made up” by judges has hardly concerned Sotomayor in the past.

At another point, she remarked that questions about whether certain types of weapons were covered by the Second Amendment was not before the Court yet. I might be reading too much into it, but I took her comment and the way she asked it as a recognition that regardless of what happens in this case, she knows that the votes are there to take other 2A cases.

Near the end of the argument, Justice Ginsburg (who looked very frail, but nevertheless was engaged and asked a number of probative questions in both of Monday’s arguments) asked the City’s counsel whether, because the transportation ban forbade taking a licensed gun to a second house (whether in or out of the city), that would require a license holder who wished to be armed at home to acquire two guns — one for each house — and leave one gun at an unoccupied location at all times, which she seemed to intimate would be less safe than transporting one gun between them.

To me, she plainly was teasing an argument that perhaps the NYC transportation ban could be struck based on intermediate scrutiny, perhaps to try and tempt Roberts into reversing on narrower grounds. (Query why she would do this if she thinks Roberts might squish on mootness.)

At one point in the argument, Justice Breyer made a comment that indicated that he still does not accept that Heller was correctly decided…which caused his neighbor, Justice Thomas, to lean over and engage him in a whispered conversation.

My read on the merits: nothing has changed, and things are as they have been. There is a wing of the Court (Ginsburg, Breyer, Kagen, Sotomayor) that is adamantly anti-2A and would gladly reverse Heller if they had the chance. There are four votes (Thomas, Alito, Gorsuch, and Kavanaugh) who go the other way, and would likely expand Heller significantly.

Roberts is also at least nominally in this camp, but the question remains whether he will succumb to the Beltway social, media, and political pressure as he did in the Obamacare decision.

My prediction: if they reach the merits, 5-4 to reverse.  Smart money would be that Roberts will write the opinion, but I’ll go out on a limb and predict that he’ll assign it to Kavanaugh, and will adopt the “Text, History, and Tradition” test for 2A cases. Concurrence by Thomas, Alito, and Gorsuch, pushing for strict scrutiny and an end to lower court gamesmanship on 2A cases.

We’ll see . . . .

guns

via The Truth About Guns https://ift.tt/1TozHfp

December 3, 2019 at 03:24PM

Marvel’s new ‘Black Widow’ trailer teases the spy thriller Natasha Romanoff deserves

Marvel’s new ‘Black Widow’ trailer teases the spy thriller Natasha Romanoff deserves

https://ift.tt/34KO6A5

Marvel has a trailer out for Black Widow, the story focused on the member of the Avengers team played by Scarlett Johansson. This preview of the movie features a lot of heart-pumping action, and an all-star cast that includes Rachel Weisz, Florence Pugh, David Harbour, and of course, Johansson herself.

What we get in this trailer is a look at a movie that appears to span multiple genres – it starts off looking very much like a Bourne-esque spy thriller with exciting, somewhat gritty hand-to-hand fight scenes. Later on, though, it seems to show more superhero vibes in the tradition of the big and glossy Marvel cinematic universe, though leaning more towards Captain America: Winter Soldier than the big tent circus set pieces of the core Avengers lineup, or the wacky, neon glare of the Guardians franchise and the most recent Thor.

Black Widow’s Russian spy background is clearly on display here, and it looks like there’s going to be a very weird ‘family reunion’ on display with some Russian heroes. Overall, it looks entertaining as heck – and it has a lot to live up to, as the first Marvel Studios film after Avengers: Endgame (Spider-Man: Far From Home only gets partial credit because of the shared character ownership with Sony).

technology

via TechCrunch https://techcrunch.com

December 3, 2019 at 07:57AM

Cache Eloquent queries in Laravel 6

Cache Eloquent queries in Laravel 6

https://ift.tt/2IPx22y

The package can be found on GitHub, where the documentation will approach all of the main points of the app. However, during this article, you’ll learn just the basics of caching and clearing cache so you can get started before you will dig deeper.

Installation

The package can be installed through Composer:

$ composer require rennokki/laravel-eloquent-query-cache

Your models will need the QueryCacheable trait:

use Rennokki\QueryCache\Traits\QueryCacheable;class Article extends Model
{
use QueryCacheable;
...
}

Enable the caching behavior by default

By default, the package does not enable query caching. To achieve this, add the $cacheFor variable in your model:

use Rennokki\QueryCache\Traits\QueryCacheable;class Article extends Model
{
use QueryCacheable;
protected $cacheFor = 180; // 3 minutes
}

Whenever a query will be triggered, the cache will intervene and in case the cache is empty for that query, it will store it and next time will retrieve it from the caching database; in case it exists, it will retrieve it and serve it, without hitting the database.

// database hit; the query result was stored in the cache
Article::latest()->get();
// database was not hit; the query result was retrieved from the cache
Article::latest()->get();

If you simply want to avoid hitting the cache, you can use the ->dontCache() before hitting the final method.

Article::latest()->dontCache()->firstOrFail();

Enable the caching behavior query-by-query

The alternative is to enable cache query-by-query if caching by default doesn’t sound like a good option to you.

First of all, remove the $cacheFor variable from your model.

On each query, you can call ->cacheFor(...) to specify that you want to cache that query.

Article::cacheFor(now()->addHours(24))->paginate(15);

Organize better with tags

Some cache storages, like Redis or Memcached, come up with the support of tagging your keys. This is useful because we can tag our queries in-cache and invalidate the needed cache whenever we want to.

As a simple example, this can be useful if we want to invalidate the articles list cache when one article gets updated.

$articles = Article::cacheFor(60)->cacheTags(['latest:articles'])->latest()->get();$article = Article::find($id);
$article->update(['title' => 'My new title']);
Article::flushQueryCache(['latest:articles']);

The method flushQueryCache invalidates only the caches that were tagged with latest:articles. If some other queries would have been tagged with tags other than latest:articles, they would be kept in the cache.

Digging deeper

For more about this package, check out the project’s page on GitHub.

programming

via Laravel News Links https://ift.tt/2dvygAJ

December 3, 2019 at 08:36AM