D/Volley: [1] 5.onErrorResponse: Product









up vote
0
down vote

favorite












How do I insert data from MySQL into Gridview on Fragments? I've tried it with a coding method used for Activity. I've changed a lot but it's still wrong. This is my coding:



/**
* A simple @link Fragment subclass.
*/
public class Product extends Fragment implements
SwipeRefreshLayout.OnRefreshListener

GridView grid_product;
SwipeRefreshLayout swipe;

List<ProductData> newsList = new ArrayList<ProductData>();

private static final String TAG = Product.class.getSimpleName();

private static String url_list = Server.URL + "news.php?offset=";

private int offSet = 0;

int no;

ProductAdapter adapter;

public static final String TAG_NO = "no";
public static final String TAG_ID = "id";
public static final String TAG_JUDUL = "judul";
public static final String TAG_TGL = "tgl";
public static final String TAG_ISI = "isi";
public static final String TAG_GAMBAR = "gambar";

Handler handler;
Runnable runnable;


public Product()
// Required empty public constructor



@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState)
// Inflate the layout for this fragment
View view = inflater.inflate(R.layout.fragment_product, container, false);
swipe = (SwipeRefreshLayout) view.findViewById(R.id.swipe_refresh_layout);
grid_product = (GridView) view.findViewById(R.id.grid_product);
setProduct();

return view;


private void setProduct()


adapter = new ProductAdapter(getActivity(), newsList);
grid_product.setAdapter(adapter);
grid_product.setOnItemClickListener(new AdapterView.OnItemClickListener()
@Override
public void onItemClick(AdapterView<?> parent, View view, int position, long id)
//pindah activity
startActivity(new Intent(
getActivity(), DetailActivity.class
));


);


I don't know where the mistake is:



 swipe.setOnRefreshListener(this);

swipe.post(new Runnable()
@Override
public void run()
swipe.setRefreshing(true);
newsList.clear();
adapter.notifyDataSetChanged();
callNews(0);


);

grid_product.setOnScrollListener(new AbsListView.OnScrollListener()

private int currentVisibleItemCount;
private int currentScrollState;
private int currentFirstVisibleItem;
private int totalItem;

@Override
public void onScrollStateChanged(AbsListView view, int scrollState)
this.currentScrollState = scrollState;
this.isScrollCompleted();


@Override
public void onScroll(AbsListView view, int firstVisibleItem, int visibleItemCount, int totalItemCount)
this.currentFirstVisibleItem = firstVisibleItem;
this.currentVisibleItemCount = visibleItemCount;
this.totalItem = totalItemCount;


private void isScrollCompleted()
if (totalItem - currentFirstVisibleItem == currentVisibleItemCount
&& this.currentScrollState == SCROLL_STATE_IDLE)

swipe.setRefreshing(true);
handler = new Handler();

runnable = new Runnable()
public void run()
callNews(offSet);

;

handler.postDelayed(runnable, 3000);



);



@Override
public void onRefresh()
newsList.clear();
adapter.notifyDataSetChanged();
callNews(0);



I don't know where the mistake is:



private void callNews(int page)

swipe.setRefreshing(true);

// Creating volley request obj
JsonArrayRequest arrReq = new JsonArrayRequest(url_list + page,
new Response.Listener<JSONArray>()
@Override
public void onResponse(JSONArray response)
Log.d(TAG, response.toString());

if (response.length() > 0)
// Parsing json
for (int i = 0; i < response.length(); i++)
try

JSONObject obj = response.getJSONObject(i);
ProductData news = new ProductData();

no = obj.getInt(TAG_NO);

news.addId(obj.getString(TAG_ID));
news.addJudul(obj.getString(TAG_JUDUL));

if (obj.getString(TAG_GAMBAR) != "")
news.addGambar(obj.getString(TAG_GAMBAR));


news.addDatetime(obj.getString(TAG_TGL));
news.addIsi(obj.getString(TAG_ISI));

// adding news to news array
newsList.add(news);

if (no > offSet)
offSet = no;

Log.d(TAG, "offSet " + offSet);

catch (JSONException e)
Log.e(TAG, "JSON Parsing error: " + e.getMessage());


// notifying list adapter about data changes
// so that it renders the list view with updated data
adapter.notifyDataSetChanged();


swipe.setRefreshing(false);


, new Response.ErrorListener()

@Override
public void onErrorResponse(VolleyError error)
VolleyLog.d(TAG, "Error: " + error.getMessage());
swipe.setRefreshing(false);

);

