« first day (1779 days earlier)      last day (649 days later) » 

11:31
namespace livefactory\models;
use Yii;
class AuthAssignment extends \yii\db\ActiveRecord
{
/**
* @inheritdoc
*/
public static function tableName()
{
return 'auth_assignment';
}

/**
* @inheritdoc
*/
public function rules()
{
return [
[['item_name', 'user_id'], 'required'],
[['created_at' ,'user_id'], 'integer'],
[['item_name',], 'string', 'max' => 64],
[['item_name', 'user_id'], 'unique', 'targetAttribute' => ['item_name', 'user_id']]
];
}

/**
* @inheritdoc
*/
public function attributeLabels()
1 message moved from PHP
$company = livefactory\models\Company::find()->asArray()->one();
$address = livefactory\models\search\Address::companyAddress($company['id']);
$role = livefactory\models\AuthAssignment::find()->where("item_name='Admin' AND user_id='".Yii::$app->user->identity->id."'")->asArray()->one();
if(count($role) > 0){
Yii::$app->params['user_role']= 'admin';
}else{
Yii::$app->params['user_role']= 'guest';
}
1 message moved from PHP
12:07
namespace livefactory\models;

use Yii;

/**
* This is the model class for table "auth_assignment".
*
* @property string $item_name
* @property string $user_id
* @property integer $created_at
*
* @property AuthItem $itemName
*/
class AuthAssignment extends \yii\db\ActiveRecord
{
/**
* @inheritdoc
*/
public static function tableName()
{
return 'auth_assignment';
}

/**
* @inheritdoc
*/
public function rules()
{
return [
[['item_name', 'user_id'], 'required'],
[['created_at' ,'user_id'], 'integer'],
$company = livefactory\models\Company::find()->asArray()->one();
$address = livefactory\models\search\Address::companyAddress($company['id']);
$role = livefactory\models\AuthAssignment::find()->where("item_name='Admin' AND user_id='".Yii::$app->user->identity->id."'")->asArray()->one();
if(count($role) > 0){
Yii::$app->params['user_role']= 'admin';
}else{
Yii::$app->params['user_role']= 'guest';
}
12:28
2 messages moved from PHP
 
6 hours later…
18:41
force
test
 
3 hours later…
22:15
>> info
>> info
@AwalGarg BOT: AwalGarg's bot written with Rx streams and other hipster tech. Also zirak and towc are smelly.
5 messages moved from Sandbox

« first day (1779 days earlier)      last day (649 days later) »