Skip to content

Commit

Permalink
based on latest skeleton
Browse files Browse the repository at this point in the history
  • Loading branch information
Praesidiarius committed Jan 18, 2020
0 parents commit 2c2f1a5
Show file tree
Hide file tree
Showing 22 changed files with 1,207 additions and 0 deletions.
12 changes: 12 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
.vagrant/
.idea/
vendor/
config/development.config.php
public/themes/vuze
public/themes/ablepro
data/cache/*
!data/cache/.gitkeep
phpunit.xml
composer.lock
.phpunit.result.cache
docs/html/
42 changes: 42 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
language: php

cache:
directories:
- $HOME/.composer/cache

env:
global:
- COMPOSER_ARGS="--no-interaction"
- COVERAGE_DEPS="php-coveralls/php-coveralls"

matrix:
fast_finish: true
include:
- php: 7.2
env:
- DEPS=lowest
- php: 7.2
env:
- DEPS=latest
- CS_CHECK=true

before_install:
- if [[ $TEST_COVERAGE != 'true' ]]; then phpenv config-rm xdebug.ini || return 0 ; fi

install:
- travis_retry composer install $COMPOSER_ARGS --ignore-platform-reqs
- if [[ $LEGACY_DEPS != '' ]]; then travis_retry composer update $COMPOSER_ARGS --with-dependencies $LEGACY_DEPS ; fi
- if [[ $DEPS == 'latest' ]]; then travis_retry composer update $COMPOSER_ARGS ; fi
- if [[ $DEPS == 'lowest' ]]; then travis_retry composer update --prefer-lowest --prefer-stable $COMPOSER_ARGS ; fi
- if [[ $TEST_COVERAGE == 'true' ]]; then travis_retry composer require --dev $COMPOSER_ARGS $COVERAGE_DEPS ; fi
- stty cols 120 && composer show

script:
- if [[ $TEST_COVERAGE == 'true' ]]; then composer test-coverage ; else composer test ; fi
- if [[ $CS_CHECK == 'true' ]]; then composer cs-check ; fi

after_script:
- if [[ $TEST_COVERAGE == 'true' ]]; then vendor/bin/php-coveralls -v ; fi

notifications:
email: false
25 changes: 25 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Changelog

All notable changes to this project will be documented in this file, in reverse chronological order by release.

## 1.0.0 - TBD

### Added

- Its a composer package now

### Changed

- 100% of 0.9.x Codebase

### Deprecated

- 100% of 0.9.x Codebase

### Removed

- 100% of 0.9.x Codebase

### Fixed

- Removed dependencies
2 changes: 2 additions & 0 deletions COPYRIGHT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Copyright (c) 2019-2020, Verein onePlace
All rights reserved. (https://1plc.ch/)
27 changes: 27 additions & 0 deletions LICENSE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
Copyright (c) 2019-2020, Verein onePlace
All rights reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:

- Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.

- Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.

- Neither the name of Verein onePlace nor the names of its contributors may
be used to endorse or promote products derived from this software without
specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
40 changes: 40 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
# oneplace-contact

[![Build Status](https://travis-ci.com/OnePlc/PLC_X_Contact.svg?branch=master)](https://travis-ci.com/OnePlc/PLC_X_Contact)
[![Coverage Status](https://coveralls.io/repos/github/OnePlc/PLC_X_Contact/badge.svg?branch=master)](https://coveralls.io/github/OnePlc/PLC_X_Contact?branch=master)

## Introduction

This is the Contact Module for onePlace Software Framework based on Laminas Project (former Zend Framework)

Create your web based apps on the fly! onePlace brings you extended Entity and Table Models,
View Helpers and much more - so you can build your Webapp to manage database based data,
in almost any layout you can image.

onePlace is built for maximum freedom of choice for your app, and so only small
parts of laminas mvc are utilized. a lot is done from scratch to give you more freedom / customization.

## Contact Module

This contact module is a starting point for your own onePlace modules.
It expands on [oneplace-core](https://github.com/OnePlc/PLC_X_Core) and uses the onePlace / Laminas MVC layer and module systems.

## Installation

Copy files to webserver

Init database

Update config files

first login with admin

## Getting started

how to utilize user manager

how to create own modules

## Documentation

Documentation will be extended soon.
50 changes: 50 additions & 0 deletions composer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
{
"name": "oneplace/oneplace-contact",
"description": "onePlace Contact Module",
"type": "oneplace-module",
"license": "BSD-3-Clause",
"keywords": [
"laminas",
"mvc",
"contact",
"oneplace",
"framework"
],
"require-dev": {
"phpunit/phpunit": "^8",
"oneplace/oneplace-core": "^1.0.0",
"laminas/laminas-test": "^3.3.0"
},
"require": {
"php": "^7.1",
"oneplace/oneplace-core": "^1.0.0"
},
"autoload": {
"psr-4": {
"OnePlace\\Contact\\": "src/"
}
},
"autoload-dev": {
"psr-4": {
"OnePlaceTest\\Contact\\": "test/"
}
},
"scripts": {
"cs-check": "phpcs",
"cs-fix": "phpcbf",
"development-disable": "laminas-development-mode disable",
"development-enable": "laminas-development-mode enable",
"development-status": "laminas-development-mode status",
"post-create-project-cmd": [
"@development-enable",
"php -r '$file = file_get_contents(\".gitignore\"); $file = str_replace(\"composer.lock\", \"\", $file); file_put_contents(\".gitignore\", $file);'"
],
"serve": "php -S 0.0.0.0:8080 -t public",
"test": "phpunit"
},
"extra": {
"zf": {
"module": "OnePlace\\Contact"
}
}
}
64 changes: 64 additions & 0 deletions config/module.config.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
<?php
/**
* module.config.php - Contact Config
*
* Main Config File for Contact Module
*
* @category Config
* @package Contact
* @author Verein onePlace
* @copyright (C) 2020 Verein onePlace <[email protected]>
* @license https://opensource.org/licenses/BSD-3-Clause
* @version 1.0.0
* @since 1.0.0
*/