// Adding request to request queue
AppController.getInstance().addToRequestQueue(arrReq);












share|improve this question









New contributor




Nilzam yahya putra is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.



















  • Hi and welcome to SO. Please try to elaborate your problem, what is it exactly that you're stuck with. Also, take a moment to properly format your answer so that code can be distinguished from normal text. A well formed question is more likely to be noticed by someone who can answer your question. Hope it helps :)
    – Vijay Chavda
    Nov 10 at 15:56










  • Vijay has good feedback. Also make sure to check out How to Ask and help center for more help.
    – LAD
    Nov 10 at 19:49














up vote
0
down vote

favorite












How do I insert data from MySQL into Gridview on Fragments? I've tried it with a coding method used for Activity. I've changed a lot but it's still wrong. This is my coding:



/**
* A simple @link Fragment subclass.
*/
public class Product extends Fragment implements
SwipeRefreshLayout.OnRefreshListener

GridView grid_product;
SwipeRefreshLayout swipe;

List<ProductData> newsList = new ArrayList<ProductData>();

private static final String TAG = Product.class.getSimpleName();

private static String url_list = Server.URL + "news.php?offset=";

private int offSet = 0;

int no;

ProductAdapter adapter;

public static final String TAG_NO = "no";
public static final String TAG_ID = "id";
public static final String TAG_JUDUL = "judul";
public static final String TAG_TGL = "tgl";
public static final String TAG_ISI = "isi";
public static final String TAG_GAMBAR = "gambar";

Handler handler;
Runnable runnable;


public Product()
// Required empty public constructor



@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState)
// Inflate the layout for this fragment
View view = inflater.inflate(R.layout.fragment_product, container, false);
swipe = (SwipeRefreshLayout) view.findViewById(R.id.swipe_refresh_layout);
grid_product = (GridView) view.findViewById(R.id.grid_product);
setProduct();

return view;


private void setProduct()


adapter = new ProductAdapter(getActivity(), newsList);
grid_product.setAdapter(adapter);
grid_product.setOnItemClickListener(new AdapterView.OnItemClickListener()
@Override
public void onItemClick(AdapterView<?> parent, View view, int position, long id)
//pindah activity
startActivity(new Intent(
getActivity(), DetailActivity.class
));


);


I don't know where the mistake is:



 swipe.setOnRefreshListener(this);

swipe.post(new Runnable()
@Override
public void run()
swipe.setRefreshing(true);
newsList.clear();
adapter.notifyDataSetChanged();
callNews(0);


);

grid_product.setOnScrollListener(new AbsListView.OnScrollListener()

private int currentVisibleItemCount;
private int currentScrollState;
private int currentFirstVisibleItem;
private int totalItem;

@Override
public void onScrollStateChanged(AbsListView view, int scrollState)
this.currentScrollState = scrollState;
this.isScrollCompleted();


@Override
public void onScroll(AbsListView view, int firstVisibleItem, int visibleItemCount, int totalItemCount)
this.currentFirstVisibleItem = firstVisibleItem;
this.currentVisibleItemCount = visibleItemCount;
this.totalItem = totalItemCount;


private void isScrollCompleted()
if (totalItem - currentFirstVisibleItem == currentVisibleItemCount
&& this.currentScrollState == SCROLL_STATE_IDLE)

swipe.setRefreshing(true);
handler = new Handler();

runnable = new Runnable()
public void run()
callNews(offSet);

;

handler.postDelayed(runnable, 3000);



);



@Override
public void onRefresh()
newsList.clear();
adapter.notifyDataSetChanged();
callNews(0);



I don't know where the mistake is:



private void callNews(int page)

swipe.setRefreshing(true);

// Creating volley request obj
JsonArrayRequest arrReq = new JsonArrayRequest(url_list + page,
new Response.Listener<JSONArray>()
@Override
public void onResponse(JSONArray response)
Log.d(TAG, response.toString());

if (response.length() > 0)
// Parsing json
for (int i = 0; i < response.length(); i++)
try

JSONObject obj = response.getJSONObject(i);
ProductData news = new ProductData();

no = obj.getInt(TAG_NO);

news.addId(obj.getString(TAG_ID));
news.addJudul(obj.getString(TAG_JUDUL));

if (obj.getString(TAG_GAMBAR) != "")
news.addGambar(obj.getString(TAG_GAMBAR));


news.addDatetime(obj.getString(TAG_TGL));
news.addIsi(obj.getString(TAG_ISI));

// adding news to news array
newsList.add(news);

if (no > offSet)
offSet = no;

Log.d(TAG, "offSet " + offSet);

catch (JSONException e)
Log.e(TAG, "JSON Parsing error: " + e.getMessage());


// notifying list adapter about data changes
// so that it renders the list view with updated data
adapter.notifyDataSetChanged();


swipe.setRefreshing(false);


, new Response.ErrorListener()

@Override
public void onErrorResponse(VolleyError error)
VolleyLog.d(TAG, "Error: " + error.getMessage());
swipe.setRefreshing(false);

);

