Airship\Cabin\Bridge\Landing\Admin::manageNotaries PHP Method

manageNotaries() public method

Landing page for the Administrative > Extensions section
public manageNotaries ( )
    public function manageNotaries()
    {
        $this->storeLensVar('active_submenu', ['Admin', 'Extensions']);
        $channels = \Airship\loadJSON(ROOT . '/config/channels.json');
        foreach ($channels as $chanName => $chanConfig) {
            $channels[$chanName]['notaries'] = \Airship\loadJSON(ROOT . '/config/channel_peers/' . $chanName . '.json');
        }
        $post = $this->post(new NotaryFilter());
        if (!empty($post)) {
            if (!empty($post['new_notary_submit'])) {
                $this->addNotary($channels, $post);
            } elseif (!empty($post['delete_notary'])) {
                $this->deleteNotary($channels, $post);
            }
            \Airship\redirect($this->airship_cabin_prefix . '/admin/notaries');
        }
        $this->lens('admin_notaries', ['active_link' => 'bridge-link-admin-ext-notaries', 'channels' => $channels]);
    }