Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
J
jinfa-platform
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
linweijiong
jinfa-platform
Commits
e21cfc89
Commit
e21cfc89
authored
Aug 31, 2020
by
前端-许佳敏
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
script脚本更新
parent
97156771
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
142 additions
and
8 deletions
+142
-8
index.js
scripts/services/index.js
+1
-1
index.tsx
src/components/DropDeleteDown/index.tsx
+22
-0
index.tsx
src/components/NiceForm/index.tsx
+2
-1
index.tsx
src/components/NiceForm/public/index.tsx
+12
-1
index.tsx
src/pages/transaction/purchaseOrder/readyAddOrder/index.tsx
+55
-2
index.ts
...s/transaction/purchaseOrder/readyAddOrder/schema/index.ts
+48
-0
index.ts
src/store/channelProduct/index.ts
+2
-3
No files found.
scripts/services/index.js
View file @
e21cfc89
...
...
@@ -37,7 +37,7 @@ const serviceConfig = {
shopInfo
:
{
url
:
'/manage/shop/findShopsBySiteId'
,
params
:
{
siteId
:
50
2
siteId
:
35
2
},
method
:
'get'
},
...
...
src/components/DropDeleteDown/index.tsx
0 → 100644
View file @
e21cfc89
import
React
,
{
ReactElement
}
from
'react'
import
{
Dropdown
,
Button
}
from
'antd'
import
{
DownOutlined
}
from
'@ant-design/icons'
export
interface
DropDeleteDownProps
{
children
:
ReactElement
}
const
DropDeleteDown
:
React
.
FC
<
DropDeleteDownProps
>
=
(
props
)
=>
{
return
(
<
Dropdown
overlay=
{
props
.
children
}
trigger=
{
[
'click'
]
}
>
<
Button
>
更多
<
DownOutlined
/>
</
Button
>
</
Dropdown
>
)
}
DropDeleteDown
.
defaultProps
=
{}
export
default
DropDeleteDown
\ No newline at end of file
src/components/NiceForm/index.tsx
View file @
e21cfc89
...
...
@@ -2,7 +2,7 @@ import React from 'react';
import
SchemaForm
,
{
IAntdSchemaFormProps
,
createVirtualBox
,
registerVirtualBox
,
Schema
,
SchemaField
,
FormButtonGroup
,
Reset
,
createControllerBox
,
registerValidationRules
,
}
from
'@formily/antd'
;
import
{
Button
,
Space
,
Row
,
Col
}
from
'antd'
;
import
{
Button
,
Space
,
Row
,
Col
,
DatePicker
}
from
'antd'
;
import
CustomUpload
from
'./components/CustomUpload'
;
import
CustomStatus
from
'./components/CustomStatus'
;
import
CustomAddArray
from
'./components/CustomAddArray'
;
...
...
@@ -87,6 +87,7 @@ export const componentExport = {
Phone
,
SearchSelect
,
Input
,
DateRangePicker
:
DatePicker
.
RangePicker
,
TableTagList
,
}
const
NiceForm
:
React
.
FC
<
NiceFormProps
>
=
props
=>
{
...
...
src/components/NiceForm/public/index.tsx
View file @
e21cfc89
// 全局注册虚拟布局组件
import
React
from
'react'
import
{
registerVirtualBox
,
SchemaField
}
from
"@formily/antd"
import
{
Col
,
Row
}
from
'antd'
import
{
Col
,
Row
,
Space
}
from
'antd'
import
cx
from
'classnames'
import
styled
from
'styled-components'
...
...
@@ -54,4 +54,14 @@ registerVirtualBox('empty-layout', (_props) => {
return
(
<
div
>
{
children
}
</
div
>
)
})
// 操作按钮集合
registerVirtualBox
(
'controller-group'
,
(
_props
)
=>
{
const
{
children
,
props
}
=
_props
return
(
<
Space
>
{
children
}
</
Space
>
)
})
\ No newline at end of file
src/pages/transaction/purchaseOrder/readyAddOrder/index.tsx
View file @
e21cfc89
import
React
from
'react'
import
{
Card
}
from
'antd'
import
{
Card
,
Button
,
Space
,
Dropdown
,
Menu
}
from
'antd'
import
{
StandardTable
}
from
'god'
import
{
PageHeaderWrapper
}
from
'@ant-design/pro-layout'
import
{
PublicApi
}
from
'@/services/api'
import
{
useReadyAddOrder
}
from
'./model/useReadyAddOrder'
import
{
PlusCircleOutlined
,
DownOutlined
,
DeleteOutlined
}
from
'@ant-design/icons'
import
DropDeleteDown
from
'@/components/DropDeleteDown'
import
{
tableListSchema
}
from
'./schema'
import
{
useStateFilterSearchLinkageEffect
}
from
'@/formSchema/effects/useFilterSearch'
import
{
FORM_FILTER_PATH
}
from
'@/formSchema/const'
import
Submit
from
'@/components/NiceForm/components/Submit'
import
{
DatePicker
}
from
'@formily/antd-components'
// 待新增订单
...
...
@@ -13,19 +20,65 @@ const fetchTableData = async (params) => {
const
{
data
}
=
await
PublicApi
.
getOrderProcurementStayAddList
(
params
)
return
data
}
// TODO
const
ReadyAddOrder
:
React
.
FC
<
ReadyAddOrderProps
>
=
(
props
)
=>
{
const
{
columns
}
=
useReadyAddOrder
()
const
handleMenuClick
=
(
e
)
=>
{
switch
(
e
.
key
)
{
case
'1'
:
{
// 批量删除
break
;
}
}
}
return
<
PageHeaderWrapper
>
<
Card
>
<
StandardTable
fetchTableData=
{
params
=>
fetchTableData
(
params
)
}
columns=
{
columns
}
formilyLayouts=
{
{
justify
:
'space-between'
}
}
formilyProps=
{
{
ctx
:
{
inline
:
false
,
schema
:
tableListSchema
,
effects
:
(
$
,
actions
)
=>
{
useStateFilterSearchLinkageEffect
(
$
,
actions
,
'orderNo'
,
FORM_FILTER_PATH
,
);
},
components
:
{
DateRangePicker
:
DatePicker
.
RangePicker
,
Submit
}
},
layouts
:
{
order
:
2
,
span
:
16
}
}
}
formilyChilds=
{
{
children
:
<
Space
>
<
Button
icon=
{
<
PlusCircleOutlined
/>
}
type=
'primary'
>
新建
</
Button
>
<
Button
>
批量提交审核
</
Button
>
<
DropDeleteDown
>
<
Menu
onClick=
{
(
e
)
=>
handleMenuClick
(
e
)
}
>
<
Menu
.
Item
key=
"1"
icon=
{
<
DeleteOutlined
/>
}
>
批量删除
</
Menu
.
Item
>
</
Menu
>
</
DropDeleteDown
>
</
Space
>,
layouts
:
{
span
:
8
}
}
}
/>
...
...
src/pages/transaction/purchaseOrder/readyAddOrder/schema/index.ts
View file @
e21cfc89
import
{
ISchema
}
from
'@formily/antd'
;
import
{
FORM_FILTER_PATH
}
from
'@/formSchema/const'
;
export
const
tableListSchema
:
ISchema
=
{
type
:
'object'
,
properties
:
{
orderNo
:
{
type
:
'string'
,
"x-component"
:
'SearchFilter'
,
'x-component-props'
:
{
placeholder
:
'搜索'
,
align
:
'flex-end'
,
},
},
[
FORM_FILTER_PATH
]:
{
type
:
'object'
,
'x-component'
:
'flex-layout'
,
'x-component-props'
:
{
inline
:
true
,
colStyle
:
{
marginLeft
:
20
}
},
properties
:
{
orderThe
:
{
type
:
'string'
,
'x-component-props'
:
{
placeholder
:
'请输入订单摘要'
,
}
},
"[startCreateTime,endCreateTime]"
:
{
type
:
'array'
,
"x-component"
:
'daterangepicker'
,
'x-component-props'
:
{
placeholder
:
[
'开始时间'
,
'结束时间'
],
},
},
submit
:
{
'x-component'
:
'Submit'
,
'x-component-props'
:
{
children
:
'查询'
,
},
},
},
},
}
}
\ No newline at end of file
src/store/channelProduct/index.ts
View file @
e21cfc89
import
{
action
,
computed
,
observable
,
runInAction
}
from
'mobx'
import
{
IChannelProductModule
}
from
'@/module/channelProductModule'
;
// mobx要用到的数据类型
import
{
GetProductChannelCommodityGetCommodityListResponseDetail
}
from
'@/services'
;
/**
* 渠道直采商品
...
...
@@ -8,7 +7,7 @@ import { GetProductChannelCommodityGetCommodityListResponseDetail } from '@/serv
class
ChannelProductStore
implements
IChannelProductModule
{
// 选择商品区块
@
observable
public
productSelectRowInStore
:
GetProductChannelCommodityGetCommodityListResponseDetail
=
null
;
@
observable
public
productSelectRowInStore
:
any
=
null
;
@
observable
public
priceType
:
number
=
null
@
observable
public
productName
:
string
=
null
...
...
@@ -22,7 +21,7 @@ class ChannelProductStore implements IChannelProductModule {
// }
@
action
.
bound
public
setProductSelectRowInStore
(
data
:
GetProductChannelCommodityGetCommodityListResponseDetail
)
{
public
setProductSelectRowInStore
(
data
:
any
)
{
this
.
productSelectRowInStore
=
data
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment