public static function create($belongsTo, $type, $data, $attributes = [])
    {
        $obj = new Task();
        $obj->belongsTo = $belongsTo;
        $obj->type = $type;
        $obj->data = $data;
        $obj->additional = $attributes;
        $obj->save();
    }
public static function create($belongsTo, $type, $data, $attributes = [])
    {
        $obj = new Task();
        $obj->belongsTo = $belongsTo;
        $obj->type = $type;
        $obj->data = $data;
        $obj->additional = $attributes;
        $obj->save();
    }
public static function create ( $ belongsTo , $ type , $ data , $ attributes = [ ] ) { $ obj = new Task ( ) ; $ obj -> belongsTo = $ belongsTo ; $ obj -> type = $ type ; $ obj -> data = $ data ; $ obj -> additional = $ attributes ; $ obj -> save ( ) ; }
Create new task

@param string       $belongsTo
@param string       $type
@param object|array $data
@param array        $attributes
Create new task