content: import React from 'react';
  import TextInput from '../common/TextInput';
  import SelectInput from '../common/SelectInput';
  
  const CustomerForm = ({customer, allStatus, onSave, onChange, loading, errors}) => {
  	return (
  		<form>
  			<TextInput
  				name="firstname"
  				label="First Name"
  				value={customer.firstname}
  				onChange={onChange}
  				error={errors.title}/>
  
  			<TextInput
  				name="lastname"
  				label="Last Name"
  				value={customer.lastname}
  				onChange={onChange}
  				error={errors.title}/>
  
  			<TextInput
  				name="address"
  				label="Address"
  				value={customer.address}
  				onChange={onChange}
  				error={errors.title}/>
  
  			<TextInput
  				name="amount"
  				label="Amount"
  				value={customer.amount}
  				onChange={onChange}
  				error={errors.title}/>
  
  			<SelectInput
  				name="status"
  				label="Status"
  				value={customer.status}
  				defaultOption="Select Status"
  				options={allStatus}
  				onChange={onChange}
  				error={errors.status}/>
  
  			<TextInput
  				name="joining_date"
  				label="Joining Date"
  				value={customer.joining_date}
  				onChange={onChange}
  				error={errors.category}/>
  
  			<TextInput
  				name="last_fees_paid_on"
  				label="Last Fees Paid On"
  				value={customer.last_fees_paid_on}
  				onChange={onChange}
  				error={errors.category}/>
  
  			<TextInput
  				name="contact"
  				label="Contact"
  				value={customer.contact}
  				onChange={onChange}
  				error={errors.length}/>
  
  			<TextInput
  				name="email"
  				label="Email"
  				value={customer.email}
  				onChange={onChange}
  				error={errors.length}/>
  
  			<input
  				type="submit"
  				disabled={loading}
  				value={loading ? 'Saving...' : 'Save'}
  				className="btn btn-primary"
  				onClick={onSave}/>
  
  		</form>
  	);
  };
  
  CustomerForm.propTypes = {
  	customer: React.PropTypes.object.isRequired,
  	allStatus: React.PropTypes.array,
  	onSave: React.PropTypes.func,
  	onChange: React.PropTypes.func,
  	loading: React.PropTypes.bool,
  	errors: React.PropTypes.object
  };
  
  export default CustomerForm;
  