1234567891011121314151617181920212223242526272829303132333435363738394041 |
- import request from '@/utils/request'
- export function getExamList(data = {}) {
- return request({
- 'url': '/app/shiti/list',
- headers: {
- isToken: true
- },
- method: 'post',
- data,
- timeout: 20000
- })
- }
- export function getExamAnswerList(data = {}) {
- return request({
- 'url': '/app/shiti/answer/list',
- headers: {
- isToken: true
- },
- method: 'post',
- data,
- timeout: 20000
- })
- }
- function initScript() {
- // 动态加载第三方JS文件
- const script = document.createElement('script');
- script.src = 'https://cdn.example.com/third-party-library.js';
- script.onload = () => {
- // JS文件加载完成后的回调
- console.log('Third-party library loaded.');
- // 你可以在这里调用第三方库的方法
- };
- script.onerror = () => {
- // 处理加载错误
- console.error('Failed to load third-party library.');
- };
- document.head.appendChild(script); // 或者使用 document.body.appendChild(script);
- }
|