Created
March 7, 2015 03:58
-
-
Save mwiencek/aed5d1061b018afc073f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// This file is part of MusicBrainz, the open internet music database. | |
// Copyright (C) 2015 MetaBrainz Foundation | |
// Licensed under the GPL version 2, or (at your option) any later version: | |
// http://www.gnu.org/licenses/gpl-2.0.txt | |
var React = require('react'); | |
var PartialDate = require('./PartialDate.js'); | |
var i18n = require('../../../common/i18n.js'); | |
var DatePeriod = React.createClass({ | |
render: function () { | |
var relationship = this.props.relationship; | |
// var error = ??? | |
return ( | |
<PartialDate label={i18n.addColon('Begin date')} date={relationship.beginDate} /> | |
<PartialDate label={i18n.addColon('End date')} date={relationship.endDate} /> | |
{error && | |
<tr> | |
<td></td> | |
<td class="error">{error}</td> | |
</tr>} | |
<tr> | |
<td colspan="2"> | |
<label> | |
<input type="checkbox" checked={relationship.ended} onChange={this.props.endedChangeCallback} /> | |
{i18n.l('This relationship has ended.')} | |
</label> | |
</td> | |
</tr> | |
); | |
} | |
}); | |
module.exports = DatePeriod; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment