{"id":21660216,"url":"https://github.com/slub/mahu_partners","last_synced_at":"2025-03-20T05:25:29.040Z","repository":{"id":41279291,"uuid":"438661502","full_name":"slub/mahu_partners","owner":"slub","description":null,"archived":false,"fork":false,"pushed_at":"2021-12-23T15:50:19.000Z","size":586,"stargazers_count":1,"open_issues_count":1,"forks_count":1,"subscribers_count":8,"default_branch":"main","last_synced_at":"2025-01-25T07:09:01.537Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/slub.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-12-15T14:36:08.000Z","updated_at":"2024-04-17T19:45:01.000Z","dependencies_parsed_at":"2022-09-21T01:10:57.823Z","dependency_job_id":null,"html_url":"https://github.com/slub/mahu_partners","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slub%2Fmahu_partners","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slub%2Fmahu_partners/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slub%2Fmahu_partners/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slub%2Fmahu_partners/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/slub","download_url":"https://codeload.github.com/slub/mahu_partners/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244555952,"owners_count":20471535,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-25T09:32:30.270Z","updated_at":"2025-03-20T05:25:29.018Z","avatar_url":"https://github.com/slub.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# TYPO3 extension `mahu_partners`\n\nThe extension `mahu_partners` offers the domain model for companies / institutes and regulations used in the [Material Hub](https://www.materialhub.de). In addition, it provides listings, search functionality and detail pages for both entities. \n\nFurthermore, the extension comes with a frontend editor for company / institute records. In this regard, each Company record is associated with the user that created it. A listing of the records created by the currently logged in user is a further feature of this extension.\n\nIn addition there is a simple file management per Company record. To this end, the extension offers a listing of files in the directory associated with the Company and allows to upload new files, respectively, delete existing ones.\n\n## Development\n\nAll Material Hub extension are shipped with a [grunt](https://gruntjs.com/) configuration \\(requires [Node.js](https://nodejs.org/en/)\\). This ensures that during development the files from /Resources/Private/Css and /Resources/Private/JavaScript are copied to /Resources/Public as soon as changes occur. For this purpose, the command `grunt` must be executed in the root directory of the respective project via the console. Before committing to git, it is recommended to automatically generate a \"production version\" with the command `grunt buildProd`, where minified files are stored in the /Resources/Public folder.\n\n## Usage\n\n### Setup\n\n- Add the plugin as a content element and select a view mode in the plugin options. Available modes are described below.\n- Include the static TypoScript \"Mahu Frontend partners extension\".\n- Configure the extension via TypoScript.\n    - a complete list of options can be found [below](#typoScript-configuration-options)\n    - set the `plugin.tx_mahupartners.persistence.storagePid` to the folders containing relevant records\n\n\n### Plugin modes\nOnce the plugin is added as a content element, one of the plugin modes can be selected via flexform:\n\n| Mode | Description |\n| ---- | ----------- |\n| Partner | Search functionality and detail pages for companies / institutes|\n| Partnerliste für Nutzer | Lists the companies / institutes created by the current user |\n| Partner Editieransicht | Frontend editor for companies / institutes |\n| Regulations | Search functionality and detail pages for regulations |\n| Neueste Partner | Lists Company records. |\n| Dateien | Simple file management per Company (list, add, remove). |\n\n\n## TypoScript Configuration Options\n\nTo configure this extension, the following settings are supported as part of the array `plugin.tx_mahupartners.settings` of the TypoScript setup configuration.\n\n- `showLogos` (defaults to true): Indicates whether logos of companies / institutes should be displayed in certain views.\n- `prefix` (defaults to tx_mahupartners_mahupartners): The prefix used for URL generation of \"show materials of partner XY\" and \"show corresponding materials\" links.\n- `regulationSearchPageID`: Id of the regulation search page\n- `partnerSearchPageID`: Id of the company / institute search page\n- `dataproviderPageID`: Id of the data provider area page\n- `orgaDescriptionPageID`: Id of the organization description page\n- `orgaDescriptionPreviewPageID`: Id of the company / institute preview page\n- `materialEditorPageID`: Id of the Material Editor page\n- `contactPageID`: Id of the contact page\n- `uploadPageID`: Id of the page that allows users to upload files.\n- `materialSearchPageID`: Id of the materials search page\n\n### Settings for file management\n\nWhen creating or editing a new company / institute record, a logo file can be uploaded. In addition, users can upload files like material descriptions. Such files are stored in a Company-specific folder. The storage and parent folder of those directories can, amongst other settings, be configured as follows:\n\n- `imageUpload`\n    - `path` (defaults to /user_upload/): the parent directory of user folders\n    - `storage` (defaults to 1): the storage in which the defined path exists\n    - `siteURL`: the root site's URL, e.g. https://www.example.org/\n- `dateFormat` (defaults to d.m.Y H:i): configures how dates are formatted in the Company files list\n\n\n### Paging\n\nThe search UI supports results paging (relevant for the plugin modes \"Partner\" and \"Regulations\") that can be configured using the `paging` array with a structure as follows:\n\n- `paging`\n    - `perPage` (integer, defaults to 20): number of results per page\n    - `maximumPerPage` (integer, defaults to 1000): the maximum number of results to fetch from the data base\n    - `detailPagePaging` (boolean, defaults to 1): if set to 1 this enables paging between detail pages\n    - `menu`: an array of results per page options to be shown in a drop-down menu in the search UI.\n\n\nDefault settings and example:\n\n```\n\tpaging {\n\t\tperPage = 20\n\t\tmaximumPerPage = 1000\n\t\tdetailPagePaging = 1\n\t\tmenu {\n\t\t\t0 = 5\n\t\t\t1 = 10\n\t\t\t2 = 20\n\t\t\t3 = 50\n\t\t\t4 = 100\n\t\t}\n\t}\n```\n\n### Sorting\n\nResult sorting (relevant for the plugin modes \"Partner\" and \"Regulations\") can be influenced using the arrays `sort` and `sortOptions`.\n\n- `sort`: An array with items of the following structure:\n    - `id`: the ID of that sort option\n    - `sortCriteria`: the actual sort configuration consisting of a property name and the sort order (either \"asc\" or \"desc\")\n- `sortOptions`: UI-related settings\n    - `menu`: an array that defines the sort options (see `sort`) to appear in a drop down list in the search UI\n    - `selected`: Defines the sort option that is initially selected in the drop down list\n\nDefault settings and example:\n\n```\n\tsort {\n\t\t0 {\n\t\t\tid = nameAsc\n\t\t\tsortCriteria = name asc\n\t\t}\n\t\t1 {\n\t\t\tid = nameDesc\n\t\t\tsortCriteria = name desc\n\t\t}\n\t}\n\tsortOptions {\n\t\tmenu {\n\t\t\t0 = nameAsc\n\t\t\t1 = nameDesc\n\t\t}\n\t\tselected = nameAsc\n\t}\n```\n\n\n### E-mail notifications\nThe extension allows to send e-mail notifications when organization records have been created or removed via the frontend editor (relevant for plugin mode \"Partner Editieransicht\"), and in case files for a organization are uploaded or removed.\n\n- `notification`:  An array with separate child arrays for each event type (currently `add`, `remove`, `fileadd`, and `fileremove`). Each of them supports these settings:\n    - `enabled` (boolean, defaults to 0): enable or disable notifications for this event\n    - `sender` (e-mail address): the e-mail address of the sender\n    - `senderName`: the name of the sender\n    - `to` (e-mail address): the e-mail address of the receiver\n    - `toName`: the name of the receiver\n\nExample:\n\n```\n\tnotification {\n\t\tadd {\n\t\t\tenabled = 1\n\t\t\tsender = sender@example.org\n\t\t\tsenderName = Sender\n\t\t\tto = receiver@example.com\n\t\t\ttoName = Receiver\n\t\t}\n\t\tedit {\n\t\t\tenabled = 1\n\t\t\tsender = sender@example.org\n\t\t\tsenderName = Sender\n\t\t\tto = receiver@example.com\n\t\t\ttoName = Receiver\n\t\t}\n\t}\n```\n\n### Company listing\n\n- `companyList`: configures the plugin mode \"Neueste Partner\" according to these settings:\n    - `number` (integer, defaults to 6): the maximum number of Companies shown\n    - `mode` (string, defaults to random): defines the listing mode. Valid modes are: random, latest\n    \n### Shared variables\n\nFurthermore, the extension relies on certain **variables**, shared with the extension `mahu_frontend`, existing in the `lib` data structure.\n\n- language settings\n     - `lib.currentLangID`: the ID of the current language\n     - `lib.currentLang`:  the name/code if the current language\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fslub%2Fmahu_partners","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fslub%2Fmahu_partners","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fslub%2Fmahu_partners/lists"}