Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
N
newShopFront
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
newshop
newShopFront
Commits
b7158808
Commit
b7158808
authored
Dec 18, 2019
by
邓学云
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
服务类目
parent
c809425b
Changes
7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
117 additions
and
70 deletions
+117
-70
delivery.js
src/api/delivery.js
+16
-1
deliveryDetails.vue
src/views/delivery/details/deliveryDetails.vue
+77
-9
distributionPrice.vue
src/views/delivery/distributionPrice.vue
+12
-1
Scategorymg.vue
src/views/storedc/Scategorymg.vue
+2
-54
branchService_editor.vue
src/views/storedc/details/branchService_editor.vue
+3
-2
storeEvaluateManage.vue
src/views/storedc/storeEvaluateManage.vue
+6
-1
userGroup.vue
src/views/userstaff/userGroup.vue
+1
-2
No files found.
src/api/delivery.js
View file @
b7158808
...
...
@@ -39,7 +39,7 @@ export function getProvincialList(parameter) {
params
:
parameter
})
}
// 新增
运费模板
// 新增
配送价格
export
function
addDelivery
(
parameter
)
{
return
axios
({
url
:
'transport/transport-settings/transport-fee-add'
,
...
...
@@ -63,6 +63,21 @@ export function getAllCity (parameter) {
params
:
parameter
})
}
// 更新配送价格
export
function
modifyDelivery
(
parameter
)
{
return
axios
({
url
:
'transport/transport-settings/transport-fee-update'
,
method
:
'put'
,
data
:
parameter
})
}
// 删除配送价格
export
function
deleteDelivery
(
parameter
)
{
return
axios
({
url
:
'transport/transport-settings/transport-fee-del?GUID='
+
parameter
,
method
:
'delete'
})
}
/**
...
...
src/views/delivery/details/deliveryDetails.vue
View file @
b7158808
...
...
@@ -188,9 +188,9 @@
<!-- fixed footer toolbar -->
<footer-tool-bar
:style=
"{ width: isSideMenu() && isDesktop() ? `calc(100% - ${sidebarOpened ? 256 : 80}px)` : '100%'}"
>
<!-- 新建 -->
<a-button
@
click
.
stop
.
prevent=
"handleSubmit"
htmlType=
"submit"
type=
"primary"
>
提交
</a-button>
<a-button
v-if=
"editDetails"
@
click
.
stop
.
prevent=
"handleSubmit"
htmlType=
"submit"
type=
"primary"
>
提交
</a-button>
<!-- 编辑 -->
<
!-- <a-button @click.stop.prevent="handleSubmit1" htmlType="submit" type="primary">提交</a-button> --
>
<
a-button
v-else
@
click
.
stop
.
prevent=
"handleSubmit1"
htmlType=
"submit"
type=
"primary"
>
提交
</a-button
>
<a-button
@
click=
"goBack"
style=
"margin-left: 8px"
>
返回
</a-button>
</footer-tool-bar>
<a-modal
title=
"选择门店"
:width=
"800"
:destroyOnClose=
"destroyOnClose"
v-model=
"visible"
@
ok=
"handleOk()"
>
...
...
@@ -231,7 +231,7 @@ import moment from 'moment'
import
FooterToolBar
from
'@/components/FooterToolbar'
import
{
mixin
,
mixinDevice
}
from
'@/utils/mixin'
import
{
STable
}
from
'@/components'
import
{
getTransportList
,
getProvincialList
,
addDelivery
,
getEditDetails
,
getAllCity
}
from
'@/api/delivery'
import
{
getTransportList
,
getProvincialList
,
addDelivery
,
getEditDetails
,
getAllCity
,
modifyDelivery
}
from
'@/api/delivery'
import
{
getUListUserGroup
}
from
'@/api/userstaff'
import
{
loadAddress
}
from
'@/api/store'
...
...
@@ -252,6 +252,7 @@ export default {
xs
:
{
span
:
24
},
sm
:
{
span
:
12
}
},
editDetails
:
true
,
//新建或者编辑,默认新建
formCheck
:
this
.
$form
.
createForm
(
this
),
visible
:
false
,
destroyOnClose
:
true
,
...
...
@@ -327,12 +328,16 @@ export default {
this
.
getAllC
()
var
goId
=
this
.
$route
.
query
.
goid
;
if
(
goId
==
0
){
this
.
editDetails
=
false
;
this
.
getDetails
(
this
.
$route
.
query
.
GUID
)
}
else
{
this
.
editDetails
=
true
;
}
},
methods
:{
// 提交(新建)
handleSubmit
(){
var
that
=
this
;
const
{
modalForm
:
{
validateFields
}
}
=
this
;
validateFields
({
force
:
true
},
(
err
,
values
)
=>
{
if
(
!
err
)
{
...
...
@@ -348,11 +353,20 @@ export default {
deliveryData
.
LIMIT_MEMBER_GROUP_GUID
=
deliveryData
.
LIMIT_MEMBER_GROUP_GUID
.
join
(
','
)
}
if
(
this
.
modalTree
.
checkedKeys
){
this
.
modalTree
.
checkedKeys
.
map
(
function
(
item
,
index
){
deliveryData
.
SELECT_AREA
=
[];
this
.
modalTree
.
checkedKeys
.
forEach
((
item
,
index
)
=>
{
if
(
item
==
'P0'
){
this
.
modalTree
.
checkedKeys
.
splice
(
index
,
1
)
}
if
(
item
.
split
(
''
).
includes
(
'P'
)){
th
at
.
modalTree
.
checkedKeys
.
splice
(
index
,
1
)
th
is
.
modalTree
.
checkedKeys
.
splice
(
index
,
1
)
}
})
// this.modalTree.checkedKeys.map(function(item,index){
// if(item.split('').includes('P')){
// that.modalTree.checkedKeys.splice(index,1)
// }
// })
deliveryData
.
SELECT_AREA
=
this
.
modalTree
.
checkedKeys
.
join
(
','
)
}
if
(
this
.
tableData
.
length
>
0
){
...
...
@@ -365,11 +379,65 @@ export default {
deliveryData
.
BRANCHES_INFO
=
''
}
console
.
log
(
deliveryData
)
//
addDelivery(deliveryData).then(res => {
//
this.goBack();
//
}).catch(err => {
addDelivery
(
deliveryData
).
then
(
res
=>
{
this
.
goBack
();
}).
catch
(
err
=>
{
})
}
})
},
// 提交(编辑)
handleSubmit1
(){
var
that
=
this
;
const
{
modalForm
:
{
validateFields
}
}
=
this
;
const
guidData
=
{
GUID
:
this
.
$route
.
query
.
GUID
}
validateFields
({
force
:
true
},
(
err
,
values
)
=>
{
if
(
!
err
)
{
const
deliveryData
=
Object
.
assign
({
...
values
},
guidData
);
for
(
let
item
in
deliveryData
){
if
(
deliveryData
[
item
]
===
true
){
deliveryData
[
item
]
=
'1'
}
else
if
(
deliveryData
[
item
]
===
false
){
deliveryData
[
item
]
=
'0'
}
}
if
(
deliveryData
.
LIMIT_MEMBER_GROUP_GUID
){
deliveryData
.
LIMIT_MEMBER_GROUP_GUID
=
deliveryData
.
LIMIT_MEMBER_GROUP_GUID
.
join
(
','
)
}
if
(
this
.
modalTree
.
checkedKeys
){
deliveryData
.
SELECT_AREA
=
[];
this
.
modalTree
.
checkedKeys
.
forEach
((
item
,
index
)
=>
{
if
(
item
==
'P0'
){
this
.
modalTree
.
checkedKeys
.
splice
(
index
,
1
)
}
if
(
item
.
split
(
''
).
includes
(
'P'
)){
this
.
modalTree
.
checkedKeys
.
splice
(
index
,
1
)
}
})
// this.modalTree.checkedKeys.map(function(item,index){
// if(item.split('').includes('P')){
// that.modalTree.checkedKeys.splice(index,1)
// }
// })
deliveryData
.
SELECT_AREA
=
this
.
modalTree
.
checkedKeys
.
join
(
','
)
}
if
(
this
.
tableData
.
length
>
0
){
const
BRANCHES_INFO
=
[]
this
.
tableData
.
forEach
(
item
=>
{
BRANCHES_INFO
.
push
(
item
.
GUID
)
})
deliveryData
.
BRANCHES_INFO
=
BRANCHES_INFO
.
join
(
','
)
}
else
{
deliveryData
.
BRANCHES_INFO
=
''
}
console
.
log
(
deliveryData
)
modifyDelivery
(
deliveryData
).
then
(
res
=>
{
this
.
goBack
();
}).
catch
(
err
=>
{
})
}
})
},
...
...
src/views/delivery/distributionPrice.vue
View file @
b7158808
...
...
@@ -45,7 +45,7 @@
<
script
>
import
moment
from
'moment'
import
{
STable
}
from
'@/components'
import
{
getDeliveryList
,
getTransportList
}
from
'@/api/delivery'
import
{
getDeliveryList
,
getTransportList
,
deleteDelivery
}
from
'@/api/delivery'
export
default
{
name
:
"delivery"
,
...
...
@@ -111,6 +111,9 @@ export default {
}
}
},
mounted
(){
this
.
$refs
.
table
.
refresh
();
},
methods
:{
goEdit
(
value
){
if
(
value
==
1
){
...
...
@@ -119,6 +122,14 @@ export default {
this
.
$router
.
push
({
path
:
'/delivery/deliveryDetails'
,
query
:{
goid
:
0
,
GUID
:
value
.
GUID
}})
}
},
remove
(
value
){
deleteDelivery
(
value
).
then
(
res
=>
{
this
.
$refs
.
table
.
refresh
();
this
.
$message
.
success
(
res
.
message
)
}).
catch
(
err
=>
{
})
}
}
}
</
script
>
\ No newline at end of file
src/views/storedc/Scategorymg.vue
View file @
b7158808
...
...
@@ -155,62 +155,10 @@ export default {
}
},
handleEdit
(
value
)
{
this
.
visible
=
true
var
that
=
this
if
(
value
==
1
){
// 新建
this
.
modalNow
=
1
;
this
.
$router
.
push
({
path
:
'/storedc/details/branchservice_editor'
,
query
:{
goid
:
1
}})
}
else
{
// 编辑
this
.
modalNow
=
0
;
getScategorymgDetails
(
value
.
CODE
)
.
then
(
res
=>
{
// this.radioVal = res.data[0]
console
.
log
(
res
.
data
[
0
])
// this.modalForm.initialValue(res)
this
.
$nextTick
(()
=>
{
this
.
GUID
=
res
.
data
[
0
].
GUID
this
.
modalForm
.
setFieldsValue
(
res
.
data
[
0
])
})
})
.
catch
(
err
=>
{})
}
},
handleadd
()
{
this
.
$router
.
push
({
path
:
'/storedc/branchservice_add'
})
},
handleOk
()
{
if
(
this
.
modalNow
==
1
){
const
{
modalForm
:
{
validateFields
}
}
=
this
validateFields
({
force
:
true
},
(
err
,
values
)
=>
{
if
(
!
err
)
{
this
.
visible
=
false
const
ScategorymgParams
=
{
...
values
}
ScategorymgParams
.
CREATE_TIME
=
ScategorymgParams
.
CREATE_TIME
.
format
(
'YYYY-MM-DD HH:mm:ss'
)
addScategorymg
(
ScategorymgParams
)
this
.
$refs
.
table
.
refresh
(
true
)
}
})
}
else
{
let
GUID
=
this
.
GUID
const
{
modalForm
:
{
validateFields
}
}
=
this
validateFields
({
force
:
true
},
(
err
,
values
)
=>
{
if
(
!
err
)
{
const
ScategorymgDetails
=
Object
.
assign
({
...
values
},
{
GUID
:
GUID
})
ScategorymgDetails
.
CREATE_TIME
=
ScategorymgDetails
.
CREATE_TIME
.
format
(
'YYYY-MM-DD HH:mm:ss'
)
modifyScategorymgDetails
(
ScategorymgDetails
)
.
then
(
res
=>
{
this
.
visible
=
false
// this.whichOptions=1;
this
.
$refs
.
table
.
refresh
(
true
)
})
.
catch
(
err
=>
{})
}
})
this
.
$router
.
push
({
path
:
'/storedc/details/branchservice_editor'
,
query
:{
goid
:
0
,
GUID
:
value
.
CODE
}})
}
},
remove
(
key
)
{
...
...
src/views/storedc/details/branchService_editor.vue
View file @
b7158808
...
...
@@ -66,7 +66,7 @@
</a-form-item>
<a-form-item
:wrapperCol=
"
{ span: 24 }" style="text-align: center">
<a-button
v-if=
"goId == 1"
@
click
.
stop
.
prevent=
"handleSubmit"
htmlType=
"submit"
type=
"primary"
>
提交
</a-button>
<a-button
v-if=
"goId == 1"
@
click
.
stop
.
prevent=
"handleSubmit"
htmlType=
"submit"
type=
"primary"
>
提交
1
</a-button>
<a-button
v-else
@
click
.
stop
.
prevent=
"handleSubmit1()"
htmlType=
"submit"
type=
"primary"
>
提交
</a-button>
<a-button
@
click=
"goBack"
style=
"margin-left: 8px"
>
返回
</a-button>
</a-form-item>
...
...
@@ -114,7 +114,7 @@ export default {
methods
:
{
// 时间处理
DateCheck
(
value
){
if
(
value
||
value
!=
null
||
value
!=
"
"
){
if
(
value
&&
value
!=
null
&&
value
!=
""
&&
value
!=
"undefined
"
){
return
moment
(
value
,
'YYYY-MM-DD HH:mm:ss'
)
}
},
...
...
@@ -128,6 +128,7 @@ export default {
validateFields
({
force
:
true
},
(
err
,
values
)
=>
{
if
(
!
err
)
{
const
ScategorymgParams
=
{
...
values
}
ScategorymgParams
.
CREATE_TIME
=
ScategorymgParams
.
CREATE_TIME
.
format
(
"YYYY-MM-DD HH:mm:ss"
);
addScategorymg
(
ScategorymgParams
)
this
.
$router
.
push
({
path
:
'/storedc/scategorymg'
})
}
...
...
src/views/storedc/storeEvaluateManage.vue
View file @
b7158808
...
...
@@ -156,6 +156,7 @@
<a-form-item
:labelCol=
'labelCol'
:wrapperCol=
'wrapperCol'
hidden
>
<a-input
hidden
...
...
@@ -434,6 +435,7 @@ export default {
console
.
log
(
key
)
deleteEvaluate
(
key
).
then
(
res
=>
{
this
.
$refs
.
table
.
refresh
();
this
.
$message
.
success
(
res
.
message
)
}).
catch
(
err
=>
{
})
...
...
@@ -467,7 +469,10 @@ export default {
// this.whichOptions=1;
this
.
$refs
.
table
.
refresh
(
true
)
}).
catch
(
err
=>
{
this
.
$notification
[
'error'
]({
message
:
err
.
response
.
data
.
message
,
description
:
err
.
response
.
data
.
message
})
})
}
})
...
...
src/views/userstaff/userGroup.vue
View file @
b7158808
...
...
@@ -107,10 +107,9 @@ export default {
}
},
remove
(
key
)
{
console
.
log
(
key
)
deleteUserGroup
(
key
).
then
(
res
=>
{
console
.
log
(
'已删除'
)
this
.
$refs
.
table
.
refresh
();
this
.
$message
.
success
(
'删除成功!'
)
}).
catch
(
err
=>
{
})
...
...
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