// Adding request to request queue
AppController.getInstance().addToRequestQueue(arrReq);












share|improve this question









New contributor




Nilzam yahya putra is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.



















  • Hi and welcome to SO. Please try to elaborate your problem, what is it exactly that you're stuck with. Also, take a moment to properly format your answer so that code can be distinguished from normal text. A well formed question is more likely to be noticed by someone who can answer your question. Hope it helps :)
    – Vijay Chavda
    Nov 10 at 15:56










  • Vijay has good feedback. Also make sure to check out How to Ask and help center for more help.
    – LAD
    Nov 10 at 19:49












up vote
0
down vote

favorite









up vote
0
down vote

favorite











How do I insert data from MySQL into Gridview on Fragments? I've tried it with a coding method used for Activity. I've changed a lot but it's still wrong. This is my coding:



/**
* A simple @link Fragment subclass.
*/
public class Product extends Fragment implements
SwipeRefreshLayout.OnRefreshListener

GridView grid_product;
SwipeRefreshLayout swipe;

List<ProductData> newsList = new ArrayList<ProductData>();

private static final String TAG = Product.class.getSimpleName();

private static String url_list = Server.URL + "news.php?offset=";

private int offSet = 0;

int no;

ProductAdapter adapter;

public static final String TAG_NO = "no";
public static final String TAG_ID = "id";
public static final String TAG_JUDUL = "judul";
public static final String TAG_TGL = "tgl";
public static final String TAG_ISI = "isi";
public static final String TAG_GAMBAR = "gambar";

Handler handler;
Runnable runnable;


public Product()
// Required empty public constructor



@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState)
// Inflate the layout for this fragment
View view = inflater.inflate(R.layout.fragment_product, container, false);
swipe = (SwipeRefreshLayout) view.findViewById(R.id.swipe_refresh_layout);
grid_product = (GridView) view.findViewById(R.id.grid_product);
setProduct();

return view;


private void setProduct()


adapter = new ProductAdapter(getActivity(), newsList);
grid_product.setAdapter(adapter);
grid_product.setOnItemClickListener(new AdapterView.OnItemClickListener()
@Override
public void onItemClick(AdapterView<?> parent, View view, int position, long id)
//pindah activity
startActivity(new Intent(
getActivity(), DetailActivity.class
));


);


I don't know where the mistake is:



 swipe.setOnRefreshListener(this);

swipe.post(new Runnable()
@Override
public void run()
swipe.setRefreshing(true);
newsList.clear();
adapter.notifyDataSetChanged();
callNews(0);


);

grid_product.setOnScrollListener(new AbsListView.OnScrollListener()

private int currentVisibleItemCount;
private int currentScrollState;
private int currentFirstVisibleItem;
private int totalItem;

@Override
public void onScrollStateChanged(AbsListView view, int scrollState)
this.currentScrollState = scrollState;
this.isScrollCompleted();


@Override
public void onScroll(AbsListView view, int firstVisibleItem, int visibleItemCount, int totalItemCount)
this.currentFirstVisibleItem = firstVisibleItem;
this.currentVisibleItemCount = visibleItemCount;
this.totalItem = totalItemCount;


private void isScrollCompleted()
if (totalItem - currentFirstVisibleItem == currentVisibleItemCount
&& this.currentScrollState == SCROLL_STATE_IDLE)

swipe.setRefreshing(true);
handler = new Handler();

runnable = new Runnable()
public void run()
callNews(offSet);

;

handler.postDelayed(runnable, 3000);



);



@Override
public void onRefresh()
newsList.clear();
adapter.notifyDataSetChanged();
callNews(0);



I don't know where the mistake is:



private void callNews(int page)

swipe.setRefreshing(true);

