Toggle navigation
This project
Loading...
Sign in
najixian
/
xt_dc_admin
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
0
Members
Labels
Wiki
Forks
Network
Download as
Email Patches
Plain Diff
Browse Files
Commit
630489938f1014fe3c321cf17c60312e18601b57
Authored by
pengye
2019-12-19 18:30:05 +0800
1 parent
3e1bafca
build: skipped
no message
Changes
1
Builds
0
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
28 deletions
application/admin/view/area/addagent.html
application/admin/view/area/addagent.html
View file @
6304899
{include file="common/head"/}
<div
class=
"admin-main fadeInUp animated"
ng-app=
"hd"
ng-controller=
"ctrl"
>
<fieldset
class=
"layui-elem-field layui-field-title"
>
<legend>
绑定代理商
</legend>
</fieldset>
<div
class=
"admin-main layui-anim layui-anim-upbit"
>
<form
class=
"layui-form layui-form-pane"
>
<div
class=
"layui-form-item"
>
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label"
>
代理商名称
</label>
<div
class=
"layui-input-4"
>
<input
type=
'hidden'
name=
'areaid'
value=
'{$areaid}'
>
<input
type=
"text"
name=
"agent_name"
ng-model=
"field.title"
lay-verify=
"required"
class=
"layui-input"
>
</div>
</div>
...
...
@@ -17,32 +13,32 @@
<input
type=
"text"
name=
"agent_phone"
ng-model=
"field.title"
lay-verify=
"required"
class=
"layui-input"
>
</div>
</div>
<input
type=
"hidden"
name=
'areaid'
value=
"{$areaid}"
>
<div
class=
"layui-form-item"
>
<div
class=
"layui-input-block"
>
<button
type=
"button"
class=
"layui-btn"
lay-submit=
""
lay-filter=
"submit"
>
{:lang('submit')}
</button>
<a
href=
"{:url('addagent')}"
class=
"layui-btn layui-btn-primary"
>
{:lang('back')}
</a>
</div>
<div
class=
"layui-input-block"
>
<button
type=
"button"
class=
"layui-btn"
lay-submit=
""
lay-filter=
"submit"
>
{:lang('submit')}
</button>
</div>
</div>
</form>
</div>
{include file="common/foot"/}
<script
src=
"/static/common/js/angular.min.js"
></script>
<script>
layui
.
use
([
'form'
,
'layer'
],
function
()
{
var
form
=
layui
.
form
,
layer
=
layui
.
layer
,
$
=
layui
.
jquery
;
form
.
on
(
'submit(submit)'
,
function
(
data
)
{
loading
=
layer
.
load
(
1
,{
shade
:[
0.1
,
'#fff'
]});
// 提交到方法 默认为本身
$
.
post
(
"{:url('addagent')}"
,
data
.
field
,
function
(
res
)
{
layer
.
close
(
loading
);
if
(
res
.
code
>
0
)
{
layer
.
msg
(
res
.
msg
,
{
time
:
1800
,
icon
:
1
},
function
()
{
location
.
href
=
res
.
url
;
});
}
else
{
layer
.
msg
(
res
.
msg
,
{
time
:
1800
,
icon
:
2
});
}
});
})
});
layui
.
use
(
'form'
,
function
()
{
var
form
=
layui
.
form
,
$
=
layui
.
jquery
;
//根据菜品ID 修改对应菜品的GIF、视频url
form
.
on
(
'submit(submit)'
,
function
(
data
)
{
var
loading
=
layer
.
load
(
1
,
{
shade
:
[
0.1
,
'#fff'
]});
$
.
post
(
"{:url('addagent')}"
,
data
.
field
,
function
(
res
)
{
layer
.
close
(
loading
);
if
(
res
.
code
==
1
)
{
layer
.
msg
(
res
.
msg
,
{
time
:
1000
,
icon
:
1
},
function
()
{
window
.
parent
.
location
.
reload
();
});
}
else
{
layer
.
msg
(
res
.
msg
,
{
time
:
1000
,
icon
:
2
});
}
});
})
});
</script>
\ No newline at end of file
...
...
Please
register
or
login
to post a comment