Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
W
wly-APP
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
刘川
wly-APP
Commits
f9e98733
Commit
f9e98733
authored
May 19, 2022
by
chuan.liu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
非配额订单下单 mock数据联调
parent
5385314a
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
433 additions
and
64 deletions
+433
-64
order-upload.nvue
pages/no-quota/order-upload.nvue
+136
-15
quota-order.nvue
pages/no-quota/quota-order.nvue
+257
-46
quota-order.nvue
pages/quota/quota-order.nvue
+1
-1
select-product.vue
pages/select-product/select-product.vue
+7
-2
noQuotaOrder.js
servers/noQuotaOrder.js
+26
-0
index.js
store/index.js
+6
-0
No files found.
pages/no-quota/order-upload.nvue
View file @
f9e98733
...
@@ -6,7 +6,8 @@
...
@@ -6,7 +6,8 @@
<text class="upload-text">附件上传</text>
<text class="upload-text">附件上传</text>
</view>
</view>
<view class="upload-block">
<view class="upload-block">
<uni-file-picker ref='files' :auto-upload='false' v-model="fileList" file-mediatype="image" :imageStyles="imageStyles" @select="select" @progress="progress" @success="success" @fail='fail'>
<uni-file-picker ref='files' :auto-upload='false' v-model="fileList" file-mediatype="image"
:imageStyles="imageStyles" @select="select" @progress="progress" @success="success" @fail='fail'>
<text>+</text>
<text>+</text>
</uni-file-picker>
</uni-file-picker>
</view>
</view>
...
@@ -29,7 +30,7 @@
...
@@ -29,7 +30,7 @@
<image class="popup-content-head__icon" src="@/static/image/icon_plan@3x.png" mode=""></image>
<image class="popup-content-head__icon" src="@/static/image/icon_plan@3x.png" mode=""></image>
</view>
</view>
<view class="popup-content-content">
<view class="popup-content-content">
<text class="popup-content-content__title">
支付
成功</text>
<text class="popup-content-content__title">
提交
成功</text>
<text class="popup-content-content__title2">订单号:{{ orderNo }}</text>
<text class="popup-content-content__title2">订单号:{{ orderNo }}</text>
</view>
</view>
<view class="popup-content-foot">
<view class="popup-content-foot">
...
@@ -43,15 +44,26 @@
...
@@ -43,15 +44,26 @@
</template>
</template>
<script>
<script>
import {
apiUpdateNoQuotaOrder
} from '@/servers/noQuotaOrder.js'
import {
mapMutations,
mapState
} from 'vuex'
export default {
export default {
data() {
data() {
return {
return {
orderNo: '',
orderNo: '',
orderInfo: {},
fileList: [],
fileList: [],
}
}
},
},
computed:{
computed: {
imageStyles(){
...mapState(['noQuotaOrder']),
imageStyles() {
return {
return {
width: 64,
width: 64,
height: 64,
height: 64,
...
@@ -62,6 +74,113 @@
...
@@ -62,6 +74,113 @@
},
},
},
},
methods: {
methods: {
async updateQuotaOrder() {
const params = {
"MODE": "SAVE",
"info": {
"GUID": "00000000000000000000000000000000",
"OBJECT_ID": "",
"PROCESS_TYPE": "ZS01",
"CUSTOMER": "0050000215",
"CUST_NAME": "崇州顺辰商贸有限公司",
"CUSTOMER_TYPE": "V003",
"ZZFLD000000": "",
"ZZFLD000028": "",
"ZZFLD00002D": "81000010",
"ZZFLD00002D_DSCR": "董平",
"POSTING_DATE": "20220321",
"STATUS": "E0001",
"ZZFLD000001": "0005000006",
"ZZFLD00003E": "",
"ZZFLD000002": "230",
"ZZFLD000003": "000000510100",
"ZZFLD000004": "",
"ZZFLD000004_DSCR": "",
"ZZFLD00002J": "",
"ZZFLD00002K": "",
"ZZFLD00002L": "",
"ZZFLD00002M": "",
"ZZFLD00002N": "",
"SALES_ORG": "0 50000025",
"CHANNEL": "",
"DIVISION": "",
"CUST_PRIC_PROC": "1",
"TAX_GROUP_BP_01": "FULL",
"ZZFLD00003C": "",
"ZZFLD00009O": "0.00",
"ZZFLD00009Q": "0.00",
"ZHKYE": "0.00"
},
'ITEM': [{
"GUID": "00000000000000000000000000000000",
"HEADER": "00000000000000000000000000000000",
"NUMBER_INT": "0000000010",
"ITM_TYPE": "",
"ZZFLD000029": "V001",
"ZZFLD000005": "3800000826",
"ZZFLD000005_Z1": "",
"ZZFLD000006": "20220322",
"ZZFLD00002Q": "V001",
"ZZFLD00002Q_Z1": "",
"ORDERED_PROD": "040001005280115668",
"DESCRIPTION": "五粮液.1618(131) 52%618mL×6",
"ZZFLD00002S": "52%618ML×6",
"UNIT": "KAR",
"ZZFLD00002T": "盒",
"QUANTITY": 6.000,
"ZZFLD00002U": 6.00,
"ZZFLD00002W": 6.00,
"ZZFLD000009": 1.00,
"INVENTORY": 0.00,
"ZZFLD00002E": " 13.00%",
"NET_PRICE": 769.00,
"ZZFLD00002X": 769.00,
"NET_VALUE": 4614.00,
"ZZFLD00002Z": 4614.00,
"ZZFLD00002A": "",
"ZZFLD00002F": " 100.00%",
"ZZFLD00002G": 769.00,
"ZZFLD00002I": 0.00,
"ZZFLD000007": 0.00,
"ZZFLD000032": 0.00,
"ZZFLD00002O": 0.00,
"ZZFLD000035": 0.00,
"ZZFLD00002B": "",
"ZZFLD000008": "",
"ZZFLD00002P": "0000000000",
"CURRENCY": "",
"MODE": "",
"WAREHOUSE": "",
"PRDTYPE": "",
"YEAR": "0000",
"ZZFLD00002Q_D": ""
}],
"item_d": [],
"USE": [],
"attachment": []
}
const res = await apiUpdateNoQuotaOrder(params)
const {
ATTACHMENT,
HISTORY,
INFO,
ITEM
} = res.DATA
const params2 = {
"USER_BP": "81000010",
"MODE": "SUBMIT",
"info": INFO,
'ITEM': ITEM,
"item_d": [],
"attachment": ATTACHMENT
}
const res2 = await apiUpdateNoQuotaOrder(params2)
console.log('ddd2', res2)
this.orderInfo = res2
this.$refs.popup.open('center')
},
change(e) {
change(e) {
console.log('当前模式:' + e.type + ',状态:' + e.show);
console.log('当前模式:' + e.type + ',状态:' + e.show);
},
},
...
@@ -71,11 +190,11 @@
...
@@ -71,11 +190,11 @@
},
},
// 选择文件
// 选择文件
select(e) {
select(e) {
console.log('选择文件:', e)
console.log('选择文件:', e
, this.fileList
)
},
},
// 上传成功
// 上传成功
success(e) {
success(e) {
console.log('上传成功',e)
console.log('上传成功',
e)
},
},
// 上传失败
// 上传失败
fail(e) {
fail(e) {
...
@@ -93,12 +212,14 @@
...
@@ -93,12 +212,14 @@
this.$refs.popup.close()
this.$refs.popup.close()
},
},
submit() {
submit() {
this.$refs.popup.open('center')
this.updateQuotaOrder()
this.$refs.files.upload()
// this.$refs.files.upload()
},
},
preStep() {
preStep() {
this.$emit('click', 'quotaOrder')
this.$emit('click', 'quotaOrder')
},
},
...mapMutations(["$uStore"]),
}
}
}
}
</script>
</script>
...
@@ -180,13 +301,13 @@
...
@@ -180,13 +301,13 @@
border-radius: 4px;
border-radius: 4px;
margin-top: 90rpx;
margin-top: 90rpx;
}
}
.uni-file-picker{
.uni-file-picker
{
width: 100%;
width: 100%;
height: 100%;
height: 100%;
}
}
/deep/ .uni-file-picker__container{
/deep/ .uni-file-picker__container
{
width: 100%;
width: 100%;
height: 100%;
height: 100%;
}
}
...
@@ -243,7 +364,7 @@
...
@@ -243,7 +364,7 @@
width: 580rpx;
width: 580rpx;
height: 408rpx;
height: 408rpx;
background: #ffffff;
background: #ffffff;
border-radius: 2
0
rpx;
border-radius: 2
4
rpx;
}
}
.popup-content-head {
.popup-content-head {
...
@@ -280,13 +401,13 @@
...
@@ -280,13 +401,13 @@
.popup-content-foot__btn {
.popup-content-foot__btn {
width: 152rpx;
width: 152rpx;
height: 60rpx;
height: 60rpx;
font-size: 22rpx;
line-height: 60rpx;
line-height: 60rpx;
background: #ffedee;
background: #ffedee;
text-align: center;
text-align: center;
color: #ff0f00;
color: #ff0f00;
font-weight: 500;
font-weight: 500;
border-radius: 32rpx;
border-radius: 32rpx;
font-size: 22rpx;
}
}
.popup-content-foot__sure {
.popup-content-foot__sure {
...
@@ -295,4 +416,4 @@
...
@@ -295,4 +416,4 @@
background: #ff1d32;
background: #ff1d32;
border: 1px solid #ff1d32;
border: 1px solid #ff1d32;
}
}
</style>
</style>
pages/no-quota/quota-order.nvue
View file @
f9e98733
This diff is collapsed.
Click to expand it.
pages/quota/quota-order.nvue
View file @
f9e98733
...
@@ -504,7 +504,7 @@
...
@@ -504,7 +504,7 @@
selectPlanOrder(product, index, mode = 'inner') {
selectPlanOrder(product, index, mode = 'inner') {
if (this.planinnerLists && this.planinnerLists.length > 0) {
if (this.planinnerLists && this.planinnerLists.length > 0) {
uni.navigateTo({
uni.navigateTo({
url: `/pages/select-sale-plan/select-sale-plan?from=
'quotaOrder'
&product=${JSON.stringify((product))}&index=${index}`
url: `/pages/select-sale-plan/select-sale-plan?from=
quotaOrder
&product=${JSON.stringify((product))}&index=${index}`
});
});
} else {
} else {
uni.showToast({
uni.showToast({
...
...
pages/select-product/select-product.vue
View file @
f9e98733
...
@@ -70,6 +70,11 @@
...
@@ -70,6 +70,11 @@
apiProductSelect
apiProductSelect
}
from
'@/servers/common.js'
}
from
'@/servers/common.js'
const
modeMap
=
{
'quotaOrder'
:
'QUOTA'
,
'noQuotaOrder'
:
'NO_QUOTA'
,
}
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
...
@@ -104,7 +109,7 @@
...
@@ -104,7 +109,7 @@
return
{
return
{
'height'
:
`
${
this
.
sysinfo
.
safeArea
.
top
+
44
}
px`
'height'
:
`
${
this
.
sysinfo
.
safeArea
.
top
+
44
}
px`
}
}
}
,
}
},
},
onNavigationBarButtonTap
(
e
)
{
onNavigationBarButtonTap
(
e
)
{
// console.log('onNavigationBarButtonTap:', e, this.isOpened, this.selectedProduct);
// console.log('onNavigationBarButtonTap:', e, this.isOpened, this.selectedProduct);
...
@@ -158,7 +163,7 @@
...
@@ -158,7 +163,7 @@
const
params
=
{
const
params
=
{
'page'
:
1
,
'page'
:
1
,
'pagesize'
:
'10'
,
'pagesize'
:
'10'
,
"MODE"
:
"QUOTA"
,
"MODE"
:
modeMap
[
this
.
toPageParams
.
page
]
,
"INFO"
:
{
"INFO"
:
{
"PROCESS_TYPE"
:
"ZS01"
,
"PROCESS_TYPE"
:
"ZS01"
,
"CUSTOMER"
:
"0050000215"
"CUSTOMER"
:
"0050000215"
...
...
servers/noQuotaOrder.js
0 → 100644
View file @
f9e98733
import
apiHelper
from
'./api.helper.js'
/**
* 销售订单行项目选择或修改后进行页面数据更新
* @param
* @returns {Promise<AxiosResponse<T>>}
*/
export
async
function
apiUpdateNoQuotaData
(
params
)
{
const
res
=
await
apiHelper
.
post
(
'/sap/bc/ztpm/to_new_crm/transdata/so_u_data_other'
,
params
)
return
res
}
/**
* 针对配额产品经销商保存、提交、取消、审核配额订单
* @param
* @returns {Promise<AxiosResponse<T>>}
*/
export
async
function
apiUpdateNoQuotaOrder
(
params
)
{
const
res
=
await
apiHelper
.
post
(
'/sap/bc/ztpm/to_new_crm/transdata/so_no_quota'
,
params
)
return
res
}
export
default
{
apiUpdateNoQuotaData
,
apiUpdateNoQuotaOrder
}
store/index.js
View file @
f9e98733
...
@@ -47,6 +47,12 @@ const store = new Vuex.Store({
...
@@ -47,6 +47,12 @@ const store = new Vuex.Store({
'item_outer'
:
[],
'item_outer'
:
[],
'item_d'
:
[],
'item_d'
:
[],
'attachment'
:
[]
'attachment'
:
[]
},
noQuotaOrder
:
{
'ITEM_INNER'
:
[],
'item_outer'
:
[],
'item_d'
:
[],
'attachment'
:
[]
}
}
},
},
mutations
:
{
mutations
:
{
...
...
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