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

dev_new_shixunsrepository
杨树林 5 years ago
commit f5df3423fa

@ -5,6 +5,7 @@ class AttachmentsController < ApplicationController
before_action :require_login, :check_auth, except: [:show] before_action :require_login, :check_auth, except: [:show]
before_action :find_file, only: %i[show destroy] before_action :find_file, only: %i[show destroy]
before_action :attachment_candown, only: [:show] before_action :attachment_candown, only: [:show]
skip_before_action :check_sign, only: [:show]
include ApplicationHelper include ApplicationHelper

@ -41,7 +41,7 @@ if (isDev) {
//ebugType="teacher"; //ebugType="teacher";
// 学生 // 学生
//debugType="student"; //debugType="student";
window.railsgettimes = function(proxy) { function railsgettimes(proxy) {
if(timestamp&&checkSubmitFlg===false){ if(timestamp&&checkSubmitFlg===false){
$.ajax({url:proxy,async:false,success:function(data){ $.ajax({url:proxy,async:false,success:function(data){
if(data.status===0){ if(data.status===0){
@ -130,6 +130,7 @@ export function initAxiosInterceptors(props) {
} else { } else {
// 加api前缀 // 加api前缀
railsgettimes(`/api/main/first_stamp.json`); railsgettimes(`/api/main/first_stamp.json`);
let newopens=md5(opens+timestamp)
config.url = url; config.url = url;
if (config.url.indexOf('?') == -1) { if (config.url.indexOf('?') == -1) {
config.url = `${config.url}?&randomcode=${timestamp}&client_key=${newopens}`; config.url = `${config.url}?&randomcode=${timestamp}&client_key=${newopens}`;

Loading…
Cancel
Save