87,842
社区成员




{
xtype: 'combo',
name: 'teacherId',
id: 'teacherId',
fieldLabel: '老师',
editable: false,
displayField: "NAME",
valueField: "ID",
width: 250,
labelWidth: 80,
queryMode: 'local',
editable: false,
store: teacherstore,
hidden:true,
x: 10,
y: 30
},
{
xtype: 'combo',
name: 'studebtId',
id: 'studebtId',
fieldLabel: '学生',
editable: false,
displayField: "SNAME",
valueField: "SID",
width: 250,
labelWidth: 80,
queryMode: 'local',
editable: false,
store: studentstore,
x: 10,
y: 30
},
var type=‘0'
$.ajax({
url: '/userInfo/userSession',
cache: false,
async: true,
dataType: 'JSON',
success: function (data) {
userList = data;
for(var i=0;i<userList.length;i++){
var typeid= userList[i].type;
if(typeid==1){
type='1';
break;
}
}
}
});
{
xtype: 'combo',
name: 'teacherId',
id: 'teacherId',
fieldLabel: '老师',
editable: false,
displayField: "NAME",
valueField: "ID",
width: 250,
labelWidth: 80,
queryMode: 'local',
editable: false,
store: teacherstore,
hidden:type==1,
x: 10,
y: 30
},
{
xtype: 'combo',
name: 'studebtId',
id: 'studebtId',
fieldLabel: '学生',
editable: false,
displayField: "SNAME",
valueField: "SID",
width: 250,
labelWidth: 80,
queryMode: 'local',
editable: false,
store: studentstore,
hidden:type!=1,
x: 10,
y: 30
},
$.ajax({
url: '/userInfo/userSession',
cache: false,
async: true,
dataType: 'JSON',
success: function (data) {
userList = data;
}
});