zoukankan      html  css  js  c++  java
  • Laravel Argument 1 passed to AppModelsRecipientsAlertRecipient::__construct() must be an instance of AppModelsRecipientsstring, string given,

    今天测试snipet的计划任务,库存低于警告值的时候,时候会会自动发送邮件到邮箱

    class SendInventoryAlerts extends Command
    {
        /**
         * The name and signature of the console command.
         *
         * @var string
         */
        protected $signature = 'snipeit:inventory-alerts';
    

     可以看到 当前命令的名称为

      snipeit:inventory-alerts

    我使用windows10调试的,开始:
    1.打开cmd,cd.... 进入项目目录
    2.输入 snipeit:inventory-alerts ,但是这时候出现了错误提示 :

    最后发现是由于php版本的缘故,我现在使用的PHP版本是5.6.27

    3.然后,我去修改环境变量,并且更新了当前的php版本为php7
    然后重新打开cmd,输入上述命令,出现的效果如下图所示,大概隔了1秒做旧,立马就收到邮件了,邮件成功发送

     



  • 相关阅读:
    什么是评审
    缺陷识别与缺陷跟踪
    白盒测试用例设计
    黑盒测试用例设计(二)
    黑盒测试用例设计技术
    Mysql基础
    JS函数
    SpringBoot整合JPA
    Python中的保留字
    操作系统的发展史
  • 原文地址:https://www.cnblogs.com/fpcing/p/10932052.html
Copyright © 2011-2022 走看看