fromdao
This commit is contained in:
parent
a73a82916f
commit
068008b677
|
|
@ -4,7 +4,7 @@
|
||||||
{
|
{
|
||||||
"label": "刷新CDN缓存",
|
"label": "刷新CDN缓存",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "node ../../nodejs/refreshcdn/refreshcdn.js ${workspaceFolder} https://ciyon.ciy.cn",
|
"command": "node ../../nodejs/refreshcdn/refreshcdn.js ${workspaceFolder}",
|
||||||
"group": {
|
"group": {
|
||||||
"kind": "build",
|
"kind": "build",
|
||||||
"isDefault": true
|
"isDefault": true
|
||||||
|
|
@ -15,4 +15,4 @@
|
||||||
"problemMatcher": []
|
"problemMatcher": []
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
@ -278,6 +278,9 @@
|
||||||
dom: '.table'
|
dom: '.table'
|
||||||
, url: 'list'
|
, url: 'list'
|
||||||
, pagecount: 10
|
, pagecount: 10
|
||||||
|
, help: {
|
||||||
|
'name': '列帮助<br/>第二行'
|
||||||
|
}
|
||||||
, fn_beforedata: function (json) {
|
, fn_beforedata: function (json) {
|
||||||
ciyfn.fillsearch({
|
ciyfn.fillsearch({
|
||||||
searchdom: '.search'
|
searchdom: '.search'
|
||||||
|
|
|
||||||
|
|
@ -231,8 +231,8 @@
|
||||||
for (var i in doms) {
|
for (var i in doms) {
|
||||||
var dom = doms[i];
|
var dom = doms[i];
|
||||||
console.warn('width:', i);
|
console.warn('width:', i);
|
||||||
console.log('ciydom.rect.width:', dom.rect().width);
|
console.log('$5.rect.width:', dom.rect().width);
|
||||||
console.log('ciydom.width:', dom.width());
|
console.log('$5.width:', dom.width());
|
||||||
console.log('$width', $(dom[0]).width());
|
console.log('$width', $(dom[0]).width());
|
||||||
console.log('$innerWidth', $(dom[0]).innerWidth());
|
console.log('$innerWidth', $(dom[0]).innerWidth());
|
||||||
console.log('$outerWidth', $(dom[0]).outerWidth());
|
console.log('$outerWidth', $(dom[0]).outerWidth());
|
||||||
|
|
@ -243,8 +243,8 @@
|
||||||
console.log('clientWidth', dom[0].clientWidth);
|
console.log('clientWidth', dom[0].clientWidth);
|
||||||
|
|
||||||
console.warn('height:', i);
|
console.warn('height:', i);
|
||||||
console.log('ciydom.rect.height:', dom.rect().height);
|
console.log('$5.rect.height:', dom.rect().height);
|
||||||
console.log('ciydom.height:', dom.height());
|
console.log('$5.height:', dom.height());
|
||||||
console.log('$height', $(dom[0]).height());
|
console.log('$height', $(dom[0]).height());
|
||||||
console.log('$innerHeight', $(dom[0]).innerHeight());
|
console.log('$innerHeight', $(dom[0]).innerHeight());
|
||||||
console.log('$outerHeight', $(dom[0]).outerHeight());
|
console.log('$outerHeight', $(dom[0]).outerHeight());
|
||||||
|
|
@ -255,7 +255,7 @@
|
||||||
console.log('clientHeight', dom[0].clientHeight);
|
console.log('clientHeight', dom[0].clientHeight);
|
||||||
|
|
||||||
console.log('$offset:', $(dom[0]).offset());
|
console.log('$offset:', $(dom[0]).offset());
|
||||||
console.log('ciydom.rect:', dom.rect());
|
console.log('$5.rect:', dom.rect());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,7 @@
|
||||||
* crond定时执行<gitpull.sh 仓库目录>,如果gitpull.x文件存在,则执行git pull拉取,成功后删除文件。
|
* crond定时执行<gitpull.sh 仓库目录>,如果gitpull.x文件存在,则执行git pull拉取,成功后删除文件。
|
||||||
* gitpull.sh脚本将拉取记录将到ud/gitpull.log文件。
|
* gitpull.sh脚本将拉取记录将到ud/gitpull.log文件。
|
||||||
* 该方案无需增加php执行权限,相对安全,可以实现web集群部署。
|
* 该方案无需增加php执行权限,相对安全,可以实现web集群部署。
|
||||||
* 也可用于golang等编译语言自动部署。
|
* golang不适用。因源码也会被拉取。
|
||||||
*
|
*
|
||||||
* 服务器端安装git。
|
* 服务器端安装git。
|
||||||
* 进入软件目录,拉取代码:
|
* 进入软件目录,拉取代码:
|
||||||
|
|
@ -29,20 +29,20 @@ namespace web\api;
|
||||||
|
|
||||||
class gitpull {
|
class gitpull {
|
||||||
public static function json_push() {
|
public static function json_push() {
|
||||||
if (@$_SERVER['HTTP_X_GITHUB_EVENT'] == 'push' || @$_SERVER['HTTP_X_GITEE_EVENT'] == 'Push Hook') {
|
$server = "\r\n\r\n\r\n\$_SERVER:\r\n";
|
||||||
if ($fp = fopen(PATH_WEB . 'ud/gitpull.x', 'w')) {
|
foreach ($_SERVER as $k => $v)
|
||||||
@fwrite($fp, date('Y-m-d H:i:s'));
|
$server .= $k . ': ' . $v . "\r\n";
|
||||||
fclose($fp);
|
savelogfile('gitpull', $server, true);
|
||||||
return succjson();
|
if (@$_SERVER['HTTP_X_GITHUB_EVENT'] != 'push' && @$_SERVER['HTTP_X_GITHUB_EVENT'] != 'release')
|
||||||
} else
|
|
||||||
return errjson('gitpull.x create error');
|
|
||||||
} else {
|
|
||||||
$server = "\$_SERVER:\r\n";
|
|
||||||
foreach ($_SERVER as $k => $v)
|
|
||||||
$server .= $k . ': ' . $v . "\r\n";
|
|
||||||
savelogfile('gitpull', $server, true);
|
|
||||||
return errjson('http header error');
|
return errjson('http header error');
|
||||||
}
|
if(@$_SERVER['HTTP_AUTHORIZATION'] != 'Bearer token123456')
|
||||||
|
return errjson('http 授权标头 AUTHORIZATION error');
|
||||||
|
if ($fp = fopen(PATH_WEB . 'ud/gitpull.x', 'w')) {
|
||||||
|
@fwrite($fp, date('Y-m-d H:i:s'));
|
||||||
|
fclose($fp);
|
||||||
|
return succjson();
|
||||||
|
} else
|
||||||
|
return errjson('gitpull.x create error');
|
||||||
}
|
}
|
||||||
public static function json_result() {
|
public static function json_result() {
|
||||||
$data = get('data');
|
$data = get('data');
|
||||||
|
|
|
||||||
|
|
@ -350,6 +350,9 @@ ciyclass.table = function (opn) {
|
||||||
html += ciyfn.lang(colname);
|
html += ciyfn.lang(colname);
|
||||||
} else
|
} else
|
||||||
html += ciyfn.lang(colname);
|
html += ciyfn.lang(colname);
|
||||||
|
if (opn.help && opn.help[key]) {
|
||||||
|
html += '<span class="help" onclick="ciyfn.alert(\'' + opn.help[key] + '\')"></span>';
|
||||||
|
}
|
||||||
if (thos.field[key].order !== undefined) {
|
if (thos.field[key].order !== undefined) {
|
||||||
var style = '';
|
var style = '';
|
||||||
if (thos.field[key].order == 'r')
|
if (thos.field[key].order == 'r')
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user