Commit e8634e55 by 蒋勇

d

parent f78e7c5e
......@@ -74,6 +74,15 @@ class AppDao extends Dao {
}
}
async findAndCountAll(qobj, t) {
if(qobj.codepath.indexOf("comapps")>=0){
var rtn={};
var cas=await this.db.models.companyapp.findAndCountAll({where:{company_id:qobj.tocompanyid}});
return rtn;
}else{
return super.findAndCountAll(qobj, t);
}
}
extraWhere(obj, w, qc, linkAttrs) {
if (obj.codepath && obj.codepath != "") {
if (obj.codepath.indexOf("pmgmyapps") > 0) {//说明是应用管理员的查询
......
......@@ -128,6 +128,15 @@ module.exports = {
"isleft":true,
},
{
"code": "comapps",
"label": "公司租用",
"bizCode": "comapps",
"isMenu": false,
"bizConfig": null,
"path": "",
"isleft":true,
},
{
"code": "pmgmyapps",
"label": "我的应用",
"isMenu": true,
......@@ -207,6 +216,7 @@ module.exports = {
"organization": {"title": "用户", "config": null, "path": "/organization", "comname": "organization"},
"allapps": {"title": "所有APP", "config": null, "path": "/allapps", "comname": "apps"},
"pmgmyapps": {"title": "我的APP", "config": null, "path": "/pmgmyapps", "comname": "apps"},
"comapps": {"title": "公司租用", "config": null, "path": "/comapps", "comname": "apps"},
"myappinfo": {"title": "应用信息", "config": null, "path": "/myappinfo", "comname": "myappinfo"},
"cachsearches": { "title": "缓存档案", "config": null, "path": "/cachsearches", "comname": "cachsearches" },
"companyinfo": {"title": "应用信息", "config": null, "path": "/companyinfo", "comname": "companyinfo"},
......
module.exports={
"bizName":"comapps",
"list":{
columnMetaData:[
{"width":"200","label":"应用KEY","prop":"appkey","isShowTip":true,"isTmpl":false},
{"width":"100","label":"应用名称","prop":"name","isShowTip":true,"isTmpl":false},
{"width":"200","label":"应用密钥","prop":"secret","isShowTip":true,"isTmpl":false},
{"width":"200","label":"是否启用","prop":"isEnabled","isShowTip":true,"isTmpl":false},
{"width":"null","label":"操作","name":"null","isShowTip":false,"isTmpl":true,"isBtns":"true"},
]
},
"form":[
{
"title":"应用控制",
"colnum":1,
"ctls":[
{"type":"switch","label":"是否启用","prop":"isEnabled","acText":"启用","inactText":"停用","placeHolder":"","style":""},
{"type":"switch","label":"是否私有","prop":"isPublish","acText":"否","inactText":"是","placeHolder":"","style":""},
{ "type": "select", "label": "应用类型", "dicKey": "app_type", "prop": "appType", "labelField": "label", "valueField": "value", "placeHolder": "请选择支付类型", "style": "" },
]
},
{
"title":"概要介绍",
"colnum":1,
"ctls":[
{ "type": "textarea", "label": "简介", "prop": "description", "placeHolder": "请输入产品简介", "style": "width:600px" }
]
},
{
"title":"基本信息",
"colnum":3,
"ctls":[
{"type":"input","label":"应用KEY","prop":"appkey","disabled":true,"placeHolder":"","style":""},
{"type":"input","label":"应用名称","prop":"name","placeHolder":"应用名称","style":""},
{"type":"input","label":"应用密钥","prop":"secret","disabled":false,"placeHolder":"","style":""},
{"type":"input","label":"域名","prop":"domainName","disabled":false,"placeHolder":"","style":""},
{"type":"input","label":"首页","prop":"homePage","disabled":false,"placeHolder":"","style":""},
{"type":"input","label":"认证URL","prop":"authUrl","disabled":false,"placeHolder":"","style":""},
{"type":"input","label":"文档URL","prop":"docUrl","disabled":false,"placeHolder":"","style":""},
{"type":"input","label":"配置URL","prop":"uiconfigUrl","disabled":false,"placeHolder":"","style":""},
{"type":"input","label":"缓存操作URL","prop":"opCacheUrl","disabled":false,"placeHolder":"","style":""},
{"type":"input","label":"接受API调用计数URL","prop":"notifyCacheCountUrl","disabled":false,"placeHolder":"","style":""},
]
},
{
"title":"个性化信息",
"colnum":2,
"ctls":[
{"type":"upload","label":"logo","prop":"logoUrl","disabled":false,"placeHolder":"","style":""},
{"type":"upload","label":"背景图","prop":"bkimageUrl","placeHolder":"应用名称","style":""},
{"type":"upload","label":"缩略图","prop":"showimgUrl","disabled":false,"placeHolder":"","style":"width:100px;height:100px"},
{"type":"upload","label":"细节图","prop":"domainName","disabled":false,"placeHolder":"","style":""},
]
},
],
"search":[
{
"title":"基本查询",
ctls:[
{"type":"input","label":"应用名称","prop":"name","placeHolder":"应用名称","style":""},
]
},
],
"auth":{
"add":[
],
"edit":[
{"icon":"el-icon-edit","title":"弃租","type":"default","key":"giveup","isInRow":true},
],
"delete":[
],
"common":[
],
}
}
......@@ -35,6 +35,8 @@ module.exports={
],
"edit":[
{"icon":"el-icon-edit","title":"设置为当前","type":"default","key":"setcurrent","isInRow":true},
{"icon":"el-icon-edit","title":"组织结构","type":"default","key":"orgmanage","isInRow":true},
{"icon":"el-icon-edit","title":"租用列表","type":"default","key":"comapps","isInRow":true},
],
"delete":[
{"icon":"el-icon-remove","title":"删除","type":"default","key":"delete","isInRow":true},
......
......@@ -9,6 +9,7 @@
deleteMethod="delete"
initMethod="initNewInstance"
isDataAuto="true"
isLazy="true"
:headStyle="headStyle"
:colFormatter="onColFormater"
:isSingleSelect="isSingleSelect"
......
......@@ -51,7 +51,11 @@
created:function(){
if(this.codePath.indexOf("myapps")>=0){
this.bizCode="pmgmyapps";
}else{
}
if(this.codePath.indexOf("allapps")>=0){
this.bizCode="allapps";
}
if(this.codePath.indexOf("comapps")>=0){
this.bizCode="allapps";
}
},
......
......@@ -41,6 +41,9 @@
}
}
if(key="comapps"){
this.$router.push("/comapps");
}
},
onColFormater(row,column,cellvalue,index){
if(column.property=="isSystem"){
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment