Browse Source

临城职教中职
zhangli 2 years ago
parent
commit
7a0a4f3fbd
1 changed files with 116 additions and 115 deletions
  1. +116
    -115
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/ArrangeLessonTerm/IndexLessonTerm.js

+ 116
- 115
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/ArrangeLessonTerm/IndexLessonTerm.js View File

@@ -151,8 +151,8 @@ var bootstrap = function ($, learun) {
text: 'text'
});
$('#WeekTimeSelect').lrselectRefresh({
data: res.data.weekList
}
data: res.data.weekList
}
);
}

@@ -215,7 +215,7 @@ var bootstrap = function ($, learun) {
});
//修改
$('#edit').on('click', function () {
if (classNo.length === 0 || classNo === 'undefined') {
if (!classNo || classNo.length === 0 || classNo === 'undefined') {
return learun.alert.warning('请选择班级!');
}
learun.layerConfirm('是否确认修改该项!', function (res) {
@@ -235,127 +235,128 @@ var bootstrap = function ($, learun) {
};
learun.postForm(top.$.rootUrl + '/EducationalAdministration/ArrangeLessonTerm/UpdateLessonTerm?keyValue=' + keyValue, { postdata: JSON.stringify(postdata) }, function () {
refreshGirdData();
})};
});
});
})
};
});
});

//查询
//$('#lr_search').on('click', function () {
// var p = {};
// p.schoolId = $('#F_SchoolId').lrselectGet();
// p.ClassNo = $('#ClassNo').lrselectGet();
// p.EmpNo = $('#EmpNo').lrselectGet();
// page.search(p);
//});
//查询
//$('#lr_search').on('click', function () {
// var p = {};
// p.schoolId = $('#F_SchoolId').lrselectGet();
// p.ClassNo = $('#ClassNo').lrselectGet();
// p.EmpNo = $('#EmpNo').lrselectGet();
// page.search(p);
//});

//打印课程表
$('#perBtn').on('click',
function () {
AddPrintContent();
});
var LODOP, P_ID = "", TaskID1, TaskID2, t, waiting = false, c = 0, loop = 0; //声明为全局变量
//打印课程表
$('#perBtn').on('click',
function () {
AddPrintContent();
});
var LODOP, P_ID = "", TaskID1, TaskID2, t, waiting = false, c = 0, loop = 0; //声明为全局变量

