本文整理汇总了Python中Directory.create_meeting方法的典型用法代码示例。如果您正苦于以下问题:Python Directory.create_meeting方法的具体用法?Python Directory.create_meeting怎么用?Python Directory.create_meeting使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Directory
的用法示例。
在下文中一共展示了Directory.create_meeting方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: send_administrator_home
# 需要导入模块: import Directory [as 别名]
# 或者: from Directory import create_meeting [as 别名]
#.........这里部分代码省略.........
text = encode(text);
window.location.href = "''' + request.cgi_href(_adminaction='editmeetingname', itemid=None, global_meetingid=None, meetingname=None) + '''&global_meetingid=" + global_meetingid + "&meetingname=" + text;
}
}
}
function deleteMeeting(mtginfo) {
parseSelectedMeeting(mtginfo);
if (global_meetingid == '') {
alert("Please select a program.");
}else if (confirm("Delete this program and all associated data?")) {
window.location.href="''' + request.cgi_href(_adminaction='delitem', id=None) + '''&id=" + global_meetingid;
}
}
function editUser(urinfo) {
var selectedUser = 'userinfo_' + urinfo;
var userid = urinfo;
if (userid == '') {
alert('Please select a user to edit');
}else{
window.location.href="''' + request.cgi_href(_adminaction="edituser", userid=None) + '''&userid=" + userid;
}
}
function deleteUser(urinfo) {
var selectedUser = 'userinfo_' + urinfo;
var userid = urinfo;
if (userid == '') {
alert('Please select a non-administrator user to delete');
}else{
if (confirm('Delete this user?')) {
window.location.href="''' + request.cgi_href(_adminaction="deluser", userid=None) + '''&userid=" + userid;
}
}
}
//-->
</script>
</head>
''')
# switch based upon the action
action = request.getvalue('_adminaction', '')
if action == 'edituser':
self.edit_user(request)
self.main_page(request)
elif action == 'deluser':
self.del_user(request)
self.main_page(request)
elif action == 'delitem':
self.del_item(request)
self.main_page(request)
elif action == 'saveuser':
self.save_user(request)
self.main_page(request)
elif action == 'generateusers':
self.generate_users(request)
elif action == 'dogenerateusers':
self.do_generate_users(request)
self.main_page(request)
elif action == 'dodeleteusers':
self.do_delete_users(request)
self.main_page(request)
elif action == 'exportusers':
self.export_users(request)
elif action == 'newmeeting':
meeting = Directory.create_meeting(request.getvalue('meetingname', ''), request.getvalue('meetingview', ''), request.session.user.id)
meeting.type = BaseView.MEETING_ROOT_ITEM
meeting.status = 0
meeting.save()
log.info(str(meeting))
groups = datagate.create_item(creatorid=request.session.user.id, parentid=meeting.id)
groups.name='groups'
groups.save()
# allow the view to initialize itself
BaseView.views[meeting.view.lower()].initialize_activity(request, meeting)
self.main_page(request)
elif action == 'editmeetingname':
meeting = datagate.get_item(request.getvalue('global_meetingid', ''))
meeting.name = request.getvalue('meetingname')
meeting.save()
log.info(str(meeting))
self.main_page(request)
else:
self.main_page(request)
# page footer
request.writeln("</body></html>")