Add submit input to Publish page
This commit is contained in:
parent
eba4dbe146
commit
7cfbb60033
1 changed files with 6 additions and 1 deletions
|
@ -12,7 +12,11 @@ var publishNumberStyle = {
|
||||||
var PublishPage = React.createClass({
|
var PublishPage = React.createClass({
|
||||||
_requiredFields: ['name', 'bid', 'meta_title', 'meta_author', 'meta_license', 'meta_description'],
|
_requiredFields: ['name', 'bid', 'meta_title', 'meta_author', 'meta_license', 'meta_description'],
|
||||||
|
|
||||||
handleSubmit: function() {
|
handleSubmit: function(event) {
|
||||||
|
if (typeof event !== 'undefined') {
|
||||||
|
event.preventDefault();
|
||||||
|
}
|
||||||
|
|
||||||
this.setState({
|
this.setState({
|
||||||
submitting: true,
|
submitting: true,
|
||||||
});
|
});
|
||||||
|
@ -456,6 +460,7 @@ var PublishPage = React.createClass({
|
||||||
<div className="card-series-submit">
|
<div className="card-series-submit">
|
||||||
<Link button="primary" label={!this.state.submitting ? 'Publish' : 'Publishing...'} onClick={this.handleSubmit} disabled={this.state.submitting} />
|
<Link button="primary" label={!this.state.submitting ? 'Publish' : 'Publishing...'} onClick={this.handleSubmit} disabled={this.state.submitting} />
|
||||||
<Link button="cancel" href="/" label="Cancel"/>
|
<Link button="cancel" href="/" label="Cancel"/>
|
||||||
|
<input type='submit' className='hidden' />
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
</main>
|
</main>
|
||||||
|
|
Loading…
Reference in a new issue