记得上下班打卡 | git大法好,push需谨慎
Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
liquidnet-bus-v1
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
董敬伟
liquidnet-bus-v1
Commits
ff00e9fb
Commit
ff00e9fb
authored
Jan 13, 2022
by
dongchun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
提交正在下单部分逻辑
parent
9d77c67a
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
409 additions
and
271 deletions
+409
-271
info.html
.../main/resources/templates/zhengzai/goblin/store/info.html
+10
-10
carefullyGoods.html
...rces/templates/zhengzai/store/homeSet/carefullyGoods.html
+4
-1
index.html
...ain/resources/templates/zhengzai/store/homeSet/index.html
+10
-0
activityList.html
...s/templates/zhengzai/store/placingOrder/activityList.html
+63
-116
activityStoreList.html
...plates/zhengzai/store/placingOrder/activityStoreList.html
+76
-72
addNewActivity.html
...templates/zhengzai/store/placingOrder/addNewActivity.html
+126
-21
storeDetail.html
...es/templates/zhengzai/store/placingOrder/storeDetail.html
+120
-51
No files found.
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/resources/templates/zhengzai/goblin/store/info.html
View file @
ff00e9fb
...
...
@@ -143,15 +143,15 @@
<div
class=
"photo_content"
>
<div>
<p>
证件正面照(国徽面)
</p>
<img
id=
"personCertFpic"
src=
"https://img.zhengzai.tv/other/2021/12/09/dd3259aaa66e4c3995ce2ab0ce38856c.png"
alt=
""
>
<img
id=
"personCertFpic"
s
tyle=
"height: 300px;"
s
rc=
"https://img.zhengzai.tv/other/2021/12/09/dd3259aaa66e4c3995ce2ab0ce38856c.png"
alt=
""
>
</div>
<div>
<p>
证件反面照(头像面)
</p>
<img
id=
"personCertBpic"
src=
"https://img.zhengzai.tv/other/2021/12/09/dd3259aaa66e4c3995ce2ab0ce38856c.png"
alt=
""
>
<img
id=
"personCertBpic"
s
tyle=
"height: 300px;"
s
rc=
"https://img.zhengzai.tv/other/2021/12/09/dd3259aaa66e4c3995ce2ab0ce38856c.png"
alt=
""
>
</div>
<div>
<p>
个人半身照(需手持身份证露上半身)
</p>
<img
id=
"personCertSpic"
src=
"https://img.zhengzai.tv/other/2021/12/09/dd3259aaa66e4c3995ce2ab0ce38856c.png"
alt=
""
>
<img
id=
"personCertSpic"
s
tyle=
"height: 300px;"
s
rc=
"https://img.zhengzai.tv/other/2021/12/09/dd3259aaa66e4c3995ce2ab0ce38856c.png"
alt=
""
>
</div>
</div>
</div>
...
...
@@ -191,14 +191,14 @@
<span><em
class=
"required"
>
*
</em>
详细地址:
</span>
<input
id=
"busAddress"
disabled
class=
"form-control"
type=
"text"
>
</div>
<div
class=
"content_store_logo"
>
<
!-- <
div class="content_store_logo">
<span><em class="required">*</em>上传合同:</span>
<img src="https://img.zhengzai.tv/other/2021/12/09/dd3259aaa66e4c3995ce2ab0ce38856c.png" alt="">
</div>
<div class="content_store_name">
<span><em class="required">*</em>合同有效期:</span>
<input disabled class="form-control" type="text">
</div>
</div>
-->
</div>
<div
class=
"content_footer"
>
<button
class=
"btn btn-primary"
onclick=
"auditAccept()"
>
审核通过
</button>
...
...
@@ -212,9 +212,7 @@
var
acceptFlg
=
[[
$
{@
permission
.
hasPermi
(
'goblin:store:audit:reject'
)}]];
var
rejectFlg
=
[[
$
{@
permission
.
hasPermi
(
'goblin:store:audit:reject'
)}]];
var
prefix
=
ctx
+
"goblin/store"
;
var
reg
=
new
RegExp
(
"(^|&)"
+
name
+
"=([^&]*)(&|$)"
);
var
r
=
window
.
location
.
search
.
substr
(
1
).
match
(
reg
);
let
storeId
=
unescape
(
r
[
2
]);
var
storeInfo
=
/*[[${storeInfo}]]*/
{};
console
.
log
(
storeInfo
);
var
storeCertification
=
/*[[${storeCertification}]]*/
{};
...
...
@@ -235,8 +233,10 @@
$
(
"#busName"
).
val
(
storeCertification
.
busName
);
$
(
"#provinceName"
).
val
(
storeCertification
.
provinceName
);
$
(
"#busAddress"
).
val
(
storeCertification
.
busAddress
);
var
reg
=
new
RegExp
(
"(^|&)"
+
id
+
"=([^&]*)(&|$)"
);
var
r
=
window
.
location
.
search
.
substr
(
1
).
match
(
reg
);
console
.
log
(
r
,
storeId
,
'取到没'
)
let
storeId
=
unescape
(
r
[
2
]);
...
...
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/resources/templates/zhengzai/store/homeSet/carefullyGoods.html
View file @
ff00e9fb
...
...
@@ -187,6 +187,9 @@
promiseMethods
(
'/selectGoods/getList'
,
'post'
).
then
(
res
=>
{
console
.
log
(
res
,
121212
)
let
{
data
}
=
res
;
if
(
data
.
length
<=
0
)
{
return
;
}
createTime
=
data
[
0
].
createTime
;
mid
=
data
[
0
].
mid
;
selectGoodsId
=
data
[
0
].
selectGoodsId
;
...
...
@@ -241,7 +244,7 @@
delTag
:
'0'
,
orderType
:
type
,
createTime
,
mid
,
mid
:
mid
||
0
,
selectGoodsId
,
updateTime
,
spuId
:
''
...
...
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/resources/templates/zhengzai/store/homeSet/index.html
View file @
ff00e9fb
...
...
@@ -77,6 +77,7 @@
<button
type=
"button"
class=
"btn btn-success"
onclick=
"goArea(4)"
>
魔方
</button>
<button
type=
"button"
class=
"btn"
onclick=
"goArea(7)"
>
精选商品
</button>
</div>
<button
type=
"button"
class=
"btn"
onclick=
"git()"
>
上线
</button>
</div>
<div
class=
"right_content"
>
<div
class=
"right_title"
>
...
...
@@ -122,6 +123,15 @@
function
delbannerSp
()
{
console
.
log
(
$
(
'.goods-banner-props'
),
'有吗'
)
}
function
git
()
{
$
.
ajax
({
type
:
'post'
,
url
:
'/frontBanner/online'
,
success
:
function
(
res
)
{
console
.
log
(
res
)
}
})
}
</script>
</body>
</html>
\ No newline at end of file
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/resources/templates/zhengzai/store/placingOrder/activityList.html
View file @
ff00e9fb
...
...
@@ -10,24 +10,6 @@
.paddings
{
padding
:
0
!important
;
}
#addClassify
{
display
:
none
;
width
:
540px
;
padding
:
20px
;
}
#addClassify
.selectClassify
{
display
:
flex
;
align-items
:
center
;
}
#addClassify
.selectClassify
label
{
display
:
flex
;
margin-right
:
20px
;
align-items
:
center
;
}
#addClassify
.selectClassify
label
input
{
margin
:
0
;
margin-right
:
2px
;
}
.shadeCss
,
.layui-layer-shade
{
background-color
:
rgb
(
0
,
0
,
0
,
0.5
)
!important
;
}
...
...
@@ -76,13 +58,13 @@
<div
class=
"row"
>
<div
class=
"btn-group-sm"
id=
"toolbar"
>
<div>
<a
class=
"btn btn-primary"
id=
"button-open-10
"
>
<a
class=
"btn btn-primary"
onclick=
"functionBtn(1)
"
>
启用
</a>
<a
class=
"btn btn-warning"
id=
"button-open-10
"
>
<a
class=
"btn btn-warning"
onclick=
"functionBtn(2)
"
>
停用
</a>
<a
class=
"btn btn-danger"
id=
"button-open-10
"
>
<a
class=
"btn btn-danger"
onclick=
"functionBtn(3)
"
>
删除
</a>
<a
class=
"btn btn-success"
id=
"addActivity"
th:onclick=
"$.operate.addTab()"
>
...
...
@@ -110,7 +92,7 @@
~
<input
type=
"text"
class=
"layui-input form-control"
id=
"test1"
name=
"endTime"
style=
"margin-left: 10px;"
placeholder=
"请选择时间"
>
<li>
<a
class=
"btn btn-primary btn-rounded btn-sm"
onclick=
"$.table.search()"
><i
class=
"fa fa-search"
></i>
搜索
</a>
<a
id=
"searchBtns"
class=
"btn btn-primary btn-rounded btn-sm"
onclick=
"$.table.search()"
><i
class=
"fa fa-search"
></i>
搜索
</a>
<a
class=
"btn btn-warning btn-rounded btn-sm"
onclick=
"$.form.reset()"
><i
class=
"fa fa-refresh"
></i>
重置
</a>
</li>
</div>
...
...
@@ -124,32 +106,7 @@
<div
class=
"col-sm-12 select-table table-striped"
>
<table
id=
"bootstrap-table"
></table>
</div>
<div
id=
"addClassify"
>
<div
class=
"selectClassify"
>
<span>
LOGO:
</span>
<img
id=
"viewImg"
src=
""
alt=
""
style=
"max-height:150px;"
>
<div
class=
"ibox-content"
>
<div
class=
"form-group"
>
<div
class=
"file-loading"
>
<input
id=
"fileinput"
type=
"file"
name=
"file"
data-browse-on-zone-click=
"true"
data-theme=
"fas"
>
</div>
</div>
</div>
</div>
<div
class=
"selectClassifyOne"
>
<span>
昵称:
</span>
<input
class=
"form-control"
type=
"text"
>
</div>
<div
class=
"selectClassify"
>
<span>
类别:
</span>
<label>
<input
type=
"radio"
checked
value=
"1"
id=
"optionsRadios1"
name=
"optionsRadios"
><span>
音乐人
</span></label>
<label>
<input
type=
"radio"
value=
"2"
id=
"optionsRadios1"
name=
"optionsRadios"
><span>
艺术家
</span></label>
<label>
<input
type=
"radio"
value=
"3"
id=
"optionsRadios1"
name=
"optionsRadios"
><span>
IP
</span></label>
</div>
</div>
</div>
</div>
<th:block
th:include=
"include :: footer"
/>
...
...
@@ -160,19 +117,10 @@
var
platformUrl
=
[[
$
{
platformUrl
}]];
var
prefix
=
ctx
+
"candy/coupon/mgt"
;
var
prefix2
=
ctx
+
"local"
;
var
viewMgtCouponFlag
=
[[
$
{@
permission
.
hasPermi
(
'candy:coupon:mgt:detail'
)}]];
var
cancelMgtCouponFlag
=
[[
$
{@
permission
.
hasPermi
(
'candy:coupon:mgt:cancel'
)}]];
let
rowData
=
{};
var
couType
=
[[
$
{
couType
}]];
layui
.
use
(
'laydate'
,
function
(){
var
laydate
=
layui
.
laydate
;
//执行一个laydate实例
laydate
.
render
({
elem
:
'#test1'
,
//指定元素
type
:
'datetime'
});
});
$
(
function
()
{
var
options
=
{
url
:
"/goblin/marketing/zhengzai/list"
,
...
...
@@ -183,16 +131,13 @@
openTab
:
prefix2
+
"/activityStoreList/id={id}"
,
// exportUrl: prefix + "/export",
onCheck
:
onCheck
,
// onCheckAll: onCheckAll,
sortName
:
"createdAt"
,
sortOrder
:
"desc"
,
modalName
:
"活动"
,
showSearch
:
false
,
showRefresh
:
true
,
showColumns
:
false
,
showToggle
:
false
,
columns
:
[
{
checkbox
:
true
radio
:
true
},
{
field
:
'name'
,
...
...
@@ -225,11 +170,7 @@
},
{
field
:
'createdAt'
,
title
:
'创建时间'
,
// formatter: function(value, row, index) {
// console.log(value)
// // return $.common.dateFormat(value, 'yyyy-MM-dd HH:mm:ss')
// }
title
:
'创建时间'
},
{
field
:
'comment'
,
...
...
@@ -239,40 +180,49 @@
title
:
'操作'
,
align
:
'center'
,
formatter
:
function
(
value
,
row
,
index
)
{
return
`<a class="btn btn-info btn-xs" href="javascript:void(0)" onclick="$.operate.detailTab('
${
index
}
')", 7, '确定下架此商品吗?
')">编辑活动</a>
<a class="btn btn-info btn-xs" href="javascript:void(0)" onclick="goToStore_list('
${
row
.
itemId
}
', 7, '确定下架此商品吗?
')">查看详情</a>`
return
`<a class="btn btn-info btn-xs" href="javascript:void(0)" onclick="$.operate.detailTab('
${
row
.
selfMarketId
}
')">编辑活动</a>
<a class="btn btn-info btn-xs" href="javascript:void(0)" onclick="goToStore_list('
${
row
.
name
}
','
${
row
.
selfMarketId
}
','
${
row
.
startTime
}
-
${
row
.
endTime
}
')">查看详情</a>`
}
}]
};
$
.
table
.
init
(
options
);
});
$
(
"#button-open-10"
).
click
(
function
(){
var
btn
=
[
'<span style="display:inline-block;padding:0 15px;height:100%;" onclick="yes(1,2)">确定</span>'
,
'取消'
];
layer
.
open
({
type
:
1
,
shade
:
true
,
title
:
'创建分类'
,
//不显示标题
btn
,
content
:
$
(
'#addClassify'
),
//捕获的元素,注意:最好该指定的元素要存放在body最外层,否则可能被其它的相对元素所影响
success
:
function
()
{
console
.
log
(
1111
)
$
(
".layui-layer-btn0"
).
addClass
(
'paddings'
)
$
(
".layui-layer-shade"
).
addClass
(
'shadeCss'
)
},
cancel
:
function
(
res
){
console
.
log
(
res
,
'111'
)
// layer.msg('捕获就是从页面已经存在的元素上,包裹layer的结构', {time: 5000, icon:6});
function
functionBtn
(
type
)
{
let
status
=
''
;
if
(
type
==
1
)
{
status
=
0
;
}
else
if
(
type
==
2
)
{
status
=
7
;
}
else
{
status
=
-
1
;
}
let
data
=
{
marketId
:
rowData
.
selfMarketId
}
data
.
status
=
status
;
promiseMethods
(
'/goblin/marketing/zhengzai/status'
,
'post'
,
data
).
then
(
res
=>
{
console
.
log
(
res
,
'res'
)
if
(
res
.
code
==
0
)
{
layer
.
msg
(
'修改状态成功!'
)
setTimeout
(()
=>
{
$
(
"#searchBtns"
).
click
();
},
500
);
}
});
})
})
}
$
(
"#button-open-11"
).
click
(
function
(){
$
(
"button[name=refresh]"
).
click
()
})
function
goToStore_list
()
{
$
.
modal
.
openTab
(
'北京草莓音乐节'
,
prefix2
+
"/activityStoreList?id="
+
1212
)
function
goToStore_list
(
name
,
id
,
time
)
{
$
.
modal
.
openTab
(
name
,
prefix2
+
"/activityStoreList?id="
+
id
+
'&time='
+
time
)
}
function
onCheck
(
row
,
$element
)
{
console
.
log
(
row
,
$element
)
rowData
=
row
;
}
function
onCheckAll
(
row
,
$element
)
{
console
.
log
(
row
,
$element
)
rowData
=
row
;
}
function
yes
(
index
,
layero
)
{
console
.
log
(
index
,
layero
)
...
...
@@ -289,37 +239,34 @@
},
success
:
function
(
e
)
{
layer
.
msg
(
"操作成功!"
)
$
(
"button[name=refresh]"
).
click
()
setTimeout
(()
=>
{
$
(
"#searchBtns"
).
click
();
},
1500
);
}
})
});
}
$
(
function
(){
$
(
"#fileinput"
).
fileinput
({
'theme'
:
'explorer-fas'
,
'uploadUrl'
:
platformUrl
+
"/platform/basicServices/alOss/upload"
,
"uploadExtraData"
:
{
"pathName"
:
"banner"
,
"buckType"
:
1
},
autoReplace
:
true
,
showCaption
:
false
,
showPreview
:
false
,
showRemove
:
false
,
showUpload
:
false
,
showCancel
:
false
,
showClose
:
false
,
autoReplace
:
true
,
dropZoneTitle
:
"请上传文件"
,
maxFileCount
:
1
}).
on
(
"filebatchselected"
,
function
(
event
,
files
)
{
//默认上传
$
(
this
).
fileinput
(
"upload"
);
})
.
on
(
"fileuploaded"
,
function
(
event
,
data
)
{
//上传回调事件
showPicture
=
'https://img.zhengzai.tv/'
+
data
.
response
.
data
.
ossPath
;
$
(
"#viewImg"
).
attr
(
'src'
,
showPicture
)
layui
.
use
(
'laydate'
,
function
(){
var
laydate
=
layui
.
laydate
;
//执行一个laydate实例
laydate
.
render
({
elem
:
'#test1'
,
//指定元素
type
:
'datetime'
});
});
function
promiseMethods
(
url
,
type
,
data
,
contentType
)
{
return
new
Promise
((
resolve
,
reject
)
=>
{
$
.
ajax
({
url
,
type
,
data
,
contentType
,
success
:
function
(
res
)
{
resolve
(
res
);
}
})
})
}
)
}
</script>
</body>
</html>
\ No newline at end of file
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/resources/templates/zhengzai/store/placingOrder/activityStoreList.html
View file @
ff00e9fb
...
...
@@ -2,7 +2,6 @@
<html
lang=
"zh"
xmlns:th=
"http://www.thymeleaf.org"
xmlns:shiro=
"http://www.pollix.at/thymeleaf/shiro"
>
<head>
<th:block
th:include=
"include :: header('店铺列表')"
/>
<th:block
th:include=
"include :: bootstrap-fileinput-css"
/>
<style>
.layui-layer-btn0
{
padding
:
0
;
...
...
@@ -82,14 +81,17 @@
</div>
</div>
<div
class=
"col-sm-12 search-collapse"
>
<form
id=
"
coupon
-form"
>
<form
id=
"
role
-form"
>
<div
class=
"select-list"
>
<ul>
<div
class=
"leftSearchBox"
>
<input
class=
"form-control"
type=
"text"
placeholder=
"请输入店铺名字"
>
</div>
<div>
</div>
<input
type=
"hidden"
name=
"marketId"
value=
""
id=
"marketId"
>
<li>
店铺名称:
<input
type=
"text"
name=
"roleName"
/>
</li>
<li>
<a
class=
"btn btn-primary btn-rounded btn-sm"
onclick=
"$.table.search()"
><i
class=
"fa fa-search"
></i>
搜索
</a>
<a
class=
"btn btn-warning btn-rounded btn-sm"
onclick=
"$.form.reset()"
><i
class=
"fa fa-refresh"
></i>
重置
</a>
</li>
</ul>
</div>
</form>
...
...
@@ -100,7 +102,6 @@
</div>
</div>
<th:block
th:include=
"include :: footer"
/>
<th:block
th:include=
"include :: bootstrap-fileinput-js"
/>
<script
th:inline=
"javascript"
>
var
dicCouponBusiType
=
[[
$
{@
dict
.
getType
(
'zhengzai_coupon_busi_type'
)}]];
var
dicCouponBindType
=
[[
$
{@
dict
.
getType
(
'zhengzai_coupon_bind_type'
)}]];
...
...
@@ -110,75 +111,78 @@
var
viewMgtCouponFlag
=
[[
$
{@
permission
.
hasPermi
(
'candy:coupon:mgt:detail'
)}]];
var
cancelMgtCouponFlag
=
[[
$
{@
permission
.
hasPermi
(
'candy:coupon:mgt:cancel'
)}]];
var
couType
=
[[
$
{
couType
}]];
$
(
function
()
{
$
(
"#fileinput"
).
fileinput
({
'theme'
:
'explorer-fas'
,
'uploadUrl'
:
platformUrl
+
"/platform/basicServices/alOss/upload"
,
"uploadExtraData"
:
{
"pathName"
:
"banner"
,
"buckType"
:
1
},
autoReplace
:
true
,
showCaption
:
false
,
showPreview
:
false
,
showRemove
:
false
,
showUpload
:
false
,
showCancel
:
false
,
showClose
:
false
,
autoReplace
:
true
,
dropZoneTitle
:
"请上传文件"
,
maxFileCount
:
1
}).
on
(
"filebatchselected"
,
function
(
event
,
files
)
{
//默认上传
$
(
this
).
fileinput
(
"upload"
);
$
(
function
()
{
// promiseMethods('', 'post', data);
let
name
=
'id'
;
let
time
=
'time'
;
var
reg
=
new
RegExp
(
"(^|&)"
+
name
+
"=([^&]*)(&|$)"
);
var
reg2
=
new
RegExp
(
"(^|&)"
+
time
+
"=([^&]*)(&|$)"
);
var
r
=
window
.
location
.
search
.
substr
(
1
).
match
(
reg
);
var
r2
=
window
.
location
.
search
.
substr
(
1
).
match
(
reg2
);
let
times
=
unescape
(
r2
[
2
])
console
.
log
(
times
)
if
(
r
)
{
$
(
"#marketId"
).
val
(
unescape
(
r
[
2
]));
}
$
.
ajax
({
type
:
'post'
,
url
:
'/goblin/marketing/zhengzai/store/list'
,
data
:
{
marketId
:
unescape
(
r
[
2
])},
success
:
function
(
res
)
{
var
options
=
{
createUrl
:
prefix2
+
"/addNewActivity"
,
detailUrl
:
prefix2
+
"/storeDetail?id={id}&time={times}&marketId={marketId}"
,
removeUrl
:
prefix
+
"/cancel/{id}"
,
updateUrl
:
prefix
+
"/edit/{id}"
,
// exportUrl: prefix + "/export",
onCheck
:
onCheck
,
data
:
res
.
data
,
// onLoadSuccess: onLoadSuccess,
showSearch
:
false
,
showRefresh
:
true
,
showColumns
:
false
,
showToggle
:
false
,
columns
:
[
{
checkbox
:
true
},
{
field
:
'storeName'
,
title
:
'店铺'
},
{
field
:
'spuCount'
,
title
:
'活动商品数量'
},
{
title
:
'操作'
,
align
:
'center'
,
formatter
:
function
(
value
,
row
,
index
)
{
return
`<a class="btn btn-info btn-xs" href="javascript:void(0)" onclick="goDetail('
${
row
.
storeName
}
','
${
row
.
storeId
}
', '
${
times
}
', '
${
unescape
(
r
[
2
])}
')">查看详情</a>`
}
}]
};
$
.
table
.
init
(
options
);
}
})
.
on
(
"fileuploaded"
,
function
(
event
,
data
)
{
//上传回调事件
showPicture
=
'https://img.zhengzai.tv/'
+
data
.
response
.
data
.
ossPath
;
$
(
"#viewImg"
).
attr
(
'src'
,
showPicture
)
})
var
options
=
{
url
:
prefix
+
"/list"
,
createUrl
:
prefix2
+
"/addNewActivity"
,
detailUrl
:
prefix2
+
"/storeDetail?id={id}"
,
removeUrl
:
prefix
+
"/cancel/{id}"
,
updateUrl
:
prefix
+
"/edit/{id}"
,
// exportUrl: prefix + "/export",
onCheck
:
onCheck
,
sortName
:
"createdAt"
,
sortOrder
:
"desc"
,
modalName
:
"活动"
,
showSearch
:
false
,
showRefresh
:
true
,
showColumns
:
false
,
showToggle
:
false
,
columns
:
[
{
checkbox
:
true
},
{
field
:
'valFace'
,
title
:
'店铺'
},
{
field
:
'bindType'
,
title
:
'活动商品数量'
,
formatter
:
function
(
value
,
row
,
index
)
{
// $('.pull-right').hide()
return
$
.
table
.
selectDictLabel
(
dicCouponBindType
,
value
);
}
},
{
title
:
'操作'
,
align
:
'center'
,
formatter
:
function
(
value
,
row
,
index
)
{
return
`<a class="btn btn-info btn-xs" href="javascript:void(0)" onclick="$.operate.detailTab('
${
row
.
itemId
}
', 7, '确定下架此商品吗?')">查看详情</a>`
}
}]
};
$
.
table
.
init
(
options
);
});
function
onCheck
(
row
,
$element
)
{
console
.
log
(
row
,
$element
)
}
// function onLoadSuccess (data) {
// console.log(data, 123)
// data = data.data
// $.table.init();
// }
// function responseHandler (data) {
// console.log(data, 1223)
// data = data.data
// $.table.init();
// }
function
goDetail
(
name
,
storeId
,
time
,
marketId
)
{
console
.
log
(
name
,
storeId
,
time
,
marketId
,
'????'
)
$
.
modal
.
openTab
(
name
,
prefix2
+
"/storeDetail?storeId="
+
storeId
+
'&time='
+
time
+
'&marketId='
+
marketId
)
}
$
(
"#button-open-11"
).
click
(
function
(){
$
(
"button[name=refresh]"
).
click
()
})
...
...
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/resources/templates/zhengzai/store/placingOrder/addNewActivity.html
View file @
ff00e9fb
...
...
@@ -90,8 +90,11 @@
~
<input
type=
"text"
class=
"layui-input form-control"
id=
"endTime"
style=
"margin-left: 10px;"
autocomplete=
"off"
placeholder=
"请选择活动结束时间"
>
</div>
<div
class=
"first_footer"
style=
"padding-left: 60px;margin-top: 12px;"
>
<button
class=
"btn btn-primary"
onclick=
"nextBtn()"
>
确定
</button>
</div>
</div>
<div
class=
"content_item"
>
<div
class=
"content_item"
style=
"display: none;"
>
<div
class=
"content_title"
>
<h3><span></span>
设置
</h3>
</div>
...
...
@@ -101,35 +104,38 @@
选择店铺:
</span>
<div
class=
"activityStore"
>
<div
class=
"activityStore_item"
>
<button
class=
"btn btn-primary"
onclick=
"addItem()"
style=
"margin-bottom: 12px;"
>
新增
</button>
<div
class=
"activityStore_item"
id=
"activityStore_item"
>
<div
class=
"input-group"
style=
"margin-right: 12px;"
>
<input
type=
"text"
class=
"form-control storeList item1"
placeholder=
"搜索店铺名称"
>
<div
class=
"input-group-btn"
>
<ul
class=
"dropdown-menu dropdown-menu-right"
role=
"menu"
>
</ul>
</div>
<!-- /btn-group -->
</div>
<input
type=
"text"
class=
"layui-input form-control"
id=
"startTime"
autocomplete=
"off"
placeholder=
"配置活动时间"
>
<button
class=
"btn btn-primary"
onclick=
"addItem()"
>
新增
</button>
<input
type=
"text"
class=
"layui-input form-control
timeSp
"
id=
"startTime"
autocomplete=
"off"
placeholder=
"配置活动时间"
>
</div>
</div>
</div>
</div>
<div
class=
"add_footer"
>
<button
class=
"btn btn-success"
onclick=
"
addItem
()"
>
保存
</button>
<
button
class=
"btn"
onclick=
"addItem()"
>
取消
</button
>
<div
class=
"add_footer"
style=
"display: none;"
>
<button
class=
"btn btn-success"
onclick=
"
save
()"
>
保存
</button>
<
!-- <button class="btn" onclick="addItem()">取消</button> --
>
</div>
</div>
<th:block
th:include=
"include :: footer"
/>
<th:block
th:include=
"include :: bootstrap-suggest-js"
/>
<th:block
th:include=
"include :: bootstrap-typeahead-js"
/>
<th:block
th:include=
"include :: bootstrap-fileinput-js"
/>
</body>
<script
th:inline=
"javascript"
>
let
count
=
1
;
var
prefix2
=
ctx
+
"local"
;
let
marketId
=
''
;
$
(
function
()
{
let
name
=
'id'
;
var
reg
=
new
RegExp
(
"(^|&)"
+
name
+
"=([^&]*)(&|$)"
);
var
r
=
window
.
location
.
search
.
substr
(
1
).
match
(
reg
);
layui
.
use
(
'laydate'
,
function
(){
var
laydate
=
layui
.
laydate
;
//执行一个laydate实例
...
...
@@ -142,16 +148,42 @@
type
:
'datetime'
});
});
common
()
common
();
if
(
r
)
{
marketId
=
unescape
(
r
[
2
]);
console
.
log
(
marketId
,
'取到没'
)
let
data
=
{
marketId
}
let
searchActivity
=
promiseMethods
(
'/goblin/marketing/zhengzai/details'
,
'post'
,
data
);
let
searchActivityStore
=
promiseMethods
(
'/goblin/marketing/zhengzai/store/list'
,
'post'
,
data
);
Promise
.
all
([
searchActivity
,
searchActivityStore
]).
then
(
res
=>
{
console
.
log
(
res
,
'res'
)
let
basisData
=
res
[
0
];
let
{
data
}
=
res
[
1
];
$
(
"#selectShow"
).
val
(
basisData
.
data
.
name
);
$
(
"#startTime"
).
val
(
basisData
.
data
.
startTime
);
$
(
"#endTime"
).
val
(
basisData
.
data
.
endTime
);
$
(
".content_item"
).
show
();
$
(
".add_footer"
).
show
();
$
(
"#activityStore_item"
).
remove
();
data
.
forEach
((
item
,
index
)
=>
{
addItem
(
item
)
})
})
}
})
function
common
()
{
$
(
"#selectShow"
).
bsSuggest
({
idField
:
'performancesId'
,
keyField
:
'title'
,
allowNoKeyword
:
false
,
//是否允许无关键字时请求数据
showBtn
:
false
,
multiWord
:
true
,
//以分隔符号分割的多关键字支持
hideOnSelect
:
true
,
getDataMethod
:
"url"
,
//获取数据的方式,总是从 URL 获取
url
:
ctx
+
'kylin/base/performance/status?status=(3,6)&title='
,
effectiveFields
:
[
'title'
],
url
:
'/kylin/base/performance/status?status=(3,6)&title='
,
/*如果从 url 获取数据,并且需要跨域,则该参数必须设置*/
processData
:
function
(
json
)
{
// url 获取数据时,对数据的处理,作为 getData 的回调函数
//字符串转化为 js 对象
...
...
@@ -159,34 +191,52 @@
}
});
$
(
".storeList"
).
bsSuggest
({
idField
:
'storeId'
,
keyField
:
'storeName'
,
allowNoKeyword
:
false
,
//是否允许无关键字时请求数据
showBtn
:
false
,
multiWord
:
true
,
//以分隔符号分割的多关键字支持
hideOnSelect
:
true
,
effectiveFields
:
[
'storeName'
],
getDataMethod
:
"url"
,
//获取数据的方式,总是从 URL 获取
url
:
ctx
+
'kylin/base/performance/status?status=(3,6)&title='
,
/*如果从 url 获取数据,并且需要跨域,则该参数必须设置*/
url
:
'/goblin/store/list?roleName='
,
processData
:
function
(
json
)
{
// url 获取数据时,对数据的处理,作为 getData 的回调函数
//字符串转化为 js 对象
return
json
;
// return json.rows;
let
data
=
{};
data
.
value
=
json
.
rows
;
return
data
// console.log(json, 'json')
}
});
}
function
addItem
()
{
function
addItem
(
item
)
{
count
++
;
let
body
=
''
;
body
+=
`<div class="activityStore_item">
if
(
item
)
{
body
+=
`<div class="activityStore_item">
<div class="input-group" style="margin-right: 12px;">
<input type="text" class="form-control storeList item
${
count
}
" data-id="
${
item
.
storeId
}
" value="
${
item
.
storeName
}
" placeholder="搜索店铺名称">
<div class="input-group-btn">
<ul class="dropdown-menu dropdown-menu-right" role="menu">
</ul>
</div>
</div>
<input type="text" class="layui-input form-control timeSp startTime
${
count
}
" id="startTime" value="
${
item
.
showTime
}
" autocomplete="off" placeholder="配置活动时间">
</div>`
}
else
{
body
+=
`<div class="activityStore_item">
<div class="input-group" style="margin-right: 12px;">
<input type="text" class="form-control storeList item
${
count
}
" placeholder="搜索店铺名称">
<div class="input-group-btn">
<ul class="dropdown-menu dropdown-menu-right" role="menu">
</ul>
</div>
<!-- /btn-group -->
</div>
<input type="text" class="layui-input form-control startTime
${
count
}
" id="startTime" autocomplete="off" placeholder="配置活动时间">
<input type="text" class="layui-input form-control
timeSp
startTime
${
count
}
" id="startTime" autocomplete="off" placeholder="配置活动时间">
</div>`
}
$
(
".activityStore"
).
append
(
body
)
common
()
layui
.
use
(
'laydate'
,
function
(){
...
...
@@ -198,5 +248,60 @@
});
});
}
function
nextBtn
(
params
)
{
let
data
=
{
endTime
:
$
(
"#endTime"
).
val
(),
startTime
:
$
(
"#startTime"
).
val
(),
name
:
$
(
"#selectShow"
).
val
(),
performanceId
:
$
(
"#selectShow"
).
attr
(
'data-id'
)
}
// endTime
if
(
marketId
)
{
data
.
marketId
=
marketId
;
promiseMethods
(
'/goblin/marketing/zhengzai/change'
,
'post'
,
data
).
then
(
res
=>
{
if
(
res
.
code
==
0
)
{
layer
.
msg
(
'修改活动成功,请配置活动对应店铺!'
)
}
})
}
else
{
promiseMethods
(
'/goblin/marketing/zhengzai'
,
'post'
,
data
).
then
(
res
=>
{
if
(
res
.
code
==
0
)
{
marketId
=
res
.
data
;
layer
.
msg
(
'添加活动成功,请配置活动对应店铺!'
)
$
(
".content_item"
).
show
();
$
(
".add_footer"
).
show
();
}
})
}
}
function
save
()
{
let
obj
=
{};
let
data
=
[];
let
domData
=
$
(
".activityStore_item"
);
Array
.
prototype
.
forEach
.
call
(
domData
,
function
(
item
,
index
){
obj
[
'marketId'
]
=
marketId
;
obj
[
'showTime'
]
=
item
.
querySelector
(
'.timeSp'
).
value
;
obj
[
'storeId'
]
=
item
.
querySelector
(
'.storeList'
).
getAttribute
(
'data-id'
);
data
.
push
({...
obj
});
})
console
.
log
(
data
)
promiseMethods
(
'/goblin/marketing/zhengzai/store'
,
'post'
,
JSON
.
stringify
(
data
),
'application/json'
).
then
(
res
=>
{
// $.operate.successCallback(res);
})
}
function
promiseMethods
(
url
,
type
,
data
,
contentType
)
{
return
new
Promise
((
resolve
,
reject
)
=>
{
$
.
ajax
({
url
,
type
,
data
,
contentType
,
success
:
function
(
res
)
{
resolve
(
res
);
}
})
})
}
</script>
</html>
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/resources/templates/zhengzai/store/placingOrder/storeDetail.html
View file @
ff00e9fb
...
...
@@ -30,6 +30,7 @@
height
:
56px
;
font-size
:
16px
;
padding-left
:
12px
;
}
.content_item
.content_store_name
input
{
margin-left
:
12px
;
...
...
@@ -129,30 +130,33 @@
</div>
<div
class=
"content_store_name"
>
<span>
有效期:
</span><p
>
2021年12月24日11:24
</p>
至
<p>
2021年12月28日11:24
</p>
<span>
有效期:
</span><p
id=
"time"
>
</p>
</div>
<input
type=
"hidden"
name=
"storeId"
id=
"storeId"
>
<input
type=
"hidden"
name=
"marketId"
id=
"marketId"
>
</div>
<div
class=
"content_item"
>
<div
class=
"content_title"
>
<h3><span></span>
认证信息
</h3>
</div>
<
div
class=
"content_store_name"
>
<span><em
class=
"required"
>
*
</em>
证件类型:
</span>
<
!-- <div class="content_store_name"> --
>
<
!-- <
span><em class="required">*</em>证件类型:</span>
<label>
<input type="radio" checked value="1" id="optionsRadios1" name="optionsRadios"><span>全部商品</span></label>
<label>
<input type="radio" value="2" id="optionsRadios1" name="optionsRadios"><span>部分商品参与</span></label>
<label>
<input
type=
"radio"
value=
"3"
id=
"optionsRadios1"
name=
"optionsRadios"
><span>
部分商品不参与
</span></label>
<
/div
>
<input type="radio" value="3" id="optionsRadios1" name="optionsRadios"><span>部分商品不参与</span></label>
-->
<
!-- </div> --
>
<div
class=
"goodsTable"
>
<div
class=
"selectGoods"
>
<
!-- <
div class="selectGoods">
<button type="button" class="btn btn-warning" onclick="selectGoodsTab()">选择商品</button>
</div>
</div>
-->
<div
class=
"goodsList select-table table-striped"
style=
"padding: 0 12px;"
>
<table
id=
"tabList"
></table>
</div>
</div>
</div>
<div
class=
"content_footer"
>
<button
class=
"btn btn-primary"
>
保存
</button>
...
...
@@ -162,54 +166,104 @@
<th:block
th:include=
"include :: footer"
/>
</body>
<script
th:inline=
"javascript"
>
$
(
function
()
{
let
name
=
'storeId'
;
let
time
=
'time'
;
let
marketId
=
'marketId'
;
var
reg
=
new
RegExp
(
"(^|&)"
+
name
+
"=([^&]*)(&|$)"
);
var
reg2
=
new
RegExp
(
"(^|&)"
+
time
+
"=([^&]*)(&|$)"
);
var
reg3
=
new
RegExp
(
"(^|&)"
+
marketId
+
"=([^&]*)(&|$)"
);
var
r
=
window
.
location
.
search
.
substr
(
1
).
match
(
reg
);
var
r2
=
window
.
location
.
search
.
substr
(
1
).
match
(
reg2
);
var
r3
=
window
.
location
.
search
.
substr
(
1
).
match
(
reg3
);
$
(
"#time"
).
html
(
unescape
(
r2
[
2
]));
$
(
"#storeId"
).
val
();
$
(
"#marketId"
).
val
();
console
.
log
(
unescape
(
r
[
2
]),
unescape
(
r2
[
2
]),
unescape
(
r3
[
2
]),
'sha'
)
let
data
=
{
marketId
:
unescape
(
r3
[
2
]),
storeId
:
unescape
(
r
[
2
]),
// pageSize: 10,
pageNum
:
1
}
$
.
ajax
({
url
:
'/goblin/marketing/zhengzai/spu'
,
type
:
'post'
,
data
,
success
:
function
(
res
)
{
// let data = [
// {
// "marketSpuId": "string",
// "coverPic": "https://img.zhengzai.tv/other/2021/12/09/dd3259aaa66e4c3995ce2ab0ce38856c.png",
// "name": "这是一个名字这是一个名字这是一个名字",
// "priceGe": 2,
// "priceLe": 10
// }
// ]
var
options
=
{
id
:
'tabList'
,
// url: '/goblin/marketing/zhengzai/spu',
createUrl
:
prefix2
+
"/addNewActivity"
,
detailUrl
:
prefix2
+
"/storeDetail?id={id}"
,
// exportUrl: prefix + "/export",
onCheck
:
onCheck
,
showSearch
:
false
,
showRefresh
:
false
,
showColumns
:
false
,
showToggle
:
false
,
data
:
res
.
data
,
columns
:
[
{
field
:
'name'
,
title
:
'商品'
,
width
:
'400'
,
formatter
:
function
(
value
,
row
,
index
)
{
let
str
=
`<div class="titleBox" style="display:flex;align-items:center;">
<img src="
${
row
.
coverPic
}
" alt="" style="height:60px">
<div class="titleData">
<p style="margin:0">
${
value
}
</p>
<p style="margin:0">¥
${
row
.
priceGe
}
- ¥
${
row
.
priceLe
}
</p>
</div>
</div>`
return
str
;
}
},
{
field
:
'valFace'
,
title
:
'线下售价'
,
// formatter: function (value, row, index) {
// let btns = [];
// if (index % 2 == 0) {
// btns.push(`
<
a
class
=
""
href
=
"javascript:;"
onclick
=
"setGoodsRole()"
>
设置商品规则
<
/a>`
)
// } else {
// btns.push(`
<
span
class
=
""
href
=
"javascript:;"
onclick
=
"$.operate.detailTab('${row.itemId}', 7, '确定下架此商品吗?')"
>
已设置商品规则
<
/span
>
//
<
a
class
=
""
href
=
"javascript:;"
style
=
"margin-left:12px"
onclick
=
"$.operate.detailTab('${row.itemId}', 7, '确定下架此商品吗?')"
>
修改
<
/a>`
)
// }
// return btns.join('')
// }
formatter
:
function
(
value
,
row
,
index
)
{
return
`<a class="btn btn-success btn-xs" href="javascript:void(0)" onclick="setGoodsRole('
${
$
(
"#marketId"
).
val
()}
', '
${
$
(
"#storeId"
).
val
()}
', '
${
row
.
marketSpuId
}
')">查看</a>`
}
},
{
title
:
'操作'
,
align
:
'center'
,
formatter
:
function
(
value
,
row
,
index
)
{
return
`<a class="btn btn-danger btn-xs" href="javascript:void(0)" onclick="delItem('
${
$
(
"#marketId"
).
val
()}
', '
${
$
(
"#storeId"
).
val
()}
', '
${
row
.
marketSpuId
}
')">删除</a>`
}
}]
};
console
.
log
(
options
,
'options'
)
$
.
table
.
init
(
options
);
}
})
});
var
dicCouponBusiType
=
[[
$
{@
dict
.
getType
(
'zhengzai_coupon_busi_type'
)}]];
var
dicCouponBindType
=
[[
$
{@
dict
.
getType
(
'zhengzai_coupon_bind_type'
)}]];
var
prefix
=
ctx
+
"candy/coupon/mgt"
;
var
prefix2
=
ctx
+
"local"
;
$
(
function
()
{
var
options
=
{
id
:
'tabList'
,
url
:
prefix
+
"/list"
,
createUrl
:
prefix2
+
"/addNewActivity"
,
detailUrl
:
prefix2
+
"/storeDetail?id={id}"
,
// exportUrl: prefix + "/export",
onCheck
:
onCheck
,
sortName
:
"createdAt"
,
sortOrder
:
"desc"
,
modalName
:
"活动"
,
showSearch
:
false
,
showRefresh
:
false
,
showColumns
:
false
,
showToggle
:
false
,
columns
:
[
{
field
:
'valFace'
,
title
:
'商品'
},
{
field
:
'valFace'
,
title
:
'线下售价'
,
formatter
:
function
(
value
,
row
,
index
)
{
let
btns
=
[];
if
(
index
%
2
==
0
)
{
btns
.
push
(
`<a class="" href="javascript:;" onclick="setGoodsRole()">设置商品规则</a>`
)
}
else
{
btns
.
push
(
`<span class="" href="javascript:;" onclick="$.operate.detailTab('
${
row
.
itemId
}
', 7, '确定下架此商品吗?')">已设置商品规则</span>
<a class="" href="javascript:;" style="margin-left:12px" onclick="$.operate.detailTab('
${
row
.
itemId
}
', 7, '确定下架此商品吗?')">修改</a>`
)
}
return
btns
.
join
(
''
)
}
},
{
title
:
'操作'
,
align
:
'center'
,
formatter
:
function
(
value
,
row
,
index
)
{
return
`<a class="btn btn-danger btn-xs" href="javascript:void(0)" onclick="$.operate.detailTab('
${
row
.
itemId
}
', 7, '确定下架此商品吗?')">删除</a>`
}
}]
};
$
.
table
.
init
(
options
);
});
function
setGoodsRole
()
{
let
url
=
prefix2
+
'/setGoodsRole'
console
.
log
(
url
)
...
...
@@ -218,6 +272,21 @@
function
onCheck
(
row
,
$element
)
{
console
.
log
(
row
,
$element
)
}
function
delItem
(
marketId
,
storeId
,
marketSpuId
)
{
$
.
ajax
({
url
:
'/goblin/marketing/zhengzai/sku/del'
,
type
:
'post'
,
data
:
{
marketId
,
storeId
,
skuId
:
marketSpuId
},
success
:
function
(
res
)
{
console
.
log
(
res
)
refreshItem
()
}
})
}
function
selectGoodsTab
()
{
let
url
=
prefix2
+
'/selectGoddsTab'
console
.
log
(
url
)
...
...
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