20170914
来源:互联网 发布:bi数据分析前景 编辑:程序博客网 时间:2024/06/05 21:50
$row.val("fNo")
if (data.state) {
var str = eval(data.response);
for (var i = 0; i < str.length; i++) {
url = DocUtils.InnerUtils.getdocServerAction({
"docPath":str[i].DocPath,
urlPattern:"/repository/file/view/"+str[i].FileID+"/last/content",
isFromAction :false,
context: me.getContext(),
useCookie : false
});
// debugger
// url = url.indexOf(window.location.protocol) < 1 ? url : window.location.protocol + "//" + window.location.host + url;
Picdata.newData();
Picdata.setValue("fPath",url);
Picdata.setValue("fWorkID",fBZID);
Picdata.saveData();
Picdata.refreshData();
list3.refresh();
}
}
{'backgroundColor': val("fChoseAnswer") !=null? 'green' :(val("fChoseAnswer")==null || val("fChoseAnswer")==''?'grey':'red')}
{'backgroundColor': val("fWeightType")=='一般'? 'red' :'blue'}
Model.prototype.Jump = function(event){
//跳转2级
var data = this.comp("Safety");
var data1= this.comp("TE_ProduceSetMain");
var a = data.getValue("fMessCode");
var state = data.getValue("fMasterTime");
if(state == undefined){
data.setValue("fMasterTime",1);
data.saveData();
var TE_critica = this.comp("TE_critica");
data1.to(a);
//
var params = new biz.Request.ActionParam();
params.setString("id", a);
// 调用动作
biz.Request.sendBizRequest({
"context" : this.getContext(),
"action" : "getCriticalControlPoint1",
"parameters" : params,
"callback" : function(data) {
// data.ignoreError 是否忽略默认的异常处理,默认值true
data.ignoreError = false;
// data.state 请求返回状态,标识请求是否执行成功
if (data.state) {
var a = data.response;
a=$.parseJSON(a);
for( var i=0;i<a.length;i++){
TE_critica.newData();
TE_critica.setValue("fNo",i+1);
TE_critica.setValue("fText",a[i].text);
TE_critica.setValue("fSixTime",a[i].state);
TE_critica.setValue("fWeightType",a[i].fWeightType);
}
}
}
});
this.comp("Tab").to("Detail");
}
public static String getCriticalControlPoint1(String id) throws JSONException{
JSONArray jsonArray = new JSONArray();
String str = "select m.fWeightType as fWeightType,m.fProduceName as fProduceName,m.fIsKey as fIsKey from TE_ProduceSetDetail m where m.fMasterID='"+id+"'";
System.out.println(str);
Table tt = KSQL.select(str, null, "/TeamTreasure/baseSet/data", null);
Iterator<Row> rows = tt.iterator();
while (rows.hasNext()) {
Row row = rows.next();
String fProduceName = row.getString("fProduceName");
String fIsKey = row.getString("fIsKey");
String fWeightType = row.getString("fWeightType");
//
JSONObject jsonObject2 = new JSONObject();
jsonObject2.put("text", fProduceName);
jsonObject2.put("state", fIsKey);
jsonObject2.put("fWeightType",fWeightType);
jsonArray.put(jsonObject2);
}
return jsonArray.toString();
}
var docID = "";
Model.prototype.modelParamsReceive = function(event){
//参数接受事件
var data = this.comp("SA_DocNode");
var context = this.getContext();
var a = event.params.a1;
docID = event.params.a1;
data.setFilter("Type","SA_DocNode.fDocID ='"+a+"'");
data.refreshData();
// var fileNames = ".gif,.jpg,.chm,.avi,.cmd,.code,.cpp,.css,.dll,.doc,.exe,.fla,.flv,.html,.ini,.mdb,.mp3,.pdf,.php,.ppt,.psd,.rar,.rb,.svg,.ttf,.txt,.wmv,.xls,.xml,.zip";
// var baasData1 =this.comp("baasData1");
// //each data
// baasData1.each(function(param){
// //遍历赋值
//
// var title= baasData1.getValue("attachmenttitle",param.row);
// //
// var str = title.split('.');
//
// var a = str[0];
// var b = str[1];
// var str1 = title.split("\\");
// var c = str1[1];
// //
//// var url = "$UI/UniteBulidCountry/ProjectTypeMoble/Plan-DangWuZiLiao/img/"+b+".png";
// var url = require.toUrl("../Plan-DangWuZiLiao/img/" + b +".png");
// baasData1.setValueByID("note",url, param.row.getID());
// baasData1.setValueByID("ssize",c, param.row.getID());
// });
};
Model.prototype.button1Click = function(event){
//返回主页
var url = "$UI/TeamTreasure/education/process/education/education.m.w";
var process = "/TeamTreasure/education/process/education/educationProcess";
var activity = "education";
url = url + '?' + 'process=' + process + '&activity=' + activity;
justep.Shell.showPage(url);
};
Model.prototype.modelLoad = function(event){
//初始化
};
Model.prototype.SA_DocNodeAfterRefresh = function(event){
//刷新后事件把图片种类改变
//声明变量
var fileNames = ".gif,.jpg,.chm,.avi,.cmd,.code,.cpp,.css,.dll,.doc,.exe,.fla,.flv,.html,.ini,.mdb,.mp3,.pdf,.php,.ppt,.psd,.rar,.rb,.svg,.ttf,.txt,.wmv,.xls,.xml,.zip";
//
var SA_DocNode =this.comp("SA_DocNode");
//each data
SA_DocNode.each(function(param){
//遍历赋值
var title= SA_DocNode.getValue("sDocName",param.row);
var fDocID= SA_DocNode.getValue("fDocID",param.row);
var docPath = SA_DocNode.getValue("fDocPath",param.row);
var FileID = SA_DocNode.getValue("FileID",param.row);
//
if(fDocID==docID){
var str = title.split('.');
var a = str[0];
var b = str[1];
//
// url1 = DocUtils.InnerUtils.getdocServerAction({
// "docPath":docPath,
// urlPattern:"/repository/file/view/"+FileID+"/last/content",
// isFromAction :false,
// context: this.getContext(),
// useCookie : false
// });
// alert("a"+a);
// alert("b"+b);
//
var url = require.toUrl("../education/img/" + b +".png");
SA_DocNode.setValueByID("sDescription",url, param.row.getID());
// SA_DocNode.setValueByID("sCacheName",url1, param.row.getID());
// var abc=SA_DocNode.setValueByID("sCacheName",url1, param.row.getID());
// alert(abc);
}
});
};
}
if (data.state) {
var str = eval(data.response);
for (var i = 0; i < str.length; i++) {
url = DocUtils.InnerUtils.getdocServerAction({
"docPath":str[i].DocPath,
urlPattern:"/repository/file/view/"+str[i].FileID+"/last/content",
isFromAction :false,
context: me.getContext(),
useCookie : false
});
// debugger
// url = url.indexOf(window.location.protocol) < 1 ? url : window.location.protocol + "//" + window.location.host + url;
Picdata.newData();
Picdata.setValue("fPath",url);
Picdata.setValue("fWorkID",fBZID);
Picdata.saveData();
Picdata.refreshData();
list3.refresh();
}
}
{'backgroundColor': val("fChoseAnswer") !=null? 'green' :(val("fChoseAnswer")==null || val("fChoseAnswer")==''?'grey':'red')}
{'backgroundColor': val("fWeightType")=='一般'? 'red' :'blue'}
Model.prototype.Jump = function(event){
//跳转2级
var data = this.comp("Safety");
var data1= this.comp("TE_ProduceSetMain");
var a = data.getValue("fMessCode");
var state = data.getValue("fMasterTime");
if(state == undefined){
data.setValue("fMasterTime",1);
data.saveData();
var TE_critica = this.comp("TE_critica");
data1.to(a);
//
var params = new biz.Request.ActionParam();
params.setString("id", a);
// 调用动作
biz.Request.sendBizRequest({
"context" : this.getContext(),
"action" : "getCriticalControlPoint1",
"parameters" : params,
"callback" : function(data) {
// data.ignoreError 是否忽略默认的异常处理,默认值true
data.ignoreError = false;
// data.state 请求返回状态,标识请求是否执行成功
if (data.state) {
var a = data.response;
a=$.parseJSON(a);
for( var i=0;i<a.length;i++){
TE_critica.newData();
TE_critica.setValue("fNo",i+1);
TE_critica.setValue("fText",a[i].text);
TE_critica.setValue("fSixTime",a[i].state);
TE_critica.setValue("fWeightType",a[i].fWeightType);
}
}
}
});
this.comp("Tab").to("Detail");
}
public static String getCriticalControlPoint1(String id) throws JSONException{
JSONArray jsonArray = new JSONArray();
String str = "select m.fWeightType as fWeightType,m.fProduceName as fProduceName,m.fIsKey as fIsKey from TE_ProduceSetDetail m where m.fMasterID='"+id+"'";
System.out.println(str);
Table tt = KSQL.select(str, null, "/TeamTreasure/baseSet/data", null);
Iterator<Row> rows = tt.iterator();
while (rows.hasNext()) {
Row row = rows.next();
String fProduceName = row.getString("fProduceName");
String fIsKey = row.getString("fIsKey");
String fWeightType = row.getString("fWeightType");
//
JSONObject jsonObject2 = new JSONObject();
jsonObject2.put("text", fProduceName);
jsonObject2.put("state", fIsKey);
jsonObject2.put("fWeightType",fWeightType);
jsonArray.put(jsonObject2);
}
return jsonArray.toString();
}
var docID = "";
Model.prototype.modelParamsReceive = function(event){
//参数接受事件
var data = this.comp("SA_DocNode");
var context = this.getContext();
var a = event.params.a1;
docID = event.params.a1;
data.setFilter("Type","SA_DocNode.fDocID ='"+a+"'");
data.refreshData();
// var fileNames = ".gif,.jpg,.chm,.avi,.cmd,.code,.cpp,.css,.dll,.doc,.exe,.fla,.flv,.html,.ini,.mdb,.mp3,.pdf,.php,.ppt,.psd,.rar,.rb,.svg,.ttf,.txt,.wmv,.xls,.xml,.zip";
// var baasData1 =this.comp("baasData1");
// //each data
// baasData1.each(function(param){
// //遍历赋值
//
// var title= baasData1.getValue("attachmenttitle",param.row);
// //
// var str = title.split('.');
//
// var a = str[0];
// var b = str[1];
// var str1 = title.split("\\");
// var c = str1[1];
// //
//// var url = "$UI/UniteBulidCountry/ProjectTypeMoble/Plan-DangWuZiLiao/img/"+b+".png";
// var url = require.toUrl("../Plan-DangWuZiLiao/img/" + b +".png");
// baasData1.setValueByID("note",url, param.row.getID());
// baasData1.setValueByID("ssize",c, param.row.getID());
// });
};
Model.prototype.button1Click = function(event){
//返回主页
var url = "$UI/TeamTreasure/education/process/education/education.m.w";
var process = "/TeamTreasure/education/process/education/educationProcess";
var activity = "education";
url = url + '?' + 'process=' + process + '&activity=' + activity;
justep.Shell.showPage(url);
};
Model.prototype.modelLoad = function(event){
//初始化
};
Model.prototype.SA_DocNodeAfterRefresh = function(event){
//刷新后事件把图片种类改变
//声明变量
var fileNames = ".gif,.jpg,.chm,.avi,.cmd,.code,.cpp,.css,.dll,.doc,.exe,.fla,.flv,.html,.ini,.mdb,.mp3,.pdf,.php,.ppt,.psd,.rar,.rb,.svg,.ttf,.txt,.wmv,.xls,.xml,.zip";
//
var SA_DocNode =this.comp("SA_DocNode");
//each data
SA_DocNode.each(function(param){
//遍历赋值
var title= SA_DocNode.getValue("sDocName",param.row);
var fDocID= SA_DocNode.getValue("fDocID",param.row);
var docPath = SA_DocNode.getValue("fDocPath",param.row);
var FileID = SA_DocNode.getValue("FileID",param.row);
//
if(fDocID==docID){
var str = title.split('.');
var a = str[0];
var b = str[1];
//
// url1 = DocUtils.InnerUtils.getdocServerAction({
// "docPath":docPath,
// urlPattern:"/repository/file/view/"+FileID+"/last/content",
// isFromAction :false,
// context: this.getContext(),
// useCookie : false
// });
// alert("a"+a);
// alert("b"+b);
//
var url = require.toUrl("../education/img/" + b +".png");
SA_DocNode.setValueByID("sDescription",url, param.row.getID());
// SA_DocNode.setValueByID("sCacheName",url1, param.row.getID());
// var abc=SA_DocNode.setValueByID("sCacheName",url1, param.row.getID());
// alert(abc);
}
});
};
}
阅读全文
0 0
- 20170914
- 20170914
- 20170914
- 20170914
- 20170914_OperatingSystem_Project01_BootLoader
- 20170914_翻转句子
- 20170914_删除公共字符
- 20170914apache专用帐号的设置
- 20170914 nwjs实现模拟图片上传
- 20170914_字符串的输入问题
- 20170914 js模拟事件,什么click()都是伪模拟
- 20170914_字符串中找出最长的连续数字串
- Scikit-learn中使用SVM对文本进行分类
- OpenCV 正面人脸检测
- PAT_A 1055. The World's Richest (25)
- 无限轮播
- 针对二分类问题的支持向量机模型
- 20170914
- Lintcode矩形面积
- C++/C++11中<iterator>的使用
- LCA 的两种算法
- HTTP 304状态码的详细讲解
- jdbc:oracle:thin:@lcoalhost:1521:orcl11解析
- 纸张尺寸
- 用 c# 来操作WORD的经验总结
- linux sed命令使用