Subscription/unsubscription seems to work.
This commit is contained in:
parent
d8ee364a4b
commit
e9165838dc
22 changed files with 14939 additions and 196 deletions
6159
client/package-lock.json
generated
Normal file
6159
client/package-lock.json
generated
Normal file
File diff suppressed because it is too large
Load diff
|
@ -24,7 +24,6 @@
|
|||
"immutable": "^3.8.1",
|
||||
"moment": "^2.18.1",
|
||||
"moment-timezone": "^0.5.13",
|
||||
"owasp-password-strength-test": "github:bures/owasp-password-strength-test",
|
||||
"prop-types": "^15.5.10",
|
||||
"querystringify": "^1.0.0",
|
||||
"react": "^15.6.1",
|
||||
|
|
|
@ -56,7 +56,7 @@ export default class API extends Component {
|
|||
|
||||
return (
|
||||
<div>
|
||||
<Title>{t('Sign in')}</Title>
|
||||
<Title>{t('API')}</Title>
|
||||
|
||||
|
||||
<div className="panel panel-default">
|
||||
|
|
|
@ -12,7 +12,7 @@ import {
|
|||
Dropdown, Form,
|
||||
withForm
|
||||
} from '../../lib/form';
|
||||
import {Icon} from "../../lib/bootstrap-components";
|
||||
import {Icon, Button} from "../../lib/bootstrap-components";
|
||||
import axios from '../../lib/axios';
|
||||
import {getFieldTypes, getSubscriptionStatusLabels} from './helpers';
|
||||
|
||||
|
@ -154,6 +154,7 @@ export default class List extends Component {
|
|||
return (
|
||||
<div>
|
||||
<Toolbar>
|
||||
<a href={`/subscription/${this.props.list.cid}`} className="btn-default"><Button label={t('Subscription Form')} className="btn-default"/></a>
|
||||
<NavButton linkTo={`/lists/${this.props.list.id}/subscriptions/create`} className="btn-primary" icon="plus" label={t('Add Subscriber')}/>
|
||||
</Toolbar>
|
||||
|
||||
|
|
|
@ -25,7 +25,10 @@ export function getFieldTypes(t) {
|
|||
|
||||
const stringFieldType = long => ({
|
||||
form: groupedField => long ? <TextArea key={getFieldKey(groupedField)} id={getFieldKey(groupedField)} label={groupedField.name}/> : <InputField key={getFieldKey(groupedField)} id={getFieldKey(groupedField)} label={groupedField.name}/>,
|
||||
assignFormData: (groupedField, data) => {},
|
||||
assignFormData: (groupedField, data) => {
|
||||
const value = data[getFieldKey(groupedField)];
|
||||
data[getFieldKey(groupedField)] = value || '';
|
||||
},
|
||||
initFormData: (groupedField, data) => {
|
||||
data[getFieldKey(groupedField)] = '';
|
||||
},
|
||||
|
@ -109,7 +112,10 @@ export function getFieldTypes(t) {
|
|||
|
||||
const jsonFieldType = {
|
||||
form: groupedField => <ACEEditor key={getFieldKey(groupedField)} id={getFieldKey(groupedField)} label={groupedField.name} mode="json" height="300px"/>,
|
||||
assignFormData: (groupedField, data) => {},
|
||||
assignFormData: (groupedField, data) => {
|
||||
const value = data[getFieldKey(groupedField)];
|
||||
data[getFieldKey(groupedField)] = value || '';
|
||||
},
|
||||
initFormData: (groupedField, data) => {
|
||||
data[getFieldKey(groupedField)] = '';
|
||||
},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue