Template:Infobox drug: Difference between revisions

From Anesthesia Wiki
Jump to navigation Jump to search
No edit summary
Tag: Reverted
No edit summary
Tag: Reverted
Line 1: Line 1:
Here is an example of the TemplateData source code for the Infobox drug template:


```
{
{
     "infobox drug": {
     "infobox drug": {
Line 16: Line 14:
                 "label": "Image",
                 "label": "Image",
                 "description": "An image of the drug or its packaging",
                 "description": "An image of the drug or its packaging",
                "type": "string",
                "required": false
            },
            "width": {
                "label": "Width",
                "description": "The width of the image in pixels",
                "type": "number",
                "required": false
            },
            "alt": {
                "label": "Alt text",
                "description": "Alternative text for the image",
                 "type": "string",
                 "type": "string",
                 "required": false
                 "required": false
Line 22: Line 32:
                 "label": "Caption",
                 "label": "Caption",
                 "description": "A brief caption for the image",
                 "description": "A brief caption for the image",
                "type": "string",
                "required": false
            },
            "pronunciation": {
                "label": "Pronunciation",
                "description": "The pronunciation of the drug name",
                 "type": "string",
                 "type": "string",
                 "required": false
                 "required": false
             },
             },
             "tradename": {
             "tradename": {
                 "label": "Trade name(s)",
                 "label": "Trade names",
                 "description": "The brand name(s) of the drug",
                "description": "The brand names of the drug",
                "type": "string",
                "required": false
            },
            "pregnancy_AU": {
                "label": "Pregnancy category (AU)",
                 "description": "The pregnancy category of the drug in Australia",
                "type": "string",
                "required": false
            },
            "pregnancy_US": {
                "label": "Pregnancy category (US)",
                "description": "The pregnancy category of the drug in the United States",
                "type": "string",
                "required": false
            },
            "pregnancy_category": {
                "label": "Pregnancy category",
                "description": "The pregnancy category of the drug",
                "type": "string",
                "required": false
            },
            "legal_AU": {
                "label": "Legal status (AU)",
                "description": "The legal status of the drug in Australia",
                "type": "string",
                "required": false
            },
            "legal_CA": {
                "label": "Legal status (CA)",
                "description": "The legal status of the drug in Canada",
                "type": "string",
                "required": false
            },
            "legal_UK": {
                "label": "Legal status (UK)",
                "description": "The legal status of the drug in the United Kingdom",
                "type": "string",
                "required": false
            },
            "legal_US": {
                "label": "Legal status (US)",
                "description": "The legal status of the drug in the United States",
                 "type": "string",
                 "type": "string",
                 "required": false
                 "required": false
Line 43: Line 101:
                 "required": false
                 "required": false
             },
             },
             "pregnancy_category": {
             "bioavailability": {
                 "label": "Pregnancy category",
                 "label": "Bioavailability",
                 "description": "The pregnancy category of the drug",
                 "description": "The bioavailability of the drug",
                "type": "string",
                "required": false
            },
            "protein_bound": {
                "label": "Protein binding",
                "description": "The protein binding of the drug",
                "type": "string",
                "required": false
            },
            "metabolism": {
                "label": "Metabolism",
                "description": "The metabolism of the drug",
                "type": "string",
                "required": false
            },
            "elimination_half-life": {
                "label": "Elimination half-life",
                "description": "The elimination half-life of the drug",
                "type": "string",
                "required": false
            },
            "excretion": {
                "label": "Excretion",
                "description": "The excretion of the drug",
                "type": "string",
                "required": false
            },
            "CAS_number": {
                "label": "CAS Number",
                "description": "The CAS registry number for the drug",
                 "type": "string",
                 "type": "string",
                 "required": false
                 "required": false
             },
             },
             "ATC_prefix": {
             "ATC_prefix": {
                 "label": "ATC prefix",
                 "label": "ATC code prefix",
                 "description": "The ATC code prefix for the drug",
                 "description": "The ATC code prefix for the drug",
                 "type": "string",
                 "type": "string",
Line 56: Line 144:
             },
             },
             "ATC_suffix": {
             "ATC_suffix": {
                 "label": "ATC suffix",
                 "label": "ATC code suffix",
                 "description": "The ATC code suffix for the drug",
                 "description": "The ATC code suffix for the drug",
                "type": "string",
                "required": false
            },
            "PubChem": {
                "label": "PubChem CID",
                "description": "The PubChem Compound ID for the drug",
                "type": "string",
                "required": false
            },
            "DrugBank": {
                "label": "DrugBank",
                "description": "The DrugBank ID for the drug",
                "type": "string",
                "required": false
            },
            "ChemSpiderID": {
                "label": "ChemSpider ID",
                "description": "The ChemSpider ID for the drug",
                "type": "string",
                "required": false
            },
            "UNII": {
                "label": "UNII",
                "description": "The Unique Ingredient Identifier for the drug",
                "type": "string",
                "required": false
            },
            "KEGG": {
                "label": "KEGG",
                "description": "The KEGG ID for the drug",
                "type": "string",
                "required": false
            },
            "ChEBI": {
                "label": "ChEBI",
                "description": "The ChEBI ID for the drug",
                "type": "string",
                "required": false
            },
            "ChEMBL": {
                "label": "ChEMBL",
                "description": "The ChEMBL ID for the drug",
                "type": "string",
                "required": false
            },
            "chemical_formula": {
                "label": "Chemical formula",
                "description": "The chemical formula of the drug",
                "type": "string",
                "required": false
            },
            "molecular_weight": {
                "label": "Molecular weight",
                "description": "The molecular weight of the drug",
                "type": "string",
                "required": false
            },
            "smiles": {
                "label": "SMILES",
                "description": "The SMILES notation for the drug",
                "type": "string",
                "required": false
            },
            "InChI": {
                "label": "InChI",
                "description": "The InChI identifier for the drug",
                "type": "string",
                "required": false
            },
            "InChIKey": {
                "label": "InChIKey",
                "description": "The InChIKey for the drug",
                 "type": "string",
                 "type": "string",
                 "required": false
                 "required": false
Line 64: Line 224:
     }
     }
}
}
```
This TemplateData source code defines the parameters for the Infobox drug template, including the label, description, type, and required status for each parameter. You can customize this TemplateData source code by adding or removing parameters as needed, and save it as a separate file on your MediaWiki site. Once you have saved this TemplateData file, it will enable users to add and edit the template more easily using a visual editor.