// Creating volley request obj
JsonArrayRequest arrReq = new JsonArrayRequest(url_list + page,
new Response.Listener<JSONArray>()
@Override
public void onResponse(JSONArray response)
Log.d(TAG, response.toString());

if (response.length() > 0)
// Parsing json
for (int i = 0; i < response.length(); i++)
try

JSONObject obj = response.getJSONObject(i);
ProductData news = new ProductData();

no = obj.getInt(TAG_NO);

news.addId(obj.getString(TAG_ID));
news.addJudul(obj.getString(TAG_JUDUL));

if (obj.getString(TAG_GAMBAR) != "")
news.addGambar(obj.getString(TAG_GAMBAR));


news.addDatetime(obj.getString(TAG_TGL));
news.addIsi(obj.getString(TAG_ISI));

// adding news to news array
newsList.add(news);

if (no > offSet)
offSet = no;

Log.d(TAG, "offSet " + offSet);

catch (JSONException e)
Log.e(TAG, "JSON Parsing error: " + e.getMessage());


// notifying list adapter about data changes
// so that it renders the list view with updated data
adapter.notifyDataSetChanged();


swipe.setRefreshing(false);


, new Response.ErrorListener()

@Override
public void onErrorResponse(VolleyError error)
VolleyLog.d(TAG, "Error: " + error.getMessage());
swipe.setRefreshing(false);

);

// Adding request to request queue
AppController.getInstance().addToRequestQueue(arrReq);












share|improve this question









New contributor




Nilzam yahya putra is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.











How do I insert data from MySQL into Gridview on Fragments? I've tried it with a coding method used for Activity. I've changed a lot but it's still wrong. This is my coding:



/**
* A simple @link Fragment subclass.
*/
public class Product extends Fragment implements
SwipeRefreshLayout.OnRefreshListener

GridView grid_product;
SwipeRefreshLayout swipe;

List<ProductData> newsList = new ArrayList<ProductData>();

private static final String TAG = Product.class.getSimpleName();

private static String url_list = Server.URL + "news.php?offset=";

private int offSet = 0;

int no;

ProductAdapter adapter;

public static final String TAG_NO = "no";
public static final String TAG_ID = "id";
public static final String TAG_JUDUL = "judul";
public static final String TAG_TGL = "tgl";
public static final String TAG_ISI = "isi";
public static final String TAG_GAMBAR = "gambar";

Handler handler;
Runnable runnable;


public Product()
// Required empty public constructor



@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState)
// Inflate the layout for this fragment
View view = inflater.inflate(R.layout.fragment_product, container, false);
swipe = (SwipeRefreshLayout) view.findViewById(R.id.swipe_refresh_layout);
grid_product = (GridView) view.findViewById(R.id.grid_product);
setProduct();

return view;


private void setProduct()


adapter = new ProductAdapter(getActivity(), newsList);
grid_product.setAdapter(adapter);
grid_product.setOnItemClickListener(new AdapterView.OnItemClickListener()
@Override
public void onItemClick(AdapterView<?> parent, View view, int position, long id)
//pindah activity
startActivity(new Intent(
getActivity(), DetailActivity.class
));


);


I don't know where the mistake is:



 swipe.setOnRefreshListener(this);

swipe.post(new Runnable()
@Override
public void run()
swipe.setRefreshing(true);
newsList.clear();
adapter.notifyDataSetChanged();
callNews(0);


);

grid_product.setOnScrollListener(new AbsListView.OnScrollListener()

private int currentVisibleItemCount;
private int currentScrollState;
private int currentFirstVisibleItem;
private int totalItem;

@Override
public void onScrollStateChanged(AbsListView view, int scrollState)
this.currentScrollState = scrollState;
this.isScrollCompleted();


@Override
public void onScroll(AbsListView view, int firstVisibleItem, int visibleItemCount, int totalItemCount)
this.currentFirstVisibleItem = firstVisibleItem;
this.currentVisibleItemCount = visibleItemCount;
this.totalItem = totalItemCount;


private void isScrollCompleted()
if (totalItem - currentFirstVisibleItem == currentVisibleItemCount
&& this.currentScrollState == SCROLL_STATE_IDLE)

swipe.setRefreshing(true);
handler = new Handler();

runnable = new Runnable()
public void run()
callNews(offSet);

;

handler.postDelayed(runnable, 3000);



);



@Override
public void onRefresh()
newsList.clear();
adapter.notifyDataSetChanged();
callNews(0);



I don't know where the mistake is:



private void callNews(int page)

swipe.setRefreshing(true);

