npm package: @startinblox/component-subscription
Description: Subscription component for startinblox
Author: startinblox
Latest version: 1.0.8

# SOLID subscription

## Introduction
Here is an online share subscription component in order to mutualize development costs, empower cooperatives on the management of their membership.

The objective is to make available to all interested cooperatives an open source tool ready, inexpensive, compliant with regulations (Thanks [Finacoop](https://www.finacoop.fr/)) and easy to implement on an already existing interface with possibilities of evolution towards bespoke needs. Any interested cooperative is free to take over the code and adapt it to its uses without any endorsement from Startin'blox in accordance with the MIT license.

Moreover, keep in mind that Startin'blox produce datas based on Solid standard and allow you to reuse those datas any were.

What you can see here is where we are now. We've done most of the job. If you want to propose an evolution or improvement for your uses, please contact us. We'll be glad to discuss !

### What does it look like ?
It’s composed of 4 step: https://startinblox.com/fr/cooperative
1. Prior information
2. Entering your personal information
3. Reading and acceptance of pre-contractual documents
4. Choice of subscription amount and payment

#### Prior informations
 * Who can be shareholder ? 
 * What are the risks ? 
 * How much share can I take ? 

It’s a good place to put your relevant FAQ. 

On this page, I must join 
 * your status
 * a complete document of your prior information.
 * A legal policy for the datas you’re going to ask

:warning: **For the prior information document**: You can get inspired by our document but we recommend you to validate it by a professional.

:warning: **For legal policy**: You can get inspired by ours but we strongly invite you to have a look to the [CNIL recommendation](https://www.cnil.fr/fr/rgpd-par-ou-commencer) here in French.

![<Screen1>](/doc_img/screen1.png)

#### Entering your personal information
It just consiste in a form which will be different if the future shareholder is a moral or a physical person

:warning: On this step, you ask the subscriber to get you informed on any email changing and to allow you to communicate to him with this email on any shareholder’s event.

![<Screen2>](/doc_img/screen2.png)

#### Reading and acceptance of pre-contractual documents
Here we provide again status and previous information ans we ask the subscriber if he has read all the document, the modalities of acceptance of the share issue.

:warning: **The cooperative exception** : This case here is developed in relation to the use case of Startin'blox which benefits from the cooperative exception. If this is not your case, please contact an advisor.

Accoding to the coopérative exception, we demand the subscriber to certify that his subscription of social shares takes place on the occasion of the provision of services by the cooperative and to confirm that he is subscribing as a beneficiary of the services of the Cooperative.

![<Screen3>](/doc_img/screen3.png)

#### Choice of subscription amount and payment

Here you should give detail about the amount of your share and any relevant informations about it. It's the screen were people choose how much they want.

![<Screen4>](/doc_img/screen4.png)

For now, we still not have a way to pay online. But it's coming and it can come sooner with your help ! (Have look to our issues)
On this page you should give a like to your bank statement.

![<Screen5>](/doc_img/screen5.png)

#### Finalisation

The last step is to upload a identity document. We have choosen to set the step at the end to make the subscription easier. For now, if the ID is missing, we relaunch manually.

![<Screen6>](/doc_img/screen6.png)

It's the time to say thanks and welcome to your new subscriber :)
A mail will be automatically send to him to confirme the reception of his informations.

#### FAQ

**Can we do without the handwritten signature?**
It may depend on the statutes of each coop. For example, it would not be possible for cooperatives whose statutes expressly mention "a hand-signed subscription form" or other binding mentions of the same kind.

**Does the subscription form have to be delivered in paper format?**
According to the Commercial Code, a subscription form is a document containing a certain amount of information but not necessarily a paper.

**In status of my cooperative, it is noted "Any subscription of shares gives rise to the signature of a subscription form in two originals by the associate", how does this manifest itself when switching to digital format?**
You would need for example 2 pdf or 2 mails (of the same content, but could be labeled "original 1/2" and "original 2/2") to sign/click. This will be the subject of a future evolution.


If you want to know more about how we manage the process with the actual tool or if you have any question to add to this faq, please contact us!

alice@statinblox.com



## Technical documentation

### Create your data source

First you should install the server which is going to welcome you subscriber datas sources.
You'll will find the documentation on [how to set a server in our documentation](https://docs.startinblox.com/import_documentation/get-started.html).

Once done, add in your package.yml [the `djangoldp_subscription` package](https://git.startinblox.com/djangoldp-packages/djangoldp_subscription):

```python
  # package.yml
  ldppackages:
    djangoldp_subscription: djangoldp_subscription

```
Then run again `sib install server`

Follow the main documentation to verify the installation and go deeper.

### How to implement in your interface

```html
  <html>
  <head>
    <!-- import the module in the head of the page -->
    <script type="module" src="https://unpkg.com/@startinblox/component-subscription"></script>
  </head>

  <body>
  <!-- use the component -->
  <solid-subscription 
    data-src="http://yourserveradress/members/" 
    upload-dir="http://yourserveradress/upload/"
    range-subscription-typemember="http://yourserveradress/typemembers/"
    range-subscription-membergender="http://yourserveradress/gendermembers/"
    contact-link="link-to-contact-page"
  >
  </solid-subscription>
```

### Parameters

| Name            | Default                | Description                                                  |
| --------------- | ---------------------- | :----------------------------------------------------------- |
| `data-src`      | `undefined`            | URL of the member datas source.                         |
| `upload-dir`     | `undefined`           | URL of the place to upload. |
|`range-subscription-typemember`| `{}` | Say if you allow morale and/or physical member                 |
| `range-subscription-membergender` | `{}`  | The gender you propose |
| `contact-link`   | `""` | The link to your contact page. |


### Note
This is a very new component. If you have any trouble, contact alice@startinblox.com :)