Revision as of 04:30, 13 May 2023

{

   "infobox drug": {
       "label": "Infobox drug",
       "description": "This template is used to display information about a medication.",
       "fields": {
           "drug_name": {
               "label": "Drug name",
               "description": "The name of the drug",
               "type": "string",
               "required": true
           },
           "image": {
               "label": "Image",
               "description": "An image of the drug or its packaging",
               "type": "string",
               "required": false
           },
           "width": {
               "label": "Width",
               "description": "The width of the image in pixels",
               "type": "number",
               "required": false
           },
           "alt": {
               "label": "Alt text",
               "description": "Alternative text for the image",
               "type": "string",
               "required": false
           },
           "caption": {
               "label": "Caption",
               "description": "A brief caption for the image",
               "type": "string",
               "required": false
           },
           "pronunciation": {
               "label": "Pronunciation",
               "description": "The pronunciation of the drug name",
               "type": "string",
               "required": false
           },
           "tradename": {
               "label": "Trade names",
               "description": "The brand names of the drug",
               "type": "string",
               "required": false
           },
           "pregnancy_AU": {
               "label": "Pregnancy category (AU)",
               "description": "The pregnancy category of the drug in Australia",
               "type": "string",
               "required": false
           },
           "pregnancy_US": {
               "label": "Pregnancy category (US)",
               "description": "The pregnancy category of the drug in the United States",
               "type": "string",
               "required": false
           },
           "pregnancy_category": {
               "label": "Pregnancy category",
               "description": "The pregnancy category of the drug",
               "type": "string",
               "required": false
           },
           "legal_AU": {
               "label": "Legal status (AU)",
               "description": "The legal status of the drug in Australia",
               "type": "string",
               "required": false
           },
           "legal_CA": {
               "label": "Legal status (CA)",
               "description": "The legal status of the drug in Canada",
               "type": "string",
               "required": false
           },
           "legal_UK": {
               "label": "Legal status (UK)",
               "description": "The legal status of the drug in the United Kingdom",
               "type": "string",
               "required": false
           },
           "legal_US": {
               "label": "Legal status (US)",
               "description": "The legal status of the drug in the United States",
               "type": "string",
               "required": false
           },
           "legal_status": {
               "label": "Legal status",
               "description": "The legal status of the drug",
               "type": "string",
               "required": false
           },
           "routes_of_administration": {
               "label": "Routes of administration",
               "description": "The routes of administration for the drug",
               "type": "string",
               "required": false
           },
           "bioavailability": {
               "label": "Bioavailability",
               "description": "The bioavailability of the drug",
               "type": "string",
               "required": false
           },
           "protein_bound": {
               "label": "Protein binding",
               "description": "The protein binding of the drug",
               "type": "string",
               "required": false
           },
           "metabolism": {
               "label": "Metabolism",
               "description": "The metabolism of the drug",
               "type": "string",
               "required": false
           },
           "elimination_half-life": {
               "label": "Elimination half-life",
               "description": "The elimination half-life of the drug",
               "type": "string",
               "required": false
           },
           "excretion": {
               "label": "Excretion",
               "description": "The excretion of the drug",
               "type": "string",
               "required": false
           },
           "CAS_number": {
               "label": "CAS Number",
               "description": "The CAS registry number for the drug",
               "type": "string",
               "required": false
           },
           "ATC_prefix": {
               "label": "ATC code prefix",
               "description": "The ATC code prefix for the drug",
               "type": "string",
               "required": false
           },
           "ATC_suffix": {
               "label": "ATC code suffix",
               "description": "The ATC code suffix for the drug",
               "type": "string",
               "required": false
           },
           "PubChem": {
               "label": "PubChem CID",
               "description": "The PubChem Compound ID for the drug",
               "type": "string",
               "required": false
           },
           "DrugBank": {
               "label": "DrugBank",
               "description": "The DrugBank ID for the drug",
               "type": "string",
               "required": false
           },
           "ChemSpiderID": {
               "label": "ChemSpider ID",
               "description": "The ChemSpider ID for the drug",
               "type": "string",
               "required": false
           },
           "UNII": {
               "label": "UNII",
               "description": "The Unique Ingredient Identifier for the drug",
               "type": "string",
               "required": false
           },
           "KEGG": {
               "label": "KEGG",
               "description": "The KEGG ID for the drug",
               "type": "string",
               "required": false
           },
           "ChEBI": {
               "label": "ChEBI",
               "description": "The ChEBI ID for the drug",
               "type": "string",
               "required": false
           },
           "ChEMBL": {
               "label": "ChEMBL",
               "description": "The ChEMBL ID for the drug",
               "type": "string",
               "required": false
           },
           "chemical_formula": {
               "label": "Chemical formula",
               "description": "The chemical formula of the drug",
               "type": "string",
               "required": false
           },
           "molecular_weight": {
               "label": "Molecular weight",
               "description": "The molecular weight of the drug",
               "type": "string",
               "required": false
           },
           "smiles": {
               "label": "SMILES",
               "description": "The SMILES notation for the drug",
               "type": "string",
               "required": false
           },
           "InChI": {
               "label": "InChI",
               "description": "The InChI identifier for the drug",
               "type": "string",
               "required": false
           },
           "InChIKey": {
               "label": "InChIKey",
               "description": "The InChIKey for the drug",
               "type": "string",
               "required": false
           }
       }
   }

}