Yii Framework Forum: Login Dengan Role - Yii Framework Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Login Dengan Role Rate Topic: -----

#1 User is offline   dyooolicious 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 109
  • Joined: 18-October 12
  • Location:Surabaya, East Java, Indonesia

Posted 21 October 2012 - 10:56 PM

Studi Kasus : Role Sederhana

Tambahkan field role di table user

Ada 3 role :
Admin
bisa semua
Member
bisa insert, update, delete post
Guest
bisa view post

Buat dropdownlist role di menu user

Simpan Role ketika login

Buat Class WebUser berisi function :

getRole()
getIsAdmin()
getIsMember()

Setting class WebUser di main

Buat otorisasi dari 3 role di masing2 controller



kalo ada studi kasus kayak gitu, langkah-langkah pembuatannya gmn ya?
keep learning, trying and praying makes you keep going !
tweet me : @dyooolicious
http://ini-infonya.blogspot.com/
0

#2 User is offline   xicond 

  • Junior Member
  • Pip
  • Yii
  • Group: Members
  • Posts: 34
  • Joined: 06-October 12

Posted 29 October 2012 - 07:14 AM

coba dipraktikan dulu

Yii::Otentikasi dan Otorisasi

View Postdyooolicious, on 21 October 2012 - 10:56 PM, said:

Studi Kasus : Role Sederhana

Tambahkan field role di table user

Ada 3 role :
Admin
bisa semua
Member
bisa insert, update, delete post
Guest
bisa view post

Buat dropdownlist role di menu user

Simpan Role ketika login

Buat Class WebUser berisi function :

getRole()
getIsAdmin()
getIsMember()

Setting class WebUser di main

Buat otorisasi dari 3 role di masing2 controller



kalo ada studi kasus kayak gitu, langkah-langkah pembuatannya gmn ya?

0

#3 User is offline   dyooolicious 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 109
  • Joined: 18-October 12
  • Location:Surabaya, East Java, Indonesia

Posted 29 October 2012 - 08:17 PM

iya, sudah selesai :)
keep learning, trying and praying makes you keep going !
tweet me : @dyooolicious
http://ini-infonya.blogspot.com/
0

#4 User is offline   zykapratama 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 7
  • Joined: 13-January 11
  • Location:Indonesia

Posted 17 January 2013 - 02:08 AM

View Postdyooolicious, on 21 October 2012 - 10:56 PM, said:

Studi Kasus : Role Sederhana

Tambahkan field role di table user

Ada 3 role :
Admin
bisa semua
Member
bisa insert, update, delete post
Guest
bisa view post

Buat dropdownlist role di menu user

Simpan Role ketika login

Buat Class WebUser berisi function :

getRole()
getIsAdmin()
getIsMember()

Setting class WebUser di main

Buat otorisasi dari 3 role di masing2 controller



kalo ada studi kasus kayak gitu, langkah-langkah pembuatannya gmn ya?


kenapa gak pake ini aja ???

Rights Extension
0

#5 User is offline   J.J 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 126
  • Joined: 01-April 11

Posted 27 January 2013 - 10:55 AM

View Postdyooolicious, on 21 October 2012 - 10:56 PM, said:

Studi Kasus : Role Sederhana

Tambahkan field role di table user

Ada 3 role :
Admin
bisa semua
Member
bisa insert, update, delete post
Guest
bisa view post

Buat dropdownlist role di menu user

Simpan Role ketika login

Buat Class WebUser berisi function :

getRole()
getIsAdmin()
getIsMember()

Setting class WebUser di main

Buat otorisasi dari 3 role di masing2 controller



kalo ada studi kasus kayak gitu, langkah-langkah pembuatannya gmn ya?


Pake extension aja gan, lbh cepat. Bisa pake extension right, atau pake ini. Yii auth

Untuk dokumentasinya, dapat dilihat di dokumentasi.
Selamat mencoba gan.. B)
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users