trithuc-mvc-react 2.6.2 → 2.6.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/api/index.js +1 -1
  2. package/package.json +1 -1
package/api/index.js CHANGED
@@ -132,7 +132,7 @@ export const saveDataToTable = async ({ tableName, data }) => {
132
132
  });
133
133
  return res.data;
134
134
  } else {
135
- if (!data.Id) {
135
+ if (!data.Id || data.Id === "0") {
136
136
  // Khi không có ID, thực hiện POST đến apiUrl
137
137
  const res = await api.post(`${getBaseUrl()}/${apiUrl}/${tableName}`, data);
138
138
  return res.data;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "trithuc-mvc-react",
3
- "version": "2.6.2",
3
+ "version": "2.6.3",
4
4
  "main": "index.js",
5
5
  "scripts": {
6
6
  "test": "echo \"Error: no test specified\" && exit 1"