namespace OnePlace\Contact;

use Laminas\Router\Http\Literal;
use Laminas\Router\Http\Segment;
use Laminas\ServiceManager\Factory\InvokableFactory;

return [
# Contact Module - Routes
'router' => [
'routes' => [
# Module Basic Route
'contact' => [
'type' => Segment::class,
'options' => [
'route' => '/contact[/:action[/:id]]',
'constraints' => [
'action' => '[a-zA-Z][a-zA-Z0-9_-]*',
'id' => '[0-9]+',
],
'defaults' => [
'controller' => Controller\ContactController::class,
'action' => 'index',
],
],
],
'contact-api' => [
'type' => Segment::class,
'options' => [
'route' => '/contact/api[/:action[/:id]]',
'constraints' => [
'action' => '[a-zA-Z][a-zA-Z0-9_-]*',
'id' => '[0-9]+',
],
'defaults' => [
'controller' => Controller\ApiController::class,
'action' => 'index',
],
],
],
],
],

# View Settings
'view_manager' => [
'template_path_stack' => [
'contact' => __DIR__ . '/../view',
],
],
];
Empty file added docs/book/index.md
Empty file.
15 changes: 15 additions & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
docs_dir: docs/book
site_dir: docs/html
nav:
- Home: index.md
- Introduction: intro.md
- 'Quick Start': quick-start.md
- Reference:
- 'Dynamic Fields': dynamic-fields.md
- Examples: examples.md
site_name: oneplace-contact
site_description: "onePlace Application Contact Module"
repo_url: 'https://github.com/OnePlc/PLC_X_Contact'
theme: readthedocs
extra:
project: onePlc
13 changes: 13 additions & 0 deletions phpunit.xml.dist
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit colors="true">
<testsuites>
<testsuite name="Contact Module Test Suite">
<directory>./test</directory>
</testsuite>
</testsuites>
<filter>
<whitelist addUncoveredFilesFromWhitelist="true">
<directory suffix=".php">./src</directory>
</whitelist>
</filter>
</phpunit>
Loading

0 comments on commit 2c2f1a5

Please sign in to comment.