Commit 732de195 authored by 前端-钟卫鹏's avatar 前端-钟卫鹏

fix:添加设置价格

parent 3602da7d
// 选择商品和会员弹框和商品规格的列
export const columnsSetMember: any[] = [
{
title: 'ID',
dataIndex: 'memberId',
align: 'center',
key: 'memberId',
},
{
title: '会员名称',
dataIndex: 'name',
align: 'center',
key: 'name',
},
{
title: '会员类型',
dataIndex: 'memberTypeName',
align: 'center',
key: 'memberTypeName',
},
{
title: '会员角色',
dataIndex: 'roleName',
align: 'center',
key: 'roleName',
},
{
title: '会员等级',
dataIndex: 'levelTag',
align: 'center',
key: 'levelTag',
}
]
export const columnsSetProduct: any[] = [
{
title: '商品ID',
dataIndex: 'id',
align: 'center',
key: 'id',
},
{
title: '商品名称',
dataIndex: 'name',
align: 'center',
key: 'name',
width: 210,
ellipsis: true,
},
{
title: '品类',
dataIndex: 'customerCategoryName',
align: 'center',
key: 'customerCategoryName',
},
{
title: '品牌',
dataIndex: 'brandName',
align: 'center',
key: 'brandName',
},
{
title: '单位',
dataIndex: 'unitName',
align: 'center',
key: 'unitName',
},
]
......@@ -2,6 +2,7 @@ import { ISchema } from '@formily/antd';
import { FORM_FILTER_PATH } from '@/formSchema/const';
import { GlobalConfig } from '@/global/config';
import { SHOP_TYPES } from '@/constants';
import { PublicApi } from '@/services/api';
// 将获取的商城转化为可用类型
const getShopTypeMap = (() => {
......@@ -250,8 +251,8 @@ export const setPriceSchema: ISchema = {
"x-component": 'MultTable',
"x-component-props": {
rowKey: 'memberId',
columns: "{{tableColumns}}",
prefix: "{{tableAddButton}}",
columns: "{{tableProductColumns}}",
prefix: "{{tableAddProductButton}}",
pagination: {
"onChange": "{{paginationChange}}",
"total": "{{membersLength}}"
......@@ -282,8 +283,8 @@ export const setPriceSchema: ISchema = {
"x-component": 'MultTable',
"x-component-props": {
rowKey: 'memberId',
columns: "{{tableColumns}}",
prefix: "{{tableAddButton}}",
columns: "{{tableMemberColumns}}",
prefix: "{{tableAddMemberButton}}",
pagination: {
"onChange": "{{paginationChange}}",
"total": "{{membersLength}}"
......@@ -298,3 +299,135 @@ export const setPriceSchema: ISchema = {
}
}
}
// 选择商品和会员高级筛选
export const formSearch: ISchema = {
type: 'object',
properties: {
name: {
type: 'string',
'x-component': 'ModalSearch',
'x-component-props': {
placeholder: '请输入会员名字',
align: 'flex-left',
},
},
[FORM_FILTER_PATH]: {
type: 'object',
'x-component': 'flex-layout',
'x-component-props': {
rowStyle: {
flexWrap: 'nowrap',
style: {
marginRight: 0
}
},
colStyle: {
marginTop: 20,
},
},
properties: {
memberTypeId: {
type: 'string',
"x-component": 'Select',
"x-component-props": {
options: [],
style: {width: '180px'},
placeholder: '请选择会员类型'
}
},
level: {
type: 'string',
"x-component": 'Select',
"x-component-props": {
options: [],
style: {width: '180px'},
placeholder: '请选择会员等级'
}
},
roleId: {
type: 'string',
"x-component": 'Select',
"x-component-props": {
options: [],
style: {width: '180px'},
placeholder: '请选择会员角色'
}
},
submit: {
"x-component": 'Submit',
"x-mega-props": {
span: 1
},
"x-component-props": {
children: '查询'
}
}
}
}
}
}
export const formProduct: ISchema = {
type: 'object',
properties: {
name: {
type: 'string',
'x-component': 'ModalSearch',
'x-component-props': {
placeholder: '请输入商品名称',
align: 'flex-left',
},
},
[FORM_FILTER_PATH]: {
type: 'object',
'x-component': 'flex-layout',
'x-component-props': {
rowStyle: {
flexWrap: 'nowrap',
style: {
marginRight: 0
}
},
colStyle: {
marginTop: 20,
},
},
properties: {
customerCategoryId: {
type: 'string',
"x-component": 'SearchSelect',
"x-component-props": {
placeholder: '请选择品类',
className: 'fixed-ant-selected-down', // 该类强制将显示的下拉框出现在select下, 只有这里出现问题, ??
fetchSearch: PublicApi.getProductSelectGetSelectCustomerCategory,
style: {
width: 160
}
}
},
brandId: {
type: 'string',
"x-component": 'SearchSelect',
"x-component-props": {
placeholder: '请选择品牌',
fetchSearch: PublicApi.getProductSelectGetSelectBrand,
style: {
width: 160
}
}
},
submit: {
"x-component": 'Submit',
"x-mega-props": {
span: 1
},
"x-component-props": {
children: '查询'
}
}
}
}
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment