diff --git a/static/resources/js/components/replication/create-policy.directive.html b/static/resources/js/components/replication/create-policy.directive.html index 84c9e8b5c..b77da9eab 100644 --- a/static/resources/js/components/replication/create-policy.directive.html +++ b/static/resources/js/components/replication/create-policy.directive.html @@ -9,74 +9,75 @@ - +
- - - - - - + + + + + + - + @@ -31,8 +31,8 @@
NameDescriptionDestinationStart TimeActivationActions// 'name' | tr //// 'description' | tr //// 'destination' | tr //// 'start_time' | tr //// 'activation' | tr// // 'actions' | tr //

No replication policies, add new replication policy.

// 'no_replication_policies' | tr //

//r.name////r.target_name// //r.start_time | dateL : 'YYYY-MM-DD HH:mm:ss'// - Enabled - Disabled + // 'enabled' | tr // + // 'disabled' | tr //
@@ -51,7 +51,7 @@
//vm.replicationPolicies ? vm.replicationPolicies.length : 0// // 'items' | tr //

-

Replication Jobs

+

// 'replication_jobs' | tr //


@@ -65,15 +65,15 @@
- - - - - + + + + + - + diff --git a/static/resources/js/components/system-management/create-destination.directive.html b/static/resources/js/components/system-management/create-destination.directive.html index 81d29fc90..fd2565625 100644 --- a/static/resources/js/components/system-management/create-destination.directive.html +++ b/static/resources/js/components/system-management/create-destination.directive.html @@ -9,48 +9,47 @@ - +
@@ -15,14 +15,14 @@
NameOperationStart TimeStatusLogs// 'name' | tr //// 'operation' | tr //// 'start_time' | tr //// 'status' | tr //// 'logs' | tr //

No replication jobs.

// 'no_replication_jobs' | tr //

