|
@@ -3752,6 +3752,8 @@ function ($rootScope, $scope, $state, $translate, $localStorage, $cookieStore, $
|
3752
|
3752
|
) {
|
3753
|
3753
|
// -------------------start----------------------
|
3754
|
3754
|
$scope.modelData = modelData;
|
|
3755
|
+ // 事件报修图片
|
|
3756
|
+ $scope.requestImgs = [];
|
3755
|
3757
|
// 当前所属院区处理
|
3756
|
3758
|
console.log(modelData);
|
3757
|
3759
|
// if(modelData){
|
|
@@ -3795,6 +3797,13 @@ function ($rootScope, $scope, $state, $translate, $localStorage, $cookieStore, $
|
3795
|
3797
|
//报修生成事件,数据回显
|
3796
|
3798
|
//来电生成事件,数据回显
|
3797
|
3799
|
//暂存生成事件,数据回显
|
|
3800
|
+ // 报修图片
|
|
3801
|
+ if (modelData.incident) {
|
|
3802
|
+ api_wechatfile.listAttachment("wechatRequesterIncident", modelData.incident.id).then( (res) => {
|
|
3803
|
+ $scope.requestImgs = res.data || [];
|
|
3804
|
+ });
|
|
3805
|
+ }
|
|
3806
|
+
|
3798
|
3807
|
$scope.categorySelect = modelData.incident.category;
|
3799
|
3808
|
$scope.jry_modelLeft = modelData.incident.category?modelData.incident.category.mutiCategory:'';
|
3800
|
3809
|
console.log($scope.jry_deptData)
|
|
@@ -3820,6 +3829,27 @@ function ($rootScope, $scope, $state, $translate, $localStorage, $cookieStore, $
|
3820
|
3829
|
};
|
3821
|
3830
|
}
|
3822
|
3831
|
$scope.minYYtime = new Date();
|
|
3832
|
+ // 预览图片
|
|
3833
|
+ $scope.previewNew = function (type, url, idx) {
|
|
3834
|
+ let title = $scope[type][idx].title;
|
|
3835
|
+ $modal.open({
|
|
3836
|
+ backdrop: false,
|
|
3837
|
+ size: "sm",
|
|
3838
|
+ templateUrl: "assets/views/customform/tpl/ui-showimage.html",
|
|
3839
|
+ controller: function ($scope, $rootScope, scope, $modalInstance) {
|
|
3840
|
+ $scope.title = title;
|
|
3841
|
+ $scope.imageurl = $rootScope.attachmentAddressSplicing(url);
|
|
3842
|
+ $scope.cancel = function () {
|
|
3843
|
+ $modalInstance.dismiss("cancel");
|
|
3844
|
+ };
|
|
3845
|
+ },
|
|
3846
|
+ resolve: {
|
|
3847
|
+ scope: function () {
|
|
3848
|
+ return $scope;
|
|
3849
|
+ },
|
|
3850
|
+ },
|
|
3851
|
+ });
|
|
3852
|
+ };
|
3823
|
3853
|
// 建单并派单
|
3824
|
3854
|
$scope.buildAndAssign = function(){
|
3825
|
3855
|
if(!$scope.categorySelectId){
|
|
@@ -3974,7 +4004,7 @@ function ($rootScope, $scope, $state, $translate, $localStorage, $cookieStore, $
|
3974
|
4004
|
// 有图片
|
3975
|
4005
|
$scope.uploader.onBeforeUploadItem = function(item) {
|
3976
|
4006
|
angular.extend(item.headers, $rootScope.getSession());
|
3977
|
|
- item.url = api_bpm_domain.uploadAttachment(response.id).getRequestedUrl();
|
|
4007
|
+ item.url = api_bpm_domain.uploadAttachmentJryModel("wechatRequesterIncident", response.data.id).getRequestedUrl();
|
3978
|
4008
|
item.formData.push({ 'fileName': item.file.name });
|
3979
|
4009
|
};
|
3980
|
4010
|
$scope.uploader.uploadAll();
|
|
@@ -4059,7 +4089,7 @@ function ($rootScope, $scope, $state, $translate, $localStorage, $cookieStore, $
|
4059
|
4089
|
// 有图片
|
4060
|
4090
|
$scope.uploader.onBeforeUploadItem = function(item) {
|
4061
|
4091
|
angular.extend(item.headers, $rootScope.getSession());
|
4062
|
|
- item.url = api_bpm_domain.uploadAttachment(response.id).getRequestedUrl();
|
|
4092
|
+ item.url = api_bpm_domain.uploadAttachmentJryModel("wechatRequesterIncident", response.data.id).getRequestedUrl();
|
4063
|
4093
|
item.formData.push({ 'fileName': item.file.name });
|
4064
|
4094
|
};
|
4065
|
4095
|
$scope.uploader.uploadAll();
|
|
@@ -4471,7 +4501,7 @@ function ($rootScope, $scope, $state, $translate, $localStorage, $cookieStore, $
|
4471
|
4501
|
// 有图片
|
4472
|
4502
|
scope.uploader.onBeforeUploadItem = function(item) {
|
4473
|
4503
|
angular.extend(item.headers, $rootScope.getSession());
|
4474
|
|
- item.url = api_bpm_domain.uploadAttachment(resData.id).getRequestedUrl();
|
|
4504
|
+ item.url = api_bpm_domain.uploadAttachmentJryModel("wechatRequesterIncident", resData.data.id).getRequestedUrl();
|
4475
|
4505
|
item.formData.push({ 'fileName': item.file.name });
|
4476
|
4506
|
};
|
4477
|
4507
|
scope.uploader.uploadAll();
|