Merge pull request #417 from nextcloud/readme

Add a nice readme! :)
This commit is contained in:
Jan C. Borchardt 2020-05-27 00:17:11 +02:00 committed by GitHub
commit 4fcc8e5be2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 32 additions and 71 deletions

View file

@ -1,83 +1,40 @@
# Nextcloud Forms # Nextcloud Forms
![Downloads](https://img.shields.io/github/downloads/nextcloud/forms/total.svg?style=flat-square) ![Downloads](https://img.shields.io/github/downloads/nextcloud/forms/total.svg?style=flat-square)
[![Code coverage](https://img.shields.io/codecov/c/github/nextcloud/forms.svg?style=flat-square)](https://codecov.io/gh/nextcloud/forms/) [![Code coverage](https://img.shields.io/codecov/c/github/nextcloud/forms.svg?style=flat-square)](https://codecov.io/gh/nextcloud/forms/)
[![Dependabot status](https://img.shields.io/badge/Dependabot-enabled-brightgreen.svg?longCache=true&style=flat-square&logo=dependabot)](https://dependabot.com) [![Dependabot status](https://img.shields.io/badge/Dependabot-enabled-brightgreen.svg?longCache=true&style=flat-square&logo=dependabot)](https://dependabot.com)
[![Start contributing](https://img.shields.io/github/issues/nextcloud/forms/good%20first%20issue?color=7057ff&label=Contribute)](https://github.com/nextcloud/forms/issues?q=is%3Aissue+is%3Aopen+sort%3Aupdated-desc+label%3A%22good+first+issue%22)
Forms allows the creation of shareable forms, with multiple question types and privacy settings. **📝 Simple surveys and questionnaires, self-hosted**
![](img/screenshots/forms1.png)
- **📝 Simple design:** No mass of options, only the essentials. Works well on mobile of course.
- **💾 Export results:** Results can be exported as CSV in the same format used by Google Forms.
- **🙋 Get involved!** We have lots of stuff planned like more question types, collaboration on forms, [and much more](https://github.com/nextcloud/forms/milestones)!
**Note**: This app is tested with Apache2 webserver, MySQL database, and apt-get package manager. To use alternatives, replace the relevant commands with those of your technology. This document assumes that a working ## 🏗 Development setup
NextCloud development environment has been installed. See https://docs.nextcloud.com/server/stable/developer_manual/general/devenv.html for help with this.
## Build the app 1. ☁ Clone this app into the `apps` folder of your Nextcloud: `git clone https://github.com/nextcloud/forms.git`
2. 👩‍💻 In the folder of the app, run the command `npm ci && npm run dev` to install dependencies and build the Javascript.
3. ✅ Enable the app through the app management of your Nextcloud
4. 🎉 Partytime! Help fix [some issues](https://github.com/nextcloud/forms/issues) and [review pull requests](https://github.com/nextcloud/forms/pulls) 👍
``` bash
# set up and build for production
make
# install dependencies ### 🧙 Advanced development stuff
make dev-setup
# build for dev and watch changes To build the Javascript whenever you make changes, you can also use `npm run build`. Or `npm run watch` to automatically rebuild on every file save.
make watch-js
# build for dev You run all tests by using `make test`.
make build-js
# build for production with minification
make build-js-production
``` ## ♥ How to create a pull request
## Running tests
You can use the provided Makefile to run all tests by using:
_ps: only works if you're using php locally and have forms installed info your apps default folder_ This guide will help you get started:
- 💃 [Opening a pull request](https://opensource.guide/how-to-contribute/#opening-a-pull-request)
```
make test
```
## :v: Code of conduct ## ✌ Code of conduct
The Nextcloud community has core values that are shared between all members during conferences,
hackweeks and on all interactions in online platforms including [Github](https://github.com/nextcloud) and [Forums](https://help.nextcloud.com).
If you contribute, participate or interact with this community, please respect [our shared values](https://nextcloud.com/code-of-conduct/). :relieved:
## :heart: How to create a pull request
This guide will help you get started:
- :dancer: :smile: [Opening a pull request](https://opensource.guide/how-to-contribute/#opening-a-pull-request)
## Code Overview
The following are the most important code files for development of the Forms App.
**Note**: all paths are relative to nextcloud/apps/forms/
- **lib/Controller/apiController.php**: The main API of the application. The functions defined in this file are called from http requests, and interface with the database
- **lib/Controller/pageController.php**: Passes objects between screens
- **lib/Db/**: All the files where database entities are defined and SQL queries are written. Mapper files define functions that retrieve data from the database
- **src/js/**
- **Main.js**: where Vue app is created
- **App.vue**: The root component for the vue app
- **Router.js**: Defines URLs that can be navigated to from the Vue app
- **src/js/components/**
- **formsListItem.vue**: Defines the list items (created surveys) within the forms app home page
- **quizFormItem.vue**: Questions (for any survey) are defined as a quizFormItem here
- **src/js/views/**
- **Create.vue**: File where survey creation page is handled
- **List.vue**: File where list of created surveys is handled (located on the forms app home page)
- **Results.vue**: File where page that displays survey results is handled
- **appinfo/routes.php**: Defines server endpoints that can be accessed by the client
- **/js/vote.js**: File that contains the logic for the response page and responding to a form
- **/css/vote.scss**: File that contains CSS formatting for the response page
- **/templates/vote.tmpl.php**: File that contains the form template that is dynamically populated by the database
The Nextcloud community has core values that are shared between all members during conferences, hackweeks and on all interactions in online platforms including [Github](https://github.com/nextcloud) and [forums](https://help.nextcloud.com). If you contribute, participate or interact with this community, please respect [our shared values](https://nextcloud.com/code-of-conduct/). 😌

View file

@ -3,14 +3,20 @@
xsi:noNamespaceSchemaLocation="https://apps.nextcloud.com/schema/apps/info.xsd"> xsi:noNamespaceSchemaLocation="https://apps.nextcloud.com/schema/apps/info.xsd">
<id>forms</id> <id>forms</id>
<name>Forms</name> <name>Forms</name>
<summary>A forms app, similar to Google Forms.</summary> <summary>📝 Simple surveys and questionnaires, self-hosted</summary>
<description>A forms app, similar to Google Forms with the possibility to restrict access (members, certain groups/users, and public).</description> <description><![CDATA[**Simple surveys and questionnaires, self-hosted!**
- **📝 Simple design:** No mass of options, only the essentials. Works well on mobile of course.
- **💾 Export results:** Results can be exported as CSV in the same format used by Google Forms.
- **🙋 Get involved!** We have lots of stuff planned like more question types, collaboration on forms, [and much more](https://github.com/nextcloud/forms/milestones)!
]]></description>
<version>2.0.0-beta2</version> <version>2.0.0-beta2</version>
<licence>agpl</licence> <licence>agpl</licence>
<author>Affan Hussain</author> <author>Affan Hussain</author>
<author>Ajfar Huq</author> <author>Ajfar Huq</author>
<author>Inigo Jiron</author> <author>Inigo Jiron</author>
<author>Jan C. Borchardt</author>
<author>John Molakvoæ</author> <author>John Molakvoæ</author>
<author>Jonas Rittershofer</author> <author>Jonas Rittershofer</author>
<author>Kai Schröer</author> <author>Kai Schröer</author>
@ -33,10 +39,8 @@
<admin>https://github.com/nextcloud/forms/blob/master/README.md</admin> <admin>https://github.com/nextcloud/forms/blob/master/README.md</admin>
</documentation> </documentation>
<screenshot>https://raw.githubusercontent.com/nextcloud/forms/master/screenshots/Create.PNG</screenshot> <screenshot>https://raw.githubusercontent.com/nextcloud/forms/master/screenshots/forms1.png</screenshot>
<screenshot>https://raw.githubusercontent.com/nextcloud/forms/master/screenshots/List.PNG</screenshot> <screenshot>https://raw.githubusercontent.com/nextcloud/forms/master/screenshots/forms2.png</screenshot>
<screenshot>https://raw.githubusercontent.com/nextcloud/forms/master/screenshots/Vote.PNG</screenshot>
<screenshot>https://raw.githubusercontent.com/nextcloud/forms/master/screenshots/Results.PNG</screenshot>
<dependencies> <dependencies>
<nextcloud min-version="17" max-version="20" /> <nextcloud min-version="17" max-version="20" />

BIN
img/screenshots/forms1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 110 KiB

BIN
img/screenshots/forms2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB