Commit a68710bd by 孙龙

up

parent 6780167d
...@@ -57,5 +57,5 @@ MAIL_ENCRYPTION=tls ...@@ -57,5 +57,5 @@ MAIL_ENCRYPTION=tls
ADMIN=liuzhiyong@teshehui.com ADMIN=liuzhiyong@teshehui.com
LOGIN_DOMAIN='user.liexin.net' LOGIN_DOMAIN='user.liexin.net'
ERP_DOMAIN=http://192.168.1.235:6888 ERP_DOMAIN=http://192.168.1.235:6886
ERP_DB_NAME=ICHUNT ERP_DB_NAME=ICHUNT
\ No newline at end of file
...@@ -221,6 +221,13 @@ Class AjaxController extends Controller ...@@ -221,6 +221,13 @@ Class AjaxController extends Controller
return $this->ajaxReturn(-1,"该模板已经被主人禁用了"); return $this->ajaxReturn(-1,"该模板已经被主人禁用了");
} }
if($template_name != $templateInfo->template_name){
$count = TemplateListModel::where("create_userid",$request->user->userId)->where("template_name",$template_name)->count("id");
if($count > 0){
return $this->ajaxReturn(-1,"模板名称已经存在,请修改模板名称再提交!");
}
}
$data['t_id'] = intval($id); $data['t_id'] = intval($id);
try{ try{
DB::Connection("label")->transaction(function () use($data,$request) { DB::Connection("label")->transaction(function () use($data,$request) {
......
...@@ -58,6 +58,7 @@ ...@@ -58,6 +58,7 @@
<script type="text/html" id="action"> <script type="text/html" id="action">
<!-- <a class="btn btn-xs btn-outline btn-info" lay-event="offline">离线使用</a> --> <!-- <a class="btn btn-xs btn-outline btn-info" lay-event="offline">离线使用</a> -->
<a class="btn btn-xs btn-outline btn-success" href="/web/showTemplate?t_id=@{{ d.id }}" target="_blank" lay-event="show">预览</a> <a class="btn btn-xs btn-outline btn-success" href="/web/showTemplate?t_id=@{{ d.id }}" target="_blank" lay-event="show">预览</a>
<a class="btn btn-xs btn-outline btn-success" href="/web/design?t_id=@{{ d.id }}" target="_blank">编辑</a> <a class="btn btn-xs btn-outline btn-success" href="/web/design?t_id=@{{ d.id }}" target="_blank">编辑</a>
@{{# if (d.status == -1) { }} @{{# if (d.status == -1) { }}
<a class="btn btn-xs btn-outline layui-btn-primary" lay-event="enable">启用</a> <a class="btn btn-xs btn-outline layui-btn-primary" lay-event="enable">启用</a>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment