bug
This commit is contained in:
parent
1d1d974e8d
commit
faf2782dba
|
|
@ -41,6 +41,7 @@ export const getAdvanceSearchCondition = (params) => {
|
|||
return WeaTools.callApi('/api/bs/hrmorganization/comp/getSearchCondition', 'GET', params);
|
||||
}
|
||||
|
||||
|
||||
export const add = (params) => {
|
||||
return WeaTools.callApi('/api/bs/hrmorganization/comp/saveBaseComp', 'POST', params);
|
||||
}
|
||||
|
|
@ -49,6 +50,10 @@ export const version = (params) => {
|
|||
return WeaTools.callApi('/api/bs/hrmorganization/version/subcompanyfielddefined/save', 'POST', params);
|
||||
}
|
||||
|
||||
export const selectVersions = (params) => {
|
||||
return WeaTools.callApi('/api/bs/hrmorganization/version/subcompanyfielddefined/getVersion', 'GET', params);
|
||||
}
|
||||
|
||||
export const editResource = (params) => {
|
||||
return WeaTools.callApi('/api/bs/hrmorganization/comp/updateComp', 'POST', params);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -45,6 +45,10 @@ export const version = (params) => {
|
|||
return WeaTools.callApi('/api/bs/hrmorganization/version/departmentfielddefined/save', 'POST', params);
|
||||
}
|
||||
|
||||
export const selectVersions = (params) => {
|
||||
return WeaTools.callApi('/api/bs/hrmorganization/version/departmentfielddefined/getVersion', 'GET', params);
|
||||
}
|
||||
|
||||
export const getTransferForm = (params) => {
|
||||
return WeaTools.callApi('/api/bs/hrmorganization/dept/getMoveForm', 'GET', params);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -37,6 +37,10 @@ export const getCopyForm = (params) => {
|
|||
return WeaTools.callApi('/api/bs/hrmorganization/job/getCopyForm', 'GET', params);
|
||||
}
|
||||
|
||||
export const refresh = (params) => {
|
||||
return WeaTools.callApi('/api/bs/hrmorganization/job/refresh', 'GET', params);
|
||||
}
|
||||
|
||||
export const add = (params) => {
|
||||
return fetch('/api/bs/hrmorganization/job/saveBaseForm', {
|
||||
method: 'POST',
|
||||
|
|
|
|||
|
|
@ -43,7 +43,9 @@ export const version = (params) => {
|
|||
return WeaTools.callApi('/api/bs/hrmorganization/version/resourcefielddefined/save', 'POST', params);
|
||||
}
|
||||
|
||||
|
||||
export const selectVersions = (params) => {
|
||||
return WeaTools.callApi('/api/bs/hrmorganization/version/resourcefielddefined/getVersion', 'GET', params);
|
||||
}
|
||||
|
||||
export const exportResource = (ids) => {
|
||||
fetch('/api/bs/hrmorganization/common/resource/export?ids='+ids).then(res => res.blob().then(blob => {
|
||||
|
|
|
|||
|
|
@ -22,6 +22,14 @@ export default class VersionsSlider extends React.Component {
|
|||
|
||||
}
|
||||
|
||||
isEmptyObject(obj) {
|
||||
for (let key in obj) {
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
render() {
|
||||
const {
|
||||
versionList,
|
||||
|
|
@ -32,54 +40,54 @@ export default class VersionsSlider extends React.Component {
|
|||
|
||||
|
||||
return (
|
||||
<div style={{ "marginTop": "50px", "paddingLeft": "30px", "height": "30px", "lineHeight": "30px", "paddingRight": "30px" }}>
|
||||
<Row>
|
||||
<Col span={8}>
|
||||
<p>操作人: {versionList.operateName}</p>
|
||||
</Col>
|
||||
<Col span={8}>
|
||||
<p>操作时间: {versionList.operateTime}</p>
|
||||
</Col>
|
||||
<Col span={8}>
|
||||
<div>版本: <Select showSearch
|
||||
style={{ width: 100 }}
|
||||
placeholder="请选择版本"
|
||||
defaultValue="1.0"
|
||||
optionFilterProp="children"
|
||||
notFoundContent="无法找到"
|
||||
onChange={handleChange}
|
||||
>
|
||||
{
|
||||
versionList.versions.map((item) => {
|
||||
return (<Option value={item.value}>V{item.value}</Option>)
|
||||
})
|
||||
}
|
||||
|
||||
<div style={{ "marginTop": "50px", "paddingLeft": "30px", "height": "30px", "lineHeight": "30px", "paddingRight": "30px" }}>
|
||||
<Row>
|
||||
<Col span={8}>
|
||||
<p>操作人: {versionList.operateName}</p>
|
||||
</Col>
|
||||
<Col span={8}>
|
||||
<p>操作时间: {versionList.operateTime}</p>
|
||||
</Col>
|
||||
<Col span={8}>
|
||||
<div>版本: <Select showSearch
|
||||
style={{ width: 100 }}
|
||||
placeholder="请选择版本"
|
||||
defaultValue="1.0"
|
||||
optionFilterProp="children"
|
||||
notFoundContent="无法找到"
|
||||
onChange={handleChange}
|
||||
>
|
||||
{
|
||||
versionList.versions.map((item) => {
|
||||
return (<Option value={item.value}>V{item.value}</Option>)
|
||||
})
|
||||
}
|
||||
|
||||
</Select></div>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
<div style={{ "marginTop": "30px", "width": "100%" }}>
|
||||
{newData.map((item, index) => {
|
||||
return (
|
||||
<div key={index} style={{ "display": "flex" }}>
|
||||
{item.map((subItem) => {
|
||||
</Select></div>
|
||||
</Col>
|
||||
</Row>
|
||||
<div style={{ "marginTop": "30px", "width": "100%" }}>
|
||||
{newData.map((item, index) => {
|
||||
return (
|
||||
<div style={{ "width": "50%", "height": "40px", "overflow": "hidden", "testOverflow": "ellipsis", "whiteSpace": "nowrap" }}>
|
||||
<span style={{ "width": "80px", "display": "inline-block", "textAlign": "right", "color": "#999999" }}>{subItem.fieldId}</span>
|
||||
{subItem.fieldValue.length > 10 ? <Tooltip placement="topLeft" title={subItem.fieldValue}>
|
||||
<span style={{ "marginLeft": "20px" }}>{subItem.fieldValue}</span>
|
||||
</Tooltip> : <span style={{ "marginLeft": "20px" }}>{subItem.fieldValue}</span>}
|
||||
<div key={index} style={{ "display": "flex" }}>
|
||||
{item.map((subItem) => {
|
||||
return (
|
||||
<div style={{ "width": "50%", "height": "40px", "overflow": "hidden", "testOverflow": "ellipsis", "whiteSpace": "nowrap" }}>
|
||||
<span style={{ "width": "80px", "display": "inline-block", "textAlign": "right", "color": "#999999" }}>{subItem.fieldId}</span>
|
||||
{subItem.fieldValue.length > 10 ? <Tooltip placement="topLeft" title={subItem.fieldValue}>
|
||||
<span style={{ "marginLeft": "20px" }}>{subItem.fieldValue}</span>
|
||||
</Tooltip> : <span style={{ "marginLeft": "20px" }}>{subItem.fieldValue}</span>}
|
||||
|
||||
</div>
|
||||
|
||||
);
|
||||
})}
|
||||
</div>
|
||||
|
||||
);
|
||||
})}
|
||||
</div>
|
||||
);
|
||||
})}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
/**
|
||||
* @Author: 程亮
|
||||
* @Date: 2022-05-18 14:52:39
|
||||
* @LastEditTime: 2022-12-09 17:45:16
|
||||
* @LastEditTime: 2022-12-15 19:29:14
|
||||
* @Description:
|
||||
* @FilePath: /trunk/src4js/pc4mobx/organization/components/company/CompanyExtend.js
|
||||
*/
|
||||
|
|
@ -235,7 +235,7 @@ export default class CompanyExtend extends React.Component {
|
|||
|
||||
view = () => {
|
||||
const { companyExtend } = this.props;
|
||||
companyExtend.open = true;
|
||||
companyExtend.selectVersions();
|
||||
}
|
||||
|
||||
onClose = () => {
|
||||
|
|
@ -305,7 +305,7 @@ export default class CompanyExtend extends React.Component {
|
|||
height={94}
|
||||
direction={'right'}
|
||||
measure={'%'}
|
||||
content={<VersionsSlider versionList={versionList} handleChange={val => companyExtend.changeVersion(val)}/>}
|
||||
content={!isEmpty(versionList) ? <VersionsSlider versionList={versionList} handleChange={val => companyExtend.changeVersion(val)}/> : <div style={{"textAlign":"center","color":"red","fontSize":"20px","marginTop": "50px"}}> 暂无历史版本 </div>}
|
||||
onClose={this.onClose}
|
||||
onAnimationEnd={() => console.log('onAnimationEnd')} />
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
/**
|
||||
* @Author: 程亮
|
||||
* @Date: 2022-06-02 09:20:03
|
||||
* @LastEditTime: 2022-12-09 17:46:00
|
||||
* @LastEditTime: 2022-12-15 19:28:54
|
||||
* @Description:
|
||||
* @FilePath: /trunk/src4js/pc4mobx/organization/components/department/departmentExtend.js
|
||||
*/
|
||||
|
|
@ -43,7 +43,7 @@ export default class DepartmentExtendStore extends React.Component {
|
|||
|
||||
view = () => {
|
||||
const { departmentExtend } = this.props;
|
||||
departmentExtend.open = true;
|
||||
departmentExtend.selectVersions();
|
||||
}
|
||||
|
||||
getTabChildren = () => {
|
||||
|
|
@ -296,7 +296,7 @@ export default class DepartmentExtendStore extends React.Component {
|
|||
height={94}
|
||||
direction={'right'}
|
||||
measure={'%'}
|
||||
content={!isEmpty(versionList) ? <VersionsSlider versionList={versionList} handleChange={val => departmentExtend.changeVersion(val)}/> : ''}
|
||||
content={!isEmpty(versionList) ? <VersionsSlider versionList={versionList} handleChange={val => departmentExtend.changeVersion(val)}/> : <div style={{"textAlign":"center","color":"red","fontSize":"20px","marginTop": "50px"}}> 暂无历史版本 </div>}
|
||||
onClose={this.onClose}
|
||||
onAnimationEnd={() => console.log('onAnimationEnd')} />
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
/**
|
||||
* @Author: 程亮
|
||||
* @Date: 2022-05-26 14:05:59
|
||||
* @LastEditTime: 2022-12-13 16:01:40
|
||||
* @LastEditTime: 2022-12-15 17:09:27
|
||||
* @Description:
|
||||
* @FilePath: /trunk/src4js/pc4mobx/organization/components/job/Job.js
|
||||
*/
|
||||
|
|
@ -127,9 +127,18 @@ export default class Job extends React.Component {
|
|||
job.setNeDialogTitle(i18n.label.newPost());
|
||||
job.setNewVisible(true);
|
||||
job.getJobForm();
|
||||
|
||||
}
|
||||
|
||||
|
||||
refresh() {
|
||||
const {
|
||||
job
|
||||
} = this.props;
|
||||
|
||||
job.refresh();
|
||||
}
|
||||
|
||||
|
||||
//联查人员
|
||||
select(id) {
|
||||
const {
|
||||
|
|
|
|||
|
|
@ -26,10 +26,11 @@ export class CompanyExtendStore {
|
|||
@observable tabkey = '0';
|
||||
|
||||
@observable open = false;
|
||||
|
||||
@observable version = '1.0';
|
||||
|
||||
@observable selectedRowKeys = [];
|
||||
@observable selectedRows = [];
|
||||
@observable versionList = {};
|
||||
|
||||
@action onRowSelect = (keys) => {
|
||||
this.setSelectedRowKeys(keys);
|
||||
|
|
@ -47,6 +48,23 @@ export class CompanyExtendStore {
|
|||
this.detailSelectedKey = '0'
|
||||
}
|
||||
|
||||
@action selectVersions = () => {
|
||||
let params = {
|
||||
id:this.id,
|
||||
version:this.version
|
||||
}
|
||||
Api.selectVersions(params).then((res) => {
|
||||
this.open = true;
|
||||
if (res.code === 200) {
|
||||
this.setVersionList(res.data);
|
||||
} else {
|
||||
message.warning(res.msg);
|
||||
}
|
||||
}, error => {
|
||||
message.warning(error.msg);
|
||||
})
|
||||
}
|
||||
|
||||
init = () => {
|
||||
this.detailSelectedKey = '0'
|
||||
this.isEditor = false;
|
||||
|
|
@ -177,7 +195,8 @@ export class CompanyExtendStore {
|
|||
}
|
||||
|
||||
changeVersion = data => {
|
||||
debugger
|
||||
this.version = data;
|
||||
this.selectVersions();
|
||||
}
|
||||
|
||||
setLoading(val) {
|
||||
|
|
@ -245,49 +264,53 @@ export class CompanyExtendStore {
|
|||
this.date = date;
|
||||
}
|
||||
|
||||
//历史版本
|
||||
@observable versionList = {
|
||||
operateName: '史永成',
|
||||
operateTime: '2022-12-31',
|
||||
versions: [
|
||||
{ value: "1.0" },
|
||||
{ value: "1.1" },
|
||||
{ value: "1.2" },
|
||||
{ value: "1.3" }
|
||||
],
|
||||
datas: [
|
||||
{
|
||||
fieldId: '简称',
|
||||
fieldValue: '泛微'
|
||||
}, {
|
||||
fieldId: '全称',
|
||||
fieldValue: '泛微'
|
||||
}, {
|
||||
fieldId: '上级分部',
|
||||
fieldValue: '泛微北京'
|
||||
}, {
|
||||
fieldId: '网站',
|
||||
fieldValue: '1546875925@qq.com'
|
||||
}, {
|
||||
fieldId: '分部ID',
|
||||
fieldValue: '8'
|
||||
}, {
|
||||
fieldId: '显示顺序',
|
||||
fieldValue: '9'
|
||||
}, {
|
||||
fieldId: '分部编号',
|
||||
fieldValue: '分部1-1'
|
||||
}, {
|
||||
fieldId: '限制用户数',
|
||||
fieldValue: '产品运营'
|
||||
}, {
|
||||
fieldId: '在职离职人数',
|
||||
fieldValue: '产品运营'
|
||||
}
|
||||
]
|
||||
|
||||
|
||||
|
||||
setVersionList(obj) {
|
||||
this.versionList = obj;
|
||||
}
|
||||
|
||||
//历史版本
|
||||
// @observable versionList = {
|
||||
// operateName: '史永成',
|
||||
// operateTime: '2022-12-31',
|
||||
// versions: [
|
||||
// { value: "1.0" },
|
||||
// { value: "1.1" },
|
||||
// { value: "1.2" },
|
||||
// { value: "1.3" }
|
||||
// ],
|
||||
// datas: [
|
||||
// {
|
||||
// fieldId: '简称',
|
||||
// fieldValue: '泛微'
|
||||
// }, {
|
||||
// fieldId: '全称',
|
||||
// fieldValue: '泛微'
|
||||
// }, {
|
||||
// fieldId: '上级分部',
|
||||
// fieldValue: '泛微北京'
|
||||
// }, {
|
||||
// fieldId: '网站',
|
||||
// fieldValue: '1546875925@qq.com'
|
||||
// }, {
|
||||
// fieldId: '分部ID',
|
||||
// fieldValue: '8'
|
||||
// }, {
|
||||
// fieldId: '显示顺序',
|
||||
// fieldValue: '9'
|
||||
// }, {
|
||||
// fieldId: '分部编号',
|
||||
// fieldValue: '分部1-1'
|
||||
// }, {
|
||||
// fieldId: '限制用户数',
|
||||
// fieldValue: '产品运营'
|
||||
// }, {
|
||||
// fieldId: '在职离职人数',
|
||||
// fieldValue: '产品运营'
|
||||
// }
|
||||
// ]
|
||||
|
||||
|
||||
|
||||
// }
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -29,6 +29,8 @@ export class DepartmentExtendStore {
|
|||
@observable selectedRows = [];
|
||||
|
||||
@observable open = false;
|
||||
@observable version = '1.0';
|
||||
@observable versionList = {};
|
||||
|
||||
@action onRowSelect = (keys) => {
|
||||
this.setSelectedRowKeys(keys);
|
||||
|
|
@ -39,8 +41,7 @@ export class DepartmentExtendStore {
|
|||
}
|
||||
|
||||
|
||||
@action
|
||||
edit = () => {
|
||||
@action edit = () => {
|
||||
this.isEditor = true;
|
||||
this.getData();
|
||||
this.getTabInfo();
|
||||
|
|
@ -77,6 +78,23 @@ export class DepartmentExtendStore {
|
|||
})
|
||||
}
|
||||
|
||||
@action("历史版本") selectVersions = () => {
|
||||
let params = {
|
||||
id:this.id,
|
||||
version:this.version
|
||||
}
|
||||
Api.selectVersions(params).then((res) => {
|
||||
this.open = true;
|
||||
if (res.code === 200) {
|
||||
this.setVersionList(res.data);
|
||||
} else {
|
||||
message.warning(res.msg);
|
||||
}
|
||||
}, error => {
|
||||
message.warning(error.msg);
|
||||
})
|
||||
}
|
||||
|
||||
editResource = () => {
|
||||
let pDatas = this.form.getFormParams();
|
||||
Api.editResource({ ...{
|
||||
|
|
@ -240,50 +258,8 @@ export class DepartmentExtendStore {
|
|||
this.date = date;
|
||||
}
|
||||
|
||||
//历史版本
|
||||
@observable versionList = {
|
||||
operateName: '史永成',
|
||||
operateTime: '2022-12-31',
|
||||
versions: [
|
||||
{ value: "1.0" },
|
||||
{ value: "1.1" },
|
||||
{ value: "1.2" },
|
||||
{ value: "1.3" }
|
||||
],
|
||||
datas: [
|
||||
{
|
||||
fieldId: '简称',
|
||||
fieldValue: '泛微'
|
||||
}, {
|
||||
fieldId: '全称',
|
||||
fieldValue: '泛微'
|
||||
}, {
|
||||
fieldId: '上级分部',
|
||||
fieldValue: '泛微北京'
|
||||
}, {
|
||||
fieldId: '网站',
|
||||
fieldValue: '1546875925@qq.com'
|
||||
}, {
|
||||
fieldId: '分部ID',
|
||||
fieldValue: '8'
|
||||
}, {
|
||||
fieldId: '显示顺序',
|
||||
fieldValue: '9'
|
||||
}, {
|
||||
fieldId: '分部编号',
|
||||
fieldValue: '分部1-1'
|
||||
}, {
|
||||
fieldId: '限制用户数',
|
||||
fieldValue: '产品运营'
|
||||
}, {
|
||||
fieldId: '在职离职人数',
|
||||
fieldValue: '产品运营'
|
||||
}
|
||||
]
|
||||
|
||||
|
||||
|
||||
setVersionList(obj) {
|
||||
this.versionList = obj;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -155,6 +155,19 @@ export class JobStore {
|
|||
})
|
||||
}
|
||||
|
||||
@action("刷新") refresh() {
|
||||
Api.refresh().then(res => {
|
||||
if (res.code === 200) {
|
||||
this.getTableInfo();
|
||||
message.success(res.msg);
|
||||
} else {
|
||||
message.warning(res.msg);
|
||||
}
|
||||
}, error => {
|
||||
message.warning(error.msg);
|
||||
})
|
||||
}
|
||||
|
||||
updateForbiddenTag(checked, id) {
|
||||
let params = {
|
||||
forbiddenTag: checked,
|
||||
|
|
|
|||
Loading…
Reference in New Issue