cafe_buy_duo 0.0.21 → 0.0.23

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.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/cafe_buy_duo.rb +70 -61
  3. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a08dd941b463ea6a2da44c03146dd90ac71e0c439781ae8181c83d432cb4e62d
4
- data.tar.gz: 0d7a4327ef647325b75dde558eec5c67d29f0c07c6f5473bf473431086d5be72
3
+ metadata.gz: a7639af0261a14854ff48b5b7cd5ae08dd5bb2c5d1b836de091d0e2c0eeb08d9
4
+ data.tar.gz: 435bbf352065f577bb4507991c6a3ccf76a023cfd62dcfa329f020debdbb7a66
5
5
  SHA512:
6
- metadata.gz: 290fb53426a540f56ef48937d5923c2a87236c1c4e1eb81c203b8520415eac8323941f8b9aa182ed0d1fa06b8cf95c3ab511e24fe7bf47bff24644d816f04ca3
7
- data.tar.gz: fca0e4c96bb6902c9c4e48100f668b531ceb30c12e3514bf0a8cefe9d6c8941e6009210cbbf305fe57fe3d7a5fe9da6b4fd65f6003cf47e68eacfacad7ec8d00
6
+ metadata.gz: 4e9bc99605e2b33bb98ff072055dd5ea6b547662bc42fdcfdfc029b8c5e7b9bf60db1c69d4958fb86aff0da980336ef5867e4080b334631f2e095327c056c6c7
7
+ data.tar.gz: 0d6ee0c53ec2801df192486244b3775b2f8594397dc5ffdf76bd2758f36e4c027f2a549d442c5470aa77c36d480c9f66008f4ba4101e6f280d93cb37e06abed4
data/lib/cafe_buy_duo.rb CHANGED
@@ -1564,11 +1564,11 @@ end
1564
1564
  end
1565
1565
  end
1566
1566
  end
1567
- sleep(1)
1567
+ sleep(0.5)
1568
1568
  @driver.action.key_down(:end).key_up(:end).perform
1569
- sleep(1)
1569
+ sleep(0.5)
1570
1570
  @driver.action.key_down(:enter).key_up(:enter).perform
1571
- sleep(1)
1571
+ sleep(0.5)
1572
1572
  # if check_image == 0
1573
1573
  # if value_data['nodes'].length == 0
1574
1574
  # value_data['nodes'][0] = {
@@ -1669,89 +1669,95 @@ end
1669
1669
  @driver.find_element(:xpath, '//*[@placeholder="태그를 입력해주세요 (최대 10개)"]').send_keys(tag_mm2.join("\n")+"\n")
1670
1670
 
1671
1671
  sleep(1)
1672
- # data['populationParams'] = '{"configuration":{"openType":'+option['공개']+',"commentYn":'+option['댓글허용']+',"searchYn":'+option['검색허용']+',"sympathyYn":'+option['공감허용']+',"scrapType":'+option['블로그공유']+',"outSideAllowYn":'+option['외부공유허용']+',"twitterPostingYn":false,"facebookPostingYn":false,"cclYn":false},"populationMeta":{"categoryId":'+category_value+',"logNo":null,"directorySeq":0,"directoryDetail":null,"mrBlogTalkCode":null,"postWriteTimeType":"now","tags":"'+tags2+'","moviePanelParticipation":false,"greenReviewBannerYn":false,"continueSaved":false,"noticePostYn":false,"autoByCategoryYn":false,"postLocationSupportYn":false,"postLocationJson":null,"prePostDate":null,"thisDayPostInfo":null,"scrapYn":false,"autoSaveNo":'+(Time.now.to_f.round(3)*1000).to_i.to_s+'},"editorSource":"AbZmtbYiAmhrzPJyhPXNWg=="}'
1673
- # if option['공개'] == '2'
1674
- # @driver.find_element(:xpath ,'//*[@id="root"]/div/div[1]/div/div[3]/div[3]/div/div/div/div[3]/div/div/ul/li[1]/span/label').click
1675
- # elsif option['공개'] == '3'
1676
- # @driver.find_element(:xpath, '//*[@id="root"]/div/div[1]/div/div[3]/div[3]/div/div/div/div[3]/div/div/ul/li[3]/span/label').click
1677
- # elsif option['공개'] == '0'
1678
- # @driver.find_element(:xpath, '//*[@id="root"]/div/div[1]/div/div[3]/div[3]/div/div/div/div[3]/div/div/ul/li[4]/span/label').click
1679
- # else
1680
- # @driver.find_element(:xpath, '//*[@id="root"]/div/div[1]/div/div[3]/div[3]/div/div/div/div[3]/div/div/ul/li[2]/span/label').click
1681
- # end
1672
+
1673
+ if option['전체공개'] == 'true'
1674
+ puts '전체공개'
1675
+ begin
1676
+ @driver.find_element(:xpath, '//*[@class="btn_open_set"]').click
1677
+ sleep(2)
1678
+ @driver.find_element(:xpath, '//*[@for="all"]').click
1679
+ rescue
1680
+ end
1681
+ sleep(1)
1682
+ end
1683
+
1684
+ if option['멤버공개'] == 'true'
1685
+ puts '멤버공개'
1686
+ begin
1687
+ @driver.find_element(:xpath, '//*[@class="btn_open_set"]').click
1688
+ sleep(2)
1689
+ @driver.find_element(:xpath, '//*[@for="member"]').click
1690
+ rescue
1691
+ end
1692
+ sleep(1)
1693
+ end
1694
+
1682
1695
  if option['댓글허용'] == 'true'
1683
1696
  puts '댓글허용'
