|
|
@@ -0,0 +1,94 @@
|
|
|
+/**
|
|
|
+ * 描述:周期季度列表
|
|
|
+ */
|
|
|
+shr.defineClass("shr.custom.ExamineGradePersonScoreList", shr.framework.List, {
|
|
|
+ /**
|
|
|
+ * 描述:初始化操作
|
|
|
+ *
|
|
|
+ * @action
|
|
|
+ */
|
|
|
+ initalizeDOM: function () {
|
|
|
+ var _self = this;
|
|
|
+ shr.custom.ExamineGradePersonScoreList.superClass.initalizeDOM.call(this);
|
|
|
+
|
|
|
+ },
|
|
|
+
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 查看
|
|
|
+ */
|
|
|
+ viewAction: function (billId, rowid) {
|
|
|
+ // 编辑界面禁用,则直接返回
|
|
|
+ if (this.editViewDisable) {
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ this.reloadPage({
|
|
|
+ uipk: "com.kingdee.eas.custom.performancenew.app.ExamineGradePersonEntryScore.list",
|
|
|
+ billId: billId,
|
|
|
+
|
|
|
+ });
|
|
|
+ }, /**
|
|
|
+ * 查询表格
|
|
|
+ */
|
|
|
+ queryGrid: function () {
|
|
|
+ var _self = this;
|
|
|
+ var $grid = $(this.gridId);
|
|
|
+ // filter
|
|
|
+ var filterItems = this.getFilterItems();
|
|
|
+ var str = filterItems;
|
|
|
+ var pattern = /(\w+)\s+like\s+'%(.*?)%'/; // 匹配字段名和百分号内的内容
|
|
|
+ // fastFilter
|
|
|
+ var fastFilterItems = this.getFastFilterItems();
|
|
|
+ if (fastFilterItems) {
|
|
|
+ $grid.jqGrid("option", "fastFilterItems", JSON.stringifyOnce(fastFilterItems));
|
|
|
+ }
|
|
|
+ var matchResult = str.match(pattern);
|
|
|
+ var columnName = matchResult ? matchResult[1] : null;
|
|
|
+ var extractedData = matchResult ? matchResult[2] : null;
|
|
|
+ console.log(columnName); // 输出: "personNumber"
|
|
|
+ console.log(extractedData); // 输出: "AA"
|
|
|
+ if(columnName!=null){
|
|
|
+ filterItems = "(" + columnName + " = '" + extractedData + "')"
|
|
|
+ }
|
|
|
+ $grid.jqGrid("option", "filterItems", filterItems);
|
|
|
+
|
|
|
+ //seniorFilter
|
|
|
+ var advancedFilter = this.getAdvancedFilterItems();
|
|
|
+ if (_self.fastFilterMap && _self.fastFilterMap.fastFilterItems && _self.isReturn) {
|
|
|
+ advancedFilter = _self.fastFilterMap.fastFilterItems.advancedFilter;
|
|
|
+ }
|
|
|
+ if (advancedFilter) {
|
|
|
+ $grid.jqGrid("option", "advancedFilter", JSON.stringify(advancedFilter));
|
|
|
+ } else {
|
|
|
+ $grid.jqGrid("option", "advancedFilter", null);
|
|
|
+ }
|
|
|
+
|
|
|
+ // 修改为通过URL取数
|
|
|
+ if (!_self.isFirstLoadData) {
|
|
|
+ $grid.jqGrid('setGridParam', { datatype: 'local' });
|
|
|
+ $grid.bind("jqGridLoadComplete", function (e, datas) {
|
|
|
+ $grid.jqGrid('showNoRecords');
|
|
|
+ });
|
|
|
+ _self.isFirstLoadData = true;
|
|
|
+ } else {
|
|
|
+ $grid.jqGrid('setGridParam', { datatype: 'json' });
|
|
|
+ }
|
|
|
+
|
|
|
+ // reload
|
|
|
+ $grid.jqGrid("reloadGrid");
|
|
|
+ var filtertype = 'normal';
|
|
|
+ var filterValue = filterItems;
|
|
|
+ if (this.getQuickFilterItems()) {
|
|
|
+ filtertype = 'QuickFilter';
|
|
|
+ filterValue = this.getQuickFilterItems();
|
|
|
+ }
|
|
|
+ if (this.getCustomFilterItems()) {
|
|
|
+ filtertype = 'CustomFilter';
|
|
|
+ filterValue = this.getCustomFilterItems();
|
|
|
+ }
|
|
|
+ var text = { id: this.uipk, text: this.title, filtertype: filtertype, filter: filterValue };
|
|
|
+ var value = { type: 2, msg: text };
|
|
|
+ shr.operateLogger(value);
|
|
|
+ },
|
|
|
+
|
|
|
+});
|