- int
- real
- string
- list
- qml object type
- qml basic type
This file contains 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
# remove current vim | |
sudo apt-get remove --purge vim vim-runtime vim-gnome vim-tiny vim-gui-common | |
# removes current link for vim | |
sudo rm -rf /usr/local/share/vim /usr/bin/vim | |
# add ppa for newest version of ruby (currently, as of 06/06/2017, ruby v2.4) | |
sudo apt-add-repository ppa:brightbox/ruby-ng | |
sudo apt-get update |
This file contains 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
var temp = $("<input type='text' value='" + mediaId + "'/>"); | |
temp.appendTo('body'); | |
temp.select();//选中元素 | |
if(document.execCommand('copy')){ | |
layer.msg('media_id已复制到剪切板!'); | |
}else{ | |
layer.msg('复制到剪切板失败!'); | |
} | |
temp.remove(); |
This file contains 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
<?php | |
//需要数据的键与子项目id相同 | |
$arr = [ | |
1 => [ | |
"id" => 1, | |
"pid" => 0, | |
"value" => 1 | |
], | |
2 => [ | |
"id" => 2, |
This file contains 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
set normal (set_color normal) | |
set magenta (set_color magenta) | |
set yellow (set_color yellow) | |
set green (set_color green) | |
set red (set_color red) | |
set gray (set_color -o black) | |
# Fish git prompt | |
set __fish_git_prompt_showdirtystate 'yes' | |
set __fish_git_prompt_showstashstate 'yes' |
This file contains 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 apt-get install fonts-droid-fallback ttf-wqy-zenhei ttf-wqy-microhei fonts-arphic-ukai fonts-arphic-uming |
This file contains 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
<?php | |
/** | |
* author jianglong | |
* date 2019/8/13 上午9:10 | |
*/ | |
/** | |
* Class AbstractFactory | |
* |
This file contains 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
<?php | |
class Date { | |
//月转化为周 | |
private function month2Week(int $year, int $month): array | |
{ | |
$start = 1; | |
$end = date('d', strtotime(date("{$year}-{$month}-01") . ' + 1 month - 1 day')); | |
$days = range($start, $end); | |
return array_chunk($days, 7); | |
} |
This file contains 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
<?php | |
trait Camel2Snake | |
{ | |
public function camel2Snake(string $camel): string | |
{ | |
return strtolower(preg_replace('/(?<=[a-z])([A-Z])/', '_$1', $camel)); | |
} | |
} |
This file contains 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
<?php | |
/** | |
* author jianglong | |
* date 2019/8/5 下午5:00 | |
*/ | |
/** | |
* 文件锁 | |
* Trait FileLock |
OlderNewer