快 捷 圈 子 2

北京学生综合素质评价发圈子一次性完成

  1. // ==UserScript==
  2. // @name 快 捷 圈 子 2
  3. // @namespace https://gf.qytechs.cn/users/904812
  4. // @version 0.1
  5. // @description 北京学生综合素质评价发圈子一次性完成
  6. // @author 2222234
  7. // @match https://zhsz.bjedu.cn/web/index/index
  8. // @grant none
  9. // @license GNU Affero General Public License v3.0
  10.  
  11. // ==/UserScript==
  12.  
  13. $(function(){
  14. var h = document.documentElement.clientHeight;
  15.  
  16. var Data = vmMomentsData;
  17.  
  18. var open = document.createElement("div");
  19. window.document.body.append(open);
  20. open.id="open";
  21. open.innerHTML=">";
  22. open.style.left = "0px";
  23. open.style.top="40%";
  24. open.style.width = "30px";
  25. open.style.height = "30px";
  26. open.style.backgroundColor = "rgba(0, 0, 0, 0.25)";
  27. open.style.position = "fixed";
  28. open.style.zIndex = "114514";
  29. open.style.fontSize="25px";
  30. open.style.lineHeight="30px";
  31. open.style.textAlign="center";
  32. var o = false;
  33.  
  34. var send = document.createElement("div");
  35. window.document.body.append(send);
  36. send.id="send";
  37. send.style.left = "-250px";
  38. send.style.top="0px";
  39. send.style.width = "250px";
  40. send.style.height = "100%";
  41. send.style.backgroundColor = "rgba(0, 0, 0, 0.25)";
  42. send.style.position = "fixed";
  43. send.style.zIndex = "114514";
  44. send.style.visibility="hidden";
  45.  
  46. var moments = document.createElement("form");
  47. send.append(moments);
  48. moments.id="moments";
  49. moments.style.left = "25px";
  50. moments.style.top="65px";
  51. moments.style.width = "200px";
  52. moments.style.height = 0.6*h+"px";
  53. moments.style.overflow = "auto";
  54. moments.style.overflowX = "hidden";
  55. moments.style.position = "fixed";
  56.  
  57. var tagList = Data.tagList;
  58.  
  59. for(var tag = 0;tag<tagList.length;tag++){
  60. var moment = document.createElement("input");
  61. moment.name="ms";
  62. moment.style.width="100px";
  63. moment.style.backgroundColor="rgba(255, 255, 255, 0.5)";
  64. moments.innerHTML=moments.innerHTML+" "+tagList[tag].name+"<br>";
  65. moments.append(moment);
  66. moments.innerHTML=moments.innerHTML+"<br>";
  67. }
  68.  
  69. var write = document.createElement("button");
  70. send.append(write);
  71. write.id="write";
  72. write.innerHTML="发表";
  73. write.style.left = "25px";
  74. write.style.top=0.6*h+90+"px";
  75. write.style.width = "150px";
  76. write.style.height = "50px";
  77. write.style.backgroundColor = "rgba(255,255,255,1)";
  78. write.style.position = "fixed";
  79. write.style.fontSize="25px";
  80. write.style.lineHeight="50px";
  81. write.style.textAlign="center";
  82.  
  83. var memberList = Data.curClassMemberList;
  84.  
  85. write.onclick=function(){
  86. var ms = document.getElementsByName('ms');
  87. if(confirm("使用?")){
  88. for(var i=0;i<tagList.length;i++){
  89. for(var i1 = 0;i1<ms[i].value;i1++){
  90. $.ajax({
  91. url: "/web/moments/addmoments",
  92. type: 'POST',
  93. data:{"content":function(){
  94. var text = "";
  95. for(var t = 0;t<20;t++){
  96. text+="同学们表现得都非常棒!";
  97. }
  98. return text;
  99. },
  100. "at_uids":function(){
  101. var ats = [];
  102. for(var mem = 0;mem<memberList.length;mem++){
  103. ats[mem]=memberList[mem].uid;
  104. }
  105. return ats;
  106. },
  107. "class_id":Data.curClass.id,
  108. "tag_id":tagList[i].id,
  109. "tag":tagList[i].name,
  110. "is_group":1
  111. },
  112. dataType: 'json',
  113. });
  114. }
  115. }
  116. }
  117. }
  118.  
  119. window.onresize=function(){
  120. h = document.documentElement.clientHeight;
  121. moments.style.height = 0.6*h+"px";
  122. write.style.top=0.6*h+90+"px";
  123. }
  124.  
  125. open.onmouseover=function(){
  126. open.style.backgroundColor = "rgba(0, 0, 0, 0.5)";
  127. }
  128. open.onmouseout=function(){
  129. open.style.backgroundColor = "rgba(0, 0, 0, 0.25)";
  130. }
  131.  
  132. open.onclick=function(){
  133. if(!o){
  134. open.style.left = "250px";
  135. open.innerHTML="<";
  136. send.style.left = "0px";
  137. send.style.visibility ="visible";
  138. o=true;
  139. }else{
  140. open.style.left = "0px";
  141. open.innerHTML=">";
  142. send.style.visibility ="hidden";
  143. o=false;
  144. }
  145. }
  146. });

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址