This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sdfsdfsdfsdf |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def connect(%{"username" => username, "chat_token" => chat_token}, socket) do | |
case Repo.get_by(User, username: username) do | |
nil -> | |
:error | |
user -> | |
if user.chat_token == chat_token do | |
socket = assign(socket, :current_user, user) | |
{:ok, socket} | |
else | |
:error |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
OpenSSH_7.2p2, OpenSSL 1.0.2h-fips 3 May 2016 | |
debug1: Reading configuration data /home/nguyenvinhlinh/.ssh/config | |
debug1: Reading configuration data /etc/ssh/ssh_config | |
debug1: /etc/ssh/ssh_config line 58: Applying options for * | |
debug1: Connecting to 128.199.95.172 [128.199.95.172] port 22. | |
debug1: Connection established. | |
debug1: key_load_public: No such file or directory | |
debug1: identity file /home/nguyenvinhlinh/.ssh/id_rsa type -1 | |
debug1: key_load_public: No such file or directory | |
debug1: identity file /home/nguyenvinhlinh/.ssh/id_rsa-cert type -1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// /function toggleCampusSelect() { | |
// switch($('#js-role-select').val()) { | |
// case 'campus_manager': | |
// $('#js-campus-select').show(); | |
// $("div.contract-full-time").hide(); | |
// $("#user_contract_type").prop("disabled", true); | |
// $("#user_contract_type").val("full time"); | |
// break; | |
// case 'teacher': | |
// $("#user_contract_type").prop("disabled", false); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def getDataCampusSchedule(conn, %{"f" => %{"campus_id" => campus_id, "semester_id" => semester_id}}) do | |
query = from csetting in ClassSetting , | |
join: ctime in ClassTime, on: ctime.id == csetting.class_time_id, | |
join: class in Class, on: class.id == csetting.class_id, | |
join: teacher in User,on: teacher.id == csetting.teacher_id, | |
join: subject in Subject, on: subject.id == csetting.subject_id, | |
join: campus in Campus, on: campus.id == class.campus_id, | |
where: class.semester_id == ^String.to_integer(semester_id), | |
order_by: [ctime.id, csetting.date], |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
defmodule Plug.TeacherProfileControl do | |
import Plug.Conn | |
import Phoenix.Controller | |
alias Iea.User | |
use Plug.TeacherProfileControl | |
def init(opt) do | |
opt | |
end | |
defmacro is_edit_path(conn) do |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
defmodule XXX do | |
import Plug.Conn | |
import Phoenix.Controller | |
def __using__(params) do | |
params | |
end | |
defmacro is_edit_path(conn) do | |
conn.request_path == Iea.Router.Helpers.teacher_user_path(conn, :edit_profile) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
LoadError: libncurses.so.5: cannot open shared object file: No such file or directory - /home/nguyenvinhlinh/.rvm/rubies/ruby-2.0.0-p643/lib/ruby/2.0.0/x86_64-linux/readline.so | |
/home/nguyenvinhlinh/.rvm/gems/ruby-2.0.0-p643@dots/gems/byebug-3.1.2/lib/byebug/history.rb:1:in `require' | |
/home/nguyenvinhlinh/.rvm/gems/ruby-2.0.0-p643@dots/gems/byebug-3.1.2/lib/byebug/history.rb:1:in `<top (required)>' | |
/home/nguyenvinhlinh/.rvm/gems/ruby-2.0.0-p643@dots/gems/byebug-3.1.2/lib/byebug/interfaces/local_interface.rb:1:in `require' | |
/home/nguyenvinhlinh/.rvm/gems/ruby-2.0.0-p643@dots/gems/byebug-3.1.2/lib/byebug/interfaces/local_interface.rb:1:in `<top (required)>' | |
/home/nguyenvinhlinh/.rvm/gems/ruby-2.0.0-p643@dots/gems/byebug-3.1.2/lib/byebug/interface.rb:31:in `require' | |
/home/nguyenvinhlinh/.rvm/gems/ruby-2.0.0-p643@dots/gems/byebug-3.1.2/lib/byebug/interface.rb:31:in `<module:Byebug>' | |
/home/nguyenvinhlinh/.rvm/gems/ruby-2.0.0-p643@dots/gems/byebug-3.1.2/lib/byebug/interface.rb:1:in `<top (required)>' | |
/home/nguyenvinhl |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
- hosts: kmt | |
become_user: root | |
become: yes | |
gather_facts: no | |
remote_user: vagrant | |
tasks: | |
- name: Install postgres database | |
apt: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2016/10/20 10:35:36 [crit] 26974#0: *1 connect() to unix:/tmp/baggable/baggable-uwsgi.sock failed (2: No such file or directory) while connecting to upstream, client: 10.0.2.2, server: localhost, request: "GET / HTTP/1.1", upstream: "uwsgi://unix:/tmp/baggable/baggable-uwsgi.sock:", host: "localhost:9100" | |
2016/10/20 10:35:36 [crit] 26974#0: *1 connect() to unix:/tmp/baggable/baggable-uwsgi.sock failed (2: No such file or directory) while connecting to upstream, client: 10.0.2.2, server: localhost, request: "GET /favicon.ico HTTP/1.1", upstream: "uwsgi://unix:/tmp/baggable/baggable-uwsgi.sock:", host: "localhost:9100", referrer: "http://localhost:9100/" | |
2016/10/20 10:35:37 [crit] 26974#0: *1 connect() to unix:/tmp/baggable/baggable-uwsgi.sock failed (2: No such file or directory) while connecting to upstream, client: 10.0.2.2, server: localhost, request: "GET / HTTP/1.1", upstream: "uwsgi://unix:/tmp/baggable/baggable-uwsgi.sock:", host: "localhost:9100" | |
2016/10/20 10:35:37 [crit] 26974#0: *1 connect() to unix |
OlderNewer