@rolatech/angular-services 20.0.0-beta.13 → 20.0.0-beta.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1547,6 +1547,20 @@ class PropertyService extends BaseService {
1547
1547
  withCredentials: true,
1548
1548
  });
1549
1549
  }
1550
+ export() {
1551
+ return this.http.get(`${this.actionUrl}/export`, {
1552
+ observe: 'response',
1553
+ responseType: 'blob',
1554
+ withCredentials: true
1555
+ }).pipe(map((resp) => {
1556
+ const cd = resp.headers.get('Content-Disposition') || '';
1557
+ const match = /filename\*?=(?:UTF-8''|")?([^";]+)/i.exec(cd);
1558
+ const raw = match?.[1] ?? 'properties.csv';
1559
+ // decode RFC5987 filenames
1560
+ const filename = decodeURIComponent(raw.replace(/"/g, ''));
1561
+ return { blob: resp.body, filename };
1562
+ }));
1563
+ }
1550
1564
  archived(propertyId) {
1551
1565
  return this.http.post(`${this.actionUrl}/${propertyId}/archived`, {}, {
1552
1566
  withCredentials: true,
@@ -1883,6 +1897,35 @@ class PropertyService extends BaseService {
1883
1897
  deleteTenant(id) {
1884
1898
  return this.http.delete(`${this.actionUrl}/tenants/${id}`, { withCredentials: true });
1885
1899
  }
1900
+ //COS
1901
+ uploadVideoTourInit(propertyId, data) {
1902
+ return this.http.post(`${this.actionUrl}/${propertyId}/video-tour/init`, data, {
1903
+ withCredentials: true,
1904
+ });
1905
+ }
1906
+ uploadVideoTourPartsToProperty(propertyId, data) {
1907
+ return this.http.post(`${this.actionUrl}/${propertyId}/video-tour/parts`, data, {
1908
+ withCredentials: true,
1909
+ });
1910
+ }
1911
+ completePartUpload(propertyId, data) {
1912
+ return this.http.put(`${this.actionUrl}/${propertyId}/video-tour/parts`, data, {
1913
+ withCredentials: true,
1914
+ });
1915
+ }
1916
+ uploadVideoToProperty(propertyId, data) {
1917
+ return this.http.post(`${this.actionUrl}/${propertyId}/video-tour`, data, {
1918
+ withCredentials: true,
1919
+ });
1920
+ }
1921
+ deletePropertyVideo(propertyId, videoId) {
1922
+ return this.http.delete(`${this.actionUrl}/${propertyId}/video-tour/${videoId}`, { withCredentials: true });
1923
+ }
1924
+ uploadPropertyVideoThumbnail(videoId, data) {
1925
+ return this.http.post(`${this.actionUrl}/video-tour/${videoId}/thumbnail`, data, {
1926
+ withCredentials: true,
1927
+ });
1928
+ }
1886
1929
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.3", ngImport: i0, type: PropertyService, deps: null, target: i0.ɵɵFactoryTarget.Injectable });
1887
1930
  static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.1.3", ngImport: i0, type: PropertyService, providedIn: 'root' });
1888
1931
  }