yii

    0热度

    2回答

    我已经使用模型关联加入了两张表。这两个表是films和movie_streams但是有一些错误 我的查询: $film = Film::model()->with('movie_streams')->find(array('select' => '*', 'condition' => 'user_id=:user_id, 'params' => array(':user_id' => $user_

    0热度

    2回答

    我,当我试图插入值2016-03-27T03此错误:在我Yii1应用51.213与数据类型“时间戳”列:15 exception 'CDbException' with message 'CDbCommand failed to execute the SQL statement: SQLSTATE[22007]: Invalid datetime format: 1292 Incorrect d

    0热度

    2回答

    所以我设置了一个CRUD上传文件到服务器的根目录,名为'uploads'。 现在,该文件已正确保存在特定文件夹中,并且数据库条目看起来没问题 - 但图像不显示在CRUD的“索引”和“视图”操作中。对此有任何想法? 创建: public function actionCreate() { $model = new PhotoGalleryCategories();

    0热度

    1回答

    在观看/索引文件,其中示出了模型的所有i的数据使用 'filter'=>ArrayHelper::map(Mobile::find()->asArray()->all(),'id', 'mobile'), 它工作忠实地但不显示值。它只有一些空的领域。 这里是我的看法/指数代码: <?php use yii\helpers\Html; use yii\grid\GridView; use

    0热度

    1回答

    我正在用yii2 advance编写代码。 Warning: require($file): failed to open stream: No such file or directory in C:\xampp\htdocs\Yii-Dummy\vendor\composer\autoload_real.php on line 66 Fatal error: require(): Failed

    1热度

    2回答

    我现在正在与rbac yii2合作。 我定义了数据库中的所有角色和权限。 现在对我来说,问题是我应该在哪里检查访问规则? 例如,作者可以更新他自己的帖子。 我还在rule_name ='isAuthor'中保存了数据库中的规则。 但我对检查条件感到困惑,以访问自己的帖子。 这里是我的actionRule: <?php public function actionRule(){ $aut

    1热度

    2回答

    我想在Yii 2中更改GridView的显示格式。例如,我希望有一些行和列的数据,如Internet市场显示产品。 例如,在每一行中我想要有4-5个产品.. 这是默认使用GridView的一个示例。 <?= GridView::widget([ 'dataProvider' => $dataProvider, 'filterModel' => $searchModel,

    0热度

    1回答

    我要添加过滤器与列表视图(有些事情喜欢在网格视图),但我不不知道 过滤器我想是的CheckBox如何做和DropDown选项。 这是我的操作代码在SiteController <?php public function actionMobiles(){ $searchModel = new MobileSearch(); //$dataProvider = $searchM

    0热度

    1回答

    虽然从YII发送邮件,支持SMTP协议,它提供了以下错误: Swift_TransportException: Expected response code 250 but got code "530", with message "530 5.7.57 SMTP; Client was not authenticated to send anonymous mail during MAIL FR

    0热度

    1回答

    我想使用SQLYog从MySql查询中获取(选择)下一行值,与 相同的id_voyage_order? 例子: id_timesheet | id_voyage_order | Duration ---------------------------------------- 1 | 106 | 0.00 2 | 106 | 24.00 3 | 210 |