Merge branch 'dev_aliyun' of https://bdgit.educoder.net/Hjqreturn/educoder into develop

# Conflicts:
#	public/assets/.sprockets-manifest-4627fa5586ef7fed55ca286af7c028e9.json
dev_home
杨树明 5 years ago
commit f49877e7e1

@ -24,7 +24,7 @@
background: unset;
}
/* 内容表格 */
/* 内容表格 */
table {
table-layout: fixed;
@ -100,6 +100,14 @@
}
}
.admin-list-container {
overflow-x: scroll;
& > table {
min-width: 900px;
}
}
.global-error {
color: grey;
min-height: 300px;
@ -124,7 +132,6 @@
}
.batch-action-container {
margin-bottom: -15px;
padding: 10px 20px 0;
background: #fff;
}

@ -124,7 +124,6 @@
}
.batch-action-container {
margin-bottom: -15px;
padding: 10px 20px 0;
background: #fff;
}

@ -31,7 +31,7 @@
}
&-item {
padding: 5px 15px;
padding: 5px 10px;
display: flex;
flex-direction: column;
align-items: center;

@ -124,7 +124,6 @@
}
.batch-action-container {
margin-bottom: -15px;
padding: 10px 20px 0;
background: #fff;
}

@ -26,6 +26,7 @@ class PartnersController < ApplicationController
if params[:manager_group_id].present?
# 重命名
@manager_group = current_partner.partner_manager_groups.find(params[:manager_group_id])
return render_error('不能修改管理者权限组名称') if @manager_group.admin?
@manager_group.update!(name: name)
else
# 新建
@ -35,6 +36,7 @@ class PartnersController < ApplicationController
def remove_manager_group
manager_group = current_partner.partner_manager_groups.find(params[:manager_group_id])
return render_error('不能删除管理者权限组') if manager_group.admin?
manager_group.destroy!
render_delete_success
@ -57,6 +59,8 @@ class PartnersController < ApplicationController
def remove_partner_manager
partner_manager = current_partner.partner_managers.find(params[:manager_id])
return render_error('不能删除自己') if partner_manager.user_id == current_user.id && partner_manager.partner_manager_group.admin?
partner_manager.destroy!
render_delete_success

@ -17,6 +17,6 @@ class Users::AuthenticationAppliesController < Users::BaseAccountController
private
def create_params
params.permit(:name, :gender, :id_number, :upload_image, attachment_ids: [])
params.permit(:name, :show_realname, :gender, :id_number, :upload_image, attachment_ids: [])
end
end

@ -1,7 +1,7 @@
class Users::ApplyAuthenticationForm
include ActiveModel::Model
attr_accessor :name, :id_number, :gender, :upload_image, :attachment_ids
attr_accessor :name, :show_realname, :id_number, :gender, :upload_image, :attachment_ids
validates :name, presence: true
validate :validate_ID_number

@ -15,6 +15,7 @@ class Users::ApplyAuthenticationService < ApplicationService
user.lastname = params[:name].to_s.strip
user.firstname = ''
user.ID_number = params[:id_number].to_s.strip.presence
user.show_realname = params[:show_realname].to_s == 'true' if params[:show_realname].to_s.present?
ActiveRecord::Base.transaction do
user.authentication = false

@ -6,7 +6,7 @@
<%= javascript_void_link '新增', class: 'btn btn-primary', data: { toggle: 'modal', target: '.auth-schools-new-add' } %>
</div>
<div class="box auth-schools-list-container">
<div class="box admin-list-container auth-schools-list-container">
<%= render(partial: 'admins/auth_schools/shared/list', locals: { schools: @schools }) %>
</div>

@ -59,6 +59,6 @@
</div>
</div>
<div class="box competition-prize-user-list-container">
<div class="box admin-list-container competition-prize-user-list-container">
<%= render(partial: 'admins/competition_prize_users/shared/list', locals: { prize_users: @prize_users }) %>
</div>

@ -25,7 +25,7 @@
</div>
</div>
<div class="box competitions-list-container">
<div class="box admin-list-container competitions-list-container">
<%= render partial: 'admins/competitions/shared/list', locals: { competitions: @competitions } %>
</div>

@ -12,7 +12,7 @@
<%= javascript_void_link('添加', class: 'btn btn-primary', data: { toggle: 'modal', target: '.admin-select-school-modal' }) %>
</div>
<div class="box customer-list-container">
<div class="box admin-list-container customer-list-container">
<%= render 'admins/customers/shared/list', customers: @customers %>
</div>

