| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150 |
- Ext.define('school.view.basic.class.ClassDetail', {
- extend: 'school.view.core.form.FormPanel',
- xtype: 'classdetail',
- controller: 'classdetail',
- viewModel: 'classdetail',
- //字段属性
- _title: '班级信息',
- _idField: 'clazz_id',
- _codeField: null,
- // _readUrl: 'http://10.1.80.47:9560/class/read',
- _readUrl: '/api/school/class/read',
- // _saveUrl: 'http://10.1.80.47:9560/class/save',
- _saveUrl: '/api/school/class/save',
- _deleteUrl: '/api/school/class/delete',
- initId: 0,
- initComponent: function () {
- Ext.apply(this, {
- defaultItems: [{
- xtype: 'hidden',
- name: 'clazz_id',
- fieldLabel: 'id',
- group: '班级信息',
- }, {
- xtype: "textfield",
- name: "clazz_name",
- fieldLabel: "班级名称",
- columnWidth: 0.5,
- group: '班级信息',
- }, {
- // xtype: 'textfield',
- // name: 'code',
- // fieldLabel: '班级代码',
- // }, {
- xtype: 'textfield',
- name: 'clazz_grade',
- fieldLabel: '所属年级',
- columnWidth: 0.5,
- group: '班级信息',
- }, {
- xtype: "textfield",
- name: "clazz_adress",
- fieldLabel: "班级地址",
- columnWidth: 1,
- group: '班级信息',
- }, {
- xtype: "textfield",
- name: 'clazz_status',
- fieldLabel: "状态",
- columnWidth: 0.5,
- group: '班级信息',
- }, {
- xtype: "textfield",
- name: 'clazz_remarks',
- fieldLabel: '备注',
- columnWidth: 0.5,
- group: '班级信息',
- }, {
- name: "detail0",
- xtype: "detailGridField",
- detnoColumn: 'sd_detno',
- storeModel: 'school.model.basic.Student',
- allowEmpty: true,
- showCount: false,
- readOnly: true,
- group: '学生信息',
- columns: [{
- text: 'id',
- dataIndex: 'stu_id',
- hidden: true
- }, {
- text: '编号',
- dataIndex: 'stu_number'
- }, {
- text: '姓名',
- dataIndex: 'stu_name'
- }, {
- text: '性别',
- dataIndex: 'stu_sex'
- }, {
- text: '出生日期',
- dataIndex: 'stu_birthday',
- xtype: 'datecolumn',
- format: 'Y-m-d'
- }, {
- text: '年龄',
- dataIndex: 'stu_age'
- }, {
- text: '家庭住址',
- dataIndex: 'stu_address'
- }, {
- text: '入学时间',
- dataIndex: 'stu_enroll_date',
- xtype: 'datecolumn',
- format: 'Y-m-d'
- }, {
- text: '毕业时间',
- dataIndex: 'stu_graduate_date',
- xtype: 'datecolumn',
- format: 'Y-m-d'
- }, {
- text: '备注',
- dataIndex: 'stu_remarks'
- }]
- }, {
- name: "detail1",
- xtype: "detailGridField",
- idColumn: 'teacher_clazz_id',
- detnoColumn: 'no',
- storeModel: 'school.model.basic.Subject',
- deleteDetailUrl: '/api/school/class/deleteDetail',
- allowEmpty: true,
- showCount: false,
- group: '学科信息',
- columns: [{
- text: 'id',
- dataIndex: 'teacher_clazz_id',
- hidden: true
- }, {
- text: '学科id',
- dataIndex: 'subject_id',
- editor: {
- xtype: 'textfield'
- }
- }, {
- text: '学科',
- dataIndex: 'subject_name',
- xtype: 'subjectcolumn'
- }, {
- text: '任课教师id',
- dataIndex: 'teacher_id',
- editor: {
- xtype: 'textfield'
- }
- }, {
- text: '任课教师',
- dataIndex: 'teacher_name',
- editor: {
- xtype: 'textfield'
- }
- }]
- }]
- });
- this.callParent();
- },
- });
|