function AddPrintContent() {
var myHtml = myHtml = $('.personalBox').html();
var strBodyStyle = "<style>" + document.getElementById("style1").innerHTML + "</style>";
var strFormHtml = strBodyStyle + "<body>" + myHtml + "</body>";
function AddPrintContent() {
var myHtml = myHtml = $('.personalBox').html();
var strBodyStyle = "<style>" + document.getElementById("style1").innerHTML + "</style>";
var strFormHtml = strBodyStyle + "<body>" + myHtml + "</body>";

LODOP = getLodop();
LODOP.PRINT_INIT("个人授课表");
LODOP.SET_PRINT_PAGESIZE(2, 0, 0, "A4");
LODOP = getLodop();
LODOP.PRINT_INIT("个人授课表");
LODOP.SET_PRINT_PAGESIZE(2, 0, 0, "A4");

LODOP.SET_PRINT_MODE("PRINT_DUPLEX", 2);
LODOP.SET_PRINT_MODE("PRINT_DEFAULTSOURCE", 7);
LODOP.SET_PRINT_MODE("PRINT_DUPLEX", 2);
LODOP.SET_PRINT_MODE("PRINT_DEFAULTSOURCE", 7);

LODOP.ADD_PRINT_HTM(10, 10, '284mm', '185mm', strFormHtml);
//打印预览
LODOP.SET_SHOW_MODE("LANDSCAPE_DEFROTATED", 1); //横向时的正向显示
var TaskID1 = LODOP.PREVIEW();
// 直接打印
// var TaskID1=LODOP.PRINT();
LODOP.ADD_PRINT_HTM(10, 10, '284mm', '185mm', strFormHtml);
//打印预览
LODOP.SET_SHOW_MODE("LANDSCAPE_DEFROTATED", 1); //横向时的正向显示
var TaskID1 = LODOP.PREVIEW();
// 直接打印
// var TaskID1=LODOP.PRINT();

}
}
},
bindSelect: function () {
//课程
$('#LessonInfo').lrDataSourceSelect({
// 展开最大高度
maxHeight: '100px',
placeholder: "请选择课程",
allowSearch: true,
code: 'LessonInfo',
value: 'lessonno',
text: 'lessonname'
});
//教师
$('#EmpInfo').lrDataSourceSelect({
placeholder: "请选择教师",
maxHeight: 300,
allowSearch: true,
code: 'EmpInfo',
value: 'empno',
text: 'empname'
});
//教室
$('#ClassroomInfo').lrDataSourceSelect({
placeholder: "请选择教室",
maxHeight: 300,
allowSearch: true,
code: 'ClassroomInfo',
value: 'classroomno',
text: 'classroomname'
});
////周次
//$('#WeekTimeSelect').lrselect({
// placeholder: "请选择周次",
// maxHeight: 300,
// allowSearch: true,
// type:'multiple',
// data: weekList
//});
//星期
$('#WeekSelect').lrselect({
placeholder: "请选择星期",
maxHeight: 300,
allowSearch: true,
//type: 'multiple',
data: [{ text: '星期一', value: '1' }, { text: '星期二', value: '2' }, { text: '星期三', value: '3' }, { text: '星期四', value: '4' }, { text: '星期五', value: '5' }, { text: '星期六', value: '6' }, { text: '星期日', value: '7' }, { text: '星期八', value: '8' }, { text: '星期九', value: '9' }, { text: '星期十', value: '10' }],
value: 'value',
text: 'text'
});
//节次
$('#NodeSelect').lrselect({
placeholder: "请选择节次",
maxHeight: 300,
allowSearch: true,
//type: 'multiple',
data: [{ text: '1节', value: '1' }, { text: '2节', value: '2' }, { text: '3节', value: '3' }, { text: '4节', value: '4' }, { text: '5节', value: '5' }, { text: '6节', value: '6' }, { text: '7节', value: '7' }, { text: '8节', value: '8' }, { text: '9节', value: '9' }, { text: '10节', value: '10' }],
value: 'value',
text: 'text'
});
bindSelect: function () {
//课程
$('#LessonInfo').lrDataSourceSelect({
// 展开最大高度
maxHeight: '100px',
placeholder: "请选择课程",
allowSearch: true,
code: 'LessonInfo',
value: 'lessonno',
text: 'lessonname'
});
//教师
$('#EmpInfo').lrDataSourceSelect({
placeholder: "请选择教师",
maxHeight: 300,
allowSearch: true,
code: 'EmpInfo',
value: 'empno',
text: 'empname'
});
//教室
$('#ClassroomInfo').lrDataSourceSelect({
placeholder: "请选择教室",
maxHeight: 300,
allowSearch: true,
code: 'ClassroomInfo',
value: 'classroomno',
text: 'classroomname'
});
////周次
//$('#WeekTimeSelect').lrselect({
// placeholder: "请选择周次",
// maxHeight: 300,
// allowSearch: true,
// type:'multiple',
// data: weekList
//});
//星期
$('#WeekSelect').lrselect({
placeholder: "请选择星期",
maxHeight: 300,
allowSearch: true,
//type: 'multiple',
data: [{ text: '星期一', value: '1' }, { text: '星期二', value: '2' }, { text: '星期三', value: '3' }, { text: '星期四', value: '4' }, { text: '星期五', value: '5' }, { text: '星期六', value: '6' }, { text: '星期日', value: '7' }, { text: '星期八', value: '8' }, { text: '星期九', value: '9' }, { text: '星期十', value: '10' }],
value: 'value',
text: 'text'
});
//节次
$('#NodeSelect').lrselect({
placeholder: "请选择节次",
maxHeight: 300,
allowSearch: true,
//type: 'multiple',
data: [{ text: '1节', value: '1' }, { text: '2节', value: '2' }, { text: '3节', value: '3' }, { text: '4节', value: '4' }, { text: '5节', value: '5' }, { text: '6节', value: '6' }, { text: '7节', value: '7' }, { text: '8节', value: '8' }, { text: '9节', value: '9' }, { text: '10节', value: '10' }],
value: 'value',
text: 'text'
});

},
search: function (param) {
param = param || {};
//当前第几周
param.curWeek = curWeek;
//班级
param.classNo = classNo;//'202010';//
page.loadData(param);
},
search: function (param) {
param = param || {};
//当前第几周
param.curWeek = curWeek;
//班级
param.classNo = classNo;//'202010';//
page.loadData(param);

$('#WeekTimeSelect').lrselectRefresh({
data: weekList
});
$('#LessonInfo').lrselectSet('');
$('#EmpInfo').lrselectSet('');
$('#ClassroomInfo').lrselectSet('');
$('#WeekTimeSelect').lrselectSet('');
$('#WeekSelect').lrselectSet('');
$('#NodeSelect').lrselectSet('');
}
$('#WeekTimeSelect').lrselectRefresh({
data: weekList
});
$('#LessonInfo').lrselectSet('');
$('#EmpInfo').lrselectSet('');
$('#ClassroomInfo').lrselectSet('');
$('#WeekTimeSelect').lrselectSet('');
$('#WeekSelect').lrselectSet('');
$('#NodeSelect').lrselectSet('');
}
};
refreshGirdData = function () {
page.search();
};
page.init();
refreshGirdData = function () {
page.search();
};
page.init();
};

Loading…
Cancel
Save