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
d6e47ec7
authored
Dec 31, 2024
by
杨树贤
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
去掉合同开始时间和js卡主问题
parent
ae2cce52
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
3 additions
and
11 deletions
app/Http/Controllers/Api/SupplierContractApiController.php
app/Http/Services/SupplierContractService.php
resources/views/script/SaveSupplierContractScript.blade.php
resources/views/web/SaveSupplierContract.blade.php
app/Http/Controllers/Api/SupplierContractApiController.php
View file @
d6e47ec7
...
...
@@ -33,7 +33,6 @@ class SupplierContractApiController extends Controller
'id'
,
'supplier_id'
,
'commission_rate'
,
'start_time'
,
'end_time'
,
'check_date'
,
]);
...
...
@@ -41,8 +40,7 @@ class SupplierContractApiController extends Controller
$validator
=
\Validator
::
make
(
$data
,
[
'supplier_id'
=>
'required|integer'
,
'start_time'
=>
'required|date'
,
'end_time'
=>
'required|date|after:start_time'
,
'end_time'
=>
'required|date'
,
'commission_rate'
=>
'required|numeric|max:100|min:1'
,
'check_date'
=>
'required|integer|min:1|max:31'
],
[
...
...
app/Http/Services/SupplierContractService.php
View file @
d6e47ec7
...
...
@@ -29,7 +29,6 @@ class SupplierContractService
{
try
{
\DB
::
connection
(
'web'
)
->
beginTransaction
();
$data
[
'start_time'
]
=
strtotime
(
$data
[
'start_time'
]);
$data
[
'end_time'
]
=
strtotime
(
$data
[
'end_time'
]);
// 检查是否已存在相同供应商的合同
...
...
@@ -56,8 +55,7 @@ class SupplierContractService
if
(
$oldData
)
{
$columnMap
=
[
'supplier_id'
=>
'供应商'
,
'start_time'
=>
'开始时间'
,
'end_time'
=>
'结束时间'
,
'end_time'
=>
'截止时间'
,
'commission_rate'
=>
'抽佣比率'
,
'check_date'
=>
'对账日期'
,
];
...
...
resources/views/script/SaveSupplierContractScript.blade.php
View file @
d6e47ec7
...
...
@@ -58,6 +58,7 @@
admin
.
closeThisDialog
();
},
1000
);
}
else
{
layer
.
close
(
loadIndex
);
layer
.
msg
(
res
.
err_msg
,
{
icon
:
5
});
...
...
resources/views/web/SaveSupplierContract.blade.php
View file @
d6e47ec7
...
...
@@ -33,11 +33,6 @@
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label"
><span
class=
"require"
>
*
</span>
合同有效期
</label>
<div
class=
"layui-input-inline"
style=
"width: 150px;"
>
<input
type=
"text"
name=
"start_time"
id=
"start_time"
lay-verify=
"required"
placeholder=
"开始日期"
class=
"layui-input"
autocomplete=
"off"
value=
"{{ $contract['start_time'] or '' }}"
>
</div>
<div
class=
"layui-form-mid"
>
-
</div>
<div
class=
"layui-input-inline"
style=
"width: 150px;"
>
<input
type=
"text"
name=
"end_time"
id=
"end_time"
lay-verify=
"required"
placeholder=
"结束日期"
class=
"layui-input"
autocomplete=
"off"
value=
"{{ $contract['end_time'] or '' }}"
>
</div>
...
...
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