所以我的 Mailable 视图抛出了这个错误——这就是我手头上的一切。当我使用 Lumen 5.8 时它运行良好,所以我猜测它是在升级到 Laravel 6 之后发生的。
调用未定义的函数array_except()(查看:/kunden/182801_60322/tu/uat/api/resources/views/mail/invite-employee.blade.php)
我的刀片文件如下所示:
@extends('mail.master')
@section('content')
<tr>
<td align="left" style="border: 1px solid #dddee5; border-bottom: 2px solid #cecfd9; padding; 20px;">
<div class="padded">
<p>
{!! nl2br(e($data->message)) !!}
</p>
</div>
</td>
<tr>
<tr>
<td align="left" bgcolor="#eaeaf2" class="padded">
<p style="margin-bottom: 5px;" class="cta-label">{{ $data->copy->click }}</p>
<div class="cta-link">
<a style="color: #337BE9;" class="cta-link--a" href="{{ $data->appUrl }}/{{ $data->route }}/{{ $data->verificationCode }}">{{ $data->appUrl }}/{{ $data->route }}/{{ $data->verificationCode }}</a>
</div>
<p style="font-size: 12px; margin-top: 10px;">{{ $data->copy->mistake }}</p>
</td>
</tr>
@endsection
Run Code Online (Sandbox Code Playgroud)
显然代码的任何部分都没有试图调用该函数。
我的 composer.json …
这是一个臭名昭著的错误,在开发人员中拥有相当多的“追随者”,但众所周知,调试起来非常棘手。日志是这样的
PersonalSituationComponent.html:3 ERROR Error: ExpressionChangedAfterItHasBeenCheckedError: Expression has changed after it was checked. Previous value: 'true'. Current value: 'false'.
at viewDebugError (core.es5.js:8434) [angular]
at expressionChangedAfterItHasBeenCheckedError (core.es5.js:8412) [angular]
at checkBindingNoChanges (core.es5.js:8576) [angular]
at checkNoChangesNodeInline (core.es5.js:12455) [angular]
at checkNoChangesNode (core.es5.js:12429) [angular]
at debugCheckNoChangesNode (core.es5.js:13209) [angular]
at debugCheckRenderNodeFn (core.es5.js:13149) [angular]
at Object.eval [as updateRenderer] (PersonalSituationComponent.html:3) [angular]
at Object.debugUpdateRenderer [as updateRenderer] (core.es5.js:13131) [angular]
at checkNoChangesView (core.es5.js:12251) [angular]
at callViewAction (core.es5.js:12618) [angular]
at execEmbeddedViewsAction (core.es5.js:12596) [angular]
at checkNoChangesView (core.es5.js:12250) [angular]
at callViewAction (core.es5.js:12618) [angular]
Run Code Online (Sandbox Code Playgroud)
并没有真正的帮助。如果在 html …
javascript debugging typescript angular2-changedetection angular
我是Angular2的新手,正在边做边学.现在,我已成功构建了一个包含父组件,多个子组件和数据库服务的多视图.现在我将要使用各自的父子组件来实现其他视图.
应用程序应该使用可以在其他组件中添加/更新/删除的相同数据集,因此我正在寻找一个单独的数据层,可以由应用程序的所有组件直接查询.更多 - 我需要相同的服务实例,以便中间数据随处可用,以及避免不必要的数据库访问.在Angular2中定义和使用这样一个类的最佳方法是什么?
更新问: 现在,当我可以直接访问整个应用程序中数据层的同一实例的变量时,处理组件中变量的最佳方法是什么?
a)我应该使用本地组件变量,它们是相同数据层变量的副本(因此显式加载,获取和设置它们),如
this.locations = this.datalayer.locations;
this.selectedLocation;
updateLocation(id) {
this.selectedLocation = id;
this.datalayer.setSelectedLocation(id);
}
getSelectedLocation() {
return this.selectedLocation;
}
Run Code Online (Sandbox Code Playgroud)
或者b)我应该专门处理数据层变量,迭代它们,从组件中获取和设置它们吗?
updateLocation(id) {
this.datalayer.selectedLocation = id;
}
getSelectedLocation() {
return this.datalayer.selectedLocation;
}
Run Code Online (Sandbox Code Playgroud)
或者可能有一个选项c?
data-layers typescript angular2-routing angular2-services angular
有一个以独立模式运行的 Web 应用程序,具有以下 manifest.json
{
"lang": "de",
"name": "Test.App",
"short_name": "Test.App",
"start_url": "/36485/",
"display": "standalone",
"theme_color": "#FF4500",
"background_color": "#FFFFFF",
"icons": [...]
}
Run Code Online (Sandbox Code Playgroud)
此模式下没有浏览器 UI,因此必须在新的 Safari 窗口中打开文档(如 pdf、文档等)。这让我想到一个问题:如何强制 Safari 打开一个新的浏览器窗口?我们现在找到的解决方案是给它一个不同的域名(!!),即。一个子域。所有其他选项 - 无论是它window.open还是taget=_blank- 都没有任何效果,所有链接都将在同一个独立窗口中打开,因此无法返回到实际的应用程序界面。外部域似乎可以解决问题。是否有任何解决方法可以避免使用子域?也许通过清单中的一些定义?
manifest mobile-safari iphone-standalone-web-app progressive-web-apps
闪烁快要了我的命,在阅读了所有 jQuery 相关线程和mdn 后,我仍然无法弄清楚。
所以我有这个 @Directive 用于显示工具提示,这就是我将其绑定到元素的方式:
@HostListener('mouseenter', ['$event']) onEnter( e: MouseEvent ) {
this.showTooltip(e);
}
@HostListener('mouseleave', ['$event']) onLeave( e: MouseEvent ) {
this.hideTooltip(e);
}
@HostListener('click', ['$event']) onClick( e: MouseEvent ) {
this.hideTooltip(e);
}
constructor(
private el: ElementRef,
private renderer: Renderer2,
private coordsService: CoordsService,
@Inject(DOCUMENT) doc
) {
this.docBody = doc.body;
}
public ngAfterViewInit(): void {
this.tooltipContainer = this.renderer.createElement('div');
this.renderer.addClass( this.tooltipContainer, 'tooltip--tip');
this.renderer.addClass( this.tooltipContainer, 'tooltip--pos_' + this.position);
}
public showTooltip( e: MouseEvent ): void {
if ( this.tooltip …Run Code Online (Sandbox Code Playgroud) mouseevent typescript angular2-directives angular2-hostbinding angular
我希望我的网格在1320px的行中有24列.我还希望将默认(正文)字体大小设置为22px.让我告诉你如何使用SASS/SCSS和Zurb Foundation轻松完成这项工作......等等,什么?
不容易.除了rem-base不破坏网格之外,基本上不可能将"默认"字体大小设置为不同的值.如果$rem-base: 16px和$base-font-size: 100%一切工作正常-我只是想更大的字体.如果$rem-base: 16px和$base-font-size: 22px网格计算为1815px而不是1320px.当然,因为设置html字体大小设置rem单位和其他所有font-size指的是rem.
在_global.scss(V 5.2.1)处更改行345,346并将它们设置为不同的变量
html { font-size: $rem-base; }
body { font-size: $base-font-size; }
Run Code Online (Sandbox Code Playgroud)
不会影响p,ul等的字体大小
所以问题仍然存在:如何使用Foundation5 SCSS获得基本尺寸为22px的1320/24网格?
干杯
天真的问题:有没有办法使用 Artisan 在 Lumen 框架中创建一个 Mailable 类,如下所示:(php artisan make:mail OrderShipped示例取自文档)。
这是composer.json
{
"name": "laravel/lumen",
"description": "The Laravel Lumen Framework.",
"keywords": ["framework", "laravel", "lumen"],
"license": "MIT",
"type": "project",
"require": {
"php": ">=5.6.4",
"laravel/lumen-framework": "5.4.*",
"vlucas/phpdotenv": "~2.2",
"firebase/php-jwt": "^4.0",
"guzzlehttp/guzzle": "^6.3",
"illuminate/mail": "5.4",
"phanan/cascading-config": "~2.0"
},
"require-dev": {
"fzaninotto/faker": "~1.4",
"phpunit/phpunit": "~5.0",
"mockery/mockery": "~0.9"
},
"autoload": {
"psr-4": {
"App\\": "app/"
}
},
"autoload-dev": {
"classmap": [
"tests/",
"database/"
]
},
"scripts": {
"post-root-package-install": [
"php -r \"copy('.env.example', '.env');\"" …Run Code Online (Sandbox Code Playgroud) angular ×3
typescript ×3
laravel ×2
lumen ×2
data-layers ×1
debugging ×1
javascript ×1
laravel-5.4 ×1
laravel-6 ×1
manifest ×1
mouseevent ×1
php ×1
sass ×1