1684
- begin
1685
- @driver.find_element(:xpath, '/html/body/div[1]/div/div/section/div/div[2]/div[2]/div[3]/ul/li[1]/div/label').click
1686
- sleep(1)
1687
-
1688
- rescue
1689
-
1697
+ begin
1698
+ @driver.find_element(:xpath, '//*[@for="coment"]').click
1699
+ rescue
1700
+ end
1701
+ sleep(1)
1690
1702
  end
1691
- end
1692
1703
 
1693
-
1704
+
1694
1705
  if option['블로그,카페 공유허용'] == 'true'
1695
1706
  puts '블로그,카페 공유허용'
1696
1707
  begin
1697
- @driver.find_element(:xpath, '/html/body/div[1]/div/div/section/div/div[2]/div[2]/div[3]/ul/li[2]/div[1]/label').click
1698
- sleep(1)
1699
- rescue
1700
-
1708
+ @driver.find_element(:xpath, '//*[@for="blog_sharing"]').click
1709
+ rescue
1710
+ end
1711
+ sleep(1)
1701
1712
  end
1702
- end
1703
1713
 
1704
1714
 
1705
-
1715
+
1706
1716
  if option['외부공유허용'] == 'true'
1707
1717
  puts '외부공유허용'
1708
1718
  begin
1709
- @driver.find_element(:xpath, '/html/body/div[1]/div/div/section/div/div[2]/div[2]/div[3]/ul/li[3]/div[1]/label').click
1710
- sleep(1)
1711
- rescue
1712
-
1719
+ @driver.find_element(:xpath, '//*[@for="external_sharing"]').click
1720
+ rescue
1721
+ end
1722
+ sleep(1)
1713
1723
  end
1714
- end
1715
1724
 
1716
- sleep(1)
1725
+
1717
1726
 
1718
1727
  if option['복사,저장 허용'] == 'true'
1719
1728
  puts '복사,저장 허용'
1720
1729
  begin
1721
- @driver.find_element(:xpath, '/html/body/div[1]/div/div/section/div/div[2]/div[2]/div[3]/ul/li[4]/div[1]/label').click
1730
+ @driver.find_element(:xpath, '//*[@for="copy"]').click
1731
+ rescue
1732
+ end
1722
1733
  sleep(1)
1723
- rescue
1724
-
1725
1734
  end
1726
- end
1727
1735
 
1728
-
1736
+
1729
1737
  if option['자동출처 사용'] == 'true'
1730
- puts '자동출처 사용'
1731
- begin
1732
- @driver.find_element(:xpath, '/html/body/div[1]/div/div/section/div/div[2]/div[2]/div[3]/ul/li[5]/div[1]/label').click
1733
- sleep(1)
1734
- rescue
1735
-
1736
- end
1737
- end
1738
+ puts '자동출처 사용'
1739
+ begin
1740
+ @driver.find_element(:xpath, '//*[@for="automatic_source"]').click
1741
+ rescue
1742
+ end
1743
+ sleep(1)
1744
+ end
1738
1745
 
1739
-
1746
+
1740
1747
 
1741
1748
  if option['CCL 사용'] == 'true'
1742
1749
  puts 'CCL 사용'
1743
1750
  begin
1744
- @driver.find_element(:xpath, '/html/body/div[1]/div/div/section/div/div[2]/div[2]/div[3]/ul/li[6]/div[1]/label').click
1751
+ @driver.find_element(:xpath, '//*[@for="ccl"]').click
1752
+ rescue
1753
+ end
1745
1754
  sleep(1)
1746
- rescue
1747
-
1748
1755
  end
1749
- end
1750
-
1756
+
1751
1757
  # puts data['documentModel'] = data['documentModel'].to_json
1752
- sleep(2)
1758
+
1753
1759
  sleep(dd_time.to_i)
1754
- @driver.find_element(:xpath, '/html/body/div[1]/div/div/section/div/div[1]/div/a').click
1760
+ @driver.find_element(:xpath, '//*[@class="BaseButton BaseButton--skinGreen size_default"]').click
1755
1761
 
1756
1762
  sleep(7)
1757
1763
 
@@ -3212,14 +3218,17 @@ class Wordpress
3212
3218
  option['배달'] = [@data['포스트설정']['직거래'].checked?, @data['포스트설정']['택배 거래'].checked?, @data['포스트설정']['온라인전송'].checked?]
3213
3219
  option['직 거래 카테고리'] = product_category1
3214
3220
  option['결제'] = payment
3221
+
3215
3222
  if @data['포스트설정']['전체공개'].checked?
3216
- option['공개'] = '2'
3217
- # elsif @data['포스트설정']['서로이웃공개'].checked?
3218
- # option['공개'] = '3'
3219
- # elsif @data['포스트설정']['비공개'].checked?
3220
- # option['공개'] = '0'
3223
+ option['전체공개'] = 'true'
3224
+ else
3225
+ option['전체공개'] = 'false'
3226
+ end
3227
+
3228
+ if @data['포스트설정']['멤버공개'].checked?
3229
+ option['멤버공개'] = 'true'
3221
3230
  else
3222
- option['공개'] = '1'
3231
+ option['멤버공개'] = 'false'
3223
3232
  end
3224
3233
 
3225
3234
  if @data['포스트설정']['댓글허용'].checked?
@@ -5168,7 +5177,7 @@ class Wordpress
5168
5177
  end
5169
5178
  }
5170
5179
  }
5171
- @data['포스트설정']['멤버공개'] = checkbox('맴버공개'){
5180
+ @data['포스트설정']['멤버공개'] = checkbox('멤버공개'){
5172
5181
  top 10
5173
5182
  left 1
5174
5183
  on_toggled{
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cafe_buy_duo
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.21
4
+ version: 0.0.23
5
5
  platform: ruby
6
6
  authors:
7
7
  - zon