@ -24,6 +24,6 @@
其它作业总数<span class="text-danger"><%= @other_homework_total %></span>个
</div>
<div class="box daily-school-statistic-list-container">
<div class="box admin-list-container daily-school-statistic-list-container">
<%= render partial: 'admins/daily_school_statistics/shared/list', locals: { statistics: @statistics } %>
</div>

@ -10,7 +10,7 @@
<% end %>
</div>
<div class="box department-applies-list-container">
<div class="box admin-list-container department-applies-list-container">
<%= render(partial: 'admins/department_applies/shared/list', locals: { applies: @depart_applies }) %>
</div>

@ -23,7 +23,7 @@
<%= javascript_void_link '新建部门', class: 'btn btn-primary', data: { toggle: 'modal', target: '.admin-create-department-modal' } %>
</div>
<div class="box department-list-container">
<div class="box admin-list-container department-list-container">
<%= render partial: 'admins/departments/shared/list',
locals: { departments: @departments, users_count: @users_count, professional_auth_count: @professional_auth_count } %>
</div>

@ -7,7 +7,7 @@
</div>
<div class="box ec-templates-list-container">
<div class="box admin-list-container ec-templates-list-container">
<%= render(partial: 'admins/ec_templates/shared/list', locals: { templates: @templates }) %>
</div>

@ -28,6 +28,6 @@
</div>
</div>
<div class="box competition-enroll-list-container">
<div class="box admin-list-container competition-enroll-list-container">
<%= render(partial: 'admins/enroll_lists/list', locals: { enroll_lists: @enroll_lists }) %>
</div>

@ -7,7 +7,7 @@
id: "-1", content: "", msg: "添加" } %>
</div>
<div class="box graduation-standards-list-container">
<div class="box admin-list-container graduation-standards-list-container">
<%= render(partial: 'admins/graduation_standards/shared/list', locals: { standards: @standards }) %>
</div>

@ -29,7 +29,7 @@
<%= javascript_void_link '批量同意', class: 'btn btn-outline-primary btn-sm batch-agree-btn' %>
</div>
<div class="box identity-authentication-list-container">
<div class="box admin-list-container identity-authentication-list-container">
<%= render(partial: 'admins/identity_authentications/shared/list', locals: { applies: @applies }) %>
</div>

@ -11,7 +11,7 @@
<%= javascript_void_link '新建', class: 'btn btn-primary', data: { toggle: 'modal', target: '.admin-create-laboratory-modal' } %>
</div>
<div class="box laboratory-list-container">
<div class="box admin-list-container laboratory-list-container">
<%= render(partial: 'admins/laboratories/shared/list', locals: { laboratories: @laboratories }) %>
</div>

@ -38,7 +38,7 @@
<%= javascript_void_link('添加实训', class: 'btn btn-primary', data: { toggle: 'modal', target: '.admin-add-laboratory-shixun-modal' }) %>
</div>
<div class="box laboratory-shixun-list-container" data-id="<%= current_laboratory.id %>">
<div class="box admin-list-container laboratory-shixun-list-container" data-id="<%= current_laboratory.id %>">
<%= render partial: 'admins/laboratory_shixuns/shared/list', locals: { laboratory_shixuns: @laboratory_shixuns } %>
</div>

@ -38,7 +38,7 @@
<%= javascript_void_link('添加课程', class: 'btn btn-primary', data: { toggle: 'modal', target: '.admin-add-laboratory-subject-modal' }) %>
</div>
<div class="box laboratory-subject-list-container" data-id="<%= current_laboratory.id %>">
<div class="box admin-list-container laboratory-subject-list-container" data-id="<%= current_laboratory.id %>">
<%= render partial: 'admins/laboratory_subjects/shared/list', locals: { laboratory_subjects: @laboratory_subjects } %>
</div>

@ -25,7 +25,7 @@
<% end %>
</div>
<div class="box library-applies-list-container">
<div class="box admin-list-container library-applies-list-container">
<%= render(partial: 'admins/library_applies/shared/list', locals: { applies: @library_applies }) %>
</div>

@ -2,6 +2,6 @@
<% add_admin_breadcrumb('本科专业目录') %>
<% end %>
<div class="box major-informations-list-container">
<div class="box admin-list-container major-informations-list-container">
<%= render(partial: 'admins/major_informations/shared/list', locals: { majors: @disciplines }) %>
</div>

@ -16,7 +16,7 @@
</div>
<% end %>
<div class="box mirror-repository-list-container">
<div class="box admin-list-container mirror-repository-list-container">
<%= render partial: 'admins/mirror_repositories/shared/list', locals: { mirrors: @mirrors } %>
</div>

