This repository has been archived by the owner on Aug 30, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Conversation-management: import/export (#33)
- Loading branch information
Showing
10 changed files
with
197 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
/* | ||
* Copyright 2017 Redlink GmbH | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
* | ||
*/ | ||
|
||
angular | ||
.module('smartiApp') | ||
.config(function ($httpProvider) { | ||
// $httpProvider.interceptors.push('devAuthInterceptor'); | ||
}) | ||
.factory('devAuthInterceptor', function($location, $log) { | ||
var user = $location.search().user || 'user', | ||
passwd = $location.search().passwd || user; | ||
|
||
$log.error('!!Warning!! Using hard-coded credentials for user "' + user + '"'); | ||
return { | ||
'request': function(config) { | ||
if (user && passwd) { | ||
config.withCredentials = true; | ||
config.headers['Authorization'] = 'Basic ' + btoa(user+':'+passwd); | ||
} | ||
return config; | ||
} | ||
}; | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
<!-- | ||
~ Copyright 2017 Redlink GmbH | ||
~ | ||
~ Licensed under the Apache License, Version 2.0 (the "License"); | ||
~ you may not use this file except in compliance with the License. | ||
~ You may obtain a copy of the License at | ||
~ | ||
~ http://www.apache.org/licenses/LICENSE-2.0 | ||
~ | ||
~ Unless required by applicable law or agreed to in writing, software | ||
~ distributed under the License is distributed on an "AS IS" BASIS, | ||
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
~ See the License for the specific language governing permissions and | ||
~ limitations under the License. | ||
~ | ||
--> | ||
|
||
<form class="form" name="uploadForm" ng-submit="$modal.upload()"> | ||
<div class="modal-header"> | ||
<h3 class="modal-title">Import Conversations</h3> | ||
</div> | ||
<div class="modal-body" id="modal-body"> | ||
<div class="form-group"> | ||
<input type="file" name="file" | ||
ngf-select | ||
accept="application/json" | ||
ng-model="$modal.uploadFile" required/> | ||
<p></p> | ||
</div> | ||
<div class="checkbox"> | ||
<label><input type="checkbox" ng-model="$modal.uploadReplace" class="checkbox">Replace</label> | ||
</div> | ||
</div> | ||
<div class="modal-footer"> | ||
<button class="btn btn-primary" ng-disabled="uploadForm.$invalid"> | ||
<i class="glyphicon glyphicon-upload"></i> Importieren | ||
</button> | ||
<button class="btn btn-default" type="reset" ng-click="$modal.cancel()">Cancel</button> | ||
</div> | ||
</form> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters