|
@@ -31,7 +31,7 @@ const Organization = Form.create()(React.createClass({
|
|
|
name: this.state.name, //组织名称
|
|
|
superId: this.state.superId,//上级组织
|
|
|
type: this.state.type,//组织类型
|
|
|
- depNo: this.state.depNo,//组织编号
|
|
|
+ depNo: this.state.depNo1,//组织编号
|
|
|
},
|
|
|
success: function (data) {
|
|
|
let theArr = [];
|
|
@@ -73,6 +73,7 @@ const Organization = Form.create()(React.createClass({
|
|
|
},
|
|
|
getInitialState() {
|
|
|
return {
|
|
|
+ editvisible: false,
|
|
|
workingHoursType: 0,
|
|
|
searchMore: true,
|
|
|
selectedRowKeys: [],
|
|
@@ -209,6 +210,10 @@ const Organization = Form.create()(React.createClass({
|
|
|
//编辑部门,保存
|
|
|
edithandleSubmit(e) {
|
|
|
e.preventDefault();
|
|
|
+ if (!this.state.depNo) {
|
|
|
+ message.warning('请填写组织编号');
|
|
|
+ return
|
|
|
+ }
|
|
|
//上级组织字典
|
|
|
let nameText = this.state.SuperArr
|
|
|
let superText = this.state.editSuperId;
|
|
@@ -257,6 +262,7 @@ const Organization = Form.create()(React.createClass({
|
|
|
abbreviation: _this.state.abbreviation,
|
|
|
workingHoursType: _this.state.workingHoursType,
|
|
|
hideSign: _this.state.hideSign,//显示标识
|
|
|
+ depNo: _this.state.depNo,//组织编号
|
|
|
}
|
|
|
}).done(
|
|
|
function (data) {
|
|
@@ -299,6 +305,7 @@ const Organization = Form.create()(React.createClass({
|
|
|
abbreviation: _this.state.abbreviation,
|
|
|
workingHoursType: _this.state.workingHoursType,
|
|
|
hideSign: _this.state.hideSign,//显示标识
|
|
|
+ depNo: _this.state.depNo,//组织编号
|
|
|
}
|
|
|
}).done(
|
|
|
function (data) {
|
|
@@ -346,6 +353,7 @@ const Organization = Form.create()(React.createClass({
|
|
|
abbreviation: _this.state.abbreviation,
|
|
|
workingHoursType: _this.state.workingHoursType,
|
|
|
hideSign: _this.state.hideSign,//显示标识
|
|
|
+ depNo: _this.state.depNo,//组织编号
|
|
|
}
|
|
|
}).done(
|
|
|
function (data) {
|
|
@@ -389,6 +397,7 @@ const Organization = Form.create()(React.createClass({
|
|
|
province: _this.state.province,
|
|
|
workingHoursType: _this.state.workingHoursType,
|
|
|
hideSign: _this.state.hideSign,//显示标识
|
|
|
+ depNo: _this.state.depNo,//组织编号
|
|
|
}
|
|
|
}).done(
|
|
|
function (data) {
|
|
@@ -436,7 +445,7 @@ const Organization = Form.create()(React.createClass({
|
|
|
editStatus: thisdata.status, //组织状态
|
|
|
province: thisdata.province,//省份
|
|
|
editSuperId: thisdata.superId, //上级组织
|
|
|
- editDepNo: thisdata.depNo, //组织编号
|
|
|
+ depNo: thisdata.depNo, //组织编号
|
|
|
editCreateId: thisdata.createId, //创建人
|
|
|
editTime: thisdata.createTime, //创建时间
|
|
|
editRemarks: thisdata.remarks, //组织职能说明
|
|
@@ -455,7 +464,7 @@ const Organization = Form.create()(React.createClass({
|
|
|
editStatus: thisdata.status, //组织状态
|
|
|
province: thisdata.province, //省份
|
|
|
editSuperId: thisdata.superId, //上级组织
|
|
|
- editDepNo: thisdata.depNo, //组织编号
|
|
|
+ depNo: thisdata.depNo, //组织编号
|
|
|
editCreateId: thisdata.createId, //创建人
|
|
|
editTime: thisdata.createTime, //创建时间
|
|
|
editRemarks: thisdata.remarks, //组织职能说明
|
|
@@ -522,6 +531,10 @@ const Organization = Form.create()(React.createClass({
|
|
|
message.warning('请选择上级组织');
|
|
|
return false;
|
|
|
}
|
|
|
+ if (!this.state.depNo) {
|
|
|
+ message.warning('请填写组织编号');
|
|
|
+ return false;
|
|
|
+ }
|
|
|
this.props.form.validateFields((err, values) => {
|
|
|
if (!err) {
|
|
|
this.setState({
|
|
@@ -540,6 +553,7 @@ const Organization = Form.create()(React.createClass({
|
|
|
remarks: this.state.remarksOrganization,//组织职能说明
|
|
|
workingHoursType: this.state.workingHoursType,//作息时间
|
|
|
hideSign: this.state.hideSign,//显示标识
|
|
|
+ depNo: this.state.depNo,//组织编号
|
|
|
}
|
|
|
}).done(function (data) {
|
|
|
this.setState({
|
|
@@ -642,6 +656,7 @@ const Organization = Form.create()(React.createClass({
|
|
|
})
|
|
|
},
|
|
|
addClick() {
|
|
|
+ this.state.DepN = '';//组织编号
|
|
|
this.state.theTypes = '';
|
|
|
this.state.nameOrganization = '';//组织名称清零
|
|
|
this.state.managerIdOrganization = '';//负责人ID清零
|
|
@@ -680,7 +695,7 @@ const Organization = Form.create()(React.createClass({
|
|
|
this.state.superId = undefined;//上级组织清零
|
|
|
this.state.name = '';//组织名称清零
|
|
|
this.state.type = undefined;//组织类型清零
|
|
|
- this.state.depNo = '';//组织编号清零
|
|
|
+ this.state.depNo1 = '';//组织编号清零
|
|
|
this.loadData();
|
|
|
},
|
|
|
searchSwitch() {
|
|
@@ -760,8 +775,8 @@ const Organization = Form.create()(React.createClass({
|
|
|
<span style={{ marginRight: '20px' }}>更多搜索 <Switch defaultChecked={false} onChange={this.searchSwitch} /></span>
|
|
|
<div style={this.state.searchMore ? { display: 'none' } : { display: 'inline-block' }}>
|
|
|
<Input placeholder="组织编号" style={{ width: '150px', marginRight: '10px' }}
|
|
|
- value={this.state.depNo}
|
|
|
- onChange={(e) => { this.setState({ depNo: e.target.value }); }} />
|
|
|
+ value={this.state.depNo1}
|
|
|
+ onChange={(e) => { this.setState({ depNo1: e.target.value }); }} />
|
|
|
<Select placeholder="组织类型"
|
|
|
style={{ width: '150px', marginRight: '50px' }}
|
|
|
value={this.state.type}
|
|
@@ -774,7 +789,12 @@ const Organization = Form.create()(React.createClass({
|
|
|
</div>
|
|
|
</TabPane>
|
|
|
<TabPane tab="新增组织" key="2" >
|
|
|
- <Button type="primary" className="addButton" onClick={this.addClick} style={{ marginBottom: '10px', float: 'left' }}>新增组织<Icon type="plus" /></Button>
|
|
|
+ <Button
|
|
|
+ type="primary"
|
|
|
+ className="addButton"
|
|
|
+ onClick={this.addClick}
|
|
|
+ style={{ marginBottom: '10px', float: 'left' }}
|
|
|
+ >新增组织<Icon type="plus" /></Button>
|
|
|
</TabPane>
|
|
|
<TabPane tab="更改表格显示数据" key="3">
|
|
|
<div style={{ marginLeft: 10 }}>
|
|
@@ -903,6 +923,23 @@ const Organization = Form.create()(React.createClass({
|
|
|
<FormItem
|
|
|
labelCol={{ span: 7 }}
|
|
|
wrapperCol={{ span: 12 }}
|
|
|
+ label="组织编号"
|
|
|
+ >
|
|
|
+ <Input
|
|
|
+ placeholder='组织编号'
|
|
|
+ value={this.state.depNo}
|
|
|
+ onChange={(e) => {
|
|
|
+ this.setState({
|
|
|
+ depNo: e.target.value
|
|
|
+ })
|
|
|
+ }}
|
|
|
+ />
|
|
|
+ </FormItem>
|
|
|
+ </div>
|
|
|
+ <div className="clearfix">
|
|
|
+ <FormItem
|
|
|
+ labelCol={{ span: 7 }}
|
|
|
+ wrapperCol={{ span: 12 }}
|
|
|
label="组织职能说明" >
|
|
|
<Input type="textarea" rows={4} placeholder="组织职能说明" value={this.state.remarksOrganization}
|
|
|
onChange={(e) => { this.setState({ remarksOrganization: e.target.value }) }} style={{ width: '95%' }} />
|
|
@@ -1100,7 +1137,15 @@ const Organization = Form.create()(React.createClass({
|
|
|
wrapperCol={{ span: 12 }}
|
|
|
label="组织编号"
|
|
|
>
|
|
|
- <span>{this.state.editDepNo}</span>
|
|
|
+ <Input
|
|
|
+ placeholder='组织编号'
|
|
|
+ value={this.state.depNo}
|
|
|
+ onChange={(e) => {
|
|
|
+ this.setState({
|
|
|
+ depNo: e.target.value
|
|
|
+ })
|
|
|
+ }}
|
|
|
+ />
|
|
|
</FormItem>
|
|
|
</div>
|
|
|
<div className="clearfix" >
|