Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
smart_core_connect
/
core-connect
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
ea0117b1
authored
May 22, 2018
by
Wittaya-PIM
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'integration' into wittaya
parents
9b7a9912
c9ff32ad
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
9 additions
and
8 deletions
+9
-8
www/src/Controller/ProfilesController.php
+6
-4
www/src/Controller/UsersController.php
+3
-4
www/src/Template/Profiles/index.ctp
+0
-0
www/src/Template/Users/signup.ctp
+0
-0
No files found.
www/src/Controller/ProfilesController.php
View file @
ea0117b1
...
...
@@ -8,13 +8,13 @@ use Cake\Http\Client;
class
ProfilesController
extends
AppController
{
public
function
index
(
$id
=
13112
){
public
function
index
(){
$this
->
viewBuilder
()
->
layout
(
'blank'
);
/*******************************/
$id
=
$this
->
Auth
->
user
(
'id'
);
$id
=
$this
->
Auth
->
user
(
'id'
);
$this
->
loadModel
(
'Users'
);
$responseUserProfile
=
$this
->
Users
->
get
(
$id
,
[
...
...
@@ -47,8 +47,8 @@ class ProfilesController extends AppController
'keyField'
=>
'id'
,
'valueField'
=>
'province_name_th'
])
->
where
([
'master_country_id ='
=>
$responseUserPersonal
[
'master_country_id'
]])
->
order
([
'province_name_th'
]);
->
where
([
'master_country_id ='
=>
$responseUserPersonal
[
'master_country_id'
]])
->
order
([
'province_name_th'
]);
// pr($Province);die;
if
(
!
empty
(
$Province
))
$Province
=
$Province
->
toArray
();
...
...
@@ -56,6 +56,8 @@ class ProfilesController extends AppController
$dateNow
=
$res
->
i18nFormat
(
'dd/MM/yyyy'
);
if
(
$this
->
request
->
is
([
'patch'
,
'post'
,
'put'
]))
{
// pr($this->request->data());die;
$data
=
$this
->
request
->
data
;
// pr($this->request->data);die;
...
...
www/src/Controller/UsersController.php
View file @
ea0117b1
...
...
@@ -117,13 +117,12 @@ class UsersController extends AppController {
'keyField'
=>
'id'
,
'valueField'
=>
'province_name_th'
]
);
);
if
(
!
empty
(
$provinces
))
$provinces
=
$provinces
->
toArray
();
$this
->
set
(
compact
(
'provinces'
,
'countries'
));
$this
->
viewBuilder
()
->
layout
(
'blank'
);
}
$this
->
viewBuilder
()
->
layout
(
'blank'
);
}
#---------------------------------------------------------------------------------------------------
#Signup
...
...
www/src/Template/Profiles/index.ctp
View file @
ea0117b1
This diff is collapsed.
Click to expand it.
www/src/Template/Users/signup.ctp
View file @
ea0117b1
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