Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
power
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
254
Issues
254
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Package Registry
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Pardeep Sahu
power
Commits
b14b3eb9
Commit
b14b3eb9
authored
3 years ago
by
Pardeep Sahu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
target report download calculation issue fixed
parent
e3ec50ac
Pipeline
#2587
passed with stage
in 22 seconds
Changes
4
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
8 additions
and
6 deletions
+8
-6
app/Http/Controllers/AdminController.php
app/Http/Controllers/AdminController.php
+1
-1
app/Http/Controllers/AsmController.php
app/Http/Controllers/AsmController.php
+1
-1
app/Http/Controllers/RsmController.php
app/Http/Controllers/RsmController.php
+3
-2
app/Http/Controllers/SseController.php
app/Http/Controllers/SseController.php
+3
-2
No files found.
app/Http/Controllers/AdminController.php
View file @
b14b3eb9
...
...
@@ -14399,7 +14399,7 @@ class AdminController extends Controller
if ($month == 'current') {
$currentDay = date('Y-m-d');
$goneMonthDays =
getWorkingDaysCount(date('Y-m-01'), date('Y-m-d')
);
$goneMonthDays =
(getWorkingDaysCount(date('Y-m-01'), date('Y-m-d'))-1
);
} else {
$currentDay = $start_date;
$goneMonthDays = getWorkingDaysCount($start_date, $end_day);
...
...
This diff is collapsed.
Click to expand it.
app/Http/Controllers/AsmController.php
View file @
b14b3eb9
...
...
@@ -8074,7 +8074,7 @@ class AsmController extends Controller
if
(
$month
==
'current'
)
{
$currentDay
=
date
(
'Y-m-d'
);
$goneMonthDays
=
getWorkingDaysCount
(
date
(
'Y-m-01'
),
date
(
'Y-m-d'
)
);
$goneMonthDays
=
(
getWorkingDaysCount
(
date
(
'Y-m-01'
),
date
(
'Y-m-d'
))
-
1
);
}
else
{
$currentDay
=
$start_date
;
$goneMonthDays
=
getWorkingDaysCount
(
$start_date
,
$end_day
);
...
...
This diff is collapsed.
Click to expand it.
app/Http/Controllers/RsmController.php
View file @
b14b3eb9
...
...
@@ -7065,6 +7065,7 @@ class RsmController extends Controller
public
function
target_report
(
Request
$request
)
{
$search
=
$request
->
all
();
$user_id
=
Auth
::
id
();
$result
[
'allFirms'
]
=
DB
::
table
(
'firms'
)
->
where
(
'status'
,
1
)
->
orderBy
(
'firm_name'
,
'ASC'
)
->
get
();
//asm
...
...
@@ -7093,7 +7094,7 @@ class RsmController extends Controller
$result
[
'allDealers'
]
=
$result
[
'allDealers'
]
->
where
(
"oem_id"
,
$request
->
oem
);
}
if
(
!
empty
(
$
request
->
asm
_id
))
{
if
(
!
empty
(
$
user
_id
))
{
$result
[
'allDealers'
]
=
$result
[
'allDealers'
]
->
whereRaw
(
"find_in_set(
$request->asm_id
,reporting_authority)"
);
}
...
...
@@ -7262,7 +7263,7 @@ class RsmController extends Controller
if
(
$month
==
'current'
)
{
$currentDay
=
date
(
'Y-m-d'
);
$goneMonthDays
=
getWorkingDaysCount
(
date
(
'Y-m-01'
),
date
(
'Y-m-d'
)
);
$goneMonthDays
=
(
getWorkingDaysCount
(
date
(
'Y-m-01'
),
date
(
'Y-m-d'
))
-
1
);
}
else
{
$currentDay
=
$start_date
;
$goneMonthDays
=
getWorkingDaysCount
(
$start_date
,
$end_day
);
...
...
This diff is collapsed.
Click to expand it.
app/Http/Controllers/SseController.php
View file @
b14b3eb9
...
...
@@ -7536,6 +7536,7 @@ class SseController extends Controller
public
function
target_report
(
Request
$request
)
{
$search
=
$request
->
all
();
$user_id
=
Auth
::
id
();
$result
[
'allFirms'
]
=
DB
::
table
(
'firms'
)
->
where
(
'status'
,
1
)
->
orderBy
(
'firm_name'
,
'ASC'
)
->
get
();
//asm
...
...
@@ -7564,7 +7565,7 @@ class SseController extends Controller
$result
[
'allDealers'
]
=
$result
[
'allDealers'
]
->
where
(
"oem_id"
,
$request
->
oem
);
}
if
(
!
empty
(
$
request
->
asm
_id
))
{
if
(
!
empty
(
$
user
_id
))
{
$result
[
'allDealers'
]
=
$result
[
'allDealers'
]
->
whereRaw
(
"find_in_set(
$request->asm_id
,reporting_authority)"
);
}
...
...
@@ -7735,7 +7736,7 @@ class SseController extends Controller
if
(
$month
==
'current'
)
{
$currentDay
=
date
(
'Y-m-d'
);
$goneMonthDays
=
getWorkingDaysCount
(
date
(
'Y-m-01'
),
date
(
'Y-m-d'
)
);
$goneMonthDays
=
(
getWorkingDaysCount
(
date
(
'Y-m-01'
),
date
(
'Y-m-d'
))
-
1
);
}
else
{
$currentDay
=
$start_date
;
$goneMonthDays
=
getWorkingDaysCount
(
$start_date
,
$end_day
);
...
...
This diff is collapsed.
Click to expand it.
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