bug修复
This commit is contained in:
@ -21,13 +21,13 @@ export class ParterChannelSalesListComponent implements OnInit {
|
|||||||
sf!: SFComponent;
|
sf!: SFComponent;
|
||||||
spuStatus = '1';
|
spuStatus = '1';
|
||||||
|
|
||||||
data=[{name1:1111}]
|
data = [{ name1: 1111 }]
|
||||||
constructor(
|
constructor(
|
||||||
public router: Router,
|
public router: Router,
|
||||||
public ar: ActivatedRoute,
|
public ar: ActivatedRoute,
|
||||||
public service: ChannelSalesService,
|
public service: ChannelSalesService,
|
||||||
private modalService: NzModalService
|
private modalService: NzModalService
|
||||||
) {}
|
) { }
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询参数
|
* 查询参数
|
||||||
@ -90,6 +90,17 @@ export class ParterChannelSalesListComponent implements OnInit {
|
|||||||
title: '邀请码',
|
title: '邀请码',
|
||||||
index: 'inviteCode'
|
index: 'inviteCode'
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
title: '状态',
|
||||||
|
className: 'text-center',
|
||||||
|
index: 'stateLocked',
|
||||||
|
type: 'badge',
|
||||||
|
badge: {
|
||||||
|
true: { text: '冻结', color: 'error' },
|
||||||
|
false: { text: '正常', color: 'success' }
|
||||||
|
},
|
||||||
|
width: 130
|
||||||
|
},
|
||||||
{
|
{
|
||||||
title: '操作',
|
title: '操作',
|
||||||
className: 'text-center',
|
className: 'text-center',
|
||||||
@ -100,7 +111,7 @@ export class ParterChannelSalesListComponent implements OnInit {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
text: '冻结',
|
text: '冻结',
|
||||||
click: (_record, _modal, _instance) => this.stop(_record.id),
|
click: (_record, _modal, _instance) => this.stop(_record),
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
@ -109,10 +120,10 @@ export class ParterChannelSalesListComponent implements OnInit {
|
|||||||
|
|
||||||
add() {
|
add() {
|
||||||
const modalRef = this.modalService.create({
|
const modalRef = this.modalService.create({
|
||||||
nzWidth:600,
|
nzWidth: 600,
|
||||||
nzTitle: '新增',
|
nzTitle: '新增',
|
||||||
nzContent: ParterChannelSalesEditComponent,
|
nzContent: ParterChannelSalesEditComponent,
|
||||||
nzComponentParams: {sts: 'add'}
|
nzComponentParams: { sts: 'add' }
|
||||||
});
|
});
|
||||||
modalRef.afterClose.subscribe(res => {
|
modalRef.afterClose.subscribe(res => {
|
||||||
if (res) {
|
if (res) {
|
||||||
@ -124,7 +135,7 @@ export class ParterChannelSalesListComponent implements OnInit {
|
|||||||
// 编辑
|
// 编辑
|
||||||
edit(record: STData) {
|
edit(record: STData) {
|
||||||
const modalRef = this.modalService.create({
|
const modalRef = this.modalService.create({
|
||||||
nzWidth:600,
|
nzWidth: 600,
|
||||||
nzTitle: '编辑',
|
nzTitle: '编辑',
|
||||||
nzContent: ParterChannelSalesEditComponent,
|
nzContent: ParterChannelSalesEditComponent,
|
||||||
nzComponentParams: { i: record }
|
nzComponentParams: { i: record }
|
||||||
@ -135,21 +146,23 @@ export class ParterChannelSalesListComponent implements OnInit {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
stop(record: STData) {
|
||||||
|
if (!record.stateLocked) {
|
||||||
|
const params = {
|
||||||
stop(id: any) {
|
id: record.id
|
||||||
this.modalService.confirm({
|
}
|
||||||
nzTitle: '<i>冻结确认</i>',
|
this.modalService.confirm({
|
||||||
nzContent: `<b>确定冻结该账号吗?</br>`,
|
nzTitle: '<i>冻结确认</i>',
|
||||||
// nzOnOk: () =>
|
nzContent: `<b>确定冻结该账号吗?</br>`,
|
||||||
// this.service.request('', '').subscribe(res => {
|
nzOnOk: () =>
|
||||||
// if (res) {
|
this.service.request(this.service.$api_frozenChannelSales, params).subscribe(res => {
|
||||||
// this.service.msgSrv.success('冻结成功!');
|
if (res) {
|
||||||
// this.st.reload();
|
this.service.msgSrv.success('冻结成功!');
|
||||||
// }
|
this.st.reload();
|
||||||
// })
|
}
|
||||||
});
|
})
|
||||||
|
});
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@ -19,6 +19,8 @@ export class ChannelSalesService extends BaseService {
|
|||||||
$api_listChannelSalesManagement = '/api/mdc/channelSalesManagement/list/listChannelSalesManagement';
|
$api_listChannelSalesManagement = '/api/mdc/channelSalesManagement/list/listChannelSalesManagement';
|
||||||
// 根据渠道销售id获取渠道信息
|
// 根据渠道销售id获取渠道信息
|
||||||
$api_getChannelSalesInfo = '/api/mdc/channelSalesManagement/getChannelSalesInfo';
|
$api_getChannelSalesInfo = '/api/mdc/channelSalesManagement/getChannelSalesInfo';
|
||||||
|
// 冻结渠道销售
|
||||||
|
$api_frozenChannelSales = '/api/mdc/channelSalesManagement/frozenChannelSales';
|
||||||
|
|
||||||
|
|
||||||
constructor(public injector: Injector) {
|
constructor(public injector: Injector) {
|
||||||
|
|||||||
Reference in New Issue
Block a user