Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
杨树贤
/
liexin_supplier
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
944c38a1
authored
Apr 26, 2022
by
杨树贤
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
新增页面关闭逻辑
parent
8bf96bad
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
41 additions
and
42 deletions
resources/views/script/AddSupplierScript.blade.php
resources/views/script/supplier/SupplierBaseScript.blade.php
resources/views/script/AddSupplierScript.blade.php
View file @
944c38a1
...
...
@@ -60,5 +60,45 @@
}
});
form
.
on
(
'submit(cancelAddSupplier)'
,
function
(
data
)
{
admin
.
closeThisTabs
();
});
form
.
on
(
'submit(addSupplier)'
,
function
(
data
)
{
let
url
=
'/api/supplier/AddSupplier'
;
let
res
=
ajax
(
url
,
data
.
field
);
if
(
!
res
)
{
layer
.
msg
(
'网络错误,请重试'
,
{
icon
:
6
});
}
else
{
if
(
res
.
err_code
===
0
)
{
layer
.
msg
(
res
.
err_msg
,
{
icon
:
6
});
admin
.
closeThisTabs
();
}
else
{
layer
.
msg
(
res
.
err_msg
,
{
icon
:
5
});
//todo
}
}
return
false
;
});
form
.
on
(
'submit(addAndApplySupplier)'
,
function
(
data
)
{
layer
.
confirm
(
'确定直接申请审核吗?确定后会直接进入审核中的状态,无法进行二次修改'
,
function
(
index
)
{
//还要判断
let
url
=
'/api/supplier/AddSupplier?direct_apply=1'
;
let
res
=
ajax
(
url
,
data
.
field
);
if
(
!
res
)
{
layer
.
msg
(
'网络错误,请重试'
,
{
icon
:
6
});
}
else
{
if
(
res
.
err_code
===
0
)
{
layer
.
msg
(
res
.
err_msg
,
{
icon
:
6
});
admin
.
closeThisTabs
();
}
else
{
layer
.
msg
(
res
.
err_msg
,
{
icon
:
5
});
}
}
});
return
false
;
});
});
</script>
\ No newline at end of file
resources/views/script/supplier/SupplierBaseScript.blade.php
View file @
944c38a1
...
...
@@ -174,46 +174,5 @@
data
:
regionData
,
selected
:
provinceCity
});
form
.
on
(
'submit(cancelAddSupplier)'
,
function
(
data
)
{
admin
.
closeThisDialog
();
});
form
.
on
(
'submit(addSupplier)'
,
function
(
data
)
{
let
url
=
'/api/supplier/AddSupplier'
;
let
res
=
ajax
(
url
,
data
.
field
);
if
(
!
res
)
{
layer
.
msg
(
'网络错误,请重试'
,
{
icon
:
6
});
}
else
{
if
(
res
.
err_code
===
0
)
{
admin
.
closeThisDialog
();
parent
.
layer
.
msg
(
res
.
err_msg
,
{
icon
:
6
});
}
else
{
parent
.
layer
.
msg
(
res
.
err_msg
,
{
icon
:
5
});
//todo
}
}
return
false
;
});
form
.
on
(
'submit(addAndApplySupplier)'
,
function
(
data
)
{
layer
.
confirm
(
'确定直接申请审核吗?确定后会直接进入审核中的状态,无法进行二次修改'
,
function
(
index
)
{
//还要判断
let
url
=
'/api/supplier/AddSupplier?direct_apply=1'
;
let
res
=
ajax
(
url
,
data
.
field
);
if
(
!
res
)
{
layer
.
msg
(
'网络错误,请重试'
,
{
icon
:
6
});
}
else
{
if
(
res
.
err_code
===
0
)
{
admin
.
closeThisDialog
();
parent
.
layer
.
msg
(
res
.
err_msg
,
{
icon
:
6
});
}
else
{
parent
.
layer
.
msg
(
res
.
err_msg
,
{
icon
:
5
});
}
}
});
return
false
;
});
});
</script>
\ No newline at end of file
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