Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
上
上药订单生命周期升级
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
sph
上药订单生命周期升级
Commits
c3a40599
Commit
c3a40599
authored
Mar 16, 2021
by
xiejb
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加获取订单列表
parent
6aacc9d6
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
120 additions
and
47 deletions
+120
-47
src/api/myOrder.js
src/api/myOrder.js
+1
-1
src/assets/img/order.png
src/assets/img/order.png
+0
-0
src/views/myInvoice/index.vue
src/views/myInvoice/index.vue
+15
-1
src/views/myOrder/components/HighSearch.vue
src/views/myOrder/components/HighSearch.vue
+2
-2
src/views/myOrder/index.vue
src/views/myOrder/index.vue
+9
-6
src/views/myOrder/myOrderList.vue
src/views/myOrder/myOrderList.vue
+55
-18
src/views/myOrder/orderInvoice/invoiecDetail/orderInvoiecListItem.vue
...Order/orderInvoice/invoiecDetail/orderInvoiecListItem.vue
+1
-1
src/views/myOrder/orderListItem.vue
src/views/myOrder/orderListItem.vue
+37
-18
No files found.
src/api/myOrder.js
View file @
c3a40599
...
...
@@ -2,7 +2,7 @@ import { fetch } from '@/utils'
// 获取商品列表
export
function
getMyOrderList
(
params
)
{
return
fetch
({
url
:
'
/
product/queryGoods_PS
'
,
url
:
'
/
OrderLife/queryOrder
'
,
method
:
'
post
'
,
data
:
params
,
loading
:
true
...
...
src/assets/img/order.png
0 → 100644
View file @
c3a40599
1.97 KB
src/views/myInvoice/index.vue
View file @
c3a40599
...
...
@@ -48,7 +48,7 @@ export default {
return
time
}
},
moun
ted
()
{
activa
ted
()
{
// 设置标题栏关闭返回按钮
this
.
$store
.
commit
(
'
setNavBar
'
,
{
show
:
true
,
...
...
@@ -62,6 +62,20 @@ export default {
// 给window添加一个popstate事件,拦截返回键,执行this.onBrowserBack事件,addEventListener需要指向一个方法
window
.
addEventListener
(
'
popstate
'
,
this
.
onBrowserBack
,
false
)
},
mounted
()
{
// 设置标题栏关闭返回按钮
// this.$store.commit('setNavBar', {
// show: true,
// leftArrow: true,
// rightIcon: true,
// title: '发票',
// leftText: '',
// leftClick: this.closeAppPage,
// rightClick: this.onMoreSearch
// })
// // 给window添加一个popstate事件,拦截返回键,执行this.onBrowserBack事件,addEventListener需要指向一个方法
// window.addEventListener('popstate', this.onBrowserBack, false)
},
destroyed
()
{
// 当页面销毁必须要移除这个事件,vue不刷新页面,不移除会重复执行这个事件
window
.
removeEventListener
(
'
popstate
'
,
this
.
onBrowserBack
,
false
)
...
...
src/views/myOrder/components/HighSearch.vue
View file @
c3a40599
...
...
@@ -16,7 +16,7 @@
<div
class=
"high-info"
>
<div
class=
"title font-bold font-16"
>
请输入订单号
</div>
<!--
<div
contenteditable=
"true"
class=
"inputInfo"
>
{{
orderNo
}}
</div>
-->
<input
:value=
"
orderNo"
class=
"input"
type=
"text"
>
<input
v-model=
"moreSearchInfo.
orderNo"
class=
"input"
type=
"text"
>
</div>
<div
class=
"high-info"
@
click=
"showPost('supplier')"
>
<div
class=
"title font-bold font-16"
>
供应商
</div>
...
...
@@ -216,7 +216,7 @@ export default {
},
methods
:
{
timeConfirm
(
data
)
{
this
.
time
=
data
this
.
moreSearchInfo
.
time
=
data
},
onSearchClick
()
{
this
.
moreSearchShow
=
false
...
...
src/views/myOrder/index.vue
View file @
c3a40599
...
...
@@ -22,7 +22,7 @@
v-for=
"(item, index) in tabsTitle"
:key=
"index"
:title=
"item.title"
>
<my-order-list
:ref=
"item.name"
:
activeTab=
"activeTab"
:more-search-info=
"moreSearchInfo
"
@
orderItemAction=
"orderItemAction"
/>
<my-order-list
:ref=
"item.name"
:
orderTypeCode=
"item.orderTypeCode"
:activeTab=
"activeTab
"
@
orderItemAction=
"orderItemAction"
/>
</van-tab>
</van-tabs>
<high-search
v-model=
"moreSearchShow"
@
onsearch=
"moreSearchConfirm"
@
onclean=
"moreSearchClean"
/>
...
...
@@ -35,11 +35,11 @@ import HighSearch from './components/HighSearch.vue'
import
{
getFormateDate
}
from
'
@/utils/common
'
import
{
bridge
}
from
"
@/utils
"
;
const
allTabsTitle
=
[
{
title
:
'
全部
'
,
name
:
'
all
'
},
{
title
:
'
已开单
'
,
name
:
'
billing
'
},
{
title
:
'
已发货
'
,
name
:
'
ship
'
},
{
title
:
'
已
完成
'
,
name
:
'
carryOut
'
},
{
title
:
'
已取消
'
,
name
:
'
cancel
'
}
{
title
:
'
全部
'
,
name
:
'
all
'
,
orderTypeCode
:
''
},
{
title
:
'
待发货
'
,
name
:
'
billing
'
,
orderTypeCode
:
'
100
'
},
{
title
:
'
待收货
'
,
name
:
'
ship
'
,
orderTypeCode
:
'
220
'
},
{
title
:
'
已
签收
'
,
name
:
'
carryOut
'
,
orderTypeCode
:
'
400
'
},
{
title
:
'
已取消
'
,
name
:
'
cancel
'
,
orderTypeCode
:
'
110
'
}
]
export
default
{
components
:
{
...
...
@@ -176,10 +176,13 @@ export default {
// this.$refs.all[0].httpAction(this.moreSearchInfo)
})
this
.
moreSearchInfo
=
JSON
.
parse
(
JSON
.
stringify
(
data
))
console
.
log
(
data
)
console
.
log
(
this
.
moreSearchInfo
)
this
.
$EventBus
.
$emit
(
'
myOrderMoreSearch
'
,
this
.
moreSearchInfo
)
},
// 高级搜索取消
moreSearchClean
(
data
)
{
console
.
log
(
this
.
moreSearchInfo
)
this
.
moreSearchInfo
=
JSON
.
parse
(
JSON
.
stringify
(
data
))
this
.
$EventBus
.
$emit
(
'
myOrderMoreSearch
'
,
this
.
moreSearchInfo
)
},
...
...
src/views/myOrder/myOrderList.vue
View file @
c3a40599
...
...
@@ -66,6 +66,7 @@
// 引入接口
import
{
getMyOrderList
}
from
'
@/api/myOrder
'
import
orderListItem
from
'
./orderListItem.vue
'
import
{
getFormateDate
}
from
'
@/utils/common
'
import
{
valid
}
from
'
semver
'
export
default
{
name
:
'
MyOrderList
'
,
...
...
@@ -84,17 +85,25 @@ export default {
orderList
:
[],
orderItem
:
{},
sphImage
:
require
(
'
@/assets/img/u48.png
'
),
moreSearchInfo
:
{
supplier
:
''
,
// 供应商
consignor
:
[],
// 货主
goods
:
''
,
// 商品
client
:
''
,
// 客户
orderNo
:
''
,
time
:
{
start
:
getFormateDate
(
new
Date
(),
'
yyyy-MM-dd
'
),
end
:
getFormateDate
(
new
Date
(),
'
yyyy-MM-dd
'
)
}
}
}
},
props
:
{
moreSearchInfo
:
{
type
:
Object
,
default
:
()
=>
{
return
{
}
}
},
activeTab
:
''
activeTab
:
''
,
orderTypeCode
:
{
type
:
String
,
default
:
''
}
},
computed
:
{
linkInfo
()
{
...
...
@@ -110,9 +119,10 @@ export default {
},
mounted
()
{
// this.onLoad()
let
_this
=
this
this
.
$EventBus
.
$on
(
'
myOrderMoreSearch
'
,
(
model
)
=>
{
// console.log(model)
this
.
onRefresh
()
_this
.
moreSearchInfo
=
model
_
this
.
onRefresh
()
})
},
watch
:
{
...
...
@@ -142,23 +152,50 @@ export default {
getPostData
()
{
let
_this
=
this
let
data
=
{
'
dbName
'
:
'
erp_test_shaphar-上药控股有限公司-204-23528
'
,
// 'erp_ogg_shaphar',
'
start
'
:
_this
.
currentPage
,
'
length
'
:
_this
.
pageSize
,
'
goods
'
:
''
'
businessType
'
:
''
,
'
clientID
'
:
[
'
3168
'
],
// 客户编码
'
endDate
'
:
_this
.
moreSearchInfo
.
time
.
end
,
// 结束时间
'
startDate
'
:
_this
.
moreSearchInfo
.
time
.
start
,
// 开始时间
'
goodsCode
'
:
''
,
// 商品代码
'
goodsDesc
'
:
''
,
// 商品描述
'
goodsId
'
:
''
,
// 商品ID
'
goodsName
'
:
''
,
// 商品名称
'
goodsSpec
'
:
''
,
// 商品规格
'
isDelivered
'
:
''
,
// 是否配送 TRUE是/FALSE
'
isInvoice
'
:
''
,
// 是否开票 TURE 是 FALSE 否
'
isWeb
'
:
''
,
// 是否网单 TURE 是FALSE 否
'
manufacturer
'
:
''
,
// 生产企业
'
mdmClientCode
'
:
''
,
// 主数据客户编码
'
order
'
:
''
,
'
orderId
'
:
''
,
// 订单ID
'
orderNo
'
:
!
_this
.
moreSearchInfo
.
orderNo
?
''
:
_this
.
moreSearchInfo
.
orderNo
,
// 订单号
// 订单状态ERP 100 已开单110 已取消180 已完(销退)WMS200 待出库210 拣配中220 已出库TMS300 调度中310 运输中400 已签收410 签收执420 拒收
'
orderStatusCode
'
:
_this
.
orderTypeCode
,
'
orderType
'
:
'
SALE
'
,
// 订单类型 正常销售SALE销售退货SALE_RTN
'
pageNum
'
:
_this
.
currentPage
,
'
pageSize
'
:
_this
.
pageSize
,
'
shippingAdress
'
:
''
,
// 送货地址
'
sort
'
:
''
,
'
sourceDb
'
:
'
SHYY
'
,
// 数据来源
'
sourceOrderNo
'
:
''
,
// 来源订单号(网上订单号)
'
sourceSystem
'
:
''
,
// 订单来源 来源订单号和订单来源必须同时不为空
'
supplierId
'
:
[
]
// 供应商(部门)编码
}
getMyOrderList
(
data
).
then
(
rt
=>
{
if
(
rt
.
code
===
1
||
rt
.
code
===
'
1
'
)
{
if
(
rt
.
data
.
code
===
'
00000
'
)
{
if
(
_this
.
isRefreshing
)
{
_this
.
orderList
=
rt
.
data
_this
.
orderList
=
rt
.
data
.
entity
.
orderList
}
else
if
(
rt
.
data
||
rt
.
data
.
length
>
0
)
{
_this
.
orderList
=
_this
.
orderList
.
concat
(
rt
.
data
)
_this
.
orderList
=
_this
.
orderList
.
concat
(
rt
.
data
.
entity
.
orderList
)
}
// 重置刷新提示
_this
.
isRefreshing
=
false
// 重置加载更多提示
_this
.
isLoading
=
false
if
(
rt
.
data
.
length
<
10
)
{
if
(
rt
.
data
.
entity
.
orderList
.
length
<
10
)
{
_this
.
finished
=
true
}
else
{
// 加载成功后下一页自增1
...
...
src/views/myOrder/orderInvoice/invoiecDetail/orderInvoiecListItem.vue
View file @
c3a40599
...
...
@@ -4,7 +4,7 @@
<div
class=
"orderNum"
>
<van-image
fit=
"contain"
width=
"45"
height=
"50"
:src=
"sphImage"
/>
<div
class=
"num"
>
订单号:34678649876
</div>
<van-button
style=
"margin: auto;"
class=
"numBtn"
round
plain
size=
"mini"
type=
"info"
>
复制
</van-button>
<van-button
style=
"margin: auto;
width: 50PX
"
class=
"numBtn"
round
plain
size=
"mini"
type=
"info"
>
复制
</van-button>
</div>
<div
class=
"divider"
></div>
<div
class=
"invoiecInfo"
>
...
...
src/views/myOrder/orderListItem.vue
View file @
c3a40599
...
...
@@ -4,46 +4,48 @@
<div
class=
"orderNum"
>
<van-image
fit=
"contain"
width=
"50"
height=
"55"
:src=
"sphImage"
/>
<div
class=
"num"
>
<div
class=
"numBer"
>
订单号:34678649876
</div>
<van-button
color=
"#D9001B"
class=
"numBtn"
round
plain
size=
"mini"
type=
"info"
>
退
</van-button>
<van-button
color=
"#4b7902"
class=
"numBtn"
round
plain
size=
"mini"
type=
"info"
>
冷
</van-button>
<van-button
color=
"#02a7f0"
class=
"numBtn"
round
plain
size=
"mini"
type=
"info"
>
精麻
</van-button>
<div
class=
"numBer"
>
订单号:
{{
item
.
orderNo
}}
</div>
<!--
<van-button
color=
"#D9001B"
class=
"numBtn"
round
plain
size=
"mini"
type=
"info"
>
退
</van-button>
-->
<!--
<van-button
color=
"#4b7902"
class=
"numBtn"
round
plain
size=
"mini"
type=
"info"
>
冷
</van-button>
-->
<!--
<van-button
color=
"#02a7f0"
class=
"numBtn"
round
plain
size=
"mini"
type=
"info"
>
精麻
</van-button>
-->
</div>
<!--
<div
class=
"dian"
></div>
-->
<!--
<div
class=
"numType"
><span>
{{
item
.
orderStatus
}}
</span></div>
-->
<div
class=
"numType"
>
<van-button
:color=
"orderTypeColor(item)"
plain
size=
"mini"
type=
"info"
>
{{
item
.
orderStatus
}}
</van-button>
</div>
<div
class=
"dian"
></div>
<div
class=
"numType"
><span>
已开单
</span></div>
</div>
<div
class=
"divider"
></div>
<div
class=
"orderInfo"
>
<div
class=
"company"
@
click=
"btnAction('details')"
>
<span
style=
"width:
83%"
>
上药控股有限公司
</span>
<span
style=
"
margin-right: 5PX;"
>
共8件
</span>
<span
style=
"width:
75%"
>
{{
item
.
sourceSystem
}}
</span>
<span
style=
"
width: 25%;margin-right: 5PX;text-align: right;"
>
共
{{
item
.
orderTotalQty
}}
</span>
<van-icon
style=
"margin: auto 0;"
color=
"#1989fa"
name=
"arrow"
/>
</div>
<div
class=
"info"
@
click=
"btnAction('details')"
>
<div
class=
"headImage"
>
<van-image
width=
"55"
height=
"55"
src=
"https://img01.yzcdn.cn/vant/cat.jpeg"
/>
<van-image
width=
"55"
height=
"55"
:src=
"orderImage"
/>
</div>
<div
class=
"details"
>
<div
class=
"titleInfo"
>
[132521]阿西匹林/0.25g*s/上海市浦东新区金科路长泰广场负一楼
{{
item
.
goodsInfos
[
0
].
goodsDesc
}}
</div>
<div
class=
"priceInfo"
>
<div
class=
"price"
>
¥
<span
style=
"color:red;"
>
10.5
</span></div>
<div
class=
"numBer"
>
X
8
</div>
<div
class=
"price"
>
¥
<span
style=
"color:red;"
>
{{
item
.
goodsInfos
[
0
].
taxPrice
}}
</span></div>
<div
class=
"numBer"
>
X
{{
item
.
goodsInfos
[
0
].
orderQty
}}
</div>
</div>
</div>
</div>
<div
class=
"orderTime"
@
click=
"btnAction('details')"
>
<van-icon
size=
"20"
style=
"margin: auto 0; width: 7%;"
name=
"clock-o"
/>
<span
style=
"width: 50%;"
>
2020-11-10 18:09:33
</span>
<div
class=
"price"
>
总计:¥
<span
style=
"color:red;"
>
10.5
</span></div>
<span
style=
"width: 50%;"
>
{{
item
.
orderDate
}}
</span>
<div
class=
"price"
>
总计:¥
<span
style=
"color:red;"
>
{{
item
.
orderTotalAmount
}}
</span></div>
</div>
<van-divider
:style=
"
{ color: '#999999', borderColor: '#999999', margin: '10PX 0 10PX 0'}"/>
<div
class=
"btnInfo"
style=
"text-align: right;"
>
<van-button
@
click=
"btnAction('invoice')"
style=
"border-radius: 5PX;"
plain
size=
"small"
type=
"info"
>
查看发票
</van-button>
<van-button
@
click=
"btnAction('logistics')"
style=
"border-radius: 5PX;"
plain
size=
"small"
type=
"info"
>
查看物流
</van-button>
<van-button
@
click=
"btnAction('clearance')"
style=
"border-radius: 5PX;"
plain
size=
"small"
type=
"info"
>
清货单
</van-button>
<van-button
v-if=
"item.isInvoice === 'TRUE'"
@
click=
"btnAction('invoice')"
style=
"border-radius: 5PX;"
plain
size=
"small"
type=
"info"
>
查看发票
</van-button>
<van-button
v-if=
"item.isDelivered === 'TRUE'"
@
click=
"btnAction('logistics')"
style=
"border-radius: 5PX;"
plain
size=
"small"
type=
"info"
>
查看物流
</van-button>
<van-button
v-if=
"item.isWeb === 'TRUE'"
@
click=
"btnAction('clearance')"
style=
"border-radius: 5PX;"
plain
size=
"small"
type=
"info"
>
清货单
</van-button>
</div>
</div>
</div>
...
...
@@ -58,6 +60,7 @@ export default {
data
()
{
return
{
sphImage
:
require
(
'
@/assets/img/u48.png
'
),
orderImage
:
require
(
'
@/assets/img/order.png
'
)
}
},
props
:
{
...
...
@@ -85,6 +88,22 @@ export default {
// this.onLoad()
},
methods
:
{
// 根据订单类型返回颜色
orderTypeColor
(
model
)
{
if
(
model
.
orderStatusCode
===
'
100
'
)
{
// 待发货
return
'
#53BE00
'
}
else
if
(
model
.
orderStatusCode
===
'
220
'
)
{
// 待收货
return
'
#E6C500
'
}
else
if
(
model
.
orderStatusCode
===
'
400
'
)
{
// 已签收
return
'
#4b7902
'
}
else
if
(
model
.
orderStatusCode
===
'
110
'
)
{
// 已取消
return
'
#D9001B
'
}
},
onRefresh
()
{
},
// 查看发票 查看物流 清货单
...
...
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