Skip to content

Commit

Permalink
X2.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
simplewindorg committed Sep 29, 2016
1 parent 469bd79 commit 031225c
Show file tree
Hide file tree
Showing 10 changed files with 37 additions and 22 deletions.
6 changes: 6 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
如何贡献我的源代码
===

此文档介绍了 ThinkCMF 团队的组成以及运转机制,您提交的代码将给 ThinkCMF 项目带来什么好处,以及如何才能加入我们的行列。

## 通过 Github 贡献代码
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ ThinkCMF是一款基于PHP+MYSQL开发的中文内容管理框架。ThinkCMF提
文档:http://www.thinkcmf.com/document

## UPDATE
### X2.2.0 Beta2
### X2.2.0
[Core]
* 增加wind.js可以自定义重写js,css的版本
* 增加$_GET统一urldecode
Expand Down
1 change: 1 addition & 0 deletions admin/themes/simplebootx/Admin/Setting/site.html
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@
<div class="control-group">
<label class="control-label">{:L('WEBSITE_ADMIN_THEME')}</label>
<div class="controls">
<php>$site_adminstyle=empty($site_adminstyle)?'flat':$site_adminstyle;</php>
<select name="options[site_adminstyle]">
<foreach name="adminstyles" item="vo">
<php>$adminstyle_selected=$site_adminstyle==$vo?"selected":"";</php>
Expand Down
4 changes: 2 additions & 2 deletions admin/themes/simplebootx/Portal/AdminPage/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
</form>
<form class="js-ajax-form" method="post">
<div class="table-actions">
<button class="btn btn-primary btn-small js-ajax-submit" type="submit" data-action="{:U('AdminPage/delete')}" data-subcheck="true" data-msg="{:L('DELETE_CONFIRM_MESSAGE')}">{:L('DELETE')}</button>
<button class="btn btn-danger btn-small js-ajax-submit" type="submit" data-action="{:U('AdminPage/delete')}" data-subcheck="true" data-msg="{:L('DELETE_CONFIRM_MESSAGE')}">{:L('DELETE')}</button>
</div>
<table class="table table-hover table-bordered table-list">
<thead>
Expand Down Expand Up @@ -56,7 +56,7 @@
</tfoot>
</table>
<div class="table-actions">
<button class="btn btn-primary btn-small js-ajax-submit" type="submit" data-action="{:U('AdminPage/delete')}" data-subcheck="true" data-msg="你确定删除吗?">{:L('DELETE')}</button>
<button class="btn btn-danger btn-small js-ajax-submit" type="submit" data-action="{:U('AdminPage/delete')}" data-subcheck="true" data-msg="你确定删除吗?">{:L('DELETE')}</button>
</div>
<div class="pagination">{$page}</div>
</form>
Expand Down
9 changes: 7 additions & 2 deletions admin/themes/simplebootx/User/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,13 @@
<td>{$vo.last_login_ip}</td>
<td>{$user_statuses[$vo['user_status']]}</td>
<td align="center">
<a href="{:U('indexadmin/ban',array('id'=>$vo['id']))}" class="js-ajax-dialog-btn" data-msg="{:L('BLOCK_USER_CONFIRM_MESSAGE')}">{:L('BLOCK_USER')}</a>|
<a href="{:U('indexadmin/cancelban',array('id'=>$vo['id']))}" class="js-ajax-dialog-btn" data-msg="{:L('ACTIVATE_USER_CONFIRM_MESSAGE')}">{:L('ACTIVATE_USER')}</a>
<noteq name="vo.id" value="1">
<a href="{:U('indexadmin/ban',array('id'=>$vo['id']))}" class="js-ajax-dialog-btn" data-msg="{:L('BLOCK_USER_CONFIRM_MESSAGE')}">{:L('BLOCK_USER')}</a>|
<a href="{:U('indexadmin/cancelban',array('id'=>$vo['id']))}" class="js-ajax-dialog-btn" data-msg="{:L('ACTIVATE_USER_CONFIRM_MESSAGE')}">{:L('ACTIVATE_USER')}</a>
<else/>
<a style="color: #ccc;">{:L('BLOCK_USER')}</a>|
<a style="color: #ccc;">{:L('ACTIVATE_USER')}</a>
</noteq>
</td>
</tr>
</foreach>
Expand Down
28 changes: 13 additions & 15 deletions application/User/Controller/IndexadminController.class.php
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
<?php

/**
* 会员
*/
namespace User\Controller;

use Common\Controller\AdminbaseController;

class IndexadminController extends AdminbaseController {
function index(){

public function index(){
$where=array();
$request=I('request.');

Expand Down Expand Up @@ -42,25 +40,25 @@ function index(){
$this->display(":index");
}

function ban(){
$id=intval($_GET['id']);
public function ban(){
$id= I('get.id',0,'intval');
if ($id) {
$rst = M("Users")->where(array("id"=>$id,"user_type"=>2))->setField('user_status','0');
if ($rst) {
$result = M("Users")->where(array("id"=>$id,"user_type"=>2))->setField('user_status',0);
if ($result) {
$this->success("会员拉黑成功!", U("indexadmin/index"));
} else {
$this->error('会员拉黑失败!');
$this->error('会员拉黑失败,会员不存在,或者是管理员');
}
} else {
$this->error('数据传入失败!');
}
}

function cancelban(){
$id=intval($_GET['id']);
public function cancelban(){
$id= I('get.id',0,'intval');
if ($id) {
$rst = M("Users")->where(array("id"=>$id,"user_type"=>2))->setField('user_status','1');
if ($rst) {
$result = M("Users")->where(array("id"=>$id,"user_type"=>2))->setField('user_status',1);
if ($result) {
$this->success("会员启用成功!", U("indexadmin/index"));
} else {
$this->error('会员启用失败!');
Expand Down
4 changes: 4 additions & 0 deletions config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
name: thinkcmf
version: 1
handle:
- rewrite: if(!is_dir() && !is_file() && path~"^(.*)$") goto "/index.php/$1"
2 changes: 1 addition & 1 deletion index.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ function stripslashesRecursive(array $array){
//静态缓存目录
define("HTML_PATH", SITE_PATH . "data/runtime/Html/");
//版本号
define("THINKCMF_VERSION", 'X2.2 Beta3');
define("THINKCMF_VERSION", 'X2.2.0');

define("THINKCMF_CORE_TAGLIBS", 'cx,Common\Lib\Taglib\TagLibSpadmin,Common\Lib\Taglib\TagLibHome');

Expand Down
1 change: 1 addition & 0 deletions public/js/jquery.validate/jquery.validate.js
Original file line number Diff line number Diff line change
Expand Up @@ -1349,6 +1349,7 @@ $.extend( $.validator, {

// http://jqueryvalidation.org/date-method/
date: function( value, element ) {
value = value.replace(/-/g,'/');//for safari only support date 2016/05/20
return this.optional( element ) || !/Invalid|NaN/.test( new Date( value ).toString() );
},

Expand Down
2 changes: 1 addition & 1 deletion themes/simplebootx_en-us/Portal/index.html
Original file line number Diff line number Diff line change
@@ -1 +1 @@
just a demo!
just a demo for multi lang user! LANG IS en-us;

0 comments on commit 031225c

Please sign in to comment.