fix bug
This commit is contained in:
@ -4,7 +4,7 @@
|
||||
* @Author : Shiming
|
||||
* @Date : 2022-02-24 20:09:49
|
||||
* @LastEditors : Shiming
|
||||
* @LastEditTime : 2022-03-29 10:51:52
|
||||
* @LastEditTime : 2022-03-29 11:14:08
|
||||
* @FilePath : \\tms-obc-web\\src\\app\\routes\\partner\\rebate-management\\components\\rebate-setting\\rebate-setting.component.html
|
||||
* Copyright (C) 2022 huzhenhong. All rights reserved.
|
||||
-->
|
||||
@ -41,6 +41,7 @@
|
||||
#st
|
||||
[data]="service.$api_get_rebateConfig"
|
||||
[columns]="columns"
|
||||
[scroll]="{x: '1200px'}"
|
||||
[req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }"
|
||||
[res]="{ reName: { list: 'data.records', total: 'data.total' } }"
|
||||
[page]="{ show: true, showSize: true, pageSizes: [10, 20, 30, 50, 100, 200, 300, 500, 1000] }"
|
||||
|
||||
@ -23,7 +23,6 @@ export class ParterRebateManageMentSettingComponent implements OnInit {
|
||||
sf!: SFComponent;
|
||||
spuStatus = '1';
|
||||
_$expand = false;
|
||||
data = [{ name1: 1111 }];
|
||||
constructor(
|
||||
public router: Router,
|
||||
public ar: ActivatedRoute,
|
||||
@ -32,30 +31,12 @@ export class ParterRebateManageMentSettingComponent implements OnInit {
|
||||
public shipperservice: ShipperBaseService,
|
||||
) {}
|
||||
/**
|
||||
* 查询字段个数
|
||||
*/
|
||||
get queryFieldCount(): number {
|
||||
return Object.keys(this.schema?.properties || {}).length;
|
||||
}
|
||||
/**
|
||||
* 伸缩查询条件
|
||||
*/
|
||||
expandToggle(): void {
|
||||
this._$expand = !this._$expand;
|
||||
this.sf?.setValue('/_$expand', this._$expand);
|
||||
}
|
||||
/**
|
||||
* 查询参数
|
||||
*/
|
||||
get reqParams() {
|
||||
const params: any = Object.assign({}, this.sf?.value || {});
|
||||
delete params._$expand;
|
||||
return {
|
||||
...params,
|
||||
deadlineTime: {
|
||||
start: this.sf?.value?.deadlineTime?.[0] || '',
|
||||
end: this.sf?.value?.deadlineTime?.[1] || '',
|
||||
},
|
||||
};
|
||||
}
|
||||
ngOnInit() {
|
||||
@ -66,15 +47,22 @@ export class ParterRebateManageMentSettingComponent implements OnInit {
|
||||
initSF() {
|
||||
this.schema = {
|
||||
properties: {
|
||||
_$expand: { type: 'boolean', ui: { hidden: true } },
|
||||
month: {
|
||||
configName: {
|
||||
type: 'string',
|
||||
title: '配置名称',
|
||||
format: 'configName',
|
||||
},
|
||||
stateLocked: {
|
||||
type: 'string',
|
||||
title: '状态'
|
||||
title: '状态',
|
||||
enum: [
|
||||
{label: '全部', value: ''},
|
||||
{label: '启用', value: 0},
|
||||
{label: '禁用', value: 1},
|
||||
],
|
||||
ui: {
|
||||
widget: 'select',
|
||||
},
|
||||
|
||||
},
|
||||
}
|
||||
};
|
||||
@ -90,35 +78,44 @@ export class ParterRebateManageMentSettingComponent implements OnInit {
|
||||
this.columns = [
|
||||
{
|
||||
title: '配置名称',
|
||||
index: 'configName'
|
||||
index: 'configName',
|
||||
width: '200px',
|
||||
},
|
||||
{
|
||||
title: '配置类型',
|
||||
render: 'configType'
|
||||
render: 'configType',
|
||||
width: '200px',
|
||||
|
||||
},
|
||||
{
|
||||
title: '备注',
|
||||
index: 'remark'
|
||||
index: 'remark',
|
||||
width: '250px',
|
||||
},
|
||||
{
|
||||
title: '关联合伙人范围',
|
||||
render: 'partnerType'
|
||||
render: 'partnerType',
|
||||
width: '200px',
|
||||
},
|
||||
{
|
||||
title: '创建时间',
|
||||
index: 'enableTime'
|
||||
index: 'enableTime',
|
||||
width: '200px',
|
||||
},
|
||||
{
|
||||
title: '启用时间',
|
||||
index: 'enableTime'
|
||||
index: 'enableTime',
|
||||
width: '200px',
|
||||
},
|
||||
{
|
||||
title: '优先级',
|
||||
index: 'priority'
|
||||
index: 'priority',
|
||||
width: '100px',
|
||||
},
|
||||
{
|
||||
title: '状态',
|
||||
render: 'stateLocked'
|
||||
render: 'stateLocked',
|
||||
width: '100px',
|
||||
},
|
||||
{
|
||||
title: '操作',
|
||||
|
||||
Reference in New Issue
Block a user