@ -9,6 +9,6 @@
<%= link_to '新建', new_admins_mirror_repository_mirror_script_path(current_mirror), class: 'btn btn-primary' %>
</div>
<div class="box mirror-script-list-container">
<div class="box admin-list-container mirror-script-list-container">
<%= render partial: 'admins/mirror_scripts/shared/list', locals: { mirror: current_mirror, scripts: @scripts } %>
</div>

@ -9,6 +9,6 @@
<% end %>
</div>
<div class="box myshixun-list-container">
<div class="box admin-list-container myshixun-list-container">
<%= render(partial: 'admins/myshixuns/shared/list', locals: { myshixuns: @myshixuns, finish_game_count: @finish_game_count, total_score: @total_score }) %>
</div>

@ -11,7 +11,7 @@
<%= javascript_void_link('添加', class: 'btn btn-primary', data: { toggle: 'modal', target: '.admin-select-school-modal' }) %>
</div>
<div class="box partner-list-container">
<div class="box admin-list-container partner-list-container">
<%= render 'admins/partners/shared/list', partners: @partners %>
</div>

@ -29,7 +29,7 @@
<%= javascript_void_link '批量同意', class: 'btn btn-outline-primary btn-sm batch-agree-btn' %>
</div>
<div class="box professional-authentication-list-container">
<div class="box admin-list-container professional-authentication-list-container">
<%= render(partial: 'admins/professional_authentications/shared/list', locals: { applies: @applies }) %>
</div>

@ -25,7 +25,7 @@
<% end %>
</div>
<div class="box project-package-applies-list-container">
<div class="box admin-list-container project-package-applies-list-container">
<%= render(partial: 'admins/project_package_applies/shared/list', locals: { applies: @package_applies}) %>
</div>

@ -44,6 +44,6 @@
</form>
</div>
<div class="box school-statistic-list-container">
<div class="box admin-list-container school-statistic-list-container">
<%= render partial: 'admins/school_statistics/shared/list', locals: { statistics: @statistics } %>
</div>

@ -11,6 +11,6 @@
<%#= javascript_void_link '新建单位', class: 'btn btn-primary', data: { toggle: 'modal', target: '.admin-create-school-modal' } %>
</div>
<div class="box school-list-container">
<div class="box admin-list-container school-list-container">
<%= render partial: 'admins/schools/shared/list', locals: { schools: @schools } %>
</div>

@ -25,7 +25,7 @@
<% end %>
</div>
<div class="box shixun-authorization-list-container">
<div class="box admin-list-container shixun-authorization-list-container">
<%= render(partial: 'admins/shixun_authorizations/shared/list', locals: { applies: @applies, shixun_map: @shixun_map }) %>
</div>

@ -69,7 +69,7 @@
<% end %>
</div>
<div class="box shixun-settings-list-container">
<div class="box admin-list-container shixun-settings-list-container">
<%= render partial: 'admins/shixun_settings/shared/list', locals: { shixun_settings: @shixun_settings } %>
</div>

@ -27,6 +27,6 @@
<a href="javascript:void(0)" class="btn btn-primary" id="shixuns-export" data-disable-with = '导出中...'>导出</a>
</div>
<div class="box shixuns-list-container">
<div class="box admin-list-container shixuns-list-container">
<%= render partial: 'admins/shixuns/shared/list', locals: { shixuns: @shixuns } %>
</div>

@ -25,7 +25,7 @@
<% end %>
</div>
<div class="box subject-authorization-list-container">
<div class="box admin-list-container subject-authorization-list-container">
<%= render(partial: 'admins/subject_authorizations/shared/list',
locals: { applies: @applies, subject_map: @subject_map, challenge_count_map: @challenge_count_map }) %>
</div>

@ -34,7 +34,7 @@
<% end %>
</div>
<div class="box subject-list-container">
<div class="box admin-list-container subject-list-container">
<%= render partial: 'admins/subjects/shared/list', locals: { subjects: @subjects } %>
</div>

@ -22,6 +22,6 @@
<%= javascript_void_link '导出', class: 'btn btn-outline-primary export-action', 'data-url': export_admins_user_statistics_path(format: :xlsx) %>
</div>
<div class="box user-statistic-list-container">
<div class="box admin-list-container user-statistic-list-container">
<%= render partial: 'admins/user_statistics/shared/list', locals: { users: @users } %>
</div>

