{
    "idDS":  "Doc_Num",
    "TableRE":  "docCmd\u0026param=CMA",
    "Webformgroup":  null,
    "DS":  "DS_Doc_CMA",
    "Titre":  "Commande achat",
    "id":  "CMA",
    "pieceJoint":  true,
    "TitreOnglet":  null,
    "Drawer":  false,
    "Onglet":  false,
    "SubTitle":  "Commande achat",
    "Detail":  null,
    "TableRE_Detail":  null,
"Config":  {
                    "type":  "div",
                    "class":  "",
                    "buttons": [
                        {
                            "name": "Importer",
                            "style": "flex items-center gap-1 h-8 px-3 text-xs font-medium rounded-md border border-gray-500 text-gray-600 hover:bg-violet-500 hover:border-violet-500 hover:text-white transition",
                            "visible": true,
                            "fonction": "calc",
                            "icon": "fas fa-upload",
                            "dynamicBtn": true
                        },
                        {
                            "name": "Réservation",
                            "style": "flex items-center gap-1 h-8 px-3 text-xs font-medium rounded-md border border-gray-500 text-gray-600 hover:bg-green-500 hover:border-green-500 hover:text-white transition",
                            "visible": true,
                            "fonction": "calc",
                            "dynamicBtn": true
                        },
                        {
                            "name": "Valider",
                            "style": "flex items-center gap-1 h-8 px-3 text-xs font-medium rounded-md border border-gray-500 text-gray-600 hover:bg-green-500 hover:border-green-500 hover:text-white transition",
                            "visible": true,
                            "fonction": "valider",
                            "icon": "fas fa-check",
                            "dynamicBtn": true
                        }
                    ],
                    "children":  [
                                    {
                                        "type":  "div",
                                        "width":  "12",
                                      "children": [
                                        {
                                          "table": "Document",
                                          "champs": "Doc_Num",
                                          "label": "Num",
                                          "type": "Input",
                                          "width": "2"
                                        },
                                        {
                                          "table": "Document",
                                          "champs": "Doc_Date",
                                          "label": "Date",
                                          "type": "date",
                                          "width": "2"
                                        },
                                        {
                                          "table": "Document",
                                          "champs": "Tiers_code",
                                          "label": "Fournisseur",
                                          "type": "search",
                                          "width": "2",
                                          "tableRE_Code": "FOURNISSEUR",
                                          "TableRE_ChampRetour": "Tiers_code",
                                          "TableRE_ChampRetourAffichage": "Tiers_RS"
                                        },
                                        {
                                          "table": "Document",
                                          "champs": "Site_Code",
                                          "label": "Site",
                                          "type": "search",
                                          "width": "2",
                                          "tableRE_Code": "SITES",
                                          "TableRE_ChampRetour": "Site_Code",
                                          "TableRE_ChampRetourAffichage": "Site_Des"
                                        },
                                        {
                                          "table": "Document",
                                          "champs": "Doc_Ref",
                                          "label": "Réf",
                                          "type": "Input",
                                          "width": "2"
                                        },
                                        {
                                          "table": "Document",
                                          "champs": "Devise_Code",
                                          "label": "Devise",
                                          "type": "search",
                                          "width": "2",
                                          "tableRE_Code": "devises",
                                          "TableRE_ChampRetour": "Devise_Code",
                                          "TableRE_ChampRetourAffichage": "Devise_Code"
                                        },
                                        {
                                          "table": "Document",
                                          "champs": "Doc_Devise_Cours",
                                          "label": "Cours",
                                          "type": "Input",
                                          "width": "1"
                                        },
                                        {
                                          "table": "Document",
                                          "champs": "xCMD_urgent",
                                          "label": "Commande Urgent",
                                          "type": "checkbox",
                                          "width": "2"
                                        },
                                        {
                                          "table": "Document",
                                          "champs": "xcommentaire",
                                          "label": "Commentaire",
                                          "type": "textarea",
                                          "width": "3"
                                        },
                                        {
                                          "table": "Document",
                                          "champs": "Doc_Param1",
                                          "label": "Transporteur",
                                          "type": "search",
                                          "width": "2",
                                          "tableRE_Code": "Transporteurs",
                                          "TableRE_ChampRetour": "Tiers_code",
                                          "TableRE_ChampRetourAffichage": "Tiers_RS"
                                        },
                                        {
                                          "table": "Document",
                                          "champs": "Doc_xNature",
                                          "label": "Nature",
                                          "type": "select",
                                          "width": "2",
                                          "param": "natureCMA"
                                        },
                                        {
                                          "table": "Document",
                                          "champs": "Doc_xReappro",
                                          "label": "Réapprovisionnement",
                                          "type": "checkbox",
                                          "width": "2"
                                        },

                                        {
                                          "table": "Document",
                                          "champs": "ModeReg_Code",
                                          "label": "Mode Paiement",
                                          "type": "search",
                                          "width": "2",
                                          "tableRE_Code": "ModeReg",
                                          "TableRE_ChampRetour": "ModeReg_Code",
                                          "TableRE_ChampRetourAffichage": "ModeReg_Libelle"
                                        },
                                        {
                                          "table": "Document",
                                          "champs": "Doc_Valide",
                                          "label": "Statut",
                                          "type": "search",
                                          "width": "2",
                                          "tableRE_Code": "DiverSys\u0026param=cmd",
                                          "TableRE_ChampRetour": "DiverSys_Ordre",
                                          "TableRE_ChampRetourAffichage": "DiverSys_Libelle"
                                        },
                                        {
                                          "type": "table",
                                          "width": "12",
                                          "table": "DocumentD",
                                          "ds": "DocumentD",
                                          "idDS": "DocD_Id",
                                          "children": [
                                            {
                                              "table": "DocumentD",
                                              "champs": "Art_Code",
                                              "label": "Code",
                                              "type": "search",
                                              "width": 100,
                                              "tableRE_Code": "Article",
                                              "TableRE_ChampRetour": "Art_Code",
                                              "TableRE_ChampRetourAffichage": "Art_Code"
                                            },
                                            {
                                              "table": "DocumentD",
                                              "champs": "Art_Des",
                                              "label": "Désignation",
                                              "type": "Input",
                                              "width": 200,
                                              "class": "text-red-500"
                                            },
                                            {
                                              "table": "DocumentD",
                                              "champs": "DocD_PUHTB",
                                              "label": "PrixU Brut Vente",
                                              "type": "decimal",
                                              "width": 90,
                                              "class_wrapper": "bg-[#B4C6E7]"
                                            },
                                            {
                                              "table": "DocumentD",
                                              "champs": "DocD_TxRem1",
                                              "label": "Rem1 %",
                                              "type": "decimal",
                                              "width": 90,
                                              "class_wrapper": "bg-[#B4C6E7]"
                                            },
                                            {
                                              "table": "DocumentD",
                                              "champs": "DocD_TxRem",
                                              "label": "Rem2 %",
                                              "type": "decimal",
                                              "width": 90,
                                              "class_wrapper": "bg-[#B4C6E7]"
                                            },
                                            {
                                              "table": "DocumentD",
                                              "champs": "DocD_PUHTN",
                                              "label": "PrixU Net Vente",
                                              "type": "decimal",
                                              "width": 90,
                                              "class_wrapper": "bg-[#B4C6E7]"
                                            },
                                            {
                                              "table": "DocumentD",
                                              "champs": "DocD_Q",
                                              "label": "Quantité",
                                              "type": "decimal",
                                              "width": 70
                                            },
                                            {
                                              "table": "DocumentD",
                                              "champs": "DocD_THT",
                                              "label": "THT vente",
                                              "type": "decimal",
                                              "width": 90,
                                              "class_wrapper": "bg-[#B4C6E7]"
                                            },
                                            {
                                              "table": "DocumentD",
                                              "champs": "DocD_TxTVA",
                                              "label": "Taux TVA",
                                              "type": "search",
                                              "width": 40,
                                              "tableRE_Code": "TVA"
                                            },
                                            {
                                              "table": "DocumentD",
                                              "champs": "DocD_Unite",
                                              "label": "Unité",
                                              "type": "Input",
                                              "width": 90,
                                              "tableRE_Code": "Unit"
                                            },
                                            {
                                              "table": "DocumentD",
                                              "champs": "XDateLiv",
                                              "label": "Date Liv Souhaité",
                                              "type": "date",
                                              "width": 100
                                            },
                                            {
                                              "table": "DocumentD",
                                              "champs": "xDocD_Four_FraisDivers",
                                              "label": "Fournisseur Frais Divers",
                                              "type": "search",
                                              "width": 100,
                                              "tableRE_Code": "FOURNISSEUR",
                                              "TableRE_ChampRetour": "Tiers_code",
                                              "TableRE_ChampRetourAffichage": "Tiers_RS"
                                            },
                                            {
                                              "table": "DocumentD",
                                              "champs": "xDocD_FraisPort",
                                              "label": "Frais Port",
                                              "type": "decimal",
                                              "width": 100,
                                              "class_wrapper": "bg-[#B4C6E7]"
                                            },
                                            {
                                              "table": "DocumentD",
                                              "champs": "xDocD_RefFour",
                                              "label": "Réference ",
                                              "type": "Input",
                                              "width": 120
                                            },
                                            {
                                              "table": "DocumentD",
                                              "champs": "XInfoAchat",
                                              "label": "Info Achat",
                                              "type": "Input",
                                              "width": 100
                                            },
                                            {
                                              "table": "DocumentD",
                                              "champs": "DocD_xLienDocDId",
                                              "label": "Lien commande",
                                              "type": "Input",
                                              "width": 100
                                            },
                                            {
                                              "table": "DocumentD",
                                              "champs": "XStockReserve",
                                              "label": "Quantité reservée",
                                              "type": "Input",
                                              "width": 100
                                            },
                                            {
                                              "table": "DocumentD",
                                              "champs": "Date_Create",
                                              "label": "Date de création",
                                              "type": "date",
                                              "width": 200,
                                              "readonly": true
                                            },
                                            {
                                              "table": "DocumentD",
                                              "champs": "Date_Modif",
                                              "label": "Date de modification",
                                              "type": "date",
                                              "width": 200,
                                              "readonly": true
                                            }
                                          ]
                                        },
                                        {
                                          "type": "div",
                                          "width": "12",
                                          "class_wrapper": "flex no-wrap overflow-auto",
                                          "table": "Document",
                                          "children": [
                                            {
                                              "table": "Document",
                                              "champs": "Doc_THT",
                                              "label": "Total HT",
                                              "type": "decimal",
                                              "width": 2
                                            },
                                            {
                                              "table": "Document",
                                              "champs": "Doc_TTVA",
                                              "label": "TVA",
                                              "type": "decimal",
                                              "width": 2
                                            },
                                            {
                                              "table": "Document",
                                              "champs": "Doc_TTTC",
                                              "label": "Total TTC",
                                              "type": "decimal",
                                              "width": 2
                                            }
                                          ]
                                        }
                                      ]
                                    }
                                ]
               },
    "Table_Name":  "Document"
}
