提交 1fe53228 编写于 作者: laizhilong's avatar laizhilong

Merge remote-tracking branch 'origin/master'

......@@ -40,8 +40,6 @@ export default {
redirect_uri: "RedirectURI",
region_id: "RegionId",
disabled: "是否禁用",
lic: "授权",
image: "图片",
accessid: "开放平台接入标识",
},
uiactions: {
......
......@@ -39,8 +39,6 @@ export default {
redirect_uri: "RedirectURI",
region_id: "RegionId",
disabled: "是否禁用",
lic: "授权",
image: "图片",
accessid: "开放平台接入标识",
},
uiactions: {
......
......@@ -114,16 +114,165 @@ mock.onGet(new RegExp(/^\/sysuserauths\/([a-zA-Z0-9\-\;]{1,35})\/select$/)).repl
console.groupEnd();
return [status, _items];
});
// URI参数传递情况未实现
// URI参数传递情况未实现
// URI参数传递情况未实现
// URI参数传递情况未实现
// URI参数传递情况未实现
// URI参数传递情况未实现
// URI参数传递情况未实现
// Create
mock.onPost(new RegExp(/^\/sysuserauths\/?([a-zA-Z0-9\-\;]{0,35})$/)).reply((config: any) => {
console.groupCollapsed("实体:sysuserauth 方法: Create");
console.table({url:config.url, method: config.method, data:config.data});
let status = MockAdapter.mockStatus(config);
if (status !== 200) {
return [status, null];
}
const paramArray:Array<any> = ['id'];
const matchArray:any = new RegExp(/^\/sysuserauths\/([a-zA-Z0-9\-\;]{1,35})$/).exec(config.url);
let tempValue: any = {};
if(matchArray && matchArray.length >1 && paramArray && paramArray.length >0){
paramArray.forEach((item: any, index: number) => {
Object.defineProperty(tempValue, item, {
enumerable: true,
value: matchArray[index + 1]
});
});
}
console.groupCollapsed("response数据 status: "+status+" data: ");
console.table(mockDatas[0]);
console.groupEnd();
console.groupEnd();
return [status, mockDatas[0]];
});
// Update
mock.onPut(new RegExp(/^\/sysuserauths\/?([a-zA-Z0-9\-\;]{0,35})$/)).reply((config: any) => {
console.groupCollapsed("实体:sysuserauth 方法: Update");
console.table({url:config.url, method: config.method, data:config.data});
let status = MockAdapter.mockStatus(config);
if (status !== 200) {
return [status, null];
}
const paramArray:Array<any> = ['id'];
const matchArray:any = new RegExp(/^\/sysuserauths\/([a-zA-Z0-9\-\;]{1,35})$/).exec(config.url);
let tempValue: any = {};
if(matchArray && matchArray.length >1 && paramArray && paramArray.length >0){
paramArray.forEach((item: any, index: number) => {
Object.defineProperty(tempValue, item, {
enumerable: true,
value: matchArray[index + 1]
});
});
}
//let items = mockDatas ? mockDatas : [];
//let _items = items.find((item: any) => Object.is(item.id, tempValue.id));
let data = JSON.parse(config.data);
mockDatas.forEach((item)=>{
if(item['id'] == tempValue['id'] ){
for(let value in data){
if(item.hasOwnProperty(value)){
item[value] = data[value];
}
}
}
})
console.groupCollapsed("response数据 status: "+status+" data: ");
console.table(data);
console.groupEnd();
console.groupEnd();
return [status, data];
});
// GetDraft
mock.onGet(new RegExp(/^\/sysuserauths\/getdraft$/)).reply((config: any) => {
console.groupCollapsed("实体:sysuserauth 方法: GetDraft");
console.table({url:config.url, method: config.method, data:config.data});
// GetDraft
let status = MockAdapter.mockStatus(config);
if (status !== 200) {
return [status, null];
}
console.groupCollapsed("response数据 status: "+status+" data: ");
console.table({});
console.groupEnd();
console.groupEnd();
return [status, {}];
});
// CheckKey
mock.onPost(new RegExp(/^\/sysuserauths\/?([a-zA-Z0-9\-\;]{0,35})\/checkkey$/)).reply((config: any) => {
console.groupCollapsed("实体:sysuserauth 方法: CheckKey");
console.table({url:config.url, method: config.method, data:config.data});
let status = MockAdapter.mockStatus(config);
if (status !== 200) {
return [status, null];
}
const paramArray:Array<any> = ['id'];
const matchArray:any = new RegExp(/^\/sysuserauths\/([a-zA-Z0-9\-\;]{1,35})\/checkkey$/).exec(config.url);
let tempValue: any = {};
if(matchArray && matchArray.length >1 && paramArray && paramArray.length >0){
paramArray.forEach((item: any, index: number) => {
Object.defineProperty(tempValue, item, {
enumerable: true,
value: matchArray[index + 1]
});
});
}
//let items = mockDatas ? mockDatas : [];
//let _items = items.find((item: any) => Object.is(item.id, tempValue.id));
let data = JSON.parse(config.data);
mockDatas.forEach((item)=>{
if(item['id'] == tempValue['id'] ){
for(let value in data){
if(item.hasOwnProperty(value)){
item[value] = data[value];
}
}
}
})
console.groupCollapsed("response数据 status: "+status+" data: ");
console.table(data);
console.groupEnd();
console.groupEnd();
return [status, data];
});
// Save
mock.onPost(new RegExp(/^\/sysuserauths\/?([a-zA-Z0-9\-\;]{0,35})\/save$/)).reply((config: any) => {
console.groupCollapsed("实体:sysuserauth 方法: Save");
console.table({url:config.url, method: config.method, data:config.data});
let status = MockAdapter.mockStatus(config);
if (status !== 200) {
return [status, null];
}
const paramArray:Array<any> = ['id'];
const matchArray:any = new RegExp(/^\/sysuserauths\/([a-zA-Z0-9\-\;]{1,35})\/save$/).exec(config.url);
let tempValue: any = {};
if(matchArray && matchArray.length >1 && paramArray && paramArray.length >0){
paramArray.forEach((item: any, index: number) => {
Object.defineProperty(tempValue, item, {
enumerable: true,
value: matchArray[index + 1]
});
});
}
//let items = mockDatas ? mockDatas : [];
//let _items = items.find((item: any) => Object.is(item.id, tempValue.id));
let data = JSON.parse(config.data);
mockDatas.forEach((item)=>{
if(item['id'] == tempValue['id'] ){
for(let value in data){
if(item.hasOwnProperty(value)){
item[value] = data[value];
}
}
}
})
console.groupCollapsed("response数据 status: "+status+" data: ");
console.table(data);
console.groupEnd();
console.groupEnd();
return [status, data];
});
// FetchDefault
mock.onGet(new RegExp(/^\/sysuserauths\/select$/)).reply((config: any) => {
mock.onGet(new RegExp(/^\/sysuserauths\/fetchdefault$/)).reply((config: any) => {
console.groupCollapsed("实体:sysuserauth 方法: FetchDefault");
console.table({url:config.url, method: config.method, data:config.data});
let status = MockAdapter.mockStatus(config);
......@@ -138,7 +287,7 @@ mock.onGet(new RegExp(/^\/sysuserauths\/select$/)).reply((config: any) => {
});
// FetchDefault
mock.onGet(new RegExp(/^\/sysuserauths\/select(\?[\w-./?%&=,]*)*$/)).reply((config: any) => {
mock.onGet(new RegExp(/^\/sysuserauths\/fetchdefault(\?[\w-./?%&=,]*)*$/)).reply((config: any) => {
console.groupCollapsed("实体:sysuserauth 方法: FetchDefault");
console.table({url:config.url, method: config.method, data:config.data});
if(config.url.includes('page')){
......@@ -173,3 +322,59 @@ mock.onGet(new RegExp(/^\/sysuserauths\/select(\?[\w-./?%&=,]*)*$/)).reply((conf
// URI参数传递情况未实现
// URI参数传递情况未实现
// Remove
mock.onDelete(new RegExp(/^\/sysuserauths\/([a-zA-Z0-9\-\;]{1,35})$/)).reply((config: any) => {
console.groupCollapsed("实体:sysuserauth 方法: Remove");
console.table({url:config.url, method: config.method, data:config.data});
let status = MockAdapter.mockStatus(config);
if (status !== 200) {
return [status, null];
}
const paramArray:Array<any> = ['id'];
const matchArray:any = new RegExp(/^\/sysuserauths\/([a-zA-Z0-9\-\;]{1,35})$/).exec(config.url);
let tempValue: any = {};
if(matchArray && matchArray.length >1 && paramArray && paramArray.length >0){
paramArray.forEach((item: any, index: number) => {
Object.defineProperty(tempValue, item, {
enumerable: true,
value: matchArray[index + 1]
});
});
}
let items = mockDatas ? mockDatas : [];
let _items = items.find((item: any) => Object.is(item.id, tempValue.id));
console.groupCollapsed("response数据 status: "+status+" data: ");
console.table(_items?_items:{});
console.groupEnd();
console.groupEnd();
return [status, _items?_items:{}];
});
// Get
mock.onGet(new RegExp(/^\/sysuserauths\/([a-zA-Z0-9\-\;]{1,35})$/)).reply((config: any) => {
console.groupCollapsed("实体:sysuserauth 方法: Get");
console.table({url:config.url, method: config.method, data:config.data});
let status = MockAdapter.mockStatus(config);
if (status !== 200) {
return [status, null];
}
const paramArray:Array<any> = ['id'];
const matchArray:any = new RegExp(/^\/sysuserauths\/([a-zA-Z0-9\-\;]{1,35})$/).exec(config.url);
let tempValue: any = {};
if(matchArray && matchArray.length >1 && paramArray && paramArray.length >0){
paramArray.forEach((item: any, index: number) => {
Object.defineProperty(tempValue, item, {
enumerable: true,
value: matchArray[index + 1]
});
});
}
let items = mockDatas ? mockDatas : [];
let _items = items.find((item: any) => Object.is(item.id, tempValue.id));
console.groupCollapsed("response数据 status: "+status+" data: ");
console.table(_items?_items:{});
console.groupEnd();
console.groupEnd();
return [status, _items?_items:{}];
});
......@@ -31,7 +31,7 @@ export default class SysUserAuthServiceBase extends EntityService {
this.APPLYDEKEY ='sysuserauth';
this.APPDEKEY = 'id';
this.APPDENAME = 'sysuserauths';
this.APPDETEXT = '';
this.APPDETEXT = 'username';
this.APPNAME = 'web';
this.SYSTEMNAME = 'ibzuaa';
}
......@@ -53,6 +53,123 @@ export default class SysUserAuthServiceBase extends EntityService {
return res;
}
/**
* Create接口方法
*
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof SysUserAuthServiceBase
*/
public async Create(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let masterData:any = {};
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
}
if(data.srffrontuf){
delete data.srffrontuf;
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/sysuserauths`,data,isloading);
return res;
}
/**
* Update接口方法
*
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof SysUserAuthServiceBase
*/
public async Update(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let masterData:any = {};
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/sysuserauths/${context.sysuserauth}`,data,isloading);
return res;
}
/**
* Remove接口方法
*
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof SysUserAuthServiceBase
*/
public async Remove(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let res:any = Http.getInstance().delete(`/sysuserauths/${context.sysuserauth}`,isloading);
return res;
}
/**
* Get接口方法
*
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof SysUserAuthServiceBase
*/
public async Get(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let res:any = await Http.getInstance().get(`/sysuserauths/${context.sysuserauth}`,isloading);
return res;
}
/**
* GetDraft接口方法
*
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof SysUserAuthServiceBase
*/
public async GetDraft(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let res:any = await Http.getInstance().get(`/sysuserauths/getdraft`,isloading);
res.data.sysuserauth = data.sysuserauth;
return res;
}
/**
* CheckKey接口方法
*
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof SysUserAuthServiceBase
*/
public async CheckKey(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let res:any = Http.getInstance().post(`/sysuserauths/${context.sysuserauth}/checkkey`,data,isloading);
return res;
}
/**
* Save接口方法
*
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof SysUserAuthServiceBase
*/
public async Save(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let masterData:any = {};
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/sysuserauths/${context.sysuserauth}/save`,data,isloading);
return res;
}
/**
* FetchDefault接口方法
*
......@@ -63,5 +180,8 @@ export default class SysUserAuthServiceBase extends EntityService {
* @memberof SysUserAuthServiceBase
*/
public async FetchDefault(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let tempData:any = JSON.parse(JSON.stringify(data));
let res:any = Http.getInstance().get(`/sysuserauths/fetchdefault`,tempData,isloading);
return res;
}
}
\ No newline at end of file
......@@ -109,42 +109,6 @@
</app-form-item>
</i-col>
<i-col v-show="detailsModel.lic.visible" :style="{}" :lg="{ span: 24, offset: 0 }">
<app-form-item name='lic' :itemRules="this.rules().lic" class='' :caption="$t('entities.sysopenaccess.main_form.details.lic')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.lic.error" :isEmptyCaption="false" labelPos="LEFT">
<ibiz-file-upload
:data="data"
formItemName="lic"
:value="data.lic"
:formState="formState"
folder="sysopenaccess"
ownertype="lic"
:ownerid="data.srfkey"
:show-ocrview="true"
:show-preview="true"
:show-edit="true"
:show-drag="false"
:persistence="false"
@formitemvaluechange="onFormItemValueChange"></ibiz-file-upload>
</app-form-item>
</i-col>
<i-col v-show="detailsModel.image.visible" :style="{}" :lg="{ span: 24, offset: 0 }">
<app-form-item name='image' :itemRules="this.rules().image" class='' :caption="$t('entities.sysopenaccess.main_form.details.image')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.lic.error" :isEmptyCaption="false" labelPos="LEFT">
<ibiz-image-upload
:data="data"
formItemName="image"
:value="data.image"
:formState="formState"
folder="sysopenaccess"
ownertype="image"
:ownerid="data.srfkey"
:show-ocrview="true"
:show-preview="true"
:persistence="true"
@formitemvaluechange="onFormItemValueChange"></ibiz-image-upload>
</app-form-item>
</i-col>
</row>
......@@ -497,8 +461,6 @@ export default class MainBase extends Vue implements ControlInterface {
redirect_uri: null,
region_id: null,
disabled: null,
lic: null,
image: null,
accessid: null,
sysopenaccess:null,
};
......@@ -627,18 +589,6 @@ export default class MainBase extends Vue implements ControlInterface {
{ required: false, type: 'number', message: '是否禁用 值不能为空', trigger: 'change' },
{ required: false, type: 'number', message: '是否禁用 值不能为空', trigger: 'blur' },
],
lic: [
{ type: 'string', message: '授权 值必须为字符串类型', trigger: 'change' },
{ type: 'string', message: '授权 值必须为字符串类型', trigger: 'blur' },
{ required: false, type: 'string', message: '授权 值不能为空', trigger: 'change' },
{ required: false, type: 'string', message: '授权 值不能为空', trigger: 'blur' },
],
image: [
{ type: 'string', message: '图片 值必须为字符串类型', trigger: 'change' },
{ type: 'string', message: '图片 值必须为字符串类型', trigger: 'blur' },
{ required: false, type: 'string', message: '图片 值不能为空', trigger: 'change' },
{ required: false, type: 'string', message: '图片 值不能为空', trigger: 'blur' },
],
accessid: [
{ type: 'string', message: '开放平台接入标识 值必须为字符串类型', trigger: 'change' },
{ type: 'string', message: '开放平台接入标识 值必须为字符串类型', trigger: 'blur' },
......@@ -764,10 +714,6 @@ export default class MainBase extends Vue implements ControlInterface {
region_id: new FormItemModel({ caption: 'RegionId', detailType: 'FORMITEM', name: 'region_id', visible: true, isShowCaption: true, form: this, isControlledContent: false , disabled: false, enableCond: 3 })
,
disabled: new FormItemModel({ caption: '是否禁用', detailType: 'FORMITEM', name: 'disabled', visible: true, isShowCaption: true, form: this, isControlledContent: false , disabled: false, enableCond: 3 })
,
lic: new FormItemModel({ caption: '授权', detailType: 'FORMITEM', name: 'lic', visible: true, isShowCaption: true, form: this, isControlledContent: false , disabled: false, enableCond: 3 })
,
image: new FormItemModel({ caption: '图片', detailType: 'FORMITEM', name: 'image', visible: true, isShowCaption: true, form: this, isControlledContent: false , disabled: false, enableCond: 3 })
,
accessid: new FormItemModel({ caption: '开放平台接入标识', detailType: 'FORMITEM', name: 'accessid', visible: true, isShowCaption: true, form: this, isControlledContent: false , disabled: false, enableCond: 3 })
,
......@@ -941,30 +887,6 @@ export default class MainBase extends Vue implements ControlInterface {
this.formDataChange({ name: 'disabled', newVal: newVal, oldVal: oldVal });
}
/**
* 监控表单属性 lic 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof MainBase
*/
@Watch('data.lic')
onLicChange(newVal: any, oldVal: any) {
this.formDataChange({ name: 'lic', newVal: newVal, oldVal: oldVal });
}
/**
* 监控表单属性 image 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof MainBase
*/
@Watch('data.image')
onImageChange(newVal: any, oldVal: any) {
this.formDataChange({ name: 'image', newVal: newVal, oldVal: oldVal });
}
/**
* 监控表单属性 accessid 值
*
......@@ -1048,8 +970,6 @@ export default class MainBase extends Vue implements ControlInterface {
}
/**
......
......@@ -85,14 +85,6 @@ export default class MainModel {
prop: 'disabled',
dataType: 'YESNO',
},
{
name: 'lic',
dataType:'FORMITEM',
},
{
name: 'image',
dataType:'FORMITEM',
},
{
name: 'accessid',
prop: 'id',
......
......@@ -56,6 +56,9 @@ public class SysUserAuthSearchContext extends QueryWrapperContext<SysUserAuth> {
{
this.query=query;
if(!StringUtils.isEmpty(query)){
this.getSearchCond().and( wrapper ->
wrapper.like("username", query)
);
}
}
}
......
!!!!模版产生代码错误:----
Tip: If the failing expression is known to be legally refer to something that's sometimes null or missing, either specify a default value like myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing</#if>. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)??
----
----
FTL stack trace ("~" means nesting-related):
- Failed at: ${dbinst.getUserName()} [in template "CODETEMPL_en_US" at line 28, column 24]
----
\ No newline at end of file
<?xml version="1.1" encoding="UTF-8" standalone="no"?>
<databaseChangeLog xmlns="http://www.liquibase.org/xml/ns/dbchangelog" xmlns:ext="http://www.liquibase.org/xml/ns/dbchangelog-ext" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog-ext http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-ext.xsd http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-3.6.xsd">
<!--输出实体[SYS_AUTHLOG]数据结构 -->
<changeSet author="a_A_5d9d78509" id="tab-sys_authlog-1-1">
<createTable tableName="IBZAUTHLOG">
<column name="LOGID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_SYS_AUTHLOG_LOGID"/>
</column>
<column name="USERNAME" remarks="" type="VARCHAR(100)">
</column>
<column name="PERSONNAME" remarks="" type="VARCHAR(100)">
</column>
<column name="DOMAIN" remarks="" type="VARCHAR(100)">
</column>
<column name="AUTHTIME" remarks="" type="DATETIME">
</column>
<column name="IPADDR" remarks="" type="VARCHAR(100)">
</column>
<column name="MACADDR" remarks="" type="VARCHAR(100)">
</column>
<column name="USERAGENT" remarks="" type="VARCHAR(100)">
</column>
<column name="AUTHCODE" remarks="" type="VARCHAR(15)">
</column>
</createTable>
</changeSet>
<!--输出实体[SYS_OPEN_ACCESS]数据结构 -->
<changeSet author="a_A_5d9d78509" id="tab-sys_open_access-21-2">
<createTable tableName="IBZOPENACCESS">
<column name="ACCESSID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_SYS_OPEN_ACCESS_ACCESSID"/>
</column>
<column name="ACCESSNAME" remarks="" type="VARCHAR(100)">
</column>
<column name="OPEN_TYPE" remarks="" type="VARCHAR(100)">
</column>
<column name="ACCESS_KEY" remarks="" type="VARCHAR(100)">
</column>
<column name="SECRET_KEY" remarks="" type="VARCHAR(100)">
</column>
<column name="REGION_ID" remarks="" type="VARCHAR(100)">
</column>
<column name="ACCESS_TOKEN" remarks="" type="VARCHAR(1000)">
</column>
<column name="EXPIRES_TIME" remarks="" type="DATETIME">
</column>
<column name="DISABLED" remarks="" type="INT">
</column>
<column name="REDIRECT_URI" remarks="" type="VARCHAR(500)">
</column>
</createTable>
</changeSet>
<!--输出实体[SYS_PSSYSTEM]数据结构 -->
<changeSet author="a_A_5d9d78509" id="tab-sys_pssystem-1-3">
<createTable tableName="IBZPSSYSTEM">
<column name="PSSYSTEMID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_SYS_PSSYSTEM_PSSYSTEMID"/>
</column>
<column name="PSSYSTEMNAME" remarks="" type="VARCHAR(100)">
</column>
<column name="SYSSTRUCTURE" remarks="" type="TEXT(1048576)">
</column>
<column name="APPS" remarks="" type="TEXT(1048576)">
</column>
<column name="MD5CHECK" remarks="" type="VARCHAR(100)">
</column>
<column name="SHOWORDER" remarks="" type="INT">
</column>
</createTable>
</changeSet>
<!--输出实体[SYS_PERMISSION]数据结构 -->
<changeSet author="a_A_5d9d78509" id="tab-sys_permission-1-4">
<createTable tableName="IBZPERMISSION">
<column name="SYS_PERMISSIONID" remarks="" type="VARCHAR(200)">
<constraints primaryKey="true" primaryKeyName="PK_SYS_PERMISSION_SYS_PERMISSI"/>
</column>
<column name="SYS_PERMISSIONNAME" remarks="" type="VARCHAR(200)">
</column>
<column name="PERMISSIONTYPE" remarks="" type="VARCHAR(60)">
</column>
<column name="PSSYSTEMID" remarks="" type="VARCHAR(100)">
</column>
<column name="ENABLE" remarks="" type="INT">
</column>
<column name="CREATEDATE" remarks="" type="DATETIME">
</column>
<column name="UPDATEDATE" remarks="" type="DATETIME">
</column>
</createTable>
</changeSet>
<!--输出实体[SYS_ROLE]数据结构 -->
<changeSet author="a_A_5d9d78509" id="tab-sys_role-1-5">
<createTable tableName="IBZROLE">
<column name="SYS_ROLEID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_SYS_ROLE_SYS_ROLEID"/>
</column>
<column name="SYS_ROLENAME" remarks="" type="VARCHAR(200)">
</column>
<column name="MEMO" remarks="" type="VARCHAR(100)">
</column>
<column name="PROLEID" remarks="" type="VARCHAR(100)">
</column>
<column name="CREATEDATE" remarks="" type="DATETIME">
</column>
<column name="UPDATEDATE" remarks="" type="DATETIME">
</column>
<column name="CREATEMAN" remarks="" type="VARCHAR(60)">
</column>
<column name="UPDATEMAN" remarks="" type="VARCHAR(60)">
</column>
</createTable>
</changeSet>
<!--输出实体[SYS_ROLE_PERMISSION]数据结构 -->
<changeSet author="a_A_5d9d78509" id="tab-sys_role_permission-1-6">
<createTable tableName="IBZROLE_PERMISSION">
<column name="SYS_ROLE_PERMISSIONID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_SYS_ROLE_PERMISSION_SYS_ROL"/>
</column>
<column name="SYS_ROLEID" remarks="" type="VARCHAR(100)">
</column>
<column name="SYS_PERMISSIONID" remarks="" type="VARCHAR(200)">
</column>
<column name="CREATEDATE" remarks="" type="DATETIME">
</column>
<column name="UPDATEDATE" remarks="" type="DATETIME">
</column>
</createTable>
</changeSet>
<!--输出实体[SYS_USER_AUTH]数据结构 -->
<changeSet author="a_A_5d9d78509" id="tab-sys_user_auth-20-7">
<createTable tableName="IBZUSERAUTH">
<column name="AUTHID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_SYS_USER_AUTH_AUTHID"/>
</column>
<column name="USERID" remarks="" type="VARCHAR(100)">
</column>
<column name="IDENTITY_TYPE" remarks="" type="VARCHAR(100)">
</column>
<column name="IDENTIFIER" remarks="" type="VARCHAR(200)">
</column>
<column name="CREDENTIAL" remarks="" type="VARCHAR(500)">
</column>
</createTable>
</changeSet>
<!--输出实体[SYS_USER_ROLE]数据结构 -->
<changeSet author="a_A_5d9d78509" id="tab-sys_user_role-1-8">
<createTable tableName="IBZUSER_ROLE">
<column name="SYS_USER_ROLEID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_SYS_USER_ROLE_SYS_USER_ROLE"/>
</column>
<column name="SYS_ROLEID" remarks="" type="VARCHAR(100)">
</column>
<column name="SYS_USERID" remarks="" type="VARCHAR(100)">
</column>
<column name="CREATEDATE" remarks="" type="DATETIME">
</column>
<column name="UPDATEDATE" remarks="" type="DATETIME">
</column>
</createTable>
</changeSet>
<!--输出实体[SYS_AUTHLOG]外键关系 -->
<!--输出实体[SYS_OPEN_ACCESS]外键关系 -->
<!--输出实体[SYS_PSSYSTEM]外键关系 -->
<!--输出实体[SYS_PERMISSION]外键关系 -->
<!--输出实体[SYS_ROLE]外键关系 -->
<changeSet author="a_A_5d9d78509" id="fk-sys_role-1-9">
<addForeignKeyConstraint baseColumnNames="PROLEID" baseTableName="IBZROLE" constraintName="DER1N_SYS_ROLE_SYS_ROLE_PROLEI" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="SYS_ROLEID" referencedTableName="IBZROLE" validate="true"/>
</changeSet>
<!--输出实体[SYS_ROLE_PERMISSION]外键关系 -->
<changeSet author="a_A_5d9d78509" id="fk-sys_role_permission-1-10">
<addForeignKeyConstraint baseColumnNames="SYS_PERMISSIONID" baseTableName="IBZROLE_PERMISSION" constraintName="DER1N_SYS_ROLE_PERMISSION_SYS_" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="SYS_PERMISSIONID" referencedTableName="IBZPERMISSION" validate="true"/>
</changeSet>
<!--输出实体[SYS_USER_AUTH]外键关系 -->
<!--输出实体[SYS_USER_ROLE]外键关系 -->
<changeSet author="a_A_5d9d78509" id="fk-sys_user_role-1-12">
<addForeignKeyConstraint baseColumnNames="SYS_ROLEID" baseTableName="IBZUSER_ROLE" constraintName="DER1N_SYS_USER_ROLE_SYS_ROLE_S" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="SYS_ROLEID" referencedTableName="IBZROLE" validate="true"/>
</changeSet>
</databaseChangeLog>
......@@ -46,5 +46,114 @@ public class SysUserAuthResource {
@Lazy
public SysUserAuthMapping sysuserauthMapping;
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzuaa-SysUserAuth-Create-all')")
@ApiOperation(value = "新建账号绑定", tags = {"账号绑定" }, notes = "新建账号绑定")
@RequestMapping(method = RequestMethod.POST, value = "/sysuserauths")
public ResponseEntity<SysUserAuthDTO> create(@RequestBody SysUserAuthDTO sysuserauthdto) {
SysUserAuth domain = sysuserauthMapping.toDomain(sysuserauthdto);
sysuserauthService.create(domain);
SysUserAuthDTO dto = sysuserauthMapping.toDto(domain);
return ResponseEntity.status(HttpStatus.OK).body(dto);
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzuaa-SysUserAuth-Create-all')")
@ApiOperation(value = "批量新建账号绑定", tags = {"账号绑定" }, notes = "批量新建账号绑定")
@RequestMapping(method = RequestMethod.POST, value = "/sysuserauths/batch")
public ResponseEntity<Boolean> createBatch(@RequestBody List<SysUserAuthDTO> sysuserauthdtos) {
sysuserauthService.createBatch(sysuserauthMapping.toDomain(sysuserauthdtos));
return ResponseEntity.status(HttpStatus.OK).body(true);
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzuaa-SysUserAuth-Update-all')")
@ApiOperation(value = "更新账号绑定", tags = {"账号绑定" }, notes = "更新账号绑定")
@RequestMapping(method = RequestMethod.PUT, value = "/sysuserauths/{sysuserauth_id}")
public ResponseEntity<SysUserAuthDTO> update(@PathVariable("sysuserauth_id") String sysuserauth_id, @RequestBody SysUserAuthDTO sysuserauthdto) {
SysUserAuth domain = sysuserauthMapping.toDomain(sysuserauthdto);
domain .setId(sysuserauth_id);
sysuserauthService.update(domain );
SysUserAuthDTO dto = sysuserauthMapping.toDto(domain );
return ResponseEntity.status(HttpStatus.OK).body(dto);
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzuaa-SysUserAuth-Update-all')")
@ApiOperation(value = "批量更新账号绑定", tags = {"账号绑定" }, notes = "批量更新账号绑定")
@RequestMapping(method = RequestMethod.PUT, value = "/sysuserauths/batch")
public ResponseEntity<Boolean> updateBatch(@RequestBody List<SysUserAuthDTO> sysuserauthdtos) {
sysuserauthService.updateBatch(sysuserauthMapping.toDomain(sysuserauthdtos));
return ResponseEntity.status(HttpStatus.OK).body(true);
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzuaa-SysUserAuth-Remove-all')")
@ApiOperation(value = "删除账号绑定", tags = {"账号绑定" }, notes = "删除账号绑定")
@RequestMapping(method = RequestMethod.DELETE, value = "/sysuserauths/{sysuserauth_id}")
public ResponseEntity<Boolean> remove(@PathVariable("sysuserauth_id") String sysuserauth_id) {
return ResponseEntity.status(HttpStatus.OK).body(sysuserauthService.remove(sysuserauth_id));
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzuaa-SysUserAuth-Remove-all')")
@ApiOperation(value = "批量删除账号绑定", tags = {"账号绑定" }, notes = "批量删除账号绑定")
@RequestMapping(method = RequestMethod.DELETE, value = "/sysuserauths/batch")
public ResponseEntity<Boolean> removeBatch(@RequestBody List<String> ids) {
sysuserauthService.removeBatch(ids);
return ResponseEntity.status(HttpStatus.OK).body(true);
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzuaa-SysUserAuth-Get-all')")
@ApiOperation(value = "获取账号绑定", tags = {"账号绑定" }, notes = "获取账号绑定")
@RequestMapping(method = RequestMethod.GET, value = "/sysuserauths/{sysuserauth_id}")
public ResponseEntity<SysUserAuthDTO> get(@PathVariable("sysuserauth_id") String sysuserauth_id) {
SysUserAuth domain = sysuserauthService.get(sysuserauth_id);
SysUserAuthDTO dto = sysuserauthMapping.toDto(domain);
return ResponseEntity.status(HttpStatus.OK).body(dto);
}
@ApiOperation(value = "获取账号绑定草稿", tags = {"账号绑定" }, notes = "获取账号绑定草稿")
@RequestMapping(method = RequestMethod.GET, value = "/sysuserauths/getdraft")
public ResponseEntity<SysUserAuthDTO> getDraft() {
return ResponseEntity.status(HttpStatus.OK).body(sysuserauthMapping.toDto(sysuserauthService.getDraft(new SysUserAuth())));
}
@ApiOperation(value = "检查账号绑定", tags = {"账号绑定" }, notes = "检查账号绑定")
@RequestMapping(method = RequestMethod.POST, value = "/sysuserauths/checkkey")
public ResponseEntity<Boolean> checkKey(@RequestBody SysUserAuthDTO sysuserauthdto) {
return ResponseEntity.status(HttpStatus.OK).body(sysuserauthService.checkKey(sysuserauthMapping.toDomain(sysuserauthdto)));
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzuaa-SysUserAuth-Save-all')")
@ApiOperation(value = "保存账号绑定", tags = {"账号绑定" }, notes = "保存账号绑定")
@RequestMapping(method = RequestMethod.POST, value = "/sysuserauths/save")
public ResponseEntity<Boolean> save(@RequestBody SysUserAuthDTO sysuserauthdto) {
return ResponseEntity.status(HttpStatus.OK).body(sysuserauthService.save(sysuserauthMapping.toDomain(sysuserauthdto)));
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzuaa-SysUserAuth-Save-all')")
@ApiOperation(value = "批量保存账号绑定", tags = {"账号绑定" }, notes = "批量保存账号绑定")
@RequestMapping(method = RequestMethod.POST, value = "/sysuserauths/savebatch")
public ResponseEntity<Boolean> saveBatch(@RequestBody List<SysUserAuthDTO> sysuserauthdtos) {
sysuserauthService.saveBatch(sysuserauthMapping.toDomain(sysuserauthdtos));
return ResponseEntity.status(HttpStatus.OK).body(true);
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzuaa-SysUserAuth-searchDefault-all')")
@ApiOperation(value = "获取DEFAULT", tags = {"账号绑定" } ,notes = "获取DEFAULT")
@RequestMapping(method= RequestMethod.GET , value="/sysuserauths/fetchdefault")
public ResponseEntity<List<SysUserAuthDTO>> fetchDefault(SysUserAuthSearchContext context) {
Page<SysUserAuth> domains = sysuserauthService.searchDefault(context) ;
List<SysUserAuthDTO> list = sysuserauthMapping.toDto(domains.getContent());
return ResponseEntity.status(HttpStatus.OK)
.header("x-page", String.valueOf(context.getPageable().getPageNumber()))
.header("x-per-page", String.valueOf(context.getPageable().getPageSize()))
.header("x-total", String.valueOf(domains.getTotalElements()))
.body(list);
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzuaa-SysUserAuth-searchDefault-all')")
@ApiOperation(value = "查询DEFAULT", tags = {"账号绑定" } ,notes = "查询DEFAULT")
@RequestMapping(method= RequestMethod.POST , value="/sysuserauths/searchdefault")
public ResponseEntity<Page<SysUserAuthDTO>> searchDefault(@RequestBody SysUserAuthSearchContext context) {
Page<SysUserAuth> domains = sysuserauthService.searchDefault(context) ;
return ResponseEntity.status(HttpStatus.OK)
.body(new PageImpl(sysuserauthMapping.toDto(domains.getContent()), context.getPageable(), domains.getTotalElements()));
}
}
......@@ -22,9 +22,9 @@ spring:
max-file-size: 100MB
max-request-size: 100MB
datasource:
username: root
password: 'root'
url: jdbc:mysql://127.0.0.1:3306/ibzuaa?autoReconnect=true&useUnicode=true&characterEncoding=UTF-8&useOldAliasMetadataBehavior=true&allowMultiQueries=true
username: a_A_5d9d78509
password: '@6dEfb3@'
url: jdbc:mysql://172.16.180.232:3306/a_A_5d9d78509?autoReconnect=true&useUnicode=true&characterEncoding=UTF-8&useOldAliasMetadataBehavior=true&allowMultiQueries=true
driver-class-name: com.mysql.jdbc.Driver
filters: stat,wall,log4j2
#配置初始化大小/最小/最大
......@@ -45,7 +45,7 @@ spring:
pool-prepared-statements: false
max-pool-prepared-statement-per-connection-size: 20
isSyncDBSchema: false
defaultSchema: root
defaultSchema: a_A_5d9d78509
conf: classpath:liquibase/master.xml
#Mybatis-plus配置
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册