123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308 |
- Ext.define('make.view.make.makePick.QueryPanel', {
- extend: 'saas.view.core.query.QueryPanel',
- xtype: 'make-makepick-querypanel',
- controller: 'make-makepick-querypanel',
- viewModel: {
- extend: 'saas.view.core.query.QueryPanelModel',
- data: {
- form: {}, // 查询字段记录
- addEnable: false, // 显示新增按钮
- auditEnable: true, // 显示审核按钮
- printEnable: false, // 显示打印按钮
- importEnable: false, // 显示导入按钮
- exportEnable: true, // 显示导出按钮
- closeEnable: false, // 显示关闭按钮
- deleteEnable: true, // 显示删除按钮
- deleteDisable:false, //删除按钮是否可使用
-
- openAudit:false,//单独显示审核按钮
- openUnAudit:false,//单独显示反审核按钮
- openEnable:false, //显示开启 针对已取消列表
- configurable: true, // 允许列设置
-
- }
- },
- viewName: 'make-makepick-querypanel',
- caller: 'MakePick',
- //importUploadPath: '/api/purchse/makepick/saveToFormal',
- initComponent: function () {
- var me = this;
- Ext.apply(me, {
- queryFormItems: [ {
- xtype: 'condatefield',
- name: 'pi_date',
- fieldLabel: '日期',
- columnWidth: 0.5,
- operation: 'between',
- },{
- xtype: 'multiqueryField',
- columnWidth: 0.4,
- name: 'multi_query',
- querys: {
- "BillCode": {"field": "pi_inoutno" ,"desc": "领料单号"},
- "MakeCode": {"field": "prodiodetail.pd_ordercode" ,"desc": "制造单号"},
- "Prod": {"field": "pr_code", "dbfinds": [{//物料
- from: 'pr_code',
- to: 'pr_code'
- },{
- from: 'pr_detail',
- to: 'pr_detail'
- }]},
- "Emp":{"field": "prodinout.creatorName", "dbfinds": [{
- from: 'em_name',
- to: 'prodinout.creatorName'
- }]},
- },
- setShowDetail: function(v){
- this.showDetail = (v == 'Prod' ||v=='MakeCode');
- },
- }],
- moreQueryFormItems: [{
- xtype: 'condatefield',
- name: 'pi_date',
- fieldLabel: '单据日期',
- value:1,
- columnWidth: 1
- }, {
- xtype: 'departDbfindTrigger',
- name: 'pi_departmentname',
- fieldLabel: '部门'
- },{
- xtype: 'warehouseDbfindTrigger',
- name: 'prodiodetail.pd_whname',
- showDetail: true,
- fieldLabel: '仓库'
- },{
- xtype: 'productDbfindTrigger',
- name: 'Prodiodetail.pd_prodcode',
- showDetail: true,
- fieldLabel: '物料编号'
- },{
- xtype: 'textfield',
- name: 'pr_detail',
- fieldLabel: '产品名称',
- readOnly: true,
- }, {
- xtype: 'textfield',
- name: 'pr_orispeccode',
- fieldLabel: '产品型号',
- readOnly: true,
- }, {
- xtype: "remotecombo",
- name: "pr_brand",
- fieldLabel: "厂家/品牌",
- storeUrl: '/api/document/productbrand/getCombo',
- editable: false,
- hiddenBtn:true
- },{
- xtype: 'combobox',
- name: 'pi_statuscode',
- fieldLabel: '审核状态',
- queryMode: 'local',
- displayField: 'pi_status',
- valueField: 'pi_statuscode',
- emptyText :'全部',
- editable:false,
- store: Ext.create('Ext.data.ArrayStore', {
- fields: ['pi_statuscode', 'pi_status'],
- data: [
- ["ALL", "全部"],
- ["AUDITED", "已审核"],
- ["UNAUDITED", "未审核"]
- ]
- }),
- getCondition: function(value) {
- if(value == 'ALL') {
- return '1=1';
- }else {
- return 'pi_statuscode=\'' + value + '\'';
- }
- }
- }, {
- xtype: 'employeeDbfindTrigger',
- name: 'creatorName',
- fieldLabel: '录入人',
- emptyText:'请输入账户名称或姓名',
- getCondition: function(value) {
- if(!value) {
- return '1=1';
- }else {
- return 'prodinout.creatorName like\'%' + value + '%\'';
- }
- }
- },{
- xtype: 'employeeDbfindTrigger',
- name: 'pi_auditman',
- fieldLabel: '审核人',
- emptyText:'请输入账户名称或姓名',
- }],
- queryGridConfig: {
- idField: 'id',
- codeField: 'pi_inoutno',
- mainIdField:'_id',
- detailIdField:'pd_id',
- addTitle: me.addTitle,
- addXtype: me.addXtype,
- defaultCondition: me.defaultCondition,
- baseVastUrl: me.baseVastUrl,
- caller: 'MakePick',
- baseColumn: [{
- text: 'id',
- dataIndex: 'id',
- hidden: true,
- xtype: 'numbercolumn'
- }, {
- text: '领料单号',
- dataIndex: 'pi_inoutno',
- width: 150
- }, {
- text: '单据类型',
- dataIndex: 'pi_class',
- hidden: true
- }, {
- text: '单据日期',
- dataIndex: 'pi_date',
- xtype: 'datecolumn',
- width: 110
- }, {
- text: '审核状态',
- align: 'center',
- dataIndex: 'pi_status',
- width: 80
- }, {
- text: '金额(元)',
- hidden:true,
- xtype: 'numbercolumn',
- dataIndex: 'pi_costtotal',
- width: 110,
- renderer: function(v, m, r) {
- return saas.util.BaseUtil.numberFixFormat(v, 2, true);
- }
- }, {
- text: '录入人',
- align: 'center',
- dataIndex: 'creatorName',
- width: 100
- }, {
- text: '审核人',
- align: 'center',
- dataIndex: 'pi_auditman',
- width: 100
- }, {
- text: '审核日期',
- align: 'center',
- dataIndex: 'pi_auditdate',
- xtype: 'datecolumn',
- width: 110
- }, {
- hidden:true,
- text: '币种',
- dataIndex: 'pi_currency',
- align: 'center',
- width: 65
- }, {
- text: '备注',
- dataIndex: 'pi_remark',
- width: 250
- }],
- relativeColumn: [{
- text: 'id',
- dataIndex: 'pd_id',
- xtype: 'numbercolumn',
- hidden: true
- }, {
- text: '领料单号',
- dataIndex: 'pi_inoutno',
- width: 150
- }, {
- text: '单据日期',
- dataIndex: 'pi_date',
- xtype: 'datecolumn',
- width: 110
- }, {
- text: '审核状态',
- align: 'center',
- dataIndex: 'pi_status',
- width: 80
- }, {
- text: '审核日期',
- align: 'center',
- dataIndex: 'pi_auditdate',
- xtype: 'datecolumn',
- width: 110
- }, {
- text: '制造单号',
- dataIndex: 'pd_ordercode',
- width: 150
- }, {
- text: '工单序号',
- dataIndex: 'pd_orderdetno',
- align: 'center',
- width: 80
- }, {
- text: '物料编号',
- dataIndex: 'pr_code',
- width: 150,
- }, {
- text: '厂家/品牌',
- dataIndex: 'pr_brand',
- width: 100
- }, {
- text: '物料名称',
- dataIndex: 'pr_detail',
- width: 150
- }, {
- text: '型号',
- dataIndex: 'pr_orispeccode',
- width: 200,
- renderer: saas.util.RenderUtil['renderer_prod']
- }, {
- text: '规格',
- dataIndex: 'pr_spec',
- width: 200
- }, {
- text: '仓库',
- dataIndex: 'pd_whname',
- width: 120
- }, {
- text: '数量',
- dataIndex: 'pd_outqty',
- xtype: 'numbercolumn',
- width: 110,
- renderer: function(v, m, r) {
- return saas.util.BaseUtil.numberFormat(v, 6, true);
- }
- }, {
- text: '单位',
- dataIndex: 'pr_unit',
- width: 65
- }, {
- text: '成本单价(元)',
- dataIndex: 'pd_price',
- xtype: 'numbercolumn',
- renderer: function(v, m, r) {
- return saas.util.BaseUtil.numberFormat(v, 8, true);
- },
- width: 110
- }, {
- text: '金额(元)',
- hidden:true,
- dataIndex: 'pd_total',
- xtype: 'numbercolumn',
- width: 110,
- renderer: function(v, m, r) {
- return saas.util.BaseUtil.numberFixFormat(v, 2, true);
- },
- }, {
- text: '备注',
- dataIndex: 'pd_remark',
- width: 250
- }]
- }
- });
- this.callParent(arguments);
- },
- });
|