// Creating volley request obj
JsonArrayRequest arrReq = new JsonArrayRequest(url_list + page,
new Response.Listener<JSONArray>()
@Override
public void onResponse(JSONArray response)
Log.d(TAG, response.toString());

if (response.length() > 0)
// Parsing json
for (int i = 0; i < response.length(); i++)
try

JSONObject obj = response.getJSONObject(i);
ProductData news = new ProductData();

no = obj.getInt(TAG_NO);

news.addId(obj.getString(TAG_ID));
news.addJudul(obj.getString(TAG_JUDUL));

if (obj.getString(TAG_GAMBAR) != "")
news.addGambar(obj.getString(TAG_GAMBAR));


news.addDatetime(obj.getString(TAG_TGL));
news.addIsi(obj.getString(TAG_ISI));

// adding news to news array
newsList.add(news);

if (no > offSet)
offSet = no;

Log.d(TAG, "offSet " + offSet);

catch (JSONException e)
Log.e(TAG, "JSON Parsing error: " + e.getMessage());


// notifying list adapter about data changes
// so that it renders the list view with updated data
adapter.notifyDataSetChanged();


swipe.setRefreshing(false);


, new Response.ErrorListener()

@Override
public void onErrorResponse(VolleyError error)
VolleyLog.d(TAG, "Error: " + error.getMessage());
swipe.setRefreshing(false);

);

// Adding request to request queue
AppController.getInstance().addToRequestQueue(arrReq);









json android-volley






share|improve this question









New contributor




Nilzam yahya putra is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.











share|improve this question









New contributor




Nilzam yahya putra is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









share|improve this question




share|improve this question








edited Nov 10 at 22:47









Daniel Kaparunakis

2,11191626




2,11191626






New contributor




Nilzam yahya putra is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









asked Nov 10 at 14:20









Nilzam yahya putra

1




1




New contributor




Nilzam yahya putra is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.





New contributor





Nilzam yahya putra is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.






Nilzam yahya putra is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.











  • Hi and welcome to SO. Please try to elaborate your problem, what is it exactly that you're stuck with. Also, take a moment to properly format your answer so that code can be distinguished from normal text. A well formed question is more likely to be noticed by someone who can answer your question. Hope it helps :)
    – Vijay Chavda
    Nov 10 at 15:56










  • Vijay has good feedback. Also make sure to check out How to Ask and help center for more help.
    – LAD
    Nov 10 at 19:49
















  • Hi and welcome to SO. Please try to elaborate your problem, what is it exactly that you're stuck with. Also, take a moment to properly format your answer so that code can be distinguished from normal text. A well formed question is more likely to be noticed by someone who can answer your question. Hope it helps :)
    – Vijay Chavda
    Nov 10 at 15:56










  • Vijay has good feedback. Also make sure to check out How to Ask and help center for more help.
    – LAD
    Nov 10 at 19:49















Hi and welcome to SO. Please try to elaborate your problem, what is it exactly that you're stuck with. Also, take a moment to properly format your answer so that code can be distinguished from normal text. A well formed question is more likely to be noticed by someone who can answer your question. Hope it helps :)
– Vijay Chavda
Nov 10 at 15:56




Hi and welcome to SO. Please try to elaborate your problem, what is it exactly that you're stuck with. Also, take a moment to properly format your answer so that code can be distinguished from normal text. A well formed question is more likely to be noticed by someone who can answer your question. Hope it helps :)
– Vijay Chavda
Nov 10 at 15:56












Vijay has good feedback. Also make sure to check out How to Ask and help center for more help.
– LAD
Nov 10 at 19:49




Vijay has good feedback. Also make sure to check out How to Ask and help center for more help.
– LAD
Nov 10 at 19:49

















active

oldest

votes











Your Answer






StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");

StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);






Nilzam yahya putra is a new contributor. Be nice, and check out our Code of Conduct.









 

draft saved


draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53239867%2fd-volley-1-5-onerrorresponse-product%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown






























active

oldest

votes













active

oldest

votes









active

oldest

votes






active

oldest

votes








Nilzam yahya putra is a new contributor. Be nice, and check out our Code of Conduct.









 

draft saved


draft discarded


















Nilzam yahya putra is a new contributor. Be nice, and check out our Code of Conduct.












Nilzam yahya putra is a new contributor. Be nice, and check out our Code of Conduct.











Nilzam yahya putra is a new contributor. Be nice, and check out our Code of Conduct.













 


draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53239867%2fd-volley-1-5-onerrorresponse-product%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







這個網誌中的熱門文章

How to read a connectionString WITH PROVIDER in .NET Core?

In R, how to develop a multiplot heatmap.2 figure showing key labels successfully

Museum of Modern and Contemporary Art of Trento and Rovereto