Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
施宇
/
icsales
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
38b60c08
authored
Jul 15, 2019
by
施宇
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
111
parent
3c2e6093
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
298 additions
and
62 deletions
Application/Home/View/Home/index.html
Application/Home/View/Index/index.html
Application/Home/View/Index/search.html
Application/Home/View/QuotePrice/inquiry.html
Application/Home/View/QuotePrice/releaseinquiry.html
Application/Home/View/RobOrder/index.html
Application/Home/View/Search/index.html
dist/css/common/base.css
dist/css/common/base.less
dist/js/global/api.js
dist/js/global/global.min.js
dist/js/home/index.js
dist/js/index/search.js
dist/js/quoteprice/inquiry.js
dist/js/roborder/index.js
dist/js/search/index.js
Application/Home/View/Home/index.html
View file @
38b60c08
...
@@ -48,7 +48,7 @@
...
@@ -48,7 +48,7 @@
<div
class=
"search_div clr"
>
<div
class=
"search_div clr"
>
<div
class=
"input_div fl"
>
<div
class=
"input_div fl"
>
<span
class=
"icon iconfont iconjuxing"
></span>
<span
class=
"icon iconfont iconjuxing"
></span>
<input
type=
"text"
placeholder=
"请输入要搜索的内容"
>
<input
type=
"text"
placeholder=
"请输入要搜索的内容"
class=
"search-input"
>
</div>
</div>
<div
class=
"btn fl btn_60 btn_fz_18 input_btn bold btn_blue"
>
<div
class=
"btn fl btn_60 btn_fz_18 input_btn bold btn_blue"
>
搜索
搜索
...
...
Application/Home/View/Index/index.html
View file @
38b60c08
...
@@ -27,7 +27,7 @@
...
@@ -27,7 +27,7 @@
<div
class=
"search_div clr"
>
<div
class=
"search_div clr"
>
<div
class=
"input_div fl"
>
<div
class=
"input_div fl"
>
<span
class=
"icon iconfont iconjuxing"
></span>
<span
class=
"icon iconfont iconjuxing"
></span>
<input
type=
"text"
placeholder=
"请输入要搜索的型号"
>
<input
type=
"text"
placeholder=
"请输入要搜索的型号"
class=
"search-input"
>
</div>
</div>
<div
class=
"input_btn fl btn_48 btn bold btn_blue"
>
<div
class=
"input_btn fl btn_48 btn bold btn_blue"
>
搜索
搜索
...
@@ -263,11 +263,18 @@
...
@@ -263,11 +263,18 @@
});
});
$
(
'.input_btn'
).
click
(
function
()
{
$
(
'.input_btn'
).
click
(
function
()
{
var
key
=
$
(
'.search-input'
).
val
();
if
(
key
)
{
window
.
location
.
href
=
search_url
+
'/indexsearch?key='
+
key
;
}
else
{
window
.
location
.
href
=
search_url
+
'/indexsearch'
window
.
location
.
href
=
search_url
+
'/indexsearch'
})
}
});
$
(
'.mobile_wrapper .lb_nav span'
).
click
(
function
()
{
$
(
'.mobile_wrapper .lb_nav span'
).
click
(
function
()
{
var
index
=
$
(
this
).
index
();
var
index
=
$
(
this
).
index
();
$
(
'.mobile_wrapper .lb_div_content'
).
css
(
'left'
,
-
(
index
*
700
/
7
)
+
'vw'
);
$
(
'.mobile_wrapper .lb_div_content'
).
css
(
'left'
,
-
(
index
*
700
/
7
)
+
'vw'
);
$
(
this
).
addClass
(
'active'
).
siblings
().
removeClass
(
'active'
)
$
(
this
).
addClass
(
'active'
).
siblings
().
removeClass
(
'active'
)
});
});
...
...
Application/Home/View/Index/search.html
View file @
38b60c08
...
@@ -15,7 +15,7 @@
...
@@ -15,7 +15,7 @@
<div
class=
"search_div clr"
>
<div
class=
"search_div clr"
>
<div
class=
"input_div fl"
>
<div
class=
"input_div fl"
>
<span
class=
"icon iconfont iconjuxing"
></span>
<span
class=
"icon iconfont iconjuxing"
></span>
<input
type=
"text"
placeholder=
"请输入要搜索的内容"
>
<input
type=
"text"
placeholder=
"请输入要搜索的内容"
class=
"input-search"
>
</div>
</div>
<div
class=
"input_btn fl btn_48 btn bold btn_blue"
>
<div
class=
"input_btn fl btn_48 btn bold btn_blue"
>
搜索
搜索
...
@@ -33,19 +33,19 @@
...
@@ -33,19 +33,19 @@
<div
class=
"zz condition_content"
>
<div
class=
"zz condition_content"
>
<span
class=
"bold"
>
时间:
</span>
<span
class=
"bold"
>
时间:
</span>
<div
class=
"condition_right_content clr"
>
<div
class=
"condition_right_content clr"
>
<div
class=
"fl
active
"
>
今天
</div>
<div
class=
"fl
jt
"
>
今天
</div>
<div
class=
"fl"
>
三天之内
</div>
<div
class=
"fl
st
"
>
三天之内
</div>
<div
class=
"fl
"
>
本周
</div>
<div
class=
"fl
qt"
>
七天之内
</div>
</div>
</div>
</div>
</div>
<div
class=
"fz condition_content "
>
<
!-- <
div class="fz condition_content ">
<span class="bold">封装:</span>
<span class="bold">封装:</span>
<div class="condition_right_content clr">
<div class="condition_right_content clr">
<div class="fl">贸易商</div>
<div class="fl">贸易商</div>
<div class="fl">贸易商</div>
<div class="fl">贸易商</div>
<div class="fl">贸易商</div>
<div class="fl">贸易商</div>
</div>
</div>
</div>
</div>
-->
</div>
</div>
<div
class=
"goods_data_list search_data_list"
>
<div
class=
"goods_data_list search_data_list"
>
</div>
</div>
...
...
Application/Home/View/QuotePrice/inquiry.html
View file @
38b60c08
...
@@ -101,7 +101,7 @@
...
@@ -101,7 +101,7 @@
<
div
class
=
"time fr ellipsis boxsiz"
>
{{
layui
.
util
.
toDateString
(
item
.
update_time
*
1000
)}}
<
/div
>
<
div
class
=
"time fr ellipsis boxsiz"
>
{{
layui
.
util
.
toDateString
(
item
.
update_time
*
1000
)}}
<
/div
>
<
/div
>
<
/div
>
<
a
class
=
"icon iconfont iconjuxing2 fr"
><
/a
>
<
a
class
=
"icon iconfont iconjuxing2 fr"
><
/a
>
{{
#
if
(
item
[
'status
/eq'
]
!
==
1
){
}}
{{
#
if
(
item
[
'status
'
]
==
1
){
}}
{{
#
if
(
item
[
'audit_status'
]
==
1
){
}}
{{
#
if
(
item
[
'audit_status'
]
==
1
){
}}
<
a
class
=
"xj xj_status fr"
>
下架
<
/a
>
<
a
class
=
"xj xj_status fr"
>
下架
<
/a
>
{{
#
}
else
{
}}
{{
#
}
else
{
}}
...
...
Application/Home/View/QuotePrice/releaseinquiry.html
View file @
38b60c08
...
@@ -13,7 +13,7 @@
...
@@ -13,7 +13,7 @@
<include
file=
"public/top"
/>
<include
file=
"public/top"
/>
<div
class=
"right_content release_inquiry_content"
>
<div
class=
"right_content release_inquiry_content"
>
<div
class=
"content"
>
<div
class=
"content"
>
<div
class=
"nav_title"
>
商品管理 > 发布商品 > 上传商品
</div>
<div
class=
"nav_title"
>
询报价 > 发布询价
</div>
<div
class=
"inquiry_form"
>
<div
class=
"inquiry_form"
>
<div
class=
"top_title clr"
>
<div
class=
"top_title clr"
>
<h3
class=
"bold fl"
>
发布询价
</h3>
<h3
class=
"bold fl"
>
发布询价
</h3>
...
...
Application/Home/View/RobOrder/index.html
View file @
38b60c08
This diff is collapsed.
Click to expand it.
Application/Home/View/Search/index.html
View file @
38b60c08
...
@@ -17,7 +17,7 @@
...
@@ -17,7 +17,7 @@
<div
class=
"search_div clr"
>
<div
class=
"search_div clr"
>
<div
class=
"input_div fl"
>
<div
class=
"input_div fl"
>
<span
class=
"icon iconfont iconjuxing"
></span>
<span
class=
"icon iconfont iconjuxing"
></span>
<input
type=
"text"
placeholder=
"请输入要搜索的内容"
>
<input
type=
"text"
placeholder=
"请输入要搜索的内容"
class=
"input-search"
>
</div>
</div>
<div
class=
"input_btn fl btn_48 btn bold btn_blue"
>
<div
class=
"input_btn fl btn_48 btn bold btn_blue"
>
搜索
搜索
...
@@ -29,25 +29,25 @@
...
@@ -29,25 +29,25 @@
</div>
</div>
<div
class=
"search_condition"
>
<div
class=
"search_condition"
>
<ul
class=
"search_nav clr"
>
<ul
class=
"search_nav clr"
>
<li
class=
"search_sp fl
active
"
>
商品
</li>
<li
class=
"search_sp fl"
>
商品
</li>
<li
class=
"search_xj fl"
>
询价
</li>
<li
class=
"search_xj fl"
>
询价
</li>
</ul>
</ul>
<div
class=
"zz condition_content"
>
<div
class=
"zz condition_content"
>
<span
class=
"bold"
>
时间:
</span>
<span
class=
"bold"
>
时间:
</span>
<div
class=
"condition_right_content clr"
>
<div
class=
"condition_right_content clr"
>
<div
class=
"fl
active
"
>
今天
</div>
<div
class=
"fl
jt
"
>
今天
</div>
<div
class=
"fl"
>
三天之内
</div>
<div
class=
"fl
st
"
>
三天之内
</div>
<div
class=
"fl
"
>
本周
</div>
<div
class=
"fl
qt"
>
七天之内
</div>
</div>
</div>
</div>
</div>
<div
class=
"fz condition_content "
>
<
!-- <
div class="fz condition_content ">
<span class="bold">封装:</span>
<span class="bold">封装:</span>
<div class="condition_right_content clr">
<div class="condition_right_content clr">
<div class="fl">贸易商</div>
<div class="fl">贸易商</div>
<div class="fl">贸易商</div>
<div class="fl">贸易商</div>
<div class="fl">贸易商</div>
<div class="fl">贸易商</div>
</div>
</div>
</div>
</div>
-->
</div>
</div>
<div
class=
"goods_data_list"
>
<div
class=
"goods_data_list"
>
</div>
</div>
...
...
dist/css/common/base.css
View file @
38b60c08
...
@@ -550,6 +550,9 @@ body {
...
@@ -550,6 +550,9 @@ body {
display
:
none
;
display
:
none
;
}
}
}
}
.layui-icon
{
display
:
none
!important
;
}
@font-face
{
@font-face
{
font-family
:
"iconfont"
;
font-family
:
"iconfont"
;
src
:
url('../../fonts/iconfont.eot?t=1561691322757')
;
src
:
url('../../fonts/iconfont.eot?t=1561691322757')
;
...
@@ -846,4 +849,3 @@ body {
...
@@ -846,4 +849,3 @@ body {
color
:
#ADB6BF
;
color
:
#ADB6BF
;
cursor
:
pointer
;
cursor
:
pointer
;
}
}
/*# sourceMappingURL=base.css.map */
\ No newline at end of file
dist/css/common/base.less
View file @
38b60c08
...
@@ -684,6 +684,9 @@ body {
...
@@ -684,6 +684,9 @@ body {
display: none;
display: none;
}
}
}
}
.layui-icon{
display: none !important;
}
// 字体样式
// 字体样式
@import "./fonts.less";
@import "./fonts.less";
...
...
dist/js/global/api.js
View file @
38b60c08
...
@@ -108,7 +108,7 @@
...
@@ -108,7 +108,7 @@
/***
/***
* 询价上下架
* 询价上下架
*/
*/
inquir
ysave
:
offer_url
+
"/inquiry
/save"
,
inquir
statusysave
:
offer_url
+
"/inquiry/status
/save"
,
/***
/***
* 询价统计
* 询价统计
*/
*/
...
...
dist/js/global/global.min.js
View file @
38b60c08
!
function
()
{
!
function
()
{
window
.
IcController
=
{
window
.
IcController
=
{
init
:
function
()
{
init
:
function
()
{
this
.
created
(
this
).
mounted
(
this
).
handleBind
(
this
);
this
.
created
(
this
).
mounted
(
this
).
handleBind
(
this
);
...
@@ -47,7 +47,9 @@
...
@@ -47,7 +47,9 @@
//处理token失效的情况
//处理token失效的情况
if
(
data
.
errcode
===
501
||
data
.
err_code
===
501
)
{
if
(
data
.
errcode
===
501
||
data
.
err_code
===
501
)
{
layer
.
msg
(
'登录已失效,请重新登录'
,
{
time
:
600
},
function
()
{
layer
.
msg
(
'登录已失效,请重新登录'
,
{
time
:
600
},
function
()
{
window
.
location
.
href
=
passport_url
+
'/login'
;
window
.
location
.
href
=
passport_url
+
'/login'
;
...
@@ -77,7 +79,9 @@
...
@@ -77,7 +79,9 @@
if
(
$
(
'#head_pic'
).
length
>
0
)
{
if
(
$
(
'#head_pic'
).
length
>
0
)
{
//获取用户信息
//获取用户信息
this
.
getData
(
apis
.
userInfo
,
'GET'
,
{
token
:
Util
.
getCookie
(
'token'
)
||
''
},
function
(
res
)
{
this
.
getData
(
apis
.
userInfo
,
'GET'
,
{
token
:
Util
.
getCookie
(
'token'
)
||
''
},
function
(
res
)
{
if
(
res
.
errcode
===
0
)
{
if
(
res
.
errcode
===
0
)
{
...
@@ -100,7 +104,7 @@
...
@@ -100,7 +104,7 @@
$
(
".user_home"
).
find
(
".last_login_time"
).
empty
().
html
(
res
.
data
[
'last_login_time'
]);
$
(
".user_home"
).
find
(
".last_login_time"
).
empty
().
html
(
res
.
data
[
'last_login_time'
]);
$
(
".user_home"
).
find
(
".info_desc"
).
children
(
'p'
).
empty
().
html
(
'Hi,'
+
Util
.
getTimeState
());
$
(
".user_home"
).
find
(
".info_desc"
).
children
(
'p'
).
empty
().
html
(
'Hi,'
+
Util
.
getTimeState
());
}
}
...
@@ -151,7 +155,11 @@
...
@@ -151,7 +155,11 @@
//退出
//退出
$
(
".nav_end"
).
on
(
'click'
,
function
()
{
$
(
".nav_end"
).
on
(
'click'
,
function
()
{
layer
.
confirm
(
'您确定退出系统嘛'
,
{
icon
:
3
,
title
:
'提示'
,
move
:
false
},
function
(
index
)
{
layer
.
confirm
(
'您确定退出系统嘛'
,
{
icon
:
3
,
title
:
'提示'
,
move
:
false
},
function
(
index
)
{
opt
.
getData
(
apis
.
authLogout
,
'POST'
,
null
,
function
(
res
)
{
opt
.
getData
(
apis
.
authLogout
,
'POST'
,
null
,
function
(
res
)
{
...
@@ -328,6 +336,43 @@
...
@@ -328,6 +336,43 @@
}
}
return
text
;
return
text
;
},
/**获取前几天的日期 */
getDay
:
function
(
day
)
{
var
today
=
new
Date
();
var
targetday_milliseconds
=
today
.
getTime
()
+
1000
*
60
*
60
*
24
*
day
;
today
.
setTime
(
targetday_milliseconds
);
//注意,这行是关键代码
var
tYear
=
today
.
getFullYear
();
var
tMonth
=
today
.
getMonth
();
var
tDate
=
today
.
getDate
();
tMonth
=
this
.
doHandleMonth
(
tMonth
+
1
);
tDate
=
this
.
doHandleMonth
(
tDate
);
return
tYear
+
"-"
+
tMonth
+
"-"
+
tDate
+
' 00:00:00'
;
},
/**对月份进行处理 */
doHandleMonth
:
function
(
month
)
{
var
m
=
month
;
if
(
month
.
toString
().
length
==
1
)
{
m
=
"0"
+
month
;
52
}
return
m
;
}
}
};
};
if
(
typeof
define
===
"function"
&&
define
.
amd
)
{
if
(
typeof
define
===
"function"
&&
define
.
amd
)
{
...
...
dist/js/home/index.js
View file @
38b60c08
...
@@ -72,7 +72,14 @@ $(function () {
...
@@ -72,7 +72,14 @@ $(function () {
$
(
this
).
addClass
(
'active'
).
siblings
().
removeClass
(
'active'
)
$
(
this
).
addClass
(
'active'
).
siblings
().
removeClass
(
'active'
)
});
});
$
(
'.input_btn'
).
click
(
function
()
{
$
(
'.input_btn'
).
click
(
function
()
{
var
key
=
$
(
'.search-input'
).
val
();
if
(
key
){
window
.
location
.
href
=
"/search?key="
+
key
;
}
else
{
window
.
location
.
href
=
"/search"
window
.
location
.
href
=
"/search"
}
});
});
$
(
'.home_content'
).
on
(
'click'
,
'.newXjIcon'
,
function
()
{
$
(
'.home_content'
).
on
(
'click'
,
'.newXjIcon'
,
function
()
{
window
.
location
.
href
=
"/roborder"
window
.
location
.
href
=
"/roborder"
...
...
dist/js/index/search.js
View file @
38b60c08
// $(function () {
// var indexSearch = {
// init: function () {
// this.bindFun();
// $('.search_sp').click();
// },
// getData: function (type) {
// var url = type==1?apis.goodsSearch:apis.inquirySearch;
// IcController.getData(url, 'GET', {
// "offset": 8,
// "p": 1,
// }, function (res) {
// var getTpl = "";
// if(type == 1){
// getTpl = sphtml.innerHTML
// }else{
// getTpl = xjhtml.innerHTML
// }
// if (res.errcode == 0) {
// $('.nav_title').find('span').text(res.total);
// var list = [];
// if(type == 1){
// list = res.goods_list
// }else{
// list = res.inquiry_list
// }
// layui.laytpl(getTpl).render(list, function (html) {
// $(".search_data_list").html(html);
// });
// } else if (res.errcode == 105001) {
// $('.nav_title').find('span').text(0)
// layui.laytpl(getTpl).render([], function (html) {
// $(".search_data_list").html(html);
// });
// }
// })
// },
// bindFun:function(){
// var self = this;
// $('.search_nav li').on('click',function(){
// var index = $(this).index();
// $(this).addClass('active').siblings().removeClass('active');
// $(".search_data_list").empty();
// $('.nav_title').find('span').text(0)
// if(index == 0){//商品
// self.getData(1)
// }else{//询价
// self.getData(2)
// }
// })
// }
// };
// indexSearch.init();
// })
$
(
function
()
{
$
(
function
()
{
var
indexSearch
=
{
var
indexSearch
=
{
key
:
Util
.
getRequest
(
'key'
)
||
""
,
init
:
function
()
{
init
:
function
()
{
$
(
'.input-search'
).
val
(
this
.
key
);
this
.
bindFun
();
this
.
bindFun
();
$
(
'.
search_sp
'
).
click
();
$
(
'.
input_btn
'
).
click
();
},
},
getData
:
function
(
type
)
{
getData
:
function
(
type
,
time
)
{
var
url
=
type
==
1
?
apis
.
goodsSearch
:
apis
.
inquirySearch
;
var
self
=
this
;
var
url
=
type
==
1
?
apis
.
goodsSearch
:
apis
.
inquirySearch
;
IcController
.
getData
(
url
,
'GET'
,
{
IcController
.
getData
(
url
,
'GET'
,
{
"offset"
:
8
,
"offset"
:
8
,
"p"
:
1
,
"p"
:
1
,
"goods_name/like"
:
self
.
key
,
"start_time"
:
time
},
function
(
res
)
{
},
function
(
res
)
{
var
getTpl
=
""
;
var
getTpl
=
""
;
if
(
type
==
1
)
{
if
(
type
==
1
)
{
getTpl
=
sphtml
.
innerHTML
getTpl
=
sphtml
.
innerHTML
}
else
{
}
else
{
getTpl
=
xjhtml
.
innerHTML
getTpl
=
xjhtml
.
innerHTML
}
}
if
(
res
.
errcode
==
0
)
{
if
(
res
.
errcode
==
0
)
{
$
(
'.nav_title'
).
find
(
'span'
).
text
(
res
.
total
)
;
$
(
'.nav_title'
).
find
(
'span'
).
text
(
res
.
total
)
var
list
=
[];
var
list
=
[];
if
(
type
==
1
)
{
if
(
type
==
1
)
{
list
=
res
.
goods_list
list
=
res
.
goods_list
}
else
{
}
else
{
list
=
res
.
inquiry_list
list
=
res
.
inquiry_list
}
}
layui
.
laytpl
(
getTpl
).
render
(
list
,
function
(
html
)
{
layui
.
laytpl
(
getTpl
).
render
(
list
,
function
(
html
)
{
$
(
".
search
_data_list"
).
html
(
html
);
$
(
".
goods
_data_list"
).
html
(
html
);
});
});
}
else
if
(
res
.
errcode
==
105001
)
{
}
else
if
(
res
.
errcode
==
type
==
1
?
105013
:
105001
)
{
$
(
'.nav_title'
).
find
(
'span'
).
text
(
0
)
$
(
'.nav_title'
).
find
(
'span'
).
text
(
0
)
layui
.
laytpl
(
getTpl
).
render
([],
function
(
html
)
{
layui
.
laytpl
(
getTpl
).
render
([],
function
(
html
)
{
$
(
".
search
_data_list"
).
html
(
html
);
$
(
".
goods
_data_list"
).
html
(
html
);
});
});
}
}
})
})
},
},
bindFun
:
function
()
{
bindFun
:
function
()
{
var
self
=
this
;
var
self
=
this
;
$
(
'.search_nav li'
).
on
(
'click'
,
function
(){
$
(
'.search_nav li'
).
on
(
'click'
,
function
()
{
$
(
this
).
addClass
(
'active'
).
siblings
().
removeClass
(
'active'
);
$
(
".goods_data_list"
).
empty
();
$
(
'.nav_title'
).
find
(
'span'
).
text
(
0
);
$
(
'.jt'
).
click
();
});
$
(
'.input_btn'
).
on
(
'click'
,
function
()
{
self
.
key
=
$
(
'.input-search'
).
val
();
$
(
'.search_sp'
).
click
();
});
$
(
'.zz'
).
on
(
'click'
,
'.fl'
,
function
()
{
var
index
=
$
(
this
).
index
();
var
index
=
$
(
this
).
index
();
var
spOrXj
=
1
;
var
time
=
new
Date
(
Util
.
getDay
(
0
));
$
(
this
).
addClass
(
'active'
).
siblings
().
removeClass
(
'active'
);
$
(
this
).
addClass
(
'active'
).
siblings
().
removeClass
(
'active'
);
$
(
".search_data_list"
).
empty
();
if
(
$
(
'.search_xj'
).
hasClass
(
'active'
))
{
$
(
'.nav_title'
).
find
(
'span'
).
text
(
0
)
spOrXj
=
2
if
(
index
==
0
){
//商品
}
self
.
getData
(
1
)
if
(
index
==
0
)
{
}
else
{
//询价
self
.
getData
(
spOrXj
,
time
.
getTime
()
/
1000
)
self
.
getData
(
2
)
}
else
if
(
index
==
1
)
{
time
=
new
Date
(
Util
.
getDay
(
-
3
));
self
.
getData
(
spOrXj
,
time
.
getTime
()
/
1000
)
}
else
{
time
=
new
Date
(
Util
.
getDay
(
-
7
));
self
.
getData
(
spOrXj
,
time
.
getTime
()
/
1000
)
}
}
})
})
}
}
...
...
dist/js/quoteprice/inquiry.js
View file @
38b60c08
...
@@ -46,6 +46,7 @@ $(function () {
...
@@ -46,6 +46,7 @@ $(function () {
count
:
res
.
total
,
count
:
res
.
total
,
limit
:
7
,
limit
:
7
,
curr
:
page
,
curr
:
page
,
layout
:[
'prev'
,
'page'
,
'next'
,
'refresh'
],
jump
:
function
(
obj
,
first
)
{
jump
:
function
(
obj
,
first
)
{
if
(
!
first
)
{
if
(
!
first
)
{
//分页回调调用
//分页回调调用
...
@@ -97,7 +98,8 @@ $(function () {
...
@@ -97,7 +98,8 @@ $(function () {
},
},
sxj
:
function
(
id
,
type
)
{
sxj
:
function
(
id
,
type
)
{
//上下架 1上架 2下架
//上下架 1上架 2下架
IcController
.
getData
(
apis
.
inquirysave
,
'GET'
,
{
var
self
=
this
;
IcController
.
getData
(
apis
.
inquirstatusysave
,
'GET'
,
{
"token"
:
Util
.
getCookie
(
'token'
)
||
""
,
"token"
:
Util
.
getCookie
(
'token'
)
||
""
,
"inquiry_items_id"
:
id
,
"inquiry_items_id"
:
id
,
"status"
:
type
"status"
:
type
...
@@ -106,7 +108,8 @@ $(function () {
...
@@ -106,7 +108,8 @@ $(function () {
layer
.
msg
(
'操作成功'
,
{
layer
.
msg
(
'操作成功'
,
{
time
:
600
time
:
600
},
function
()
{
},
function
()
{
console
.
log
(
'操作成功'
)
self
.
getCount
();
$
(
'.layui-icon-refresh'
).
click
();
});
});
}
else
{
}
else
{
layer
.
msg
(
'操作失败'
)
layer
.
msg
(
'操作失败'
)
...
@@ -158,7 +161,7 @@ $(function () {
...
@@ -158,7 +161,7 @@ $(function () {
inquiry
.
getData
(
inquiry
.
params
,
1
);
inquiry
.
getData
(
inquiry
.
params
,
1
);
});
});
//上架
//上架
$
(
'.inquiry_data'
).
on
(
'click'
,
'.
sj
'
,
function
(
e
)
{
$
(
'.inquiry_data'
).
on
(
'click'
,
'.
fb
'
,
function
(
e
)
{
e
.
stopPropagation
();
e
.
stopPropagation
();
var
userId
=
$
(
this
).
parent
(
'.data_item'
).
attr
(
'userid'
);
var
userId
=
$
(
this
).
parent
(
'.data_item'
).
attr
(
'userid'
);
if
(
$
(
this
).
hasClass
(
'disabled'
))
{
if
(
$
(
this
).
hasClass
(
'disabled'
))
{
...
...
dist/js/roborder/index.js
0 → 100644
View file @
38b60c08
$
(
function
()
{
var
roborderObj
=
{
init
:
function
()
{
this
.
getData
(
1
,
1
);
this
.
bindFun
();
},
getData
:
function
(
type
,
p
)
{
var
self
=
this
;
var
params
=
{
"offset"
:
10
,
"p"
:
p
,
};
if
(
type
==
1
)
{
//最新询价
params
[
"add_time/order"
]
=
"desc"
;
}
else
if
(
type
==
2
)
{
//今日询价
params
[
"today"
]
=
"1"
;
}
else
{
//0回复询价
params
[
"offer_num/eq"
]
=
0
;
}
IcController
.
getData
(
apis
.
inquirySearch
,
'GET'
,
params
,
function
(
res
)
{
var
getTpl
=
zqTpl
.
innerHTML
;
if
(
res
.
errcode
===
0
)
{
$
(
'#pagination'
).
show
();
layui
.
laytpl
(
getTpl
).
render
(
res
.
inquiry_list
,
function
(
html
)
{
$
(
".goods_data_list"
).
empty
().
html
(
html
);
layui
.
laypage
.
render
({
elem
:
'pagination'
,
theme
:
'#1080d0'
,
count
:
res
.
total
,
limit
:
10
,
curr
:
p
,
jump
:
function
(
obj
,
first
)
{
if
(
!
first
)
{
//分页回调调用
self
.
getData
(
type
,
obj
.
curr
)
}
}
});
});
}
else
{
layui
.
laytpl
(
getTpl
).
render
([],
function
(
html
)
{
$
(
".goods_data_list"
).
empty
().
html
(
html
);
$
(
'#pagination'
).
hide
();
});
}
})
},
bindFun
:
function
(){
var
self
=
this
;
$
(
'.condition_content'
).
find
(
'.filter_span'
).
on
(
'click'
,
function
(){
var
index
=
$
(
this
).
index
();
$
(
this
).
addClass
(
'active'
).
siblings
().
removeClass
(
'active'
);
$
(
".goods_data_list"
).
empty
();
$
(
'#pagination'
).
hide
();
self
.
getData
(
index
,
1
)
});
$
(
'.roborder_content'
).
on
(
'click'
,
'.my_xj_item'
,
function
(){
var
userid
=
$
(
this
).
attr
(
'userid'
);
window
.
location
.
href
=
"/quotedetail?id="
+
userid
});
//编辑
$
(
'.edit_div'
).
click
(
function
()
{
window
.
location
.
href
=
"/releaseinquiry"
});
}
};
roborderObj
.
init
();
})
\ No newline at end of file
dist/js/search/index.js
View file @
38b60c08
$
(
function
()
{
$
(
function
()
{
var
search
=
{
var
search
=
{
key
:
Util
.
getRequest
(
'key'
)
||
""
,
init
:
function
()
{
init
:
function
()
{
$
(
'.input-search'
).
val
(
this
.
key
);
this
.
bindFun
();
this
.
bindFun
();
$
(
'.
search_sp
'
).
click
();
$
(
'.
input_btn
'
).
click
();
},
},
getData
:
function
(
type
,
p
)
{
getData
:
function
(
type
,
p
,
time
)
{
var
self
=
this
;
var
self
=
this
;
var
url
=
type
==
1
?
apis
.
goodsSearch
:
apis
.
inquirySearch
;
var
url
=
type
==
1
?
apis
.
goodsSearch
:
apis
.
inquirySearch
;
IcController
.
getData
(
url
,
'GET'
,
{
IcController
.
getData
(
url
,
'GET'
,
{
"offset"
:
10
,
"offset"
:
10
,
"p"
:
p
,
"p"
:
p
,
"goods_name/like"
:
self
.
key
,
"start_time"
:
time
},
function
(
res
)
{
},
function
(
res
)
{
var
getTpl
=
""
;
var
getTpl
=
""
;
if
(
type
==
1
)
{
if
(
type
==
1
)
{
getTpl
=
sphtml
.
innerHTML
getTpl
=
sphtml
.
innerHTML
}
else
{
}
else
{
getTpl
=
xjhtml
.
innerHTML
getTpl
=
xjhtml
.
innerHTML
}
}
if
(
res
.
errcode
==
0
)
{
if
(
res
.
errcode
==
0
)
{
$
(
'#pagination'
).
show
();
$
(
'#pagination'
).
show
();
$
(
'.nav_title'
).
find
(
'span'
).
text
(
res
.
total
)
$
(
'.nav_title'
).
find
(
'span'
).
text
(
res
.
total
)
var
list
=
[];
var
list
=
[];
if
(
type
==
1
)
{
if
(
type
==
1
)
{
list
=
res
.
goods_list
list
=
res
.
goods_list
}
else
{
}
else
{
list
=
res
.
inquiry_list
list
=
res
.
inquiry_list
}
}
layui
.
laytpl
(
getTpl
).
render
(
list
,
function
(
html
)
{
layui
.
laytpl
(
getTpl
).
render
(
list
,
function
(
html
)
{
...
@@ -37,12 +41,12 @@ $(function () {
...
@@ -37,12 +41,12 @@ $(function () {
jump
:
function
(
obj
,
first
)
{
jump
:
function
(
obj
,
first
)
{
if
(
!
first
)
{
if
(
!
first
)
{
//分页回调调用
//分页回调调用
self
.
getData
(
type
,
obj
.
curr
)
self
.
getData
(
type
,
obj
.
curr
,
self
.
key
,
time
)
}
}
}
}
});
});
});
});
}
else
if
(
res
.
errcode
==
105001
)
{
}
else
if
(
res
.
errcode
==
type
==
1
?
105013
:
105001
)
{
$
(
'.nav_title'
).
find
(
'span'
).
text
(
0
)
$
(
'.nav_title'
).
find
(
'span'
).
text
(
0
)
layui
.
laytpl
(
getTpl
).
render
([],
function
(
html
)
{
layui
.
laytpl
(
getTpl
).
render
([],
function
(
html
)
{
$
(
".goods_data_list"
).
html
(
html
);
$
(
".goods_data_list"
).
html
(
html
);
...
@@ -55,15 +59,32 @@ $(function () {
...
@@ -55,15 +59,32 @@ $(function () {
bindFun
:
function
()
{
bindFun
:
function
()
{
var
self
=
this
;
var
self
=
this
;
$
(
'.search_nav li'
).
on
(
'click'
,
function
()
{
$
(
'.search_nav li'
).
on
(
'click'
,
function
()
{
var
index
=
$
(
this
).
index
();
$
(
this
).
addClass
(
'active'
).
siblings
().
removeClass
(
'active'
);
$
(
this
).
addClass
(
'active'
).
siblings
().
removeClass
(
'active'
);
$
(
".goods_data_list"
).
empty
();
$
(
".goods_data_list"
).
empty
();
$
(
'.nav_title'
).
find
(
'span'
).
text
(
0
);
$
(
'.nav_title'
).
find
(
'span'
).
text
(
0
);
$
(
'#pagination'
).
hide
();
$
(
'#pagination'
).
hide
();
if
(
index
==
0
)
{
//商品
$
(
'.jt'
).
click
();
self
.
getData
(
1
,
1
)
});
}
else
{
//询价
$
(
'.input_btn'
).
on
(
'click'
,
function
()
{
self
.
getData
(
2
,
1
)
self
.
key
=
$
(
'.input-search'
).
val
();
$
(
'.search_sp'
).
click
();
});
$
(
'.zz'
).
on
(
'click'
,
'.fl'
,
function
()
{
var
index
=
$
(
this
).
index
();
var
spOrXj
=
1
;
var
time
=
new
Date
(
Util
.
getDay
(
0
));
$
(
this
).
addClass
(
'active'
).
siblings
().
removeClass
(
'active'
);
if
(
$
(
'.search_xj'
).
hasClass
(
'active'
))
{
spOrXj
=
2
}
if
(
index
==
0
)
{
self
.
getData
(
spOrXj
,
1
,
time
.
getTime
()
/
1000
)
}
else
if
(
index
==
1
)
{
time
=
new
Date
(
Util
.
getDay
(
-
3
));
self
.
getData
(
spOrXj
,
1
,
time
.
getTime
()
/
1000
)
}
else
{
time
=
new
Date
(
Util
.
getDay
(
-
7
));
self
.
getData
(
spOrXj
,
1
,
time
.
getTime
()
/
1000
)
}
}
})
})
}
}
...
...
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