Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
projecttwo
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
wangtao
projecttwo
Commits
4a493263
Commit
4a493263
authored
Jul 08, 2025
by
wangtao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
学习资料
parent
309bca7e
Changes
21
Hide whitespace changes
Inline
Side-by-side
Showing
21 changed files
with
351 additions
and
48 deletions
+351
-48
CertOrder.php
app/admin/controller/cert/CertOrder.php
+78
-6
edit.html
app/admin/view/advert/edit.html
+1
-0
index.html
app/admin/view/caiwu/withdrawal/index.html
+3
-3
edit.html
app/admin/view/cert/cert/edit.html
+14
-4
certaddress.html
app/admin/view/cert/cert_order/certaddress.html
+59
-0
index.html
app/admin/view/cert/cert_order/index.html
+70
-8
index.html
app/admin/view/course/course/index.html
+1
-0
index.html
app/admin/view/order/payment/index.html
+1
-1
index.html
app/admin/view/project/project/index.html
+1
-0
index.html
app/admin/view/users/business/index.html
+4
-3
add.html
app/admin/view/users/mail/add.html
+1
-1
index.html
app/admin/view/users/school/index.html
+3
-2
index.html
app/admin/view/users/smrz/index.html
+1
-0
index.html
app/admin/view/users/user/index.html
+8
-5
Cert.php
app/api/controller/mine/Cert.php
+2
-0
User.php
app/api/controller/mine/User.php
+42
-3
AddExperience.php
app/api/middleware/AddExperience.php
+12
-9
UserValidate.php
app/api/validate/UserValidate.php
+2
-1
CertOrder.php
app/model/CertOrder.php
+7
-1
CertOrderAddress.php
app/model/CertOrderAddress.php
+40
-0
User.php
app/model/project/User.php
+1
-1
No files found.
app/admin/controller/cert/CertOrder.php
View file @
4a493263
...
...
@@ -11,9 +11,12 @@
namespace
app\admin\controller\cert
;
use
app\admin\controller\AdminBase
;
use
app\event\PhpOffice
;
use
app\model\CertOrder
as
CertOrderModel
;
use
app\model\CertOrderAddress
;
use
app\model\project\Mail
;
use
think\App
;
/**
* 后台主控制器
*/
...
...
@@ -49,10 +52,13 @@ class CertOrder extends AdminBase
if
(
isset
(
$post
[
'cert_title'
])
&&
!
empty
(
$post
[
'cert_title'
]))
{
$certmap
[]
=
[
'cert.title'
,
'like'
,
'%'
.
trim
(
$post
[
'cert_title'
])
.
'%'
];
}
if
(
isset
(
$post
[
'ff_type'
])
&&
!
empty
(
$post
[
'ff_type'
]))
{
$certmap
[]
=
[
'cert.ff_type'
,
'='
,
$post
[
'ff_type'
]
-
1
];
}
if
(
isset
(
$post
[
'status'
])
&&
!
empty
(
$post
[
'status'
]))
{
$map
[]
=
[
'status'
,
'='
,
$post
[
'status'
]];
}
$list
=
$this
->
certorder
->
hasWhere
(
'userprofile'
,
$hasmap
)
->
hasWhere
(
'certdata'
,
$certmap
)
->
where
(
$map
)
->
with
([
'certdata'
,
'userprofile'
,
'certfiledata'
])
->
append
([
'status_text'
])
->
order
(
'createtime desc'
)
->
paginate
(
$post
[
'limit'
]);
$list
=
$this
->
certorder
->
hasWhere
(
'userprofile'
,
$hasmap
)
->
hasWhere
(
'certdata'
,
$certmap
)
->
where
(
$map
)
->
with
([
'certdata'
,
'userprofile'
,
'certfiledata'
])
->
append
([
'status_text'
])
->
order
(
'createtime desc'
)
->
paginate
(
$post
[
'limit'
]);
return
$this
->
returnMsg
(
$list
);
}
...
...
@@ -66,9 +72,9 @@ class CertOrder extends AdminBase
$post
=
input
();
$result
=
$this
->
certorder
->
update
([
$post
[
'af'
]
=>
$post
[
'av'
]],
[[
'id'
,
'='
,
$post
[
'id'
]]]);
if
(
$result
)
{
return
$this
->
returnMsg
(
'修改成功'
,
1
);
}
else
{
if
(
$result
)
{
return
$this
->
returnMsg
(
'修改成功'
,
1
);
}
else
{
return
$this
->
returnMsg
(
'修改成功'
);
}
}
...
...
@@ -95,6 +101,10 @@ class CertOrder extends AdminBase
if
(
empty
(
$post
[
'errordesc'
]))
{
return
$this
->
returnMsg
(
"请输入失败原因"
);
}
$len
=
mb_strlen
(
$post
[
'errordesc'
],
'UTF-8'
);
if
(
$len
>
200
){
return
$this
->
returnMsg
(
"失败原因长度不能超过200字"
);
}
$errordesc
=
$post
[
'errordesc'
];
$shstatus
=
2
;
}
...
...
@@ -108,7 +118,7 @@ class CertOrder extends AdminBase
if
(
$post
[
'shstatus'
]
==
1
)
{
Mail
::
createmail
(
$cert_order_info
[
'user_id'
],
"您报名的证书【"
.
$cert_order_info
[
'certdata'
][
'title'
]
.
"】已审核通过"
);
}
else
{
Mail
::
createmail
(
$cert_order_info
[
'user_id'
],
"您报名的证书【"
.
$cert_order_info
[
'certdata'
][
'title'
]
.
"】审核不通过 - "
.
$errordesc
);
Mail
::
createmail
(
$cert_order_info
[
'user_id'
],
"您报名的证书【"
.
$cert_order_info
[
'certdata'
][
'title'
]
.
"】审核不通过 - "
.
$errordesc
);
}
return
$this
->
returnMsg
(
"操作成功"
,
1
);
}
else
{
...
...
@@ -122,9 +132,71 @@ class CertOrder extends AdminBase
public
function
detail
()
{
$post
=
input
();
$info
=
$this
->
certorder
->
with
([
'certdata'
,
'userprofile'
])
->
append
([
'status_text'
])
->
where
(
'id'
,
$post
[
'id'
])
->
find
();
$info
=
$this
->
certorder
->
with
([
'certdata'
,
'userprofile'
])
->
append
([
'status_text'
])
->
where
(
'id'
,
$post
[
'id'
])
->
find
();
$this
->
assign
(
'info'
,
$info
);
return
$this
->
fetch
(
''
,
''
,
false
);
}
public
function
certaddress
()
{
$post
=
input
();
$info
=
CertOrderAddress
::
where
(
'cert_order_id'
,
$post
[
'cert_order_id'
])
->
find
();
$this
->
assign
(
'info'
,
$info
);
return
$this
->
fetch
(
''
,
''
,
false
);
}
//导出excel
public
function
excelcertorder
()
{
$post
=
input
();
$map
[]
=
[
'cert_order.is_del'
,
'='
,
0
];
$map
[]
=
[
'cert_order.status'
,
'>'
,
0
];
$hasmap
=
[];
if
(
isset
(
$post
[
'kw'
])
&&
!
empty
(
$post
[
'kw'
]))
{
$hasmap
[]
=
[
'user.username|user.mobile'
,
'like'
,
'%'
.
$post
[
'kw'
]
.
'%'
];
}
$certmap
=
[];
if
(
isset
(
$post
[
'cert_title'
])
&&
!
empty
(
$post
[
'cert_title'
]))
{
$certmap
[]
=
[
'cert.title'
,
'like'
,
'%'
.
trim
(
$post
[
'cert_title'
])
.
'%'
];
}
if
(
isset
(
$post
[
'ff_type'
])
&&
!
empty
(
$post
[
'ff_type'
]))
{
$certmap
[]
=
[
'cert.ff_type'
,
'='
,
$post
[
'ff_type'
]
-
1
];
}
if
(
isset
(
$post
[
'status'
])
&&
!
empty
(
$post
[
'status'
]))
{
$map
[]
=
[
'status'
,
'='
,
$post
[
'status'
]];
}
try
{
$list
=
$this
->
certorder
->
hasWhere
(
'userprofile'
,
$hasmap
)
->
hasWhere
(
'certdata'
,
$certmap
)
->
where
(
$map
)
->
with
([
'certdata'
,
'userprofile'
,
'certorderaddress'
])
->
append
([
'status_text'
])
->
order
(
'createtime desc'
)
->
select
()
->
toArray
();
if
(
empty
(
$list
))
{
throw
new
\Exception
(
'没有数据'
);
}
$exceldata
[]
=
[
'用户名'
,
'用户手机'
,
'证书名称'
,
'发放方式'
,
'状态'
,
'报名姓名'
,
'报名身份证号码'
,
'报名手机号'
,
'报名邮箱'
,
'时间'
,
'收货人'
,
'收货人联系方式'
,
'详细地址'
];
foreach
(
$list
as
$v
)
{
$exceldata
[]
=
[
$v
[
'userprofile'
][
'username'
],
$v
[
'userprofile'
][
'mobile'
],
$v
[
'certdata'
][
'title'
],
(
$v
[
'certdata'
][
'ff_type'
]
==
1
?
'邮寄'
:
'线上'
),
$v
[
'status_text'
],
$v
[
'name'
],
$v
[
'idcard'
],
$v
[
'mobile'
],
$v
[
'email'
],
$v
[
'createtime'
],
(
isset
(
$v
[
'certorderaddress'
][
'nickname'
])
?
$v
[
'certorderaddress'
][
'nickname'
]
:
''
),
(
isset
(
$v
[
'certorderaddress'
][
'mobile'
])
?
$v
[
'certorderaddress'
][
'mobile'
]
:
''
),
(
isset
(
$v
[
'certorderaddress'
][
'detail_address'
])
?
$v
[
'certorderaddress'
][
'detail_address'
]
:
''
)
];
}
$excelid
=
PhpOffice
::
exportexcel
(
$exceldata
,
'证书报名导出'
);
$data
[
'url'
]
=
'/admin/cert.cert_order/downloadfile?excel=1&fileid='
.
$excelid
;
return
$this
->
returnMsg
(
'success'
,
1
,
$data
);
}
catch
(
\Exception
$e
)
{
return
$this
->
returnMsg
(
$e
->
getMessage
());
}
}
}
\ No newline at end of file
app/admin/view/advert/edit.html
View file @
4a493263
...
...
@@ -28,6 +28,7 @@
<input
type=
"radio"
name=
"type"
value=
"2"
title=
"内链"
checked
{
eq
name=
"$data.p_id|default=''"
value=
"2"
}
checked
{/
eq
}
>
<input
type=
"radio"
name=
"type"
value=
"1"
title=
"外链"
{
eq
name=
"$data.type|default=''"
value=
"1"
}
checked
{/
eq
}
>
</div>
</div>
<div
class=
"layui-form-item"
>
...
...
app/admin/view/caiwu/withdrawal/index.html
View file @
4a493263
...
...
@@ -117,13 +117,13 @@
{
type
:
'checkbox'
,
fixed
:
'left'
},
{
field
:
'id'
,
width
:
50
,
unresize
:
true
,
align
:
'center'
,
title
:
'ID'
,
sort
:
!
0
},
{
field
:
'sn'
,
width
:
180
,
align
:
'center'
,
title
:
'提现单号'
},
{
field
:
'username'
,
align
:
'center'
,
width
:
1
2
0
,
title
:
'用户名'
,
templet
:
'<div>{{= d.getuserdata.username}}</div>'
},
{
field
:
'username'
,
align
:
'center'
,
width
:
1
5
0
,
title
:
'用户名'
,
templet
:
'<div>{{= d.getuserdata.username}}</div>'
},
{
field
:
'mobile'
,
align
:
'center'
,
width
:
120
,
title
:
'用户手机'
,
templet
:
'<div>{{= d.getuserdata.mobile}}</div>'
},
{
field
:
'realname'
,
align
:
'center'
,
width
:
1
0
0
,
title
:
'真实姓名'
,
templet
:
'<div>{{= d.getuserdata.smrzinfo.realname}}</div>'
},
{
field
:
'realname'
,
align
:
'center'
,
width
:
1
5
0
,
title
:
'真实姓名'
,
templet
:
'<div>{{= d.getuserdata.smrzinfo.realname}}</div>'
},
{
field
:
'tx_money'
,
align
:
'center'
,
width
:
100
,
title
:
'提现金额'
},
{
field
:
'tx_commission'
,
align
:
'center'
,
width
:
100
,
title
:
'提现手续费'
},
{
field
:
'tx_sj_money'
,
align
:
'center'
,
width
:
100
,
title
:
'实际到账金额'
},
{
field
:
'account'
,
align
:
'center'
,
title
:
'提现账号'
},
{
field
:
'account'
,
align
:
'center'
,
minWidth
:
150
,
title
:
'提现账号'
},
{
field
:
'sh_status'
,
width
:
100
,
align
:
'center'
,
title
:
'审核状态'
,
templet
:
'#withdrawalstatus-demo'
},
{
field
:
'status'
,
width
:
100
,
align
:
'center'
,
title
:
'打款状态'
,
templet
:
'#withdrawaldk-demo'
},
{
field
:
'createtime'
,
width
:
120
,
align
:
'center'
,
title
:
'发布时间'
},
...
...
app/admin/view/cert/cert/edit.html
View file @
4a493263
...
...
@@ -26,7 +26,8 @@
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label"
>
证书标题
</label>
<div
class=
"layui-input-block"
>
<input
type=
"text"
name=
"title"
placeholder=
"证书标题"
autocomplete=
"off"
class=
"layui-input"
value=
"{$data.title|default=''}"
>
<input
type=
"text"
name=
"title"
placeholder=
"证书标题"
autocomplete=
"off"
maxlength=
"200"
class=
"layui-input"
value=
"{$data.title|default=''}"
>
</div>
</div>
...
...
@@ -34,7 +35,7 @@
<label
class=
"layui-form-label"
>
证书简介
</label>
<div
class=
"layui-input-block"
>
<textarea
placeholder=
"请输入证书简介"
name=
"description"
class=
"layui-textarea"
>
{$data.description|default=''}
</textarea>
<textarea
placeholder=
"请输入证书简介"
name=
"description"
class=
"layui-textarea"
maxlength=
"250"
>
{$data.description|default=''}
</textarea>
</div>
</div>
...
...
@@ -45,6 +46,15 @@
</div>
</div>
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label"
>
发放方式
</label>
<div
class=
"layui-input-block"
>
<input
type=
"radio"
name=
"ff_type"
value=
"0"
title=
"线上"
checked
{
eq
name=
"$data.ff_type|default=''"
value=
"0"
}
checked
{/
eq
}
>
<input
type=
"radio"
name=
"ff_type"
value=
"1"
title=
"邮寄"
{
eq
name=
"$data.ff_type|default=''"
value=
"1"
}
checked
{/
eq
}
>
</div>
<div
class=
"layui-form-mid"
style=
"color: #f51212;"
><i
class=
"layui-icon"
>
</i>
证书发放方式:线上需要管理员后台上传证书,邮寄需要用户填写收获地址
</div>
</div>
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label"
>
价格
</label>
<div
class=
"layui-input-block"
>
...
...
@@ -86,7 +96,7 @@
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label"
>
适合人群
</label>
<div
class=
"layui-input-block"
>
<input
type=
"text"
name=
"shrq"
placeholder=
"请输入适合人群"
autocomplete=
"off"
class=
"layui-input"
<input
type=
"text"
name=
"shrq"
placeholder=
"请输入适合人群"
autocomplete=
"off"
maxlength=
"220"
class=
"layui-input"
value=
"{$data.shrq|default=''}"
>
</div>
</div>
...
...
@@ -94,7 +104,7 @@
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label"
>
发证机构
</label>
<div
class=
"layui-input-block"
>
<input
type=
"text"
name=
"fzjg"
placeholder=
"请输入发证机构"
autocomplete=
"off"
class=
"layui-input"
<input
type=
"text"
name=
"fzjg"
placeholder=
"请输入发证机构"
autocomplete=
"off"
maxlength=
"220"
class=
"layui-input"
value=
"{$data.fzjg|default=''}"
>
</div>
</div>
...
...
app/admin/view/cert/cert_order/certaddress.html
0 → 100644
View file @
4a493263
{extend name="base/header" /}
{block name="body"}
<style>
.layui-table
.widthtd
{
width
:
120px
;}
</style>
<div
style=
"margin: 0px 10px;"
>
{if $info}
<table
class=
"layui-table"
>
<tbody>
<tr>
<td
class=
"widthtd"
><strong>
收货人
</strong></td>
<td>
{$info.nickname}
</td>
<td
class=
"widthtd"
><strong>
联系方式
</strong></td>
<td>
{$info.mobile}
</td>
</tr>
<tr>
<td
class=
"widthtd"
><strong>
详细地址
</strong></td>
<td
colspan=
"3"
>
{$info.detail_address}
</td>
</tr>
</tbody>
</table>
{else /}
<table
class=
"layui-table"
>
<tbody>
<tr>
<td
class=
"widthtd"
><strong>
未填写邮寄地址
</strong></td>
</tr>
</tbody>
</table>
{/if}
</div>
{/block}
{block name="script"}
<script
type=
"text/javascript"
>
layui
.
use
([
'buildItems'
,
'form'
,
'laydate'
,
'util'
],
function
()
{
var
form
=
layui
.
form
;
/*解析顶部分组选项*/
});
$
(
".imgclick"
).
click
(
function
(){
var
src
=
$
(
this
).
attr
(
'src'
),
alt
=
$
(
this
).
attr
(
'alt'
);
layer
.
photos
({
photos
:{
data
:[{
alt
:
alt
,
src
:
src
}],
start
:
'0'
},
anim
:
5
,
shade
:[
0.4
,
'#000'
]});
});
var
callbackdata
=
function
()
{
var
data
=
$
(
".layui-form"
).
serialize
();
return
data
;
};
</script>
{/block}
\ No newline at end of file
app/admin/view/cert/cert_order/index.html
View file @
4a493263
...
...
@@ -20,10 +20,18 @@
<option
value=
"3"
>
申请成功
</option>
</select>
</div>
<div
class=
"layui-inline"
style=
"width:150px;"
>
<select
name=
"ff_type"
>
<option
value=
""
>
证书发放方式
</option>
<option
value=
"1"
>
线上
</option>
<option
value=
"2"
>
邮寄
</option>
</select>
</div>
<div
class=
"layui-inline"
>
<div
class=
"layui-btn-group"
>
<button
class=
"layui-btn"
lay-submit
lay-filter=
"search-certorder"
><i
class=
"layui-icon layui-icon-search"
></i>
搜索
</button>
<a
class=
"layui-btn"
lay-submit
lay-filter=
"search-certorder-all"
onclick=
"$('#certorder-groupid').val('')"
><i
class=
"layui-icon layui-icon-light"
></i>
全部
</a>
<button
class=
"layui-btn"
lay-submit
lay-filter=
"excel-certorder"
><i
class=
"layui-icon layui-icon-download-circle"
></i>
导出
</button>
</div>
</div>
</div>
...
...
@@ -44,10 +52,16 @@
<
a
class
=
"layui-btn layui-btn-xs"
lay
-
event
=
"detail"
>
详情
<
/a
>
<
a
class
=
"layui-btn layui-btn-xs"
lay
-
event
=
"shenhei"
>
审核
<
/a
>
{{
#
if
(
d
.
certfiledata
)
{
}}
<
a
class
=
"layui-btn layui-btn-xs"
lay
-
event
=
"uploadcert"
>
查看证书
<
/a
>
{{
#
if
(
d
.
certdata
.
ff_type
==
1
)
{
}}
<
a
class
=
"layui-btn layui-btn-xs"
lay
-
event
=
"certaddress"
>
邮寄地址
<
/a
>
{{
#
}
else
{
}}
<
a
class
=
"layui-btn layui-btn-xs"
lay
-
event
=
"uploadcert"
>
上传证书
<
/a
>
{{
#
if
(
d
.
certfiledata
)
{
}}
<
a
class
=
"layui-btn layui-btn-xs"
lay
-
event
=
"uploadcert"
>
查看证书
<
/a
>
{{
#
}
else
{
}}
<
a
class
=
"layui-btn layui-btn-xs"
lay
-
event
=
"uploadcert"
>
上传证书
<
/a
>
{{
#
}
}}
{{
#
}
}}
<!--
<
a
class
=
"layui-btn layui-btn-xs"
lay
-
event
=
"more"
>-->
<!--
更多
-->
...
...
@@ -67,6 +81,7 @@
<
a
class
=
"layui-btn layui-btn-xs"
>
{{
=
d
.
status_text
}}
<
/a
>
{{
#
}
}}
{{
#
}
}}
</script>
<!--JS部分-->
<script>
...
...
@@ -91,12 +106,14 @@
{
field
:
'id'
,
width
:
50
,
unresize
:
true
,
align
:
'center'
,
title
:
'ID'
,
sort
:
!
0
},
{
field
:
'certordername'
,
align
:
'center'
,
width
:
160
,
title
:
'用户名'
,
templet
:
'<div>{{d.userprofile.username}}</div>'
},
{
field
:
'mobile'
,
align
:
'center'
,
width
:
120
,
title
:
'用户手机号'
,
templet
:
'<div>{{d.userprofile.mobile}}</div>'
},
{
field
:
'name'
,
align
:
'center'
,
title
:
'证书名称'
,
templet
:
'<div>{{d.certdata.title}}</div>'
},
{
field
:
'name'
,
align
:
'center'
,
minWidth
:
200
,
title
:
'证书名称'
,
templet
:
'<div>{{d.certdata.title}}</div>'
},
// {field:'ff_type',align:'center',minWidth:200,title:'发放方式',templet:'
<
div
>
{{
=
d
.
certdata
.
ff_type
?
==
1
"邮寄"
:
"线上"
}}
<
/div>'}
,
{
field
:
'ff_type'
,
align
:
'center'
,
minWidth
:
100
,
title
:
'发放方式'
,
templet
:
function
(
d
){
return
'<div>'
+
(
d
.
certdata
.
ff_type
==
1
?
'邮寄'
:
'线上'
)
+
'</div>'
}},
{
field
:
"status_text"
,
width
:
100
,
align
:
'center'
,
title
:
"状态"
,
templet
:
'#certorderstatus-demo'
},
{
field
:
'name'
,
align
:
'center'
,
title
:
'报名姓名'
},
{
field
:
'idcard'
,
align
:
'center'
,
title
:
'报名身份证号码'
},
{
field
:
'mobile'
,
align
:
'center'
,
title
:
'报名手机号'
},
{
field
:
'email'
,
align
:
'center'
,
title
:
'报名邮箱'
},
{
field
:
'name'
,
align
:
'center'
,
width
:
120
,
title
:
'报名姓名'
},
{
field
:
'idcard'
,
align
:
'center'
,
width
:
200
,
title
:
'报名身份证号码'
},
{
field
:
'mobile'
,
align
:
'center'
,
width
:
120
,
title
:
'报名手机号'
},
{
field
:
'email'
,
align
:
'center'
,
width
:
160
,
title
:
'报名邮箱'
},
{
field
:
'createtime'
,
width
:
150
,
align
:
'center'
,
title
:
'创建时间'
},
{
fixed
:
'right'
,
width
:
150
,
align
:
'center'
,
templet
:
'#certorderdemo'
,
title
:
'操作'
}
]],
...
...
@@ -132,6 +149,8 @@
del
(
id
);
}
else
if
(
obj
.
event
===
'uploadcert'
){
uploadcert
(
id
);
}
else
if
(
obj
.
event
===
'certaddress'
){
certaddress
(
id
);
}
else
if
(
obj
.
event
===
'certorder-event-image'
){
var
src
=
$
(
this
).
attr
(
'src'
),
alt
=
$
(
this
).
attr
(
'alt'
);
layer
.
photos
({
photos
:{
data
:[{
alt
:
alt
,
src
:
src
}],
start
:
'0'
},
anim
:
5
,
shade
:[
0.4
,
'#000'
]});
...
...
@@ -148,6 +167,7 @@
btn2
:
function
(
index
,
layero
,
that
){
layer
.
prompt
({
formType
:
2
,
maxlength
:
200
,
value
:
''
,
title
:
'请输入失败原因'
,
},
function
(
value
,
index
,
elem
){
...
...
@@ -225,6 +245,20 @@
},
});
}
/**/
function
certaddress
(
id
=
''
,
type
=
''
){
var
title
=
"邮寄地址"
;
layer
.
open
({
type
:
2
,
area
:
[
'900px'
,
'90%'
],
title
:
title
,
btn
:
[
'确定'
,
'关闭'
],
content
:
'/admin/cert.cert_order/certaddress?cert_order_id='
+
id
,
yes
:
function
(
index
,
layero
){
layer
.
close
(
index
);
},
});
}
/**/
function
shajax
(
id
,
shstatus
,
errordesc
=
''
){
$
.
ajax
({
...
...
@@ -249,5 +283,33 @@
});
}
form
.
on
(
'submit(excel-certorder)'
,
function
(
data
){
var
checkStatus
=
table
.
checkStatus
(
'certorder'
);
var
checkRows
=
checkStatus
.
data
;
var
ids
=
checkRows
.
map
(
function
(
d
){
return
d
.
id
;});
var
field
=
data
.
field
;
// 获得表单字段
field
.
ids
=
ids
;
layer
.
load
();
$
.
ajax
({
method
:
"post"
,
url
:
app_root
+
'/excelcertorder'
,
data
:
field
,
dataType
:
"json"
,
success
:
function
(
res
){
layer
.
closeAll
();
if
(
res
.
code
===
1
)
{
window
.
location
.
href
=
res
.
data
.
url
;
}
else
{
layer
.
msg
(
res
.
msg
,{
icon
:
2
,
shade
:[
0.4
,
'#000'
],
time
:
1500
},
function
(){
});
}
}
});
return
false
;
// 阻止默认 form 跳转
});
});
</script>
\ No newline at end of file
app/admin/view/course/course/index.html
View file @
4a493263
...
...
@@ -234,6 +234,7 @@
btn2
:
function
(
index
,
layero
,
that
){
layer
.
prompt
({
formType
:
2
,
maxlength
:
200
,
value
:
''
,
title
:
'请输入失败原因'
,
},
function
(
value
,
index
,
elem
){
...
...
app/admin/view/order/payment/index.html
View file @
4a493263
...
...
@@ -83,7 +83,7 @@
{
field
:
'order_no'
,
align
:
'center'
,
width
:
200
,
title
:
'支付单号'
},
{
field
:
'username'
,
align
:
'center'
,
width
:
150
,
title
:
'用户名'
,
templet
:
'<div>{{= d.getuserdata.username}}</div>'
},
{
field
:
'mobile'
,
align
:
'center'
,
width
:
120
,
title
:
'用户手机'
,
templet
:
'<div>{{= d.getuserdata.mobile}}</div>'
},
{
field
:
'order_name'
,
align
:
'center'
,
title
:
'支付详细'
},
{
field
:
'order_name'
,
align
:
'center'
,
minWidth
:
220
,
title
:
'支付详细'
},
{
field
:
'pay_amount'
,
align
:
'center'
,
width
:
100
,
title
:
'支付金额'
},
{
field
:
"pay_status_text"
,
width
:
100
,
align
:
'center'
,
title
:
"支付状态"
,
templet
:
'#paystatus-demo'
},
{
field
:
'pay_method_text'
,
align
:
'center'
,
width
:
100
,
title
:
'支付类型'
},
...
...
app/admin/view/project/project/index.html
View file @
4a493263
...
...
@@ -259,6 +259,7 @@
btn2
:
function
(
index
,
layero
,
that
){
layer
.
prompt
({
formType
:
2
,
maxlength
:
200
,
value
:
''
,
title
:
'请输入失败原因'
,
},
function
(
value
,
index
,
elem
){
...
...
app/admin/view/users/business/index.html
View file @
4a493263
...
...
@@ -92,9 +92,9 @@
{
field
:
'id'
,
width
:
50
,
unresize
:
true
,
align
:
'center'
,
title
:
'ID'
,
sort
:
!
0
},
{
field
:
'businessname'
,
align
:
'center'
,
width
:
160
,
title
:
'用户名'
,
templet
:
'<div>{{d.getuserdata.username}}</div>'
},
{
field
:
'mobile'
,
align
:
'center'
,
width
:
120
,
title
:
'用户手机号'
,
templet
:
'<div>{{d.getuserdata.mobile}}</div>'
},
{
field
:
'name'
,
align
:
'center'
,
title
:
'企业名称'
},
{
field
:
'type'
,
align
:
'center'
,
title
:
'类型'
},
{
field
:
'addressxx'
,
align
:
'center'
,
title
:
'详细地址'
},
{
field
:
'name'
,
align
:
'center'
,
minWidth
:
150
,
title
:
'企业名称'
},
{
field
:
'type'
,
align
:
'center'
,
minWidth
:
100
,
title
:
'类型'
},
{
field
:
'addressxx'
,
align
:
'center'
,
minWidth
:
200
,
title
:
'详细地址'
},
{
field
:
"status_text"
,
width
:
100
,
align
:
'center'
,
title
:
"状态"
,
templet
:
'#status-demo'
},
{
field
:
'contacts_name'
,
align
:
'center'
,
width
:
100
,
title
:
'联系人姓名'
},
{
field
:
'job'
,
align
:
'center'
,
width
:
100
,
title
:
'联系人职位'
},
...
...
@@ -150,6 +150,7 @@
btn2
:
function
(
index
,
layero
,
that
){
layer
.
prompt
({
formType
:
2
,
maxlength
:
200
,
value
:
''
,
title
:
'请输入失败原因'
,
},
function
(
value
,
index
,
elem
){
...
...
app/admin/view/users/mail/add.html
View file @
4a493263
...
...
@@ -23,7 +23,7 @@
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label"
>
消息内容
</label>
<div
class=
"layui-input-block"
>
<textarea
placeholder=
"请输入消息内容"
name=
"content"
class=
"layui-textarea"
></textarea>
<textarea
placeholder=
"请输入消息内容"
name=
"content"
class=
"layui-textarea"
maxlength=
"220"
></textarea>
</div>
</div>
...
...
app/admin/view/users/school/index.html
View file @
4a493263
...
...
@@ -96,8 +96,8 @@
{
field
:
'id'
,
width
:
50
,
unresize
:
true
,
align
:
'center'
,
title
:
'ID'
,
sort
:
!
0
},
{
field
:
'schoolname'
,
align
:
'center'
,
width
:
160
,
title
:
'用户名'
,
templet
:
'<div>{{d.getuserdata.username}}</div>'
},
{
field
:
'mobile'
,
align
:
'center'
,
width
:
120
,
title
:
'用户手机号'
,
templet
:
'<div>{{d.getuserdata.mobile}}</div>'
},
{
field
:
'name'
,
align
:
'center'
,
title
:
'学校名称'
},
{
field
:
'addressxx'
,
align
:
'center'
,
title
:
'详细地址'
},
{
field
:
'name'
,
align
:
'center'
,
minWidth
:
150
,
title
:
'学校名称'
},
{
field
:
'addressxx'
,
align
:
'center'
,
minWidth
:
200
,
title
:
'详细地址'
},
{
field
:
"status_text"
,
width
:
100
,
align
:
'center'
,
title
:
"状态"
,
templet
:
'#status-demo'
},
{
field
:
'contacts_name'
,
align
:
'center'
,
width
:
100
,
title
:
'联系人姓名'
},
{
field
:
'job'
,
align
:
'center'
,
width
:
100
,
title
:
'联系人职位'
},
...
...
@@ -153,6 +153,7 @@
btn2
:
function
(
index
,
layero
,
that
){
layer
.
prompt
({
formType
:
2
,
maxlength
:
200
,
value
:
''
,
title
:
'请输入失败原因'
,
},
function
(
value
,
index
,
elem
){
...
...
app/admin/view/users/smrz/index.html
View file @
4a493263
...
...
@@ -149,6 +149,7 @@
btn2
:
function
(
index
,
layero
,
that
){
layer
.
prompt
({
formType
:
2
,
maxlength
:
200
,
value
:
''
,
title
:
'请输入失败原因'
,
},
function
(
value
,
index
,
elem
){
...
...
app/admin/view/users/user/index.html
View file @
4a493263
...
...
@@ -80,7 +80,7 @@
{
type
:
'checkbox'
,
fixed
:
'left'
},
{
field
:
'id'
,
width
:
50
,
unresize
:
true
,
align
:
'center'
,
title
:
'ID'
,
sort
:
!
0
},
{
field
:
'headericourl'
,
width
:
50
,
align
:
'center'
,
title
:
'头像'
,
templet
:
'<div><div class="files_itemadv"><img src="{{d.headericourl}}" lay-event="user-event-image" /></div></div>'
},
{
field
:
'username'
,
align
:
'center'
,
title
:
'用户名'
},
{
field
:
'username'
,
align
:
'center'
,
minWidth
:
200
,
title
:
'用户名'
},
{
field
:
'realname'
,
align
:
'center'
,
width
:
120
,
title
:
'真实姓名'
,
templet
:
'<div>{{= d.realname ? d.realname : "-"}}</div>'
},
{
field
:
'mobile'
,
align
:
'center'
,
width
:
120
,
title
:
'手机号'
},
{
field
:
'roletxt'
,
align
:
'center'
,
width
:
120
,
title
:
'用户类型'
},
...
...
@@ -138,10 +138,13 @@
},{
title
:
'重置密码'
,
id
:
'restpwd'
},{
title
:
'删除'
,
id
:
'del'
}],
}
// ,{
// title: '删除',
// id: 'del'
// }
],
click
:
function
(
menudata
){
if
(
menudata
.
id
===
'monelog'
){
usermoneylogOpen
(
id
);
...
...
app/api/controller/mine/Cert.php
View file @
4a493263
...
...
@@ -31,6 +31,7 @@ class Cert extends BaseController
$query
=
CertOrder
::
where
(
$where
)
// ->append(['otherFileList'])
->
with
([
'certfiledata'
=>
[
'certfile'
]])
->
with
([
'certorderaddress'
])
->
where
(
'co.status'
,
'!='
,
0
)
->
alias
(
'co'
)
->
join
(
'cert c'
,
'c.id = co.cert_id'
)
...
...
@@ -41,6 +42,7 @@ class Cert extends BaseController
'c.fzjg'
,
'c.id as cert_id'
,
'c.price'
,
'c.ff_type'
,
'c.sn'
]);
...
...
app/api/controller/mine/User.php
View file @
4a493263
...
...
@@ -11,6 +11,7 @@ use app\api\validate\CourseValidate;
use
app\api\validate\UserValidate
;
use
app\BaseController
;
use
app\model\CertOrder
;
use
app\model\CertOrderAddress
;
use
app\model\Course
as
CourseModel
;
use
app\model\Payment
;
use
app\model\project\Mail
;
...
...
@@ -21,6 +22,7 @@ use app\model\project\UserWithdrawal;
use
app\Request
;
use
app\model\project\User
as
UserModel
;
use
think\facade\Db
;
use
think\facade\Validate
;
class
User
extends
BaseController
{
...
...
@@ -136,9 +138,9 @@ class User extends BaseController
$data
[
'account'
]
=
$data
[
'zfb'
];
$data
[
'user_id'
]
=
$request
->
userId
;
unset
(
$data
[
'zfb'
]);
if
(
$zfbinfo
)
{
if
(
$zfbinfo
)
{
$res
=
UserAccount
::
where
(
'user_id'
,
$request
->
userId
)
->
update
(
$data
);
}
else
{
}
else
{
$res
=
UserAccount
::
create
(
$data
);
}
...
...
@@ -197,7 +199,7 @@ class User extends BaseController
return
$vo
;
}
$data
=
$request
->
param
();
$smrzinfo
=
UserSmrz
::
where
([
'user_id'
=>
$request
->
userId
])
->
find
();
$smrzinfo
=
UserSmrz
::
where
([
'user_id'
=>
$request
->
userId
])
->
where
(
'is_del'
,
0
)
->
find
();
if
(
$smrzinfo
)
{
if
(
$smrzinfo
[
'status'
]
==
2
)
{
return
$this
->
returnMsg
(
'已认证'
);
...
...
@@ -472,4 +474,41 @@ class User extends BaseController
}
//证书添加收获地址
public
function
savecertaddress
(
Request
$request
)
{
$post
=
$request
->
param
();
$validate
=
Validate
::
rule
([
'cert_order_id'
=>
'require'
,
'nickname'
=>
'require'
,
'mobile'
=>
'require|mobile'
,
'province'
=>
'require'
,
'city'
=>
'require'
,
'area'
=>
'require'
,
'address'
=>
'require'
,
])
->
message
([
'cert_order_id.require'
=>
'证书id不能为空'
,
'nickname.require'
=>
'收货人不能为空'
,
'mobile.require'
=>
'收货人联系方式不能为空'
,
'mobile.mobile'
=>
'收货人联系方式错误'
,
'province.require'
=>
'请选择省市区'
,
'city.require'
=>
'请选择省市区'
,
'area.require'
=>
'请选择省市区'
,
'address.require'
=>
'请输入详细地址'
,
]);
if
(
!
$validate
->
check
(
$post
))
{
return
$this
->
returnMsg
(
$validate
->
getError
(),
0
);
}
$data
=
$request
->
only
([
'cert_order_id'
,
'nickname'
,
'mobile'
,
'province'
,
'city'
,
'area'
,
'address'
]);
$data
[
'user_id'
]
=
$request
->
userId
;
$data
[
'detail_address'
]
=
get_area_name
(
$data
[
'province'
])
.
' '
.
get_area_name
(
$data
[
'city'
])
.
' '
.
get_area_name
(
$data
[
'area'
])
.
' '
.
$data
[
'address'
];
$info
=
CertOrderAddress
::
where
([
'cert_order_id'
=>
$post
[
'cert_order_id'
]])
->
find
();
if
(
$info
)
{
$res
=
CertOrderAddress
::
where
([
'cert_order_id'
=>
$post
[
'cert_order_id'
]])
->
update
(
$data
);
}
else
{
$res
=
CertOrderAddress
::
create
(
$data
);
}
return
$this
->
returnMsg
(
'添加成功'
,
1
,
$res
);
}
}
\ No newline at end of file
app/api/middleware/AddExperience.php
View file @
4a493263
...
...
@@ -10,15 +10,18 @@ class AddExperience
public
function
handle
(
$request
,
\Closure
$next
)
{
$log
=
[
'ip'
=>
$request
->
ip
(),
'method'
=>
$request
->
method
(),
'url'
=>
$request
->
url
(),
'params'
=>
$request
->
param
(),
'header'
=>
$request
->
header
(),
'time'
=>
date
(
'Y-m-d H:i:s'
),
];
Log
::
channel
(
'api_log'
)
->
write
(
$log
);
if
(
$request
->
url
()
!=
'/api/task.order/run'
){
$log
=
[
'ip'
=>
$request
->
ip
(),
'method'
=>
$request
->
method
(),
'url'
=>
$request
->
url
(),
'params'
=>
$request
->
param
(),
'header'
=>
$request
->
header
(),
'time'
=>
date
(
'Y-m-d H:i:s'
),
];
Log
::
channel
(
'api_log'
)
->
write
(
$log
);
}
$response
=
$next
(
$request
);
try
{
...
...
app/api/validate/UserValidate.php
View file @
4a493263
...
...
@@ -19,7 +19,7 @@ class UserValidate extends BaseValidate
'updateValue'
=>
'require'
,
'zfb'
=>
'require'
,
'realname'
=>
'require'
,
'idcard'
=>
'require'
,
'idcard'
=>
'require
|idCard
'
,
'idcard_q'
=>
'require'
,
'idcard_h'
=>
'require'
,
'amount'
=>
'require|chenckAmount'
,
...
...
@@ -48,6 +48,7 @@ class UserValidate extends BaseValidate
'updateField.updateFieldchange'
=>
'提交信息长度或者格式错误'
,
'amount.require'
=>
'金额不能为空'
,
'amount.chenckAmount'
=>
'金额不合法'
,
'idcard.idCard'
=>
'身份证格式错误'
,
];
protected
function
checkPasswordEqual
(
$value
,
$rule
,
$data
)
...
...
app/model/CertOrder.php
View file @
4a493263
...
...
@@ -22,7 +22,7 @@ class CertOrder extends Model
public
function
certdata
()
{
return
$this
->
hasOne
(
Cert
::
class
,
'id'
,
'cert_id'
)
->
field
(
'id,title,price'
);
->
field
(
'id,title,price
,ff_type
'
);
}
...
...
@@ -39,6 +39,12 @@ class CertOrder extends Model
return
$this
->
belongsTo
(
User
::
class
,
'user_id'
,
'id'
)
->
field
(
'id,username,mobile'
);
}
//证书收货地址
public
function
certorderaddress
()
{
return
$this
->
hasOne
(
CertOrderAddress
::
class
,
'cert_order_id'
,
'id'
);
}
public
function
getOtherFileListAttr
(
$value
,
$data
)
{
...
...
app/model/CertOrderAddress.php
0 → 100644
View file @
4a493263
<?php
/**
* ===========================================================================
* Veitool 快捷开发框架系统
* Author: Niaho 26843818@qq.com
* Copyright (c)2019-2025 www.veitool.com All rights reserved.
* Licensed: 这不是一个自由软件,不允许对程序代码以任何形式任何目的的再发行
* ---------------------------------------------------------------------------
*/
namespace
app\model
;
use
app\model\project\User
;
use
app\model\system\SystemUploadFile
;
use
think\Model
;
/**
* 课程模型
*/
class
CertOrderAddress
extends
Model
{
protected
$autoWriteTimestamp
=
true
;
protected
$createTime
=
'createtime'
;
public
function
userprofile
()
{
return
$this
->
belongsTo
(
User
::
class
,
'user_id'
,
'id'
)
->
field
(
'id,username,mobile'
);
}
public
function
certorder
()
{
return
$this
->
belongsTo
(
CertOrder
::
class
,
'cert_order_id'
,
'id'
);
}
}
\ No newline at end of file
app/model/project/User.php
View file @
4a493263
...
...
@@ -111,7 +111,7 @@ class User extends Model
//实名信息
public
function
userReal
()
{
return
$this
->
hasOne
(
UserSmrz
::
class
,
'user_id'
,
'id'
)
->
where
(
'is_del'
,
0
)
->
where
(
'status'
,
2
)
;
return
$this
->
hasOne
(
UserSmrz
::
class
,
'user_id'
,
'id'
)
->
where
(
'is_del'
,
0
);
}
...
...
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