-
+ {this.handleTitleCheckboxChange(value, "input")}}/>
@@ -103,7 +147,7 @@ export default class SelectFieldModal extends React.Component {
-
+ {this.showSelectedChange(value)}}/>
)
diff --git a/pc4mobx/hrmSalary/pages/calculateDetail/salaryDetail.js b/pc4mobx/hrmSalary/pages/calculateDetail/salaryDetail.js
index b419d14d..3f321af3 100644
--- a/pc4mobx/hrmSalary/pages/calculateDetail/salaryDetail.js
+++ b/pc4mobx/hrmSalary/pages/calculateDetail/salaryDetail.js
@@ -67,13 +67,17 @@ export default class SalaryDetail extends React.Component {
result.oldWidth = result.width;
result.width = "150px";
if(result.children) {
- result.width = null;
+ result.width = (result.children.length * 150) + "px";
result.children.map(child => {
child.title = child.text
child.dataIndex = child.column
child.width = "150px";
})
}
+
+ if(result.dataIndex === "taxAgentName" || result.dataIndex === "username" || result.dataIndex === "departmentName") {
+ result.fixed = "left"
+ }
return result;
})
columns.push({
@@ -84,7 +88,6 @@ export default class SalaryDetail extends React.Component {
return
{this.handleEdit(record)}}>编辑
}
})
- console.log("columns: ", columns);
return columns;
}
diff --git a/pc4mobx/hrmSalary/pages/salaryFile/salaryItemChangeList.js b/pc4mobx/hrmSalary/pages/salaryFile/salaryItemChangeList.js
index 76aba627..8b399f57 100644
--- a/pc4mobx/hrmSalary/pages/salaryFile/salaryItemChangeList.js
+++ b/pc4mobx/hrmSalary/pages/salaryFile/salaryItemChangeList.js
@@ -57,8 +57,8 @@ export default class SalaryItemChangeList extends React.Component {
// 页面跳转
handlePageChange(value) {
this.searchParams.current = value
- const { salaryFileStore: {singleSalaryItemList} } = this.props;
- singleSalaryItemList(this.searchParams)
+ const { salaryFileStore: {fetchSingleSalaryItemList} } = this.props;
+ fetchSingleSalaryItemList(this.searchParams)
}
render() {
diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/archives/index.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/archives/index.js
index b8eb29e0..b09f48b2 100644
--- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/archives/index.js
+++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/archives/index.js
@@ -246,7 +246,6 @@ export default class Archives extends React.Component {
// getColumns={this.getColumns}
// onOperatesClick={this.onOperatesClick.bind(this)}
/> */}
-
{
API.getCondition().then(action(res => {
if (res.status) { // 接口请求成功/失败处理
- this.condition = res.data.condition;
- this.form.initFormFields(res.data.condition); // 渲染高级搜索form表单
+ let condition = removePropertyCondition(res.data.condition)
+ this.condition = condition;
+ this.form.initFormFields(condition); // 渲染高级搜索form表单
} else {
message.error(res.msg || '接口调用失败!')
}
diff --git a/pc4mobx/hrmSalary/stores/cumDeduct.js b/pc4mobx/hrmSalary/stores/cumDeduct.js
index f9c99fcc..42ba3d22 100644
--- a/pc4mobx/hrmSalary/stores/cumDeduct.js
+++ b/pc4mobx/hrmSalary/stores/cumDeduct.js
@@ -4,6 +4,7 @@ import { WeaForm, WeaTableNew } from 'comsMobx';
import * as API from '../apis/cumDeduct'; // 引入API接口文件
import * as TaxAgentApi from '../apis/taxAgent'
+import { removePropertyCondition } from '../util/response';
const { TableStore } = WeaTableNew;
@@ -62,8 +63,9 @@ export class CumDeductStore {
getCondition = () => {
API.getCumDeductSaCondition().then(action(res => {
if (res.status) { // 接口请求成功/失败处理
- this.condition = res.data.condition;
- this.form.initFormFields(res.data.condition); // 渲染高级搜索form表单
+ let condition = removePropertyCondition(res.data.condition)
+ this.condition = condition;
+ this.form.initFormFields(condition); // 渲染高级搜索form表单
} else {
message.error(res.errormsg || '接口调用失败!')
}
diff --git a/pc4mobx/hrmSalary/stores/cumSituation.js b/pc4mobx/hrmSalary/stores/cumSituation.js
index f3361912..39229018 100644
--- a/pc4mobx/hrmSalary/stores/cumSituation.js
+++ b/pc4mobx/hrmSalary/stores/cumSituation.js
@@ -1,6 +1,7 @@
import { observable, action, toJS } from 'mobx';
import { message } from 'antd';
import { WeaForm, WeaTableNew } from 'comsMobx';
+import { removePropertyCondition } from '../util/response';
import * as API from '../apis/cumSituation'; // 引入API接口文件
import * as TaxAgentApi from '../apis/taxAgent'
@@ -60,8 +61,9 @@ export class CumSituationStore {
getCondition = () => {
API.getCumSituationSaCondition().then(action(res => {
if (res.status) { // 接口请求成功/失败处理
- this.condition = res.data.condition;
- this.form.initFormFields(res.data.condition); // 渲染高级搜索form表单
+ let condition = removePropertyCondition(res.data.condition)
+ this.condition = condition;
+ this.form.initFormFields(condition); // 渲染高级搜索form表单
} else {
message.error(res.errormsg || '接口调用失败!')
}
diff --git a/pc4mobx/hrmSalary/stores/otherDeduct.js b/pc4mobx/hrmSalary/stores/otherDeduct.js
index 86f9ba08..c2af08f1 100644
--- a/pc4mobx/hrmSalary/stores/otherDeduct.js
+++ b/pc4mobx/hrmSalary/stores/otherDeduct.js
@@ -1,6 +1,7 @@
import { observable, action, toJS } from 'mobx';
import { message } from 'antd';
import { WeaForm, WeaTableNew } from 'comsMobx';
+import { removePropertyCondition } from '../util/response';
import * as API from '../apis/otherDeduct'; // 引入API接口文件
import * as TaxAgentApi from '../apis/taxAgent'
@@ -61,8 +62,9 @@ export class OtherDeductStore {
getCondition = () => {
API.getOtherDeductSaCondition().then(action(res => {
if (res.status) { // 接口请求成功/失败处理
- this.condition = res.data.condition;
- this.form.initFormFields(res.data.condition); // 渲染高级搜索form表单
+ let condition = removePropertyCondition(res.data.condition)
+ this.condition = condition;
+ this.form.initFormFields(condition); // 渲染高级搜索form表单
} else {
message.error(res.errormsg || '接口调用失败!')
}
diff --git a/pc4mobx/hrmSalary/util/index.js b/pc4mobx/hrmSalary/util/index.js
index 6aef0a40..f74d1172 100644
--- a/pc4mobx/hrmSalary/util/index.js
+++ b/pc4mobx/hrmSalary/util/index.js
@@ -3,11 +3,95 @@ import { WeaSwitch } from 'comsMobx';
import { WeaLocaleProvider, WeaAlertPage, WeaSearchGroup, WeaFormItem } from 'ecCom';
const getLabel = WeaLocaleProvider.getLabel;
+// 渲染form表单: 一般对form的渲染都统一使用该方法
+export const getCustomSearchs = (form, condition, col, isCenter) => {
+ const { isFormInit } = form;
+ const formParams = form.getFormParams();
+ let items = [];
+ let group = [];
+ isFormInit && condition &&
+ condition.map(c =>{
+ c.items.map(fields => {
+ items.push({
+ com:(
+
+
+ ),
+ colSpan:1,
+ })
+ });
+ });
+
+ if(items.length > 0) {
+ group.push(
+ )
+ return group;
+ }
+}
+
+// 渲染form表单: 一般对form的渲染都统一使用该方法
+// export const getSearchs = (form, condition, col, isCenter) => {
+// const { isFormInit } = form;
+// const formParams = form.getFormParams();
+// let group = [];
+// isFormInit && condition && condition.map(c =>{
+// let items = [];
+// c.items.map(fields => {
+// items.push({
+// com:(
+//
+//
+// ),
+// colSpan:1,
+// })
+// });
+// group.push(
+// )
+// });
+// return group;
+// }
+
// 渲染form表单: 一般对form的渲染都统一使用该方法
export const getSearchs = (form, condition, col, isCenter) => {
const { isFormInit } = form;
const formParams = form.getFormParams();
+ console.log("formParams: ", formParams);
let group = [];
+ console.log("condition:", condition);
isFormInit && condition && condition.map(c =>{
let items = [];
c.items.map(fields => {
diff --git a/pc4mobx/hrmSalary/util/index2.js b/pc4mobx/hrmSalary/util/index2.js
deleted file mode 100644
index bf81e977..00000000
--- a/pc4mobx/hrmSalary/util/index2.js
+++ /dev/null
@@ -1,150 +0,0 @@
-import { Spin } from 'antd';
-import { WeaSwitch } from 'comsMobx';
-import { WeaLocaleProvider, WeaAlertPage, WeaSearchGroup, WeaFormItem } from 'ecCom';
-const getLabel = WeaLocaleProvider.getLabel;
-
-// 渲染form表单: 一般对form的渲染都统一使用该方法
-export const getCustomSearchs = (form, condition, col, isCenter) => {
- const { isFormInit } = form;
- const formParams = form.getFormParams();
- let items = [];
- let group = [];
- isFormInit && condition &&
- condition.map(c =>{
- c.items.map(fields => {
- items.push({
- com:(
-
-
- ),
- colSpan:1,
- })
- });
- });
-
- if(items.length > 0) {
- group.push(
- )
- return group;
- }
-}
-
-// 渲染form表单: 一般对form的渲染都统一使用该方法
-// export const getSearchs = (form, condition, col, isCenter) => {
-// const { isFormInit } = form;
-// const formParams = form.getFormParams();
-// let group = [];
-// isFormInit && condition && condition.map(c =>{
-// let items = [];
-// c.items.map(fields => {
-// items.push({
-// com:(
-//
-//
-// ),
-// colSpan:1,
-// })
-// });
-// group.push(
-// )
-// });
-// return group;
-// }
-
-// 渲染form表单: 一般对form的渲染都统一使用该方法
-export const getSearchs = (form, condition, col, isCenter) => {
- const { isFormInit } = form;
- const formParams = form.getFormParams();
- let group = [];
- isFormInit && condition && condition.map(c =>{
- let items = [];
- c.items.map(fields => {
- items.push({
- com:(
-
-
- ),
- colSpan:1,
- })
- });
- group.push(
- )
- });
- return group;
-}
-
-// 页面加载中效果处理
-export const renderLoading = (loading) => (
-
-
-
-)
-
-// 无权限处理
-export const renderNoright = () => (
-
-
- {getLabel(2012,'对不起,您暂时没有权限!')}
-
-
-)
-
-// 暂无数据处理
-export const renderNoData = () => (
-
-
- 暂无数据
-
-
-)
\ No newline at end of file
diff --git a/pc4mobx/hrmSalary/util/response.js b/pc4mobx/hrmSalary/util/response.js
new file mode 100644
index 00000000..d93d6fab
--- /dev/null
+++ b/pc4mobx/hrmSalary/util/response.js
@@ -0,0 +1,26 @@
+/**
+ * 删除属性为空的属性
+ * @param {*} obj
+ * @returns
+ */
+export const removeProperty = (obj) => {
+ Object.keys(obj).forEach(item => {
+ if (obj[item] === undefined || obj[item] === null || obj[item] === 'null') delete obj[item]
+ })
+ return obj
+}
+
+/**
+ * condition删除为空的属性
+ */
+export const removePropertyCondition = (condition) => {
+ condition.forEach(group => {
+ group.items && group.items.forEach(item => {
+ removeProperty(item)
+ if(item.browserConditionParam) {
+ removeProperty(item.browserConditionParam)
+ }
+ })
+ })
+ return condition
+}
\ No newline at end of file