@ -31,7 +31,7 @@
<%= javascript_void_link '导入课堂成员', class: 'btn btn-secondary btn-sm ml-2', data: { toggle: 'modal', target: '.admin-import-course-member-modal'} %>
</div>
<div class="box users-list-container">
<div class="box admin-list-container users-list-container">
<%= render partial: 'admins/users/shared/user_list', locals: { users: @users } %>
</div>

@ -25,7 +25,7 @@
<% end %>
</div>
<div class="box video-applies-list-container">
<div class="box admin-list-container video-applies-list-container">
<%= render(partial: 'admins/video_applies/shared/list', locals: { applies: @video_applies}) %>
</div>

@ -35,7 +35,7 @@
<% end %>
</div>
<div class="box laboratory-shixun-list-container">
<div class="box admin-list-container laboratory-shixun-list-container">
<%= render partial: 'cooperative/laboratory_shixuns/shared/list', locals: { laboratory_shixuns: @laboratory_shixuns } %>
</div>

@ -35,7 +35,7 @@
<% end %>
</div>
<div class="box laboratory-subject-list-container">
<div class="box admin-list-container laboratory-subject-list-container">
<%= render partial: 'cooperative/laboratory_subjects/shared/list', locals: { laboratory_subjects: @laboratory_subjects } %>
</div>

@ -7,7 +7,7 @@
<%= javascript_void_link '添加管理员', class: 'btn btn-primary btn-sm', data: { toggle: 'modal', target: '.cooperative-add-laboratory-user-modal'} %>
</div>
<div class="box laboratory-user-list-container">
<div class="box admin-list-container laboratory-user-list-container">
<%= render partial: 'cooperative/laboratory_users/shared/list', locals: { laboratory_users: @laboratory_users } %>
</div>

@ -4,11 +4,13 @@
<% manager_group.partner_managers.each do |manager| %>
<div class="partner-manager-item partner-manager-item-<%= manager.id %>">
<%= delete_link 'x',
remove_partner_manager_partner_path(current_partner, manager_id: manager.id, element: ".partner-manager-item-#{manager.id}"),
data: { toggle: 'tooltip', title: '删除' },
class: 'remove-partner-manager-action' do %>
<i class="fa fa-times-circle"></i>
<% if !manager_group.admin? || manager.user_id != current_user.id %>
<%= delete_link 'x',
remove_partner_manager_partner_path(current_partner, manager_id: manager.id, element: ".partner-manager-item-#{manager.id}"),
data: { toggle: 'tooltip', title: '删除' },
class: 'remove-partner-manager-action' do %>
<i class="fa fa-times-circle"></i>
<% end %>
<% end %>
<%= link_to "/users/#{manager.user.login}", data: { toggle: 'tooltip', title: '查看个人主页' },

File diff suppressed because one or more lines are too long

