eleven-solutions-common-website-unique-web 6.0.6 → 6.0.7
Sign up to get free protection for your applications and to get access to all the features.
@@ -253,6 +253,11 @@ const TaxonomyForm = () => {
|
|
253
253
|
console.error("Error deleting Taxonomy:", error);
|
254
254
|
}
|
255
255
|
});
|
256
|
+
useEffect(() => {
|
257
|
+
similarTaxonomies.forEach((taxonomy) => {
|
258
|
+
console.log("Parent ID:", taxonomy.parentId);
|
259
|
+
});
|
260
|
+
}, [similarTaxonomies]);
|
256
261
|
return (_jsxs("div", { className: `${isEditMode && isMultiple ? "w-full" : "max-w-4xl"} p-6 mx-auto dark:bg-gray-800`, children: [_jsxs("div", { className: `transition duration-300 ${isModalOpen ? "filter blur-sm" : ""}`, children: [_jsx("h1", { className: "text-3xl font-bold text-center text-blue-600 capitalize dark:text-white mb-4", children: isEditMode ? "Edit Taxonomy" : "Add Taxonomy" }), _jsx("h1", { className: "text-2xl text-blue-600 capitalize dark:text-white mb-4", children: isEditMode ? `Taxonomy Type: ${type}` : "" }), !isMultiple && (_jsxs("form", { children: [!isEditMode && (_jsxs("div", { className: "mb-6 w-full", children: [_jsxs("label", { className: "text-gray-900 dark:text-gray-200 font-semibold", children: ["Type ", _jsx("span", { className: "text-red-500", children: "*" })] }), _jsx("input", { required: true, value: inputType, onChange: (e) => setInputType(e.target.value), type: "text", className: "w-full px-4 py-2 mt-2 text-gray-800 bg-white border border-gray-400 rounded-md dark:bg-gray-800 dark:text-gray-300 dark:border-gray-800 focus:border-blue-400 focus:ring-blue-300 focus:ring-opacity-40 dark:focus:border-blue-300 focus:outline-none focus:ring", placeholder: "Enter Type" })] })), _jsxs("div", { className: "mb-6 w-full", children: [_jsxs("label", { className: "text-gray-900 dark:text-gray-200 font-semibold", children: ["Code ", _jsx("span", { className: "text-red-500", children: "*" })] }), _jsx("input", { required: true, value: code, onChange: (e) => setCode(e.target.value === "" ? "" : Number(e.target.value)), type: "number", className: "w-full px-4 py-2 mt-2 text-gray-800 bg-white border border-gray-400 rounded-md dark:bg-gray-800 dark:text-gray-300 dark:border-gray-800 focus:border-blue-400 focus:ring-blue-300 focus:ring-opacity-40 dark:focus:border-blue-300 focus:outline-none focus:ring", placeholder: "Enter Code", disabled: similarTaxonomies.some((taxonomy) => taxonomy.isEdit === false) })] }), _jsxs("div", { className: "mb-6 w-full", children: [_jsxs("label", { className: "text-gray-900 dark:text-gray-200 font-semibold", children: ["Value ", _jsx("span", { className: "text-red-500", children: "*" })] }), _jsx("input", { required: true, value: value, onChange: (e) => setValue(e.target.value), type: "text", className: "w-full px-4 py-2 mt-2 text-gray-800 bg-white border border-gray-400 rounded-md dark:bg-gray-800 dark:text-gray-300 dark:border-gray-800 focus:border-blue-400 focus:ring-blue-300 focus:ring-opacity-40 dark:focus:border-blue-300 focus:outline-none focus:ring", placeholder: "Enter Value", disabled: similarTaxonomies.some((taxonomy) => taxonomy.isEdit === false) })] }), _jsxs("div", { className: "flex space-x-4 mt-6 justify-between", children: [_jsx("div", { children: isEditMode && (_jsx("div", { children: similarTaxonomies.some((taxonomy) => taxonomy.isEdit) && (_jsx("button", { type: "button", onClick: () => {
|
257
262
|
handleDeleteClick(id);
|
258
263
|
window.location.href = "/admin/taxinomies";
|
package/package.json
CHANGED
@@ -318,6 +318,12 @@ const TaxonomyForm = () => {
|
|
318
318
|
}
|
319
319
|
};
|
320
320
|
|
321
|
+
useEffect(() => {
|
322
|
+
similarTaxonomies.forEach((taxonomy) => {
|
323
|
+
console.log("Parent ID:", taxonomy.parentId);
|
324
|
+
});
|
325
|
+
}, [similarTaxonomies]);
|
326
|
+
|
321
327
|
return (
|
322
328
|
<div
|
323
329
|
className={`${
|