//r.repository//
- - - - + + + + - + diff --git a/static/resources/js/components/system-management/destination.directive.js b/static/resources/js/components/system-management/destination.directive.js index de0a5f059..54ecac4b2 100644 --- a/static/resources/js/components/system-management/destination.directive.js +++ b/static/resources/js/components/system-management/destination.directive.js @@ -52,7 +52,7 @@ } function listDestinationSuccess(data, status) { - vm.destinations = data; + vm.destinations = data || []; } function listDestinationFailed(data, status) { diff --git a/static/resources/js/components/system-management/replication.directive.html b/static/resources/js/components/system-management/replication.directive.html index 54fdeebe2..c61ba1976 100644 --- a/static/resources/js/components/system-management/replication.directive.html +++ b/static/resources/js/components/system-management/replication.directive.html @@ -13,17 +13,17 @@
NameEndpointCreation TimeAction// 'name' | tr //// 'endpoint' | tr //// 'creation_time' | tr //// 'actions' | tr //

No destinations, add new destination.

// 'no_destinations' | tr //

//r.name//
- - - - - - - + + + + + + + - + @@ -31,7 +31,10 @@ - +
NameDescriptionProjectDestinationStart TimeActivationActions// 'name' | tr //// 'description' | tr //// 'projects' | tr //// 'destination' | tr //// 'start_time' | tr //// 'activation' | tr //// 'actions' | tr //

No replications.

// 'no_replications' | tr //

//r.name////r.project_name// //r.target_name// //r.start_time | dateL : 'YYYY-MM-DD HH:mm:ss'////r.enabled == 1 ? 'Enabled' : 'Disabled'// + // 'enabled' | tr // + // 'disabled' | tr // +
diff --git a/static/resources/js/layout/navigation/navigation-admin-options.directive.html b/static/resources/js/layout/navigation/navigation-admin-options.directive.html index 18154b033..0f5b53086 100644 --- a/static/resources/js/layout/navigation/navigation-admin-options.directive.html +++ b/static/resources/js/layout/navigation/navigation-admin-options.directive.html @@ -1,6 +1,6 @@
    -
  • Destinations|
  • -
  • Replication +
  • // 'destination' | tr //|
  • +
  • // 'replication' | tr // diff --git a/static/resources/js/layout/navigation/navigation-details.directive.html b/static/resources/js/layout/navigation/navigation-details.directive.html deleted file mode 100644 index 12addf369..000000000 --- a/static/resources/js/layout/navigation/navigation-details.directive.html +++ /dev/null @@ -1,5 +0,0 @@ - \ No newline at end of file diff --git a/static/resources/js/layout/navigation/navigation-header.directive.js b/static/resources/js/layout/navigation/navigation-header.directive.js index 2326c1ba2..9d5464ca1 100644 --- a/static/resources/js/layout/navigation/navigation-header.directive.js +++ b/static/resources/js/layout/navigation/navigation-header.directive.js @@ -28,7 +28,8 @@ function link(scope, element, attrs, ctrl) { var visited = ctrl.url; - if (visited !== "") { + console.log('visited:' + visited); + if (visited !== '' && visited !== '/') { element.find('a[href*="' + visited + '"]').addClass('active'); } element.find('a').on('click', click); diff --git a/static/resources/js/services/i18n/locale_messages_en-US.js b/static/resources/js/services/i18n/locale_messages_en-US.js index b036c35aa..5eb5f59eb 100644 --- a/static/resources/js/services/i18n/locale_messages_en-US.js +++ b/static/resources/js/services/i18n/locale_messages_en-US.js @@ -134,5 +134,31 @@ var locale_messages = { 'confirm_to_delete_user_title': 'Delete user', 'confirm_to_delete_user': 'Are you sure to delete the current user?', 'confirm_to_delete_destination_title': 'Delete destination', - 'confirm_to_delete_destination': 'Are you sure to delete the current destination?' + 'confirm_to_delete_destination': 'Are you sure to delete the current destination?', + 'replication': 'Replication', + 'add_new_replication': 'New Replication', + 'name': 'Name', + 'description': 'Description', + 'destination': 'Destination', + 'start_time': 'Start Time', + 'activation': 'Activation', + 'replication_jobs': 'Replication Jobs', + 'actions': 'Actions', + 'status': 'Status', + 'logs' : 'Logs', + 'enabled': 'Enabled', + 'disabled': 'Disabled', + 'no_replication_policies': 'No replication policies, add new replication policy.', + 'no_replications': 'No replications.', + 'no_replication_jobs': 'No replication jobs.', + 'no_destinations': 'No destinations, add new destination.', + 'name_is_required': 'Name is required.', + 'name_is_too_long': 'Name is too long. (maximum 20 characters)', + 'description_is_too_long': 'Description is too long. (maximum 20 characters)', + 'enable': 'Enable', + 'general_setting': 'General', + 'destination_setting': 'Destination Setting', + 'endpoint': 'Endpoint', + 'test_connection': 'Test connection', + 'add_new_destination': 'New Destination' }; \ No newline at end of file diff --git a/static/resources/js/services/i18n/locale_messages_zh-CN.js b/static/resources/js/services/i18n/locale_messages_zh-CN.js index 0ebd36252..d8c15f437 100644 --- a/static/resources/js/services/i18n/locale_messages_zh-CN.js +++ b/static/resources/js/services/i18n/locale_messages_zh-CN.js @@ -132,5 +132,32 @@ var locale_messages = { 'confirm_to_delete_user_title': '删除用户', 'confirm_to_delete_user': '确认删除当前用户吗?', 'confirm_to_delete_destination_title': '删除目标', - 'confirm_to_delete_destination': '确认删除当前目标吗?' + 'confirm_to_delete_destination': '确认删除当前目标吗?', + 'replication': '复制', + 'add_new_replication': '新增复制', + 'name': '名称', + 'description': '描述', + 'destination': '目标', + 'start_time': '起始时间', + 'activation': '活动状态', + 'replication_jobs': '复制任务', + 'actions': '操作', + 'status': '状态', + 'logs': '日志', + 'enabled': '启用', + 'disabled': '停用', + 'no_replication_policies': '没有复制策略,请新增复制策略。', + 'no_replications': '没有复制策略。', + 'no_replication_jobs': '没有复制任务。', + 'no_destinations': '没有目标设置,请新增目标。', + 'name_is_required': '名称为必填项', + 'name_is_too_long': '名称长度超出限制。(最长为20个字符)', + 'description_is_too_long': '描述内容长度超出限制。(最长为20个字符)', + 'enable': '启用', + 'general_setting': '一般设置', + 'destination_setting': '目标设置', + 'endpoint': '终端URL', + 'endpoint_is_required': '终端URL为必填项。', + 'test_connection': '测试连接', + 'add_new_destination': '新建目标' }; \ No newline at end of file diff --git a/views/navigation-detail.htm b/views/navigation-detail.htm index 98e8da761..22b075c79 100644 --- a/views/navigation-detail.htm +++ b/views/navigation-detail.htm @@ -1,7 +1,7 @@