public function storePermalinks(Request $request)
    {
        $data = $request->all();

        $tmp = [];
        foreach ($data as $permalinks){
            $tmp = array_merge($tmp, $permalinks);
        }

        if(Permalink::truncate()) {
            if(Permalink::insert($tmp)) {
                return $this->response('Permalinks are saved', 200);
            }
        }

        return $this->response('Permalinks could not be saved. Please try again later.', 500);
    }