-
Что такое
полиморфизм
? -
Что такое *инкапсуляция? Что такое *нарушение инкапсуляции?
-
Чем
абстрактный
класс отличается отинтерфейса
? -
Расскажите о
паттерне MVC
. Чем отличаетсяпассивная
модель отактивной
?
This guide explains the way to setup a production server using Capistrano.
- Capistrano is a development gem which assist the developer to run commands on the production server (something like a Heroku toolbelt)
- Hence, it is installed and configured on developer's computer
# Gemfile
# Use Capistrano for deployment
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
sudo npm update -g cordova | |
sudo npm update -g ionic | |
rm -rf plugins/ | |
rm -rf platforms/ | |
ionic platform add ios | |
ionic run ios |
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
select posts.post_name | |
, posts.post_date | |
, (select pm.meta_value from lrt7sk_postmeta as pm where pm.post_id = posts.ID and pm.meta_key = 'wpcf-client_email' limit 1) as email | |
, (select pm.meta_value from lrt7sk_postmeta as pm where pm.post_id = posts.ID and pm.meta_key = 'wpcf-client_phone' limit 1) as phone | |
from lrt7sk_posts as posts | |
where posts.post_type = 'orders' |
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
// Закомментировать строку | |
// background:url(./images/leaf.png) no-repeat; | |
// Добавить в конце файла | |
.sublogotip { | |
color: #fff; | |
font-size: 11pt; | |
} | |
.contactblock { | |
color: #fff; |
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
require 'sneakers' | |
require 'json' | |
require 'tubesock' | |
class Processor | |
include Sneakers::Worker | |
include Tubesock::Hijack | |
from_queue 'receive_transactions_queue', | |
durable: true, | |
arguments: { |
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
--- | |
en: | |
date: | |
abbr_day_names: | |
- Sun | |
- Mon | |
- Tue | |
- Wed | |
- Thu | |
- Fri |
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
SELECT u.firm_name AS 'Компания', | |
ROUND(SUM(CASE WHEN p.t_time BETWEEN DATE(DATE_ADD(NOW(), INTERVAL -30 day)) AND DATE(NOW()) THEN p.amount ELSE 0 END),2) AS 'За весь месяц' , | |
ROUND(SUM(CASE WHEN p.t_time BETWEEN DATE(DATE_ADD(NOW(), INTERVAL -7 day)) AND DATE(NOW()) THEN p.amount ELSE NULL END),2) AS 'За 1 неделю', | |
ROUND(SUM(CASE WHEN p.t_time BETWEEN DATE(DATE_ADD(NOW(), INTERVAL -14 day)) AND DATE(DATE_ADD(NOW(), INTERVAL -7 day)) THEN p.amount ELSE NULL END),2) AS 'За 2 неделю', | |
ROUND(SUM(CASE WHEN p.t_time BETWEEN DATE(DATE_ADD(NOW(), INTERVAL -21 day)) AND DATE(DATE_ADD(NOW(), INTERVAL -14 day)) THEN p.amount ELSE NULL END),2) AS 'За 3 неделю', | |
ROUND(SUM(CASE WHEN p.t_time BETWEEN DATE(DATE_ADD(NOW(), INTERVAL -28 day)) AND DATE(DATE_ADD(NOW(), INTERVAL -21 day)) THEN p.amount ELSE NULL END),2) AS 'За 4 неделю' | |
FROM payments p | |
JOIN user u | |
ON p.user_id=u.id | |
WHERE p.status='sign' |
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
SELECT | |
uc.user_id AS Id, | |
uc.client_name AS name, | |
lc.law_full_name AS fullname, | |
us.username AS phone, | |
us.email, | |
lc.inn, | |
lc.ogrn, | |
cba.account_num AS account, | |
b.bank_name AS bank, |
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
Select | |
acqt.transaction_id As transactnum | |
, acqt.fld_007 As transactdate | |
, acqt.fld_004 / 100 As amount | |
, acqt.fld_042 As merchant_id | |
, acqt.fld_002 As card_num | |
, acqt.reader_sn As reader_num | |
, acqt.mti As transtype | |
, acqt.card_type As brand | |
, COALESCE(uc.user_id, ue.client_id, 1010379) As client_id |