日志操作增加
This commit is contained in:
parent
98bb6e3ae4
commit
0f4c438bbf
|
|
@ -0,0 +1,12 @@
|
||||||
|
|
||||||
|
import {
|
||||||
|
WeaTools
|
||||||
|
} from 'ecCom'
|
||||||
|
|
||||||
|
export const getLogList = (params) => {
|
||||||
|
return WeaTools.callApi('/api/bs/hrmorganization/hrmresource/listPage', 'GET', params);
|
||||||
|
}
|
||||||
|
|
||||||
|
export const getAdvanceSearchCondition = (params) => {
|
||||||
|
return WeaTools.callApi('/api/bs/hrmorganization/hrmresource/getSearchCondition', 'GET', params);
|
||||||
|
}
|
||||||
|
|
@ -12,18 +12,20 @@ const WeaLogViewComp = WeaLogView.Component;
|
||||||
const {
|
const {
|
||||||
LogStore
|
LogStore
|
||||||
} = WeaLogView;
|
} = WeaLogView;
|
||||||
|
import LogView from "./log/logView";
|
||||||
|
|
||||||
|
import {LogViewStore} from "../stores/logview"
|
||||||
|
|
||||||
class Home extends React.Component {
|
class Home extends React.Component {
|
||||||
constructor(props) {
|
constructor(props) {
|
||||||
super(props);
|
super(props);
|
||||||
this.state = {
|
this.state = {
|
||||||
key: new Date().getTime(),
|
keys: new Date().getTime(),
|
||||||
visible: false,
|
visible: false,
|
||||||
logStore: new LogStore(),
|
logViewStore: new LogViewStore()
|
||||||
logType: '4',
|
|
||||||
logSmallType: ''
|
|
||||||
}
|
}
|
||||||
window.setLogViewProps = this.setLogViewProps;
|
window.setLogViewProp = this.setLogViewProp;
|
||||||
}
|
}
|
||||||
|
|
||||||
componentDidMount(){
|
componentDidMount(){
|
||||||
|
|
@ -46,13 +48,10 @@ class Home extends React.Component {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
setLogViewProps = (props) => {
|
setLogViewProp = (props) => {
|
||||||
this.setState({
|
this.setState({
|
||||||
key: new Date().getTime(),
|
|
||||||
targetId: '',
|
|
||||||
visible: true,
|
visible: true,
|
||||||
logType: '4',
|
logViewStore: new LogViewStore(),
|
||||||
logStore: new LogStore(),
|
|
||||||
...props
|
...props
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
@ -61,15 +60,18 @@ class Home extends React.Component {
|
||||||
visible: false
|
visible: false
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
//const isSingle = window.location.pathname.indexOf('/spa/hrm/engine') > -1;
|
//const isSingle = window.location.pathname.indexOf('/spa/hrm/engine') > -1;
|
||||||
return (
|
return (
|
||||||
<div style={{height:"100%"}}>
|
<div style={{height:"100%"}}>
|
||||||
<WeaPopoverHrm ecId={`${this && this.props && this.props.ecId || ''}_WeaPopoverHrm@jp3tsb`} />
|
<WeaPopoverHrm ecId={`${this && this.props && this.props.ecId || ''}_WeaPopoverHrm@jp3tsb`} />
|
||||||
<WeaLogViewComp ecId={`${this && this.props && this.props.ecId || ''}_WeaLogViewComp@mc1954`} {...this.state} onCancel={this.onCancel}/>
|
<LogView ecId={`${this && this.props && this.props.ecId || ''}_LogView@mc1954`} {...this.state} onCancel={this.onCancel}/>
|
||||||
|
{/* <WeaLogViewComp ecId={`${this && this.props && this.props.ecId || ''}_WeaLogViewComp@mc1954`} {...this.state} onCancel={this.onCancel}/> */}
|
||||||
<WeaLocaleProvider ecId={`${this && this.props && this.props.ecId || ''}_WeaLocaleProvider@3on3aj`}>
|
<WeaLocaleProvider ecId={`${this && this.props && this.props.ecId || ''}_WeaLocaleProvider@3on3aj`}>
|
||||||
{this.props.children}
|
{this.props.children}
|
||||||
</WeaLocaleProvider>
|
</WeaLocaleProvider>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,167 @@
|
||||||
|
import React from 'react'
|
||||||
|
import * as mobx from 'mobx'
|
||||||
|
import {
|
||||||
|
inject,
|
||||||
|
observer
|
||||||
|
} from 'mobx-react'
|
||||||
|
import {
|
||||||
|
WeaTop,
|
||||||
|
WeaTab,
|
||||||
|
WeaFormItem,
|
||||||
|
WeaDialog,
|
||||||
|
WeaSearchGroup
|
||||||
|
} from 'ecCom'
|
||||||
|
import {
|
||||||
|
Row,
|
||||||
|
Col,
|
||||||
|
Spin,
|
||||||
|
Modal,
|
||||||
|
Button,
|
||||||
|
message,
|
||||||
|
Switch
|
||||||
|
} from 'antd'
|
||||||
|
import {
|
||||||
|
WeaSwitch,
|
||||||
|
WeaTableNew
|
||||||
|
} from 'comsMobx'
|
||||||
|
import {
|
||||||
|
i18n
|
||||||
|
} from '../../public/i18n';
|
||||||
|
|
||||||
|
import '../../style/common.less';
|
||||||
|
|
||||||
|
const toJS = mobx.toJS;
|
||||||
|
const confirm = Modal.confirm;
|
||||||
|
const WeaTable = WeaTableNew.WeaTable;
|
||||||
|
|
||||||
|
|
||||||
|
export default class LogView extends React.Component {
|
||||||
|
constructor(props) {
|
||||||
|
super(props);
|
||||||
|
this.state = ({
|
||||||
|
height: 402,
|
||||||
|
width: 1075,
|
||||||
|
dialogTitle: '日志查看',
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
componentWillMount() {
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
componentDidMount() {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
componentWillReceiveProps(nextProps) {
|
||||||
|
if (this.props.keys !== nextProps.keys) {
|
||||||
|
nextProps.logViewStore.init(nextProps.logMoudleType);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
getPanelComponents() {
|
||||||
|
const {
|
||||||
|
logViewStore
|
||||||
|
} = this.props;
|
||||||
|
const {
|
||||||
|
searchCondition,
|
||||||
|
form,
|
||||||
|
searchConditionLoading
|
||||||
|
} = logViewStore;
|
||||||
|
|
||||||
|
let arr = [];
|
||||||
|
let formParams = form.getFormParams();
|
||||||
|
const {
|
||||||
|
isFormInit
|
||||||
|
} = form;
|
||||||
|
|
||||||
|
isFormInit && searchCondition.map(c => {
|
||||||
|
c.items.map((field, index) => {
|
||||||
|
arr.push(<Col ecId={`${this && this.props && this.props.ecId || ''}_Col@4cc308@${index}`} span={(index % 2 == 0) ? 10 : 11} offset={1}>
|
||||||
|
<div style={{ marginTop: 20 }}>
|
||||||
|
<WeaFormItem ecId={`${this && this.props && this.props.ecId || ''}_WeaFormItem@u6ex85@${index}`}
|
||||||
|
label={`${field.label}`}
|
||||||
|
labelCol={{ span: `${field.labelcol}` }}
|
||||||
|
wrapperCol={{ span: `${field.fieldcol}` }}>
|
||||||
|
{<WeaSwitch ecId={`${this && this.props && this.props.ecId || ''}_WeaSwitch@p7d3td@${index}`} fieldConfig={field} form={form} formParams={formParams} />}
|
||||||
|
</WeaFormItem>
|
||||||
|
</div>
|
||||||
|
</Col>)
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
if (searchConditionLoading) {
|
||||||
|
return (
|
||||||
|
<div className='hrm-loading-center-small' style={{ top: '25%' }}>
|
||||||
|
<Spin ecId={`${this && this.props && this.props.ecId || ''}_Spin@lbktzb`} spinning={searchConditionLoading}></Spin>
|
||||||
|
</div>
|
||||||
|
)
|
||||||
|
} else {
|
||||||
|
return <Row ecId={`${this && this.props && this.props.ecId || ''}_Row@ppeb6z`} onKeyDown={(e) => {
|
||||||
|
if (e.keyCode == 13 && e.target.tagName === "INPUT") {
|
||||||
|
logViewStore.getTableInfo();
|
||||||
|
logViewStore.setPanelStatus(false)
|
||||||
|
}
|
||||||
|
}}>{arr}</Row>
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
getTabBtn() {
|
||||||
|
const {
|
||||||
|
logViewStore
|
||||||
|
} = this.props;
|
||||||
|
const {
|
||||||
|
form
|
||||||
|
} = logViewStore;
|
||||||
|
|
||||||
|
const btn = [
|
||||||
|
(<Button ecId={`${this && this.props && this.props.ecId || ''}_Button@bx87i8`} type="primary" onClick={() => { logViewStore.getTableInfo(); logViewStore.setPanelStatus(false) }}>{i18n.button.search()}</Button>),
|
||||||
|
(<Button ecId={`${this && this.props && this.props.ecId || ''}_Button@218ju6`} onClick={() => form.reset()}>{i18n.button.reset()}</Button>),
|
||||||
|
(<Button ecId={`${this && this.props && this.props.ecId || ''}_Button@5u9mfz`} onClick={() => logViewStore.setPanelStatus(false)}>{i18n.button.cancel()}</Button>),
|
||||||
|
];
|
||||||
|
|
||||||
|
return btn;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
render() {
|
||||||
|
|
||||||
|
const {
|
||||||
|
visible, onCancel, logViewStore
|
||||||
|
} = this.props, {
|
||||||
|
tableStore,isPanelShow,conditionNum
|
||||||
|
} = logViewStore, {
|
||||||
|
height, dialogTitle, width,
|
||||||
|
} = this.state;
|
||||||
|
|
||||||
|
return (
|
||||||
|
<WeaDialog ecId={`${this && this.props && this.props.ecId || ''}_WeaDialog@1txk5f`}
|
||||||
|
title={dialogTitle}
|
||||||
|
icon="icon-coms-currency"
|
||||||
|
iconBgcolor="#217346"
|
||||||
|
visible={visible}
|
||||||
|
closable={true}
|
||||||
|
hasScroll={true}
|
||||||
|
onCancel={() => onCancel()}
|
||||||
|
style={{ height: height, width: width }}
|
||||||
|
>
|
||||||
|
<WeaTab ecId={`${this && this.props && this.props.ecId || ''}_WeaTab@9c3zts`}
|
||||||
|
searchType={['advanced']}
|
||||||
|
showSearchAd={isPanelShow}
|
||||||
|
setShowSearchAd={bool => logViewStore.setPanelStatus(bool)}
|
||||||
|
hideSearchAd={() => logViewStore.setPanelStatus(false)}
|
||||||
|
searchsAd={isPanelShow ? this.getPanelComponents() : <div></div>}
|
||||||
|
advanceHeight={Math.ceil(conditionNum / 2) * 52 + 20}
|
||||||
|
hasMask={false}
|
||||||
|
buttonsAd={this.getTabBtn()}
|
||||||
|
onSearch={() => logViewStore.getTableInfo()}
|
||||||
|
/>
|
||||||
|
<WeaTable ecId={`${this && this.props && this.props.ecId || ''}_WeaTable@pgmg3x`}
|
||||||
|
comsWeaTableStore={tableStore}
|
||||||
|
hasOrder={true}
|
||||||
|
needScroll={true}
|
||||||
|
/>
|
||||||
|
</WeaDialog>)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -266,8 +266,9 @@ export default class StaffScheme extends React.Component {
|
||||||
}
|
}
|
||||||
|
|
||||||
log = () => {
|
log = () => {
|
||||||
window.setLogViewProps({
|
window.setLogViewProp({
|
||||||
logSmallType: '3010',
|
logMoudleType: '0',
|
||||||
|
keys: new Date().getTime(),
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
/**
|
/**
|
||||||
* @Author: 程亮
|
* @Author: 程亮
|
||||||
* @Date: 2022-06-09 10:16:00
|
* @Date: 2022-06-09 10:16:00
|
||||||
* @LastEditTime: 2022-06-29 17:23:37
|
* @LastEditTime: 2022-07-04 15:12:06
|
||||||
* @Description:
|
* @Description:
|
||||||
* @FilePath: /trunk/src4js/pc4mobx/organization/stores/fieldDefined.js
|
* @FilePath: /trunk/src4js/pc4mobx/organization/stores/fieldDefined.js
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -21,7 +21,8 @@ import {ResourceExtendStore} from "./resourceExtend";
|
||||||
import {DatasImportStore} from "./datasImport";
|
import {DatasImportStore} from "./datasImport";
|
||||||
import {HrmImportResource} from "./importresource";
|
import {HrmImportResource} from "./importresource";
|
||||||
import {HrmImportCommon} from "./importCommon";
|
import {HrmImportCommon} from "./importCommon";
|
||||||
import {HrmBasicDataImport} from "./import"
|
import {HrmBasicDataImport} from "./import";
|
||||||
|
|
||||||
|
|
||||||
module.exports = {
|
module.exports = {
|
||||||
simpleOrgStore: new SimpleOrgStore(),
|
simpleOrgStore: new SimpleOrgStore(),
|
||||||
|
|
@ -47,5 +48,5 @@ module.exports = {
|
||||||
datasImport: new DatasImportStore(),
|
datasImport: new DatasImportStore(),
|
||||||
hrmImportResource:new HrmImportResource(),
|
hrmImportResource:new HrmImportResource(),
|
||||||
hrmImportCommon:new HrmImportCommon(),
|
hrmImportCommon:new HrmImportCommon(),
|
||||||
hrmBasicDataImport:new HrmBasicDataImport()
|
hrmBasicDataImport:new HrmBasicDataImport(),
|
||||||
};
|
};
|
||||||
|
|
|
||||||
|
|
@ -304,15 +304,11 @@ export class JobStore {
|
||||||
}
|
}
|
||||||
|
|
||||||
updateConditions(data) {
|
updateConditions(data) {
|
||||||
this.form1.updateFields({
|
const label = "等级方案"
|
||||||
scheme_id: {
|
const index = findIndex(this.condition[0].items, { label });
|
||||||
value: '',
|
this.condition[0].items[index].browserConditionParam.replaceDatas = [{ name: data.sequence_id.valueObj[0].scheme_ids, id: data.sequence_id.valueObj[0].scheme_values }];
|
||||||
},
|
this.setCondition(this.condition,false);
|
||||||
});
|
this.form1.initFormFields(this.condition);
|
||||||
// const label = "等级方案"
|
|
||||||
// const index = findIndex(this.condition[0].items, { label });
|
|
||||||
// this.condition[0].items[index].browserConditionParam.replaceDatas = [{ name: data.sequence_id.valueObj[0].scheme_ids, id: "18" }];
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -51,39 +51,39 @@ export class JobGradeStore {
|
||||||
@observable hasRight = true;
|
@observable hasRight = true;
|
||||||
@observable treeLoading = true;
|
@observable treeLoading = true;
|
||||||
|
|
||||||
@observable treeConfig = {
|
@observable treeConfig = {
|
||||||
data: [],
|
data: [],
|
||||||
selectedKeys: [],
|
selectedKeys: [],
|
||||||
treeExpandKeys: [],
|
treeExpandKeys: [],
|
||||||
onExpand: (keys) => {
|
onExpand: (keys) => {
|
||||||
this.treeConfig.treeExpandKeys = keys;
|
this.treeConfig.treeExpandKeys = keys;
|
||||||
},
|
},
|
||||||
onSelectedTreeNode: (key, count, countType) => {
|
onSelectedTreeNode: (key, count, countType) => {
|
||||||
this.treeConfig.selectedKeys = [key];
|
this.treeConfig.selectedKeys = [key];
|
||||||
this.selectedTreeNodeInfo = countType.node.props.data;
|
this.selectedTreeNodeInfo = countType.node.props.data;
|
||||||
this.getTableInfo();
|
this.getTableInfo();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
//选中树节点的信息
|
//选中树节点的信息
|
||||||
@observable selectedTreeNodeInfo;
|
@observable selectedTreeNodeInfo;
|
||||||
|
|
||||||
@action initData = () => {
|
@action initData = () => {
|
||||||
this.selectedTreeNodeInfo = null;
|
this.selectedTreeNodeInfo = null;
|
||||||
this.treeConfig.treeExpandKeys.length = 0;
|
this.treeConfig.treeExpandKeys.length = 0;
|
||||||
Api.getTree().then(res => {
|
Api.getTree().then(res => {
|
||||||
if (res.code === 200) {
|
if (res.code === 200) {
|
||||||
if (res.data.length > 0) {
|
if (res.data.length > 0) {
|
||||||
this.treeConfig.data = res.data;
|
this.treeConfig.data = res.data;
|
||||||
this.treeConfig.selectedKeys = [res.data[0].key];
|
this.treeConfig.selectedKeys = [res.data[0].key];
|
||||||
this.treeConfig.treeExpandKeys = "-1";
|
this.treeConfig.treeExpandKeys = "-1";
|
||||||
this.selectedTreeNodeInfo = res.data[0];
|
this.selectedTreeNodeInfo = res.data[0];
|
||||||
this.getTableInfo();
|
this.getTableInfo();
|
||||||
this.setTreeLoading(false);
|
this.setTreeLoading(false);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
message.error(res.msg);
|
message.error(res.msg);
|
||||||
}
|
}
|
||||||
}, error => { })
|
}, error => { })
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -278,15 +278,34 @@ export class JobGradeStore {
|
||||||
|
|
||||||
updateConditions(val) {
|
updateConditions(val) {
|
||||||
let currenttime = Date.now();
|
let currenttime = Date.now();
|
||||||
let key = `schemId_${currenttime}`;
|
let key = `scheme_id_${currenttime}`;
|
||||||
const lastKey = this.key;
|
const lastKey = this.key;
|
||||||
Reflect.deleteProperty(this.condition[0].items[4].browserConditionParam.dataParams,lastKey)
|
Reflect.deleteProperty(this.condition[0].items[4].browserConditionParam.completeParams, lastKey);
|
||||||
|
Reflect.deleteProperty(this.condition[0].items[4].browserConditionParam.conditionDataParams, lastKey);
|
||||||
|
Reflect.deleteProperty(this.condition[0].items[4].browserConditionParam.dataParams, lastKey);
|
||||||
|
Reflect.deleteProperty(this.condition[0].items[4].browserConditionParam.destDataParams, lastKey);
|
||||||
this.setKey(key);
|
this.setKey(key);
|
||||||
|
this.condition[0].items[4].browserConditionParam.completeParams = {
|
||||||
|
[key]: val,
|
||||||
|
...this.condition[0].items[4].browserConditionParam.completeParams,
|
||||||
|
currenttime: currenttime
|
||||||
|
}
|
||||||
|
this.condition[0].items[4].browserConditionParam.conditionDataParams = {
|
||||||
|
[key]: val,
|
||||||
|
...this.condition[0].items[4].browserConditionParam.conditionDataParams,
|
||||||
|
currenttime: currenttime
|
||||||
|
}
|
||||||
this.condition[0].items[4].browserConditionParam.dataParams = {
|
this.condition[0].items[4].browserConditionParam.dataParams = {
|
||||||
[key]:val,
|
[key]: val,
|
||||||
...this.condition[0].items[4].browserConditionParam.dataParams,
|
...this.condition[0].items[4].browserConditionParam.dataParams,
|
||||||
currenttime: currenttime
|
currenttime: currenttime
|
||||||
}
|
}
|
||||||
|
this.condition[0].items[4].browserConditionParam.destDataParams = {
|
||||||
|
[key]: val,
|
||||||
|
...this.condition[0].items[4].browserConditionParam.destDataParams,
|
||||||
|
currenttime: currenttime
|
||||||
|
}
|
||||||
|
|
||||||
this.form.updateFields({
|
this.form.updateFields({
|
||||||
levelId: {
|
levelId: {
|
||||||
value: ''
|
value: ''
|
||||||
|
|
@ -396,7 +415,7 @@ export class JobGradeStore {
|
||||||
this.rightMenu = rightMenu;
|
this.rightMenu = rightMenu;
|
||||||
}
|
}
|
||||||
|
|
||||||
setKey (key) {
|
setKey(key) {
|
||||||
this.key = key;
|
this.key = key;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,114 @@
|
||||||
|
import {
|
||||||
|
observable,
|
||||||
|
action
|
||||||
|
} from 'mobx';
|
||||||
|
import * as mobx from 'mobx';
|
||||||
|
import * as Api from '../apis/logview';
|
||||||
|
import {
|
||||||
|
WeaForm
|
||||||
|
} from 'comsMobx';
|
||||||
|
import {
|
||||||
|
WeaTableNew
|
||||||
|
} from 'comsMobx';
|
||||||
|
import {
|
||||||
|
Modal,
|
||||||
|
message,
|
||||||
|
} from 'antd'
|
||||||
|
import {
|
||||||
|
i18n
|
||||||
|
} from '../public/i18n';
|
||||||
|
|
||||||
|
const toJS = mobx.toJS;
|
||||||
|
const {
|
||||||
|
TableStore
|
||||||
|
} = WeaTableNew;
|
||||||
|
|
||||||
|
export class LogViewStore {
|
||||||
|
@observable tableStore = new TableStore();
|
||||||
|
@observable searchCondition = [];
|
||||||
|
@observable isPanelShow = false; //高级搜索面板
|
||||||
|
@observable form = new WeaForm();
|
||||||
|
@observable conditionNum = 20;
|
||||||
|
@observable searchConditionLoading = true;
|
||||||
|
@observable visible = false;
|
||||||
|
@observable dialogLoading = false;
|
||||||
|
@observable moduleType = ""; //模块类型
|
||||||
|
|
||||||
|
init(logMoudleType) {
|
||||||
|
this.setModuleType(logMoudleType);
|
||||||
|
this.getTableInfo();
|
||||||
|
this.getSearchCondition();
|
||||||
|
}
|
||||||
|
|
||||||
|
@action getTableInfo() {
|
||||||
|
let params = {
|
||||||
|
...this.form.getFormParams(),
|
||||||
|
moduleType:this.moduleType
|
||||||
|
}
|
||||||
|
this.tableStore = new TableStore();
|
||||||
|
Api.getLogList(params).then(res => {
|
||||||
|
if (res.code === 200) {
|
||||||
|
res.data.datas && this.tableStore.getDatas(res.data.datas, 1);
|
||||||
|
} else {
|
||||||
|
message.warning(res.msg);
|
||||||
|
}
|
||||||
|
}, error => {
|
||||||
|
message.warning(error.msg);
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@action getSearchCondition() {
|
||||||
|
this.setDialogLoading(true);
|
||||||
|
Api.getAdvanceSearchCondition().then(res => {
|
||||||
|
if (res.code === 200) {
|
||||||
|
this.setDialogLoading(false);
|
||||||
|
res.data.conditions && this.setSearchCondition(res.data.conditions);
|
||||||
|
res.data.conditions && this.form.initFormFields(res.data.conditions);
|
||||||
|
} else {
|
||||||
|
message.warning(res.msg);
|
||||||
|
}
|
||||||
|
}, error => {
|
||||||
|
message.warning(error.msg);
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
setDialogLoading(bool) {
|
||||||
|
this.dialogLoading = bool;
|
||||||
|
}
|
||||||
|
|
||||||
|
setPanelStatus(bool) {
|
||||||
|
this.isPanelShow = bool;
|
||||||
|
bool && this.getSearchCondition();
|
||||||
|
if (!bool) {
|
||||||
|
this.scLoadingReset();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
isEmptyObject(obj) {
|
||||||
|
for (let key in obj) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
setSearchCondition(searchCondition) {
|
||||||
|
this.searchCondition = searchCondition;
|
||||||
|
}
|
||||||
|
|
||||||
|
scLoadingReset() {
|
||||||
|
this.searchConditionLoading = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
setVisable(bool) {
|
||||||
|
this.visible = bool;
|
||||||
|
}
|
||||||
|
|
||||||
|
setModuleType(moduleType) {
|
||||||
|
this.moduleType = moduleType;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
Loading…
Reference in New Issue