Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
tl_estate
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
hujun
tl_estate
Commits
232c894e
Commit
232c894e
authored
Mar 15, 2019
by
agping
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
账户明细
parent
8517d09b
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
159 additions
and
6 deletions
+159
-6
cashAccountList.html
application/index/view/redEnvelope/cashAccountList.html
+63
-2
cashAccountList.js
public/resource/js/cashAccountList.js
+93
-0
cash_account_list_template_tpl.html
public/resource/template/cash_account_list_template_tpl.html
+3
-4
No files found.
application/index/view/redEnvelope/cashAccountList.html
View file @
232c894e
{layout name="global/frame_two_tpl" /}
{layout name="global/frame_two_tpl" /}
<input
type=
"hidden"
class=
"page-load"
id=
"cashAccountList"
/>
<input
type=
"hidden"
class=
"page-load"
id=
"cashAccountList"
/>
<style>
<style>
#file_input_pic
{
opacity
:
0
;
position
:
absolute
;
top
:
19px
;
left
:
165px
;
height
:
43px
;
width
:
76px
;
}
#container_body_img_area
>
div
{
float
:
left
;
width
:
216px
;
}
.result
{
width
:
130px
;
height
:
auto
;
float
:
left
;
text-align
:
center
;
color
:
red
;
}
.result
>
img
,
.result2
>
img
{
width
:
120px
;
height
:
120px
;
margin-top
:
8px
;
}
</style>
</style>
<div
id=
"page-content-wrapper"
>
<div
id=
"page-content-wrapper"
>
<div
class=
"container"
>
<div
class=
"container"
>
...
@@ -70,4 +93,42 @@
...
@@ -70,4 +93,42 @@
</div>
</div>
</div>
</div>
</div>
</div>
<!--审核 上传图片-->
<div
class=
"modal fade"
id=
"modal-addPic"
tabindex=
"-1"
role=
"dialog"
aria-labelledby=
"myModalLabel"
aria-hidden=
"true"
>
<div
class=
"modal-dialog"
>
<div
class=
"modal-content"
>
<div
class=
"modal-header"
>
<button
type=
"button"
class=
"close"
data-dismiss=
"modal"
aria-hidden=
"true"
>
×
</button>
<h4
class=
"modal-title"
>
审核通过
</h4>
</div>
<div
class=
"modal-body"
style=
"height: 600px;"
>
<div>
<div
style=
"height: 600px;"
>
<div
class=
"form-group full-width-100 full-pic-area"
>
<!--input上传图片-->
<div
id=
"container_body"
>
<label>
请选择一个图像文件:
</label>
<button
type=
"button btn2"
class=
"btn btn-default"
>
上传图片
</button>
<input
type=
"file"
id=
"file_input_pic"
/>
<div
id=
"container_body_img_area"
></div>
</div>
</div>
<ul
class=
"img-pre-ul"
id=
"xiangqing_pic_ul"
>
</ul>
</div>
</div>
</div>
<div
class=
"modal-footer"
>
<button
type=
"button btn2"
class=
"btn btn-primary"
id=
"saveBtn"
data-dismiss=
"modal"
>
保存
</button>
</div>
</div>
<!-- /.modal-content -->
</div>
<!-- /.modal -->
</div>
public/resource/js/cashAccountList.js
View file @
232c894e
...
@@ -2,6 +2,7 @@ define (['doT', 'text!temp/cash_account_list_template_tpl.html', 'css!style/home
...
@@ -2,6 +2,7 @@ define (['doT', 'text!temp/cash_account_list_template_tpl.html', 'css!style/home
redEnvelope
=
{
redEnvelope
=
{
pageNo
:
1
,
/*第几页*/
pageNo
:
1
,
/*第几页*/
pageSize
:
10
,
/*每页显示多少条*/
pageSize
:
10
,
/*每页显示多少条*/
id
:
0
,
init
:
function
()
{
init
:
function
()
{
//初始化dot
//初始化dot
$
(
"body"
).
append
(
template
);
$
(
"body"
).
append
(
template
);
...
@@ -17,6 +18,13 @@ define (['doT', 'text!temp/cash_account_list_template_tpl.html', 'css!style/home
...
@@ -17,6 +18,13 @@ define (['doT', 'text!temp/cash_account_list_template_tpl.html', 'css!style/home
e
.
stopPropagation
();
e
.
stopPropagation
();
$
(
this
).
parent
().
parent
().
remove
();
$
(
this
).
parent
().
parent
().
remove
();
});
$
(
document
).
on
(
'click'
,
'.audit-pic'
,
function
(
e
)
{
var
_this
=
$
(
this
);
e
.
preventDefault
();
e
.
stopPropagation
();
redEnvelope
.
id
=
_this
.
attr
(
"data-id"
);
});
});
$
(
"#search"
).
click
(
function
()
{
//搜索
$
(
"#search"
).
click
(
function
()
{
//搜索
redEnvelope
.
getList
(
1
);
redEnvelope
.
getList
(
1
);
...
@@ -24,6 +32,91 @@ define (['doT', 'text!temp/cash_account_list_template_tpl.html', 'css!style/home
...
@@ -24,6 +32,91 @@ define (['doT', 'text!temp/cash_account_list_template_tpl.html', 'css!style/home
$
(
"#reset"
).
click
(
function
()
{
//重置
$
(
"#reset"
).
click
(
function
()
{
//重置
document
.
getElementById
(
"form_search"
).
reset
();
document
.
getElementById
(
"form_search"
).
reset
();
});
});
$
(
'#file_input_pic'
).
on
(
'change'
,
function
(){
var
_this
=
$
(
this
);
var
formData
=
new
FormData
();
formData
.
append
(
'type'
,
'chat'
);
formData
.
append
(
'image'
,
_this
[
0
].
files
[
0
]);
$
.
ajax
({
type
:
'post'
,
url
:
ServerHostImageLiu
+
'/index/uploadImg'
,
data
:
formData
,
dataType
:
'json'
,
contentType
:
false
,
cache
:
false
,
processData
:
false
,
beforeSend
:
function
()
{},
success
:
function
(
_data
)
{
if
(
_data
.
code
==
200
)
{
$
(
'#container_body_img_area'
).
append
(
'<div class="result"><img data-imgname="{0}" src="{1}" alt=""/> <span class="span-del">删除</span></div>'
.
stringFormatObj
({
'0'
:
_data
.
data
.
img_path
,
'1'
:
_data
.
data
.
internet_img_name
?
urlDeal
(
_data
.
data
.
internet_img_name
):
_data
.
data
.
internet_img_name
}));
}
else
{
alert
(
_data
.
msg
);
};
},
error
:
function
()
{
alert
(
'enter error'
);
},
complete
:
function
(
xhr
,
textStatus
)
{
if
(
textStatus
===
'timeout'
)
{
//处理超时的逻辑
alert
(
'请求超时,请重试'
);
};
}
});
});
//图片删除事件
$
(
document
).
on
(
'click'
,
'.span-del'
,
function
(
e
)
{
e
.
preventDefault
();
e
.
stopPropagation
();
$
(
this
).
parent
().
remove
();
});
//保存上传的图片
$
(
document
).
on
(
'click'
,
'#saveBtn'
,
function
(
e
)
{
var
_this
=
$
(
this
);
e
.
preventDefault
();
e
.
stopPropagation
();
var
imgname
=
[];
for
(
var
i
=
0
;
i
<
$
(
'.result'
).
length
;
i
++
)
{
imgname
[
i
]
=
$
(
'.result>img'
).
eq
(
i
).
attr
(
'data-imgname'
);
};
var
_data
=
{};
//无新的图片上传 不调用接口
if
(
imgname
.
join
(
','
))
{
_data
[
'transfer_img'
]
=
imgname
.
join
(
','
);
}
else
{
return
};
var
authtoken
=
JSON
.
parse
(
decodeURIComponent
(
localStorage
.
getItem
(
'pcUserInfo'
)));
_data
[
'id'
]
=
redEnvelope
.
id
;
_data
[
'operator_id'
]
=
authtoken
.
id
;
_data
[
'operator_name'
]
=
authtoken
.
name
;
_data
[
'status'
]
=
1
;
$
.
ajax
({
type
:
'GET'
,
url
:
'/index/check'
,
data
:
_data
,
dataType
:
'json'
,
beforeSend
:
function
()
{},
success
:
function
(
_data
)
{
alert
(
_data
.
msg
);
},
error
:
function
()
{
alert
(
'enter error'
);
},
complete
:
function
(
xhr
,
textStatus
)
{
if
(
textStatus
===
'timeout'
)
{
//处理超时的逻辑
alert
(
'请求超时,请重试'
);
};
}
});
});
},
},
...
...
public/resource/template/cash_account_list_template_tpl.html
View file @
232c894e
...
@@ -23,11 +23,10 @@
...
@@ -23,11 +23,10 @@
<
td
>
[
%=
it
[
item
][
'user_phone'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'user_phone'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'operator_name'
]
%
]
<
/td
>
<
td
>
[
%=
it
[
item
][
'operator_name'
]
%
]
<
/td
>
<
td
>
<
td
>
[
%
if
(
it
[
item
][
'status'
]
==
0
&&
it
[
item
][
'is_essay'
]
==
2
){
%
]
[
%
if
(
it
[
item
][
'status'
]
==
0
&&
it
[
item
][
'is_essay'
]
==
2
){
%
]
<
a
class
=
"btn1 btn-success is_show"
data
-
toggle
=
"modal"
data
-
id
=
'[%= it[item]["id"] %]'
data
-
target
=
"#modal-show"
>
审核通过
<
/a
>
<
a
class
=
"btn1 btn-success audit-pic"
href
=
"#modal-addPic"
data
-
toggle
=
"modal"
data
-
id
=
'[%= it[item]["id"] %]'
>
审核通过
<
/a
>
[
%
}
%
]
[
%
}
%
]
<
/td
>
<
/td
>
<
/tr
>
<
/tr
>
[
%
}
%
]
[
%
}
%
]
...
...
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