Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
op-web-service
Project
Project
Details
Activity
Releases
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
bp
op-web-service
Commits
bc8ee4ae
Commit
bc8ee4ae
authored
Aug 10, 2021
by
lihui
Browse files
Options
Browse Files
Download
Plain Diff
fix: bug--all
parents
d30b982e
16532533
Changes
8
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
60 additions
and
65 deletions
+60
-65
groupmeal.js
server/controllers/groupmeal.js
+3
-3
router.js
server/router.js
+3
-3
index.vue
src/pages/Activity/Manage/index.vue
+6
-6
addProduc.vue
src/pages/Activity/releaseProduc/components/addProduc.vue
+34
-34
infoEditing.vue
src/pages/Activity/releaseProduc/components/infoEditing.vue
+6
-5
spellOrderSet.vue
...pages/Activity/releaseProduc/components/spellOrderSet.vue
+1
-8
index.vue
src/pages/Groupmeal/newOrderManagement/index.vue
+4
-3
groupmeal.js
src/service/Groupmeal/groupmeal.js
+3
-3
No files found.
server/controllers/groupmeal.js
View file @
bc8ee4ae
...
...
@@ -150,7 +150,7 @@ exports.newGetOrderList = async ctx => {
// 获取活动名称
exports
.
newGetMarketingList
=
async
ctx
=>
{
const
url
=
`
${
GROUPMEAL_URI
}
/order/background/marketing_list`
;
const
url
=
`
${
GROUPMEAL_URI
}
/order/background/
order_condition_
marketing_list`
;
const
opts
=
{
url
,
method
:
"GET"
...
...
@@ -160,7 +160,7 @@ exports.newGetMarketingList = async ctx => {
// 获取商品名称
exports
.
newGetGoodsList
=
async
ctx
=>
{
const
url
=
`
${
GROUPMEAL_URI
}
/order/background/goods_list`
;
const
url
=
`
${
GROUPMEAL_URI
}
/order/background/
order_condition_
goods_list`
;
const
opts
=
{
url
,
method
:
"GET"
...
...
@@ -170,7 +170,7 @@ exports.newGetGoodsList = async ctx => {
// 获取自提点
exports
.
newGetSubShopList
=
async
ctx
=>
{
const
url
=
`
${
GROUPMEAL_URI
}
/order/background/
sub_shop
_list`
;
const
url
=
`
${
GROUPMEAL_URI
}
/order/background/
order_condition_take_place
_list`
;
const
opts
=
{
url
,
method
:
"GET"
...
...
server/router.js
View file @
bc8ee4ae
...
...
@@ -103,9 +103,9 @@ router.post(`${API_VERSION}/order/oldbackground/order_refund`, groupmeal.orderRe
// 新订单管理
router
.
get
(
`
${
API_VERSION
}
/order/background/op_order_list`
,
groupmeal
.
newGetOrderList
);
router
.
get
(
`
${
API_VERSION
}
/order/background/marketing_list`
,
groupmeal
.
newGetMarketingList
);
router
.
get
(
`
${
API_VERSION
}
/order/background/goods_list`
,
groupmeal
.
newGetGoodsList
);
router
.
get
(
`
${
API_VERSION
}
/order/background/
sub_shop
_list`
,
groupmeal
.
newGetSubShopList
);
router
.
get
(
`
${
API_VERSION
}
/order/background/
order_condition_
marketing_list`
,
groupmeal
.
newGetMarketingList
);
router
.
get
(
`
${
API_VERSION
}
/order/background/
order_condition_
goods_list`
,
groupmeal
.
newGetGoodsList
);
router
.
get
(
`
${
API_VERSION
}
/order/background/
order_condition_take_place
_list`
,
groupmeal
.
newGetSubShopList
);
router
.
get
(
`
${
API_VERSION
}
/order/background/order_export`
,
groupmeal
.
newOrderExport
);
router
.
get
(
`
${
API_VERSION
}
/order/background/order_print`
,
groupmeal
.
newOrderPrint
);
router
.
get
(
`
${
API_VERSION
}
/order/background/order_item_list`
,
groupmeal
.
newOrderItemList
);
...
...
src/pages/Activity/Manage/index.vue
View file @
bc8ee4ae
<
template
>
<
L
ayout>
<
l
ayout>
<div
class=
"manage-wrapper"
v-loading=
"tableLoading"
...
...
@@ -155,15 +155,18 @@
<
/div
>
<
/el-form
>
<
/div
>
<
/
L
ayout
>
<
/
l
ayout
>
<
/template
>
<
script
>
import
{
Layout
}
from
"../../Groupmeal/layout/index.vue"
;
import
layout
from
"../../Groupmeal/layout/index.vue"
;
import
{
ElMessage
}
from
"element-plus"
;
import
ActivityService
from
"@/service/Activity/index"
;
import
dayJs
from
"dayjs"
;
export
default
{
name
:
"Manage"
,
components
:
{
layout
}
,
data
()
{
return
{
activity
:
{
...
...
@@ -184,9 +187,6 @@ export default {
]
}
;
}
,
components
:
{
Layout
}
,
methods
:
{
/* API */
// 获取商品列表
...
...
src/pages/Activity/releaseProduc/components/addProduc.vue
View file @
bc8ee4ae
...
...
@@ -65,12 +65,12 @@
>
<el-form-item
label=
"图片:"
>
<el-upload
:class=
"{
hide:hideUpload
}"
:class=
"{
hide: hideUpload
}"
:data=
"{ type: 1 }"
:action=
"uploadUrl"
:on-preview=
"previewImage"
:on-success=
"handleDetailSuccess"
:on-change
=
"handleDetailChange"
:on-change
=
"handleDetailChange"
:before-remove=
"removeDetailFiles"
:file-list=
"picUrlList"
auto-upload
...
...
@@ -241,19 +241,19 @@ import {
getBusinessList
,
pindanGoods
,
markGoodsInfo
,
editGoods
,
editGoods
}
from
"../../../../service/Activity/index"
;
export
default
{
props
:
{
editInfo
:
{
type
:
Object
,
required
:
()
=>
{}
,
required
:
()
=>
{}
},
addProduc
:
{
type
:
Array
,
required
:
()
=>
{}
,
}
,
required
:
()
=>
{}
}
},
data
()
{
return
{
...
...
@@ -274,7 +274,7 @@ export default {
original_price
:
""
,
inventory_total
:
null
,
total_amount_order
:
null
,
business1
:
""
,
business1
:
""
},
picUrlList
:
[],
...
...
@@ -282,14 +282,14 @@ export default {
isShowPopver
:
false
,
// 是否展示图片框
uploadUrl
:
`
${
GOODS_URI
}
/ksy/ks3apiunencrypt/ks3api_upload`
,
// 金山云上传地址
hideUpload
:
false
,
limitCount
:
"1"
,
limitCount
:
1
,
// 商品库添加
selCommodityPopup
:
false
,
// 商品库添加弹窗状态
business2
:
""
,
// 商家
multipleSelection
:
[],
// 勾选的数据
goodsSkuID
:
""
,
goodsSkuID
:
""
};
},
computed
:
{
...
...
@@ -303,7 +303,7 @@ export default {
this
.
commodityForm
.
total_amount_order
);
}
}
,
}
},
methods
:
{
// 上移
...
...
@@ -334,7 +334,7 @@ export default {
this
.
isShowPopver
=
true
;
},
handleDetailChange
(){
handleDetailChange
()
{
this
.
hideUpload
=
this
.
picUploadList
.
length
>=
this
.
limitCount
;
},
...
...
@@ -360,7 +360,7 @@ export default {
const
res
=
await
getBusinessList
(
params
);
this
.
businessOpt
=
[
{
ota_id
:
""
,
ota_name
:
"全部"
},
...
res
.
result
.
list
,
...
res
.
result
.
list
];
}
catch
(
error
)
{
this
.
$message
.
error
(
"发生未知错误,请稍后再试一下吧~~~"
);
...
...
@@ -377,7 +377,7 @@ export default {
this
.
commodityForm
.
business1
=
res
.
result
.
goods_info
.
ota_id
;
for
(
var
i
in
res
.
result
.
goods_info
.
desc_pic_url_list
)
{
this
.
picUrlList
.
push
({
url
:
res
.
result
.
goods_info
.
desc_pic_url_list
[
i
]
,
url
:
res
.
result
.
goods_info
.
desc_pic_url_list
[
i
]
});
}
},
...
...
@@ -395,26 +395,26 @@ export default {
marketing_type
:
"4"
,
ota_id
:
this
.
commodityForm
.
business1
,
op_cur_user
:
store
.
state
.
userInfo
.
email
,
goods_sku_id
:
goodsSkuID
,
goods_sku_id
:
goodsSkuID
});
if
(
res
.
code
==
0
)
{
ElMessage
.
success
({
message
:
"修改成功"
,
type
:
"success"
,
type
:
"success"
});
this
.
pindanGoodsMet
();
setTimeout
(()
=>
{
for
(
var
i
in
this
.
comTableData
)
{
if
(
this
.
comTableData
[
i
].
goods_sku_id
==
goodsSkuID
)
{
this
.
comTableData
.
splice
(
i
,
1
);
this
.
comTableData
.
splice
(
i
,
1
,
this
.
comLibTableData
[
i
]
);
}
}
for
(
var
j
in
this
.
comLibTableData
)
{
if
(
this
.
comLibTableData
[
j
].
goods_sku_id
==
goodsSkuID
)
{
this
.
comTableData
.
push
(
this
.
comLibTableData
[
j
]);
}
}
//
for (var j in this.comLibTableData) {
//
if (this.comLibTableData[j].goods_sku_id == goodsSkuID) {
//
this.comTableData.push(this.comLibTableData[j]);
//
}
//
}
},
500
);
this
.
addCommodityPopup
=
false
;
}
else
{
...
...
@@ -455,12 +455,12 @@ export default {
marketing_type
:
"4"
,
price
:
this
.
commodityForm
.
price
,
ota_id
:
this
.
commodityForm
.
business1
,
op_cur_user
:
store
.
state
.
userInfo
.
email
,
op_cur_user
:
store
.
state
.
userInfo
.
email
});
if
(
res
.
code
==
0
)
{
ElMessage
.
success
({
message
:
"添加商品成功"
,
type
:
"success"
,
type
:
"success"
});
this
.
comTableData
.
push
(
res
.
result
.
goods_info
);
this
.
addCommodityPopup
=
false
;
...
...
@@ -477,7 +477,7 @@ export default {
// 添加商品保存
commoditySave
(
infoForm
)
{
this
.
$refs
[
infoForm
].
validate
(
(
valid
)
=>
{
this
.
$refs
[
infoForm
].
validate
(
valid
=>
{
if
(
valid
)
{
if
(
this
.
addCommodityTitle
==
"商品添加"
)
{
this
.
addGoodsMet
();
...
...
@@ -516,9 +516,9 @@ export default {
if
(
this
.
comTableData
.
length
==
0
)
{
this
.
comTableData
.
push
(...
this
.
multipleSelection
);
}
else
{
this
.
multipleSelection
.
forEach
(
(
item
)
=>
{
this
.
multipleSelection
.
forEach
(
item
=>
{
let
num
=
0
;
this
.
comTableData
.
some
(
(
val
)
=>
{
this
.
comTableData
.
some
(
val
=>
{
num
++
;
if
(
val
.
goods_sku_id
===
item
.
goods_sku_id
)
{
val
.
goods_sku_id
=
item
.
goods_sku_id
;
...
...
@@ -539,26 +539,26 @@ export default {
this
.
comTableData
.
splice
(
i
,
1
);
}
}
}
,
}
},
watch
:
{
addProduc
:
function
(
newVal
)
{
addProduc
:
function
(
newVal
)
{
let
marketingId
=
this
.
$route
.
query
.
marketing_id
;
if
(
marketingId
==
undefined
)
{
return
;
}
this
.
comTableData
=
newVal
;
}
,
}
},
created
()
{
this
.
getBusinessListMet
();
}
,
}
};
</
script
>
<
style
scoped
>
.addProduc
{
width
:
64
%
;
width
:
90
%
;
margin
:
0
auto
;
}
...
...
src/pages/Activity/releaseProduc/components/infoEditing.vue
View file @
bc8ee4ae
<
template
>
<div
class=
"infoEditing"
>
{{
picSubmitList
.
length
}}
<el-form
ref=
"infoEditForm"
:model=
"infoEditForm"
label-width=
"80px"
>
<el-form-item
label=
"标题:"
>
<el-input
v-model=
"infoEditForm.title"
maxlength=
"30"
></el-input>
...
...
@@ -88,10 +87,11 @@ export default {
url
:
this
.
propData
.
pindan_pic_url
[
i
]
});
}
this
.
hideUpload
=
this
.
picSubmitList
.
length
>=
this
.
limitCount
;
// 大于9 隐藏
}
},
deep
:
true
//
immediate: true
deep
:
true
,
immediate
:
true
}
},
methods
:
{
...
...
@@ -102,8 +102,7 @@ export default {
},
handleDetailChange
()
{
this
.
hideUpload
=
this
.
infoEditForm
.
picUploadList
.
length
>=
this
.
limitCount
;
this
.
hideUpload
=
this
.
picSubmitList
.
length
>=
this
.
limitCount
;
},
// 图片上传成功时
...
...
@@ -113,6 +112,7 @@ export default {
// 发布功能需要的图片列表
url
:
res
.
result
.
url
});
this
.
hideUpload
=
this
.
picSubmitList
.
length
>=
this
.
limitCount
;
},
// 图片删除后
...
...
@@ -122,6 +122,7 @@ export default {
this
.
picSubmitList
.
splice
(
i
,
1
);
}
}
this
.
hideUpload
=
this
.
picSubmitList
.
length
>=
this
.
limitCount
;
},
// 获取营销活动详情
...
...
src/pages/Activity/releaseProduc/components/spellOrderSet.vue
View file @
bc8ee4ae
...
...
@@ -8,7 +8,6 @@
v-model=
"startDate"
type=
"datetime"
:disabledDate=
"pickerOptions.disabledDateStart"
:default-value=
"new Date()"
placeholder=
"拼单开始时间"
@
change=
"changeStartTime"
>
...
...
@@ -17,7 +16,6 @@
class=
"endTimePicker"
v-model=
"endDate"
type=
"datetime"
:default-value=
"new Date()"
placeholder=
"拼单结束时间"
:disabledDate=
"pickerOptions.disabledDateEnd"
@
change=
"changeEndTime"
...
...
@@ -248,12 +246,7 @@ export default {
return
time
.
getTime
()
<
_now
||
time
.
getTime
()
>
threeDays
;
//大于当前的禁止,小于3天前的禁止
}
,
disabledDateEnd
(
time
)
{
let
_now
=
null
;
if
(
this
.
startDate
)
{
_now
=
this
.
startDate
;
}
else
{
_now
=
Date
.
now
();
}
let
_now
=
Date
.
now
();
let
ninety
=
90
*
24
*
60
*
60
*
1000
;
let
ninetyDays
=
_now
+
ninety
;
return
time
.
getTime
()
<
_now
||
time
.
getTime
()
>
ninetyDays
;
//大于当前的禁止,小于90天前的禁止
...
...
src/pages/Groupmeal/newOrderManagement/index.vue
View file @
bc8ee4ae
...
...
@@ -71,9 +71,9 @@
>
<el-option
v-for=
"item in selLiftPoinArr"
:key=
"item.
sub_shop
_id"
:label=
"item.
sub_shop
_name"
:value=
"item.
sub_shop
_id"
:key=
"item.
take_place
_id"
:label=
"item.
take_place
_name"
:value=
"item.
take_place
_id"
></el-option>
</el-select>
</el-form-item>
...
...
@@ -491,6 +491,7 @@ export default {
marketing_id
:
val
,
};
const
res
=
await
newGetGoodsList
(
params
);
// 商品名称
console
.
log
(
res
);
this
.
getSubShopListMet
(
val
);
//自提点
// const res = await getSubShopList(params);
this
.
tradeNameArr
=
res
.
result
;
...
...
src/service/Groupmeal/groupmeal.js
View file @
bc8ee4ae
...
...
@@ -127,13 +127,13 @@ export async function newGetOrderList(params) {
// 获取活动名称
export
async
function
newGetMarketingList
()
{
const
res
=
await
axios
.
get
(
"/api/v1/order/background/marketing_list"
);
const
res
=
await
axios
.
get
(
"/api/v1/order/background/
order_condition_
marketing_list"
);
return
res
;
}
// 获取商品名称
export
async
function
newGetGoodsList
(
params
)
{
const
res
=
await
axios
.
get
(
"/api/v1/order/background/goods_list"
,
{
const
res
=
await
axios
.
get
(
"/api/v1/order/background/
order_condition_
goods_list"
,
{
params
});
return
res
;
...
...
@@ -141,7 +141,7 @@ export async function newGetGoodsList(params) {
// 获取自提点
export
async
function
newGetSubShopList
(
params
)
{
const
res
=
await
axios
.
get
(
"/api/v1/order/background/
sub_shop
_list"
,{
const
res
=
await
axios
.
get
(
"/api/v1/order/background/
order_condition_take_place
_list"
,{
params
});
return
res
;
...
...
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