@ -25558,32 +25558,42 @@ input.form-control {
}
/* line 103, app/assets/stylesheets/admins/common.scss */
.admin-body-container .admin-list-container {
overflow-x: scroll;
}
/* line 106, app/assets/stylesheets/admins/common.scss */
.admin-body-container .admin-list-container > table {
min-width: 900px;
}
/* line 111, app/assets/stylesheets/admins/common.scss */
.admin-body-container .global-error {
color: grey;
min-height: 300px;
}
/* line 107, app/assets/stylesheets/admins/common.scss */
/* line 115, app/assets/stylesheets/admins/common.scss */
.admin-body-container .global-error-code {
font-size: 80px;
}
/* line 111, app/assets/stylesheets/admins/common.scss */
/* line 119, app/assets/stylesheets/admins/common.scss */
.admin-body-container .global-error-text {
font-size: 24px;
}
/* line 117, app/assets/stylesheets/admins/common.scss */
/* line 125, app/assets/stylesheets/admins/common.scss */
.admin-body-container .nav-tabs .nav-link {
padding: 0.5rem 2rem;
}
/* line 122, app/assets/stylesheets/admins/common.scss */
/* line 130, app/assets/stylesheets/admins/common.scss */
.admin-body-container .CodeMirror {
border: 1px solid #ced4da;
}
/* line 126, app/assets/stylesheets/admins/common.scss */
/* line 134, app/assets/stylesheets/admins/common.scss */
.admin-body-container .batch-action-container {
margin-bottom: -15px;
padding: 10px 20px 0;

@ -17065,7 +17065,7 @@ input.form-control {
/* line 33, app/assets/stylesheets/colleges/partner_manager_groups.scss */
.partners-partner-manager-groups-page .partner-manager-item {
padding: 5px 15px;
padding: 5px 10px;
display: -webkit-box;
display: flex;
-webkit-box-orient: vertical;

@ -56,13 +56,14 @@ class RegisListviewdata extends React.Component {
</div>
<div style={{
marginTop: "29px",
marginLeft: "37px"
}}>
marginLeft: "37px",
width: "160px",
textAlign: "center",
}} className="textsize">
{
this.props.admin?
this.props.admin===true?
<a className="maxnamewidth160" title={item.name} style={{
color: "#05101A",
<a className="maxnamewidth160" title={item.name} style={{
fontSize: "16px",
width: "160px",
textAlign: "center",

@ -838,7 +838,9 @@ reglistviewdivs2 {
}
.maxnamewidth78 {
max-width: 78px;
width: 78px !important;
max-width: 78px !important;
min-width: 78px !important;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
@ -870,7 +872,9 @@ reglistviewdivs2 {
.maxnamewidth160 {
max-width: 160px;
width: 160px !important;
min-width:160px !important;
max-width: 160px !important;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
@ -885,4 +889,12 @@ reglistviewdivs2 {
cursor: default;
}
/*文字长度限制?*/
/*文字长度限制?*/
.textsize{
width: 160px !important;
min-width: 160px !important;
max-width: 160px !important;
text-align: center;
}

@ -87,15 +87,16 @@ class Exercisestatisticalresult extends Component {
funtaskstatustwo=(checkedValues,list)=>{
let{sort,page,limit}=this.state;
if(checkedValues.length===list.length){
this.setState({
exercise_group_id:[]
})
}else{
this.setState({
exercise_group_id:checkedValues
})
}
// if(checkedValues.length===list.length){
// this.setState({
// exercise_group_id:[]
// })
// }else{
//
// }
this.setState({
exercise_group_id:checkedValues
})
this.updatefun(sort,checkedValues,page,limit)
}
@ -144,7 +145,7 @@ class Exercisestatisticalresult extends Component {
<span className="fl ">
<a id="graduation_comment_no_limit"
className={this.state.exercise_group_id.length === 0 ? "pl10 pr10 mr20 check_on" : "pl10 pr10 mr20"}
onClick={() => this.alldatalist()}>不限</a>
onClick={() => this.alldatalist()}>全部</a>
</span>
<CheckboxGroup onChange={(e)=>this.funtaskstatustwo(e,data&&data.course_groups)} value={this.state.exercise_group_id} style={{width:'87%',paddingTop: '4px'}}>
{ data&&data.course_groups.map((item, key) => {

@ -229,6 +229,9 @@ render() {
}
.ant-dropdown-menu-item, .ant-dropdown-menu-submenu-title{
padding: 0px 12px;
}
.ant-dropdown-menu-item:hover, .ant-dropdown-menu-submenu-title:hover{
background:transparent !important;
}
`
}

@ -4,7 +4,7 @@ import { SnackbarHOC, getImageUrl, City, ConditionToolTip } from 'educoder';
import { Form, Button, Input, Radio, Select, Tooltip, Icon, AutoComplete } from 'antd'
const RadioGroup = Radio.Group;
const Option = Select.Option;
class AccpimtBasicEditItem extends Component {
class AccountBasicEditItem extends Component {
constructor(props){
super(props);
}
@ -196,4 +196,4 @@ class AccpimtBasicEditItem extends Component {
)
}
}
export default AccpimtBasicEditItem;
export default AccountBasicEditItem;

@ -257,10 +257,10 @@ class RealNameCertificationModal extends Component{
onSendOk = () => {
this.props.form.validateFieldsAndScroll((err, values) => {
console.log(values);
console.log(this.state.department_id);
// console.log(values);
// console.log(this.state.realName);
if(!err){
let{imageUrl2}=this.state;
let{imageUrl2,showRealName}=this.state;
let{current_user,basicInfo}=this.props;
if(imageUrl2){
let { certification } = this.props;
@ -268,9 +268,10 @@ class RealNameCertificationModal extends Component{
// 实名认证
let url = `/users/accounts/${current_user && current_user.login}/authentication_apply.json`
axios.post((url),{
name:values.name || basicInfo.name,
name:this.state.realName || basicInfo.name,
gender:parseInt(values.sex),
id_number:values.credentials,
show_realname:showRealName,
attachment_ids:[this.state.fileID]
}).then((result)=>{
if(result){
@ -692,7 +693,7 @@ class RealNameCertificationModal extends Component{
</div>
:
<AccountBasicEditItem
identity={identity}
identity={identity}
getFieldDecorator={getFieldDecorator}
professionalFlag={professionalFlag}
basicInfo={basicInfo}

Loading…
Cancel
Save